lib/hexapdf/encryption/standard_security_handler.rb in hexapdf-0.29.0 vs lib/hexapdf/encryption/standard_security_handler.rb in hexapdf-0.30.0
- old
+ new
@@ -322,13 +322,13 @@
# If the optional +check_permissions+ argument is +true+, the permissions for files
# encrypted with revision 6 are checked. Otherwise, permission changes are ignored.
def prepare_decryption(password: '', check_permissions: true)
if dict[:Filter] != :Standard
raise(HexaPDF::UnsupportedEncryptionError,
- "Invalid /Filter value for standard security handler")
+ "Invalid /Filter value #{dict[:Filter]} for standard security handler")
elsif ![2, 3, 4, 6].include?(dict[:R])
raise(HexaPDF::UnsupportedEncryptionError,
- "Invalid /R value for standard security handler")
+ "Invalid /R value #{dict[:R]} for standard security handler")
elsif dict[:R] <= 4 && !document.trailer[:ID].kind_of?(PDFArray)
document.trailer[:ID] = ['', '']
end
@trailer_id_hash = trailer_id_hash