summaryrefslogtreecommitdiff
path: root/src/lib/libcrypto/md2
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/libcrypto/md2')
-rw-r--r--src/lib/libcrypto/md2/Makefile6
-rw-r--r--src/lib/libcrypto/md2/md2.h3
-rw-r--r--src/lib/libcrypto/md2/md2_dgst.c9
3 files changed, 4 insertions, 14 deletions
diff --git a/src/lib/libcrypto/md2/Makefile b/src/lib/libcrypto/md2/Makefile
index 7f43321ab2..17f878aeb7 100644
--- a/src/lib/libcrypto/md2/Makefile
+++ b/src/lib/libcrypto/md2/Makefile
@@ -33,7 +33,7 @@ top:
33all: lib 33all: lib
34 34
35lib: $(LIBOBJ) 35lib: $(LIBOBJ)
36 $(ARX) $(LIB) $(LIBOBJ) 36 $(AR) $(LIB) $(LIBOBJ)
37 $(RANLIB) $(LIB) || echo Never mind. 37 $(RANLIB) $(LIB) || echo Never mind.
38 @touch lib 38 @touch lib
39 39
@@ -74,9 +74,7 @@ clean:
74 74
75# DO NOT DELETE THIS LINE -- make depend depends on it. 75# DO NOT DELETE THIS LINE -- make depend depends on it.
76 76
77md2_dgst.o: ../../include/openssl/bio.h ../../include/openssl/crypto.h 77md2_dgst.o: ../../include/openssl/crypto.h ../../include/openssl/e_os2.h
78md2_dgst.o: ../../include/openssl/e_os2.h ../../include/openssl/err.h
79md2_dgst.o: ../../include/openssl/fips.h ../../include/openssl/lhash.h
80md2_dgst.o: ../../include/openssl/md2.h ../../include/openssl/opensslconf.h 78md2_dgst.o: ../../include/openssl/md2.h ../../include/openssl/opensslconf.h
81md2_dgst.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h 79md2_dgst.o: ../../include/openssl/opensslv.h ../../include/openssl/ossl_typ.h
82md2_dgst.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h 80md2_dgst.o: ../../include/openssl/safestack.h ../../include/openssl/stack.h
diff --git a/src/lib/libcrypto/md2/md2.h b/src/lib/libcrypto/md2/md2.h
index d59c9f2593..a46120e7d4 100644
--- a/src/lib/libcrypto/md2/md2.h
+++ b/src/lib/libcrypto/md2/md2.h
@@ -81,9 +81,6 @@ typedef struct MD2state_st
81 } MD2_CTX; 81 } MD2_CTX;
82 82
83const char *MD2_options(void); 83const char *MD2_options(void);
84#ifdef OPENSSL_FIPS
85int private_MD2_Init(MD2_CTX *c);
86#endif
87int MD2_Init(MD2_CTX *c); 84int MD2_Init(MD2_CTX *c);
88int MD2_Update(MD2_CTX *c, const unsigned char *data, size_t len); 85int MD2_Update(MD2_CTX *c, const unsigned char *data, size_t len);
89int MD2_Final(unsigned char *md, MD2_CTX *c); 86int MD2_Final(unsigned char *md, MD2_CTX *c);
diff --git a/src/lib/libcrypto/md2/md2_dgst.c b/src/lib/libcrypto/md2/md2_dgst.c
index cc4eeaf7a7..c57b3da288 100644
--- a/src/lib/libcrypto/md2/md2_dgst.c
+++ b/src/lib/libcrypto/md2/md2_dgst.c
@@ -62,11 +62,6 @@
62#include <openssl/md2.h> 62#include <openssl/md2.h>
63#include <openssl/opensslv.h> 63#include <openssl/opensslv.h>
64#include <openssl/crypto.h> 64#include <openssl/crypto.h>
65#ifdef OPENSSL_FIPS
66#include <openssl/fips.h>
67#endif
68
69#include <openssl/err.h>
70 65
71const char MD2_version[]="MD2" OPENSSL_VERSION_PTEXT; 66const char MD2_version[]="MD2" OPENSSL_VERSION_PTEXT;
72 67
@@ -78,7 +73,7 @@ const char MD2_version[]="MD2" OPENSSL_VERSION_PTEXT;
78static void md2_block(MD2_CTX *c, const unsigned char *d); 73static void md2_block(MD2_CTX *c, const unsigned char *d);
79/* The magic S table - I have converted it to hex since it is 74/* The magic S table - I have converted it to hex since it is
80 * basically just a random byte string. */ 75 * basically just a random byte string. */
81static MD2_INT S[256]={ 76static const MD2_INT S[256]={
82 0x29, 0x2E, 0x43, 0xC9, 0xA2, 0xD8, 0x7C, 0x01, 77 0x29, 0x2E, 0x43, 0xC9, 0xA2, 0xD8, 0x7C, 0x01,
83 0x3D, 0x36, 0x54, 0xA1, 0xEC, 0xF0, 0x06, 0x13, 78 0x3D, 0x36, 0x54, 0xA1, 0xEC, 0xF0, 0x06, 0x13,
84 0x62, 0xA7, 0x05, 0xF3, 0xC0, 0xC7, 0x73, 0x8C, 79 0x62, 0xA7, 0x05, 0xF3, 0xC0, 0xC7, 0x73, 0x8C,
@@ -121,7 +116,7 @@ const char *MD2_options(void)
121 return("md2(int)"); 116 return("md2(int)");
122 } 117 }
123 118
124FIPS_NON_FIPS_MD_Init(MD2) 119int MD2_Init(MD2_CTX *c)
125 { 120 {
126 c->num=0; 121 c->num=0;
127 memset(c->state,0,sizeof c->state); 122 memset(c->state,0,sizeof c->state);