2 .\" Copyright (c) 2008, Sun Microsystems, Inc. All Rights Reserved.
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH PKCS11_SOFTTOKEN 5 "Mar 25, 2008"
8 pkcs11_softtoken \- Software RSA PKCS#11 softtoken
12 /usr/lib/security/pkcs11_softtoken.so
13 /usr/lib/security/64/pkcs11_softtoken.so
19 The \fBpkcs11_softtoken.so\fR object implements the RSA PKCS#11 v2.20
20 specification in software. Persistent storage for "token" objects is provided
21 by this PKCS#11 implementation.
24 Application developers should link to \fBlibpkcs11.so\fR rather than link
25 directly to \fBpkcs11_softtoken.so\fR. See \fBlibpkcs11\fR(3LIB).
28 The following cryptographic algorithms are implemented: DES, 3DES, AES,
29 Blowfish, RC4, MD5, SHA1, SHA256, SHA384, SHA512, RSA, DSA, DH, and ECC.
32 All of the Standard PKCS#11 functions listed on \fBlibpkcs11\fR(3LIB) are
33 implemented except for the following:
46 A call to these functions returns \fBCKR_FUNCTION_NOT_SUPPORTED\fR.
49 The following RSA PKCS#11 v2.20 mechanisms are supported:
53 CKM_RSA_PKCS_KEY_PAIR_GEN
61 CKM_DH_PKCS_KEY_PAIR_GEN
106 CKM_SHA_1_HMAC_GENERAL
108 CKM_SHA256_HMAC_GENERAL
110 CKM_SHA384_HMAC_GENERAL
112 CKM_MD5_KEY_DERIVATION
113 CKM_SHA1_KEY_DERIVATION
114 CKM_SHA256_KEY_DERIVATION
115 CKM_SHA384_KEY_DERIVATION
116 CKM_SHA512_KEY_DERIVATION
118 CKM_SSL3_PRE_MASTER_KEY_GEN
119 CKM_SSL3_MASTER_KEY_DERIVE
120 CKM_SSL3_KEY_AND_MAC_DERIVE
121 CKM_SSL3_MASTER_KEY_DERIVE_DH
122 CKM_TLS_PRE_MASTER_KEY_GEN
123 CKM_TLS_MASTER_KEY_DERIVE
124 CKM_TLS_KEY_AND_MAC_DERIVE
125 CKM_TLS_MASTER_KEY_DERIVE_DH
131 Each of the following types of key objects has certain token-specific
132 attributes that are set to true by default as a result of object creation,
133 key/key pair generation, and key derivation.
137 \fBPublic key object\fR
140 \fBCKA_ENCRYPT\fR, \fBCKA_VERIFY\fR, \fBCKA_VERIFY_RECOVER\fR
146 \fBPrivate key object\fR
149 \fBCKA_DECRYPT\fR, \fBCKA_SIGN\fR, \fBCKA_SIGN_RECOVER\fR,
150 \fBCKA_EXTRACTABLE\fR
156 \fBSecret key object\fR
159 \fBCKA_ENCRYPT\fR, \fBCKA_DECRYPT\fR, \fBCKA_SIGN\fR, \fBCKA_VERIFY\fR,
160 \fBCKA_EXTRACTABLE\fR
165 The following certificate objects are supported:
169 \fB\fBCKC_X_509\fR\fR
172 For \fBCKC_X_509\fR certificate objects, the following attributes are
173 supported: \fBCKA_SUBJECT\fR, \fBCKA_VALUE\fR, \fBCKA_LABEL\fR, \fBCKA_ID\fR,
174 \fBCKA_ISSUER\fR, \fBCKA_SERIAL_NUMBER\fR, and \fBCKA_CERTIFICATE_TYPE\fR.
180 \fB\fBCKC_X_509_ATTR_CERT\fR\fR
183 For \fBCKC_X_509_ATTR_CERT\fR certificate objects, the following attributes are
184 supported: \fBCKA_OWNER\fR, \fBCKA_VALUE, CKA_LABEL\fR,
185 \fBCKA_SERIAL_NUMBER\fR, \fBCKA_AC_ISSUER\fR, \fBCKA_ATTR_TYPES\fR, and
186 \fBCKA_CERTIFICATE_TYPE\fR.
191 The search operation of objects matching the template is performed at
192 \fBC_FindObjectsInit\fR. The matched objects are cached for subsequent
193 \fBC_FindObjects\fR operations.
196 The \fBpkcs11_softtoken.so\fR object provides a filesystem-based persistent
197 token object store for storing token objects. The default location of the token
198 object store is the user's home directory returned by \fBgetpwuid_r()\fR. The
199 user can override the default location by using the \fB${SOFTTOKEN_DIR}\fR
200 environment variable.
203 If the token object store has never been initialized, the \fBC_Login()\fR
204 function might return \fBCKR_OK\fR but the user will not be able to create,
205 generate, derive or find any private token object and receives
206 \fBCKR_PIN_EXPIRED\fR.
209 The user must use the \fBpktool\fR(1) \fBsetpin\fR command with the default
210 passphrase "changeme" as the old passphrase to change the passphrase of the
211 object store. This action is needed to initialize and set the passphrase to a
212 newly created token object store.
215 After logging into object store with the new passphrase that was set by the
216 \fBpktool setpin\fR command, the user can create and store the private token
217 object in this newly created object store. Until the token object store is
218 initialized by \fBsetpin\fR, the \fBC_Login()\fR function is allowed, but all
219 attempts by the user to create, generate, derive or find any private token
220 object fails with a \fBCKR_PIN_EXPIRED\fR error.
223 The PIN provided for \fBC_Login()\fR and \fBC_SetPIN()\fR functions can be any
224 string of characters with lengths between 1 and 256 and no embedded nulls.
228 The return values for each of the implemented functions are defined and listed
229 in the RSA PKCS#11 v2.20 specification. See http://www.rsasecurity.com
234 \fB\fB\fIuser_home_directory\fR/.sunw/pkcs11_softtoken\fR\fR
238 user's default token object store
244 \fB\fB${SOFTTOKEN_DIR}/pkcs11_softtoken\fR\fR
248 alternate token object store
254 See \fBattributes\fR(5) for a description of the following attributes:
262 ATTRIBUTE TYPE ATTRIBUTE VALUE
264 Interface Stability Committed
267 MT-Safe with exceptions. See section 6.5.2 of RSA PKCS#11 v2.20.
270 Standard PKCS#11 v2.20
276 \fBpktool\fR(1), \fBcryptoadm\fR(1M), \fBlibpkcs11\fR(3LIB),
277 \fBattributes\fR(5), \fBpkcs11_kernel\fR(5)
280 RSA PKCS#11 v2.20 http://www.rsasecurity.com