Directory Services

DSDISPLAYSPECOPTIONS

The DSDISPLAYSPECOPTIONS structure is returned by the CFSTR_DS_DISPLAY_SPEC_OPTIONS clipboard format used to supply data to a context menu or property page extension about the display specifiers used. It is important, to specify the credentials required by the extension, to access data in the Active Directory®.

typedef struct _DSDISPLAYSPECOPTIONS {
DWORD dwSize;
DWORD dwFlags;
DWORD offsetAttribPrefix;
DWORD offsetUserName;
DWORD offsetPassword;
DWORD offsetServer;
DWORD offsetServerConfigPath; } DSDISPLAYSPECOPTIONS,
*PDSDISPLAYSPECOPTIONS,
*LPDSDISPLAYSPECOPTIONS;

Members

dwSize
The size of the structure for versioning purposes.
dwFlags
A set of flags that indicate data about the object and define the contents of the structure. This can be zero or a combination of one or more of the following values.
Value Meaning
DSDSOF_HASUSERANDSERVERINFO
0x00000001
The offsetUserName, offsetPassword, offsetServer and offsetServerConfigPath members are valid.
DSDSOF_SIMPLEAUTHENTICATE
0x00000002
Do not specify ADS_SECURE_AUTHENTICATION flag when calling ADsOpenObject.
DSDSOF_DONTSIGNSEAL
0x00000004
Do not sign and seal when opening directory service objects.
DSDSOF_DSAVAILABLE
0x40000000
Forces the client to avoid checking if the user is authenticated, the network is present or logged in, assuming the client belongs to an Active Directory domain.
offsetAttribPrefix
Contains the offset, in bytes, from the start of the DSDISPLAYSPECOPTIONS structure to a NULL-terminated, Unicode string that contains the prefix of the display specifier that the created extension was obtained from. This string can be one of the following values.
Value Meaning
"admin" The extension was obtained from the adminPropertyPages attribute.
"shell" The extension was obtained from the shellPropertyPages attribute.

The following example shows how to use this member.

pwszAttribPrefix = (LPWSTR)((LPBYTE)pdos + pdso->offsetAttribPrefix);
offsetUserName
Contains the offset, in bytes, from the start of the DSDISPLAYSPECOPTIONS structure to a NULL-terminated, Unicode string that contains the name of the user used to authenticate the bind. This member is only valid if dwFlags contains the DSDSOF_HASUSERANDSERVERINFO flag. If this member contains zero, the user name is not included.

The following example shows how to use this member.

pwszUserName = (LPWSTR)((LPBYTE)pdso + pdso->offsetUserName);
offsetPassword
Contains the offset, in bytes, from the start of the DSDISPLAYSPECOPTIONS structure to a NULL-terminated, Unicode string that contains the password used to authenticate the bind. This member is only valid if dwFlags contains the DSDSOF_HASUSERANDSERVERINFO flag. If this member contains zero, the password is not included.

The following example shows how to use this member.

pwszPassword = (LPWSTR)((LPBYTE)pdso + pdso->offsetPassword);
offsetServer
Contains the offset, in bytes, from the start of the DSDISPLAYSPECOPTIONS structure to a NULL-terminated, Unicode string that contains the name of the server. This member is only valid if dwFlags contains the DSDSOF_HASUSERANDSERVERINFO flag. If this member contains zero, the server name is not included.

The following example shows how to use this member.

pwszServer = (LPWSTR)((LPBYTE)pdso + pdso->offsetServer);
offsetServerConfigPath
Contains the offset, in bytes, from the start of the DSDISPLAYSPECOPTIONS structure to a NULL-terminated, Unicode string that contains the ADsPath of the server. This member is only valid if dwFlags contains the DSDSOF_HASUSERANDSERVERINFO flag. If this member contains zero, the server path is not included.

The following example shows how to use this member.

pwszServerConfigPath = (LPWSTR)((LPBYTE)pdso + pdso->offsetServerConfigPath);

Requirements

Client: Included in Windows XP and Windows 2000 Professional.
Server: Included in Windows Server 2003 and Windows 2000 Server.
Header: Declared in Dsclient.h.

See Also

Active Directory Display Structures, ADsOpenObject, CFSTR_DS_DISPLAY_SPEC_OPTIONS