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

Allow customization of redirect strategy in CasAuthenticationEntrypoint #14881

Closed
kakawait opened this issue Apr 10, 2024 · 2 comments
Closed
Assignees
Labels
in: cas An issue in spring-security-cas type: enhancement A general enhancement
Milestone

Comments

@kakawait
Copy link

kakawait commented Apr 10, 2024

Expected Behavior

Allow more customization or inheritance for CasAuthenticationEntrypoint

Current Behavior

CasAuthenticationEntrypoint has final keyword on

@Override
public final void commence(final HttpServletRequest servletRequest, HttpServletResponse response,
		AuthenticationException authenticationException) throws IOException {
...
}

that prevent developer to change behavior.

If removing final isn't acceptable, otherwise allow changing hardcoded new DefaultRedirectStrategy() inside commence to allow injecting RedirectStrategy inside constructor

Context

Allow developer to apply different strategy without having copying CasAuthenticationEntrypoint, could resolve #3123 for example


I'm totally ok to propose a PR, but I'd like to get validation that is something acceptable

@kakawait kakawait added status: waiting-for-triage An issue we've not yet triaged type: enhancement A general enhancement labels Apr 10, 2024
@rishiraj88
Copy link
Contributor

Looks like a nice suggestion. Flexibility should be favoured unless there is a strong blocker.

@marcusdacoregio marcusdacoregio added in: cas An issue in spring-security-cas and removed status: waiting-for-triage An issue we've not yet triaged labels Apr 10, 2024
@marcusdacoregio marcusdacoregio self-assigned this Apr 10, 2024
@marcusdacoregio marcusdacoregio changed the title Open CasAuthenticationEntrypoint for better customization Allow customization of redirect strategy in CasAuthenticationEntrypoint Apr 10, 2024
@marcusdacoregio
Copy link
Contributor

Thanks for the report @kakawait. I've repurposed the ticket to allow customization of the redirect strategy if you are okay with it.

@marcusdacoregio marcusdacoregio added this to the 6.3.0-RC1 milestone Apr 10, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: cas An issue in spring-security-cas type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

3 participants