Sep 30th, 2012, 01:22 AM
No way to override default RedirectStrategy for LoginUrlAuthenticationEntryPoint
I need to inject a different implementation of org.springframework.security.web.RedirectStrategy into org.springframework.security.web.authentication.Lo ginUrlAuthenticationEntryPoint. However, I noticed, as of 3.1.2.RELEASE, there is no way to change the default (DefaultRedirectStrategy) RedirectStrategy either via constructor or field mutator.
For now, what I did, is that I created a new class and copy ( @_@ ) the entire LoginUrlAuthenticationEntryPoint code into it and add a constructor to inject a RedirectStrategy.
In other classes like AbstractAuthenticationTargetUrlRequestHandler, it has a setter to override the default RedirectStrategy, and I think it should also be for LoginUrlAuthenticationEntryPoint.
What do you guys think? Should I create a Jira issue for this already?
Let me know.