public abstract class AbstractRecipient
extends java.lang.Object
| Constructor and Description |
|---|
AbstractRecipient() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkContentAlgorithm(org.bouncycastle.asn1.x509.AlgorithmIdentifier contentAlgorithm)
Apply both of the recipient's restrictions to the content-encryption algorithm the message
names, resolving an RFC 9709 key-derivation wrapper to the content-encryption algorithm it
carries first, so that the restrictions are applied to the algorithm the content is actually
encrypted under.
|
protected void |
checkTagSize(org.bouncycastle.asn1.x509.AlgorithmIdentifier contentAlgorithm)
Refuse an AEAD content algorithm whose authentication tag is shorter than the configured
minimum.
|
protected boolean |
isContentAlgorithmAllowed(org.bouncycastle.asn1.ASN1ObjectIdentifier contentAlgorithm) |
protected void |
setAllowedContentAlgorithmSet(java.util.Set<org.bouncycastle.asn1.ASN1ObjectIdentifier> allowedContentAlgorithms) |
protected void |
setMinimumTagSizeInBits(int tagSizeInBits) |
protected final void setAllowedContentAlgorithmSet(java.util.Set<org.bouncycastle.asn1.ASN1ObjectIdentifier> allowedContentAlgorithms)
protected final boolean isContentAlgorithmAllowed(org.bouncycastle.asn1.ASN1ObjectIdentifier contentAlgorithm)
protected final void setMinimumTagSizeInBits(int tagSizeInBits)
protected final void checkTagSize(org.bouncycastle.asn1.x509.AlgorithmIdentifier contentAlgorithm)
throws CMSTagLengthException
contentAlgorithm - the content-encryption AlgorithmIdentifier (carries the AEAD ICV length).CMSTagLengthException - if the tag size is below the configured minimum.protected final void checkContentAlgorithm(org.bouncycastle.asn1.x509.AlgorithmIdentifier contentAlgorithm)
throws CMSException
contentAlgorithm - the content-encryption AlgorithmIdentifier taken from the message.CMSAlgorithmNotAllowedException - if the content algorithm is not in the allowed set.CMSTagLengthException - if the tag size is below the configured minimum.CMSException