EnvelopedData Class
Namespace: Rebex.Security.Cryptography.Pkcs
Assembly: Rebex.Common.dll (version 7.0.9083)
Represents a CMS/PKCS #7 encrypted data.
Syntax
public class EnvelopedData : PkcsBase
Inherited Members
Constructors
Name | Description |
---|---|
EnvelopedData() | Creates an instance of EnvelopedData class. It must be initialized using Load(Stream) or Decode(Byte[]) methods before any other methods and properties can be accessed. |
EnvelopedData(ContentInfo) | Creates an instance of SignedData class using the specified content information as the inner content. |
EnvelopedData(ContentInfo, ObjectIdentifier) | Creates an instance of EnvelopedData class using the specified content information and encryption algorithm. |
EnvelopedData(ContentInfo, ObjectIdentifier, Int32) | Creates an instance of EnvelopedData class using the specified content information and encryption algorithm. |
Properties
Name | Description |
---|---|
CertificateFinder | Gets or sets the ICertificateFinder to be used to find certificates corresponding to a SubjectIdentifier. |
CertificateRevocationLists | Gets the collection of certificate revocation lists (CRLs) that are embedded in the message. |
Certificates | Gets the collection of certificates that are embedded in the message. |
ContentEncryptionAlgorithm | Gets the identifier of the algorithm used to encrypt the content. |
ContentInfo | Gets the inner content information for this CMS/PKCS #7 message. It contains the content type identifier and content data. |
HasPrivateKey | Returns a value indicating whether the private key to decrypt the symmetric key and encrypted content is available. |
IsEncrypted | Gets a value indicating whether the content is encrypted. |
RecipientInfos | Gets the collection of recipients associated with this CMS/PKCS #7 message. |
Silent | Gets or sets a value indicating whether cryptographic providers are allowed to display any user interface (UI) when working with private keys. |
UnprotectedAttributes | Gets the collection of unprotected (unencrypted) attributes associated with this CMS/PKCS #7 message. |
UseDer | Gets or sets a value indicating whether to use DER encoding rules when encoding SignedData. |
Methods
Name | Description |
---|---|
AcquirePrivateKey() | Tries acquiring a private key unless it is already available. |
Clone() | Creates a copy of this object. |
Decode(Byte[]) | Decodes an encoded CMS/PKCS #7 encrypted message from raw data. Upon successful decoding, information can be retrieved using EnvelopedData methods and properties. |
Decrypt() | Decrypts the contents of the CMS/PKCS #7 message. |
Encode() | Encodes the EnvelopedData object into CMS/PKCS #7 message data. |
Encrypt() | Encrypts the contents of the CMS/PKCS #7 message. |
GetSymmetricAlgorithm() | Gets the symmetric algorithm used to encrypt or decrypt the content, or null if it cannot be retrieved. |
GetSymmetricKey() | Gets the symmetric key used to encrypt the message, or null if it cannot be retrieved. |
IsEnvelopedData(Byte[], Int32, Int32) | Determines whether the specified content info ASN.1 sequence is an enveloped data sequence. |
Load(Stream) | Loads a CMS/PKCS #7 encrypted message from a stream. Upon successful decoding, information can be retrieved using EnvelopedData methods and properties. |
LoadSignedOrEnvelopedData(Stream, ICertificateFinder, Boolean) | Loads a CMS/PKCS #7 signed or enveloped message from a stream. Returns an instance of SignedData for signed message, EnvelopedData for enveloped message, or null for methods and properties. Inherited from PkcsBase. |
Save(Stream) | Saves EnvelopedData into a stream. |