Is is possible to read from / view encrypted PDF files using the Objective-C version of the PDFNet SDK? I’m already accomplishing this via the Java SDK by doing the following…
`
// My PDF viewer
PDFViewCtrl viewer;
// Stream to the encrypted document’s file data
FileInputStream streamIn;
// Cipher used to decrypt document data
Cipher decryptCipher;
// Define a cipher stream that will be able to decrypt
// all document data for the PDF viewer
CipherInputStream decryptStream = new CipherInputStream(streamIn, decryptCipher);
// Initialize a new document using the decryption
// stream and display it in the PDF viewer
PDFDoc doc = new PDFDoc(decryptStream);
viewer.setDoc(doc);
`
I’ve been digging around the documentation and it seems like I may be able to accomplish this using PTFDFDoc’s initWithStream call and a PTFilter or PTFilterReader but the documentation is vague and confusing.
Am I on the right trail? If so, how should I define a PTFilter. If not, what should I be doing instead?