Reader plug-in, save copy of password protected pdf without password

Hello,
We currently have an Acrobat Reader plugin (using the 8.1 SDK) and are having trouble with password protected PDFs.
The sole purpose of our plug-in is to pass a copy of the currently open PDF to a different folder on the user's computer. The problem we are facing is with the password protected PDFs. We would like to pass a copy of the PDF that doesn't have the readonly password protection.
Scenario:
1. The user opens a password protected PDF in Adobe Reader.
2. They are prompted for the password, they enter it and can see the PDF. 3. Now they click our custom button.
4. Save a copy of the currently open PDF without password protection
Since we already know they have entered the correct password, in theory we should be able to either save all of the content to a new file, or simply remove the password protection.
Can anyone point me in the right direction so that I will be able to get a PDF without the password?
Thanks,
Ryan

Hi again,
I was doing some research in the API reference and examples and I think that for my business problem, it will be sufficient if I can get the read access password. I found that I am able to use the following:
AVCryptGetPassword(pdDoc, permsWanted, (void **)&password)
This prompts the user to enter the password and puts the actual password in the &password variable, which will will work for us. Ideally though, I would like to not have to prompt the user again for the password since they already entered when opening the pdf, is it possible to get access to the plain text of the password that they typed when opening the pdf or another way?
I tried:
StdSecurityDataRec* secData;
secData = (StdSecurityDataRec*)PDDocGetNewSecurityData (pdDoc);
if (secData) {
if (secData->hasUserPW)
char* mypw = secData->userPW;
However, the password is encrypted. Thanks for your help!
Thanks,
Ryan

Similar Messages

  • Password-protected PDF demands password in triplicate

    I'm having problems with a password-protected PDF (created in Acrobat Pro 8 ) which opens fine with a single entry of the password when downloaded but when website visitors try to open the form directly in their browser it keeps asking for the password and will only open on the third password attempt (by when most visitors will have given up on it). Could you please tell me what is causing this phenomenon and whether I can fix it? TIA.
    Simon

    It looks like this issue may be limited to files that have been set to restrict the user's ability to print or edit the document (even after a password has been entered for viewing).  I found that a password-protected PDF could be viewed in iBooks, but after I added the print restriction, I had the same problem you reported.

  • Open password protected file without password?  Lost my password.

    I lost my password to a Pages protected file and must find a way to open it without the password. 

    Best not to pull your brain apart trying to decipher the password issue. I lost my password recently and went nearly 8 months of stress trying every combination possible to open. My issue was my laptop. I was completely locked out. Until I got help on this Forum to remedy my issue. Since your issue concerns Pages I cannot imagine what strategies you could use or dream up. Save yourself by recreating your document if possible. Saving face is better than "stress sleep" that deprives your health and creates a host of other stress related issues. Start over and create another Pages document.

  • Can't open password protected pdf in reader

    Password protected PDF rejects password.
    The password is correct, as this PDF can be opened on other
    PC.
    Ver of adobe reader is 11.0 on windows 7 pro

    Save PDF to desktop and open in adobe reader, also open reader
    first and selected file

  • How do I save a password protected file without a password?

    Someone sent me a password protected file and I want to save it on my computer without the password.
    Thanks,
    Scott

    Hi Scott,
    It is not possible to save a password protected file without a password with Adobe Reader, you would require Adobe Acrobat to remove the password protection. Even with Adobe Acrobat you can only remove the security if you are aware about the password otherwise you need to contact the Author/creator of the PDF to remove the security.
    Regards,
    ~Pranav

  • How to read a password protected pdf on a surface pro 2?

    Has anyone been able to successfully open a password protected PDF on a Surface Pro 2?  The Adobe Reader app doesn't work on the surface pro 2 with protected PDFs.

    Use Adobe Reader XI, the regular Adobe Reader for any Windows system.

  • I cannot open password protected PDF document with attachments with Adobe Reader on OS X. Crashes.

    I cannot open password protected PDF document having attachments on my OS X (v 10.8.4) with Adobe Reader X nor XI. The reader crashes. The same document using the same password opens fine on the laptop and Windows systems wheni it is fetched from a secure mail server. Why?

    Moved to Adobe Reader

  • Reading password protected pdf email attachments

    When I open a password protected pdf file that was attached to an email received on my iPhone, it appears to open (accurate page count displayed top left corner) but the page is blank and I never see a prompt that asks for the password.

    I'm having the same problem, I've tried to open password protected pdf files on my iPhone, but the password screen doesn't appear. I've tried 2 different pdf reader apps from the app store. I was going to buy an iPad for reading my ebooks from college but I won't until I can get this figured out. The school says Adobe and Apple don't play well together and that is the problem. Hope someone has a work around for this.

  • Open password protected PDF in website

    Hi,
    I hope someone can help me. Greatly appreciate it.
    My website has PDF documents that's available for registered users to view online (through my site) only.
    Currently, I can't find any solutions to prevent users from downloading/"save-as" the PDF doc in their local drives, so I'm thinking of password-protecting these PDFs. This will ensure that they'd not be able to view the PDFs even though they download it and save-as local.
    However, how do I open these password-protected PDFs on my site?
    When I point/redirect to these PDFs, it will prompt for password.
    It'd defeat all protection intent if I were to give the password to the user to enter, right?
    Example:
    1. Response.Redirect("mySecuredPdf.pdf")
    2. The browser will then prompt user for password.
    What can I do in the CodeBehind to enable the server to OPEN the pdf, and at the same time, pass the correct password to the viewer to open without prompting?
    I cannot remove password, because I want to prevent users from downloading and then opening it later, or redistributing the file.
    btw, i'm using ASP.NET.
    Please help.

    There's a similar thread in the Acrobat Windows section, and the answer is the same - only a DRM system with a client UI (such as Adobe Digital Editions) can restrict the *use* of a file. You cannot prevent the client downloading and saving it, as otherwise they can't see it on their screen. The page you're reading now is not on a computer at Adobe - it's on yours.
    > What can I do in the CodeBehind to enable the server to OPEN the pdf, and at the same time, pass the correct password to the viewer to open without prompting?
    I think you're getting the flow a little backwards - the PDF is 'opened' by the client, using their copy of Adobe Reader (or whatever). The webserver has nothing to do with the process other than blindly sending the file's 1s and 0s down a wire, so can't do anything to directly control the client's desktop applications.

  • Need to recreate a password protected PDF but can't unlock origional

    I have a password protected PDF protfolio that I need to recreate but no longer have the origional password for.  I could just write a new PDF, but so much time was spent creating the origional.  Is there a way to save a copy and then re-apply the password security?

    I want to add that the pdf password unlock programs usually are easier to break the permission password for you to copy, print and edit with corresponding tools. But to crack the open password it's more difficult and if your file is protected by this kind of pdf security, you may have to type word by word from scratch.....

  • Acrobat 8.1 and C# - How can you detect password protected PDF files?

    I am modifying our existing C# code that opens PDF files.  But when ever we hit a password protected file, we are prompted for a password.  This is an automated process, so if we detect a password protected file, we move the file to a manual processing folder to be processed later.
    We are using Acrobat 8.1 Standard.
    Our code looks like this:
    using 
    System;
    using 
    System.Collections.Generic;
    using 
    System.Linq;
    using 
    System.Text;
    using 
    Acrobat;
    using 
    System.IO;
    using 
    Word = Microsoft.Office.Interop.Word;
    using 
    System.Reflection;
         AcroApp app = new AcroApp();     app.Hide();
         try
              if (app != null)          {
                   app.CloseAllDocs();
                   AcroAVDoc av = new AcroAVDoc(); 
                   if (av.Open(filename, "Test") == true)               {
                        AcroPDDoc doc = new AcroPDDoc();                    doc = (
    AcroPDDoc)av.GetPDDoc(); 
                        doc.Save((
    short)Acrobat.PDSaveFlags.PDSaveFull, 
                        Utilities.GeneratePath(FileVersion.TEMP) + fi.Name.RemoveFileExtension() + ".PDF");                    doc.Close();
         catch (Exception ex)     {
              ErrorLog.LogError(filename.RemoveFileExtension(), ex);     }
         finally
              app.CloseAllDocs();
              app.Exit();
    This works great for non-password protected PDF files, but it prompts for a password if the file is password protected.  I was looking at the FileOpenEX functionality, but I can not find the reference to bring into my C# project.  It looks like it is only for C++, since I could only find C++ examples.
    Any help would be appreciated.
    Thanks,
    Tom

    There are no methods in the Acrobat SDK for C# for what you wish to accomplish.

  • How to display in browser a password protected pdf file I created?

    I created a password protected pdf file.
    I want to display the file in browser so that viewers can only view it online.
    It is better that viewers cannot download it.
    But I donot know how to prevent viewers downloading the file.
    Since the pdf is password protected, viewers don't have the password even they download it.
    But how can I display the password protected pdf file in browser when I know the password?
    Or is there a better to just viewers see the pdf file online and prevent them from downloading and printing it?

    Any file on the web has to be copied to the local machine in order for the file content to be presented to the viewer. That's how the "www" is built.  So, to make use of your web based PDF the file has to be downloaded to the local machine. This might be to the local machine's temporary internet / browser cache or (via a 'save this to my computer') to some other location on the local machine's HDD. Bottom line -- web based files get downloaded this is the case for protected file or a non-protected file.
    Be well...
    Message was edited by: CtDave

  • Password Protected PDF files

    When a password protected attachement is sent to my iPhone, there is no icon attached, only the code in the email.  However, it's normal when I view the email with my PC (Fire Fox or IE).  The same thing happens on the iPhone 3, 4 and iPad 3.  Without the PDF icon, I cannot save the file to be opened with any other application such as iBooks or PDF readers.  Any ideas?

    That's indeed a problem with Quickoffice Adobe reader2.5 which doesn't support password protected pdf. You can raise a ticket in the quickoffice support page requesting that feature. http://support.quickoffice.com/index.php?_m=tickets&_a=submit
    If a reply has solved your problem click Accept as solution button, doing it will help others know the solution. Thanks.

  • Mavericks Preview Opens Password Protected PDF?

    I exported a image in CS6 Illustrater as a pdf. I saved the pdf using two passwords. One password was for opening it and the second one for editng it. It was saved with any editing turned off. When I opened it in Preview on Mavericks the Preview app correctly displayed a password textfield to open it. After I entered the password it opened correctly. When I attempted a basic edit of the pdf, a simple rotatation of the image, Preview displayed a little note indicating that the original document was password protected so it made a copy of the original pdf. I was then free to edit the copy in Preview such as rotate, add txt, and so forth. I don't think this is going to make many people who distribute and sell password protected pdf files that happy. What the heck is going on here?

    It looks like this issue may be limited to files that have been set to restrict the user's ability to print or edit the document (even after a password has been entered for viewing).  I found that a password-protected PDF could be viewed in iBooks, but after I added the print restriction, I had the same problem you reported.

  • InDesign Data Merge using password protected PDFs?

    I am trying to print postcards with Data Merge and I've run into a problem. The source files for one of the images are password protected PDFs. They all use the same password, and I do know the password, but InDesign wants me to enter the password every time it processes a record.
    If I'm printing 10,000 postcards, I would have to enter the password 10,000 times to make my merged file!
    Does anyone have any suggestions? Is there a way to enter the password once and, maybe hold down [command + option + control + kitchensink] or whatever, while clicking "OK" to apply that password to all future password dialog boxes? Is there a script I can run that could automatically enter the password?
    The original source PDFs need to keep the password protection, so removing the security en masse isn't an option. Making non-secure copies of all the possible PDFs that could be used seems really unwieldy and would take up a lot of network storage resources, so I really hope there is a more elegant solution out there.
    I'm using CS5 on a Mac and I would LOVE it if anyone has any suggestions at all on how to fix this. Thanks!
    -Cole Hartson

    Your path needs to use a colon instead of a forward slash. Also you might need to add the name of your hard drive before Users.
    The easiest way to get the correct path is to manually place one of the images, then go to the links panel, right-click on the image name and select Copy Info > Copy Platform Style Path.

Maybe you are looking for

  • Deploying a web service to tomcat

    Hello I've had a problem deploying a web app that includes a web service. The application runs with no problems on the development computer using netbean6's built in tomcat 6 but when I drop the war file on to the test server the following catalina e

  • Concatenation of list of values in a single variable.

    My query returns list of transactions. I want store all these transactions in a single variable and are comma separated. We are achieving this functionality by FOR loop. Is there any simple method to achieve this? Please let me know if you have any i

  • Problem while using select

    I am using the <select>[ tag to display a pull down in my jsp.. I have a menu bar which has another pull down...When i try to select something from the menu if there is a select pull down below it then the select pull down overlaps the menu pull down

  • A problem with building a web service with netbeans

    always a problem occurs when i try to build a web service server side. build is perfect .but when i said run the project there is an error occurs: "Deployment error:null. See the server log file for details." error link goes me to this row in the bui

  • Javascript for onchange of a selectlist.

    Hi, I have a requirement. There is a selectlist in my form. Once user selects a value in this, I have to display 6 or 7 fields. How can I write a javascript to do this and attach to the selectlist ? I am new to javascript. Can anyone point me to some