ICertAdmin2::GetMyRoles method (certadm.h)
The GetMyRoles method retrieves the certification authority (CA) roles of the caller.
HRESULT GetMyRoles( const BSTR strConfig, LONG *pRoles );
String value that represents a valid configuration string for the CA in the form COMPUTERNAME\CANAME, where COMPUTERNAME is the Certificate Services server's network name, and CANAME is the common name of the CA, as entered during Certificate Services setup. For information about the configuration string name, see ICertConfig.
A pointer to a LONG value that represents the retrieved CA roles for the caller. This can be a bitwise combination of zero or more of the following values.
C++If the function is successful, the return value is S_OK.
If the function fails, the return value is an HRESULT that indicates the error. For a list of common error codes, see Common HRESULT Values.
VBThe return value is a Long value that represents the retrieved CA roles for the caller. This can be a bitwise combination of zero or more of the following values.
||Caller has CA administrator capability.|
||Caller has CA auditor capability.|
||Caller has enrollment access.|
||Caller has CA officer capability.|
||Caller has CA backup capability.|
||Caller has read access.|
|Minimum supported client||None supported|
|Minimum supported server||Windows Server 2003 [desktop apps only]|
|Header||certadm.h (include Certsrv.h)|