xref: /freebsd/crypto/krb5/src/ccapi/test/test_ccapi_ccache.h (revision 7f2fe78b9dd5f51c821d771b63d2e096f6fd49e9)
1*7f2fe78bSCy Schubert #ifndef _TEST_CCAPI_CCACHE_H_
2*7f2fe78bSCy Schubert #define _TEST_CCAPI_CCACHE_H_
3*7f2fe78bSCy Schubert 
4*7f2fe78bSCy Schubert #include "test_ccapi_globals.h"
5*7f2fe78bSCy Schubert 
6*7f2fe78bSCy Schubert int check_cc_ccache_release(void);
7*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_release(cc_context_t context, cc_ccache_t ccache, cc_int32 expected_err, const char *description);
8*7f2fe78bSCy Schubert int check_cc_ccache_destroy(void);
9*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_destroy(cc_context_t context, cc_ccache_t ccache, cc_int32 expected_err, const char *description);
10*7f2fe78bSCy Schubert int check_cc_ccache_set_default(void);
11*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_set_default(cc_context_t context, cc_ccache_t ccache, cc_int32 expected_err, const char *description);
12*7f2fe78bSCy Schubert int check_cc_ccache_get_credentials_version(void);
13*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_get_credentials_version(cc_ccache_t ccache, cc_uint32 expected_cred_vers, cc_int32 expected_err, const char *description);
14*7f2fe78bSCy Schubert int check_cc_ccache_get_name(void);
15*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_get_name(cc_ccache_t ccache, const char *expected_name, cc_int32 expected_err, const char *description);
16*7f2fe78bSCy Schubert int check_cc_ccache_get_principal(void);
17*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_get_principal(cc_ccache_t ccache, cc_uint32 cred_vers, const char *expected_principal, cc_int32 expected_err, const char *description);
18*7f2fe78bSCy Schubert int check_cc_ccache_set_principal(void);
19*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_set_principal(cc_ccache_t ccache, cc_uint32 cred_vers, const char *in_principal, cc_int32 expected_err, const char *description);
20*7f2fe78bSCy Schubert 
21*7f2fe78bSCy Schubert int check_cc_ccache_store_credentials(void);
22*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_store_credentials(cc_ccache_t ccache, const cc_credentials_union *credentials, cc_int32 expected_err, const char *description);
23*7f2fe78bSCy Schubert int check_cc_ccache_remove_credentials(void);
24*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_remove_credentials(cc_ccache_t ccache, cc_credentials_t in_creds, cc_int32 expected_err, const char *description);
25*7f2fe78bSCy Schubert 
26*7f2fe78bSCy Schubert int check_cc_ccache_new_credentials_iterator(void);
27*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_new_credentials_iterator(cc_ccache_t ccache, cc_credentials_iterator_t *iterator, cc_int32 expected_err, const char *description);
28*7f2fe78bSCy Schubert 
29*7f2fe78bSCy Schubert int check_cc_ccache_get_change_time(void);
30*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_get_change_time(cc_ccache_t ccache, cc_time_t *last_time, cc_int32 expected_err, const char *description);
31*7f2fe78bSCy Schubert int check_cc_ccache_get_last_default_time(void);
32*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_get_last_default_time(cc_ccache_t ccache, cc_time_t *last_time, cc_int32 expected_err, const char *description);
33*7f2fe78bSCy Schubert 
34*7f2fe78bSCy Schubert int check_cc_ccache_move(void);
35*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_move(cc_ccache_t source, cc_ccache_t destination, cc_int32 expected_err, const char *description);
36*7f2fe78bSCy Schubert 
37*7f2fe78bSCy Schubert int check_cc_ccache_compare(void);
38*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_compare(cc_ccache_t ccache, cc_ccache_t compare_to, cc_uint32 *equal, cc_int32 expected_err, const char *description);
39*7f2fe78bSCy Schubert 
40*7f2fe78bSCy Schubert int check_cc_ccache_get_kdc_time_offset(void);
41*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_get_kdc_time_offset(cc_ccache_t ccache, cc_int32 credentials_version, cc_time_t *time_offset, cc_int32 expected_err, const char *description);
42*7f2fe78bSCy Schubert 
43*7f2fe78bSCy Schubert int check_cc_ccache_set_kdc_time_offset(void);
44*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_set_kdc_time_offset(cc_ccache_t ccache, cc_int32 credentials_version, cc_time_t time_offset, cc_int32 expected_err, const char *description);
45*7f2fe78bSCy Schubert 
46*7f2fe78bSCy Schubert int check_cc_ccache_clear_kdc_time_offset(void);
47*7f2fe78bSCy Schubert cc_int32 check_once_cc_ccache_clear_kdc_time_offset(cc_ccache_t ccache, cc_int32 credentials_version, cc_int32 expected_err, const char *description);
48*7f2fe78bSCy Schubert 
49*7f2fe78bSCy Schubert #endif /* _TEST_CCAPI_CCACHE_H_ */
50