VMware vRealize Automation 8.x (2022) — Question 14
Which two use cases can be addressed by the method level security annotation @PreAuthorize? (Choose two.)
Answer options
- A. Allow access to a method based on user identity.
- B. Allow access to a method based on the returned object.
- C. Allow access to a method based on HTTP method.
- D. Allow access to a method based on request URL.
- E. Allow access to a method based on roles.
Correct answer: A, E
Explanation
@PreAuthorize is specifically designed to control access to methods based on user identity and roles, making options A and E correct. Options B, C, and D do not align with the intended use of @PreAuthorize, as they do not pertain to user identity or roles.