4 * The contents of this file are subject to the terms of the
5 * Common Development and Distribution License (the "License").
6 * You may not use this file except in compliance with the License.
8 * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 * or http://www.opensolaris.org/os/licensing.
10 * See the License for the specific language governing permissions
11 * and limitations under the License.
13 * When distributing Covered Code, include this CDDL HEADER in each
14 * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 * If applicable, add the following below this CDDL HEADER, with the
16 * fields enclosed by brackets "[]" replaced with your own identifying
17 * information: Portions Copyright [yyyy] [name of copyright owner]
22 * Copyright 2009 Sun Microsystems, Inc. All rights reserved.
23 * Use is subject to license terms.
33 #include <security/cryptoki.h>
34 #include <security/pkcs11t.h>
37 * The following global variables are defined in softGeneral.c
39 extern boolean_t softtoken_initialized
;
40 extern pthread_mutex_t soft_giant_mutex
;
41 extern struct slot soft_slot
;
42 extern struct obj_to_be_freed_list obj_delay_freed
;
43 extern struct ses_to_be_freed_list ses_delay_freed
;
45 #define SOFTTOKEN_SLOTID 1
47 /* CK_INFO: Information about cryptoki */
48 #define CRYPTOKI_VERSION_MAJOR 2
49 #define CRYPTOKI_VERSION_MINOR 40
50 #define LIBRARY_DESCRIPTION "Sun Crypto Softtoken "
51 #define LIBRARY_VERSION_MAJOR 1
52 #define LIBRARY_VERSION_MINOR 1
55 /* CK_SLOT_INFO: Information about our slot */
56 #define HARDWARE_VERSION_MAJOR 0
57 #define HARDWARE_VERSION_MINOR 0
58 #define FIRMWARE_VERSION_MAJOR 0
59 #define FIRMWARE_VERSION_MINOR 0
61 /* CK_TOKEN_INFO: More information about token */
62 #define TOKEN_MODEL "1.0 "
63 #define MAX_PIN_LEN 256
66 #define SOFT_TOKEN_FLAGS CKF_RNG|\
67 CKF_USER_PIN_INITIALIZED|\
69 CKF_RESTORE_KEY_NOT_NEEDED|\
70 CKF_DUAL_CRYPTO_OPERATIONS|\
77 #endif /* _SOFTGLOBAL_H */