I understand the following on the spring security servlet application:
@Override
public void configure(WebSecurity web) throws Exception {
web.ignoring().mvcMatchers(""/favicon.ico", "/doc.html", "/webjars/**", "/swagger-resources/**", "/**/v2/api-docs"");
}
The following requests go through the filter on spring security Reactive application:
@Bean
public SecurityWebFilterChain springSecurityFilterChain( ServerHttpSecurity http ) {
final String[] skipSwaggerUrls = new String[] {
"/favicon.ico",
"/doc.html",
"/webjars/**",
"/swagger-resources/**",
"/**/v2/api-docs" };
http.authorizeExchange()
.pathMatchers( skipSwaggerUrls ).permitAll()
.anyExchange().authenticated()
.and().csrf().disable()
.oauth2ResourceServer()
.bearerTokenConverter( new JwtExtractTokenAuthenticationConverter() )
.authenticationEntryPoint( new UserAuthenticationEntryPoint() )
.accessDeniedHandler( new UserAccessDeniedHandler() )
.jwt();
return http.build();
}
How to keep static resource requests out of the filter on Spring Security WebFlux Reactive Application?
Thanks for your help