![](/media/cache/profiles/3f4243a6f681f2920ac3e95a63517274.50x50_q85.jpg)
code that uses Watchdog to reset Mbed every 30seconds. After 30-60mins, the ethernet interface fails to setup() after WatchDog reset.
EthernetNetIf/LPC1768/lwip/netif/ppp/md5.h@0:0ce833f21e63, 2012-06-07 (annotated)
- Committer:
- eqon
- Date:
- Thu Jun 07 05:44:29 2012 +0000
- Revision:
- 0:0ce833f21e63
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
eqon | 0:0ce833f21e63 | 1 | /* |
eqon | 0:0ce833f21e63 | 2 | *********************************************************************** |
eqon | 0:0ce833f21e63 | 3 | ** md5.h -- header file for implementation of MD5 ** |
eqon | 0:0ce833f21e63 | 4 | ** RSA Data Security, Inc. MD5 Message-Digest Algorithm ** |
eqon | 0:0ce833f21e63 | 5 | ** Created: 2/17/90 RLR ** |
eqon | 0:0ce833f21e63 | 6 | ** Revised: 12/27/90 SRD,AJ,BSK,JT Reference C version ** |
eqon | 0:0ce833f21e63 | 7 | ** Revised (for MD5): RLR 4/27/91 ** |
eqon | 0:0ce833f21e63 | 8 | ** -- G modified to have y&~z instead of y&z ** |
eqon | 0:0ce833f21e63 | 9 | ** -- FF, GG, HH modified to add in last register done ** |
eqon | 0:0ce833f21e63 | 10 | ** -- Access pattern: round 2 works mod 5, round 3 works mod 3 ** |
eqon | 0:0ce833f21e63 | 11 | ** -- distinct additive constant for each step ** |
eqon | 0:0ce833f21e63 | 12 | ** -- round 4 added, working mod 7 ** |
eqon | 0:0ce833f21e63 | 13 | *********************************************************************** |
eqon | 0:0ce833f21e63 | 14 | */ |
eqon | 0:0ce833f21e63 | 15 | |
eqon | 0:0ce833f21e63 | 16 | /* |
eqon | 0:0ce833f21e63 | 17 | *********************************************************************** |
eqon | 0:0ce833f21e63 | 18 | ** Copyright (C) 1990, RSA Data Security, Inc. All rights reserved. ** |
eqon | 0:0ce833f21e63 | 19 | ** ** |
eqon | 0:0ce833f21e63 | 20 | ** License to copy and use this software is granted provided that ** |
eqon | 0:0ce833f21e63 | 21 | ** it is identified as the "RSA Data Security, Inc. MD5 Message- ** |
eqon | 0:0ce833f21e63 | 22 | ** Digest Algorithm" in all material mentioning or referencing this ** |
eqon | 0:0ce833f21e63 | 23 | ** software or this function. ** |
eqon | 0:0ce833f21e63 | 24 | ** ** |
eqon | 0:0ce833f21e63 | 25 | ** License is also granted to make and use derivative works ** |
eqon | 0:0ce833f21e63 | 26 | ** provided that such works are identified as "derived from the RSA ** |
eqon | 0:0ce833f21e63 | 27 | ** Data Security, Inc. MD5 Message-Digest Algorithm" in all ** |
eqon | 0:0ce833f21e63 | 28 | ** material mentioning or referencing the derived work. ** |
eqon | 0:0ce833f21e63 | 29 | ** ** |
eqon | 0:0ce833f21e63 | 30 | ** RSA Data Security, Inc. makes no representations concerning ** |
eqon | 0:0ce833f21e63 | 31 | ** either the merchantability of this software or the suitability ** |
eqon | 0:0ce833f21e63 | 32 | ** of this software for any particular purpose. It is provided "as ** |
eqon | 0:0ce833f21e63 | 33 | ** is" without express or implied warranty of any kind. ** |
eqon | 0:0ce833f21e63 | 34 | ** ** |
eqon | 0:0ce833f21e63 | 35 | ** These notices must be retained in any copies of any part of this ** |
eqon | 0:0ce833f21e63 | 36 | ** documentation and/or software. ** |
eqon | 0:0ce833f21e63 | 37 | *********************************************************************** |
eqon | 0:0ce833f21e63 | 38 | */ |
eqon | 0:0ce833f21e63 | 39 | |
eqon | 0:0ce833f21e63 | 40 | #ifndef MD5_H |
eqon | 0:0ce833f21e63 | 41 | #define MD5_H |
eqon | 0:0ce833f21e63 | 42 | |
eqon | 0:0ce833f21e63 | 43 | /* Data structure for MD5 (Message-Digest) computation */ |
eqon | 0:0ce833f21e63 | 44 | typedef struct { |
eqon | 0:0ce833f21e63 | 45 | u32_t i[2]; /* number of _bits_ handled mod 2^64 */ |
eqon | 0:0ce833f21e63 | 46 | u32_t buf[4]; /* scratch buffer */ |
eqon | 0:0ce833f21e63 | 47 | unsigned char in[64]; /* input buffer */ |
eqon | 0:0ce833f21e63 | 48 | unsigned char digest[16]; /* actual digest after MD5Final call */ |
eqon | 0:0ce833f21e63 | 49 | } MD5_CTX; |
eqon | 0:0ce833f21e63 | 50 | |
eqon | 0:0ce833f21e63 | 51 | void MD5Init ( MD5_CTX *mdContext); |
eqon | 0:0ce833f21e63 | 52 | void MD5Update( MD5_CTX *mdContext, unsigned char *inBuf, unsigned int inLen); |
eqon | 0:0ce833f21e63 | 53 | void MD5Final ( unsigned char hash[], MD5_CTX *mdContext); |
eqon | 0:0ce833f21e63 | 54 | |
eqon | 0:0ce833f21e63 | 55 | #endif /* MD5_H */ |