Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

TdxPSPDFSecurityOptions.KeyLength Property

Specifies the key length used to encrypt a PDF document.

#Declaration

Delphi
property KeyLength: TdxPSPDFEncryptKeyLength read; write; default pekl128;

#Property Value

Type Default
TdxPSPDFEncryptKeyLength pekl128

#Remarks

If security is enabled via the Enabled property, a PDF document is encrypted using a key that is created based on the user and owner passwords specified via the UserPassword and OwnerPassword properties. The security level of encrypted PDF documents depends on the length of the key used for the encryption. Generally, the longer the key, the more security it provides. The standard security provided by PDF documents allows you to use either a 40-bit or 128-bit key for the encryption. To select the key length, use the KeyLength property.

Property values include:

Value Description
pekl40 A 40-bit key is used.
pekl128 A 128-bit key is used.

The default value of the KeyLength property is pekl128.

See Also