Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

PdfPublicKeyDecryptionOptions

OfficeIMO.Pdf

Namespace
OfficeIMO.Pdf
Assembly
OfficeIMO.Pdf
Source revision
ac7e6e1bad8a with working tree changes
Modifiers
sealed

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

Constructors

PdfPublicKeyDecryptionOptions 2 overloads
public PdfPublicKeyDecryptionOptions(IOfficeSecurityProvider securityProvider, IEnumerable<X509Certificate2> recipientCertificates) #

Creates public-key decryption options.

Parameters

securityProvider OfficeIMO.Security.IOfficeSecurityProvider required
Provider that decrypts CMS EnvelopedData, for example OfficeSecurityProvider from OfficeIMO.Security.
recipientCertificates System.Collections.Generic.IEnumerable<System.Security.Cryptography.X509Certificates.X509Certificate2> required
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 required
recipientCertificate System.Security.Cryptography.X509Certificates.X509Certificate2 required

Properties

public int CertificateCount { get; } #

Number of recipient certificates that will be tried.