pkcs11_luna 0.2.7
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- checksums.yaml.gz.sig +0 -0
- data/.gemtest +0 -0
- data/.yardopts +1 -0
- data/Manifest.txt +24 -0
- data/README_LUNA.rdoc +103 -0
- data/Rakefile +88 -0
- data/examples/config.rb +5 -0
- data/examples/derive_aes_ecdh_key.rb +108 -0
- data/examples/encrypt_decrypt_aes.rb +41 -0
- data/examples/encrypt_decrypt_rsa.rb +47 -0
- data/examples/mechanism_list.rb +20 -0
- data/examples/multithread.rb +73 -0
- data/examples/objects_list.rb +23 -0
- data/examples/sign_verify.rb +56 -0
- data/examples/slot_info.rb +23 -0
- data/ext/extconf.rb +14 -0
- data/ext/generate_constants.rb +57 -0
- data/ext/generate_structs.rb +77 -0
- data/ext/pk11_const_macros.h +38 -0
- data/ext/pk11_struct_macros.h +435 -0
- data/ext/pk11_version.h +6 -0
- data/ext/pk11l.c +352 -0
- data/ext/pk11l_const_def.inc +804 -0
- data/ext/pk11l_struct.doc +1012 -0
- data/ext/pk11l_struct_def.inc +388 -0
- data/ext/pk11l_struct_impl.inc +388 -0
- data/lib/pkcs11_luna/extensions.rb +131 -0
- data/lib/pkcs11_luna.rb +11 -0
- data/test/app_id_helper.rb +29 -0
- data/test/luna_helper.rb +57 -0
- data/test/test_pkcs11_luna.rb +112 -0
- data/test/test_pkcs11_luna_crypt.rb +260 -0
- data.tar.gz.sig +0 -0
- metadata +173 -0
- metadata.gz.sig +1 -0
@@ -0,0 +1,388 @@
|
|
1
|
+
PKCS11_DEFINE_STRUCT(CK_VERSION);
|
2
|
+
PKCS11_DEFINE_MEMBER(CK_VERSION, major);
|
3
|
+
PKCS11_DEFINE_MEMBER(CK_VERSION, minor);
|
4
|
+
|
5
|
+
PKCS11_DEFINE_STRUCT(CK_INFO);
|
6
|
+
PKCS11_DEFINE_MEMBER(CK_INFO, cryptokiVersion);
|
7
|
+
PKCS11_DEFINE_MEMBER(CK_INFO, manufacturerID);
|
8
|
+
PKCS11_DEFINE_MEMBER(CK_INFO, flags);
|
9
|
+
PKCS11_DEFINE_MEMBER(CK_INFO, libraryDescription);
|
10
|
+
PKCS11_DEFINE_MEMBER(CK_INFO, libraryVersion);
|
11
|
+
|
12
|
+
PKCS11_DEFINE_STRUCT(CK_SLOT_INFO);
|
13
|
+
PKCS11_DEFINE_MEMBER(CK_SLOT_INFO, slotDescription);
|
14
|
+
PKCS11_DEFINE_MEMBER(CK_SLOT_INFO, manufacturerID);
|
15
|
+
PKCS11_DEFINE_MEMBER(CK_SLOT_INFO, flags);
|
16
|
+
PKCS11_DEFINE_MEMBER(CK_SLOT_INFO, hardwareVersion);
|
17
|
+
PKCS11_DEFINE_MEMBER(CK_SLOT_INFO, firmwareVersion);
|
18
|
+
|
19
|
+
PKCS11_DEFINE_STRUCT(CK_TOKEN_INFO);
|
20
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, label);
|
21
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, manufacturerID);
|
22
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, model);
|
23
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, serialNumber);
|
24
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, flags);
|
25
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulMaxSessionCount);
|
26
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulSessionCount);
|
27
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulMaxRwSessionCount);
|
28
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulRwSessionCount);
|
29
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulMaxPinLen);
|
30
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulMinPinLen);
|
31
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulTotalPublicMemory);
|
32
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulFreePublicMemory);
|
33
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulTotalPrivateMemory);
|
34
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, ulFreePrivateMemory);
|
35
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, hardwareVersion);
|
36
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, firmwareVersion);
|
37
|
+
PKCS11_DEFINE_MEMBER(CK_TOKEN_INFO, utcTime);
|
38
|
+
|
39
|
+
PKCS11_DEFINE_STRUCT(CK_SESSION_INFO);
|
40
|
+
PKCS11_DEFINE_MEMBER(CK_SESSION_INFO, slotID);
|
41
|
+
PKCS11_DEFINE_MEMBER(CK_SESSION_INFO, state);
|
42
|
+
PKCS11_DEFINE_MEMBER(CK_SESSION_INFO, flags);
|
43
|
+
PKCS11_DEFINE_MEMBER(CK_SESSION_INFO, ulDeviceError);
|
44
|
+
|
45
|
+
PKCS11_DEFINE_STRUCT(CK_DATE);
|
46
|
+
PKCS11_DEFINE_MEMBER(CK_DATE, year);
|
47
|
+
PKCS11_DEFINE_MEMBER(CK_DATE, month);
|
48
|
+
PKCS11_DEFINE_MEMBER(CK_DATE, day);
|
49
|
+
|
50
|
+
PKCS11_DEFINE_STRUCT(CK_MECHANISM_INFO);
|
51
|
+
PKCS11_DEFINE_MEMBER(CK_MECHANISM_INFO, ulMinKeySize);
|
52
|
+
PKCS11_DEFINE_MEMBER(CK_MECHANISM_INFO, ulMaxKeySize);
|
53
|
+
PKCS11_DEFINE_MEMBER(CK_MECHANISM_INFO, flags);
|
54
|
+
|
55
|
+
PKCS11_DEFINE_STRUCT(CK_C_INITIALIZE_ARGS);
|
56
|
+
PKCS11_DEFINE_MEMBER(CK_C_INITIALIZE_ARGS, pReserved);
|
57
|
+
/* unimplemented attr CK_CREATEMUTEX CreateMutex */
|
58
|
+
/* unimplemented attr CK_DESTROYMUTEX DestroyMutex */
|
59
|
+
/* unimplemented attr CK_LOCKMUTEX LockMutex */
|
60
|
+
/* unimplemented attr CK_UNLOCKMUTEX UnlockMutex */
|
61
|
+
PKCS11_DEFINE_MEMBER(CK_C_INITIALIZE_ARGS, flags);
|
62
|
+
|
63
|
+
PKCS11_DEFINE_STRUCT(CK_RSA_PKCS_OAEP_PARAMS);
|
64
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_OAEP_PARAMS, pSourceData);
|
65
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_OAEP_PARAMS, hashAlg);
|
66
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_OAEP_PARAMS, mgf);
|
67
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_OAEP_PARAMS, source);
|
68
|
+
|
69
|
+
PKCS11_DEFINE_STRUCT(CK_RSA_PKCS_PSS_PARAMS);
|
70
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_PSS_PARAMS, hashAlg);
|
71
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_PSS_PARAMS, mgf);
|
72
|
+
PKCS11_DEFINE_MEMBER(CK_RSA_PKCS_PSS_PARAMS, sLen);
|
73
|
+
|
74
|
+
PKCS11_DEFINE_STRUCT(CK_ECDH1_DERIVE_PARAMS);
|
75
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH1_DERIVE_PARAMS, pSharedData);
|
76
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH1_DERIVE_PARAMS, pPublicData);
|
77
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH1_DERIVE_PARAMS, kdf);
|
78
|
+
|
79
|
+
PKCS11_DEFINE_STRUCT(CK_ECDH2_DERIVE_PARAMS);
|
80
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, pSharedData);
|
81
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, pPublicData);
|
82
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, pPublicData2);
|
83
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, kdf);
|
84
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, ulPrivateDataLen);
|
85
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, hPrivateData);
|
86
|
+
PKCS11_DEFINE_MEMBER(CK_ECDH2_DERIVE_PARAMS, ulPublicDataLen2);
|
87
|
+
|
88
|
+
PKCS11_DEFINE_STRUCT(CK_ECMQV_DERIVE_PARAMS);
|
89
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, pSharedData);
|
90
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, pPublicData);
|
91
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, pPublicData2);
|
92
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, kdf);
|
93
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, ulPrivateDataLen);
|
94
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, hPrivateData);
|
95
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, ulPublicDataLen2);
|
96
|
+
PKCS11_DEFINE_MEMBER(CK_ECMQV_DERIVE_PARAMS, publicKey);
|
97
|
+
|
98
|
+
PKCS11_DEFINE_STRUCT(CK_X9_42_DH1_DERIVE_PARAMS);
|
99
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH1_DERIVE_PARAMS, pOtherInfo);
|
100
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH1_DERIVE_PARAMS, pPublicData);
|
101
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH1_DERIVE_PARAMS, kdf);
|
102
|
+
|
103
|
+
PKCS11_DEFINE_STRUCT(CK_X9_42_DH2_DERIVE_PARAMS);
|
104
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, pOtherInfo);
|
105
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, pPublicData);
|
106
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, pPublicData2);
|
107
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, kdf);
|
108
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, ulPrivateDataLen);
|
109
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, hPrivateData);
|
110
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_DH2_DERIVE_PARAMS, ulPublicDataLen2);
|
111
|
+
|
112
|
+
PKCS11_DEFINE_STRUCT(CK_X9_42_MQV_DERIVE_PARAMS);
|
113
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, pOtherInfo);
|
114
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, pPublicData);
|
115
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, pPublicData2);
|
116
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, kdf);
|
117
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, ulPrivateDataLen);
|
118
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, hPrivateData);
|
119
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, ulPublicDataLen2);
|
120
|
+
PKCS11_DEFINE_MEMBER(CK_X9_42_MQV_DERIVE_PARAMS, publicKey);
|
121
|
+
|
122
|
+
PKCS11_DEFINE_STRUCT(CK_KEA_DERIVE_PARAMS);
|
123
|
+
PKCS11_DEFINE_MEMBER(CK_KEA_DERIVE_PARAMS, pRandomA);
|
124
|
+
PKCS11_DEFINE_MEMBER(CK_KEA_DERIVE_PARAMS, pRandomB);
|
125
|
+
PKCS11_DEFINE_MEMBER(CK_KEA_DERIVE_PARAMS, pPublicData);
|
126
|
+
PKCS11_DEFINE_MEMBER(CK_KEA_DERIVE_PARAMS, isSender);
|
127
|
+
PKCS11_DEFINE_MEMBER(CK_KEA_DERIVE_PARAMS, ulRandomLen);
|
128
|
+
|
129
|
+
PKCS11_DEFINE_STRUCT(CK_RC2_CBC_PARAMS);
|
130
|
+
PKCS11_DEFINE_MEMBER(CK_RC2_CBC_PARAMS, ulEffectiveBits);
|
131
|
+
PKCS11_DEFINE_MEMBER(CK_RC2_CBC_PARAMS, iv);
|
132
|
+
|
133
|
+
PKCS11_DEFINE_STRUCT(CK_RC2_MAC_GENERAL_PARAMS);
|
134
|
+
PKCS11_DEFINE_MEMBER(CK_RC2_MAC_GENERAL_PARAMS, ulEffectiveBits);
|
135
|
+
PKCS11_DEFINE_MEMBER(CK_RC2_MAC_GENERAL_PARAMS, ulMacLength);
|
136
|
+
|
137
|
+
PKCS11_DEFINE_STRUCT(CK_RC5_PARAMS);
|
138
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_PARAMS, ulWordsize);
|
139
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_PARAMS, ulRounds);
|
140
|
+
|
141
|
+
PKCS11_DEFINE_STRUCT(CK_RC5_CBC_PARAMS);
|
142
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_CBC_PARAMS, pIv);
|
143
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_CBC_PARAMS, ulWordsize);
|
144
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_CBC_PARAMS, ulRounds);
|
145
|
+
|
146
|
+
PKCS11_DEFINE_STRUCT(CK_RC5_MAC_GENERAL_PARAMS);
|
147
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_MAC_GENERAL_PARAMS, ulWordsize);
|
148
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_MAC_GENERAL_PARAMS, ulRounds);
|
149
|
+
PKCS11_DEFINE_MEMBER(CK_RC5_MAC_GENERAL_PARAMS, ulMacLength);
|
150
|
+
|
151
|
+
PKCS11_DEFINE_STRUCT(CK_DES_CBC_ENCRYPT_DATA_PARAMS);
|
152
|
+
PKCS11_DEFINE_MEMBER(CK_DES_CBC_ENCRYPT_DATA_PARAMS, pData);
|
153
|
+
PKCS11_DEFINE_MEMBER(CK_DES_CBC_ENCRYPT_DATA_PARAMS, iv);
|
154
|
+
|
155
|
+
PKCS11_DEFINE_STRUCT(CK_AES_CBC_ENCRYPT_DATA_PARAMS);
|
156
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_ENCRYPT_DATA_PARAMS, pData);
|
157
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_ENCRYPT_DATA_PARAMS, iv);
|
158
|
+
|
159
|
+
PKCS11_DEFINE_STRUCT(CK_SKIPJACK_PRIVATE_WRAP_PARAMS);
|
160
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, pPassword);
|
161
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, pPublicData);
|
162
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, pRandomA);
|
163
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, pPrimeP);
|
164
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, pBaseG);
|
165
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, pSubprimeQ);
|
166
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, ulPAndGLen);
|
167
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, ulQLen);
|
168
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_PRIVATE_WRAP_PARAMS, ulRandomLen);
|
169
|
+
|
170
|
+
PKCS11_DEFINE_STRUCT(CK_SKIPJACK_RELAYX_PARAMS);
|
171
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pOldWrappedX);
|
172
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pOldPassword);
|
173
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pOldPublicData);
|
174
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pOldRandomA);
|
175
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pNewPassword);
|
176
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pNewPublicData);
|
177
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, pNewRandomA);
|
178
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, ulOldRandomLen);
|
179
|
+
PKCS11_DEFINE_MEMBER(CK_SKIPJACK_RELAYX_PARAMS, ulNewRandomLen);
|
180
|
+
|
181
|
+
PKCS11_DEFINE_STRUCT(CK_PBE_PARAMS);
|
182
|
+
PKCS11_DEFINE_MEMBER(CK_PBE_PARAMS, pInitVector);
|
183
|
+
PKCS11_DEFINE_MEMBER(CK_PBE_PARAMS, pPassword);
|
184
|
+
PKCS11_DEFINE_MEMBER(CK_PBE_PARAMS, pSalt);
|
185
|
+
PKCS11_DEFINE_MEMBER(CK_PBE_PARAMS, ulIteration);
|
186
|
+
|
187
|
+
PKCS11_DEFINE_STRUCT(CK_KEY_WRAP_SET_OAEP_PARAMS);
|
188
|
+
PKCS11_DEFINE_MEMBER(CK_KEY_WRAP_SET_OAEP_PARAMS, pX);
|
189
|
+
PKCS11_DEFINE_MEMBER(CK_KEY_WRAP_SET_OAEP_PARAMS, bBC);
|
190
|
+
|
191
|
+
PKCS11_DEFINE_STRUCT(CK_SSL3_RANDOM_DATA);
|
192
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_RANDOM_DATA, pClientRandom);
|
193
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_RANDOM_DATA, pServerRandom);
|
194
|
+
|
195
|
+
PKCS11_DEFINE_STRUCT(CK_SSL3_MASTER_KEY_DERIVE_PARAMS);
|
196
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_MASTER_KEY_DERIVE_PARAMS, RandomInfo);
|
197
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_MASTER_KEY_DERIVE_PARAMS, pVersion);
|
198
|
+
|
199
|
+
PKCS11_DEFINE_STRUCT(CK_SSL3_KEY_MAT_OUT);
|
200
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_OUT, pIVClient);
|
201
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_OUT, pIVServer);
|
202
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_OUT, hClientMacSecret);
|
203
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_OUT, hServerMacSecret);
|
204
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_OUT, hClientKey);
|
205
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_OUT, hServerKey);
|
206
|
+
|
207
|
+
PKCS11_DEFINE_STRUCT(CK_SSL3_KEY_MAT_PARAMS);
|
208
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_PARAMS, ulMacSizeInBits);
|
209
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_PARAMS, ulKeySizeInBits);
|
210
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_PARAMS, ulIVSizeInBits);
|
211
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_PARAMS, bIsExport);
|
212
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_PARAMS, RandomInfo);
|
213
|
+
PKCS11_DEFINE_MEMBER(CK_SSL3_KEY_MAT_PARAMS, pReturnedKeyMaterial);
|
214
|
+
|
215
|
+
PKCS11_DEFINE_STRUCT(CK_TLS_PRF_PARAMS);
|
216
|
+
PKCS11_DEFINE_MEMBER(CK_TLS_PRF_PARAMS, pSeed);
|
217
|
+
PKCS11_DEFINE_MEMBER(CK_TLS_PRF_PARAMS, pLabel);
|
218
|
+
PKCS11_DEFINE_MEMBER(CK_TLS_PRF_PARAMS, pOutput);
|
219
|
+
PKCS11_DEFINE_MEMBER(CK_TLS_PRF_PARAMS, pulOutputLen);
|
220
|
+
|
221
|
+
PKCS11_DEFINE_STRUCT(CK_WTLS_RANDOM_DATA);
|
222
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_RANDOM_DATA, pClientRandom);
|
223
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_RANDOM_DATA, pServerRandom);
|
224
|
+
|
225
|
+
PKCS11_DEFINE_STRUCT(CK_WTLS_MASTER_KEY_DERIVE_PARAMS);
|
226
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_MASTER_KEY_DERIVE_PARAMS, pVersion);
|
227
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_MASTER_KEY_DERIVE_PARAMS, DigestMechanism);
|
228
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_MASTER_KEY_DERIVE_PARAMS, RandomInfo);
|
229
|
+
|
230
|
+
PKCS11_DEFINE_STRUCT(CK_WTLS_PRF_PARAMS);
|
231
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_PRF_PARAMS, pSeed);
|
232
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_PRF_PARAMS, pLabel);
|
233
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_PRF_PARAMS, pOutput);
|
234
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_PRF_PARAMS, DigestMechanism);
|
235
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_PRF_PARAMS, pulOutputLen);
|
236
|
+
|
237
|
+
PKCS11_DEFINE_STRUCT(CK_WTLS_KEY_MAT_OUT);
|
238
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_OUT, pIV);
|
239
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_OUT, hMacSecret);
|
240
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_OUT, hKey);
|
241
|
+
|
242
|
+
PKCS11_DEFINE_STRUCT(CK_WTLS_KEY_MAT_PARAMS);
|
243
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, DigestMechanism);
|
244
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, ulMacSizeInBits);
|
245
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, ulKeySizeInBits);
|
246
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, ulIVSizeInBits);
|
247
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, ulSequenceNumber);
|
248
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, bIsExport);
|
249
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, RandomInfo);
|
250
|
+
PKCS11_DEFINE_MEMBER(CK_WTLS_KEY_MAT_PARAMS, pReturnedKeyMaterial);
|
251
|
+
|
252
|
+
PKCS11_DEFINE_STRUCT(CK_CMS_SIG_PARAMS);
|
253
|
+
PKCS11_DEFINE_MEMBER(CK_CMS_SIG_PARAMS, pContentType);
|
254
|
+
PKCS11_DEFINE_MEMBER(CK_CMS_SIG_PARAMS, pRequestedAttributes);
|
255
|
+
PKCS11_DEFINE_MEMBER(CK_CMS_SIG_PARAMS, pRequiredAttributes);
|
256
|
+
PKCS11_DEFINE_MEMBER(CK_CMS_SIG_PARAMS, certificateHandle);
|
257
|
+
PKCS11_DEFINE_MEMBER(CK_CMS_SIG_PARAMS, pSigningMechanism);
|
258
|
+
PKCS11_DEFINE_MEMBER(CK_CMS_SIG_PARAMS, pDigestMechanism);
|
259
|
+
|
260
|
+
PKCS11_DEFINE_STRUCT(CK_KEY_DERIVATION_STRING_DATA);
|
261
|
+
PKCS11_DEFINE_MEMBER(CK_KEY_DERIVATION_STRING_DATA, pData);
|
262
|
+
|
263
|
+
PKCS11_DEFINE_STRUCT(CK_PKCS5_PBKD2_PARAMS);
|
264
|
+
PKCS11_DEFINE_MEMBER(CK_PKCS5_PBKD2_PARAMS, pSaltSourceData);
|
265
|
+
PKCS11_DEFINE_MEMBER(CK_PKCS5_PBKD2_PARAMS, pPrfData);
|
266
|
+
PKCS11_DEFINE_MEMBER(CK_PKCS5_PBKD2_PARAMS, pPassword);
|
267
|
+
PKCS11_DEFINE_MEMBER(CK_PKCS5_PBKD2_PARAMS, saltSource);
|
268
|
+
PKCS11_DEFINE_MEMBER(CK_PKCS5_PBKD2_PARAMS, iterations);
|
269
|
+
PKCS11_DEFINE_MEMBER(CK_PKCS5_PBKD2_PARAMS, prf);
|
270
|
+
|
271
|
+
PKCS11_DEFINE_STRUCT(CK_OTP_PARAM);
|
272
|
+
PKCS11_DEFINE_MEMBER(CK_OTP_PARAM, pValue);
|
273
|
+
PKCS11_DEFINE_MEMBER(CK_OTP_PARAM, type);
|
274
|
+
|
275
|
+
PKCS11_DEFINE_STRUCT(CK_OTP_PARAMS);
|
276
|
+
PKCS11_DEFINE_MEMBER(CK_OTP_PARAMS, pParams);
|
277
|
+
PKCS11_DEFINE_MEMBER(CK_OTP_PARAMS, ulCount);
|
278
|
+
|
279
|
+
PKCS11_DEFINE_STRUCT(CK_OTP_SIGNATURE_INFO);
|
280
|
+
PKCS11_DEFINE_MEMBER(CK_OTP_SIGNATURE_INFO, pParams);
|
281
|
+
PKCS11_DEFINE_MEMBER(CK_OTP_SIGNATURE_INFO, ulCount);
|
282
|
+
|
283
|
+
PKCS11_DEFINE_STRUCT(CK_KIP_PARAMS);
|
284
|
+
PKCS11_DEFINE_MEMBER(CK_KIP_PARAMS, pSeed);
|
285
|
+
PKCS11_DEFINE_MEMBER(CK_KIP_PARAMS, pMechanism);
|
286
|
+
PKCS11_DEFINE_MEMBER(CK_KIP_PARAMS, hKey);
|
287
|
+
|
288
|
+
PKCS11_DEFINE_STRUCT(CK_AES_CTR_PARAMS);
|
289
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CTR_PARAMS, ulCounterBits);
|
290
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CTR_PARAMS, cb);
|
291
|
+
|
292
|
+
PKCS11_DEFINE_STRUCT(CK_CAMELLIA_CTR_PARAMS);
|
293
|
+
PKCS11_DEFINE_MEMBER(CK_CAMELLIA_CTR_PARAMS, ulCounterBits);
|
294
|
+
PKCS11_DEFINE_MEMBER(CK_CAMELLIA_CTR_PARAMS, cb);
|
295
|
+
|
296
|
+
PKCS11_DEFINE_STRUCT(CK_CAMELLIA_CBC_ENCRYPT_DATA_PARAMS);
|
297
|
+
PKCS11_DEFINE_MEMBER(CK_CAMELLIA_CBC_ENCRYPT_DATA_PARAMS, pData);
|
298
|
+
PKCS11_DEFINE_MEMBER(CK_CAMELLIA_CBC_ENCRYPT_DATA_PARAMS, iv);
|
299
|
+
|
300
|
+
PKCS11_DEFINE_STRUCT(CK_ARIA_CBC_ENCRYPT_DATA_PARAMS);
|
301
|
+
PKCS11_DEFINE_MEMBER(CK_ARIA_CBC_ENCRYPT_DATA_PARAMS, pData);
|
302
|
+
PKCS11_DEFINE_MEMBER(CK_ARIA_CBC_ENCRYPT_DATA_PARAMS, iv);
|
303
|
+
|
304
|
+
PKCS11_DEFINE_STRUCT(CK_AES_GCM_PARAMS);
|
305
|
+
PKCS11_DEFINE_MEMBER(CK_AES_GCM_PARAMS, pIv);
|
306
|
+
PKCS11_DEFINE_MEMBER(CK_AES_GCM_PARAMS, pAAD);
|
307
|
+
PKCS11_DEFINE_MEMBER(CK_AES_GCM_PARAMS, ulIvBits);
|
308
|
+
PKCS11_DEFINE_MEMBER(CK_AES_GCM_PARAMS, ulTagBits);
|
309
|
+
|
310
|
+
PKCS11_DEFINE_STRUCT(CK_XOR_BASE_DATA_KDF_PARAMS);
|
311
|
+
PKCS11_DEFINE_MEMBER(CK_XOR_BASE_DATA_KDF_PARAMS, pSharedData);
|
312
|
+
PKCS11_DEFINE_MEMBER(CK_XOR_BASE_DATA_KDF_PARAMS, kdf);
|
313
|
+
|
314
|
+
PKCS11_DEFINE_STRUCT(CK_ECIES_PARAMS);
|
315
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, pSharedData1);
|
316
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, pSharedData2);
|
317
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, dhPrimitive);
|
318
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, kdf);
|
319
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, ulSharedDataLen1);
|
320
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, encScheme);
|
321
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, ulEncKeyLenInBits);
|
322
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, macScheme);
|
323
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, ulMacKeyLenInBits);
|
324
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, ulMacLenInBits);
|
325
|
+
PKCS11_DEFINE_MEMBER(CK_ECIES_PARAMS, ulSharedDataLen2);
|
326
|
+
|
327
|
+
PKCS11_DEFINE_STRUCT(CK_PRF_KDF_PARAMS);
|
328
|
+
PKCS11_DEFINE_MEMBER(CK_PRF_KDF_PARAMS, pLabel);
|
329
|
+
PKCS11_DEFINE_MEMBER(CK_PRF_KDF_PARAMS, pContext);
|
330
|
+
PKCS11_DEFINE_MEMBER(CK_PRF_KDF_PARAMS, prfType);
|
331
|
+
PKCS11_DEFINE_MEMBER(CK_PRF_KDF_PARAMS, ulCounter);
|
332
|
+
PKCS11_DEFINE_MEMBER(CK_PRF_KDF_PARAMS, ulEncodingScheme);
|
333
|
+
|
334
|
+
PKCS11_DEFINE_STRUCT(CK_DES_CTR_PARAMS);
|
335
|
+
PKCS11_DEFINE_MEMBER(CK_DES_CTR_PARAMS, ulCounterBits);
|
336
|
+
PKCS11_DEFINE_MEMBER(CK_DES_CTR_PARAMS, cb);
|
337
|
+
|
338
|
+
PKCS11_DEFINE_STRUCT(CA_MOFN_STATUS);
|
339
|
+
PKCS11_DEFINE_MEMBER(CA_MOFN_STATUS, ulID);
|
340
|
+
PKCS11_DEFINE_MEMBER(CA_MOFN_STATUS, ulM);
|
341
|
+
PKCS11_DEFINE_MEMBER(CA_MOFN_STATUS, ulN);
|
342
|
+
PKCS11_DEFINE_MEMBER(CA_MOFN_STATUS, ulSecretSize);
|
343
|
+
PKCS11_DEFINE_MEMBER(CA_MOFN_STATUS, ulFlag);
|
344
|
+
|
345
|
+
PKCS11_DEFINE_STRUCT(CKCA_MODULE_INFO);
|
346
|
+
PKCS11_DEFINE_MEMBER(CKCA_MODULE_INFO, ulModuleSize);
|
347
|
+
PKCS11_DEFINE_MEMBER(CKCA_MODULE_INFO, developerName);
|
348
|
+
PKCS11_DEFINE_MEMBER(CKCA_MODULE_INFO, moduleDescription);
|
349
|
+
PKCS11_DEFINE_MEMBER(CKCA_MODULE_INFO, moduleVersion);
|
350
|
+
|
351
|
+
PKCS11_DEFINE_STRUCT(CK_HA_MEMBER);
|
352
|
+
PKCS11_DEFINE_MEMBER(CK_HA_MEMBER, memberSerial);
|
353
|
+
PKCS11_DEFINE_MEMBER(CK_HA_MEMBER, memberStatus);
|
354
|
+
|
355
|
+
PKCS11_DEFINE_STRUCT(CK_HA_STATUS);
|
356
|
+
PKCS11_DEFINE_MEMBER(CK_HA_STATUS, groupSerial);
|
357
|
+
/* unimplemented attr CK_HA_MEMBER memberList 32 */
|
358
|
+
PKCS11_DEFINE_MEMBER(CK_HA_STATUS, listSize);
|
359
|
+
|
360
|
+
PKCS11_DEFINE_STRUCT(CK_AES_CBC_PAD_EXTRACT_PARAMS);
|
361
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, pBuffer);
|
362
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, pbFileName);
|
363
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, ulType);
|
364
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, ulHandle);
|
365
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, ulDeleteAfterExtract);
|
366
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, pulBufferLen);
|
367
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, ulStorage);
|
368
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, pedId);
|
369
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_EXTRACT_PARAMS, ctxID);
|
370
|
+
|
371
|
+
PKCS11_DEFINE_STRUCT(CK_AES_CBC_PAD_INSERT_PARAMS);
|
372
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, pBuffer);
|
373
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, pbFileName);
|
374
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, ulStorageType);
|
375
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, ulContainerState);
|
376
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, pulType);
|
377
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, pulHandle);
|
378
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, ulStorage);
|
379
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, pedId);
|
380
|
+
PKCS11_DEFINE_MEMBER(CK_AES_CBC_PAD_INSERT_PARAMS, ctxID);
|
381
|
+
|
382
|
+
PKCS11_DEFINE_STRUCT(CK_CLUSTER_STATE);
|
383
|
+
PKCS11_DEFINE_MEMBER(CK_CLUSTER_STATE, bMembers);
|
384
|
+
/* unimplemented attr CK_ULONG ulMemberStatus CK_MAX_CLUSTER_MEMBERS */
|
385
|
+
|
386
|
+
PKCS11_DEFINE_STRUCT(CK_LKM_TOKEN_ID);
|
387
|
+
PKCS11_DEFINE_MEMBER(CK_LKM_TOKEN_ID, id);
|
388
|
+
|