禁用表单登陆

pull/135/head
Your Name 2019-09-30 08:57:11 +08:00
parent 8a8eb9d0a6
commit 1c19f5a614
1 changed files with 2 additions and 1 deletions

View File

@ -112,7 +112,8 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
// 授权异常
.exceptionHandling().authenticationEntryPoint(unauthorizedHandler).and()
// 禁用表单登陆
.formLogin().disable()
// 不创建会话
.sessionManagement().sessionCreationPolicy(SessionCreationPolicy.STATELESS).and()