Class JsonPathJwtConverter
- java.lang.Object
-
- org.bremersee.security.authentication.JsonPathJwtConverter
-
- All Implemented Interfaces:
org.springframework.core.convert.converter.Converter<org.springframework.security.oauth2.jwt.Jwt,org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationToken>
public class JsonPathJwtConverter extends Object implements org.springframework.core.convert.converter.Converter<org.springframework.security.oauth2.jwt.Jwt,org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationToken>
The json path jwt converter.- Author:
- Christian Bremer
-
-
Constructor Summary
Constructors Constructor Description JsonPathJwtConverter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationTokenconvert(org.springframework.security.oauth2.jwt.Jwt source)voidsetNameJsonPath(String nameJsonPath)Sets name json path.voidsetRolePrefix(String rolePrefix)Sets role prefix.voidsetRolesJsonPath(String rolesJsonPath)Sets roles json path.voidsetRolesValueList(boolean rolesValueList)Sets roles value list.voidsetRolesValueSeparator(String rolesValueSeparator)Sets roles value separator.
-
-
-
Method Detail
-
setRolesJsonPath
public void setRolesJsonPath(String rolesJsonPath)
Sets roles json path.- Parameters:
rolesJsonPath- the roles json path
-
setRolesValueList
public void setRolesValueList(boolean rolesValueList)
Sets roles value list.- Parameters:
rolesValueList- the roles value list
-
setRolesValueSeparator
public void setRolesValueSeparator(String rolesValueSeparator)
Sets roles value separator.- Parameters:
rolesValueSeparator- the roles value separator
-
setRolePrefix
public void setRolePrefix(String rolePrefix)
Sets role prefix.- Parameters:
rolePrefix- the role prefix
-
setNameJsonPath
public void setNameJsonPath(String nameJsonPath)
Sets name json path.- Parameters:
nameJsonPath- the name json path
-
convert
@NonNull public org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationToken convert(@NonNull org.springframework.security.oauth2.jwt.Jwt source)- Specified by:
convertin interfaceorg.springframework.core.convert.converter.Converter<org.springframework.security.oauth2.jwt.Jwt,org.springframework.security.oauth2.server.resource.authentication.JwtAuthenticationToken>
-
-