Class PdfStandardSecurityHandler
Represents the standard PDF security handler.
public sealed class PdfStandardSecurityHandler : PdfSecurityHandler
- Inheritance
-
objectPdfStandardSecurityHandler
- Inherited Members
- Extension Methods
Properties
- DoNotResetEncryption
Indicates that the encryption of an opened document shall not be changed.
- OwnerPassword
Sets the owner password of the document.
- UserPassword
Sets the user password of the document.
Methods
- AddCryptFilter(string, PdfCryptFilter, bool)
Adds a crypt filter to the document.
- CreateCryptFilter()
Creates a crypt filter belonging to standard security handler.
- DecryptObject(PdfObject)
Decrypts an indirect PdfObject.
- EncryptEmbeddedFileStreamsOnly()
Encrypts embedded file streams only by setting a crypt filter only in the security handler’s EFF key and setting the crypt filter’s AuthEvent Key to /EFOpen, in order authenticate embedded file streams when accessing the embedded file.
- GetCryptFilter(PdfDictionary)
Gets the crypt filter that shall be used to decrypt or encrypt the dictionary.
- GetOrAddStandardCryptFilter(bool)
Returns the StdCF as it shall be used in encryption version 4 and 5. If not yet existing, it is created regarding the asDefaultIfNew parameter, which will set StdCF as default for streams, strings, and embedded file streams.
- RemoveCryptFilters()
Removes all crypt filters from the document.
- ResetCryptFilter(PdfDictionary)
Resets the explicitly set crypt filter of a dictionary.
- SetCryptFilter(PdfDictionary, string)
Sets the dictionary’s explicitly set crypt filter to the desired crypt filter.
- SetCryptFilterAsDefault(string?)
Sets the given crypt filter as default for streams, strings, and embedded streams. The crypt filter must be manually added crypt filter, "Identity" or null to remove the StmF, StrF and EFF key.
- SetCryptFilterAsDefaultForEmbeddedFileStreams(string?)
Sets the given crypt filter as default for embedded file streams. The crypt filter must be manually added crypt filter, "Identity" or null to remove the EFF key.
- SetCryptFilterAsDefaultForStreams(string?)
Sets the given crypt filter as default for streams. The crypt filter must be manually added crypt filter, "Identity" or null to remove the StmF key.
- SetCryptFilterAsDefaultForStrings(string?)
Sets the given crypt filter as default for strings. The crypt filter must be manually added crypt filter, "Identity" or null to remove the StrF key.
- SetEncryption(PdfDefaultEncryption)
Set the encryption according to the given PdfDefaultEncryption. Allows setting the encryption automized using one single parameter.
- SetEncryption(DefaultEncryption)
Set the encryption according to the given DefaultEncryption. Allows setting the encryption automized using one single parameter.
- SetEncryptionToNoneAndResetPasswords()
Do not encrypt the PDF file. Resets the user and owner password.
- SetEncryptionToV1()
Encrypt with Version 1 (RC4 and a file encryption key length of 40 bits).
- SetEncryptionToV2(int)
Encrypt with Version 2 (RC4 and a file encryption key length of more than 40 bits, PDF 1.4).
- SetEncryptionToV2With128Bits()
Encrypt with Version 2 (RC4 and a file encryption key length of more than 40 bits, PDF 1.4) with a file encryption key length of 128 bits. This was the default encryption in PDFsharp 1.5.
- SetEncryptionToV4UsingAES(bool)
Encrypt with Version 4 (RC4 or AES and a file encryption key length of 128 bits using a crypt filter, PDF 1.5) using AES (PDF 1.6).
- SetEncryptionToV4UsingRC4(bool)
Encrypt with Version 4 (RC4 or AES and a file encryption key length of 128 bits using a crypt filter, PDF 1.5) using RC4.
- SetEncryptionToV5(bool)
Encrypt with Version 5 (AES and a file encryption key length of 256 bits using a crypt filter, PDF 2.0).
- SetIdentityCryptFilter(PdfDictionary)
Sets the dictionary’s explicitly set crypt filter to the Identity crypt filter.