Class FlowableTokenAuthenticationConfigurer<H extends HttpSecurityBuilder<H>>
java.lang.Object
org.springframework.security.config.annotation.SecurityConfigurerAdapter<DefaultSecurityFilterChain,B>
org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer<FlowableTokenAuthenticationConfigurer<H>,H>
com.flowable.core.spring.security.token.FlowableTokenAuthenticationConfigurer<H>
- All Implemented Interfaces:
SecurityConfigurer<DefaultSecurityFilterChain,H>
public class FlowableTokenAuthenticationConfigurer<H extends HttpSecurityBuilder<H>>
extends AbstractHttpConfigurer<FlowableTokenAuthenticationConfigurer<H>,H>
A Spring Security configurer used for configuring the Flowable Token Request Parameter authentication.
- Author:
- Filip Hrisafov
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final ApplicationContextprotected PersistentTokenServiceprotected Stringprotected final String -
Constructor Summary
ConstructorsConstructorDescriptionFlowableTokenAuthenticationConfigurer(ApplicationContext applicationContext, String tokenSigningSecret) -
Method Summary
Modifier and TypeMethodDescriptionprotected FlowableTokenAuthenticationProviderbuild()voidprotected com.nimbusds.jwt.proc.JWTProcessor<com.nimbusds.jose.proc.SecurityContext>protected PersistentTokenServicevoidpersistentTokenService(PersistentTokenService persistentTokenService) ThePersistentTokenServicethat should be used for loading and storing tokens.tokenRequestParameter(String tokenRequestParameter) The request parameter where the token will be stored.Methods inherited from class org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer
disable, getSecurityContextHolderStrategy, withObjectPostProcessorMethods inherited from class org.springframework.security.config.annotation.SecurityConfigurerAdapter
addObjectPostProcessor, and, getBuilder, postProcess, setBuilder
-
Field Details
-
applicationContext
-
tokenSigningSecret
-
persistentTokenService
-
tokenRequestParameter
-
-
Constructor Details
-
FlowableTokenAuthenticationConfigurer
public FlowableTokenAuthenticationConfigurer(ApplicationContext applicationContext, String tokenSigningSecret)
-
-
Method Details
-
init
- Specified by:
initin interfaceSecurityConfigurer<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>> - Overrides:
initin classSecurityConfigurerAdapter<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>> - Throws:
Exception
-
configure
- Specified by:
configurein interfaceSecurityConfigurer<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>> - Overrides:
configurein classSecurityConfigurerAdapter<DefaultSecurityFilterChain,H extends HttpSecurityBuilder<H>> - Throws:
Exception
-
build
-
createJWTProcessor
protected com.nimbusds.jwt.proc.JWTProcessor<com.nimbusds.jose.proc.SecurityContext> createJWTProcessor() -
getPersistentTokenService
-
persistentTokenService
public FlowableTokenAuthenticationConfigurer<H> persistentTokenService(PersistentTokenService persistentTokenService) ThePersistentTokenServicethat should be used for loading and storing tokens. If not set then the one from theApplicationContextwill be used- Parameters:
persistentTokenService- the persistent token service that should be used- Returns:
- the configurer for chaining
-
tokenRequestParameter
The request parameter where the token will be stored. Default value istoken.- Parameters:
tokenRequestParameter- the token request parameter- Returns:
- the configurer for chaining
-