3.1.5.5.5 SamrQueryInformationUser2 (Opnum 47)
The SamrQueryInformationUser2 method obtains attributes from a user object.
-
long SamrQueryInformationUser2( [in] SAMPR_HANDLE UserHandle, [in] USER_INFORMATION_CLASS UserInformationClass, [out, switch_is(UserInformationClass)] PSAMPR_USER_INFO_BUFFER* Buffer );
UserHandle: An RPC context handle, as specified in section 2.2.7.2, representing a user object.
UserInformationClass: An enumeration indicating which attributes to return. See section 2.2.6.28 for a list of possible values.
Buffer: The requested attributes on output. See section 2.2.6.29 for structure details.
This protocol asks the RPC runtime, via the strict_context_handle attribute, to reject the use of context handles created by a method of a different RPC interface than this one, as specified in [MS-RPCE] section 3.
Upon receiving this message, the server MUST process the data from the message subject to the following constraints:
The server MUST return an error if UserHandle.HandleType is not equal to "User".
UserHandle.GrantedAccess MUST have the required access specified in Common Processing (section 3.1.5.5.5.1).
If UserInformationClass is set to UserAllInformation, the constraints in section 3.1.5.5.5.2 ("UserAllInformation") MUST be satisfied. Otherwise, the constraints in section 3.1.5.5.5.1 ("Common Processing") MUST be satisfied.
The following bits in Buffer.All.WhichFields, and their corresponding field values, MUST never be returned by the server.
WhichFields bits
USER_ALL_NTPASSWORDPRESENT
0x01000000
USER_ALL_LMPASSWORDPRESENT
0x02000000
USER_ALL_PRIVATEDATA
0x04000000
USER_ALL_PASSWORDEXPIRED
0x08000000
USER_ALL_SECURITYDESCRIPTOR
0x10000000