EthernetNetIf

Dependents:   XBee_WiFi_EA_LPC4088

Committer:
hmike
Date:
Wed Nov 19 12:00:42 2014 +0000
Revision:
0:62580107d20c
EthernetNetIf

Who changed what in which revision?

UserRevisionLine numberNew contents of line
hmike 0:62580107d20c 1 /*
hmike 0:62580107d20c 2 ***********************************************************************
hmike 0:62580107d20c 3 ** md5.h -- header file for implementation of MD5 **
hmike 0:62580107d20c 4 ** RSA Data Security, Inc. MD5 Message-Digest Algorithm **
hmike 0:62580107d20c 5 ** Created: 2/17/90 RLR **
hmike 0:62580107d20c 6 ** Revised: 12/27/90 SRD,AJ,BSK,JT Reference C version **
hmike 0:62580107d20c 7 ** Revised (for MD5): RLR 4/27/91 **
hmike 0:62580107d20c 8 ** -- G modified to have y&~z instead of y&z **
hmike 0:62580107d20c 9 ** -- FF, GG, HH modified to add in last register done **
hmike 0:62580107d20c 10 ** -- Access pattern: round 2 works mod 5, round 3 works mod 3 **
hmike 0:62580107d20c 11 ** -- distinct additive constant for each step **
hmike 0:62580107d20c 12 ** -- round 4 added, working mod 7 **
hmike 0:62580107d20c 13 ***********************************************************************
hmike 0:62580107d20c 14 */
hmike 0:62580107d20c 15
hmike 0:62580107d20c 16 /*
hmike 0:62580107d20c 17 ***********************************************************************
hmike 0:62580107d20c 18 ** Copyright (C) 1990, RSA Data Security, Inc. All rights reserved. **
hmike 0:62580107d20c 19 ** **
hmike 0:62580107d20c 20 ** License to copy and use this software is granted provided that **
hmike 0:62580107d20c 21 ** it is identified as the "RSA Data Security, Inc. MD5 Message- **
hmike 0:62580107d20c 22 ** Digest Algorithm" in all material mentioning or referencing this **
hmike 0:62580107d20c 23 ** software or this function. **
hmike 0:62580107d20c 24 ** **
hmike 0:62580107d20c 25 ** License is also granted to make and use derivative works **
hmike 0:62580107d20c 26 ** provided that such works are identified as "derived from the RSA **
hmike 0:62580107d20c 27 ** Data Security, Inc. MD5 Message-Digest Algorithm" in all **
hmike 0:62580107d20c 28 ** material mentioning or referencing the derived work. **
hmike 0:62580107d20c 29 ** **
hmike 0:62580107d20c 30 ** RSA Data Security, Inc. makes no representations concerning **
hmike 0:62580107d20c 31 ** either the merchantability of this software or the suitability **
hmike 0:62580107d20c 32 ** of this software for any particular purpose. It is provided "as **
hmike 0:62580107d20c 33 ** is" without express or implied warranty of any kind. **
hmike 0:62580107d20c 34 ** **
hmike 0:62580107d20c 35 ** These notices must be retained in any copies of any part of this **
hmike 0:62580107d20c 36 ** documentation and/or software. **
hmike 0:62580107d20c 37 ***********************************************************************
hmike 0:62580107d20c 38 */
hmike 0:62580107d20c 39
hmike 0:62580107d20c 40 #ifndef MD5_H
hmike 0:62580107d20c 41 #define MD5_H
hmike 0:62580107d20c 42
hmike 0:62580107d20c 43 /* Data structure for MD5 (Message-Digest) computation */
hmike 0:62580107d20c 44 typedef struct {
hmike 0:62580107d20c 45 u32_t i[2]; /* number of _bits_ handled mod 2^64 */
hmike 0:62580107d20c 46 u32_t buf[4]; /* scratch buffer */
hmike 0:62580107d20c 47 unsigned char in[64]; /* input buffer */
hmike 0:62580107d20c 48 unsigned char digest[16]; /* actual digest after MD5Final call */
hmike 0:62580107d20c 49 } MD5_CTX;
hmike 0:62580107d20c 50
hmike 0:62580107d20c 51 void MD5Init ( MD5_CTX *mdContext);
hmike 0:62580107d20c 52 void MD5Update( MD5_CTX *mdContext, unsigned char *inBuf, unsigned int inLen);
hmike 0:62580107d20c 53 void MD5Final ( unsigned char hash[], MD5_CTX *mdContext);
hmike 0:62580107d20c 54
hmike 0:62580107d20c 55 #endif /* MD5_H */