OSDN Git Service

Move *.c and *.h files to src
[ffftp/ffftp.git] / src / md5.h
diff --git a/src/md5.h b/src/md5.h
new file mode 100644 (file)
index 0000000..50ea670
--- /dev/null
+++ b/src/md5.h
@@ -0,0 +1,51 @@
+/* MD5.H - header file for MD5C.C\r
+ */\r
+\r
+/* Copyright (C) 1991-2, RSA Data Security, Inc. Created 1991. All\r
+rights reserved.\r
+\r
+License to copy and use this software is granted provided that it\r
+is identified as the "RSA Data Security, Inc. MD5 Message-Digest\r
+Algorithm" in all material mentioning or referencing this software\r
+or this function.\r
+\r
+License is also granted to make and use derivative works provided\r
+that such works are identified as "derived from the RSA Data\r
+Security, Inc. MD5 Message-Digest Algorithm" in all material\r
+mentioning or referencing the derived work.\r
+\r
+RSA Data Security, Inc. makes no representations concerning either\r
+the merchantability of this software or the suitability of this\r
+software for any particular purpose. It is provided "as is"\r
+without express or implied warranty of any kind.\r
+\r
+These notices must be retained in any copies of any part of this\r
+documentation and/or software.\r
+ */\r
+\r
+/* POINTER defines a generic pointer type */\r
+typedef unsigned char *POINTER;\r
+\r
+/* UINT2 defines a two byte word */\r
+typedef unsigned short int UINT2;\r
+\r
+/* UINT4 defines a four byte word */\r
+typedef unsigned long int UINT4;\r
+\r
+/* PROTO_LIST is defined depending on how PROTOTYPES is defined above.\r
+If using PROTOTYPES, then PROTO_LIST returns the list, otherwise it\r
+  returns an empty list.\r
+ */\r
+#define PROTO_LIST(list) list\r
+\r
+/* MD5 context. */\r
+typedef struct {\r
+  UINT4 state[4];                                   /* state (ABCD) */\r
+  UINT4 count[2];        /* number of bits, modulo 2^64 (lsb first) */\r
+  unsigned char buffer[64];                         /* input buffer */\r
+} MD5_CTX;\r
+\r
+void MD5Init PROTO_LIST ((MD5_CTX *));\r
+void MD5Update PROTO_LIST\r
+  ((MD5_CTX *, unsigned char *, unsigned int));\r
+void MD5Final PROTO_LIST ((unsigned char [16], MD5_CTX *));\r