File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
core/src/main/java/hudson/security Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change 3939import jenkins .util .SystemProperties ;
4040import org .kohsuke .accmod .Restricted ;
4141import org .kohsuke .accmod .restrictions .NoExternalUse ;
42+ import org .springframework .http .HttpMethod ;
4243import org .springframework .security .core .Authentication ;
4344import org .springframework .security .core .AuthenticationException ;
4445import org .springframework .security .web .authentication .UsernamePasswordAuthenticationFilter ;
45- import org .springframework .security .web .util .matcher .AntPathRequestMatcher ;
46+ import org .springframework .security .web .servlet . util .matcher .PathPatternRequestMatcher ;
4647
4748/**
4849 * Login filter with a change for Jenkins so that
@@ -56,7 +57,7 @@ public final class AuthenticationProcessingFilter2 extends UsernamePasswordAuthe
5657
5758 @ SuppressFBWarnings (value = "HARD_CODE_PASSWORD" , justification = "This is a password parameter, not a password" )
5859 public AuthenticationProcessingFilter2 (String authenticationGatewayUrl ) {
59- setRequiresAuthenticationRequestMatcher (new AntPathRequestMatcher ( "/" + authenticationGatewayUrl , "POST" ));
60+ setRequiresAuthenticationRequestMatcher (PathPatternRequestMatcher . withDefaults (). matcher ( HttpMethod . POST , "/" + authenticationGatewayUrl ));
6061 // Jenkins/login.jelly & SetupWizard/authenticate-security-token.jelly
6162 setUsernameParameter ("j_username" );
6263 setPasswordParameter ("j_password" );
You can’t perform that action at this time.
0 commit comments