update userProfil & logout

This commit is contained in:
Parpaillax
2024-04-24 11:26:17 +02:00
parent 389b5d6b23
commit 7df76ea3ed
10 changed files with 48 additions and 40 deletions

View File

@@ -24,7 +24,7 @@ public class WebSecurityConfig{
.anyRequest().authenticated())
.formLogin((form) -> form.loginPage("/login").defaultSuccessUrl("/", true))
.logout((logout) -> logout.clearAuthentication(true).invalidateHttpSession(true)
.deleteCookies("JSESSIONID").logoutSuccessUrl("/logout")
.deleteCookies("JSESSIONID").logoutSuccessUrl("/login")
.logoutRequestMatcher(new AntPathRequestMatcher("/logout")).permitAll());
return http.build();