summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPaul Park <pjpark@mit.edu>1995-07-27 19:49:32 +0000
committerPaul Park <pjpark@mit.edu>1995-07-27 19:49:32 +0000
commitf0e0ca589c88f20f745c2c6cc5c1f5f1c18fd489 (patch)
tree14009458d4c11b92643b91cb40bc53fa64f7bb2c /src
parent73c3e2285209fc95a6afdd0bb600d88fb11601cd (diff)
downloadkrb5-f0e0ca589c88f20f745c2c6cc5c1f5f1c18fd489.tar.gz
krb5-f0e0ca589c88f20f745c2c6cc5c1f5f1c18fd489.tar.xz
krb5-f0e0ca589c88f20f745c2c6cc5c1f5f1c18fd489.zip
Add rsa-md5.h
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6347 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src')
-rw-r--r--src/lib/crypto/md5/.Sanitize1
-rw-r--r--src/lib/crypto/md5/ChangeLog4
-rw-r--r--src/lib/crypto/md5/rsa-md5.h69
3 files changed, 74 insertions, 0 deletions
diff --git a/src/lib/crypto/md5/.Sanitize b/src/lib/crypto/md5/.Sanitize
index d8cfea6f0..696d0e213 100644
--- a/src/lib/crypto/md5/.Sanitize
+++ b/src/lib/crypto/md5/.Sanitize
@@ -31,6 +31,7 @@ configure.in
md5.c
md5crypto.c
md5glue.c
+rsa-md5.h
t_mddriver.c
Things-to-lose:
diff --git a/src/lib/crypto/md5/ChangeLog b/src/lib/crypto/md5/ChangeLog
index c7cdb6f10..879337bd9 100644
--- a/src/lib/crypto/md5/ChangeLog
+++ b/src/lib/crypto/md5/ChangeLog
@@ -1,4 +1,8 @@
+Thu Jul 27 15:22:42 EDT 1995 Paul Park (pjpark@mit.edu)
+ * rsa-md5.h - Add this file, relocated from include/krb5.
+
+
Fri Jul 7 16:20:07 EDT 1995 Paul Park (pjpark@mit.edu)
* Makefile.in - Add t_cksum under unix only.
* configure.in - Define MD5_K5BETA_COMPAT to select compatability for
diff --git a/src/lib/crypto/md5/rsa-md5.h b/src/lib/crypto/md5/rsa-md5.h
new file mode 100644
index 000000000..64c3c6bae
--- /dev/null
+++ b/src/lib/crypto/md5/rsa-md5.h
@@ -0,0 +1,69 @@
+/*
+ ***********************************************************************
+ ** md5.h -- header file for implementation of MD5 **
+ ** RSA Data Security, Inc. MD5 Message-Digest Algorithm **
+ ** Created: 2/17/90 RLR **
+ ** Revised: 12/27/90 SRD,AJ,BSK,JT Reference C version **
+ ** Revised (for MD5): RLR 4/27/91 **
+ ** -- G modified to have y&~z instead of y&z **
+ ** -- FF, GG, HH modified to add in last register done **
+ ** -- Access pattern: round 2 works mod 5, round 3 works mod 3 **
+ ** -- distinct additive constant for each step **
+ ** -- round 4 added, working mod 7 **
+ ***********************************************************************
+ */
+
+/*
+ ***********************************************************************
+ ** Copyright (C) 1990, RSA Data Security, Inc. All rights reserved. **
+ ** **
+ ** License to copy and use this software is granted provided that **
+ ** it is identified as the "RSA Data Security, Inc. MD5 Message- **
+ ** Digest Algorithm" in all material mentioning or referencing this **
+ ** software or this function. **
+ ** **
+ ** License is also granted to make and use derivative works **
+ ** provided that such works are identified as "derived from the RSA **
+ ** Data Security, Inc. MD5 Message-Digest Algorithm" in all **
+ ** material mentioning or referencing the derived work. **
+ ** **
+ ** RSA Data Security, Inc. makes no representations concerning **
+ ** either the merchantability of this software or the suitability **
+ ** of this software for any particular purpose. It is provided "as **
+ ** is" without express or implied warranty of any kind. **
+ ** **
+ ** These notices must be retained in any copies of any part of this **
+ ** documentation and/or software. **
+ ***********************************************************************
+ */
+
+#ifndef KRB5_RSA_MD5__
+#define KRB5_RSA_MD5__
+
+/* Data structure for MD5 (Message-Digest) computation */
+typedef struct {
+ krb5_ui_4 i[2]; /* number of _bits_ handled mod 2^64 */
+ krb5_ui_4 buf[4]; /* scratch buffer */
+ unsigned char in[64]; /* input buffer */
+ unsigned char digest[16]; /* actual digest after MD5Final call */
+} MD5_CTX;
+
+#if (defined(__STDC__) || defined(_WINDOWS)) && !defined(KRB5_NO_PROTOTYPES)
+extern void MD5Init(MD5_CTX FAR *);
+extern void MD5Update (MD5_CTX FAR *, unsigned char FAR *, unsigned int);
+extern void MD5Final (MD5_CTX FAR *);
+#else
+extern void MD5Init();
+extern void MD5Update ();
+extern void MD5Final ();
+#endif
+
+#define RSA_MD5_CKSUM_LENGTH 16
+#define RSA_MD5_DES_CKSUM_LENGTH 16
+#define RSA_MD5_DES_CONFOUND_LENGTH 8
+
+extern krb5_checksum_entry
+ rsa_md5_cksumtable_entry,
+ rsa_md5_des_cksumtable_entry;
+
+#endif /* KRB5_RSA_MD5__ */