An instance of OM class DSX_C_GDS_SESSION identifies a particular link from an application program to a GDS DUA. This additional OM class is necessary if the user either wants to specify an authentication mechanism or wants to specify the GDS directory identifier, or alternatively wants to specify both an authentication mechanism and the directory identifier. DSX_C_GDS_SESSION can be passed as an argument to ds_bind( ).
An instance of this OM class has the OM attributes of its superclasses, OM_C_OBJECT and DS_C_SESSION, in addition to the OM attributes listed in the following table.
OM Attributes of DSX_C_GDS_SESSION
OM Attribute |
Value Syntax | Value Length | Value Number | Value Initially |
DSX_PASSWORD | String(OM_S_ OCTET_ STRING) |
- | 0 or 1 | - |
DSX_DIR_ID | OM_S_ INTEGER |
- | 1 | 1 |
DSX_AUTH_ MECHANISM |
Enum(DSX_ Auth_ Mechanism) |
- | 01 | - |
DSX_AUTH_ INFO |
String(OM_S_ OCTET_ STRING) |
- | 01 | - |
· DSX_PASSWORD
This attribute indicates the password for the user credentials.
· DSX_DIR_ID
This attribute contains an identifier for distinguishing between several configurations of the directory service within a GDS installation. The valid range is from 1 to 20.
· DSX_AUTH_MECHANISM
If this attribute is present, then it identifies the authentication mechanism that the application requests. If it is absent or has the value DSX_NONE_AT_ALL, then a ds_bind( ) without credentials (anonymous bind) is requested. The values which this attribute can take are as follows:
- DSX_NONE_AT_ALL. No authentication.
- DSX_DEFAULT. The default authentication mechanism is to use DCE authentication, therefore, DSX_DEFAULT defaults to DSX_DCE_AUTH. The value for DSX_DEFAULT can be modified through an environment variable XDS_DEF_AUTH_MECH. The value of this environment variable is checked by the XDS software following a ds_initialize( ) function call.
- DSX_SIMPLE. This requests simple authentication by using the DS_REQUESTOR and DSX_PASSWORD attributes of the DSX_C_GDS_SESSION object.
- DSX_SIMPLE_PROT1. This is reserved for future use.
- DSX_SIMPLE_PROT2. This is reserved for future use.
- DSX_DCE_AUTH. This requests the use of the DCE authentication mechanism.
- DSX_STRONG. This is reserved for future use.
If an authentication mechanism is selected that is not currently supported, then ds_bind( ) returns a DS_E_NOT_SUPPORTED error. If the selected authentication mechanism requires the user's credentials that cannot be assembled, then a DS_E_NO_INFO error is returned.
· DSX_AUTH_INFO
This attribute is Reserved for future use.
Applications can assume that an object of OM class DSX_C_GDS_SESSION, created with default values of all its OM attributes, works with all the interface functions. Such a session can be created by passing the constant DS_DEFAULT_SESSION as an argument to ds_bind( ), having already negotiated the GDS package.
The following table defines DSX_C_GDS_SESSION.
Default DSX_C_GDS_SESSION
OM Attribute | Default Value |
DS_DSA_ADDRESS | Value obtained from the cache or absent |
DS_DSA_NAME | Value obtained from the cache or absent |
DS_FILE_DESCRIPTOR | DS_NO_VALID_FILE_DESCRIPTOR |
DSX_DIR_ID | 1 |
DSX_AUTH_MECHANISM | Absent |
DSX_AUTH_INFO | Absent |