-
Notifications
You must be signed in to change notification settings - Fork 713
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix PDF decryption issue for some empty password files
Some PDF's with an empty password can't be decrypted. Investigation found that the problem is a strlen check to prevent an overflow rather than passing down the actual length of the allocated field. Specifically, the UE buffer may have NULL values in it, so a strlen check will claim the field is shorter than it is and then later checks fail because the length is the wrong size. While at it, I improved code comments on the function reading dictionary key-value strings and switched a flag use a bool rather than an int.
- Loading branch information
1 parent
47c079f
commit 814325a
Showing
1 changed file
with
23 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters