6 #define CRYPTOKI_VERSION_MAJOR 3
7 #define CRYPTOKI_VERSION_MINOR 1
8 #define CRYPTOKI_VERSION_AMENDMENT 0
11 typedef unsigned char CK_BBOOL;
12 typedef unsigned char CK_BYTE;
13 typedef unsigned char CK_CHAR;
14 typedef unsigned char CK_UTF8CHAR;
15 typedef unsigned long int CK_ULONG;
17 typedef CK_BBOOL * CK_BBOOL_PTR;
18 typedef CK_BYTE * CK_BYTE_PTR;
19 typedef CK_CHAR * CK_CHAR_PTR;
20 typedef CK_UTF8CHAR * CK_UTF8CHAR_PTR;
21 typedef CK_ULONG * CK_ULONG_PTR;
24 #define NULL_PTR ((void *)0)
25 typedef void * CK_VOID_PTR;
26 typedef void ** CK_VOID_PTR_PTR;
28 #define CK_EFFECTIVELY_INFINITE 0UL
29 #define CK_UNAVAILABLE_INFORMATION ~0UL
30 #define CK_INVALID_HANDLE 0UL
35 #define ULONGDEF(__name__) \
36 typedef CK_ULONG __name__; \
37 typedef __name__ * __name__ ## _PTR;
39 ULONGDEF(CK_ATTRIBUTE_TYPE)
40 ULONGDEF(CK_CERTIFICATE_CATEGORY)
41 ULONGDEF(CK_CERTIFICATE_TYPE)
42 ULONGDEF(CK_EC_KDF_TYPE)
43 ULONGDEF(CK_EXTRACT_PARAMS)
45 ULONGDEF(CK_GENERATOR_FUNCTION)
46 ULONGDEF(CK_HSS_LEVELS)
47 ULONGDEF(CK_HW_FEATURE_TYPE)
48 ULONGDEF(CK_JAVA_MIDP_SECURITY_DOMAIN)
51 ULONGDEF(CK_LMOTS_TYPE)
52 ULONGDEF(CK_MAC_GENERAL_PARAMS)
53 ULONGDEF(CK_MECHANISM_TYPE)
54 ULONGDEF(CK_NOTIFICATION)
55 ULONGDEF(CK_OBJECT_CLASS)
56 ULONGDEF(CK_OBJECT_HANDLE)
57 ULONGDEF(CK_OTP_PARAM_TYPE)
58 ULONGDEF(CK_PKCS5_PBKD2_PSEUDO_RANDOM_FUNCTION_TYPE)
59 ULONGDEF(CK_PKCS5_PBKDF2_SALT_SOURCE_TYPE)
60 ULONGDEF(CK_PRF_DATA_TYPE)
61 ULONGDEF(CK_PROFILE_ID)
62 ULONGDEF(CK_RC2_PARAMS)
63 ULONGDEF(CK_RSA_PKCS_MGF_TYPE)
64 ULONGDEF(CK_RSA_PKCS_OAEP_SOURCE_TYPE)
66 ULONGDEF(CK_SESSION_HANDLE)
68 ULONGDEF(CK_SP800_108_DKM_LENGTH_METHOD)
70 ULONGDEF(CK_USER_TYPE)
71 ULONGDEF(CK_X2RATCHET_KDF_TYPE)
72 ULONGDEF(CK_X3DH_KDF_TYPE)
73 ULONGDEF(CK_X9_42_DH_KDF_TYPE)
74 ULONGDEF(CK_XEDDSA_HASH_TYPE)
79 #define CK_CERTIFICATE_CATEGORY_UNSPECIFIED 0UL
80 #define CK_CERTIFICATE_CATEGORY_TOKEN_USER 1UL
81 #define CK_CERTIFICATE_CATEGORY_AUTHORITY 2UL
82 #define CK_CERTIFICATE_CATEGORY_OTHER_ENTITY 3UL
85 #define CK_OTP_VALUE 0UL
86 #define CK_OTP_PIN 1UL
87 #define CK_OTP_CHALLENGE 2UL
88 #define CK_OTP_TIME 3UL
89 #define CK_OTP_COUNTER 4UL
90 #define CK_OTP_FLAGS 5UL
91 #define CK_OTP_OUTPUT_LENGTH 6UL
92 #define CK_OTP_OUTPUT_FORMAT 7UL
95 #define CK_OTP_FORMAT_DECIMAL 0UL
96 #define CK_OTP_FORMAT_HEXADECIMAL 1UL
97 #define CK_OTP_FORMAT_ALPHANUMERIC 2UL
98 #define CK_OTP_FORMAT_BINARY 3UL
101 #define CK_OTP_PARAM_IGNORED 0UL
102 #define CK_OTP_PARAM_OPTIONAL 1UL
103 #define CK_OTP_PARAM_MANDATORY 2UL
106 #define CK_SECURITY_DOMAIN_UNSPECIFIED 0UL
107 #define CK_SECURITY_DOMAIN_MANUFACTURER 1UL
108 #define CK_SECURITY_DOMAIN_OPERATOR 2UL
109 #define CK_SECURITY_DOMAIN_THIRD_PARTY 3UL
112 #define CK_SP800_108_ITERATION_VARIABLE 0x00000001UL
113 #define CK_SP800_108_OPTIONAL_COUNTER 0x00000002UL
114 #define CK_SP800_108_COUNTER 0x00000002UL
115 #define CK_SP800_108_DKM_LENGTH 0x00000003UL
116 #define CK_SP800_108_BYTE_ARRAY 0x00000004UL
119 #define CK_SP800_108_DKM_LENGTH_SUM_OF_KEYS 0x00000001UL
120 #define CK_SP800_108_DKM_LENGTH_SUM_OF_SEGMENTS 0x00000002UL
123 #define CKA_CLASS 0x00000000UL
124 #define CKA_TOKEN 0x00000001UL
125 #define CKA_PRIVATE 0x00000002UL
126 #define CKA_LABEL 0x00000003UL
127 #define CKA_UNIQUE_ID 0x00000004UL
128 #define CKA_APPLICATION 0x00000010UL
129 #define CKA_VALUE 0x00000011UL
130 #define CKA_OBJECT_ID 0x00000012UL
131 #define CKA_CERTIFICATE_TYPE 0x00000080UL
132 #define CKA_ISSUER 0x00000081UL
133 #define CKA_SERIAL_NUMBER 0x00000082UL
134 #define CKA_AC_ISSUER 0x00000083UL
135 #define CKA_OWNER 0x00000084UL
136 #define CKA_ATTR_TYPES 0x00000085UL
137 #define CKA_TRUSTED 0x00000086UL
138 #define CKA_CERTIFICATE_CATEGORY 0x00000087UL
139 #define CKA_JAVA_MIDP_SECURITY_DOMAIN 0x00000088UL
140 #define CKA_URL 0x00000089UL
141 #define CKA_HASH_OF_SUBJECT_PUBLIC_KEY 0x0000008AUL
142 #define CKA_HASH_OF_ISSUER_PUBLIC_KEY 0x0000008BUL
143 #define CKA_NAME_HASH_ALGORITHM 0x0000008CUL
144 #define CKA_CHECK_VALUE 0x00000090UL
145 #define CKA_KEY_TYPE 0x00000100UL
146 #define CKA_SUBJECT 0x00000101UL
147 #define CKA_ID 0x00000102UL
148 #define CKA_SENSITIVE 0x00000103UL
149 #define CKA_ENCRYPT 0x00000104UL
150 #define CKA_DECRYPT 0x00000105UL
151 #define CKA_WRAP 0x00000106UL
152 #define CKA_UNWRAP 0x00000107UL
153 #define CKA_SIGN 0x00000108UL
154 #define CKA_SIGN_RECOVER 0x00000109UL
155 #define CKA_VERIFY 0x0000010AUL
156 #define CKA_VERIFY_RECOVER 0x0000010BUL
157 #define CKA_DERIVE 0x0000010CUL
158 #define CKA_START_DATE 0x00000110UL
159 #define CKA_END_DATE 0x00000111UL
160 #define CKA_MODULUS 0x00000120UL
161 #define CKA_MODULUS_BITS 0x00000121UL
162 #define CKA_PUBLIC_EXPONENT 0x00000122UL
163 #define CKA_PRIVATE_EXPONENT 0x00000123UL
164 #define CKA_PRIME_1 0x00000124UL
165 #define CKA_PRIME_2 0x00000125UL
166 #define CKA_EXPONENT_1 0x00000126UL
167 #define CKA_EXPONENT_2 0x00000127UL
168 #define CKA_COEFFICIENT 0x00000128UL
169 #define CKA_PUBLIC_KEY_INFO 0x00000129UL
170 #define CKA_PRIME 0x00000130UL
171 #define CKA_SUBPRIME 0x00000131UL
172 #define CKA_BASE 0x00000132UL
173 #define CKA_PRIME_BITS 0x00000133UL
174 #define CKA_SUBPRIME_BITS 0x00000134UL
175 #define CKA_SUB_PRIME_BITS 0x00000134UL
176 #define CKA_VALUE_BITS 0x00000160UL
177 #define CKA_VALUE_LEN 0x00000161UL
178 #define CKA_EXTRACTABLE 0x00000162UL
179 #define CKA_LOCAL 0x00000163UL
180 #define CKA_NEVER_EXTRACTABLE 0x00000164UL
181 #define CKA_ALWAYS_SENSITIVE 0x00000165UL
182 #define CKA_KEY_GEN_MECHANISM 0x00000166UL
183 #define CKA_MODIFIABLE 0x00000170UL
184 #define CKA_COPYABLE 0x00000171UL
185 #define CKA_DESTROYABLE 0x00000172UL
186 #define CKA_EC_PARAMS 0x00000180UL
187 #define CKA_EC_POINT 0x00000181UL
188 #define CKA_ALWAYS_AUTHENTICATE 0x00000202UL
189 #define CKA_WRAP_WITH_TRUSTED 0x00000210UL
190 #define CKA_OTP_FORMAT 0x00000220UL
191 #define CKA_OTP_LENGTH 0x00000221UL
192 #define CKA_OTP_TIME_INTERVAL 0x00000222UL
193 #define CKA_OTP_USER_FRIENDLY_MODE 0x00000223UL
194 #define CKA_OTP_CHALLENGE_REQUIREMENT 0x00000224UL
195 #define CKA_OTP_TIME_REQUIREMENT 0x00000225UL
196 #define CKA_OTP_COUNTER_REQUIREMENT 0x00000226UL
197 #define CKA_OTP_PIN_REQUIREMENT 0x00000227UL
198 #define CKA_OTP_COUNTER 0x0000022EUL
199 #define CKA_OTP_TIME 0x0000022FUL
200 #define CKA_OTP_USER_IDENTIFIER 0x0000022AUL
201 #define CKA_OTP_SERVICE_IDENTIFIER 0x0000022BUL
202 #define CKA_OTP_SERVICE_LOGO 0x0000022CUL
203 #define CKA_OTP_SERVICE_LOGO_TYPE 0x0000022DUL
204 #define CKA_GOSTR3410_PARAMS 0x00000250UL
205 #define CKA_GOSTR3411_PARAMS 0x00000251UL
206 #define CKA_GOST28147_PARAMS 0x00000252UL
207 #define CKA_HW_FEATURE_TYPE 0x00000300UL
208 #define CKA_RESET_ON_INIT 0x00000301UL
209 #define CKA_HAS_RESET 0x00000302UL
210 #define CKA_PIXEL_X 0x00000400UL
211 #define CKA_PIXEL_Y 0x00000401UL
212 #define CKA_RESOLUTION 0x00000402UL
213 #define CKA_CHAR_ROWS 0x00000403UL
214 #define CKA_CHAR_COLUMNS 0x00000404UL
215 #define CKA_COLOR 0x00000405UL
216 #define CKA_BITS_PER_PIXEL 0x00000406UL
217 #define CKA_CHAR_SETS 0x00000480UL
218 #define CKA_ENCODING_METHODS 0x00000481UL
219 #define CKA_MIME_TYPES 0x00000482UL
220 #define CKA_MECHANISM_TYPE 0x00000500UL
221 #define CKA_REQUIRED_CMS_ATTRIBUTES 0x00000501UL
222 #define CKA_DEFAULT_CMS_ATTRIBUTES 0x00000502UL
223 #define CKA_SUPPORTED_CMS_ATTRIBUTES 0x00000503UL
224 #define CKA_PROFILE_ID 0x00000601UL
225 #define CKA_X2RATCHET_BAG 0x00000602UL
226 #define CKA_X2RATCHET_BAGSIZE 0x00000603UL
227 #define CKA_X2RATCHET_BOBS1STMSG 0x00000604UL
228 #define CKA_X2RATCHET_CKR 0x00000605UL
229 #define CKA_X2RATCHET_CKS 0x00000606UL
230 #define CKA_X2RATCHET_DHP 0x00000607UL
231 #define CKA_X2RATCHET_DHR 0x00000608UL
232 #define CKA_X2RATCHET_DHS 0x00000609UL
233 #define CKA_X2RATCHET_HKR 0x0000060AUL
234 #define CKA_X2RATCHET_HKS 0x0000060BUL
235 #define CKA_X2RATCHET_ISALICE 0x0000060CUL
236 #define CKA_X2RATCHET_NHKR 0x0000060DUL
237 #define CKA_X2RATCHET_NHKS 0x0000060EUL
238 #define CKA_X2RATCHET_NR 0x0000060FUL
239 #define CKA_X2RATCHET_NS 0x00000610UL
240 #define CKA_X2RATCHET_PNS 0x00000611UL
241 #define CKA_X2RATCHET_RK 0x00000612UL
242 #define CKA_HSS_LEVELS 0x00000617UL
243 #define CKA_HSS_LMS_TYPE 0x00000618UL
244 #define CKA_HSS_LMOTS_TYPE 0x00000619UL
245 #define CKA_HSS_LMS_TYPES 0x0000061AUL
246 #define CKA_HSS_LMOTS_TYPES 0x0000061BUL
247 #define CKA_HSS_KEYS_REMAINING 0x0000061CUL
248 #define CKA_VENDOR_DEFINED 0x80000000UL
250 #define CKA_WRAP_TEMPLATE 0x40000211UL
251 #define CKA_UNWRAP_TEMPLATE 0x40000212UL
252 #define CKA_DERIVE_TEMPLATE 0x40000213UL
253 #define CKA_ALLOWED_MECHANISMS 0x40000600UL
255 #ifdef PKCS11_DEPRECATED
256 #define CKA_ECDSA_PARAMS 0x00000180UL
257 #define CKA_SECONDARY_AUTH 0x00000200UL
258 #define CKA_AUTH_PIN_FLAGS 0x00000201UL
262 #define CKC_X_509 0x00000000UL
263 #define CKC_X_509_ATTR_CERT 0x00000001UL
264 #define CKC_WTLS 0x00000002UL
265 #define CKC_VENDOR_DEFINED 0x80000000UL
268 #define CKD_NULL 0x00000001UL
269 #define CKD_SHA1_KDF 0x00000002UL
270 #define CKD_SHA1_KDF_ASN1 0x00000003UL
271 #define CKD_SHA1_KDF_CONCATENATE 0x00000004UL
272 #define CKD_SHA224_KDF 0x00000005UL
273 #define CKD_SHA256_KDF 0x00000006UL
274 #define CKD_SHA384_KDF 0x00000007UL
275 #define CKD_SHA512_KDF 0x00000008UL
276 #define CKD_CPDIVERSIFY_KDF 0x00000009UL
277 #define CKD_SHA3_224_KDF 0x0000000AUL
278 #define CKD_SHA3_256_KDF 0x0000000BUL
279 #define CKD_SHA3_384_KDF 0x0000000CUL
280 #define CKD_SHA3_512_KDF 0x0000000DUL
281 #define CKD_SHA1_KDF_SP800 0x0000000EUL
282 #define CKD_SHA224_KDF_SP800 0x0000000FUL
283 #define CKD_SHA256_KDF_SP800 0x00000010UL
284 #define CKD_SHA384_KDF_SP800 0x00000011UL
285 #define CKD_SHA512_KDF_SP800 0x00000012UL
286 #define CKD_SHA3_224_KDF_SP800 0x00000013UL
287 #define CKD_SHA3_256_KDF_SP800 0x00000014UL
288 #define CKD_SHA3_384_KDF_SP800 0x00000015UL
289 #define CKD_SHA3_512_KDF_SP800 0x00000016UL
290 #define CKD_BLAKE2B_160_KDF 0x00000017UL
291 #define CKD_BLAKE2B_256_KDF 0x00000018UL
292 #define CKD_BLAKE2B_384_KDF 0x00000019UL
293 #define CKD_BLAKE2B_512_KDF 0x0000001AUL
296 #define CKF_ARRAY_ATTRIBUTE 0x40000000UL
299 #define CKF_LIBRARY_CANT_CREATE_OS_THREADS 0x00000001UL
300 #define CKF_OS_LOCKING_OK 0x00000002UL
303 #define CKF_HKDF_SALT_NULL 0x00000001UL
304 #define CKF_HKDF_SALT_DATA 0x00000002UL
305 #define CKF_HKDF_SALT_KEY 0x00000004UL
308 #define CKF_INTERFACE_FORK_SAFE 0x00000001UL
311 #define CKF_HW 0x00000001UL
312 #define CKF_MESSAGE_ENCRYPT 0x00000002UL
313 #define CKF_MESSAGE_DECRYPT 0x00000004UL
314 #define CKF_MESSAGE_SIGN 0x00000008UL
315 #define CKF_MESSAGE_VERIFY 0x00000010UL
316 #define CKF_MULTI_MESSAGE 0x00000020UL
317 #define CKF_MULTI_MESSGE 0x00000020UL
318 #define CKF_FIND_OBJECTS 0x00000040UL
319 #define CKF_ENCRYPT 0x00000100UL
320 #define CKF_DECRYPT 0x00000200UL
321 #define CKF_DIGEST 0x00000400UL
322 #define CKF_SIGN 0x00000800UL
323 #define CKF_SIGN_RECOVER 0x00001000UL
324 #define CKF_VERIFY 0x00002000UL
325 #define CKF_VERIFY_RECOVER 0x00004000UL
326 #define CKF_GENERATE 0x00008000UL
327 #define CKF_GENERATE_KEY_PAIR 0x00010000UL
328 #define CKF_WRAP 0x00020000UL
329 #define CKF_UNWRAP 0x00040000UL
330 #define CKF_DERIVE 0x00080000UL
331 #define CKF_EC_F_P 0x00100000UL
332 #define CKF_EC_F_2M 0x00200000UL
333 #define CKF_EC_ECPARAMETERS 0x00400000UL
334 #define CKF_EC_OID 0x00800000UL
335 #define CKF_EC_UNCOMPRESS 0x01000000UL
336 #define CKF_EC_COMPRESS 0x02000000UL
337 #define CKF_EC_CURVENAME 0x04000000UL
338 #define CKF_EXTENSION 0x80000000UL
340 #ifdef PKCS11_DEPRECATED
341 #define CKF_EC_NAMEDCURVE 0x00800000U
345 #define CKF_END_OF_MESSAGE 0x00000001UL
348 #define CKF_NEXT_OTP 0x00000001UL
349 #define CKF_EXCLUDE_TIME 0x00000002UL
350 #define CKF_EXCLUDE_COUNTER 0x00000004UL
351 #define CKF_EXCLUDE_CHALLENGE 0x00000008UL
352 #define CKF_EXCLUDE_PIN 0x00000010UL
353 #define CKF_USER_FRIENDLY_OTP 0x00000020UL
356 #define CKF_DONT_BLOCK 1
359 #define CKF_RW_SESSION 0x00000002UL
360 #define CKF_SERIAL_SESSION 0x00000004UL
363 #define CKF_TOKEN_PRESENT 0x00000001UL
364 #define CKF_REMOVABLE_DEVICE 0x00000002UL
365 #define CKF_HW_SLOT 0x00000004UL
368 #define CKF_RNG 0x00000001UL
369 #define CKF_WRITE_PROTECTED 0x00000002UL
370 #define CKF_LOGIN_REQUIRED 0x00000004UL
371 #define CKF_USER_PIN_INITIALIZED 0x00000008UL
372 #define CKF_RESTORE_KEY_NOT_NEEDED 0x00000020UL
373 #define CKF_CLOCK_ON_TOKEN 0x00000040UL
374 #define CKF_PROTECTED_AUTHENTICATION_PATH 0x00000100UL
375 #define CKF_DUAL_CRYPTO_OPERATIONS 0x00000200UL
376 #define CKF_TOKEN_INITIALIZED 0x00000400UL
377 #define CKF_SECONDARY_AUTHENTICATION 0x00000800UL
378 #define CKF_USER_PIN_COUNT_LOW 0x00010000UL
379 #define CKF_USER_PIN_FINAL_TRY 0x00020000UL
380 #define CKF_USER_PIN_LOCKED 0x00040000UL
381 #define CKF_USER_PIN_TO_BE_CHANGED 0x00080000UL
382 #define CKF_SO_PIN_COUNT_LOW 0x00100000UL
383 #define CKF_SO_PIN_FINAL_TRY 0x00200000UL
384 #define CKF_SO_PIN_LOCKED 0x00400000UL
385 #define CKF_SO_PIN_TO_BE_CHANGED 0x00800000UL
386 #define CKF_ERROR_STATE 0x01000000UL
389 #define CKG_NO_GENERATE 0x00000000UL
390 #define CKG_GENERATE 0x00000001UL
391 #define CKG_GENERATE_COUNTER 0x00000002UL
392 #define CKG_GENERATE_RANDOM 0x00000003UL
393 #define CKG_GENERATE_COUNTER_XOR 0x00000004UL
396 #define CKG_MGF1_SHA1 0x00000001UL
397 #define CKG_MGF1_SHA256 0x00000002UL
398 #define CKG_MGF1_SHA384 0x00000003UL
399 #define CKG_MGF1_SHA512 0x00000004UL
400 #define CKG_MGF1_SHA224 0x00000005UL
401 #define CKG_MGF1_SHA3_224 0x00000006UL
402 #define CKG_MGF1_SHA3_256 0x00000007UL
403 #define CKG_MGF1_SHA3_384 0x00000008UL
404 #define CKG_MGF1_SHA3_512 0x00000009UL
407 #define CKH_MONOTONIC_COUNTER 0x00000001UL
408 #define CKH_CLOCK 0x00000002UL
409 #define CKH_USER_INTERFACE 0x00000003UL
410 #define CKH_VENDOR_DEFINED 0x80000000UL
413 #define CKK_RSA 0x00000000UL
414 #define CKK_DSA 0x00000001UL
415 #define CKK_DH 0x00000002UL
416 #define CKK_EC 0x00000003UL
417 #define CKK_X9_42_DH 0x00000004UL
418 #define CKK_KEA 0x00000005UL
419 #define CKK_GENERIC_SECRET 0x00000010UL
420 #define CKK_RC2 0x00000011UL
421 #define CKK_RC4 0x00000012UL
422 #define CKK_DES 0x00000013UL
423 #define CKK_DES2 0x00000014UL
424 #define CKK_DES3 0x00000015UL
425 #define CKK_CAST 0x00000016UL
426 #define CKK_CAST3 0x00000017UL
427 #define CKK_CAST128 0x00000018UL
428 #define CKK_RC5 0x00000019UL
429 #define CKK_IDEA 0x0000001AUL
430 #define CKK_SKIPJACK 0x0000001BUL
431 #define CKK_BATON 0x0000001CUL
432 #define CKK_JUNIPER 0x0000001DUL
433 #define CKK_CDMF 0x0000001EUL
434 #define CKK_AES 0x0000001FUL
435 #define CKK_BLOWFISH 0x00000020UL
436 #define CKK_TWOFISH 0x00000021UL
437 #define CKK_SECURID 0x00000022UL
438 #define CKK_HOTP 0x00000023UL
439 #define CKK_ACTI 0x00000024UL
440 #define CKK_CAMELLIA 0x00000025UL
441 #define CKK_ARIA 0x00000026UL
442 #define CKK_MD5_HMAC 0x00000027UL
443 #define CKK_SHA_1_HMAC 0x00000028UL
444 #define CKK_RIPEMD128_HMAC 0x00000029UL
445 #define CKK_RIPEMD160_HMAC 0x0000002AUL
446 #define CKK_SHA256_HMAC 0x0000002BUL
447 #define CKK_SHA384_HMAC 0x0000002CUL
448 #define CKK_SHA512_HMAC 0x0000002DUL
449 #define CKK_SHA224_HMAC 0x0000002EUL
450 #define CKK_SEED 0x0000002FUL
451 #define CKK_GOSTR3410 0x00000030UL
452 #define CKK_GOSTR3411 0x00000031UL
453 #define CKK_GOST28147 0x00000032UL
454 #define CKK_CHACHA20 0x00000033UL
455 #define CKK_POLY1305 0x00000034UL
456 #define CKK_AES_XTS 0x00000035UL
457 #define CKK_SHA3_224_HMAC 0x00000036UL
458 #define CKK_SHA3_256_HMAC 0x00000037UL
459 #define CKK_SHA3_384_HMAC 0x00000038UL
460 #define CKK_SHA3_512_HMAC 0x00000039UL
461 #define CKK_BLAKE2B_160_HMAC 0x0000003AUL
462 #define CKK_BLAKE2B_256_HMAC 0x0000003BUL
463 #define CKK_BLAKE2B_384_HMAC 0x0000003CUL
464 #define CKK_BLAKE2B_512_HMAC 0x0000003DUL
465 #define CKK_SALSA20 0x0000003EUL
466 #define CKK_X2RATCHET 0x0000003FUL
467 #define CKK_EC_EDWARDS 0x00000040UL
468 #define CKK_EC_MONTGOMERY 0x00000041UL
469 #define CKK_HKDF 0x00000042UL
470 #define CKK_SHA512_224_HMAC 0x00000043UL
471 #define CKK_SHA512_256_HMAC 0x00000044UL
472 #define CKK_SHA512_T_HMAC 0x00000045UL
473 #define CKK_HSS 0x00000046UL
474 #define CKK_VENDOR_DEFINED 0x80000000UL
476 #ifdef PKCS11_DEPRECATED
477 #define CKK_ECDSA 0x00000003UL
478 #define CKK_CAST5 0x00000018UL
482 #define CKM_RSA_PKCS_KEY_PAIR_GEN 0x00000000UL
483 #define CKM_RSA_PKCS 0x00000001UL
484 #define CKM_RSA_9796 0x00000002UL
485 #define CKM_RSA_X_509 0x00000003UL
486 #define CKM_MD2_RSA_PKCS 0x00000004UL
487 #define CKM_MD5_RSA_PKCS 0x00000005UL
488 #define CKM_SHA1_RSA_PKCS 0x00000006UL
489 #define CKM_RIPEMD128_RSA_PKCS 0x00000007UL
490 #define CKM_RIPEMD160_RSA_PKCS 0x00000008UL
491 #define CKM_RSA_PKCS_OAEP 0x00000009UL
492 #define CKM_RSA_X9_31_KEY_PAIR_GEN 0x0000000AUL
493 #define CKM_RSA_X9_31 0x0000000BUL
494 #define CKM_SHA1_RSA_X9_31 0x0000000CUL
495 #define CKM_RSA_PKCS_PSS 0x0000000DUL
496 #define CKM_SHA1_RSA_PKCS_PSS 0x0000000EUL
497 #define CKM_DSA_KEY_PAIR_GEN 0x00000010UL
498 #define CKM_DSA 0x00000011UL
499 #define CKM_DSA_SHA1 0x00000012UL
500 #define CKM_DSA_SHA224 0x00000013UL
501 #define CKM_DSA_SHA256 0x00000014UL
502 #define CKM_DSA_SHA384 0x00000015UL
503 #define CKM_DSA_SHA512 0x00000016UL
504 #define CKM_DSA_SHA3_224 0x00000018UL
505 #define CKM_DSA_SHA3_256 0x00000019UL
506 #define CKM_DSA_SHA3_384 0x0000001AUL
507 #define CKM_DSA_SHA3_512 0x0000001BUL
508 #define CKM_DH_PKCS_KEY_PAIR_GEN 0x00000020UL
509 #define CKM_DH_PKCS_DERIVE 0x00000021UL
510 #define CKM_X9_42_DH_KEY_PAIR_GEN 0x00000030UL
511 #define CKM_X9_42_DH_DERIVE 0x00000031UL
512 #define CKM_X9_42_DH_HYBRID_DERIVE 0x00000032UL
513 #define CKM_X9_42_MQV_DERIVE 0x00000033UL
514 #define CKM_SHA256_RSA_PKCS 0x00000040UL
515 #define CKM_SHA384_RSA_PKCS 0x00000041UL
516 #define CKM_SHA512_RSA_PKCS 0x00000042UL
517 #define CKM_SHA256_RSA_PKCS_PSS 0x00000043UL
518 #define CKM_SHA384_RSA_PKCS_PSS 0x00000044UL
519 #define CKM_SHA512_RSA_PKCS_PSS 0x00000045UL
520 #define CKM_SHA224_RSA_PKCS 0x00000046UL
521 #define CKM_SHA224_RSA_PKCS_PSS 0x00000047UL
522 #define CKM_SHA512_224 0x00000048UL
523 #define CKM_SHA512_224_HMAC 0x00000049UL
524 #define CKM_SHA512_224_HMAC_GENERAL 0x0000004AUL
525 #define CKM_SHA512_224_KEY_DERIVATION 0x0000004BUL
526 #define CKM_SHA512_256 0x0000004CUL
527 #define CKM_SHA512_256_HMAC 0x0000004DUL
528 #define CKM_SHA512_256_HMAC_GENERAL 0x0000004EUL
529 #define CKM_SHA512_256_KEY_DERIVATION 0x0000004FUL
530 #define CKM_SHA512_T 0x00000050UL
531 #define CKM_SHA512_T_HMAC 0x00000051UL
532 #define CKM_SHA512_T_HMAC_GENERAL 0x00000052UL
533 #define CKM_SHA512_T_KEY_DERIVATION 0x00000053UL
534 #define CKM_SHA3_256_RSA_PKCS 0x00000060UL
535 #define CKM_SHA3_384_RSA_PKCS 0x00000061UL
536 #define CKM_SHA3_512_RSA_PKCS 0x00000062UL
537 #define CKM_SHA3_256_RSA_PKCS_PSS 0x00000063UL
538 #define CKM_SHA3_384_RSA_PKCS_PSS 0x00000064UL
539 #define CKM_SHA3_512_RSA_PKCS_PSS 0x00000065UL
540 #define CKM_SHA3_224_RSA_PKCS 0x00000066UL
541 #define CKM_SHA3_224_RSA_PKCS_PSS 0x00000067UL
542 #define CKM_RC2_KEY_GEN 0x00000100UL
543 #define CKM_RC2_ECB 0x00000101UL
544 #define CKM_RC2_CBC 0x00000102UL
545 #define CKM_RC2_MAC 0x00000103UL
546 #define CKM_RC2_MAC_GENERAL 0x00000104UL
547 #define CKM_RC2_CBC_PAD 0x00000105UL
548 #define CKM_RC4_KEY_GEN 0x00000110UL
549 #define CKM_RC4 0x00000111UL
550 #define CKM_DES_KEY_GEN 0x00000120UL
551 #define CKM_DES_ECB 0x00000121UL
552 #define CKM_DES_CBC 0x00000122UL
553 #define CKM_DES_MAC 0x00000123UL
554 #define CKM_DES_MAC_GENERAL 0x00000124UL
555 #define CKM_DES_CBC_PAD 0x00000125UL
556 #define CKM_DES2_KEY_GEN 0x00000130UL
557 #define CKM_DES3_KEY_GEN 0x00000131UL
558 #define CKM_DES3_ECB 0x00000132UL
559 #define CKM_DES3_CBC 0x00000133UL
560 #define CKM_DES3_MAC 0x00000134UL
561 #define CKM_DES3_MAC_GENERAL 0x00000135UL
562 #define CKM_DES3_CBC_PAD 0x00000136UL
563 #define CKM_DES3_CMAC_GENERAL 0x00000137UL
564 #define CKM_DES3_CMAC 0x00000138UL
565 #define CKM_CDMF_KEY_GEN 0x00000140UL
566 #define CKM_CDMF_ECB 0x00000141UL
567 #define CKM_CDMF_CBC 0x00000142UL
568 #define CKM_CDMF_MAC 0x00000143UL
569 #define CKM_CDMF_MAC_GENERAL 0x00000144UL
570 #define CKM_CDMF_CBC_PAD 0x00000145UL
571 #define CKM_DES_OFB64 0x00000150UL
572 #define CKM_DES_OFB8 0x00000151UL
573 #define CKM_DES_CFB64 0x00000152UL
574 #define CKM_DES_CFB8 0x00000153UL
575 #define CKM_MD2 0x00000200UL
576 #define CKM_MD2_HMAC 0x00000201UL
577 #define CKM_MD2_HMAC_GENERAL 0x00000202UL
578 #define CKM_MD5 0x00000210UL
579 #define CKM_MD5_HMAC 0x00000211UL
580 #define CKM_MD5_HMAC_GENERAL 0x00000212UL
581 #define CKM_SHA_1 0x00000220UL
582 #define CKM_SHA_1_HMAC 0x00000221UL
583 #define CKM_SHA_1_HMAC_GENERAL 0x00000222UL
584 #define CKM_RIPEMD128 0x00000230UL
585 #define CKM_RIPEMD128_HMAC 0x00000231UL
586 #define CKM_RIPEMD128_HMAC_GENERAL 0x00000232UL
587 #define CKM_RIPEMD160 0x00000240UL
588 #define CKM_RIPEMD160_HMAC 0x00000241UL
589 #define CKM_RIPEMD160_HMAC_GENERAL 0x00000242UL
590 #define CKM_SHA256 0x00000250UL
591 #define CKM_SHA256_HMAC 0x00000251UL
592 #define CKM_SHA256_HMAC_GENERAL 0x00000252UL
593 #define CKM_SHA224 0x00000255UL
594 #define CKM_SHA224_HMAC 0x00000256UL
595 #define CKM_SHA224_HMAC_GENERAL 0x00000257UL
596 #define CKM_SHA384 0x00000260UL
597 #define CKM_SHA384_HMAC 0x00000261UL
598 #define CKM_SHA384_HMAC_GENERAL 0x00000262UL
599 #define CKM_SHA512 0x00000270UL
600 #define CKM_SHA512_HMAC 0x00000271UL
601 #define CKM_SHA512_HMAC_GENERAL 0x00000272UL
602 #define CKM_SECURID_KEY_GEN 0x00000280UL
603 #define CKM_SECURID 0x00000282UL
604 #define CKM_HOTP_KEY_GEN 0x00000290UL
605 #define CKM_HOTP 0x00000291UL
606 #define CKM_ACTI 0x000002A0UL
607 #define CKM_ACTI_KEY_GEN 0x000002A1UL
608 #define CKM_SHA3_256 0x000002B0UL
609 #define CKM_SHA3_256_HMAC 0x000002B1UL
610 #define CKM_SHA3_256_HMAC_GENERAL 0x000002B2UL
611 #define CKM_SHA3_256_KEY_GEN 0x000002B3UL
612 #define CKM_SHA3_224 0x000002B5UL
613 #define CKM_SHA3_224_HMAC 0x000002B6UL
614 #define CKM_SHA3_224_HMAC_GENERAL 0x000002B7UL
615 #define CKM_SHA3_224_KEY_GEN 0x000002B8UL
616 #define CKM_SHA3_384 0x000002C0UL
617 #define CKM_SHA3_384_HMAC 0x000002C1UL
618 #define CKM_SHA3_384_HMAC_GENERAL 0x000002C2UL
619 #define CKM_SHA3_384_KEY_GEN 0x000002C3UL
620 #define CKM_SHA3_512 0x000002D0UL
621 #define CKM_SHA3_512_HMAC 0x000002D1UL
622 #define CKM_SHA3_512_HMAC_GENERAL 0x000002D2UL
623 #define CKM_SHA3_512_KEY_GEN 0x000002D3UL
624 #define CKM_CAST_KEY_GEN 0x00000300UL
625 #define CKM_CAST_ECB 0x00000301UL
626 #define CKM_CAST_CBC 0x00000302UL
627 #define CKM_CAST_MAC 0x00000303UL
628 #define CKM_CAST_MAC_GENERAL 0x00000304UL
629 #define CKM_CAST_CBC_PAD 0x00000305UL
630 #define CKM_CAST3_KEY_GEN 0x00000310UL
631 #define CKM_CAST3_ECB 0x00000311UL
632 #define CKM_CAST3_CBC 0x00000312UL
633 #define CKM_CAST3_MAC 0x00000313UL
634 #define CKM_CAST3_MAC_GENERAL 0x00000314UL
635 #define CKM_CAST3_CBC_PAD 0x00000315UL
636 #define CKM_CAST128_KEY_GEN 0x00000320UL
637 #define CKM_CAST5_ECB 0x00000321UL
638 #define CKM_CAST128_ECB 0x00000321UL
639 #define CKM_CAST128_MAC 0x00000323UL
640 #define CKM_CAST128_CBC 0x00000322UL
641 #define CKM_CAST128_MAC_GENERAL 0x00000324UL
642 #define CKM_CAST128_CBC_PAD 0x00000325UL
643 #define CKM_RC5_KEY_GEN 0x00000330UL
644 #define CKM_RC5_ECB 0x00000331UL
645 #define CKM_RC5_CBC 0x00000332UL
646 #define CKM_RC5_MAC 0x00000333UL
647 #define CKM_RC5_MAC_GENERAL 0x00000334UL
648 #define CKM_RC5_CBC_PAD 0x00000335UL
649 #define CKM_IDEA_KEY_GEN 0x00000340UL
650 #define CKM_IDEA_ECB 0x00000341UL
651 #define CKM_IDEA_CBC 0x00000342UL
652 #define CKM_IDEA_MAC 0x00000343UL
653 #define CKM_IDEA_MAC_GENERAL 0x00000344UL
654 #define CKM_IDEA_CBC_PAD 0x00000345UL
655 #define CKM_GENERIC_SECRET_KEY_GEN 0x00000350UL
656 #define CKM_CONCATENATE_BASE_AND_KEY 0x00000360UL
657 #define CKM_CONCATENATE_BASE_AND_DATA 0x00000362UL
658 #define CKM_CONCATENATE_DATA_AND_BASE 0x00000363UL
659 #define CKM_XOR_BASE_AND_DATA 0x00000364UL
660 #define CKM_EXTRACT_KEY_FROM_KEY 0x00000365UL
661 #define CKM_SSL3_PRE_MASTER_KEY_GEN 0x00000370UL
662 #define CKM_SSL3_MASTER_KEY_DERIVE 0x00000371UL
663 #define CKM_SSL3_KEY_AND_MAC_DERIVE 0x00000372UL
664 #define CKM_SSL3_MASTER_KEY_DERIVE_DH 0x00000373UL
665 #define CKM_TLS_PRE_MASTER_KEY_GEN 0x00000374UL
666 #define CKM_TLS_MASTER_KEY_DERIVE 0x00000375UL
667 #define CKM_TLS_KEY_AND_MAC_DERIVE 0x00000376UL
668 #define CKM_TLS_MASTER_KEY_DERIVE_DH 0x00000377UL
669 #define CKM_TLS_PRF 0x00000378UL
670 #define CKM_SSL3_MD5_MAC 0x00000380UL
671 #define CKM_SSL3_SHA1_MAC 0x00000381UL
672 #define CKM_MD5_KEY_DERIVATION 0x00000390UL
673 #define CKM_MD2_KEY_DERIVATION 0x00000391UL
674 #define CKM_SHA1_KEY_DERIVATION 0x00000392UL
675 #define CKM_SHA256_KEY_DERIVATION 0x00000393UL
676 #define CKM_SHA384_KEY_DERIVATION 0x00000394UL
677 #define CKM_SHA512_KEY_DERIVATION 0x00000395UL
678 #define CKM_SHA224_KEY_DERIVATION 0x00000396UL
679 #define CKM_SHA3_256_KEY_DERIVATION 0x00000397UL
680 #define CKM_SHA3_256_KEY_DERIVE 0x00000397UL
681 #define CKM_SHA3_224_KEY_DERIVATION 0x00000398UL
682 #define CKM_SHA3_224_KEY_DERIVE 0x00000398UL
683 #define CKM_SHA3_384_KEY_DERIVATION 0x00000399UL
684 #define CKM_SHA3_384_KEY_DERIVE 0x00000399UL
685 #define CKM_SHA3_512_KEY_DERIVATION 0x0000039AUL
686 #define CKM_SHA3_512_KEY_DERIVE 0x0000039AUL
687 #define CKM_SHAKE_128_KEY_DERIVATION 0x0000039BUL
688 #define CKM_SHAKE_128_KEY_DERIVE 0x0000039BUL
689 #define CKM_SHAKE_256_KEY_DERIVATION 0x0000039CUL
690 #define CKM_SHAKE_256_KEY_DERIVE 0x0000039CUL
691 #define CKM_PBE_MD2_DES_CBC 0x000003A0UL
692 #define CKM_PBE_MD5_DES_CBC 0x000003A1UL
693 #define CKM_PBE_MD5_CAST_CBC 0x000003A2UL
694 #define CKM_PBE_MD5_CAST3_CBC 0x000003A3UL
695 #define CKM_PBE_MD5_CAST128_CBC 0x000003A4UL
696 #define CKM_PBE_SHA1_CAST128_CBC 0x000003A5UL
697 #define CKM_PBE_SHA1_RC4_128 0x000003A6UL
698 #define CKM_PBE_SHA1_RC4_40 0x000003A7UL
699 #define CKM_PBE_SHA1_DES3_EDE_CBC 0x000003A8UL
700 #define CKM_PBE_SHA1_DES2_EDE_CBC 0x000003A9UL
701 #define CKM_PBE_SHA1_RC2_128_CBC 0x000003AAUL
702 #define CKM_PBE_SHA1_RC2_40_CBC 0x000003ABUL
703 #define CKM_PKCS5_PBKD2 0x000003B0UL
704 #define CKM_PBA_SHA1_WITH_SHA1_HMAC 0x000003C0UL
705 #define CKM_WTLS_PRE_MASTER_KEY_GEN 0x000003D0UL
706 #define CKM_WTLS_MASTER_KEY_DERIVE 0x000003D1UL
707 #define CKM_WTLS_MASTER_KEY_DERIVE_DH_ECC 0x000003D2UL
708 #define CKM_WTLS_PRF 0x000003D3UL
709 #define CKM_WTLS_SERVER_KEY_AND_MAC_DERIVE 0x000003D4UL
710 #define CKM_WTLS_CLIENT_KEY_AND_MAC_DERIVE 0x000003D5UL
711 #define CKM_TLS10_MAC_SERVER 0x000003D6UL
712 #define CKM_TLS10_MAC_CLIENT 0x000003D7UL
713 #define CKM_TLS12_MAC 0x000003D8UL
714 #define CKM_TLS12_KDF 0x000003D9UL
715 #define CKM_TLS12_MASTER_KEY_DERIVE 0x000003E0UL
716 #define CKM_TLS12_KEY_AND_MAC_DERIVE 0x000003E1UL
717 #define CKM_TLS12_MASTER_KEY_DERIVE_DH 0x000003E2UL
718 #define CKM_TLS12_KEY_SAFE_DERIVE 0x000003E3UL
719 #define CKM_TLS_MAC 0x000003E4UL
720 #define CKM_TLS_KDF 0x000003E5UL
721 #define CKM_KEY_WRAP_LYNKS 0x00000400UL
722 #define CKM_KEY_WRAP_SET_OAEP 0x00000401UL
723 #define CKM_CMS_SIG 0x00000500UL
724 #define CKM_KIP_DERIVE 0x00000510UL
725 #define CKM_KIP_WRAP 0x00000511UL
726 #define CKM_KIP_MAC 0x00000512UL
727 #define CKM_CAMELLIA_KEY_GEN 0x00000550UL
728 #define CKM_CAMELLIA_ECB 0x00000551UL
729 #define CKM_CAMELLIA_CBC 0x00000552UL
730 #define CKM_CAMELLIA_MAC 0x00000553UL
731 #define CKM_CAMELLIA_MAC_GENERAL 0x00000554UL
732 #define CKM_CAMELLIA_CBC_PAD 0x00000555UL
733 #define CKM_CAMELLIA_ECB_ENCRYPT_DATA 0x00000556UL
734 #define CKM_CAMELLIA_CBC_ENCRYPT_DATA 0x00000557UL
735 #define CKM_CAMELLIA_CTR 0x00000558UL
736 #define CKM_ARIA_KEY_GEN 0x00000560UL
737 #define CKM_ARIA_ECB 0x00000561UL
738 #define CKM_ARIA_CBC 0x00000562UL
739 #define CKM_ARIA_MAC 0x00000563UL
740 #define CKM_ARIA_MAC_GENERAL 0x00000564UL
741 #define CKM_ARIA_CBC_PAD 0x00000565UL
742 #define CKM_ARIA_ECB_ENCRYPT_DATA 0x00000566UL
743 #define CKM_ARIA_CBC_ENCRYPT_DATA 0x00000567UL
744 #define CKM_SEED_KEY_GEN 0x00000650UL
745 #define CKM_SEED_ECB 0x00000651UL
746 #define CKM_SEED_CBC 0x00000652UL
747 #define CKM_SEED_MAC 0x00000653UL
748 #define CKM_SEED_MAC_GENERAL 0x00000654UL
749 #define CKM_SEED_CBC_PAD 0x00000655UL
750 #define CKM_SEED_ECB_ENCRYPT_DATA 0x00000656UL
751 #define CKM_SEED_CBC_ENCRYPT_DATA 0x00000657UL
752 #define CKM_SKIPJACK_KEY_GEN 0x00001000UL
753 #define CKM_SKIPJACK_ECB64 0x00001001UL
754 #define CKM_SKIPJACK_CBC64 0x00001002UL
755 #define CKM_SKIPJACK_OFB64 0x00001003UL
756 #define CKM_SKIPJACK_CFB64 0x00001004UL
757 #define CKM_SKIPJACK_CFB32 0x00001005UL
758 #define CKM_SKIPJACK_CFB16 0x00001006UL
759 #define CKM_SKIPJACK_CFB8 0x00001007UL
760 #define CKM_SKIPJACK_WRAP 0x00001008UL
761 #define CKM_SKIPJACK_PRIVATE_WRAP 0x00001009UL
762 #define CKM_SKIPJACK_RELAYX 0x0000100AUL
763 #define CKM_KEA_KEY_PAIR_GEN 0x00001010UL
764 #define CKM_KEA_KEY_DERIVE 0x00001011UL
765 #define CKM_KEA_DERIVE 0x00001012UL
766 #define CKM_FORTEZZA_TIMESTAMP 0x00001020UL
767 #define CKM_BATON_KEY_GEN 0x00001030UL
768 #define CKM_BATON_ECB128 0x00001031UL
769 #define CKM_BATON_ECB96 0x00001032UL
770 #define CKM_BATON_CBC128 0x00001033UL
771 #define CKM_BATON_COUNTER 0x00001034UL
772 #define CKM_BATON_SHUFFLE 0x00001035UL
773 #define CKM_BATON_WRAP 0x00001036UL
774 #define CKM_EC_KEY_PAIR_GEN 0x00001040UL
775 #define CKM_ECDSA 0x00001041UL
776 #define CKM_ECDSA_SHA1 0x00001042UL
777 #define CKM_ECDSA_SHA224 0x00001043UL
778 #define CKM_ECDSA_SHA256 0x00001044UL
779 #define CKM_ECDSA_SHA384 0x00001045UL
780 #define CKM_ECDSA_SHA512 0x00001046UL
781 #define CKM_EC_KEY_PAIR_GEN_W_EXTRA_BITS 0x0000140BUL
782 #define CKM_ECDH1_DERIVE 0x00001050UL
783 #define CKM_ECDH1_COFACTOR_DERIVE 0x00001051UL
784 #define CKM_ECMQV_DERIVE 0x00001052UL
785 #define CKM_ECDH_AES_KEY_WRAP 0x00001053UL
786 #define CKM_RSA_AES_KEY_WRAP 0x00001054UL
787 #define CKM_JUNIPER_KEY_GEN 0x00001060UL
788 #define CKM_JUNIPER_ECB128 0x00001061UL
789 #define CKM_JUNIPER_CBC128 0x00001062UL
790 #define CKM_JUNIPER_COUNTER 0x00001063UL
791 #define CKM_JUNIPER_SHUFFLE 0x00001064UL
792 #define CKM_JUNIPER_WRAP 0x00001065UL
793 #define CKM_FASTHASH 0x00001070UL
794 #define CKM_AES_XTS 0x00001071UL
795 #define CKM_AES_XTS_KEY_GEN 0x00001072UL
796 #define CKM_AES_KEY_GEN 0x00001080UL
797 #define CKM_AES_ECB 0x00001081UL
798 #define CKM_AES_CBC 0x00001082UL
799 #define CKM_AES_MAC 0x00001083UL
800 #define CKM_AES_MAC_GENERAL 0x00001084UL
801 #define CKM_AES_CBC_PAD 0x00001085UL
802 #define CKM_AES_CTR 0x00001086UL
803 #define CKM_AES_GCM 0x00001087UL
804 #define CKM_AES_CCM 0x00001088UL
805 #define CKM_AES_CTS 0x00001089UL
806 #define CKM_AES_CMAC 0x0000108AUL
807 #define CKM_AES_CMAC_GENERAL 0x0000108BUL
808 #define CKM_AES_XCBC_MAC 0x0000108CUL
809 #define CKM_AES_XCBC_MAC_96 0x0000108DUL
810 #define CKM_AES_GMAC 0x0000108EUL
811 #define CKM_BLOWFISH_KEY_GEN 0x00001090UL
812 #define CKM_BLOWFISH_CBC 0x00001091UL
813 #define CKM_TWOFISH_KEY_GEN 0x00001092UL
814 #define CKM_TWOFISH_CBC 0x00001093UL
815 #define CKM_BLOWFISH_CBC_PAD 0x00001094UL
816 #define CKM_TWOFISH_CBC_PAD 0x00001095UL
817 #define CKM_DES_ECB_ENCRYPT_DATA 0x00001100UL
818 #define CKM_DES_CBC_ENCRYPT_DATA 0x00001101UL
819 #define CKM_DES3_ECB_ENCRYPT_DATA 0x00001102UL
820 #define CKM_DES3_CBC_ENCRYPT_DATA 0x00001103UL
821 #define CKM_AES_ECB_ENCRYPT_DATA 0x00001104UL
822 #define CKM_AES_CBC_ENCRYPT_DATA 0x00001105UL
823 #define CKM_GOSTR3410_KEY_PAIR_GEN 0x00001200UL
824 #define CKM_GOSTR3410 0x00001201UL
825 #define CKM_GOSTR3410_WITH_GOSTR3411 0x00001202UL
826 #define CKM_GOSTR3410_KEY_WRAP 0x00001203UL
827 #define CKM_GOSTR3410_DERIVE 0x00001204UL
828 #define CKM_GOSTR3411 0x00001210UL
829 #define CKM_GOSTR3411_HMAC 0x00001211UL
830 #define CKM_GOST28147_KEY_GEN 0x00001220UL
831 #define CKM_GOST28147_ECB 0x00001221UL
832 #define CKM_GOST28147 0x00001222UL
833 #define CKM_GOST28147_MAC 0x00001223UL
834 #define CKM_GOST28147_KEY_WRAP 0x00001224UL
835 #define CKM_CHACHA20_KEY_GEN 0x00001225UL
836 #define CKM_CHACHA20 0x00001226UL
837 #define CKM_POLY1305_KEY_GEN 0x00001227UL
838 #define CKM_POLY1305 0x00001228UL
839 #define CKM_DSA_PARAMETER_GEN 0x00002000UL
840 #define CKM_DH_PKCS_PARAMETER_GEN 0x00002001UL
841 #define CKM_X9_42_DH_PARAMETER_GEN 0x00002002UL
842 #define CKM_DSA_PROBABILISTIC_PARAMETER_GEN 0x00002003UL
843 #define CKM_DSA_PROBABLISTIC_PARAMETER_GEN 0x00002003UL
844 #define CKM_DSA_SHAWE_TAYLOR_PARAMETER_GEN 0x00002004UL
845 #define CKM_DSA_FIPS_G_GEN 0x00002005UL
846 #define CKM_AES_OFB 0x00002104UL
847 #define CKM_AES_CFB64 0x00002105UL
848 #define CKM_AES_CFB8 0x00002106UL
849 #define CKM_AES_CFB128 0x00002107UL
850 #define CKM_AES_CFB1 0x00002108UL
851 #define CKM_AES_KEY_WRAP 0x00002109UL
852 #define CKM_AES_KEY_WRAP_PAD 0x0000210AUL
853 #define CKM_AES_KEY_WRAP_KWP 0x0000210BUL
854 #define CKM_AES_KEY_WRAP_PKCS7 0x0000210CUL
855 #define CKM_RSA_PKCS_TPM_1_1 0x00004001UL
856 #define CKM_RSA_PKCS_OAEP_TPM_1_1 0x00004002UL
857 #define CKM_SHA_1_KEY_GEN 0x00004003UL
858 #define CKM_SHA224_KEY_GEN 0x00004004UL
859 #define CKM_SHA256_KEY_GEN 0x00004005UL
860 #define CKM_SHA384_KEY_GEN 0x00004006UL
861 #define CKM_SHA512_KEY_GEN 0x00004007UL
862 #define CKM_SHA512_224_KEY_GEN 0x00004008UL
863 #define CKM_SHA512_256_KEY_GEN 0x00004009UL
864 #define CKM_SHA512_T_KEY_GEN 0x0000400AUL
865 #define CKM_NULL 0x0000400BUL
866 #define CKM_BLAKE2B_160 0x0000400CUL
867 #define CKM_BLAKE2B_160_HMAC 0x0000400DUL
868 #define CKM_BLAKE2B_160_HMAC_GENERAL 0x0000400EUL
869 #define CKM_BLAKE2B_160_KEY_DERIVE 0x0000400FUL
870 #define CKM_BLAKE2B_160_KEY_GEN 0x00004010UL
871 #define CKM_BLAKE2B_256 0x00004011UL
872 #define CKM_BLAKE2B_256_HMAC 0x00004012UL
873 #define CKM_BLAKE2B_256_HMAC_GENERAL 0x00004013UL
874 #define CKM_BLAKE2B_256_KEY_DERIVE 0x00004014UL
875 #define CKM_BLAKE2B_256_KEY_GEN 0x00004015UL
876 #define CKM_BLAKE2B_384 0x00004016UL
877 #define CKM_BLAKE2B_384_HMAC 0x00004017UL
878 #define CKM_BLAKE2B_384_HMAC_GENERAL 0x00004018UL
879 #define CKM_BLAKE2B_384_KEY_DERIVE 0x00004019UL
880 #define CKM_BLAKE2B_384_KEY_GEN 0x0000401AUL
881 #define CKM_BLAKE2B_512 0x0000401BUL
882 #define CKM_BLAKE2B_512_HMAC 0x0000401CUL
883 #define CKM_BLAKE2B_512_HMAC_GENERAL 0x0000401DUL
884 #define CKM_BLAKE2B_512_KEY_DERIVE 0x0000401EUL
885 #define CKM_BLAKE2B_512_KEY_GEN 0x0000401FUL
886 #define CKM_SALSA20 0x00004020UL
887 #define CKM_CHACHA20_POLY1305 0x00004021UL
888 #define CKM_SALSA20_POLY1305 0x00004022UL
889 #define CKM_X3DH_INITIALIZE 0x00004023UL
890 #define CKM_X3DH_RESPOND 0x00004024UL
891 #define CKM_X2RATCHET_INITIALIZE 0x00004025UL
892 #define CKM_X2RATCHET_RESPOND 0x00004026UL
893 #define CKM_X2RATCHET_ENCRYPT 0x00004027UL
894 #define CKM_X2RATCHET_DECRYPT 0x00004028UL
895 #define CKM_XEDDSA 0x00004029UL
896 #define CKM_HKDF_DERIVE 0x0000402AUL
897 #define CKM_HKDF_DATA 0x0000402BUL
898 #define CKM_HKDF_KEY_GEN 0x0000402CUL
899 #define CKM_SALSA20_KEY_GEN 0x0000402DUL
900 #define CKM_ECDSA_SHA3_224 0x00001047UL
901 #define CKM_ECDSA_SHA3_256 0x00001048UL
902 #define CKM_ECDSA_SHA3_384 0x00001049UL
903 #define CKM_ECDSA_SHA3_512 0x0000104AUL
904 #define CKM_EC_EDWARDS_KEY_PAIR_GEN 0x00001055UL
905 #define CKM_EC_MONTGOMERY_KEY_PAIR_GEN 0x00001056UL
906 #define CKM_EDDSA 0x00001057UL
907 #define CKM_SP800_108_COUNTER_KDF 0x000003ACUL
908 #define CKM_SP800_108_FEEDBACK_KDF 0x000003ADUL
909 #define CKM_SP800_108_DOUBLE_PIPELINE_KDF 0x000003AEUL
910 #define CKM_IKE2_PRF_PLUS_DERIVE 0x0000402EUL
911 #define CKM_IKE_PRF_DERIVE 0x0000402FUL
912 #define CKM_IKE1_PRF_DERIVE 0x00004030UL
913 #define CKM_IKE1_EXTENDED_DERIVE 0x00004031UL
914 #define CKM_HSS_KEY_PAIR_GEN 0x00004032UL
915 #define CKM_HSS 0x00004033UL
916 #define CKM_VENDOR_DEFINED 0x80000000UL
918 #ifdef PKCS11_DEPRECATED
919 #define CKM_CAST5_KEY_GEN 0x00000320UL
920 #define CKM_CAST5_CBC 0x00000322UL
921 #define CKM_CAST5_MAC 0x00000323UL
922 #define CKM_CAST5_MAC_GENERAL 0x00000324UL
923 #define CKM_CAST5_CBC_PAD 0x00000325UL
924 #define CKM_PBE_MD5_CAST5_CBC 0x000003A4UL
925 #define CKM_PBE_SHA1_CAST5_CBC 0x000003A5UL
926 #define CKM_ECDSA_KEY_PAIR_GEN 0x00001040UL
930 #define CKN_SURRENDER 0UL
931 #define CKN_OTP_CHANGED 1UL
934 #define CKO_DATA 0x00000000UL
935 #define CKO_CERTIFICATE 0x00000001UL
936 #define CKO_PUBLIC_KEY 0x00000002UL
937 #define CKO_PRIVATE_KEY 0x00000003UL
938 #define CKO_SECRET_KEY 0x00000004UL
939 #define CKO_HW_FEATURE 0x00000005UL
940 #define CKO_DOMAIN_PARAMETERS 0x00000006UL
941 #define CKO_MECHANISM 0x00000007UL
942 #define CKO_OTP_KEY 0x00000008UL
943 #define CKO_PROFILE 0x00000009UL
944 #define CKO_VENDOR_DEFINED 0x80000000UL
947 #define CKP_INVALID_ID 0x00000000UL
948 #define CKP_BASELINE_PROVIDER 0x00000001UL
949 #define CKP_EXTENDED_PROVIDER 0x00000002UL
950 #define CKP_AUTHENTICATION_TOKEN 0x00000003UL
951 #define CKP_PUBLIC_CERTIFICATES_TOKEN 0x00000004UL
952 #define CKP_COMPLETE_PROVIDER 0x00000005UL
953 #define CKP_HKDF_TLS_TOKEN 0x00000006UL
954 #define CKP_VENDOR_DEFINED 0x80000000UL
957 #define CKP_PKCS5_PBKD2_HMAC_SHA1 0x00000001UL
958 #define CKP_PKCS5_PBKD2_HMAC_GOSTR3411 0x00000002UL
959 #define CKP_PKCS5_PBKD2_HMAC_SHA224 0x00000003UL
960 #define CKP_PKCS5_PBKD2_HMAC_SHA256 0x00000004UL
961 #define CKP_PKCS5_PBKD2_HMAC_SHA384 0x00000005UL
962 #define CKP_PKCS5_PBKD2_HMAC_SHA512 0x00000006UL
963 #define CKP_PKCS5_PBKD2_HMAC_SHA512_224 0x00000007UL
964 #define CKP_PKCS5_PBKD2_HMAC_SHA512_256 0x00000008UL
967 #define CKR_OK 0x00000000UL
968 #define CKR_CANCEL 0x00000001UL
969 #define CKR_HOST_MEMORY 0x00000002UL
970 #define CKR_SLOT_ID_INVALID 0x00000003UL
971 #define CKR_GENERAL_ERROR 0x00000005UL
972 #define CKR_FUNCTION_FAILED 0x00000006UL
973 #define CKR_ARGUMENTS_BAD 0x00000007UL
974 #define CKR_NO_EVENT 0x00000008UL
975 #define CKR_NEED_TO_CREATE_THREADS 0x00000009UL
976 #define CKR_CANT_LOCK 0x0000000AUL
977 #define CKR_ATTRIBUTE_READ_ONLY 0x00000010UL
978 #define CKR_ATTRIBUTE_SENSITIVE 0x00000011UL
979 #define CKR_ATTRIBUTE_TYPE_INVALID 0x00000012UL
980 #define CKR_ATTRIBUTE_VALUE_INVALID 0x00000013UL
981 #define CKR_ACTION_PROHIBITED 0x0000001BUL
982 #define CKR_DATA_INVALID 0x00000020UL
983 #define CKR_DATA_LEN_RANGE 0x00000021UL
984 #define CKR_DEVICE_ERROR 0x00000030UL
985 #define CKR_DEVICE_MEMORY 0x00000031UL
986 #define CKR_DEVICE_REMOVED 0x00000032UL
987 #define CKR_ENCRYPTED_DATA_INVALID 0x00000040UL
988 #define CKR_ENCRYPTED_DATA_LEN_RANGE 0x00000041UL
989 #define CKR_AEAD_DECRYPT_FAILED 0x00000042UL
990 #define CKR_FUNCTION_CANCELED 0x00000050UL
991 #define CKR_FUNCTION_NOT_PARALLEL 0x00000051UL
992 #define CKR_FUNCTION_NOT_SUPPORTED 0x00000054UL
993 #define CKR_KEY_HANDLE_INVALID 0x00000060UL
994 #define CKR_KEY_SIZE_RANGE 0x00000062UL
995 #define CKR_KEY_TYPE_INCONSISTENT 0x00000063UL
996 #define CKR_KEY_NOT_NEEDED 0x00000064UL
997 #define CKR_KEY_CHANGED 0x00000065UL
998 #define CKR_KEY_NEEDED 0x00000066UL
999 #define CKR_KEY_INDIGESTIBLE 0x00000067UL
1000 #define CKR_KEY_FUNCTION_NOT_PERMITTED 0x00000068UL
1001 #define CKR_KEY_NOT_WRAPPABLE 0x00000069UL
1002 #define CKR_KEY_UNEXTRACTABLE 0x0000006AUL
1003 #define CKR_MECHANISM_INVALID 0x00000070UL
1004 #define CKR_MECHANISM_PARAM_INVALID 0x00000071UL
1005 #define CKR_OBJECT_HANDLE_INVALID 0x00000082UL
1006 #define CKR_OPERATION_ACTIVE 0x00000090UL
1007 #define CKR_OPERATION_NOT_INITIALIZED 0x00000091UL
1008 #define CKR_PIN_INCORRECT 0x000000A0UL
1009 #define CKR_PIN_INVALID 0x000000A1UL
1010 #define CKR_PIN_LEN_RANGE 0x000000A2UL
1011 #define CKR_PIN_EXPIRED 0x000000A3UL
1012 #define CKR_PIN_LOCKED 0x000000A4UL
1013 #define CKR_SESSION_CLOSED 0x000000B0UL
1014 #define CKR_SESSION_COUNT 0x000000B1UL
1015 #define CKR_SESSION_HANDLE_INVALID 0x000000B3UL
1016 #define CKR_SESSION_PARALLEL_NOT_SUPPORTED 0x000000B4UL
1017 #define CKR_SESSION_READ_ONLY 0x000000B5UL
1018 #define CKR_SESSION_EXISTS 0x000000B6UL
1019 #define CKR_SESSION_READ_ONLY_EXISTS 0x000000B7UL
1020 #define CKR_SESSION_READ_WRITE_SO_EXISTS 0x000000B8UL
1021 #define CKR_SIGNATURE_INVALID 0x000000C0UL
1022 #define CKR_SIGNATURE_LEN_RANGE 0x000000C1UL
1023 #define CKR_TEMPLATE_INCOMPLETE 0x000000D0UL
1024 #define CKR_TEMPLATE_INCONSISTENT 0x000000D1UL
1025 #define CKR_TOKEN_NOT_PRESENT 0x000000E0UL
1026 #define CKR_TOKEN_NOT_RECOGNIZED 0x000000E1UL
1027 #define CKR_TOKEN_WRITE_PROTECTED 0x000000E2UL
1028 #define CKR_UNWRAPPING_KEY_HANDLE_INVALID 0x000000F0UL
1029 #define CKR_UNWRAPPING_KEY_SIZE_RANGE 0x000000F1UL
1030 #define CKR_UNWRAPPING_KEY_TYPE_INCONSISTENT 0x000000F2UL
1031 #define CKR_USER_ALREADY_LOGGED_IN 0x00000100UL
1032 #define CKR_USER_NOT_LOGGED_IN 0x00000101UL
1033 #define CKR_USER_PIN_NOT_INITIALIZED 0x00000102UL
1034 #define CKR_USER_TYPE_INVALID 0x00000103UL
1035 #define CKR_USER_ANOTHER_ALREADY_LOGGED_IN 0x00000104UL
1036 #define CKR_USER_TOO_MANY_TYPES 0x00000105UL
1037 #define CKR_WRAPPED_KEY_INVALID 0x00000110UL
1038 #define CKR_WRAPPED_KEY_LEN_RANGE 0x00000112UL
1039 #define CKR_WRAPPING_KEY_HANDLE_INVALID 0x00000113UL
1040 #define CKR_WRAPPING_KEY_SIZE_RANGE 0x00000114UL
1041 #define CKR_WRAPPING_KEY_TYPE_INCONSISTENT 0x00000115UL
1042 #define CKR_RANDOM_SEED_NOT_SUPPORTED 0x00000120UL
1043 #define CKR_RANDOM_NO_RNG 0x00000121UL
1044 #define CKR_DOMAIN_PARAMS_INVALID 0x00000130UL
1045 #define CKR_CURVE_NOT_SUPPORTED 0x00000140UL
1046 #define CKR_BUFFER_TOO_SMALL 0x00000150UL
1047 #define CKR_SAVED_STATE_INVALID 0x00000160UL
1048 #define CKR_INFORMATION_SENSITIVE 0x00000170UL
1049 #define CKR_STATE_UNSAVEABLE 0x00000180UL
1050 #define CKR_CRYPTOKI_NOT_INITIALIZED 0x00000190UL
1051 #define CKR_CRYPTOKI_ALREADY_INITIALIZED 0x00000191UL
1052 #define CKR_MUTEX_BAD 0x000001A0UL
1053 #define CKR_MUTEX_NOT_LOCKED 0x000001A1UL
1054 #define CKR_NEW_PIN_MODE 0x000001B0UL
1055 #define CKR_NEXT_OTP 0x000001B1UL
1056 #define CKR_EXCEEDED_MAX_ITERATIONS 0x000001B5UL
1057 #define CKR_FIPS_SELF_TEST_FAILED 0x000001B6UL
1058 #define CKR_LIBRARY_LOAD_FAILED 0x000001B7UL
1059 #define CKR_PIN_TOO_WEAK 0x000001B8UL
1060 #define CKR_PUBLIC_KEY_INVALID 0x000001B9UL
1061 #define CKR_FUNCTION_REJECTED 0x00000200UL
1062 #define CKR_TOKEN_RESOURCE_EXCEEDED 0x00000201UL
1063 #define CKR_OPERATION_CANCEL_FAILED 0x00000202UL
1064 #define CKR_KEY_EXHAUSTED 0x00000203UL
1065 #define CKR_VENDOR_DEFINED 0x80000000UL
1069 #define CKS_RO_PUBLIC_SESSION 0UL
1070 #define CKS_RO_USER_FUNCTIONS 1UL
1071 #define CKS_RW_PUBLIC_SESSION 2UL
1072 #define CKS_RW_USER_FUNCTIONS 3UL
1073 #define CKS_RW_SO_FUNCTIONS 4UL
1077 #define CKU_USER 1UL
1078 #define CKU_CONTEXT_SPECIFIC 2UL
1081 #define CKZ_DATA_SPECIFIED 0x00000001UL
1084 #define CKZ_SALT_SPECIFIED 0x00000001UL
1087 #define STRUCTDEF(__name__) \
1089 typedef struct __name__ __name__; \
1090 typedef struct __name__ * __name__ ## _PTR; \
1091 typedef struct __name__ ** __name__ ## _PTR_PTR;
1109 typedef CK_RV (* CK_NOTIFY)(CK_SESSION_HANDLE, CK_NOTIFICATION,
void *);
1110 typedef CK_RV (* CK_CREATEMUTEX)(
void **);
1111 typedef CK_RV (* CK_DESTROYMUTEX)(
void *);
1112 typedef CK_RV (* CK_LOCKMUTEX)(
void *);
1113 typedef CK_RV (* CK_UNLOCKMUTEX)(
void *);
1117 CK_ATTRIBUTE_TYPE type;
1119 CK_ULONG ulValueLen;
1123 CK_CREATEMUTEX CreateMutex;
1124 CK_DESTROYMUTEX DestroyMutex;
1125 CK_LOCKMUTEX LockMutex;
1126 CK_UNLOCKMUTEX UnlockMutex;
1140 CK_ULONG ulAttributeCount;
1141 CK_OBJECT_HANDLE * phKey;
1151 CK_UTF8CHAR manufacturerID[32];
1153 CK_UTF8CHAR libraryDescription[32];
1158 CK_CHAR * pInterfaceName;
1159 void * pFunctionList;
1164 CK_MECHANISM_TYPE mechanism;
1166 CK_ULONG ulParameterLen;
1170 CK_ULONG ulMinKeySize;
1171 CK_ULONG ulMaxKeySize;
1179 CK_ULONG ulDeviceError;
1183 CK_UTF8CHAR slotDescription[64];
1184 CK_UTF8CHAR manufacturerID[32];
1191 CK_UTF8CHAR label[32];
1192 CK_UTF8CHAR manufacturerID[32];
1193 CK_UTF8CHAR model[16];
1194 CK_CHAR serialNumber[16];
1196 CK_ULONG ulMaxSessionCount;
1197 CK_ULONG ulSessionCount;
1198 CK_ULONG ulMaxRwSessionCount;
1199 CK_ULONG ulRwSessionCount;
1200 CK_ULONG ulMaxPinLen;
1201 CK_ULONG ulMinPinLen;
1202 CK_ULONG ulTotalPublicMemory;
1203 CK_ULONG ulFreePublicMemory;
1204 CK_ULONG ulTotalPrivateMemory;
1205 CK_ULONG ulFreePrivateMemory;
1208 CK_CHAR utcTime[16];
1287 CK_ULONG ulNonceLen;
1294 CK_ULONG ulCounterBits;
1320 CK_ULONG ulCounterBits;
1327 CK_ULONG ulNonceLen;
1328 CK_ULONG ulNonceFixedBits;
1329 CK_GENERATOR_FUNCTION nonceGenerator;
1337 CK_ULONG ulNonceLen;
1344 CK_BYTE * pBlockCounter;
1345 CK_ULONG blockCounterBits;
1347 CK_ULONG ulNonceBits;
1351 CK_OBJECT_HANDLE certificateHandle;
1354 CK_UTF8CHAR * pContentType;
1355 CK_BYTE * pRequestedAttributes;
1356 CK_ULONG ulRequestedAttributesLen;
1357 CK_BYTE * pRequiredAttributes;
1358 CK_ULONG ulRequiredAttributesLen;
1368 CK_MECHANISM_TYPE hash;
1375 CK_ULONG ulAESKeyBits;
1377 CK_ULONG ulSharedDataLen;
1378 CK_BYTE * pSharedData;
1383 CK_ULONG ulSharedDataLen;
1384 CK_BYTE * pSharedData;
1385 CK_ULONG ulPublicDataLen;
1386 CK_BYTE * pPublicData;
1391 CK_ULONG ulSharedDataLen;
1392 CK_BYTE * pSharedData;
1393 CK_ULONG ulPublicDataLen;
1394 CK_BYTE * pPublicData;
1395 CK_ULONG ulPrivateDataLen;
1396 CK_OBJECT_HANDLE hPrivateData;
1397 CK_ULONG ulPublicDataLen2;
1398 CK_BYTE * pPublicData2;
1403 CK_ULONG ulSharedDataLen;
1404 CK_BYTE * pSharedData;
1405 CK_ULONG ulPublicDataLen;
1406 CK_BYTE * pPublicData;
1407 CK_ULONG ulPrivateDataLen;
1408 CK_OBJECT_HANDLE hPrivateData;
1409 CK_ULONG ulPublicDataLen2;
1410 CK_BYTE * pPublicData2;
1411 CK_OBJECT_HANDLE publicKey;
1416 CK_ULONG ulContextDataLen;
1417 CK_BYTE * pContextData;
1423 CK_ULONG ulIvFixedBits;
1424 CK_GENERATOR_FUNCTION ivGenerator;
1440 CK_BYTE * pPublicData;
1441 CK_ULONG ulPublicDataLen;
1448 CK_ULONG ulWrapOIDLen;
1451 CK_OBJECT_HANDLE hKey;
1457 CK_MECHANISM_TYPE prfHashMechanism;
1458 CK_ULONG ulSaltType;
1461 CK_OBJECT_HANDLE hSaltKey;
1467 CK_MECHANISM_TYPE prfMechanism;
1468 CK_BBOOL bDataAsKey;
1474 CK_OBJECT_HANDLE hNewKey;
1478 CK_MECHANISM_TYPE prfMechanism;
1479 CK_BBOOL bHasKeygxy;
1480 CK_OBJECT_HANDLE hKeygxy;
1481 CK_BYTE * pExtraData;
1482 CK_ULONG ulExtraDataLen;
1486 CK_MECHANISM_TYPE prfMechanism;
1487 CK_BBOOL bHasPrevKey;
1488 CK_OBJECT_HANDLE hKeygxy;
1489 CK_OBJECT_HANDLE hPrevKey;
1498 CK_MECHANISM_TYPE prfMechanism;
1499 CK_BBOOL bHasSeedKey;
1500 CK_OBJECT_HANDLE hSeedKey;
1501 CK_BYTE * pSeedData;
1502 CK_ULONG ulSeedDataLen;
1507 CK_ULONG ulRandomLen;
1510 CK_ULONG ulPublicDataLen;
1511 CK_BYTE * PublicData;
1527 CK_OBJECT_HANDLE hKey;
1533 CK_OTP_PARAM_TYPE type;
1535 CK_ULONG ulValueLen;
1549 CK_BYTE * pInitVector;
1550 CK_UTF8CHAR * pPassword;
1551 CK_ULONG ulPasswordLen;
1554 CK_ULONG ulIteration;
1558 CK_PKCS5_PBKDF2_SALT_SOURCE_TYPE saltSource;
1559 void * pSaltSourceData;
1560 CK_ULONG ulSaltSourceDataLen;
1561 CK_ULONG iterations;
1562 CK_PKCS5_PBKD2_PSEUDO_RANDOM_FUNCTION_TYPE prf;
1564 CK_ULONG ulPrfDataLen;
1565 CK_UTF8CHAR * pPassword;
1566 CK_ULONG * ulPasswordLen;
1570 CK_PKCS5_PBKDF2_SALT_SOURCE_TYPE saltSource;
1571 void * pSaltSourceData;
1572 CK_ULONG ulSaltSourceDataLen;
1573 CK_ULONG iterations;
1574 CK_PKCS5_PBKD2_PSEUDO_RANDOM_FUNCTION_TYPE prf;
1576 CK_ULONG ulPrfDataLen;
1577 CK_UTF8CHAR * pPassword;
1578 CK_ULONG ulPasswordLen;
1582 CK_PRF_DATA_TYPE type;
1584 CK_ULONG ulValueLen;
1588 CK_ULONG ulEffectiveBits;
1593 CK_ULONG ulEffectiveBits;
1594 CK_ULONG ulMacLength;
1598 CK_ULONG ulWordsize;
1605 CK_ULONG ulWordsize;
1607 CK_ULONG ulMacLength;
1611 CK_ULONG ulWordsize;
1616 CK_ULONG ulAESKeyBits;
1621 CK_MECHANISM_TYPE hashAlg;
1622 CK_RSA_PKCS_MGF_TYPE mgf;
1623 CK_RSA_PKCS_OAEP_SOURCE_TYPE source;
1625 CK_ULONG ulSourceDataLen;
1629 CK_MECHANISM_TYPE hashAlg;
1630 CK_RSA_PKCS_MGF_TYPE mgf;
1636 CK_ULONG ulNonceLen;
1642 CK_ULONG ulNonceLen;
1648 CK_BYTE * pBlockCounter;
1650 CK_ULONG ulNonceBits;
1660 CK_ULONG ulPasswordLen;
1661 CK_BYTE * pPassword;
1662 CK_ULONG ulPublicDataLen;
1663 CK_BYTE * pPublicData;
1664 CK_ULONG ulPAndGLen;
1666 CK_ULONG ulRandomLen;
1670 CK_BYTE * pSubprimeQ;
1674 CK_ULONG ulOldWrappedXLen;
1675 CK_BYTE * pOldWrappedX;
1676 CK_ULONG ulOldPasswordLen;
1677 CK_BYTE * pOldPassword;
1678 CK_ULONG ulOldPublicDataLen;
1679 CK_BYTE * pOldPublicData;
1680 CK_ULONG ulOldRandomLen;
1681 CK_BYTE * pOldRandomA;
1682 CK_ULONG ulNewPasswordLen;
1683 CK_BYTE * pNewPassword;
1684 CK_ULONG ulNewPublicDataLen;
1685 CK_BYTE * pNewPublicData;
1686 CK_ULONG ulNewRandomLen;
1687 CK_BYTE * pNewRandomA;
1691 CK_BBOOL bLittleEndian;
1692 CK_ULONG ulWidthInBits;
1696 CK_SP800_108_DKM_LENGTH_METHOD dkmLengthMethod;
1697 CK_BBOOL bLittleEndian;
1698 CK_ULONG ulWidthInBits;
1701 typedef CK_MECHANISM_TYPE CK_SP800_108_PRF_TYPE;
1705 CK_SP800_108_PRF_TYPE prfType;
1706 CK_ULONG ulNumberOfDataParams;
1710 CK_ULONG ulAdditionalDerivedKeys;
1716 CK_SP800_108_PRF_TYPE prfType;
1717 CK_ULONG ulNumberOfDataParams;
1719 CK_ULONG ulAdditionalDerivedKeys;
1725 CK_OBJECT_HANDLE peer_public_prekey;
1726 CK_OBJECT_HANDLE peer_public_identity;
1727 CK_OBJECT_HANDLE own_public_identity;
1728 CK_BBOOL bEncryptedHeader;
1730 CK_MECHANISM_TYPE aeadMechanism;
1731 CK_X2RATCHET_KDF_TYPE kdfMechanism;
1736 CK_OBJECT_HANDLE own_prekey;
1737 CK_OBJECT_HANDLE initiator_identity;
1738 CK_OBJECT_HANDLE own_public_identity;
1739 CK_BBOOL bEncryptedHeader;
1741 CK_MECHANISM_TYPE aeadMechanism;
1742 CK_X2RATCHET_KDF_TYPE kdfMechanism;
1746 CK_X3DH_KDF_TYPE kdf;
1747 CK_OBJECT_HANDLE pPeer_identity;
1748 CK_OBJECT_HANDLE pPeer_prekey;
1749 CK_BYTE * pPrekey_signature;
1750 CK_BYTE * pOnetime_key;
1751 CK_OBJECT_HANDLE pOwn_identity;
1752 CK_OBJECT_HANDLE pOwn_ephemeral;
1756 CK_X3DH_KDF_TYPE kdf;
1757 CK_BYTE * pIdentity_id;
1758 CK_BYTE * pPrekey_id;
1759 CK_BYTE * pOnetime_id;
1760 CK_OBJECT_HANDLE pInitiator_identity;
1761 CK_BYTE * pInitiator_ephemeral;
1765 CK_X9_42_DH_KDF_TYPE kdf;
1766 CK_ULONG ulOtherInfoLen;
1767 CK_BYTE * pOtherInfo;
1768 CK_ULONG ulPublicDataLen;
1769 CK_BYTE * pPublicData;
1773 CK_X9_42_DH_KDF_TYPE kdf;
1774 CK_ULONG ulOtherInfoLen;
1775 CK_BYTE * pOtherInfo;
1776 CK_ULONG ulPublicDataLen;
1777 CK_BYTE * pPublicData;
1778 CK_ULONG ulPrivateDataLen;
1779 CK_OBJECT_HANDLE hPrivateData;
1780 CK_ULONG ulPublicDataLen2;
1781 CK_BYTE * pPublicData2;
1785 CK_X9_42_DH_KDF_TYPE kdf;
1786 CK_ULONG ulOtherInfoLen;
1787 CK_BYTE * OtherInfo;
1788 CK_ULONG ulPublicDataLen;
1789 CK_BYTE * PublicData;
1790 CK_ULONG ulPrivateDataLen;
1791 CK_OBJECT_HANDLE hPrivateData;
1792 CK_ULONG ulPublicDataLen2;
1793 CK_BYTE * PublicData2;
1794 CK_OBJECT_HANDLE publicKey;
1798 CK_XEDDSA_HASH_TYPE hash;
1802 CK_HSS_LEVELS levels;
1803 CK_LMS_TYPE lm_type[8];
1804 CK_LMOTS_TYPE lm_ots_type[8];
1824 CK_OBJECT_HANDLE hClientMacSecret;
1825 CK_OBJECT_HANDLE hServerMacSecret;
1826 CK_OBJECT_HANDLE hClientKey;
1827 CK_OBJECT_HANDLE hServerKey;
1828 CK_BYTE * pIVClient;
1829 CK_BYTE * pIVServer;
1833 CK_BYTE * pClientRandom;
1834 CK_ULONG ulClientRandomLen;
1835 CK_BYTE * pServerRandom;
1836 CK_ULONG ulServerRandomLen;
1840 CK_ULONG ulMacSizeInBits;
1841 CK_ULONG ulKeySizeInBits;
1842 CK_ULONG ulIVSizeInBits;
1854 CK_MECHANISM_TYPE prfMechanism;
1856 CK_ULONG ulLabelLength;
1858 CK_BYTE * pContextData;
1859 CK_ULONG ulContextDataLength;
1863 CK_MECHANISM_TYPE prfHashMechanism;
1864 CK_ULONG ulMacLength;
1865 CK_ULONG ulServerOrClient;
1872 CK_ULONG ulLabelLen;
1874 CK_ULONG * pulOutputLen;
1878 CK_ULONG ulMacSizeInBits;
1879 CK_ULONG ulKeySizeInBits;
1880 CK_ULONG ulIVSizeInBits;
1884 CK_MECHANISM_TYPE prfHashMechanism;
1890 CK_MECHANISM_TYPE prfHashMechanism;
1894 CK_OBJECT_HANDLE hMacSecret;
1895 CK_OBJECT_HANDLE hKey;
1900 CK_BYTE * pClientRandom;
1901 CK_ULONG ulClientRandomLen;
1902 CK_BYTE * pServerRandom;
1903 CK_ULONG ulServerRandomLen;
1907 CK_MECHANISM_TYPE DigestMechanism;
1908 CK_ULONG ulMacSizeInBits;
1909 CK_ULONG ulKeySizeInBits;
1910 CK_ULONG ulIVSizeInBits;
1911 CK_ULONG ulSequenceNumber;
1918 CK_MECHANISM_TYPE DigestMechanism;
1924 CK_MECHANISM_TYPE DigestMechanism;
1928 CK_ULONG ulLabelLen;
1930 CK_ULONG * pulOutputLen;
1934 extern CK_RV C_Initialize(
void *);
1935 extern CK_RV C_Finalize(
void *);
1936 extern CK_RV C_GetInfo(
CK_INFO *);
1938 extern CK_RV C_GetSlotList(CK_BBOOL, CK_SLOT_ID *, CK_ULONG *);
1939 extern CK_RV C_GetSlotInfo(CK_SLOT_ID,
CK_SLOT_INFO *);
1941 extern CK_RV C_GetMechanismList(CK_SLOT_ID, CK_MECHANISM_TYPE *, CK_ULONG *);
1942 extern CK_RV C_GetMechanismInfo(CK_SLOT_ID, CK_MECHANISM_TYPE,
1944 extern CK_RV C_InitToken(CK_SLOT_ID, CK_UTF8CHAR *, CK_ULONG, CK_UTF8CHAR *);
1945 extern CK_RV C_InitPIN(CK_SESSION_HANDLE, CK_UTF8CHAR *, CK_ULONG);
1946 extern CK_RV C_SetPIN(CK_SESSION_HANDLE, CK_UTF8CHAR *, CK_ULONG, CK_UTF8CHAR *,
1948 extern CK_RV C_OpenSession(CK_SLOT_ID, CK_FLAGS,
void *, CK_NOTIFY,
1949 CK_SESSION_HANDLE *);
1950 extern CK_RV C_CloseSession(CK_SESSION_HANDLE);
1951 extern CK_RV C_CloseAllSessions(CK_SLOT_ID);
1953 extern CK_RV C_GetOperationState(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
1954 extern CK_RV C_SetOperationState(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
1955 CK_OBJECT_HANDLE, CK_OBJECT_HANDLE);
1956 extern CK_RV C_Login(CK_SESSION_HANDLE, CK_USER_TYPE, CK_UTF8CHAR *, CK_ULONG);
1957 extern CK_RV C_Logout(CK_SESSION_HANDLE);
1958 extern CK_RV C_CreateObject(CK_SESSION_HANDLE,
CK_ATTRIBUTE *, CK_ULONG,
1959 CK_OBJECT_HANDLE *);
1960 extern CK_RV C_CopyObject(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
CK_ATTRIBUTE *,
1961 CK_ULONG, CK_OBJECT_HANDLE *);
1962 extern CK_RV C_DestroyObject(CK_SESSION_HANDLE, CK_OBJECT_HANDLE);
1963 extern CK_RV C_GetObjectSize(CK_SESSION_HANDLE, CK_OBJECT_HANDLE, CK_ULONG *);
1964 extern CK_RV C_GetAttributeValue(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
1966 extern CK_RV C_SetAttributeValue(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
1968 extern CK_RV C_FindObjectsInit(CK_SESSION_HANDLE,
CK_ATTRIBUTE *, CK_ULONG);
1969 extern CK_RV C_FindObjects(CK_SESSION_HANDLE, CK_OBJECT_HANDLE *, CK_ULONG,
1971 extern CK_RV C_FindObjectsFinal(CK_SESSION_HANDLE);
1972 extern CK_RV C_EncryptInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
1974 extern CK_RV C_Encrypt(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
1976 extern CK_RV C_EncryptUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
1977 CK_BYTE *, CK_ULONG *);
1978 extern CK_RV C_EncryptFinal(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
1979 extern CK_RV C_DecryptInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
1981 extern CK_RV C_Decrypt(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
1983 extern CK_RV C_DecryptUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
1984 CK_BYTE *, CK_ULONG *);
1985 extern CK_RV C_DecryptFinal(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
1986 extern CK_RV C_DigestInit(CK_SESSION_HANDLE,
CK_MECHANISM *);
1987 extern CK_RV C_Digest(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
1989 extern CK_RV C_DigestUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
1990 extern CK_RV C_DigestKey(CK_SESSION_HANDLE, CK_OBJECT_HANDLE);
1991 extern CK_RV C_DigestFinal(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
1992 extern CK_RV C_SignInit(CK_SESSION_HANDLE,
CK_MECHANISM *, CK_OBJECT_HANDLE);
1993 extern CK_RV C_Sign(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
1995 extern CK_RV C_SignUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
1996 extern CK_RV C_SignFinal(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
1997 extern CK_RV C_SignRecoverInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
1999 extern CK_RV C_SignRecover(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
2001 extern CK_RV C_VerifyInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
2003 extern CK_RV C_Verify(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
2005 extern CK_RV C_VerifyUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2006 extern CK_RV C_VerifyFinal(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2007 extern CK_RV C_VerifyRecoverInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
2009 extern CK_RV C_VerifyRecover(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2010 CK_BYTE *, CK_ULONG *);
2011 extern CK_RV C_DigestEncryptUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2012 CK_BYTE *, CK_ULONG *);
2013 extern CK_RV C_DecryptDigestUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2014 CK_BYTE *, CK_ULONG *);
2015 extern CK_RV C_SignEncryptUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2016 CK_BYTE *, CK_ULONG *);
2017 extern CK_RV C_DecryptVerifyUpdate(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2018 CK_BYTE *, CK_ULONG *);
2020 CK_ULONG, CK_OBJECT_HANDLE *);
2021 extern CK_RV C_GenerateKeyPair(CK_SESSION_HANDLE,
CK_MECHANISM *,
2023 CK_ULONG, CK_OBJECT_HANDLE *,
2024 CK_OBJECT_HANDLE *);
2025 extern CK_RV C_WrapKey(CK_SESSION_HANDLE,
CK_MECHANISM *, CK_OBJECT_HANDLE,
2026 CK_OBJECT_HANDLE, CK_BYTE *, CK_ULONG *);
2027 extern CK_RV C_UnwrapKey(CK_SESSION_HANDLE,
CK_MECHANISM *, CK_OBJECT_HANDLE,
2029 CK_OBJECT_HANDLE *);
2030 extern CK_RV C_DeriveKey(CK_SESSION_HANDLE,
CK_MECHANISM *, CK_OBJECT_HANDLE,
2032 extern CK_RV C_SeedRandom(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2033 extern CK_RV C_GenerateRandom(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2034 extern CK_RV C_GetFunctionStatus(CK_SESSION_HANDLE);
2035 extern CK_RV C_CancelFunction(CK_SESSION_HANDLE);
2036 extern CK_RV C_WaitForSlotEvent(CK_FLAGS, CK_SLOT_ID *,
void *);
2037 extern CK_RV C_GetInterfaceList(
CK_INTERFACE *, CK_ULONG *);
2040 extern CK_RV C_LoginUser(CK_SESSION_HANDLE, CK_USER_TYPE, CK_UTF8CHAR *,
2041 CK_ULONG, CK_UTF8CHAR *, CK_ULONG);
2042 extern CK_RV C_SessionCancel(CK_SESSION_HANDLE, CK_FLAGS);
2043 extern CK_RV C_MessageEncryptInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
2045 extern CK_RV C_EncryptMessage(CK_SESSION_HANDLE,
void *, CK_ULONG, CK_BYTE *,
2046 CK_ULONG, CK_BYTE *, CK_ULONG, CK_BYTE *,
2048 extern CK_RV C_EncryptMessageBegin(CK_SESSION_HANDLE,
void *, CK_ULONG,
2049 CK_BYTE *, CK_ULONG);
2050 extern CK_RV C_EncryptMessageNext(CK_SESSION_HANDLE,
void *, CK_ULONG,
2051 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG *,
2053 extern CK_RV C_MessageEncryptFinal(CK_SESSION_HANDLE);
2054 extern CK_RV C_MessageDecryptInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
2056 extern CK_RV C_DecryptMessage(CK_SESSION_HANDLE,
void *, CK_ULONG, CK_BYTE *,
2057 CK_ULONG, CK_BYTE *, CK_ULONG, CK_BYTE *,
2059 extern CK_RV C_DecryptMessageBegin(CK_SESSION_HANDLE,
void *, CK_ULONG,
2060 CK_BYTE *, CK_ULONG);
2061 extern CK_RV C_DecryptMessageNext(CK_SESSION_HANDLE,
void *, CK_ULONG,
2062 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG *,
2064 extern CK_RV C_MessageDecryptFinal(CK_SESSION_HANDLE);
2065 extern CK_RV C_MessageSignInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
2067 extern CK_RV C_SignMessage(CK_SESSION_HANDLE,
void *, CK_ULONG, CK_BYTE *,
2068 CK_ULONG, CK_BYTE *, CK_ULONG *);
2069 extern CK_RV C_SignMessageBegin(CK_SESSION_HANDLE,
void *, CK_ULONG);
2070 extern CK_RV C_SignMessageNext(CK_SESSION_HANDLE,
void *, CK_ULONG,
2071 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG *);
2072 extern CK_RV C_MessageSignFinal(CK_SESSION_HANDLE);
2073 extern CK_RV C_MessageVerifyInit(CK_SESSION_HANDLE,
CK_MECHANISM *,
2075 extern CK_RV C_VerifyMessage(CK_SESSION_HANDLE,
void *, CK_ULONG, CK_BYTE *,
2076 CK_ULONG, CK_BYTE *, CK_ULONG);
2077 extern CK_RV C_VerifyMessageBegin(CK_SESSION_HANDLE,
void *, CK_ULONG);
2078 extern CK_RV C_VerifyMessageNext(CK_SESSION_HANDLE,
void *, CK_ULONG,
2079 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG);
2080 extern CK_RV C_MessageVerifyFinal(CK_SESSION_HANDLE);
2082 typedef CK_RV (* CK_C_Initialize)(
void *);
2083 typedef CK_RV (* CK_C_Finalize)(
void *);
2084 typedef CK_RV (* CK_C_GetInfo)(
CK_INFO *);
2086 typedef CK_RV (* CK_C_GetSlotList)(CK_BBOOL, CK_SLOT_ID *, CK_ULONG *);
2087 typedef CK_RV (* CK_C_GetSlotInfo)(CK_SLOT_ID,
CK_SLOT_INFO *);
2088 typedef CK_RV (* CK_C_GetTokenInfo)(CK_SLOT_ID,
CK_TOKEN_INFO *);
2089 typedef CK_RV (* CK_C_GetMechanismList)(CK_SLOT_ID, CK_MECHANISM_TYPE *,
2091 typedef CK_RV (* CK_C_GetMechanismInfo)(CK_SLOT_ID, CK_MECHANISM_TYPE,
2093 typedef CK_RV (* CK_C_InitToken)(CK_SLOT_ID, CK_UTF8CHAR *, CK_ULONG,
2095 typedef CK_RV (* CK_C_InitPIN)(CK_SESSION_HANDLE, CK_UTF8CHAR *, CK_ULONG);
2096 typedef CK_RV (* CK_C_SetPIN)(CK_SESSION_HANDLE, CK_UTF8CHAR *, CK_ULONG,
2097 CK_UTF8CHAR *, CK_ULONG);
2098 typedef CK_RV (* CK_C_OpenSession)(CK_SLOT_ID, CK_FLAGS,
void *, CK_NOTIFY,
2099 CK_SESSION_HANDLE *);
2100 typedef CK_RV (* CK_C_CloseSession)(CK_SESSION_HANDLE);
2101 typedef CK_RV (* CK_C_CloseAllSessions)(CK_SLOT_ID);
2102 typedef CK_RV (* CK_C_GetSessionInfo)(CK_SESSION_HANDLE,
CK_SESSION_INFO *);
2103 typedef CK_RV (* CK_C_GetOperationState)(CK_SESSION_HANDLE, CK_BYTE *,
2105 typedef CK_RV (* CK_C_SetOperationState)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2106 CK_OBJECT_HANDLE, CK_OBJECT_HANDLE);
2107 typedef CK_RV (* CK_C_Login)(CK_SESSION_HANDLE, CK_USER_TYPE, CK_UTF8CHAR *,
2109 typedef CK_RV (* CK_C_Logout)(CK_SESSION_HANDLE);
2110 typedef CK_RV (* CK_C_CreateObject)(CK_SESSION_HANDLE,
CK_ATTRIBUTE *, CK_ULONG,
2111 CK_OBJECT_HANDLE *);
2112 typedef CK_RV (* CK_C_CopyObject)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
2114 typedef CK_RV (* CK_C_DestroyObject)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE);
2115 typedef CK_RV (* CK_C_GetObjectSize)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
2117 typedef CK_RV (* CK_C_GetAttributeValue)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
2119 typedef CK_RV (* CK_C_SetAttributeValue)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE,
2121 typedef CK_RV (* CK_C_FindObjectsInit)(CK_SESSION_HANDLE,
CK_ATTRIBUTE *,
2123 typedef CK_RV (* CK_C_FindObjects)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE *,
2124 CK_ULONG, CK_ULONG *);
2125 typedef CK_RV (* CK_C_FindObjectsFinal)(CK_SESSION_HANDLE);
2126 typedef CK_RV (* CK_C_EncryptInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2128 typedef CK_RV (* CK_C_Encrypt)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2129 CK_BYTE *, CK_ULONG *);
2130 typedef CK_RV (* CK_C_EncryptUpdate)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2131 CK_BYTE *, CK_ULONG *);
2132 typedef CK_RV (* CK_C_EncryptFinal)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
2133 typedef CK_RV (* CK_C_DecryptInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2135 typedef CK_RV (* CK_C_Decrypt)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2136 CK_BYTE *, CK_ULONG *);
2137 typedef CK_RV (* CK_C_DecryptUpdate)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2138 CK_BYTE *, CK_ULONG *);
2139 typedef CK_RV (* CK_C_DecryptFinal)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
2140 typedef CK_RV (* CK_C_DigestInit)(CK_SESSION_HANDLE,
CK_MECHANISM *);
2141 typedef CK_RV (* CK_C_Digest)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
2143 typedef CK_RV (* CK_C_DigestUpdate)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2144 typedef CK_RV (* CK_C_DigestKey)(CK_SESSION_HANDLE, CK_OBJECT_HANDLE);
2145 typedef CK_RV (* CK_C_DigestFinal)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
2146 typedef CK_RV (* CK_C_SignInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2148 typedef CK_RV (* CK_C_Sign)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
2150 typedef CK_RV (* CK_C_SignUpdate)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2151 typedef CK_RV (* CK_C_SignFinal)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG *);
2152 typedef CK_RV (* CK_C_SignRecoverInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2154 typedef CK_RV (* CK_C_SignRecover)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2155 CK_BYTE *, CK_ULONG *);
2156 typedef CK_RV (* CK_C_VerifyInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2158 typedef CK_RV (* CK_C_Verify)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG, CK_BYTE *,
2160 typedef CK_RV (* CK_C_VerifyUpdate)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2161 typedef CK_RV (* CK_C_VerifyFinal)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2162 typedef CK_RV (* CK_C_VerifyRecoverInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2164 typedef CK_RV (* CK_C_VerifyRecover)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2165 CK_BYTE *, CK_ULONG *);
2166 typedef CK_RV (* CK_C_DigestEncryptUpdate)(CK_SESSION_HANDLE, CK_BYTE *,
2167 CK_ULONG, CK_BYTE *, CK_ULONG *);
2168 typedef CK_RV (* CK_C_DecryptDigestUpdate)(CK_SESSION_HANDLE, CK_BYTE *,
2169 CK_ULONG, CK_BYTE *, CK_ULONG *);
2170 typedef CK_RV (* CK_C_SignEncryptUpdate)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG,
2171 CK_BYTE *, CK_ULONG *);
2172 typedef CK_RV (* CK_C_DecryptVerifyUpdate)(CK_SESSION_HANDLE, CK_BYTE *,
2173 CK_ULONG, CK_BYTE *, CK_ULONG *);
2174 typedef CK_RV (* CK_C_GenerateKey)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2176 CK_OBJECT_HANDLE *);
2177 typedef CK_RV (* CK_C_GenerateKeyPair)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2179 CK_ULONG, CK_OBJECT_HANDLE *,
2180 CK_OBJECT_HANDLE *);
2181 typedef CK_RV (* CK_C_WrapKey)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2182 CK_OBJECT_HANDLE, CK_OBJECT_HANDLE, CK_BYTE *,
2184 typedef CK_RV (* CK_C_UnwrapKey)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2185 CK_OBJECT_HANDLE, CK_BYTE *, CK_ULONG,
2187 typedef CK_RV (* CK_C_DeriveKey)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2189 CK_OBJECT_HANDLE *);
2190 typedef CK_RV (* CK_C_SeedRandom)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2191 typedef CK_RV (* CK_C_GenerateRandom)(CK_SESSION_HANDLE, CK_BYTE *, CK_ULONG);
2192 typedef CK_RV (* CK_C_GetFunctionStatus)(CK_SESSION_HANDLE);
2193 typedef CK_RV (* CK_C_CancelFunction)(CK_SESSION_HANDLE);
2194 typedef CK_RV (* CK_C_WaitForSlotEvent)(CK_FLAGS, CK_SLOT_ID *,
void *);
2195 typedef CK_RV (* CK_C_GetInterfaceList)(
CK_INTERFACE *, CK_ULONG *);
2196 typedef CK_RV (* CK_C_GetInterface)(CK_UTF8CHAR *,
CK_VERSION *,
2198 typedef CK_RV (* CK_C_LoginUser)(CK_SESSION_HANDLE, CK_USER_TYPE, CK_UTF8CHAR *,
2199 CK_ULONG, CK_UTF8CHAR *, CK_ULONG);
2200 typedef CK_RV (* CK_C_SessionCancel)(CK_SESSION_HANDLE, CK_FLAGS);
2201 typedef CK_RV (* CK_C_MessageEncryptInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2203 typedef CK_RV (* CK_C_EncryptMessage)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2204 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG,
2205 CK_BYTE *, CK_ULONG *);
2206 typedef CK_RV (* CK_C_EncryptMessageBegin)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2207 CK_BYTE *, CK_ULONG);
2208 typedef CK_RV (* CK_C_EncryptMessageNext)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2209 CK_BYTE *, CK_ULONG, CK_BYTE *,
2210 CK_ULONG *, CK_FLAGS);
2211 typedef CK_RV (* CK_C_MessageEncryptFinal)(CK_SESSION_HANDLE);
2212 typedef CK_RV (* CK_C_MessageDecryptInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2214 typedef CK_RV (* CK_C_DecryptMessage)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2215 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG,
2216 CK_BYTE *, CK_ULONG *);
2217 typedef CK_RV (* CK_C_DecryptMessageBegin)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2218 CK_BYTE *, CK_ULONG);
2219 typedef CK_RV (* CK_C_DecryptMessageNext)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2220 CK_BYTE *, CK_ULONG, CK_BYTE *,
2221 CK_ULONG *, CK_FLAGS);
2222 typedef CK_RV (* CK_C_MessageDecryptFinal)(CK_SESSION_HANDLE);
2223 typedef CK_RV (* CK_C_MessageSignInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2225 typedef CK_RV (* CK_C_SignMessage)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2226 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG *);
2227 typedef CK_RV (* CK_C_SignMessageBegin)(CK_SESSION_HANDLE,
void *, CK_ULONG);
2228 typedef CK_RV (* CK_C_SignMessageNext)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2229 CK_BYTE *, CK_ULONG, CK_BYTE *,
2231 typedef CK_RV (* CK_C_MessageSignFinal)(CK_SESSION_HANDLE);
2232 typedef CK_RV (* CK_C_MessageVerifyInit)(CK_SESSION_HANDLE,
CK_MECHANISM *,
2234 typedef CK_RV (* CK_C_VerifyMessage)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2235 CK_BYTE *, CK_ULONG, CK_BYTE *, CK_ULONG);
2236 typedef CK_RV (* CK_C_VerifyMessageBegin)(CK_SESSION_HANDLE,
void *, CK_ULONG);
2237 typedef CK_RV (* CK_C_VerifyMessageNext)(CK_SESSION_HANDLE,
void *, CK_ULONG,
2238 CK_BYTE *, CK_ULONG, CK_BYTE *,
2240 typedef CK_RV (* CK_C_MessageVerifyFinal)(CK_SESSION_HANDLE);
2244 CK_C_Initialize C_Initialize;
2245 CK_C_Finalize C_Finalize;
2246 CK_C_GetInfo C_GetInfo;
2247 CK_C_GetFunctionList C_GetFunctionList;
2248 CK_C_GetSlotList C_GetSlotList;
2249 CK_C_GetSlotInfo C_GetSlotInfo;
2250 CK_C_GetTokenInfo C_GetTokenInfo;
2251 CK_C_GetMechanismList C_GetMechanismList;
2252 CK_C_GetMechanismInfo C_GetMechanismInfo;
2253 CK_C_InitToken C_InitToken;
2254 CK_C_InitPIN C_InitPIN;
2255 CK_C_SetPIN C_SetPIN;
2256 CK_C_OpenSession C_OpenSession;
2257 CK_C_CloseSession C_CloseSession;
2258 CK_C_CloseAllSessions C_CloseAllSessions;
2259 CK_C_GetSessionInfo C_GetSessionInfo;
2260 CK_C_GetOperationState C_GetOperationState;
2261 CK_C_SetOperationState C_SetOperationState;
2263 CK_C_Logout C_Logout;
2264 CK_C_CreateObject C_CreateObject;
2265 CK_C_CopyObject C_CopyObject;
2266 CK_C_DestroyObject C_DestroyObject;
2267 CK_C_GetObjectSize C_GetObjectSize;
2268 CK_C_GetAttributeValue C_GetAttributeValue;
2269 CK_C_SetAttributeValue C_SetAttributeValue;
2270 CK_C_FindObjectsInit C_FindObjectsInit;
2271 CK_C_FindObjects C_FindObjects;
2272 CK_C_FindObjectsFinal C_FindObjectsFinal;
2273 CK_C_EncryptInit C_EncryptInit;
2274 CK_C_Encrypt C_Encrypt;
2275 CK_C_EncryptUpdate C_EncryptUpdate;
2276 CK_C_EncryptFinal C_EncryptFinal;
2277 CK_C_DecryptInit C_DecryptInit;
2278 CK_C_Decrypt C_Decrypt;
2279 CK_C_DecryptUpdate C_DecryptUpdate;
2280 CK_C_DecryptFinal C_DecryptFinal;
2281 CK_C_DigestInit C_DigestInit;
2282 CK_C_Digest C_Digest;
2283 CK_C_DigestUpdate C_DigestUpdate;
2284 CK_C_DigestKey C_DigestKey;
2285 CK_C_DigestFinal C_DigestFinal;
2286 CK_C_SignInit C_SignInit;
2288 CK_C_SignUpdate C_SignUpdate;
2289 CK_C_SignFinal C_SignFinal;
2290 CK_C_SignRecoverInit C_SignRecoverInit;
2291 CK_C_SignRecover C_SignRecover;
2292 CK_C_VerifyInit C_VerifyInit;
2293 CK_C_Verify C_Verify;
2294 CK_C_VerifyUpdate C_VerifyUpdate;
2295 CK_C_VerifyFinal C_VerifyFinal;
2296 CK_C_VerifyRecoverInit C_VerifyRecoverInit;
2297 CK_C_VerifyRecover C_VerifyRecover;
2298 CK_C_DigestEncryptUpdate C_DigestEncryptUpdate;
2299 CK_C_DecryptDigestUpdate C_DecryptDigestUpdate;
2300 CK_C_SignEncryptUpdate C_SignEncryptUpdate;
2301 CK_C_DecryptVerifyUpdate C_DecryptVerifyUpdate;
2302 CK_C_GenerateKey C_GenerateKey;
2303 CK_C_GenerateKeyPair C_GenerateKeyPair;
2304 CK_C_WrapKey C_WrapKey;
2305 CK_C_UnwrapKey C_UnwrapKey;
2306 CK_C_DeriveKey C_DeriveKey;
2307 CK_C_SeedRandom C_SeedRandom;
2308 CK_C_GenerateRandom C_GenerateRandom;
2309 CK_C_GetFunctionStatus C_GetFunctionStatus;
2310 CK_C_CancelFunction C_CancelFunction;
2311 CK_C_WaitForSlotEvent C_WaitForSlotEvent;
2312 CK_C_GetInterfaceList C_GetInterfaceList;
2313 CK_C_GetInterface C_GetInterface;
2314 CK_C_LoginUser C_LoginUser;
2315 CK_C_SessionCancel C_SessionCancel;
2316 CK_C_MessageEncryptInit C_MessageEncryptInit;
2317 CK_C_EncryptMessage C_EncryptMessage;
2318 CK_C_EncryptMessageBegin C_EncryptMessageBegin;
2319 CK_C_EncryptMessageNext C_EncryptMessageNext;
2320 CK_C_MessageEncryptFinal C_MessageEncryptFinal;
2321 CK_C_MessageDecryptInit C_MessageDecryptInit;
2322 CK_C_DecryptMessage C_DecryptMessage;
2323 CK_C_DecryptMessageBegin C_DecryptMessageBegin;
2324 CK_C_DecryptMessageNext C_DecryptMessageNext;
2325 CK_C_MessageDecryptFinal C_MessageDecryptFinal;
2326 CK_C_MessageSignInit C_MessageSignInit;
2327 CK_C_SignMessage C_SignMessage;
2328 CK_C_SignMessageBegin C_SignMessageBegin;
2329 CK_C_SignMessageNext C_SignMessageNext;
2330 CK_C_MessageSignFinal C_MessageSignFinal;
2331 CK_C_MessageVerifyInit C_MessageVerifyInit;
2332 CK_C_VerifyMessage C_VerifyMessage;
2333 CK_C_VerifyMessageBegin C_VerifyMessageBegin;
2334 CK_C_VerifyMessageNext C_VerifyMessageNext;
2335 CK_C_MessageVerifyFinal C_MessageVerifyFinal;
2340 CK_C_Initialize C_Initialize;
2341 CK_C_Finalize C_Finalize;
2342 CK_C_GetInfo C_GetInfo;
2343 CK_C_GetFunctionList C_GetFunctionList;
2344 CK_C_GetSlotList C_GetSlotList;
2345 CK_C_GetSlotInfo C_GetSlotInfo;
2346 CK_C_GetTokenInfo C_GetTokenInfo;
2347 CK_C_GetMechanismList C_GetMechanismList;
2348 CK_C_GetMechanismInfo C_GetMechanismInfo;
2349 CK_C_InitToken C_InitToken;
2350 CK_C_InitPIN C_InitPIN;
2351 CK_C_SetPIN C_SetPIN;
2352 CK_C_OpenSession C_OpenSession;
2353 CK_C_CloseSession C_CloseSession;
2354 CK_C_CloseAllSessions C_CloseAllSessions;
2355 CK_C_GetSessionInfo C_GetSessionInfo;
2356 CK_C_GetOperationState C_GetOperationState;
2357 CK_C_SetOperationState C_SetOperationState;
2359 CK_C_Logout C_Logout;
2360 CK_C_CreateObject C_CreateObject;
2361 CK_C_CopyObject C_CopyObject;
2362 CK_C_DestroyObject C_DestroyObject;
2363 CK_C_GetObjectSize C_GetObjectSize;
2364 CK_C_GetAttributeValue C_GetAttributeValue;
2365 CK_C_SetAttributeValue C_SetAttributeValue;
2366 CK_C_FindObjectsInit C_FindObjectsInit;
2367 CK_C_FindObjects C_FindObjects;
2368 CK_C_FindObjectsFinal C_FindObjectsFinal;
2369 CK_C_EncryptInit C_EncryptInit;
2370 CK_C_Encrypt C_Encrypt;
2371 CK_C_EncryptUpdate C_EncryptUpdate;
2372 CK_C_EncryptFinal C_EncryptFinal;
2373 CK_C_DecryptInit C_DecryptInit;
2374 CK_C_Decrypt C_Decrypt;
2375 CK_C_DecryptUpdate C_DecryptUpdate;
2376 CK_C_DecryptFinal C_DecryptFinal;
2377 CK_C_DigestInit C_DigestInit;
2378 CK_C_Digest C_Digest;
2379 CK_C_DigestUpdate C_DigestUpdate;
2380 CK_C_DigestKey C_DigestKey;
2381 CK_C_DigestFinal C_DigestFinal;
2382 CK_C_SignInit C_SignInit;
2384 CK_C_SignUpdate C_SignUpdate;
2385 CK_C_SignFinal C_SignFinal;
2386 CK_C_SignRecoverInit C_SignRecoverInit;
2387 CK_C_SignRecover C_SignRecover;
2388 CK_C_VerifyInit C_VerifyInit;
2389 CK_C_Verify C_Verify;
2390 CK_C_VerifyUpdate C_VerifyUpdate;
2391 CK_C_VerifyFinal C_VerifyFinal;
2392 CK_C_VerifyRecoverInit C_VerifyRecoverInit;
2393 CK_C_VerifyRecover C_VerifyRecover;
2394 CK_C_DigestEncryptUpdate C_DigestEncryptUpdate;
2395 CK_C_DecryptDigestUpdate C_DecryptDigestUpdate;
2396 CK_C_SignEncryptUpdate C_SignEncryptUpdate;
2397 CK_C_DecryptVerifyUpdate C_DecryptVerifyUpdate;
2398 CK_C_GenerateKey C_GenerateKey;
2399 CK_C_GenerateKeyPair C_GenerateKeyPair;
2400 CK_C_WrapKey C_WrapKey;
2401 CK_C_UnwrapKey C_UnwrapKey;
2402 CK_C_DeriveKey C_DeriveKey;
2403 CK_C_SeedRandom C_SeedRandom;
2404 CK_C_GenerateRandom C_GenerateRandom;
2405 CK_C_GetFunctionStatus C_GetFunctionStatus;
2406 CK_C_CancelFunction C_CancelFunction;
2407 CK_C_WaitForSlotEvent C_WaitForSlotEvent;