mirror of
https://github.com/openssl/openssl.git
synced 2025-01-12 13:36:28 +08:00
6eb648941e
For some reason, DSA has been aliased with dsaWithSHA1 for an eternity. They are not the same, though, and should never have been aliased in the first place. This was first discovered with 'openssl list': $ openssl list -signature-algorithms ... { 1.2.840.10040.4.1, 1.2.840.10040.4.3, 1.3.14.3.2.12, 1.3.14.3.2.13, 1.3.14.3.2.27, DSA, DSA-old, DSA-SHA, DSA-SHA1, DSA-SHA1-old, dsaEncryption, dsaEncryption-old, dsaWithSHA, dsaWithSHA1, dsaWithSHA1-old } @ default This isn't good at all, as it confuses the key algorithms signature function with a signature scheme that involves SHA1, and it makes it look like OpenSSL's providers offer a DSA-SHA1 implementation (which they currently do not do). Breaking this aliasing apart (i.e. aliasing DSA, DSA-old, dsaEncryption and dsaEncryption-old separately from the names that involve SHA) appears harmless as far as OpenSSL's test suite goes. Reviewed-by: Kurt Roeckx <kurt@roeckx.be> Reviewed-by: Tomas Mraz <tomas@openssl.org> (Merged from https://github.com/openssl/openssl/pull/24828)
45 lines
1.1 KiB
C
45 lines
1.1 KiB
C
/*
|
|
* Copyright 2006-2023 The OpenSSL Project Authors. All Rights Reserved.
|
|
*
|
|
* Licensed under the Apache License 2.0 (the "License"). You may not use
|
|
* this file except in compliance with the License. You can obtain a copy
|
|
* in the file LICENSE in the source distribution or at
|
|
* https://www.openssl.org/source/license.html
|
|
*/
|
|
|
|
/*
|
|
* This table MUST be kept in ascending order of the NID each method
|
|
* represents (corresponding to the pkey_id field) as OBJ_bsearch
|
|
* is used to search it.
|
|
*/
|
|
static const EVP_PKEY_ASN1_METHOD *standard_methods[] = {
|
|
&ossl_rsa_asn1_meths[0],
|
|
&ossl_rsa_asn1_meths[1],
|
|
#ifndef OPENSSL_NO_DH
|
|
&ossl_dh_asn1_meth,
|
|
#endif
|
|
#ifndef OPENSSL_NO_DSA
|
|
&ossl_dsa_asn1_meths[0],
|
|
&ossl_dsa_asn1_meths[1],
|
|
&ossl_dsa_asn1_meths[2],
|
|
&ossl_dsa_asn1_meths[3],
|
|
#endif
|
|
#ifndef OPENSSL_NO_EC
|
|
&ossl_eckey_asn1_meth,
|
|
#endif
|
|
&ossl_rsa_pss_asn1_meth,
|
|
#ifndef OPENSSL_NO_DH
|
|
&ossl_dhx_asn1_meth,
|
|
#endif
|
|
#ifndef OPENSSL_NO_ECX
|
|
&ossl_ecx25519_asn1_meth,
|
|
&ossl_ecx448_asn1_meth,
|
|
&ossl_ed25519_asn1_meth,
|
|
&ossl_ed448_asn1_meth,
|
|
#endif
|
|
#ifndef OPENSSL_NO_SM2
|
|
&ossl_sm2_asn1_meth,
|
|
#endif
|
|
};
|
|
|