LogoutConfigurer#createLogoutFilter sets the SecurityContextHolderStrategy twice #14592
Labels
in: config
An issue in spring-security-config
status: duplicate
A duplicate of another issue
type: bug
A general bug
The
org.springframework.security.config.annotation.web.configurers.LogoutConfigurer#createLogoutFilter
method sets theSecurityContextHolderStrategy
of the resultLogoutFilter
twice since #11061 and commit.I don't see any particular reason behind this because (as of now) the
LogoutRequestMatcher
andSecurityContextHolderStrategy
are unrelated (althoughorg.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer#getSecurityContextHolderStrategy
is protected so it could be overridden, butLogoutConfigurer
is final so there will be no subclasses).IMHO one
result.setSecurityContextHolderStrategy(getSecurityContextHolderStrategy());
call is (and will be) enough here.My educated guess is that this is some unfortunate side effect of the great copy-paste function. :)
The text was updated successfully, but these errors were encountered: