|
@@ -72,19 +72,12 @@ public class SecurityConfig {
|
|
|
.csrf((csrf) -> csrf.disable());
|
|
.csrf((csrf) -> csrf.disable());
|
|
|
|
|
|
|
|
http.sessionManagement((session) -> session
|
|
http.sessionManagement((session) -> session
|
|
|
- .sessionAuthenticationErrorUrl("/login?error=expired")
|
|
|
|
|
- .invalidSessionUrl("/login?error=expired")
|
|
|
|
|
- .maximumSessions(1)
|
|
|
|
|
|
|
+ .sessionCreationPolicy(SessionCreationPolicy.IF_REQUIRED)
|
|
|
|
|
+ .sessionFixation().migrateSession()
|
|
|
|
|
+ .maximumSessions(1)
|
|
|
.expiredUrl("/login?error=expired")
|
|
.expiredUrl("/login?error=expired")
|
|
|
- .maxSessionsPreventsLogin(false)
|
|
|
|
|
- .sessionRegistry(sessionRegistry())
|
|
|
|
|
- )
|
|
|
|
|
- .sessionManagement((session) -> session
|
|
|
|
|
- .sessionAuthenticationStrategy(concurrentSession())
|
|
|
|
|
- .sessionFixation()
|
|
|
|
|
- .newSession()
|
|
|
|
|
- .sessionCreationPolicy(SessionCreationPolicy.IF_REQUIRED)
|
|
|
|
|
- );
|
|
|
|
|
|
|
+ .sessionRegistry(sessionRegistry())
|
|
|
|
|
+ );
|
|
|
|
|
|
|
|
http.headers((headers) -> headers
|
|
http.headers((headers) -> headers
|
|
|
.frameOptions((options) -> options.sameOrigin())
|
|
.frameOptions((options) -> options.sameOrigin())
|