Skip to content

Fix beanResolver missing in CurrentSecurityContextArgumentResolver. #9331

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
wants to merge 2 commits into from

Conversation

happier233
Copy link
Contributor

CurrentSecurityContextArgumentResolver has 'beanResolver' property, but never used. I think it might be missed.
I test the AuthenticationPrincipal annotation and CurrentSecurityContext annotation, CurrentSecurityContext annotation expression cannot work with bean.

@pivotal-issuemaster
Copy link

@happier233 Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Jan 6, 2021
@pivotal-issuemaster
Copy link

@happier233 Thank you for signing the Contributor License Agreement!

Copy link
Contributor

@jzheaux jzheaux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch, @happier233! Would you please add a test that demonstrates that beanResolver is now getting used?

@jzheaux jzheaux self-assigned this Jan 6, 2021
@jzheaux jzheaux added in: web An issue in web modules (web, webmvc) type: bug A general bug and removed status: waiting-for-triage An issue we've not yet triaged labels Jan 6, 2021
@jzheaux
Copy link
Contributor

jzheaux commented Jan 26, 2021

@happier233 are you able to make the requested changes to your PR?

@jzheaux jzheaux added the status: waiting-for-feedback We need additional information before we can continue label Jan 26, 2021
@happier233 happier233 force-pushed the master branch 3 times, most recently from 083de60 to 49fbcd7 Compare February 3, 2021 13:42
@happier233
Copy link
Contributor Author

@jzheaux I'm very sorry for costing many days to add the test to the PR, but I don't know where the code in my PR caused the format error.

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Feb 3, 2021
@jzheaux
Copy link
Contributor

jzheaux commented Feb 3, 2021

No problem, @happier233. I've merged your changes in 873b9bd and polished it in 107f38f.

In the future, you can run ./gradlew format to update the formatting in your changes.

@jzheaux jzheaux closed this Feb 3, 2021
jzheaux added a commit that referenced this pull request Feb 3, 2021
jzheaux added a commit that referenced this pull request Feb 3, 2021
@spring-projects-issues spring-projects-issues added the status: backported An issue that has been backported to maintenance branches label Feb 3, 2021
jzheaux added a commit that referenced this pull request Feb 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web An issue in web modules (web, webmvc) status: backported An issue that has been backported to maintenance branches status: feedback-provided Feedback has been provided type: bug A general bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants