-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PdfReadError: File has not been decrypted #1088
Comments
Another example: https://corpora.tika.apache.org/base/docs/govdocs1/942/942303.pdf |
That file is encrypted, but with an empty user password :) (AKA "mild obfuscation" rather than encryption, but hey). Seems to be 128-bit RC4. I don't remember offhand how PyPDF2 handles this case, but it could be that a |
@MatthiasValvekens When I specify |
Seeing that basically every PDF viewer automatically tries the empty password, I think PyPDF2 should do the same. From a users perspective, this is very confusing. |
I agree with your proposal, however, there definitively seems to be a problem with the decoder : I did some test with pdfminer.six and the empty password do work |
Hope to see this implemented soon! |
I was trying to read metadata from a PDF that is not encrypted. The file is encrypted with an empty password:
Environment
Code + PDF
The PDF:
pdf/9bc3765eb6426bb34139d419a6e1f79e.pdf
The text was updated successfully, but these errors were encountered: