Class OIDCAttributeMapperHelper
- java.lang.Object
-
- org.keycloak.protocol.oidc.mappers.OIDCAttributeMapperHelper
-
public class OIDCAttributeMapperHelper extends Object
- Version:
- $Revision: 1 $
- Author:
- Bill Burke
-
-
Field Summary
Fields Modifier and Type Field Description static String
INCLUDE_IN_ACCESS_TOKEN
static String
INCLUDE_IN_ACCESS_TOKEN_HELP_TEXT
static String
INCLUDE_IN_ACCESS_TOKEN_LABEL
static String
INCLUDE_IN_ACCESS_TOKEN_RESPONSE
static String
INCLUDE_IN_ACCESS_TOKEN_RESPONSE_HELP_TEXT
static String
INCLUDE_IN_ACCESS_TOKEN_RESPONSE_LABEL
static String
INCLUDE_IN_ID_TOKEN
static String
INCLUDE_IN_ID_TOKEN_HELP_TEXT
static String
INCLUDE_IN_ID_TOKEN_LABEL
static String
INCLUDE_IN_USERINFO
static String
INCLUDE_IN_USERINFO_HELP_TEXT
static String
INCLUDE_IN_USERINFO_LABEL
static String
JSON_TYPE
static String
JSON_TYPE_TOOLTIP
static String
TOKEN_CLAIM_NAME
static String
TOKEN_CLAIM_NAME_LABEL
static String
TOKEN_CLAIM_NAME_TOOLTIP
-
Constructor Summary
Constructors Constructor Description OIDCAttributeMapperHelper()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
addAttributeConfig(List<ProviderConfigProperty> configProperties, Class<? extends ProtocolMapper> protocolMapperClass)
static void
addIncludeInTokensConfig(List<ProviderConfigProperty> configProperties, Class<? extends ProtocolMapper> protocolMapperClass)
static void
addJsonTypeConfig(List<ProviderConfigProperty> configProperties)
static void
addTokenClaimNameConfig(List<ProviderConfigProperty> configProperties)
static ProtocolMapperModel
createClaimMapper(String name, String userAttribute, String tokenClaimName, String claimType, boolean accessToken, boolean idToken, boolean userinfo, String mapperId)
static ProtocolMapperModel
createClaimMapper(String name, String userAttribute, String tokenClaimName, String claimType, boolean accessToken, boolean idToken, String mapperId)
static boolean
includeInAccessToken(ProtocolMapperModel mappingModel)
static boolean
includeInAccessTokenResponse(ProtocolMapperModel mappingModel)
static boolean
includeInIDToken(ProtocolMapperModel mappingModel)
static boolean
includeInUserInfo(ProtocolMapperModel mappingModel)
static boolean
isMultivalued(ProtocolMapperModel mappingModel)
static Object
mapAttributeValue(ProtocolMapperModel mappingModel, Object attributeValue)
static void
mapClaim(AccessTokenResponse token, ProtocolMapperModel mappingModel, Object attributeValue)
static void
mapClaim(IDToken token, ProtocolMapperModel mappingModel, Object attributeValue)
-
-
-
Field Detail
-
TOKEN_CLAIM_NAME
public static final String TOKEN_CLAIM_NAME
- See Also:
- Constant Field Values
-
TOKEN_CLAIM_NAME_LABEL
public static final String TOKEN_CLAIM_NAME_LABEL
- See Also:
- Constant Field Values
-
TOKEN_CLAIM_NAME_TOOLTIP
public static final String TOKEN_CLAIM_NAME_TOOLTIP
- See Also:
- Constant Field Values
-
JSON_TYPE
public static final String JSON_TYPE
- See Also:
- Constant Field Values
-
JSON_TYPE_TOOLTIP
public static final String JSON_TYPE_TOOLTIP
- See Also:
- Constant Field Values
-
INCLUDE_IN_ACCESS_TOKEN
public static final String INCLUDE_IN_ACCESS_TOKEN
- See Also:
- Constant Field Values
-
INCLUDE_IN_ACCESS_TOKEN_LABEL
public static final String INCLUDE_IN_ACCESS_TOKEN_LABEL
- See Also:
- Constant Field Values
-
INCLUDE_IN_ACCESS_TOKEN_HELP_TEXT
public static final String INCLUDE_IN_ACCESS_TOKEN_HELP_TEXT
- See Also:
- Constant Field Values
-
INCLUDE_IN_ID_TOKEN
public static final String INCLUDE_IN_ID_TOKEN
- See Also:
- Constant Field Values
-
INCLUDE_IN_ID_TOKEN_LABEL
public static final String INCLUDE_IN_ID_TOKEN_LABEL
- See Also:
- Constant Field Values
-
INCLUDE_IN_ID_TOKEN_HELP_TEXT
public static final String INCLUDE_IN_ID_TOKEN_HELP_TEXT
- See Also:
- Constant Field Values
-
INCLUDE_IN_ACCESS_TOKEN_RESPONSE
public static final String INCLUDE_IN_ACCESS_TOKEN_RESPONSE
- See Also:
- Constant Field Values
-
INCLUDE_IN_ACCESS_TOKEN_RESPONSE_LABEL
public static final String INCLUDE_IN_ACCESS_TOKEN_RESPONSE_LABEL
- See Also:
- Constant Field Values
-
INCLUDE_IN_ACCESS_TOKEN_RESPONSE_HELP_TEXT
public static final String INCLUDE_IN_ACCESS_TOKEN_RESPONSE_HELP_TEXT
- See Also:
- Constant Field Values
-
INCLUDE_IN_USERINFO
public static final String INCLUDE_IN_USERINFO
- See Also:
- Constant Field Values
-
INCLUDE_IN_USERINFO_LABEL
public static final String INCLUDE_IN_USERINFO_LABEL
- See Also:
- Constant Field Values
-
INCLUDE_IN_USERINFO_HELP_TEXT
public static final String INCLUDE_IN_USERINFO_HELP_TEXT
- See Also:
- Constant Field Values
-
-
Method Detail
-
mapAttributeValue
public static Object mapAttributeValue(ProtocolMapperModel mappingModel, Object attributeValue)
-
mapClaim
public static void mapClaim(IDToken token, ProtocolMapperModel mappingModel, Object attributeValue)
-
mapClaim
public static void mapClaim(AccessTokenResponse token, ProtocolMapperModel mappingModel, Object attributeValue)
-
createClaimMapper
public static ProtocolMapperModel createClaimMapper(String name, String userAttribute, String tokenClaimName, String claimType, boolean accessToken, boolean idToken, String mapperId)
-
createClaimMapper
public static ProtocolMapperModel createClaimMapper(String name, String userAttribute, String tokenClaimName, String claimType, boolean accessToken, boolean idToken, boolean userinfo, String mapperId)
-
includeInIDToken
public static boolean includeInIDToken(ProtocolMapperModel mappingModel)
-
includeInAccessToken
public static boolean includeInAccessToken(ProtocolMapperModel mappingModel)
-
includeInAccessTokenResponse
public static boolean includeInAccessTokenResponse(ProtocolMapperModel mappingModel)
-
isMultivalued
public static boolean isMultivalued(ProtocolMapperModel mappingModel)
-
includeInUserInfo
public static boolean includeInUserInfo(ProtocolMapperModel mappingModel)
-
addAttributeConfig
public static void addAttributeConfig(List<ProviderConfigProperty> configProperties, Class<? extends ProtocolMapper> protocolMapperClass)
-
addTokenClaimNameConfig
public static void addTokenClaimNameConfig(List<ProviderConfigProperty> configProperties)
-
addJsonTypeConfig
public static void addJsonTypeConfig(List<ProviderConfigProperty> configProperties)
-
addIncludeInTokensConfig
public static void addIncludeInTokensConfig(List<ProviderConfigProperty> configProperties, Class<? extends ProtocolMapper> protocolMapperClass)
-
-