Skip to content

AccountStatusUserDetailsChecker should implement MessageSourceAware #3980

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
gesellix opened this issue Jul 18, 2016 · 1 comment · Fixed by #6151
Closed

AccountStatusUserDetailsChecker should implement MessageSourceAware #3980

gesellix opened this issue Jul 18, 2016 · 1 comment · Fixed by #6151
Assignees
Labels
in: core An issue in spring-security-core
Milestone

Comments

@gesellix
Copy link

Summary

We're using Spring Security on Google App Engine. The class java.util.ResourceBundle$Control is a restricted class on GAE, which makes our application fail when using Spring Security's AbstractRememberMeServices, which internally uses the AccountStatusUserDetailsChecker.
The AccountStatusUserDetailsChecker uses a SpringSecurityMessageSource, whose javadoc states that all such classes [using SpringSecurityMessageSource] will also implement <code>MessageSourceAware</code>.

Actual Behavior

AccountStatusUserDetailsChecker uses SpringSecurityMessageSource, but doesn't implement MessageSourceAware.

Consequently, we cannot inject our own MessageSource into the default UserDetailsChecker, so that we would be forced to sub-class or implement a UserDetailsChecker with a GAE-compatible MessageSource.

Expected Behavior

AccountStatusUserDetailsChecker should implement MessageSourceAware.

Alternatively it could help to configure the SpringSecurityMessageSource to use a custom MessageSource?

Version

We're using Spring Security 4.0.3.RELEASE. The current master seems to have the same issue, though.

@danilychen
Copy link

It will be enough to add constructor to initialise messages field!

weebl2000 added a commit to weebl2000/spring-security that referenced this issue Dec 7, 2018
@rwinch rwinch self-assigned this May 1, 2019
@rwinch rwinch added this to the 5.2.0.M3 milestone May 1, 2019
@rwinch rwinch added the in: core An issue in spring-security-core label May 1, 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
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants