redirect logout

This commit is contained in:
Michele Artini 2020-11-05 09:55:02 +01:00
parent 94637fe6dd
commit e5394b008e
1 changed files with 7 additions and 1 deletions

View File

@ -99,7 +99,13 @@ public class WebSecurityConfig extends WebSecurityConfigurerAdapter {
}
private OidcClientInitiatedLogoutSuccessHandler oidcLogoutSuccessHandler() {
return new OidcClientInitiatedLogoutSuccessHandler(clientRegistrationRepository);
final OidcClientInitiatedLogoutSuccessHandler handler = new OidcClientInitiatedLogoutSuccessHandler(clientRegistrationRepository);
// NB:
// The same URL must be configured server side:
// Manage Clients > Edit Client > Other > Post-Logout Redirect
handler.setPostLogoutRedirectUri("{baseUrl}");
return handler;
}
private OAuth2UserService<OidcUserRequest, OidcUser> oidcUserService() {