mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-06 00:10:04 +01:00
Fix displaying error for not supported BitLocker key decryption
'crypt_bitlk_decrypt_key' can also fail because of wrong passphrase and other reasons.
This commit is contained in:
committed by
Milan Broz
parent
fad592b512
commit
97e39f0744
@@ -787,6 +787,7 @@ static int decrypt_key(struct crypt_device *cd,
|
|||||||
r = crypt_bitlk_decrypt_key(key->key, key->keylength, enc_key->key, outbuf, enc_key->keylength,
|
r = crypt_bitlk_decrypt_key(key->key, key->keylength, enc_key->key, outbuf, enc_key->keylength,
|
||||||
(const char*)iv, iv_size, (const char*)tag, tag_size);
|
(const char*)iv, iv_size, (const char*)tag, tag_size);
|
||||||
if (r < 0) {
|
if (r < 0) {
|
||||||
|
if (r == -ENOTSUP)
|
||||||
log_err(cd, _("This operation is not supported."));
|
log_err(cd, _("This operation is not supported."));
|
||||||
crypt_safe_free(outbuf);
|
crypt_safe_free(outbuf);
|
||||||
return r;
|
return r;
|
||||||
|
|||||||
Reference in New Issue
Block a user