aboutsummaryrefslogtreecommitdiffstats
path: root/scd/app-openpgp.c
diff options
context:
space:
mode:
authorNIIBE Yutaka <[email protected]>2019-03-13 23:23:38 +0000
committerNIIBE Yutaka <[email protected]>2019-03-13 23:23:38 +0000
commitf199b627ce512c8495af5c9bd1c81127ccde3ca0 (patch)
treebf72f7faba3f9d34f9ab6f18f2d7b8489fbb3a79 /scd/app-openpgp.c
parentg10: Fix symmetric cipher algo constant for ECDH. (diff)
downloadgnupg-f199b627ce512c8495af5c9bd1c81127ccde3ca0.tar.gz
gnupg-f199b627ce512c8495af5c9bd1c81127ccde3ca0.zip
Fix the previous commit.
* g10/ecdh.c (kek_params_table): Revert the change. * scd/app-openpgp.c (ecdh_params): Use CIPHER_ALGO_AES256 for 384-bit key. -- Avoiding CIPHER_ALGO_AES192 is intentional here. Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'scd/app-openpgp.c')
-rw-r--r--scd/app-openpgp.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/scd/app-openpgp.c b/scd/app-openpgp.c
index 62b3cbc2f..1e904b578 100644
--- a/scd/app-openpgp.c
+++ b/scd/app-openpgp.c
@@ -1448,13 +1448,13 @@ ecdh_params (const char *curve)
/* See RFC-6637 for those constants.
0x03: Number of bytes
0x01: Version for this parameter format
- KDF hash algo
- KEK symmetric cipher algo
+ KEK digest algorithm
+ KEK cipher algorithm
*/
if (nbits <= 256)
return (const unsigned char*)"\x03\x01\x08\x07";
else if (nbits <= 384)
- return (const unsigned char*)"\x03\x01\x09\x08";
+ return (const unsigned char*)"\x03\x01\x09\x09";
else
return (const unsigned char*)"\x03\x01\x0a\x09";
}