Some test text!

Secure a document with encryption

To secure a document with password protection and adjusting permissions on the document.

PDFDoc doc = new PDFDoc(input_path + "fish.pdf");

// Apply a new security handler with given security settings.
// In order to open saved PDF you will need a user password 'test'.
StdSecurityHandler new_handler = new StdSecurityHandler();

// Set a new password required to open a document
string my_password = "test";                

// Set Permissions
new_handler.SetPermission (SecurityHandler.Permission.e_print, true);
new_handler.SetPermission (SecurityHandler.Permission.e_extract_content, false);

// Note: document takes the ownership of new_handler.

Encrypt and Decrypt PDF Files
Full sample code which illustrates some of our encryption support.

Get the answers you need: Support