FM_GetSessionUserData

This function is used to obtain the userData associated with the specified session handle. If there are no associated buffers, NULL is returned in ppUserData. 

Synopsis

#include <objstate.h>
CK_RV FM_GetSessionUserData(FmNumber_t fmNo,
CK_SESSION_HANDLE hSession,
CK_VOID_PTR_PTR ppUserData);
Parameter Description
fmNo The fm number of the caller. It must be FM_NUMBER_CUSTOM_FM in this release of the software.
hSession A session handle, which was obtained from an C_OpenSession() call. The validity of this parameter is checked.
ppuserData Address of a variable (of type CK_VOID_PTR) which will contain the address of the user data if this function returns CKR_OK. It must be non-NULL.

Return Code

CKR_OK: The operation was successful. The associated user data is placed in the variable specified by ppUserData.

CKR_ARGUMENTS_BAD: ppUserData was NULL or fmNo was not FM_NUMBER_CUSTOM_FM.

CKR_SESSION_HANDLE_INVALID: hSession is not a valid session handle.