Click or drag to resize

PDFDocInitStdSecurityHandler Method (Byte)

Initializes document's SecurityHandler using the supplied password. This version of InitSecurityHandler() assumes that document uses Standard security and that a password is specified directly. This function should be called immediately after an encrypted document is opened. The function does not have any side effects on documents that are not encrypted. If the security handler was successfully initialized, it can be later obtained using GetSecurityHandler() method.

Namespace:  pdftron.PDF
Assembly:  pdftron (in pdftron.dll) Version: 255.255.255.255
Syntax
public bool InitStdSecurityHandler(
	byte[] passwordBuffer
)

Parameters

passwordBuffer
Type: SystemByte
Specifies the password used to open the document without any user feedback. If you would like to dynamically obtain the password, you need to derive a custom class from StdSecurityHandler() and use InitSecurityHandler() without any parameters. See EncTest sample for example code.

Return Value

Type: Boolean
True if the given password successfully unlocked the document, false otherwise.
See Also