Freigeben über


CTokenPrivileges::LookupPrivilege

Retrieves the attribute associated with a given privilege name.

bool LookupPrivilege( 
   LPCTSTR pszPrivilege, 
   DWORD * pdwAttributes = NULL  
) const throw(...);

Parameters

  • pszPrivilege
    Pointer to a null-terminated string that specifies the name of the privilege, as defined in the WINNT.H header file. For example, this parameter could specify the constant SE_SECURITY_NAME, or its corresponding string, "SeSecurityPrivilege."

  • pdwAttributes
    Pointer to a variable that receives the attributes.

Return Value

Returns true if the attribute is successfully retrieved, false otherwise.

Requirements

Header: atlsecurity.h

See Also

Reference

CTokenPrivileges Class

CTokenPrivileges::GetNamesAndAttributes

CTokenPrivileges::GetDisplayNames

CTokenPrivileges::GetLuidsAndAttributes