Class VerifyChannelBindings
- java.lang.Object
-
- net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
-
- org.opensaml.profile.action.AbstractProfileAction
-
- org.opensaml.saml.common.profile.impl.VerifyChannelBindings
-
- All Implemented Interfaces:
Component,DestructableComponent,InitializableComponent,ProfileAction
public class VerifyChannelBindings extends AbstractProfileAction
Action that verifies two sets ofChannelBindingsfrom two differentChannelBindingsContextobjects obtained via lookup functions, by default from below the inbound message context and from below aSOAP11Contextbelow the inbound message context.If neither function supplies a non-empty
ChannelBindingsContext, then there is no verification required, but if either one supplies a non-empty context, then a match must be achieved or an error event is signaled.If verification is successful, then the resulting match is stored in a new
ChannelBindingsContextobject created from a lookup/creation function, by default below the outbound message context.- Event:
EventIds.PROCEED_EVENT_ID,SAMLEventIds.CHANNEL_BINDINGS_ERROR- Precondition:
ChannelBindingsContextobjects to be returned from lookup functions must be populated.- Postcondition:
- Upon successful verification, a
ChannelBindingsContextobject will be created as described.
-
-
Field Summary
Fields Modifier and Type Field Description private ChannelBindingsContextchannelBindingsContext1The first set of bindings.private ChannelBindingsContextchannelBindingsContext2The second set of bindings.private Function<ProfileRequestContext,ChannelBindingsContext>channelBindingsCreationStrategyStrategy used to locate or create the context to save the verified result in.private Function<ProfileRequestContext,ChannelBindingsContext>channelBindingsLookupStrategy1Strategy used to locate the first set of bindings to operate on.private Function<ProfileRequestContext,ChannelBindingsContext>channelBindingsLookupStrategy2Strategy used to locate the second set of bindings to operate on.private org.slf4j.LoggerlogClass logger.
-
Constructor Summary
Constructors Constructor Description VerifyChannelBindings()Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoExecute(ProfileRequestContext profileRequestContext)protected booleandoPreExecute(ProfileRequestContext profileRequestContext)voidsetChannelBindingsCreationStrategy(Function<ProfileRequestContext,ChannelBindingsContext> strategy)Set the strategy used to create or locate theChannelBindingsContextto save verified results in.voidsetChannelBindingsLookupStrategy1(Function<ProfileRequestContext,ChannelBindingsContext> strategy)Set the strategy used to locate the firstChannelBindingsContextto operate on.voidsetChannelBindingsLookupStrategy2(Function<ProfileRequestContext,ChannelBindingsContext> strategy)Set the strategy used to locate the secondChannelBindingsContextto operate on.-
Methods inherited from class org.opensaml.profile.action.AbstractProfileAction
doPostExecute, doPostExecute, execute, getHttpServletRequest, getHttpServletRequestSupplier, getHttpServletResponse, getHttpServletResponseSupplier, getLogPrefix, setHttpServletRequest, setHttpServletRequestSupplier, setHttpServletResponse, setHttpServletResponseSupplier
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, doDestroy, doInitialize, 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.InitializableComponent
initialize, isInitialized
-
-
-
-
Field Detail
-
log
@Nonnull private final org.slf4j.Logger log
Class logger.
-
channelBindingsLookupStrategy1
@Nonnull private Function<ProfileRequestContext,ChannelBindingsContext> channelBindingsLookupStrategy1
Strategy used to locate the first set of bindings to operate on.
-
channelBindingsLookupStrategy2
@Nonnull private Function<ProfileRequestContext,ChannelBindingsContext> channelBindingsLookupStrategy2
Strategy used to locate the second set of bindings to operate on.
-
channelBindingsCreationStrategy
@Nonnull private Function<ProfileRequestContext,ChannelBindingsContext> channelBindingsCreationStrategy
Strategy used to locate or create the context to save the verified result in.
-
channelBindingsContext1
@Nullable private ChannelBindingsContext channelBindingsContext1
The first set of bindings.
-
channelBindingsContext2
@Nullable private ChannelBindingsContext channelBindingsContext2
The second set of bindings.
-
-
Method Detail
-
setChannelBindingsLookupStrategy1
public void setChannelBindingsLookupStrategy1(@Nonnull Function<ProfileRequestContext,ChannelBindingsContext> strategy)Set the strategy used to locate the firstChannelBindingsContextto operate on.- Parameters:
strategy- lookup strategy
-
setChannelBindingsLookupStrategy2
public void setChannelBindingsLookupStrategy2(@Nonnull Function<ProfileRequestContext,ChannelBindingsContext> strategy)Set the strategy used to locate the secondChannelBindingsContextto operate on.- Parameters:
strategy- lookup strategy
-
setChannelBindingsCreationStrategy
public void setChannelBindingsCreationStrategy(@Nonnull Function<ProfileRequestContext,ChannelBindingsContext> strategy)Set the strategy used to create or locate theChannelBindingsContextto save verified results in.- Parameters:
strategy- lookup/creation strategy
-
doPreExecute
protected boolean doPreExecute(@Nonnull ProfileRequestContext profileRequestContext)- Overrides:
doPreExecutein classAbstractProfileAction
-
doExecute
protected void doExecute(@Nonnull ProfileRequestContext profileRequestContext)- Overrides:
doExecutein classAbstractProfileAction
-
-