设置 群集数据库 密钥的安全属性。
语法
LONG ClusterRegSetKeySecurity(
  [in] HKEY                 hKey,
  [in] SECURITY_INFORMATION SecurityInformation,
  [in] PSECURITY_DESCRIPTOR pSecurityDescriptor
);
参数
[in] hKey
群集数据库密钥的句柄。
[in] SecurityInformation
指示 pSecurityDescriptor 指向的安全描述符内容SECURITY_INFORMATION结构。
[in] pSecurityDescriptor
指向 SECURITY_DESCRIPTOR 结构的指针,该结构描述要为对应于 hKey 的密钥设置的安全属性。
返回值
如果操作成功,函数将返回 ERROR_SUCCESS (0) 。
如果操作失败,该函数将返回 系统错误代码。
备注
ClusterRegSetKeySecurity 函数为所有已注册的通知端口生成CLUSTER_CHANGE_REGISTRY_ATTRIBUTES事件。
不要从以下资源 DLL 入口点函数调用 ClusterRegSetKeySecurity :
可以从任何其他资源 DLL 入口点函数或工作线程安全地调用 ClusterRegSetKeySecurity。 有关详细信息,请参阅 在资源 DLL 中对避免的函数调用。要求
| 最低受支持的客户端 | 无受支持的版本 | 
| 最低受支持的服务器 | Windows Server 2008 Enterprise、Windows Server 2008 Datacenter | 
| 目标平台 | Windows | 
| 标头 | clusapi.h | 
| Library | ClusAPI.lib | 
| DLL | ClusAPI.dll |