KM_ExportToScreen

Export a key to the console in encrypted parts. At this stage, only symmetric keys can be exported using this function.

NOTE   This function uses the following callback:

>UICB_ShowMsg_t

Synopsis

#include <kmlib.h>

CK_RV KM_ExportToScreen ( 
   CK_SESSION_HANDLE   hSession, 
   CK_OBJECT_HANDLE    hWrapeeKey, 
   CK_OBJECT_HANDLE    hWrapKey, 
   CK_BBOOL            isEncMuliPart
);
Parameter Description
hSession Handle to an open session.
hWrapeeKey Handle to the key to export.
hWrapKey Handle to the wrapping key.
isEncMuliPart

Flag indicating if the key is to exported in one or more encrypted parts. This parameter only applies if the wrappee key one of:

>CKK_DES2 - exported as two parts

>CKK_DES3 - exported as three parts

Returns

CKR_ARGUMENTS_BAD
CKR_ATTRIBUTE_SENSITIVE
CKR_ATTRIBUTE_TYPE_INVALID
CKR_BUFFER_TOO_SMALL
CKR_CRYPTOKI_NOT_INITIALIZED
CKR_DEVICE_ERROR
CKR_DEVICE_MEMORY
CKR_DEVICE_REMOVED
CKR_FUNCTION_CANCELED
CKR_FUNCTION_FAILED
CKR_GENERAL_ERROR
CKR_HOST_MEMORY
CKR_KEY_HANDLE_INVALID
CKR_KEY_NOT_WRAPPABLE
CKR_KEY_SIZE_RANGE
CKR_KEY_UNEXTRACTABLE
CKR_MECHANISM_INVALID
CKR_MECHANISM_PARAM_INVALID
CKR_OBJECT_HANDLE_INVALID
CKR_OK
CKR_OPERATION_ACTIVE
CKR_SESSION_CLOSED
CKR_SESSION_HANDLE_INVALID
CKR_USER_NOT_LOGGED_IN
CKR_WRAPPING_KEY_HANDLE_INVALID
CKR_WRAPPING_KEY_SIZE_RANGE
CKR_WRAPPING_KEY_TYPE_INCONSISTENT