NWDSListAttrsEffectiveRights(3nw)
NWDSListAttrsEffectiveRights --
returns an object's effective privileges on another object
Synopsis
#include <nwnet.h>
or
#include <nwdsacl.h>
NWDSCCODE N_API NWDSListAttrsEffectiveRights
(NWDSContextHandle context,
pnstr8 objectName,
pnstr8 subjectName,
nbool8 allAttrs,
pBuf_T attrNames,
pnint32 iterationHandle,
pBuf_T privilegeInfo);
Description
The parameters are as follows:
- context
-
(IN) Specifies the Directory context for the request.
- objectName
-
(IN) Points to the name of the Directory object whose access rights are to be checked.
- subjectName
-
(IN) Points to the name of the Directory object to which the privileges are assigned.
- allAttrs
-
(IN) Specifies whether all attributes should be returned.
- attrNames
-
(IN) Points to a request buffer containing the names of the attribute definitions for which information is to be returned.
- iterationHandle
-
(IN/OUT) Points to the information needed to resume subsequent iterations of NWDSListAttrsEffectiveRights.
- privilegeInfo
-
(OUT) Points to a result buffer receiving the requested attribute names and privileges.
Return values
- 0x0000
-
SUCCESSFUL
- Negative Value
-
Negative values indicate errors. For errors returned by Directory Services,
see ``Directory Services OS Errors'' (-001 to -255), ``Directory Services
Client Library Errors'' (-301 to -399), or ``Directory Services Agent in the
Server Errors'' (-601 to -699).
- 0x8996
-
SERVER_OUT_OF_MEMORY
- 0x89E2
-
TOO_FEW_FRAGMENTS
- 0x89E3
-
TOO_MANY_FRAGMENTS
- 0x89E4
-
PROTOCOL_VIOLATION
- 0x89E5
-
SIZE_LIMIT_EXCEEDED
- 0x89FD
-
UNKNOWN_REQUEST
- 0x89FD
-
INVALID_PACKET_LENGTH
- 0x89FE
-
BAD_PACKET
- 0x89FF
-
Failure not related to Directory Services
Notices
subjectName is the name of a directory object. If
subjectName is NULL, the name of the currently
logged-in object is used.
allAttrs and attrNames indicate which attributes you are
requesting privileged information about. If allAttrs is TRUE, privileged information about
all optional and mandatory attributes defined for the base class of the object are returned. NULL can also be passed for attrNames when
allAttrs is TRUE. If
allAttrs is FALSE, privileged information is returned only about the attributes named in the buffer pointed to by attrNames.
attrNames points to a request buffer explicitly specifying the names of the attributes for which information is to be returned.
iterationHandle controls retrieval of list results larger than the result buffer pointed to by attrNames.
Before the initial call to NWDSListAttrsEffectiveRights, set the
contents of the iteration handle pointed to by iterationHandle to
NO_MORE_ITERATIONS.
If the result buffer holds the complete results when NWDSListAttrsEffectiveRights returns from its initial call, the location pointed to by iterationHandle is
set to NO_MORE_ITERATIONS. If the iteraition handle is not set to
NO_MORE_ITERATIONS, use the iteration handle for subsequent calls to NWDSListAttrsEffectiveRights in
order to obtain further portions of the results. When the results are
completely retrieved, the contents of the iteration handle will be set to
NO_MORE_ITERATIONS.
To end the List operation before the complete results have been retrieved,
call NWDSCloseIteration with a value of DSV_LIST to free
memory and states associated with
the List operation.
Determine an object's effective privileges on another object by following these steps:
-
Allocate the result buffer by calling NWDSAllocBuf. This buffer does not need to be initialized since it is a result buffer.
-
If you want to retrieve information for selected attributes, complete steps 3 through 5. To retrieve information for all of the object's attributes, skip to step 6.
-
Allocate the request buffer by calling NWDSAllocBuf.
-
Initialize the request buffer for a DSV_READ operation by calling NWDSInitBuf.
-
Place the attribute names in the request buffer by calling NWDSPutAttrName once for each attribute name.
-
Call NWDSListAttrsEffectiveRights.
-
Determine the number of attributes in the result buffer by calling NWDSGetAttrCount.
-
For each attribute in the result buffer, retrieve the information by calling NWDSGetAttrVal.
-
If the iteration handle is not set to NO_MORE_ITERATIONS, loop to step 6. Otherwise, go to step 10.
-
Free the request buffer by calling NWDSFreeBuf.
-
Free the result buffer by calling NWDSFreeBuf.
The level of granularity for partial results is an attribute name and privilege.
Services
Directory
NCP calls
- 0x2222 23 17
-
Get File Server Information
- 0x2222 23 22
-
Get Station's Logged Info (old)
- 0x2222 23 28
-
Get Station's Logged Info
- 0x2222 104 01
-
Ping for NDS NCP
- 0x2222 104 02
-
Send NDS Fragmented Request/Reply
References
NWDSAllocBuf(3nw),
NWDSGetAttrVal(3nw),
NWDSInitBuf(3nw)
30 January 1998
© 1998 The Santa Cruz Operation, Inc. All rights reserved.