public class SwitchUserConfigurer<H extends HttpSecurityBuilder<H>> extends AbstractHttpConfigurer<SwitchUserConfigurer<H>,H>
| Modifier and Type | Class and Description |
|---|---|
protected class |
SwitchUserConfigurer.FilterSecurityInterceptorPostProcessor |
| Modifier and Type | Field and Description |
|---|---|
protected String |
cookieDomain |
protected Duration |
cookieMaxAge |
protected String |
cookieName |
protected String |
exitUserUrl |
protected ObjectPostProcessor<FilterSecurityInterceptor> |
filterSecurityInterceptorObjectPostProcessor |
protected Collection<ImpersonatePermissionVoter> |
impersonatePermissionVoters |
protected String |
key |
protected FlowableSwitchUserHandler |
switchUserHandler |
protected String |
switchUserUrl |
protected UserDetailsService |
userDetailsService |
| Constructor and Description |
|---|
SwitchUserConfigurer() |
| Modifier and Type | Method and Description |
|---|---|
void |
configure(H builder) |
SwitchUserConfigurer<H> |
cookieDomain(String cookieDomain)
The domain of the run as user cookie.
|
SwitchUserConfigurer<H> |
cookieMaxAge(Duration cookieMaxAge)
The max age for the run as user cookie.
|
SwitchUserConfigurer<H> |
cookieName(String cookieName)
The name of the run as user cookie.
|
SwitchUserConfigurer<H> |
exitUserUrl(String exitUserUrl)
The URL to respond to exit the user switching.
|
protected UserDetailsService |
getUserDetailsService(ApplicationContext applicationContext) |
SwitchUserConfigurer<H> |
impersonatePermissionVoter(ImpersonatePermissionVoter impersonatePermissionVoter)
Add an
ImpersonatePermissionVoter. |
void |
init(H builder) |
SwitchUserConfigurer<H> |
key(String key)
The key for the run as user token.
|
SwitchUserConfigurer<H> |
switchUserUrl(String switchUserUrl)
The URL to respond to switch the user processing.
|
disable, withObjectPostProcessoraddObjectPostProcessor, and, getBuilder, postProcess, setBuilderprotected String key
protected String cookieName
protected Duration cookieMaxAge
protected String cookieDomain
protected String exitUserUrl
protected String switchUserUrl
protected FlowableSwitchUserHandler switchUserHandler
protected UserDetailsService userDetailsService
protected Collection<ImpersonatePermissionVoter> impersonatePermissionVoters
protected ObjectPostProcessor<FilterSecurityInterceptor> filterSecurityInterceptorObjectPostProcessor
public SwitchUserConfigurer<H> key(String key)
key - the key for the tokenSwitchUserConfigurer for further customizationpublic SwitchUserConfigurer<H> cookieName(String cookieName)
cookieName - the name of the cookieSwitchUserConfigurer for further customizationpublic SwitchUserConfigurer<H> cookieMaxAge(Duration cookieMaxAge)
cookieMaxAge - the max age of the cookieSwitchUserConfigurer for further customizationpublic SwitchUserConfigurer<H> cookieDomain(String cookieDomain)
cookieDomain - the domain of the cookieSwitchUserConfigurer for further customizationpublic SwitchUserConfigurer<H> switchUserUrl(String switchUserUrl)
switchUserUrl - the switch user URLSwitchUserConfigurer for further customizationpublic SwitchUserConfigurer<H> exitUserUrl(String exitUserUrl)
exitUserUrl - the switch user URLSwitchUserConfigurer for further customizationpublic SwitchUserConfigurer<H> impersonatePermissionVoter(ImpersonatePermissionVoter impersonatePermissionVoter)
ImpersonatePermissionVoter.impersonatePermissionVoter - the impersonate permission voter to be added to the configurer.SwitchUserConfigurer for further customizationpublic void init(H builder)
init in interface SecurityConfigurer<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>>init in class SecurityConfigurerAdapter<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>>public void configure(H builder) throws Exception
configure in interface SecurityConfigurer<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>>configure in class SecurityConfigurerAdapter<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>>Exceptionprotected UserDetailsService getUserDetailsService(ApplicationContext applicationContext)