Home GnuPG
Diffusion GnuPG 20e85585ed20

scd:openpgp: Restructure the pin2hash_id_kdf function.

Description

scd:openpgp: Restructure the pin2hash_id_kdf function.

* scd/app-openpgp.c (wipe_and_free_string, wipe_and_free): Enable
functions.
(pin2hash_if_kdf): Change interface.  The input PIN is not anymore
changed.  Further there are no more assumptions about the length of
the provided buffer.
(verify_a_chv): Adjust for changed pin2hash_if_kdf.
(verify_chv2): Ditto
(verify_chv3): Ditto.
(do_change_pin): Ditto.
(do_sign): Ditto.

Note that this a part of the patch
63bda3aad8ec4163b0241f64e8b587d665d650c3 which we used in 2.4 to
implement a PIN cache. For easier backporting we need to add this
here.

Details

Provenance
wernerAuthored on Jan 26 2024, 3:11 PM
Parents
rG97b01ad3f878: tools: Fix argparse table of gpgconf.
Branches
Unknown
Tags
Unknown