Spring Security causes / or any path to redirect to /login, and /login to generate and serve a login form. I tried many options like adding these lines to my properties file
security.ignored=/**
spring.security.enabled=false
management.security.enabled=false
security.basic.enabled=false
Nothing worked.

This has been deprecated maybe.
Seems security.ignored=/** has been moved out from Spring Boot 2.x as if Spring Security is on the classpath, Spring Boot will add @EnableWebSecurity so adding entries to the application.properties ain't gonna work.
Here is how you can disable by configuring security config...
@Configuration
@EnableWebSecurity
public class SecurityConfig extends WebSecurityConfigurerAdapter {
@Override
protected void configure(HttpSecurity http) throws Exception {
http
.authorizeRequests()
.antMatchers("/**").permitAll();
}
}
Security changes in Spring Boot 2.0 M4
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With