source: trunk/src/secur32/hmac_md5.h@ 22015

Last change on this file since 22015 was 21364, checked in by vladest, 16 years ago
  • Added SSP DLLs loader. Still under development. Do not use in working configurations
File size: 1.5 KB
Line 
1/*
2 * Copyright 2006 Kai Blin
3 *
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
8 *
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
13 *
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
17 *
18 * This file holds the declarations needed for HMAC-MD5.
19 */
20
21#ifndef _HMAC_MD5_H_
22#define _HMAC_MD5_H_
23
24#include <string.h>
25#include "windef.h"
26
27typedef struct
28{
29 unsigned int i[2];
30 unsigned int buf[4];
31 unsigned char in[64];
32 unsigned char digest[16];
33} MD5_CTX;
34
35typedef struct
36{
37 MD5_CTX ctx;
38 unsigned char outer_padding[64];
39} HMAC_MD5_CTX;
40
41void WINAPI MD5Init( MD5_CTX *ctx );
42void WINAPI MD5Update( MD5_CTX *ctx, const unsigned char *buf, unsigned int len );
43void WINAPI MD5Final( MD5_CTX *ctx );
44
45void HMACMD5Init(HMAC_MD5_CTX *ctx, const unsigned char *key, unsigned int key_len);
46void HMACMD5Update(HMAC_MD5_CTX *ctx, const unsigned char *data, unsigned int data_len);
47void HMACMD5Final(HMAC_MD5_CTX *ctx, unsigned char *digest);
48#endif /*_HMAC_MD5_H_*/
Note: See TracBrowser for help on using the repository browser.