public class FilterAttributes extends AbstractProfileAction
AttributeFilter for the current request.EventIds.PROCEED_EVENT_ID, IdPEventIds.UNABLE_FILTER_ATTRIBS| Modifier and Type | Field and Description |
|---|---|
private AttributeContext |
attributeContext
AttributeContext to filter.
|
private com.google.common.base.Function<ProfileRequestContext,AttributeContext> |
attributeContextLookupStrategy
Strategy used to locate the
AttributeContext to filter. |
private ReloadableService<AttributeFilter> |
attributeFilterService
Service used to get the engine used to filter attributes.
|
private AuthenticationContext |
authenticationContext
AuthenticationContext to work from (if any).
|
private com.google.common.base.Function<ProfileRequestContext,AuthenticationContext> |
authnContextLookupStrategy
Strategy used to locate the
AuthenticationContext associated with a given ProfileRequestContext. |
private com.google.common.base.Function<ProfileRequestContext,AttributeFilterContext> |
filterContextCreationStrategy
Strategy used to locate or create the
AttributeFilterContext. |
private com.google.common.base.Function<ProfileRequestContext,String> |
issuerLookupStrategy
Strategy used to locate the identity of the issuer associated with the attribute filtering.
|
private org.slf4j.Logger |
log
Class logger.
|
private boolean |
maskFailures
Whether to treat resolver errors as equivalent to resolving no attributes.
|
private com.google.common.base.Function<ProfileRequestContext,SAMLMetadataContext> |
metadataContextLookupStrategy
Strategy used to locate the
SAMLMetadataContext associated with a given ProfileRequestContext. |
private com.google.common.base.Function<AttributeFilterContext,SAMLMetadataContext> |
metadataFromFilterLookupStrategy
Strategy used to locate the
SAMLMetadataContext associated with a given AttributeFilterContext. |
private MetadataResolver |
metadataResolver
Optional supplemental metadata source.
|
private com.google.common.base.Function<ProfileRequestContext,String> |
principalNameLookupStrategy
Strategy used to locate the principal name associated with the attribute filtering.
|
private com.google.common.base.Function<ProfileRequestContext,ProxiedRequesterContext> |
proxiedRequesterContextLookupStrategy
Strategy used to locate the
ProxiedRequesterContext associated with a given
ProfileRequestContext. |
private com.google.common.base.Function<AttributeFilterContext,ProxiedRequesterContext> |
proxiesFromFilterLookupStrategy
Strategy used to locate the
ProxiedRequesterContext associated with a given
AttributeFilterContext. |
private com.google.common.base.Function<ProfileRequestContext,String> |
recipientLookupStrategy
Strategy used to locate the identity of the recipient associated with the attribute filtering.
|
| Constructor and Description |
|---|
FilterAttributes(ReloadableService<AttributeFilter> filterService)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
doExecute(ProfileRequestContext profileRequestContext) |
protected boolean |
doPreExecute(ProfileRequestContext profileRequestContext) |
private void |
populateFilterContext(ProfileRequestContext profileRequestContext,
AttributeFilterContext filterContext)
Fill in the filter context data.
|
void |
setAttributeContextLookupStrategy(com.google.common.base.Function<ProfileRequestContext,AttributeContext> strategy)
Set the strategy used to locate the
AttributeContext associated with a given
ProfileRequestContext. |
void |
setAuthenticationContextLookupStrategy(com.google.common.base.Function<ProfileRequestContext,AuthenticationContext> strategy)
Set the strategy used to locate the
AuthenticationContext associated with a given
ProfileRequestContext. |
void |
setFilterContextCreationStrategy(com.google.common.base.Function<ProfileRequestContext,AttributeFilterContext> strategy)
Set the strategy used to locate or create the
AttributeFilterContext to populate. |
void |
setIssuerLookupStrategy(com.google.common.base.Function<ProfileRequestContext,String> strategy)
Set the strategy used to lookup the issuer for this attribute filtering.
|
void |
setMaskFailures(boolean flag)
Set whether to treat resolution failure as equivalent to resolving no attributes.
|
void |
setMetadataContextLookupStrategy(com.google.common.base.Function<ProfileRequestContext,SAMLMetadataContext> strategy)
Set the strategy used to locate the
SAMLMetadataContext associated with a given
ProfileRequestContext. |
void |
setMetadataResolver(MetadataResolver resolver)
Set a metadata source to use during filtering.
|
void |
setPrincipalNameLookupStrategy(com.google.common.base.Function<ProfileRequestContext,String> strategy)
Set the strategy used to locate the principal name for this attribute filtering.
|
void |
setProxiedRequesterContextLookupStrategy(com.google.common.base.Function<ProfileRequestContext,ProxiedRequesterContext> strategy)
Set the strategy used to locate the
ProxiedRequesterContext associated with a given
ProfileRequestContext. |
void |
setRecipientLookupStrategy(com.google.common.base.Function<ProfileRequestContext,String> strategy)
Set the strategy used to lookup the recipient for this attribute filtering.
|
doExecute, execute, getMessage, getMessage, getMessage, getProfileContextLookupStrategy, getRequestContext, getResult, setMessageSource, setProfileContextLookupStrategygetActivationCondition, setActivationConditiondoPostExecute, doPostExecute, execute, getHttpServletRequest, getHttpServletResponse, getLogPrefix, setHttpServletRequest, setHttpServletResponsedestroy, doDestroy, doInitialize, initialize, isDestroyed, isInitializedclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitinitialize, isInitialized@Nonnull private final org.slf4j.Logger log
@Nonnull private final ReloadableService<AttributeFilter> attributeFilterService
@Nullable private MetadataResolver metadataResolver
@Nullable private com.google.common.base.Function<ProfileRequestContext,String> issuerLookupStrategy
@Nullable private com.google.common.base.Function<ProfileRequestContext,String> recipientLookupStrategy
@Nonnull private com.google.common.base.Function<ProfileRequestContext,AttributeFilterContext> filterContextCreationStrategy
AttributeFilterContext.@Nonnull private com.google.common.base.Function<ProfileRequestContext,AttributeContext> attributeContextLookupStrategy
AttributeContext to filter.@Nonnull private com.google.common.base.Function<ProfileRequestContext,String> principalNameLookupStrategy
@Nonnull private com.google.common.base.Function<ProfileRequestContext,AuthenticationContext> authnContextLookupStrategy
AuthenticationContext associated with a given ProfileRequestContext.@Nonnull private com.google.common.base.Function<ProfileRequestContext,SAMLMetadataContext> metadataContextLookupStrategy
SAMLMetadataContext associated with a given ProfileRequestContext.@Nonnull private com.google.common.base.Function<AttributeFilterContext,SAMLMetadataContext> metadataFromFilterLookupStrategy
SAMLMetadataContext associated with a given AttributeFilterContext.@Nonnull private com.google.common.base.Function<ProfileRequestContext,ProxiedRequesterContext> proxiedRequesterContextLookupStrategy
ProxiedRequesterContext associated with a given
ProfileRequestContext.@Nonnull private com.google.common.base.Function<AttributeFilterContext,ProxiedRequesterContext> proxiesFromFilterLookupStrategy
ProxiedRequesterContext associated with a given
AttributeFilterContext.private boolean maskFailures
@Nullable private AuthenticationContext authenticationContext
@Nullable private AttributeContext attributeContext
public FilterAttributes(@Nonnull ReloadableService<AttributeFilter> filterService)
filterService - engine used to filter attributespublic void setMetadataResolver(@Nullable MetadataResolver resolver)
resolver - metadata resolverpublic void setIssuerLookupStrategy(@Nullable com.google.common.base.Function<ProfileRequestContext,String> strategy)
strategy - lookup strategypublic void setRecipientLookupStrategy(@Nullable com.google.common.base.Function<ProfileRequestContext,String> strategy)
strategy - lookup strategypublic void setFilterContextCreationStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,AttributeFilterContext> strategy)
AttributeFilterContext to populate.strategy - lookup/creation strategypublic void setAttributeContextLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,AttributeContext> strategy)
AttributeContext associated with a given
ProfileRequestContext.strategy - strategy used to locate the AttributeContext associated with a given
ProfileRequestContextpublic void setPrincipalNameLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,String> strategy)
strategy - lookup strategypublic void setAuthenticationContextLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,AuthenticationContext> strategy)
AuthenticationContext associated with a given
ProfileRequestContext.strategy - strategy used to locate the AuthenticationContext associated with a given
ProfileRequestContextpublic void setMetadataContextLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,SAMLMetadataContext> strategy)
SAMLMetadataContext associated with a given
ProfileRequestContext. Also sets the strategy to find the SAMLMetadataContext
from the AttributeFilterContext.strategy - lookup strategypublic void setProxiedRequesterContextLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,ProxiedRequesterContext> strategy)
ProxiedRequesterContext associated with a given
ProfileRequestContext. Also sets the strategy to find the ProxiedRequesterContext
from the AttributeFilterContext.strategy - lookup strategypublic void setMaskFailures(boolean flag)
This matches the behavior of V2.
flag - flag to setprotected boolean doPreExecute(@Nonnull ProfileRequestContext profileRequestContext)
doPreExecute in class AbstractConditionalProfileActionprotected void doExecute(@Nonnull ProfileRequestContext profileRequestContext)
doExecute in class AbstractProfileActionprivate void populateFilterContext(@Nonnull ProfileRequestContext profileRequestContext, @Nonnull AttributeFilterContext filterContext)
profileRequestContext - current profile request contextfilterContext - context to populateCopyright © 1999–2018 Shibboleth Consortium. All rights reserved.