Last active
October 10, 2018 14:01
-
-
Save artem-smotrakov/bed11936a6632092a079149392246fc8 to your computer and use it in GitHub Desktop.
Disabling built-in session management in Spring Boot config, see more in https://blog.gypsyengineer.com/en/security/tips-configuring-security-rest-api-spring.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Configuration | |
@EnableWebSecurity | |
public class SecurityConfig extends WebSecurityConfigurerAdapter { | |
@Override | |
protected void configure(HttpSecurity http) throws Exception { | |
http.sessionManagement() | |
.sessionCreationPolicy(SessionCreationPolicy.STATELESS); | |
// ... | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment