Class CmsEnvelopedGenerator
- Namespace
- Org.BouncyCastle.Cms
- Assembly
- BouncyCastle.Cryptography.dll
public abstract class CmsEnvelopedGenerator
- Inheritance
-
CmsEnvelopedGenerator
- Derived
- Inherited Members
Constructors
CmsEnvelopedGenerator()
protected CmsEnvelopedGenerator()
CmsEnvelopedGenerator(SecureRandom)
Constructor allowing specific source of randomness
protected CmsEnvelopedGenerator(SecureRandom random)
Parameters
randomSecureRandomInstance of
SecureRandomto use.
Fields
Aes128Cbc
public static readonly string Aes128Cbc
Field Value
Aes128Ccm
public static readonly string Aes128Ccm
Field Value
Aes128Gcm
public static readonly string Aes128Gcm
Field Value
Aes128Wrap
public static readonly string Aes128Wrap
Field Value
Aes192Cbc
public static readonly string Aes192Cbc
Field Value
Aes192Ccm
public static readonly string Aes192Ccm
Field Value
Aes192Gcm
public static readonly string Aes192Gcm
Field Value
Aes192Wrap
public static readonly string Aes192Wrap
Field Value
Aes256Cbc
public static readonly string Aes256Cbc
Field Value
Aes256Ccm
public static readonly string Aes256Ccm
Field Value
Aes256Gcm
public static readonly string Aes256Gcm
Field Value
Aes256Wrap
public static readonly string Aes256Wrap
Field Value
Camellia128Cbc
public static readonly string Camellia128Cbc
Field Value
Camellia128Wrap
public static readonly string Camellia128Wrap
Field Value
Camellia192Cbc
public static readonly string Camellia192Cbc
Field Value
Camellia192Wrap
public static readonly string Camellia192Wrap
Field Value
Camellia256Cbc
public static readonly string Camellia256Cbc
Field Value
Camellia256Wrap
public static readonly string Camellia256Wrap
Field Value
Cast5Cbc
public const string Cast5Cbc = "1.2.840.113533.7.66.10"
Field Value
DesCbc
public static readonly string DesCbc
Field Value
DesEde3Cbc
public static readonly string DesEde3Cbc
Field Value
DesEde3Wrap
public static readonly string DesEde3Wrap
Field Value
ECCDHSha1Kdf
public static readonly string ECCDHSha1Kdf
Field Value
ECCDHSha224Kdf
public static readonly string ECCDHSha224Kdf
Field Value
ECCDHSha256Kdf
public static readonly string ECCDHSha256Kdf
Field Value
ECCDHSha384Kdf
public static readonly string ECCDHSha384Kdf
Field Value
ECCDHSha512Kdf
public static readonly string ECCDHSha512Kdf
Field Value
ECDHSha1Kdf
public static readonly string ECDHSha1Kdf
Field Value
ECDHSha224Kdf
public static readonly string ECDHSha224Kdf
Field Value
ECDHSha256Kdf
public static readonly string ECDHSha256Kdf
Field Value
ECDHSha384Kdf
public static readonly string ECDHSha384Kdf
Field Value
ECDHSha512Kdf
public static readonly string ECDHSha512Kdf
Field Value
ECMqvSha1Kdf
public static readonly string ECMqvSha1Kdf
Field Value
ECMqvSha224Kdf
public static readonly string ECMqvSha224Kdf
Field Value
ECMqvSha256Kdf
public static readonly string ECMqvSha256Kdf
Field Value
ECMqvSha384Kdf
public static readonly string ECMqvSha384Kdf
Field Value
ECMqvSha512Kdf
public static readonly string ECMqvSha512Kdf
Field Value
Gost28147CryptoProWrap
public static readonly string Gost28147CryptoProWrap
Field Value
Gost28147Wrap
public static readonly string Gost28147Wrap
Field Value
IdeaCbc
public const string IdeaCbc = "1.3.6.1.4.1.188.7.1.1.2"
Field Value
RC2Cbc
public static readonly string RC2Cbc
Field Value
SeedCbc
public static readonly string SeedCbc
Field Value
SeedWrap
public static readonly string SeedWrap
Field Value
Properties
UnprotectedAttributeGenerator
public CmsAttributeTableGenerator UnprotectedAttributeGenerator { get; set; }
Property Value
Methods
AddKekRecipient(string, KeyParameter, KekIdentifier)
public void AddKekRecipient(string keyAlgorithm, KeyParameter key, KekIdentifier kekIdentifier)
Parameters
keyAlgorithmstringkeyKeyParameterkekIdentifierKekIdentifier
AddKekRecipient(string, KeyParameter, byte[])
public void AddKekRecipient(string keyAlgorithm, KeyParameter key, byte[] keyIdentifier)
Parameters
keyAlgorithmstringkeyKeyParameterkeyIdentifierbyte[]
AddKeyAgreementRecipient(string, AsymmetricKeyParameter, AsymmetricKeyParameter, X509Certificate, string)
public void AddKeyAgreementRecipient(string agreementAlgorithm, AsymmetricKeyParameter senderPrivateKey, AsymmetricKeyParameter senderPublicKey, X509Certificate recipientCert, string cekWrapAlgorithm)
Parameters
agreementAlgorithmstringsenderPrivateKeyAsymmetricKeyParametersenderPublicKeyAsymmetricKeyParameterrecipientCertX509CertificatecekWrapAlgorithmstring
AddKeyAgreementRecipient(string, AsymmetricKeyParameter, AsymmetricKeyParameter, byte[], AsymmetricKeyParameter, string)
public void AddKeyAgreementRecipient(string agreementAlgorithm, AsymmetricKeyParameter senderPrivateKey, AsymmetricKeyParameter senderPublicKey, byte[] recipientKeyID, AsymmetricKeyParameter recipientPublicKey, string cekWrapAlgorithm)
Parameters
agreementAlgorithmstringsenderPrivateKeyAsymmetricKeyParametersenderPublicKeyAsymmetricKeyParameterrecipientKeyIDbyte[]recipientPublicKeyAsymmetricKeyParametercekWrapAlgorithmstring
AddKeyAgreementRecipients(string, AsymmetricKeyParameter, AsymmetricKeyParameter, IEnumerable<X509Certificate>, string)
public void AddKeyAgreementRecipients(string agreementAlgorithm, AsymmetricKeyParameter senderPrivateKey, AsymmetricKeyParameter senderPublicKey, IEnumerable<X509Certificate> recipientCerts, string cekWrapAlgorithm)
Parameters
agreementAlgorithmstringsenderPrivateKeyAsymmetricKeyParametersenderPublicKeyAsymmetricKeyParameterrecipientCertsIEnumerable<X509Certificate>cekWrapAlgorithmstring
AddKeyTransRecipient(AsymmetricKeyParameter, byte[])
public void AddKeyTransRecipient(AsymmetricKeyParameter pubKey, byte[] subKeyId)
Parameters
pubKeyAsymmetricKeyParametersubKeyIdbyte[]
AddKeyTransRecipient(X509Certificate)
public void AddKeyTransRecipient(X509Certificate cert)
Parameters
certX509Certificate
AddKeyTransRecipient(string, AsymmetricKeyParameter, byte[])
public void AddKeyTransRecipient(string algorithm, AsymmetricKeyParameter pubKey, byte[] subKeyId)
Parameters
algorithmstringpubKeyAsymmetricKeyParametersubKeyIdbyte[]
AddKeyTransRecipient(string, X509Certificate)
public void AddKeyTransRecipient(string algorithm, X509Certificate cert)
Parameters
algorithmstringcertX509Certificate
AddPasswordRecipient(CmsPbeKey, string)
public void AddPasswordRecipient(CmsPbeKey pbeKey, string kekAlgorithmOid)
Parameters
AddRecipientInfoGenerator(RecipientInfoGenerator)
Add a generator to produce the recipient info required.
public void AddRecipientInfoGenerator(RecipientInfoGenerator recipientInfoGenerator)
Parameters
recipientInfoGeneratorRecipientInfoGeneratora generator of a recipient info object.
GenerateAsn1Parameters(string, byte[])
protected virtual Asn1Encodable GenerateAsn1Parameters(string encryptionOid, byte[] encKeyBytes)
Parameters
Returns
GetAlgorithmIdentifier(string, KeyParameter, Asn1Encodable, out ICipherParameters)
protected virtual AlgorithmIdentifier GetAlgorithmIdentifier(string encryptionOid, KeyParameter encKey, Asn1Encodable asn1Params, out ICipherParameters cipherParameters)
Parameters
encryptionOidstringencKeyKeyParameterasn1ParamsAsn1EncodablecipherParametersICipherParameters