summaryrefslogtreecommitdiffstats
path: root/crypto/objects
diff options
context:
space:
mode:
authorNils Larsch <nils@openssl.org>2007-02-03 14:41:12 +0000
committerNils Larsch <nils@openssl.org>2007-02-03 14:41:12 +0000
commit357d5de5b9c3a84f170ce91abeafa71c26fefdd9 (patch)
tree143cfee4a5a284e905093d0e2bad33549cf1a762 /crypto/objects
parent0501f02b060e45f2e2d275d779d864f3159f8ea9 (diff)
add support for DSA with SHA2
Diffstat (limited to 'crypto/objects')
-rw-r--r--crypto/objects/obj_dat.h22
-rw-r--r--crypto/objects/obj_mac.h10
-rw-r--r--crypto/objects/obj_mac.num2
-rw-r--r--crypto/objects/obj_xref.h4
-rw-r--r--crypto/objects/obj_xref.txt3
-rw-r--r--crypto/objects/objects.txt5
6 files changed, 41 insertions, 5 deletions
diff --git a/crypto/objects/obj_dat.h b/crypto/objects/obj_dat.h
index 7e0a63c265..9c6bad7891 100644
--- a/crypto/objects/obj_dat.h
+++ b/crypto/objects/obj_dat.h
@@ -62,12 +62,12 @@
* [including the GNU Public Licence.]
*/
-#define NUM_NID 833
-#define NUM_SN 829
-#define NUM_LN 829
-#define NUM_OBJ 785
+#define NUM_NID 835
+#define NUM_SN 831
+#define NUM_LN 831
+#define NUM_OBJ 787
-static unsigned char lvalues[5542]={
+static unsigned char lvalues[5560]={
0x00, /* [ 0] OBJ_undef */
0x2A,0x86,0x48,0x86,0xF7,0x0D, /* [ 1] OBJ_rsadsi */
0x2A,0x86,0x48,0x86,0xF7,0x0D,0x01, /* [ 7] OBJ_pkcs */
@@ -853,6 +853,8 @@ static unsigned char lvalues[5542]={
0x2A,0x86,0x48,0xCE,0x3D,0x04,0x03,0x02, /* [5517] OBJ_ecdsa_with_SHA256 */
0x2A,0x86,0x48,0xCE,0x3D,0x04,0x03,0x03, /* [5525] OBJ_ecdsa_with_SHA384 */
0x2A,0x86,0x48,0xCE,0x3D,0x04,0x03,0x04, /* [5533] OBJ_ecdsa_with_SHA512 */
+0x60,0x86,0x48,0x01,0x65,0x03,0x04,0x03,0x01,/* [5541] OBJ_dsa_with_SHA224 */
+0x60,0x86,0x48,0x01,0x65,0x03,0x04,0x03,0x02,/* [5550] OBJ_dsa_with_SHA256 */
};
static ASN1_OBJECT nid_objs[NUM_NID]={
@@ -2202,6 +2204,10 @@ static ASN1_OBJECT nid_objs[NUM_NID]={
&(lvalues[5525]),0},
{"ecdsa-with-SHA512","ecdsa-with-SHA512",NID_ecdsa_with_SHA512,8,
&(lvalues[5533]),0},
+{"dsa_with_SHA224","dsa_with_SHA224",NID_dsa_with_SHA224,9,
+ &(lvalues[5541]),0},
+{"dsa_with_SHA256","dsa_with_SHA256",NID_dsa_with_SHA256,9,
+ &(lvalues[5550]),0},
};
static ASN1_OBJECT *sn_objs[NUM_SN]={
@@ -2452,6 +2458,8 @@ static ASN1_OBJECT *sn_objs[NUM_SN]={
&(nid_objs[470]),/* "documentVersion" */
&(nid_objs[392]),/* "domain" */
&(nid_objs[452]),/* "domainRelatedObject" */
+&(nid_objs[833]),/* "dsa_with_SHA224" */
+&(nid_objs[834]),/* "dsa_with_SHA256" */
&(nid_objs[827]),/* "ecdsa-with-Recommended" */
&(nid_objs[416]),/* "ecdsa-with-SHA1" */
&(nid_objs[829]),/* "ecdsa-with-SHA224" */
@@ -3304,6 +3312,8 @@ static ASN1_OBJECT *ln_objs[NUM_LN]={
&(nid_objs[66]),/* "dsaWithSHA" */
&(nid_objs[113]),/* "dsaWithSHA1" */
&(nid_objs[70]),/* "dsaWithSHA1-old" */
+&(nid_objs[833]),/* "dsa_with_SHA224" */
+&(nid_objs[834]),/* "dsa_with_SHA256" */
&(nid_objs[297]),/* "dvcs" */
&(nid_objs[827]),/* "ecdsa-with-Recommended" */
&(nid_objs[416]),/* "ecdsa-with-SHA1" */
@@ -4486,6 +4496,8 @@ static ASN1_OBJECT *obj_objs[NUM_OBJ]={
&(nid_objs[673]),/* OBJ_sha384 2 16 840 1 101 3 4 2 2 */
&(nid_objs[674]),/* OBJ_sha512 2 16 840 1 101 3 4 2 3 */
&(nid_objs[675]),/* OBJ_sha224 2 16 840 1 101 3 4 2 4 */
+&(nid_objs[833]),/* OBJ_dsa_with_SHA224 2 16 840 1 101 3 4 3 1 */
+&(nid_objs[834]),/* OBJ_dsa_with_SHA256 2 16 840 1 101 3 4 3 2 */
&(nid_objs[71]),/* OBJ_netscape_cert_type 2 16 840 1 113730 1 1 */
&(nid_objs[72]),/* OBJ_netscape_base_url 2 16 840 1 113730 1 2 */
&(nid_objs[73]),/* OBJ_netscape_revocation_url 2 16 840 1 113730 1 3 */
diff --git a/crypto/objects/obj_mac.h b/crypto/objects/obj_mac.h
index c471c2faeb..db846f49c0 100644
--- a/crypto/objects/obj_mac.h
+++ b/crypto/objects/obj_mac.h
@@ -2497,6 +2497,16 @@
#define NID_sha224 675
#define OBJ_sha224 OBJ_nist_hashalgs,4L
+#define OBJ_dsa_with_sha2 OBJ_nistAlgorithms,3L
+
+#define SN_dsa_with_SHA224 "dsa_with_SHA224"
+#define NID_dsa_with_SHA224 833
+#define OBJ_dsa_with_SHA224 OBJ_dsa_with_sha2,1L
+
+#define SN_dsa_with_SHA256 "dsa_with_SHA256"
+#define NID_dsa_with_SHA256 834
+#define OBJ_dsa_with_SHA256 OBJ_dsa_with_sha2,2L
+
#define SN_hold_instruction_code "holdInstructionCode"
#define LN_hold_instruction_code "Hold Instruction Code"
#define NID_hold_instruction_code 430
diff --git a/crypto/objects/obj_mac.num b/crypto/objects/obj_mac.num
index 147bfc1d2a..1a200207ff 100644
--- a/crypto/objects/obj_mac.num
+++ b/crypto/objects/obj_mac.num
@@ -830,3 +830,5 @@ ecdsa_with_SHA224 829
ecdsa_with_SHA256 830
ecdsa_with_SHA384 831
ecdsa_with_SHA512 832
+dsa_with_SHA224 833
+dsa_with_SHA256 834
diff --git a/crypto/objects/obj_xref.h b/crypto/objects/obj_xref.h
index b385083df1..c5d75c34fa 100644
--- a/crypto/objects/obj_xref.h
+++ b/crypto/objects/obj_xref.h
@@ -30,6 +30,8 @@ static const nid_triple sigoid_srt[] =
{NID_ecdsa_with_SHA256, NID_sha256, NID_X9_62_id_ecPublicKey},
{NID_ecdsa_with_SHA384, NID_sha384, NID_X9_62_id_ecPublicKey},
{NID_ecdsa_with_SHA512, NID_sha512, NID_X9_62_id_ecPublicKey},
+ {NID_dsa_with_SHA224, NID_sha224, NID_dsa},
+ {NID_dsa_with_SHA256, NID_sha256, NID_dsa},
};
static const nid_triple * const sigoid_srt_xref[] =
@@ -50,12 +52,14 @@ static const nid_triple * const sigoid_srt_xref[] =
&sigoid_srt[10],
&sigoid_srt[11],
&sigoid_srt[13],
+ &sigoid_srt[28],
&sigoid_srt[24],
&sigoid_srt[14],
&sigoid_srt[25],
&sigoid_srt[15],
&sigoid_srt[26],
&sigoid_srt[16],
+ &sigoid_srt[27],
&sigoid_srt[23],
&sigoid_srt[17],
&sigoid_srt[18],
diff --git a/crypto/objects/obj_xref.txt b/crypto/objects/obj_xref.txt
index 01a0adbb59..e45b3d34b9 100644
--- a/crypto/objects/obj_xref.txt
+++ b/crypto/objects/obj_xref.txt
@@ -33,6 +33,9 @@ ecdsa_with_SHA512 sha512 X9_62_id_ecPublicKey
ecdsa_with_Recommended undef X9_62_id_ecPublicKey
ecdsa_with_Specified undef X9_62_id_ecPublicKey
+dsa_with_SHA224 sha224 dsa
+dsa_with_SHA256 sha256 dsa
+
id_GostR3411_94_with_GostR3410_2001 id_GostR3411_94 id_GostR3410_2001
id_GostR3411_94_with_GostR3410_94 id_GostR3411_94 id_GostR3410_94
id_GostR3411_94_with_GostR3410_94_cc id_GostR3411_94 id_GostR3410_94_cc
diff --git a/crypto/objects/objects.txt b/crypto/objects/objects.txt
index 7425196b99..e2a6c24c4c 100644
--- a/crypto/objects/objects.txt
+++ b/crypto/objects/objects.txt
@@ -831,6 +831,11 @@ nist_hashalgs 2 : SHA384 : sha384
nist_hashalgs 3 : SHA512 : sha512
nist_hashalgs 4 : SHA224 : sha224
+# OIDs for dsa-with-sha224 and dsa-with-sha256
+!Alias dsa_with_sha2 nistAlgorithms 3
+dsa_with_sha2 1 : dsa_with_SHA224
+dsa_with_sha2 2 : dsa_with_SHA256
+
# Hold instruction CRL entry extension
!Cname hold-instruction-code
id-ce 23 : holdInstructionCode : Hold Instruction Code