Skip to content

Correct improper decryption of PDFStream object in Adobe Digital Edition PDF#935

Open
LugubriousProphecy wants to merge 3 commits intonoDRM:masterfrom
LugubriousProphecy:master
Open

Correct improper decryption of PDFStream object in Adobe Digital Edition PDF#935
LugubriousProphecy wants to merge 3 commits intonoDRM:masterfrom
LugubriousProphecy:master

Conversation

@LugubriousProphecy
Copy link
Copy Markdown

The original code fails to decrypt the dictionary object within the stream object, decrypting only the data contained within the stream and not the remaining dictionary portion of the stream object. This leads to improper decryption of images with an Indexed colorspace where the lookup table is stored as an encrypted string within the dictionary of the stream object.

This change allows the decryption of the remaining data within the stream object , stored as a dictionary, and fixes the color issue that plagued encrypted PDFs with Indexed images.

The impetus for correcting this came from a PDF with images whose color was corrupted, but there may be other cases where issues have arisen due to significant information within the stream object not being properly decrypted. This change applies to the stream object and will resolve issues in those cases as well.

@LugubriousProphecy LugubriousProphecy changed the title Correct improper decryption of PDFStream object Correct improper decryption of PDFStream object in Adobe Digital Edition PDF Dec 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant