]> git.sur5r.net Git - openldap/blob - include/lutil_sha1.h
Wrap $CC with quotes.
[openldap] / include / lutil_sha1.h
1 /* This version is based on:
2  *      $OpenBSD: sha1.h,v 1.8 1997/07/15 01:54:23 millert Exp $        */
3
4 /*
5  * SHA-1 in C
6  * By Steve Reid <steve@edmweb.com>
7  * 100% Public Domain
8  */
9
10 /* XXX   I wonder if this will work on 64bit architectures... */
11 #ifndef LDAP_UINT32
12 #define LDAP_UINT32
13 typedef unsigned long uint32;
14 #endif
15
16 typedef struct {
17     uint32 state[5];
18     uint32 count[2];  
19     unsigned char buffer[64];
20 } SHA1_CTX;
21   
22 void ldap_SHA1Transform __P((uint32 state[5], const unsigned char buffer[64]));
23 void ldap_SHA1Init __P((SHA1_CTX *context));
24 void ldap_SHA1Update __P((SHA1_CTX *context, const unsigned char *data, u_int len));
25 void ldap_SHA1Final __P((unsigned char digest[20], SHA1_CTX *context));
26 char *ldap_SHA1End __P((SHA1_CTX *, char *));
27 char *ldap_SHA1File __P((char *, char *));
28 char *ldap_SHA1Data __P((const unsigned char *, size_t, char *));