blob: cfc9d230f0bf9864e3458ae805d817112d8fff03 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
.. _mozilla_projects_nss_reference_fc_getsessioninfo:
FC_GetSessionInfo
=================
`Name <#name>`__
~~~~~~~~~~~~~~~~
.. container::
FC_GetSessionInfo - obtain information about a session.
`Syntax <#syntax>`__
~~~~~~~~~~~~~~~~~~~~
.. container::
.. code:: eval
CK_RV FC_GetSessionInfo(
CK_SESSION_HANDLE hSession,
CK_SESSION_INFO_PTR pInfo
);
`Parameters <#parameters>`__
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. container::
``hSession``
[in] the open session handle.
``pInfo``
[out] pointer to the `CK_SESSION_INFO </en-US/CK_SESSION_INFO>`__ structure to be returned.
`Description <#description>`__
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. container::
``FC_GetSessionInfo`` obtains information about a session. A user may call ``FC_GetSessionInfo``
without logging into the token (to assume the NSS User role).
If the NSS cryptographic module is in the error state, ``FC_GetSessionInfo`` returns
``CKR_DEVICE_ERROR``. Otherwise, it fills in the ``CK_SESSION_INFO`` structure with the following
information:
- ``state``: the state of the session, i.e., no role is assumed, the User role is assumed, or
the Crypto Officer role is assumed
- ``flags``: bit flags that define the type of session
- ``CKF_RW_SESSION (0x00000002)``: true if the session is read/write; false if the session is
read-only.
- ``CKF_SERIAL_SESSION (0x00000004)``: this flag is provided for backward compatibility and
is always set to true.
.. _return_value:
`Return value <#return_value>`__
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.. container::
`Examples <#examples>`__
~~~~~~~~~~~~~~~~~~~~~~~~
.. container::
.. _see_also:
`See also <#see_also>`__
~~~~~~~~~~~~~~~~~~~~~~~~
.. container::
- :ref:`mozilla_projects_nss_reference_fc_closesession`,
`NSC_OpenSession </en-US/NSC_OpenSession>`__
|