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
Modifier and TypeFieldDescriptionprotected final ApplicationContext
protected PersistentTokenService
protected String
protected final String
-
Constructor Summary
ConstructorDescriptionFlowableTokenAuthenticationConfigurer
(ApplicationContext applicationContext, String tokenSigningSecret) -
Method Summary
Modifier and TypeMethodDescriptionprotected FlowableTokenAuthenticationProvider
build()
void
protected com.nimbusds.jwt.proc.JWTProcessor<com.nimbusds.jose.proc.SecurityContext>
protected PersistentTokenService
void
persistentTokenService
(PersistentTokenService persistentTokenService) ThePersistentTokenService
that 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, withObjectPostProcessor
Methods 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:
init
in interfaceSecurityConfigurer<DefaultSecurityFilterChain,
H extends HttpSecurityBuilder<H>> - Overrides:
init
in classSecurityConfigurerAdapter<DefaultSecurityFilterChain,
H extends HttpSecurityBuilder<H>> - Throws:
Exception
-
configure
- Specified by:
configure
in interfaceSecurityConfigurer<DefaultSecurityFilterChain,
H extends HttpSecurityBuilder<H>> - Overrides:
configure
in 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) ThePersistentTokenService
that should be used for loading and storing tokens. If not set then the one from theApplicationContext
will 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
-