We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
import msoffcrypto
protected = './protected.xlsx' unprotected = './unprotected.xlsx' password = '12345'
protected = './protected.xlsx'
unprotected = './unprotected.xlsx'
password = '12345'
file = open(protected, 'rb') ms_file = msoffcrypto.OfficeFile(file).is_encrypted() print(ms_file)
file = open(protected, 'rb')
ms_file = msoffcrypto.OfficeFile(file).is_encrypted()
print(ms_file)
This return
True
, but when I try
file = open(unprotected, 'rb') ms_file = msoffcrypto.OfficeFile(file).is_encrypted() print(ms_file)
file = open(unprotected, 'rb')
This give me
FileFormatError: Unencrypted document or unsupported file format
instead of False
The text was updated successfully, but these errors were encountered:
Fixed in d0383c8 and released v5.1.0. Thank you for reporting!
Sorry, something went wrong.
No branches or pull requests
import msoffcrypto
protected = './protected.xlsx'
unprotected = './unprotected.xlsx'
password = '12345'
file = open(protected, 'rb')
ms_file = msoffcrypto.OfficeFile(file).is_encrypted()
print(ms_file)
This return
, but when I try
file = open(unprotected, 'rb')
ms_file = msoffcrypto.OfficeFile(file).is_encrypted()
print(ms_file)
This give me
instead of False
The text was updated successfully, but these errors were encountered: