diff options
author | NIIBE Yutaka <gniibe@fsij.org> | 2022-09-06 06:43:03 +0200 |
---|---|---|
committer | NIIBE Yutaka <gniibe@fsij.org> | 2022-09-06 06:43:03 +0200 |
commit | f7e0b0c8a56ae03b0c3214c247ae61a939802617 (patch) | |
tree | c37e85daf34bab4769c525a314289e41997ad224 /common | |
parent | tools:gpg-auth: Show SSH key comment when asking PIN. (diff) | |
download | gnupg2-f7e0b0c8a56ae03b0c3214c247ae61a939802617.tar.xz gnupg2-f7e0b0c8a56ae03b0c3214c247ae61a939802617.zip |
common: Fix to determine ECC curve for SSH.
* common/ssh-utils.c (ssh_public_key_in_base64): Use standard name for
ECC curve.
--
See oidtable in common/openpgp-oid.c.
Fixes-commit: 8e650dbd48fa5fde6d8f08154e6a892d495e9227
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/ssh-utils.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/common/ssh-utils.c b/common/ssh-utils.c index c2f3aef54..ab29558cf 100644 --- a/common/ssh-utils.c +++ b/common/ssh-utils.c @@ -587,11 +587,11 @@ ssh_public_key_in_base64 (gcry_sexp_t key, estream_t stream, break; case GCRY_PK_ECC: - if (!strcmp (curve, "nistp256")) + if (!strcmp (curve, "NIST P-256")) identifier = "ecdsa-sha2-nistp256"; - else if (!strcmp (curve, "nistp384")) + else if (!strcmp (curve, "NIST P-384")) identifier = "ecdsa-sha2-nistp384"; - else if (!strcmp (curve, "nistp521")) + else if (!strcmp (curve, "NIST P-521")) identifier = "ecdsa-sha2-nistp521"; else err = gpg_error (GPG_ERR_UNKNOWN_CURVE); |