md4.h (1099B)
1 /* vim:set ts=2 sw=2 et cindent: */ 2 /* This Source Code Form is subject to the terms of the Mozilla Public 3 * License, v. 2.0. If a copy of the MPL was not distributed with this 4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ 5 6 #ifndef md4_h__ 7 #define md4_h__ 8 9 #ifdef __cplusplus 10 extern "C" { 11 #endif 12 13 #include <stdint.h> 14 15 /** 16 * md4sum - computes the MD4 sum over the input buffer per RFC 1320 17 * 18 * @param input 19 * buffer containing input data 20 * @param inputLen 21 * length of input buffer (number of bytes) 22 * @param result 23 * 16-byte buffer that will contain the MD4 sum upon return 24 * 25 * NOTE: MD4 is superceded by MD5. do not use MD4 unless required by the 26 * protocol you are implementing (e.g., NTLM requires MD4). 27 * 28 * NOTE: this interface is designed for relatively small buffers. A streaming 29 * interface would make more sense if that were a requirement. Currently, this 30 * is good enough for the applications we care about. 31 */ 32 void md4sum(const uint8_t* input, uint32_t inputLen, uint8_t* result); 33 34 #ifdef __cplusplus 35 } 36 #endif 37 38 #endif /* md4_h__ */