public abstract class AbstractEncryptAction extends AbstractConditionalProfileAction
The EncryptionContext governing the encryption process is located by a lookup
strategy, by default a child of the outbound message context.
An optional recipient name is also obtained from a lookup strategy.
| Modifier and Type | Field and Description |
|---|---|
private Encrypter |
encrypter
The encryption object.
|
private com.google.common.base.Function<ProfileRequestContext,EncryptionContext> |
encryptionCtxLookupStrategy
Strategy used to locate the
EncryptionContext. |
private com.google.common.base.Function<ProfileRequestContext,Encrypter.KeyPlacement> |
keyPlacementLookupStrategy
Strategy used to determine encrypted key placement.
|
private Logger |
log
Class logger.
|
private com.google.common.base.Function<ProfileRequestContext,String> |
recipientLookupStrategy
Strategy used to locate the encryption recipient.
|
| Constructor and Description |
|---|
AbstractEncryptAction()
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected boolean |
doPreExecute(ProfileRequestContext profileRequestContext) |
protected abstract org.opensaml.xmlsec.EncryptionParameters |
getApplicableParameters(EncryptionContext ctx)
Return the right set of parameters for the operation to be performed, or none if no encryption should occur.
|
Encrypter |
getEncrypter()
Get the encrypter.
|
void |
setEncryptionContextLookupStrategy(com.google.common.base.Function<ProfileRequestContext,EncryptionContext> strategy)
Set the strategy used to locate the
EncryptionContext associated with a given
ProfileRequestContext. |
void |
setKeyPlacementLookupStrategy(com.google.common.base.Function<ProfileRequestContext,Encrypter.KeyPlacement> strategy)
Set the strategy used to determine the encrypted key placement strategy.
|
void |
setRecipientLookupStrategy(com.google.common.base.Function<ProfileRequestContext,String> strategy)
Set the strategy used to locate the encryption recipient.
|
getActivationCondition, setActivationConditiondoExecute, doPostExecute, doPostExecute, execute, getHttpServletRequest, getHttpServletResponse, getLogPrefix, setHttpServletRequest, setHttpServletResponsedestroy, doDestroy, doInitialize, initialize, isDestroyed, isInitialized@Nonnull private com.google.common.base.Function<ProfileRequestContext,EncryptionContext> encryptionCtxLookupStrategy
EncryptionContext.@Nullable private com.google.common.base.Function<ProfileRequestContext,String> recipientLookupStrategy
@Nonnull private com.google.common.base.Function<ProfileRequestContext,Encrypter.KeyPlacement> keyPlacementLookupStrategy
public void setEncryptionContextLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,EncryptionContext> strategy)
EncryptionContext associated with a given
ProfileRequestContext.strategy - lookup strategypublic void setRecipientLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,String> strategy)
strategy - lookup strategypublic void setKeyPlacementLookupStrategy(@Nonnull com.google.common.base.Function<ProfileRequestContext,Encrypter.KeyPlacement> strategy)
strategy - lookup strategyprotected boolean doPreExecute(@Nonnull ProfileRequestContext profileRequestContext)
doPreExecute in class AbstractConditionalProfileAction@Nullable protected abstract org.opensaml.xmlsec.EncryptionParameters getApplicableParameters(@Nullable EncryptionContext ctx)
ctx - possibly null input context to pull parameters fromCopyright © 1999–2015. All rights reserved.