fix: Remove permitted root route

This commit is contained in:
Phan Huy Tran 2025-02-05 12:35:24 +01:00
parent 9976a000ee
commit db81b4a710
2 changed files with 1 additions and 1 deletions

View File

@ -53,7 +53,7 @@ class KeycloakSecurityConfig {
@Bean
public SecurityFilterChain resourceServerFilterChain(HttpSecurity http) throws Exception {
http.authorizeHttpRequests(auth -> auth
.requestMatchers("/test", "/", "/swagger", "/swagger-ui/**", "/v3/api-docs/**", "/health").permitAll()
.requestMatchers("/swagger", "/swagger-ui/**", "/v3/api-docs/**", "/health").permitAll()
.anyRequest().authenticated()
)
.oauth2ResourceServer(spec -> spec.jwt(Customizer.withDefaults()));