]>
git.saurik.com Git - apple/security.git/blob - OSX/libsecurity_cryptkit/lib/ckSHA1_priv.h
1 /* Copyright (c) 1998,2011,2014 Apple 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, INC. AND THE
6 * ORIGINAL LICENSEE THAT OBTAINED THESE MATERIALS FROM APPLE,
7 * INC. ANY USE OF THESE MATERIALS NOT PERMITTED BY SUCH AGREEMENT WILL
8 * EXPOSE YOU TO LIABILITY.
9 ***************************************************************************
11 * ckSHA1_priv.h - private low-level API for SHA-1 hash algorithm
19 /* Useful defines/typedefs */
21 #ifndef _CK_SHA1_PRIV_H_
22 #define _CK_SHA1_PRIV_H_
26 #if !CRYPTKIT_LIBMD_DIGEST
32 typedef unsigned char BYTE
;
33 typedef unsigned long LONG
;
35 /* The SHS block size and message digest sizes, in bytes */
37 #define SHS_BLOCKSIZE 64
38 #define SHS_DIGESTSIZE 20
40 /* The structure for storing SHS info */
43 LONG digest
[ 5 ]; /* Message digest */
44 LONG countLo
, countHi
; /* 64-bit bit count */
45 LONG data
[ 80 ]; /* SHS data buffer */
48 extern void shsInit(SHS_INFO
*shsInfo
);
49 extern void shsUpdate(SHS_INFO
*shsInfo
,
52 extern void shsFinal(SHS_INFO
*shsInfo
);
58 #endif /* !CRYPTKIT_LIBMD_DIGEST */
60 #endif /* _CK_SHA1_PRIV_H_ */