Class AbstractOID4VPClaimMapper
java.lang.Object
org.keycloak.broker.provider.AbstractIdentityProviderMapper
org.keycloak.broker.oid4vp.mappers.AbstractOID4VPClaimMapper
- All Implemented Interfaces:
DcqlQueryContributor,IdentityProviderMapper,ConfiguredProvider,EnvironmentDependentProviderFactory,Provider,ProviderFactory<IdentityProviderMapper>
- Direct Known Subclasses:
OID4VPSdJwtUserAttributeMapper,OID4VPSdJwtUserSessionAttributeMapper
public abstract class AbstractOID4VPClaimMapper
extends AbstractIdentityProviderMapper
implements EnvironmentDependentProviderFactory, DcqlQueryContributor
Base for OID4VP identity provider mappers that read a claim of one of the verified credential
presentations, addressed by the credential id and a
ClaimPath over its claims JSON.
Subclasses decide where the resolved values go. Not tied to a credential format: any format whose
verification yields claims JSON under OID4VPIdentityProvider.CREDENTIAL_CLAIMS can build on it.-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringprotected static final org.jboss.logging.LoggerFields inherited from interface org.keycloak.broker.provider.IdentityProviderMapper
ANY_PROVIDER, DEFAULT_IDENTITY_PROVIDER_MAPPER_SYNC_MODES -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Stringattribute(IdentityProviderMapperModel mapperModel) The name of the attribute the claim is stored in, null if none is configured.protected ClaimPathclaimPath(IdentityProviderMapperModel mapperModel) protected static ProviderConfigPropertyclaimValues(IdentityProviderMapperModel mapperModel, com.fasterxml.jackson.databind.JsonNode credentialClaims) protected com.fasterxml.jackson.databind.JsonNodecredentialClaims(IdentityProviderMapperModel mapperModel, BrokeredIdentityContext context) The claims of the credential this mapper reads, null if that credential was not presented.credentialId(IdentityProviderMapperModel mapperModel) The id of the requested credential this mapper reads, null if none is configured.protected static ProviderConfigPropertyString[]booleanisSupported(Config.Scope config) Check if the provider is supported and should be available based on the provider configuration.requestedClaims(IdentityProviderMapperModel mapperModel) The claims this mapper reads, empty if it is misconfigured.booleansupportsSyncMode(IdentityProviderSyncMode syncMode) protected Stringvalue(com.fasterxml.jackson.databind.JsonNode node) Methods inherited from class org.keycloak.broker.provider.AbstractIdentityProviderMapper
close, create, dependsOn, importNewUser, init, isAdminGroupJoinAllowed, isAdminRoleGrantAllowed, postInit, preprocessFederatedIdentity, updateBrokeredUser, updateBrokeredUserLegacyMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.keycloak.provider.ConfiguredProvider
getConfig, getConfigProperties, getHelpTextMethods inherited from interface org.keycloak.broker.provider.IdentityProviderMapper
getDisplayCategory, getDisplayTypeMethods inherited from interface org.keycloak.provider.ProviderFactory
getConfigMetadata, getId, order
-
Field Details
-
logger
protected static final org.jboss.logging.Logger logger -
CREDENTIAL
- See Also:
-
CREDENTIAL_LIST_TYPE
- See Also:
-
CLAIM
- See Also:
-
-
Constructor Details
-
AbstractOID4VPClaimMapper
public AbstractOID4VPClaimMapper()
-
-
Method Details
-
credentialProperty
-
claimProperty
-
credentialId
Description copied from interface:DcqlQueryContributorThe id of the requested credential this mapper reads, null if none is configured.- Specified by:
credentialIdin interfaceDcqlQueryContributor
-
claimPath
-
attribute
The name of the attribute the claim is stored in, null if none is configured. -
requestedClaims
Description copied from interface:DcqlQueryContributorThe claims this mapper reads, empty if it is misconfigured.- Specified by:
requestedClaimsin interfaceDcqlQueryContributor
-
getCompatibleProviders
- Specified by:
getCompatibleProvidersin interfaceIdentityProviderMapper
-
supportsSyncMode
- Specified by:
supportsSyncModein interfaceIdentityProviderMapper
-
isSupported
Description copied from interface:EnvironmentDependentProviderFactoryCheck if the provider is supported and should be available based on the provider configuration.- Specified by:
isSupportedin interfaceEnvironmentDependentProviderFactory- Parameters:
config- the provider configuration- Returns:
trueif the provider is supported. Otherwise,false.
-
credentialClaims
protected com.fasterxml.jackson.databind.JsonNode credentialClaims(IdentityProviderMapperModel mapperModel, BrokeredIdentityContext context) The claims of the credential this mapper reads, null if that credential was not presented. -
claimValues
protected List<String> claimValues(IdentityProviderMapperModel mapperModel, com.fasterxml.jackson.databind.JsonNode credentialClaims) -
value
-