An instance of OM class DS_C_SESSION identifies a particular link from the application program to a DUA.
An instance of this OM class has the OM attributes of its superclass, OM_C_OBJECT, in addition to the OM attributes listed in the following table.
OM Attributes of DS_C_SESSION
OM Attribute |
Value Syntax |
Value Length | Value Number | Value Initially |
DS_DSA_ ADDRESS |
Object(DS_C_ ADDRESS) |
- | 0 or 1 | local |
DS_DSA_NAME | Object(DS_C_ NAME) |
- | 0 or 1 | local |
DS_FILE_ DESCRIPTOR |
OM_S_INTEGER | - | 1 | See text |
DS_REQUESTOR | Object(DS_C_ NAME) |
- | 0 or 1 | - |
The DS_C_SESSION gathers all the information that describes a particular directory interaction. The parameters that will control such a session are set up in an instance of this OM class, which is then passed as an argument to ds_bind( ). This sets the OM attributes that describe the actual characteristics of this session, and then starts the session. A session started in this way must pass as the first argument to each interface function. The result of modifying an initiated session is unspecified. Finally, ds_unbind( ) is used to terminate the session, after which the parameters can be modified and a new session started using the same instance, if required. Multiple concurrent sessions can run using multiple instances of this OM class.
The OM attributes of a session are as follows:
· DS_DSA_ADDRESS
This attribute indicates the address of the default DSA named by DS_DSA_NAME.
· DS_DSA_NAME
This attribute indicates the DN of the DSA that is used by default to service directory requests.
· DS_FILE_DESCRIPTOR (Optional Functionality)
This OM attribute is not used by DCE XDS and is always set to DS_NO_VALID_FILE_DESCRIPTOR.
· DS_REQUESTOR
This attribute is the DN of the user of this directory service session.
Applications can assume that an object of OM class DS_C_SESSION, created with default values of all its OM attributes, works with all the interface functions. Local administrators need to ensure that this is the case. Such a session can be created by passing the constant DS_DEFAULT_SESSION as an argument to ds_bind( ).