You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When encrypting PDF files, there is no verification whether the reserved permission bits are passed correctly. This seems to allow for PDF files which do not completely follow the PDF 1.7 specification (table 3.20). (This is some follow-up to #2391.)
Environment
Which environment were you using when you encountered the problem?
This seems to allow for PDF files which do not completely follow the PDF 1.7 specification (table 3.20)
I think I might have a different version of the specs as I don't have that table.
In PDF 32000-1:2008, First Edition, 2008-7-1, Document management — Portable document format — Part 1: PDF 1.7 there is Table 22 – User access permissions.
I do see a note, though:
PDF integer objects can be interpreted as binary values in a signed twos-complement form. Since all the
reserved high-order flag bits in the encryption dictionary’s P value are required to be 1, the integer value P
shall be specified as a negative integer. For example, assuming revision 2 of the security handler, the value -
44 permits printing and copying but disallows modifying the contents and annotations.
This means that R13 -R32 are required to be 1.
However, I don't see evidence for any other values.
When encrypting PDF files, there is no verification whether the reserved permission bits are passed correctly. This seems to allow for PDF files which do not completely follow the PDF 1.7 specification (table 3.20). (This is some follow-up to #2391.)
Environment
Which environment were you using when you encountered the problem?
Code + PDF
This is a minimal, complete example that shows the issue:
The PDF file is from our own resources directory.
Output
This will print:
Problem
The text was updated successfully, but these errors were encountered: