The generic component CPKC11T contains the definitions from the PKCS11T.H include file.
A detailed description of CPKC11T can be found in PKCS#11 V2.20: Cryptographic Token Interface Standard in chapter 9 “General data types”.
Macro | Operands |
CPKC11T | MF=D / C |
Main return codes (MRC)
A detailed description of the meanings of the various MRCs can be found in section 11.1 “Function return values” as of page 112 of the PKCS#11 V2.20 standard. The CKR_ prefix indicates a return code. The following table provides an overview of these MRCs.
If you use the asynchronous interface, other return codes, which are not described in the PKCS#11 standard, may occur. These are listed at the end of the following table.
SRC2 | SRC1 | MRC | MRC-Identifier | Note |
00 | 00 | 0000 | ok | |
00 | 40 | 0001 | cancel | |
00 | 20 | 0002 | host_memory | |
00 | 80 | 0002 | host_memory | |
00 | 01 | 0003 | slot_id_invalid | |
xx | 20 | 0005 | general_error | |
00 | 40 | 0006 | function_failed | |
aa | 01 | 0007 | arguments_bad | see also CRYASC2 |
00 | 40 | 0008 | no_event | |
00 | 40 | 0009 | need_to_create_threads | |
00 | 40 | 000a | cant_lock | |
00 | 40 | 0010 | attribute_read_only | |
00 | 40 | 0011 | attribute_sensitive | |
00 | 40 | 0012 | attribute_type_invalid | |
ii | 01 | 0013 | attribute_value_invalid | The ith value is invalid. |
00 | 40 | 0020 | data_invalid | |
00 | 40 | 0021 | data_len_range | |
00 | 20 | 0030 | device_error | |
00 | 20 | 0031 | device_memory | |
00 | 80 | 0032 | device_removed | |
00 | 40 | 0040 | encrypted_data_invalid | |
00 | 40 | 0041 | encrypted_data_len_range | |
00 | 80 | 0050 | function canceled | |
00 | 40 | 0051 | function_not_parallel | |
00 | 01 | 0054 | function_not_supported | |
aa | 01 | 0060 | key_handle_invalid | see also CRYASC2 |
00 | 40 | 0062 | key_size_range | |
00 | 40 | 0063 | key_type_inconsistent | |
00 | 40 | 0064 | key_not_needed | |
00 | 40 | 0065 | key_changed | |
00 | 40 | 0066 | key_needed | |
00 | 40 | 0067 | key_indigestible | |
00 | 40 | 0068 | key_function_not_permitted | |
00 | 40 | 0069 | key_not_wrappable | |
00 | 40 | 006a | key_unextractable | |
08 | 01 | 0070 | mechanism_invalid | |
08 | 01 | 0071 | mechanism_param_invalid | |
00 | 01 | 0082 | object_handle_invalid | |
00 | 40 | 0090 | operation_active | |
00 | 40 | 0091 | operation_not_initialized | |
00 | 40 | 00a0 | pin_incorrect | |
00 | 40 | 00a1 | pin_invalid | |
00 | 40 | 00a2 | pin_len_range | |
00 | 40 | 00a3 | pin_expired | |
00 | 40 | 00a4 | pin_locked | |
00 | 80 | 00b0 | session_closed | |
00 | 80 | 00b1 | session_count | |
00 | 40 | 00b3 | session_handle_invalid | |
00 | 01 | 00b4 | session_parallel_not_supported | |
00 | 40 | 00b5 | session_read_only | |
00 | 40 | 00b6 | session_exists | |
00 | 40 | 00b7 | session_read_only_exists | |
00 | 40 | 00b8 | session_read_write_so_exists | |
00 | 40 | 00c0 | signature_invalid | |
00 | 40 | 00c1 | signature_len_range | |
00 | 40 | 00d0 | template_incomplete | |
00 | 40 | 00d1 | template_inconsistent | |
00 | 80 | 00e0 | token_not_present | |
00 | 80 | 00e1 | token_not_recognized | |
00 | 80 | 00e2 | token_write_protected | |
00 | 40 | 00f0 | unwrapping_key_handle_invalid | |
00 | 40 | 00f1 | unwrapping_key_size_range | |
00 | 40 | 00f2 | unwrapping_key_type_inconsist | |
00 | 40 | 0100 | user_already_logged_in | |
00 | 40 | 0101 | user_not_logged_in | |
00 | 40 | 0102 | user_pin_not_initialized | |
00 | 40 | 0103 | user_type_invalid | |
00 | 40 | 0104 | user_another_already_logged_in | |
00 | 40 | 0105 | user_too_many_types | |
00 | 40 | 0110 | wrapped_key_invalid | |
00 | 40 | 0112 | wrapped_key_len_range | |
00 | 40 | 0113 | wrapping_key_handle_invalid | |
00 | 40 | 0114 | wrapping_key_size_range | |
00 | 40 | 0115 | wrapping_key_type_inconsistent | |
00 | 40 | 0120 | random_seed_not_supported | |
00 | 40 | 0121 | random_no_rng | |
00 | 40 | 0150 | buffer_too_small | |
00 | 40 | 0160 | saved_state_invalid | |
00 | 40 | 0170 | information_sensitive | |
00 | 40 | 0180 | state_unsaveable | |
00 | 80 | 0190 | cryptoki_not_initialized | |
00 | 40 | 0191 | cryptoki_already_initialized | |
00 | 40 | 01a0 | mutex_bad | |
00 | 40 | 01a1 | mutex_not_locked |
Possible main return codes (MRC), that are not described in PKCS#11 V2.20
SRC2 | SRC1 | MRC | MRC-Identifier | Meaning |
00 | 40 | 8000 | PA_not_alloc | parameter area not allocated |
00 | 40 | 8001 | asynch_call_active | asynchronous call is active |
02 | 00 | 8002 | no_open_session | no session to close |
00 | 80 | 8003 | CRYPT_down | Subsystem CRYPT has been terminated betwenn two function calls |