CTokenPrivileges::LookupPrivilege

检索特性与给定的权限集的名称。

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

参数

  • pszPrivilege
    为指定权限的名称为Null结尾的字符串的指针,对于WINNT.H标头文件定义。 例如,此参数中指定常数SE_SECURITY_NAME,或其对应的字符串,“SeSecurityPrivilege”。

  • pdwAttributes
    用于接收属性的变量的指针。

返回值

否则返回true,则属性已成功检索,错误。

要求

Header: atlsecurity.h

请参见

参考

CTokenPrivileges选件类

CTokenPrivileges::GetNamesAndAttributes

CTokenPrivileges::GetDisplayNames

CTokenPrivileges::GetLuidsAndAttributes