Class AttributeInOIDCRequestedClaimsMatcher
- java.lang.Object
-
- net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
-
- net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
-
- net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
-
- net.shibboleth.idp.plugin.oidc.op.attribute.filter.matcher.impl.AttributeInOIDCRequestedClaimsMatcher
-
- All Implemented Interfaces:
net.shibboleth.idp.attribute.filter.Matcher,Component,DestructableComponent,IdentifiableComponent,IdentifiedComponent,InitializableComponent
public class AttributeInOIDCRequestedClaimsMatcher extends AbstractIdentifiableInitializableComponent implements net.shibboleth.idp.attribute.filter.Matcher
Class for matching attribute to requested claims.
-
-
Field Summary
Fields Modifier and Type Field Description private org.slf4j.LoggerlogClass logger.private StringlogPrefixThe String used to prefix log message.private booleanmatchIfRequestedClaimsSilentWhether to return a match if the request contains no requested claims.private booleanmatchOnlyIDTokenWhether to look for a match only in id token part.private booleanmatchOnlyUserInfoWhether to look for a match only in user info part.private booleanonlyIfEssentialWhether to drop non essential claims.
-
Constructor Summary
Constructors Constructor Description AttributeInOIDCRequestedClaimsMatcher()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected StringgetLogPrefix()Return a string which is to be prepended to all log messages.Set<net.shibboleth.idp.attribute.IdPAttributeValue>getMatchingValues(net.shibboleth.idp.attribute.IdPAttribute attribute, net.shibboleth.idp.attribute.filter.context.AttributeFilterContext filtercontext)booleangetMatchIRequestedClaimsSilent()Gets whether to matched if the request contains no requested claims.booleangetMatchOnlyIDToken()Gets whether to match only id token part of the requested claims.booleangetMatchOnlyUserInfo()Gets whether to match only user info part of the requested claims.booleangetOnlyIfEssential()Gets whether to drop non essential claims.voidsetMatchIfRequestedClaimsSilent(boolean flag)Sets whether to match if the request contains no requested claims.voidsetMatchOnlyIDToken(boolean flag)Sets whether to match only id token part of the requested claims.voidsetMatchOnlyUserInfo(boolean flag)Sets whether to match only user info part of the requested claims.voidsetOnlyIfEssential(boolean flag)Sets whether to drop non essential claims.private booleanverifyEssentiality(Collection<net.shibboleth.idp.attribute.IdPAttribute> claims)Checks whether any of the matching requested claims have the required flag set if necessary.-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
setId
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
doInitialize, getId
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, doDestroy, initialize, isDestroyed, isInitialized
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.shibboleth.utilities.java.support.component.IdentifiedComponent
getId
-
-
-
-
Field Detail
-
log
@Nonnull private final org.slf4j.Logger log
Class logger.
-
matchIfRequestedClaimsSilent
private boolean matchIfRequestedClaimsSilent
Whether to return a match if the request contains no requested claims.
-
matchOnlyIDToken
private boolean matchOnlyIDToken
Whether to look for a match only in id token part.
-
matchOnlyUserInfo
private boolean matchOnlyUserInfo
Whether to look for a match only in user info part.
-
onlyIfEssential
private boolean onlyIfEssential
Whether to drop non essential claims.
-
logPrefix
private String logPrefix
The String used to prefix log message.
-
-
Method Detail
-
getOnlyIfEssential
public boolean getOnlyIfEssential()
Gets whether to drop non essential claims.- Returns:
- whether to drop non essential claims
-
setOnlyIfEssential
public void setOnlyIfEssential(boolean flag)
Sets whether to drop non essential claims.- Parameters:
flag- whether to drop non essential claims
-
getMatchOnlyIDToken
public boolean getMatchOnlyIDToken()
Gets whether to match only id token part of the requested claims.- Returns:
- whether to match only id token part of the requested claims
-
setMatchOnlyIDToken
public void setMatchOnlyIDToken(boolean flag)
Sets whether to match only id token part of the requested claims.- Parameters:
flag- whether to match only id token part of the requested claims
-
getMatchOnlyUserInfo
public boolean getMatchOnlyUserInfo()
Gets whether to match only user info part of the requested claims.- Returns:
- whether to match only user info part of the requested claims
-
setMatchOnlyUserInfo
public void setMatchOnlyUserInfo(boolean flag)
Sets whether to match only user info part of the requested claims.- Parameters:
flag- whether to match only user info part of the requested claims
-
getMatchIRequestedClaimsSilent
public boolean getMatchIRequestedClaimsSilent()
Gets whether to matched if the request contains no requested claims.- Returns:
- whether to match if the request contains no requested claims
-
setMatchIfRequestedClaimsSilent
public void setMatchIfRequestedClaimsSilent(boolean flag)
Sets whether to match if the request contains no requested claims.- Parameters:
flag- whether to match if the request contains no requested claims
-
getMatchingValues
public Set<net.shibboleth.idp.attribute.IdPAttributeValue> getMatchingValues(@Nonnull net.shibboleth.idp.attribute.IdPAttribute attribute, @Nonnull net.shibboleth.idp.attribute.filter.context.AttributeFilterContext filtercontext)
- Specified by:
getMatchingValuesin interfacenet.shibboleth.idp.attribute.filter.Matcher
-
verifyEssentiality
private boolean verifyEssentiality(Collection<net.shibboleth.idp.attribute.IdPAttribute> claims)
Checks whether any of the matching requested claims have the required flag set if necessary.- Parameters:
claims- claims request claims- Returns:
- whether any of the matching requested claims have the required flag set if necessary
-
getLogPrefix
@Nonnull protected String getLogPrefix()
Return a string which is to be prepended to all log messages.- Returns:
- "Attribute Filter '<filterID>' :"
-
-