mirror of
git://git.gnupg.org/gnupg.git
synced 2024-06-10 23:49:50 +02:00
scd:openpgp: Fix PIN pin2hash_if_kdf.
* scd/app-openpgp.c (pin2hash_if_kdf): DEK had been changed to pointer
to allocated memory, so, we need to use DEKLEN for the length.
--
GnuPG-bug-id: 7121
Fixes-commit: 20e85585ed
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
parent
97b37db144
commit
bb57c808b2
|
@ -2534,7 +2534,7 @@ pin2hash_if_kdf (app_t app, int chvno, const char *pin,
|
|||
err = gcry_kdf_derive (pin, pinlen,
|
||||
GCRY_KDF_ITERSALTED_S2K,
|
||||
DIGEST_ALGO_SHA256, salt, 8,
|
||||
s2k_count, sizeof (dek), dek);
|
||||
s2k_count, deklen, dek);
|
||||
if (!err)
|
||||
{
|
||||
*r_pinlen = deklen;
|
||||
|
|
Loading…
Reference in New Issue
Block a user