Class
PdfPublicKeyDecryptionOptions
OfficeIMO.Pdf
Opens PDFs encrypted with the public-key security handler (/Filter /Adobe.PubSec). The security provider decrypts the recipient's CMS EnvelopedData; OfficeIMO.Pdf derives the file key from it.
Inheritance
- object
- PdfPublicKeyDecryptionOptions
Remarks
The provider and certificates are deliberately not exposed as public properties, so serializers that snapshot PdfLoadOptions (for example batch checkpoints) never copy certificate or key material.
Usage
Explore 1 API references to this type
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by 1
- Property PdfLoadOptions.PublicKeyDecryption
Constructors
PdfPublicKeyDecryptionOptions 2 overloads
public PdfPublicKeyDecryptionOptions(IOfficeSecurityProvider securityProvider, IEnumerable<X509Certificate2> recipientCertificates) #Creates public-key decryption options.
Parameters
- securityProvider OfficeIMO.Security.IOfficeSecurityProvider
- Provider that decrypts CMS EnvelopedData, for example OfficeSecurityProvider from OfficeIMO.Security.
- recipientCertificates System.Collections.Generic.IEnumerable<System.Security.Cryptography.X509Certificates.X509Certificate2>
- Certificates with their private keys. Each is tried against every recipient entry in the file.
public PdfPublicKeyDecryptionOptions(IOfficeSecurityProvider securityProvider, X509Certificate2 recipientCertificate) #Creates public-key decryption options for one recipient certificate.
Parameters
- securityProvider OfficeIMO.Security.IOfficeSecurityProvider
- recipientCertificate System.Security.Cryptography.X509Certificates.X509Certificate2
Inherited Methods
Properties
public int CertificateCount { get; } #Number of recipient certificates that will be tried.