Update Picocrypt.py
This commit is contained in:
parent
03069056e4
commit
1374d1b1dd
|
@ -81,7 +81,8 @@ strings = [
|
||||||
"Unknown error occured. Please try again.",
|
"Unknown error occured. Please try again.",
|
||||||
"Drag and drop file(s) and folder(s) into this window.",
|
"Drag and drop file(s) and folder(s) into this window.",
|
||||||
"File metadata (read-only):",
|
"File metadata (read-only):",
|
||||||
"Error. The input file couldn't be decoded as UTF-8."
|
"Error. The input file couldn't be decoded as UTF-8.",
|
||||||
|
"Error. The input file is corrupted so badly that Picocrypt can't decrypt it."
|
||||||
]
|
]
|
||||||
|
|
||||||
# Create root window
|
# Create root window
|
||||||
|
@ -871,10 +872,15 @@ def work():
|
||||||
# If decrypting, read values from file
|
# If decrypting, read values from file
|
||||||
else:
|
else:
|
||||||
tmp = fin.read(129)
|
tmp = fin.read(129)
|
||||||
if bytes(rs128.decode(tmp)[0])==b"+":
|
try:
|
||||||
reedsolo = True
|
if bytes(rs128.decode(tmp)[0])==b"+":
|
||||||
else:
|
reedsolo = True
|
||||||
reedsolo = False
|
else:
|
||||||
|
reedsolo = False
|
||||||
|
except:
|
||||||
|
setDecryptionUI()
|
||||||
|
statusString.set(strings[21])
|
||||||
|
return
|
||||||
|
|
||||||
metadataLength = fin.read(138)
|
metadataLength = fin.read(138)
|
||||||
metadataLength = bytes(rs128.decode(metadataLength)[0])
|
metadataLength = bytes(rs128.decode(metadataLength)[0])
|
||||||
|
|
Loading…
Reference in New Issue