On Sat, 30 Jan 2010, Dan Hatton wrote:
I have an encrypted PDF file that I can open just fine in Adobe Reader under Windows. But I'd really prefer to read it in Xpdf (or any open source tool). Unfortunately, Xpdf needs the password supplied on the command line, and the password contains characters that are special to the shell. (Actually, I don't think I need to be coy about this. It contains a percent sign, an ampersand, and a pound sign.) I've tried escaping the special characters with backslashes, enclosing the password in various types of quotes, and putting the password in an environment variable, but all of these result in "Incorrect password" errors and failure to open the document. Any ideas, please?
During an e-mail catch-up session, I realize I haven't yet posted what the resolution of this was. I found a version of Xpdf (3.0-r2, IIRC) on Cygwin which accepts the password in a GUI dialogue box. Problem solved. Thanks to Bill and Ted for their replies.