SHA224_Update() and SHA224_Final() aren't implemented, and since
authorRichard Levitte <levitte@openssl.org>
Sun, 30 May 2004 16:58:33 +0000 (16:58 +0000)
committerRichard Levitte <levitte@openssl.org>
Sun, 30 May 2004 16:58:33 +0000 (16:58 +0000)
SHA224() uses SHA256_Update() and SHA256_Final() instead, let's just
create aliases in form of macros.

make update

crypto/sha/sha.h
util/libeay.num

index 35c89375a2538e21a4248b7570507b78b56906f9..f4dd5277c2f78e68dd8f82ad7bdc58965eaaff87 100644 (file)
@@ -89,12 +89,12 @@ extern "C" {
 #define SHA_LONG unsigned int
 #endif
 
-#define SHA_LBLOCK     16
+#define SHA_LBLOCK     16U
 #define SHA_CBLOCK     (SHA_LBLOCK*4)  /* SHA treats input data as a
                                         * contiguous array of 32 bit
                                         * wide big-endian values. */
 #define SHA_LAST_BLOCK  (SHA_CBLOCK-8)
-#define SHA_DIGEST_LENGTH 20
+#define SHA_DIGEST_LENGTH 20U
 
 typedef struct SHAstate_st
        {
@@ -135,8 +135,13 @@ typedef struct SHA256state_st
 
 #ifndef OPENSSL_NO_SHA256
 int SHA224_Init(SHA256_CTX *c);
+#if 0
 int SHA224_Update(SHA256_CTX *c, const void *data, size_t len);
 int SHA224_Final(unsigned char *md, SHA256_CTX *c);
+#else
+#define SHA224_Update(c,data,len)      SHA256_Update((c),(data),(len))
+#define SHA224_Final(md,c)     SHA256_Final((md),(c))
+#endif
 unsigned char *SHA224(const unsigned char *d, size_t n,unsigned char *md);
 int SHA256_Init(SHA256_CTX *c);
 int SHA256_Update(SHA256_CTX *c, const void *data, size_t len);
index b6dab240034f1b73df5c3f9708df79eca67d8239..40c91172250f3012cc0316ed5d27e7aa3550d6ed 100755 (executable)
@@ -3213,8 +3213,8 @@ SHA512_Update                           3615      EXIST::FUNCTION:SHA,SHA512
 SHA256_Init                             3616   EXIST::FUNCTION:SHA,SHA256
 SHA224                                  3617   EXIST::FUNCTION:SHA,SHA256
 SHA384_Update                           3618   EXIST::FUNCTION:SHA,SHA512
-SHA224_Final                            3619   EXIST::FUNCTION:SHA,SHA256
-SHA224_Update                           3620   EXIST::FUNCTION:SHA,SHA256
+SHA224_Final                            3619   NOEXIST::FUNCTION:
+SHA224_Update                           3620   NOEXIST::FUNCTION:
 SHA512_Final                            3621   EXIST::FUNCTION:SHA,SHA512
 SHA224_Init                             3622   EXIST::FUNCTION:SHA,SHA256
 SHA512_Init                             3623   EXIST::FUNCTION:SHA,SHA512