CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
hrydgard

CoCalc provides the best real-time collaborative environment for Jupyter Notebooks, LaTeX documents, and SageMath, scalable from individual users to large groups and classes!

GitHub Repository: hrydgard/ppsspp
Path: blob/master/ext/libkirk/SHA1.h
Views: 1401
1
#ifndef _GLOBAL_H_
2
#define _GLOBAL_H_ 1
3
4
/* POINTER defines a generic pointer type */
5
typedef unsigned char *POINTER;
6
7
/* UINT4 defines a four byte word */
8
typedef unsigned int UINT4;
9
10
/* BYTE defines a unsigned character */
11
typedef unsigned char BYTE;
12
13
#ifndef TRUE
14
#define FALSE 0
15
#define TRUE ( !FALSE )
16
#endif /* TRUE */
17
18
#endif /* end _GLOBAL_H_ */
19
20
/* sha.h */
21
22
#ifndef _SHA_H_
23
#define _SHA_H_ 1
24
25
/* #include "global.h" */
26
27
/* The structure for storing SHS info */
28
29
typedef struct
30
{
31
UINT4 digest[ 5 ]; /* Message digest */
32
UINT4 countLo, countHi; /* 64-bit bit count */
33
UINT4 data[ 16 ]; /* SHS data buffer */
34
int Endianness;
35
} SHA_CTX;
36
37
/* Message digest functions */
38
39
void SHAInit(SHA_CTX *);
40
void SHAUpdate(SHA_CTX *, BYTE *buffer, int count);
41
void SHAFinal(BYTE *output, SHA_CTX *);
42
43
#endif /* end _SHA_H_ */
44
45
/* endian.h */
46
47
#ifndef _ENDIAN_H_
48
#define _ENDIAN_H_ 1
49
50
void endianTest(int *endianness);
51
52
#endif /* end _ENDIAN_H_ */
53
54