Summary
I set HTTP OPTIONS Request permitAll,But Request also had been intercepted
Actual Behavior
Expected Behavior
Configuration
springboot , vue.js
Version
Version :
Sample
I had set
1:)
HttpSecurity.requestMatchers().antMatchers(HttpMethod.OPTIONS)
.and()
.cors()
.and()
.csrf().disable();
2:) CorsRegistry.addMapping("/").allowedOrigins("").allowCredentials(true) .allowedMethods("GET", "POST", "DELETE", "PUT", "OPTIONS").maxAge(3600).allowedHeaders("");
3:) HttpSecurity.addFilterBefore( new LoginAuthenticationFilter( new AntPathRequestMatcher("/login"), authenticationManager(), loginAuthenticationHandler), UsernamePasswordAuthenticationFilter.class)
I want to keep all the RequestMethod of OPTIONS out of loginFilter, but it does't work
Comment From: clevertension
@ssjsyswa it seems that your have misconfigure the cors in step2, can you provide a demo so i can dig more about your problem
Comment From: eleftherias
Closing due to lack of feedback.