Skip to content

Method Security SpEL supports AuthorizationDecision return types #14598

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Tracked by #14595
rwinch opened this issue Feb 13, 2024 · 0 comments
Closed
Tracked by #14595

Method Security SpEL supports AuthorizationDecision return types #14598

rwinch opened this issue Feb 13, 2024 · 0 comments
Assignees
Labels
type: enhancement A general enhancement

Comments

@rwinch
Copy link
Member

rwinch commented Feb 13, 2024

It would be nice if we supported AuthrozationDecision return types for Method Security SpEL. This would allow method security to easily convey more information to the framework on why authorization failed (e.g. requires MFA). For example:

@Service
class Authz {
  AuthorizationDecision check(...) {
    // ...
  }
}
@PreAuthorize("@authz.check(...)")
@rwinch rwinch added the type: enhancement A general enhancement label Feb 13, 2024
@jzheaux jzheaux self-assigned this Feb 27, 2024
@jzheaux jzheaux closed this as completed in 6f07d63 Apr 4, 2024
jzheaux added a commit that referenced this issue Apr 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants