@AuthenticationPrincipal resolves to null when spring security is also included #26380
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
status: invalid
An issue that we don't feel is valid
Followup to #26117.
When using boot 2.4.1 with managed spring and spring security dependencies @AuthenticationPrincipal is no longer bound. Brief debugging appears to indicate that AuthenticationPrincipalArgumentResolver 'supports' the argument and resolves it to null before PrincipalMethodArgumentResolver has a chance to resolve it.
Sample project: https://github.com/krm1312/spring-auth-principal.
Toggle boot version in pom.xml to see difference.
The text was updated successfully, but these errors were encountered: