2003-07-21 Moritz Schulte <moritz@g10code.com>
[libgcrypt.git] / cipher / sha256.c
index 8b92d31..b1a0d87 100644 (file)
@@ -293,9 +293,16 @@ static byte asn[19] = /* Object ID is  2.16.840.1.101.3.4.2.1 */
     0x48, 0x01, 0x65, 0x03, 0x04, 0x02, 0x01, 0x05,
     0x00, 0x04, 0x20 };
 
+static gcry_md_oid_spec_t oid_spec_sha256[] =
+  {
+    /* According to the OpenPGG draft rfc2440-bis06 */
+    { "2.16.840.1.101.3.4.2.1" }, 
+    { NULL },
+  };
+
 gcry_md_spec_t digest_spec_sha256 =
   {
-    "SHA256", asn, DIM (asn), 32,
+    "SHA256", asn, DIM (asn), oid_spec_sha256, 32,
     sha256_init, sha256_write, sha256_final, sha256_read,
     sizeof (SHA256_CONTEXT)
   };