forked from greendow/Hash-DRBG
-
Notifications
You must be signed in to change notification settings - Fork 0
/
test_hash_drbg.h
68 lines (60 loc) · 2.47 KB
/
test_hash_drbg.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
/**************************************************
* File name: test_hash_drbg.h
* Author: HAN Wei
* Author's blog: https://blog.csdn.net/henter/
* Date: Feb 10th, 2019
* Description: declare hash DRBG test functions
**************************************************/
#ifndef HEADER_HASH_DRBG_TEST_FUNCTIONS_H
#define HEADER_HASH_DRBG_TEST_FUNCTIONS_H
#ifdef __cplusplus
extern "C" {
#endif
/**************************************************
* Name: test_sha256_hash_drbg_without_prediction_resistance
* Function: evaluate Hash_DRBG output based on SHA-256
* Return value:
0: function executes successfully
any other value: an error occurs
* Notes:
Test data are excerpted from the document provided by NIST.
See test_data_1.txt for details.
**************************************************/
int test_sha256_hash_drbg_without_prediction_resistance(void);
/**************************************************
* Name: test_sha256_hash_drbg_with_prediction_resistance
* Function: evaluate Hash_DRBG output based on SHA-256
* Return value:
0: function executes successfully
any other value: an error occurs
* Notes:
Test data are excerpted from the document provided by NIST.
See test_data_2.txt for details.
**************************************************/
int test_sha256_hash_drbg_with_prediction_resistance(void);
/**************************************************
* Name: test_sha512_hash_drbg_without_prediction_resistance
* Function: evaluate Hash_DRBG output based on SHA-512
* Return value:
0: function executes successfully
any other value: an error occurs
* Notes:
Test data are excerpted from the document provided by NIST.
See test_data_3.txt for details.
**************************************************/
int test_sha512_hash_drbg_without_prediction_resistance(void);
/**************************************************
* Name: test_sha512_hash_drbg_with_prediction_resistance
* Function: evaluate Hash_DRBG output based on SHA-512
* Return value:
0: function executes successfully
any other value: an error occurs
* Notes:
Test data are excerpted from the document provided by NIST.
See test_data_4.txt for details.
**************************************************/
int test_sha512_hash_drbg_with_prediction_resistance(void);
#ifdef __cplusplus
}
#endif
#endif /* end of HEADER_HASH_DRBG_TEST_FUNCTIONS_H */