Use securityMatcher() and authorizeHttpRequests()

Closes gh-922
This commit is contained in:
Joe Grandja
2022-10-22 06:00:16 -04:00
parent 411bf63bc3
commit 64d26a42a0
17 changed files with 70 additions and 70 deletions

View File

@@ -41,9 +41,9 @@ public class DefaultSecurityConfig {
FederatedIdentityConfigurer federatedIdentityConfigurer = new FederatedIdentityConfigurer()
.oauth2UserHandler(new UserRepositoryOAuth2UserHandler());
http
.authorizeRequests(authorizeRequests ->
authorizeRequests
.mvcMatchers("/assets/**", "/webjars/**", "/login").permitAll()
.authorizeHttpRequests(authorize ->
authorize
.requestMatchers("/assets/**", "/webjars/**", "/login").permitAll()
.anyRequest().authenticated()
)
.formLogin(Customizer.withDefaults())