mirror of
git://git.gnupg.org/gnupg.git
synced 2024-12-22 10:19:57 +01:00
gpg: Add canceled status message.
* common/status.h (STATUS_CANCELED_BY_USER): New. * g10/passphrase.c (passphrase_to_dek): Send STATUS_CANCELED_BY_USER instead of STATUS_MISSING_PASSPHRASE when canceled is set. -- This is to prevent further pinentry tries when the pinentry is canceled by the user during symmetric decryption. Signed-off-by: Ben Kibbey <bjk@luxsci.net> (cherry picked from commit 31e47dfad0f40e31e8b3113b933696e8e4105136)
This commit is contained in:
parent
c373735e79
commit
f05d1772c4
@ -35,6 +35,7 @@ enum
|
||||
STATUS_ENTER,
|
||||
STATUS_LEAVE,
|
||||
STATUS_ABORT,
|
||||
STATUS_CANCELED_BY_USER,
|
||||
|
||||
STATUS_GOODSIG,
|
||||
STATUS_BADSIG,
|
||||
|
@ -409,7 +409,7 @@ passphrase_to_dek (int cipher_algo, STRING2KEY *s2k,
|
||||
if (*canceled)
|
||||
{
|
||||
xfree (pw);
|
||||
write_status( STATUS_MISSING_PASSPHRASE );
|
||||
write_status( STATUS_CANCELED_BY_USER );
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user