Home GnuPG
Diffusion GPGME 3bdf8be6d2c5

json: Delete primary key if subkey gen fails

Description

json: Delete primary key if subkey gen fails

* src/gpgme-json.c (op_delete): Delete primary key on
subkey gen error.

This can happen for example if the user cancels the
pinentry to unlock the primary key when adding the
subkey. To avoid an artifact of a pimary key without
an encryption capable subkey we delete the created
key and treat the whole operation as failed.

Details

Provenance
aheineckeAuthored on Aug 28 2018, 8:35 AM
Parents
rM7d3c13df263e: json: Allow NULL request in encode and chunk
Branches
Unknown
Tags
Unknown