SUNW_C_GetMechSession man page on SmartOS

Man page or keyword search:  
man Server   16655 pages
apropos Keyword Search (all sections)
Output format
SmartOS logo
[printable version]

SUNW_C_GETMECHSESSION(3EXT)			   SUNW_C_GETMECHSESSION(3EXT)

NAME
       SUNW_C_GetMechSession,	SUNW_C_KeyToObject   -	PKCS#11	 Cryptographic
       Framework functions

SYNOPSIS
       cc [ flag ... ] file... -lpkcs11 [ library... ]
       #include <security/cryptoki.h>
       #include <security/pkcs11.h>

       CK_RV SUNW_C_GetMechSession(CK_MECHANISM_TYPE mech,
	    CK_SESSION_HANDLE_PTR hSession);

       CK_RV SUNW_C_KeyToObject(CK_SESSION_HANDLE hSession,
	    CK_MECHANISM_TYPE mech, const void *rawkey, size_t rawkey_len,
	    CK_OBJECT_HANDLE_PTR obj);

DESCRIPTION
       These functions implement the RSA PKCS#11 v2.20 specification by	 using
       plug-ins to provide the slots.

       The  SUNW_C_GetMechSession()  function  initializes the PKCS#11 crypto‐
       graphic framework and performs all necessary calls to Standard  PKCS#11
       functions  (see libpkcs11(3LIB)) to create a session capable of provid‐
       ing operations on the requested mechanism. It is not neccessary to call
       C_Initalize()  or  C_GetSlotList() before the first call to SUNW_C_Get‐
       MechSession().

       If the SUNW_C_GetMechSession() function is called  multiple  times,  it
       will  return  a new session each time without re-initalizing the frame‐
       work. If it is unable to return a  new  session,	 CKR_SESSION_COUNT  is
       returned.

       The  C_CloseSession()  function should be called to release the session
       when it is no longer required.

       The SUNW_C_KeyToObject() function creates a key object for  the	speci‐
       fied  mechanism	from  the  rawkey data. The object should be destroyed
       with C_DestroyObject() when it is no longer required.

RETURN VALUES
       The SUNW_C_GetMechSession() function returns the following values:

       CKR_OK
				The function completed successfully.

       CKR_SESSION_COUNT
				No sessions are available.

       CKR_ARGUMENTS_BAD
				A null pointer was passed for the return  ses‐
				sion handle.

       CKR_MECHANISM_INVALID
				The  requested	mechanism  is  invalid	or  no
				available plug-in provider supports it.

       CKR_FUNCTION_FAILED
				The function failed.

       CKR_GENERAL_ERROR
				A general error occurred.

       The SUNW_C_KeyToObject() function returns the following values:

       CKR_OK
				The function completed successfully.

       CKR_ARGUMENTS_BAD
				A null pointer was passed for the session han‐
				dle or the key material.

       CKR_MECHANISM_INVALID
				The  requested	mechanism  is  invalid	or  no
				available plug-in provider supports it.

       CKR_FUNCTION_FAILED
				The function failed.

       CKR_GENERAL_ERROR
				A general error occurred.

       The return values of each of the implemented functions are defined  and
       listed  in the RSA PKCS#11 v2.20 specification. See http://www.rsasecu‐
       rity.com.

USAGE
       These functions are not part of the RSA	PKCS#11	 v2.20	specification.
       They  are not likely to exist on non-Solaris systems. They are provided
       as a convenience to application programmers.  Use  of  these  functions
       will make the application non-portable to other systems.

ATTRIBUTES
       See attributes(5) for descriptions of the following attributes:

       ┌────────────────────┬─────────────────┐
       │  ATTRIBUTE TYPE    │ ATTRIBUTE VALUE │
       ├────────────────────┼─────────────────┤
       │Interface Stability │ Evolving	      │
       ├────────────────────┼─────────────────┤
       │MT-Level	    │ MT-Safe	      │
       └────────────────────┴─────────────────┘

SEE ALSO
       libpkcs11(3LIB), attributes(5)

       http://www.rsasecurity.com

				 Oct 27, 2005	   SUNW_C_GETMECHSESSION(3EXT)
[top]

List of man pages available for SmartOS

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net