]>
git.saurik.com Git - apple/security.git/blob - AppleCSP/MiscCSPAlgs/SHA1_priv.h
1 /* Copyright (c) 1998 Apple Computer, Inc. All rights reserved.
3 * NOTICE: USE OF THE MATERIALS ACCOMPANYING THIS NOTICE IS SUBJECT
4 * TO THE TERMS OF THE SIGNED "FAST ELLIPTIC ENCRYPTION (FEE) REFERENCE
5 * SOURCE CODE EVALUATION AGREEMENT" BETWEEN APPLE COMPUTER, INC. AND THE
6 * ORIGINAL LICENSEE THAT OBTAINED THESE MATERIALS FROM APPLE COMPUTER,
7 * INC. ANY USE OF THESE MATERIALS NOT PERMITTED BY SUCH AGREEMENT WILL
8 * EXPOSE YOU TO LIABILITY.
9 ***************************************************************************
11 * SHA1_priv.h - private low-level API for SHA-1 hash algorithm
15 * 22 Aug 96 Doug Mitchell at NeXT
19 /* Useful defines/typedefs */
21 #ifndef _CK_SHA1_PRIV_H_
22 #define _CK_SHA1_PRIV_H_
28 typedef unsigned char BYTE
;
29 typedef unsigned long LONG
;
31 /* The SHS block size and message digest sizes, in bytes */
33 #define SHS_BLOCKSIZE 64
34 #define SHS_DIGESTSIZE 20
36 /* The structure for storing SHS info */
39 LONG digest
[ 5 ]; /* Message digest */
40 LONG countLo
, countHi
; /* 64-bit bit count */
41 LONG data
[ 80 ]; /* SHS data buffer */
44 extern void shsInit(SHS_INFO
*shsInfo
);
45 extern void shsUpdate(SHS_INFO
*shsInfo
,
48 extern void shsFinal(SHS_INFO
*shsInfo
);
54 #endif /* _CK_SHA1_PRIV_H_ */