1
0
mirror of https://github.com/veracrypt/VeraCrypt.git synced 2025-11-13 11:58:26 -06:00

Windows: update libzip to latest version 1.7.3 (close issue #656)

This commit is contained in:
Mounir IDRASSI
2020-07-24 19:39:26 +02:00
parent 5cf7d946d2
commit 948a871c73
49 changed files with 2508 additions and 2730 deletions

View File

@@ -39,10 +39,7 @@ zip_encryption_implementation
_zip_get_encryption_implementation(zip_uint16_t em, int operation) {
switch (em) {
case ZIP_EM_TRAD_PKWARE:
if (operation == ZIP_CODEC_ENCODE) {
return NULL;
}
return zip_source_pkware;
return operation == ZIP_CODEC_DECODE ? zip_source_pkware_decode : zip_source_pkware_encode;
#if defined(HAVE_CRYPTO)
case ZIP_EM_AES_128:
@@ -55,3 +52,11 @@ _zip_get_encryption_implementation(zip_uint16_t em, int operation) {
return NULL;
}
}
ZIP_EXTERN int
zip_encryption_method_supported(zip_uint16_t method, int encode) {
if (method == ZIP_EM_NONE) {
return 1;
}
return _zip_get_encryption_implementation(method, encode ? ZIP_CODEC_ENCODE : ZIP_CODEC_DECODE) != NULL;
}