mirror of
https://github.com/ckolivas/lrzip.git
synced 2026-04-04 13:57:40 +00:00
Use separate lrz_encrypt and lrz_decrypt wrappers to lrz_crypt.
This commit is contained in:
parent
0b1db75a44
commit
ff5a5ed054
5 changed files with 20 additions and 7 deletions
2
runzip.c
2
runzip.c
|
|
@ -377,7 +377,7 @@ i64 runzip_fd(rzip_control *control, int fd_in, int fd_out, int fd_hist, i64 exp
|
|||
if (unlikely(read_1g(control, fd_in, md5_stored, MD5_DIGEST_SIZE) != MD5_DIGEST_SIZE))
|
||||
fatal("Failed to read md5 data in runzip_fd\n");
|
||||
if (ENCRYPT)
|
||||
lrz_crypt(control, md5_stored, MD5_DIGEST_SIZE, control->pass_hash, 0);
|
||||
lrz_decrypt(control, md5_stored, MD5_DIGEST_SIZE, control->pass_hash);
|
||||
for (i = 0; i < MD5_DIGEST_SIZE; i++)
|
||||
if (md5_stored[i] != md5_resblock[i]) {
|
||||
print_output("MD5 CHECK FAILED.\nStored:");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue