2N/A * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
2N/A * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
2N/A#include "softGlobal.h"
2N/A#include "softSession.h"
2N/A#include "softObject.h"
2N/A#include "softKeystore.h"
2N/A#include "softKeystoreUtil.h"
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A return (CKR_SESSION_PARALLEL_NOT_SUPPORTED);
2N/A return (CKR_SLOT_ID_INVALID);
2N/A return (CKR_ARGUMENTS_BAD);
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A return (CKR_SESSION_CLOSED);
2N/A if (soft_session_cnt == 0) {
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A return (CKR_SLOT_ID_INVALID);
2N/A all_sessions_closing = 0;
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A goto clean_exit;
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A goto clean_exit;
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A (ulOperationStateLen == 0)) {
2N/A goto clean_exit;
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A return (CKR_DEVICE_REMOVED);
2N/A return (CKR_USER_TYPE_INVALID);
2N/A return (CKR_PIN_LEN_RANGE);
2N/A return (CKR_ARGUMENTS_BAD);
2N/A return (CKR_USER_ALREADY_LOGGED_IN);
2N/A if (!softtoken_initialized)
2N/A return (CKR_CRYPTOKI_NOT_INITIALIZED);
2N/A return (CKR_USER_NOT_LOGGED_IN);
2N/A soft_logout();