1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/security/manager/ssl/src/md4.h Wed Dec 31 06:09:35 2014 +0100 1.3 @@ -0,0 +1,38 @@ 1.4 +/* vim:set ts=2 sw=2 et cindent: */ 1.5 +/* This Source Code Form is subject to the terms of the Mozilla Public 1.6 + * License, v. 2.0. If a copy of the MPL was not distributed with this 1.7 + * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 1.8 + 1.9 +#ifndef md4_h__ 1.10 +#define md4_h__ 1.11 + 1.12 +#ifdef __cplusplus 1.13 +extern "C" { 1.14 +#endif 1.15 + 1.16 +#include <stdint.h> 1.17 + 1.18 +/** 1.19 + * md4sum - computes the MD4 sum over the input buffer per RFC 1320 1.20 + * 1.21 + * @param input 1.22 + * buffer containing input data 1.23 + * @param inputLen 1.24 + * length of input buffer (number of bytes) 1.25 + * @param result 1.26 + * 16-byte buffer that will contain the MD4 sum upon return 1.27 + * 1.28 + * NOTE: MD4 is superceded by MD5. do not use MD4 unless required by the 1.29 + * protocol you are implementing (e.g., NTLM requires MD4). 1.30 + * 1.31 + * NOTE: this interface is designed for relatively small buffers. A streaming 1.32 + * interface would make more sense if that were a requirement. Currently, this 1.33 + * is good enough for the applications we care about. 1.34 + */ 1.35 +void md4sum(const uint8_t *input, uint32_t inputLen, uint8_t *result); 1.36 + 1.37 +#ifdef __cplusplus 1.38 +} 1.39 +#endif 1.40 + 1.41 +#endif /* md4_h__ */