diff options
author | Dmitry Eremin-Solenikov <dbaryshkov@gmail.com> | 2019-11-06 15:14:48 +0300 |
---|---|---|
committer | Dmitry Baryshkov <dbaryshkov@gmail.com> | 2020-01-20 03:36:30 +0300 |
commit | 47a5f1e15a24005620fde80815a29d962ee7b826 (patch) | |
tree | 0bf253902753416f34d71223ce9d195aa6c25fc9 /lib/x509 | |
parent | 4023d63f0b2795c0c0447282c808671ae8503ac3 (diff) | |
download | gnutls-47a5f1e15a24005620fde80815a29d962ee7b826.tar.gz |
x509: include digestParamSet into GOST 512-bit curves A and B params
Old implementations do not understand PublicKeyParams with omitted
digestParamSet. So include the field for old 512-bit curves to improve
compatibility with old implementations.
Signed-off-by: Dmitry Eremin-Solenikov <dbaryshkov@gmail.com>
Diffstat (limited to 'lib/x509')
-rw-r--r-- | lib/x509/key_encode.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/lib/x509/key_encode.c b/lib/x509/key_encode.c index a589dd4f33..c2bc89aad1 100644 --- a/lib/x509/key_encode.c +++ b/lib/x509/key_encode.c @@ -569,6 +569,10 @@ _gnutls_x509_write_gost_params(const gnutls_pk_params_st * params, params->curve == GNUTLS_ECC_CURVE_GOST256CPXA || params->curve == GNUTLS_ECC_CURVE_GOST256CPXB)) oid = HASH_OID_STREEBOG_256; + else if (params->algo == GNUTLS_PK_GOST_12_512 && + (params->curve == GNUTLS_ECC_CURVE_GOST512A || + params->curve == GNUTLS_ECC_CURVE_GOST512B)) + oid = HASH_OID_STREEBOG_512; else oid = NULL; |