Skip to content
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

SEC-2148: AccessDecisionVoters should return an AccessDecision instead of int #2374

Open
spring-projects-issues opened this issue Mar 8, 2013 · 0 comments
Labels
in: core An issue in spring-security-core type: enhancement A general enhancement type: jira An issue that was migrated from JIRA

Comments

@spring-projects-issues
Copy link

Janning Vygen (Migrated from SEC-2148) said:

An AccessDecisionManager throws an AccessDeniedException (ADE) which is handled later by an ExceptionTranslationFilter and AccessDeniedHandler. Inside AccessDeniedHandler we would like to forward to different error pages depending on the cause of the ADE.

But the AccessDecisionManager is just asking AccessDecisionVoter and it just returns an int for ACCESS_GRANTED or ACCESS_DENIED. It would be nice if an AccessDecisionVoter would return an AccessDecision which can hold the pure decision like granted/denied and a cause if the access was denied.

The AccessDecisionManager could then throw an ADE containing the accessDecision. The AccessDeniedHandler can grab this decision and decide what to show to the user.

@spring-projects-issues spring-projects-issues added in: core An issue in spring-security-core Open type: enhancement A general enhancement type: jira An issue that was migrated from JIRA labels Feb 5, 2016
@rwinch rwinch removed the Open label May 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: core An issue in spring-security-core type: enhancement A general enhancement type: jira An issue that was migrated from JIRA
Projects
None yet
Development

No branches or pull requests

2 participants