Java SDK giving a password Protected File
Tuesday, September 13, 2022 at 12:33pmHi,
We are using JAVA SDK v11.47 , we are downloading the PDF using the below code that is there on your developer portal.
Observations:
1. The files that we download using the below code gives us password prompt when we open it
2. if we use the ?flatten=true then we are getting a corrupted file which doesn't even open
3. When we use the .net SDK for the same package id and the document id we don't see an issue i.e. the document gets downloaded correctly and we are able to open it without any issues
FileOutputStream stream1 = new FileOutputStream("C:/Users/hhaidary/Desktop/Example/signed_document.pdf");
// Retrieve the bytes of the document (with fields)
byte[] pdfDocumentBytes = eslClient.downloadDocument(packageId, documentId);
try{
stream1.write(pdfDocumentBytes);
} finally {
stream1.close();
}
Reply to: Java SDK giving a password Protected File
Tuesday, September 13, 2022 at 01:15pmHi manoj,
Thanks for your post! Could you share below information to [email protected] so that I can look closer into the issue?
-The OneSpan Sign environment of your account
-An example transaction ID
-If there's no sensitive information, could you also share the downloaded PDF via Java and .NET SDKs?
-You mentioned about downloading flattened version by adding "?flatten=true" parameter, how did you do that? In browser or with RESTful code?
Best Regards,
Duo
Reply to: Java SDK giving a password Protected File
Tuesday, September 13, 2022 at 01:24pmHi Duo Liang,
I have sent you an email. Please let me know if you need additional details.
Reply to: Java SDK giving a password Protected File
Tuesday, September 13, 2022 at 01:56pmPrevious comment was actually from Manoj but received via secure email and copied here for ease of reference.
Reply to: Java SDK giving a password Protected File
Tuesday, September 13, 2022 at 02:00pmHi ,
Can you please remove the attachments and also the email address in the response from the forum since it is public ?