Click or drag to resize
Pdf Library for .NET

PdfDocumentSecurityEncryptMetadata Property

Gets or sets whether the document's XMP metadata stream is encrypted with the rest of the document. The default value is true.

Namespace: SelectPdf.Universal
Assembly: SelectPdf.Universal (in SelectPdf.Universal.dll) Version: 26.4
Syntax
public bool EncryptMetadata { get; set; }

Property Value

Boolean
Remarks

Set it to false to leave the XMP metadata packet readable - by a search index or a document management system - while everything else stays encrypted. The document information entries (title, author, keywords) are encrypted either way, as the PDF format requires, and a document that carries no XMP packet is not affected. It takes effect when the document is encrypted, that is when a password is set.

The PDF format cannot leave metadata readable under a 40-bit RC4 key, so with EncryptKey40Bit the metadata is always encrypted.

See Also