大网数据广告活动
域与目录服务

Setting a Control Access Right ACE in an Object's ACL

· 52CE 我爱测

Using ADSI, you set a control access right ACE just as you would a property-specific ACE, except that the IADsAccessControlEntry.ObjectType property is the rightsGUID of the control access right.

Using ADSI, you set a control access right ACE just as you would a property-specific ACE, except that the IADsAccessControlEntry.ObjectType property is the rightsGUID of the control access right. Be aware that you can also use the Win32 security APIs to set ACLs on directory objects.

The following table lists the IADsAccessControlEntry properties for control access rights that can be used to set properties for an ACE.

Property Description
AccessMask For control access rights that control extended rights access to special operations, AccessMask must contain the ADS_RIGHT_DS_CONTROL_ACCESS flag. For control access rights that define a property set, AccessMask contains ADS_RIGHT_DS_READ_PROP and/or ADS_RIGHT_DS_WRITE_PROP. For control access rights that control validated writes, AccessMask contains ADS_RIGHT_DS_SELF.
Flags This value must include the ADS_FLAG_OBJECT_TYPE_PRESENT flag.
ObjectType This value must be the StringFromGUID2 format of the rightsGUID attribute of the control access right. Be aware that, in an ACE, the GUID string must include the starting and terminating curly braces even though the rightsGUID attribute of the controlAccessRight object does not include the curly braces.
AceType Either ADS_ACETYPE_ACCESS_ALLOWED_OBJECT to grant the trustee the access control right or ADS_ACETYPE_ACCESS_DENIED_OBJECT to deny the trustee the control access right.
Trustee The security principal, for example user, group, computer, and so on, to which the ACE applies.

For more information about creating an ACE, see Setting Access Rights on an Object.

For more information and a code example for setting an ACE, see Example Code for Setting an ACE on a Directory Object.

Source: Microsoft Learn / Windows Win32 documentation by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / Windows Win32 documentation
适用范围
Windows Win32 API · Source date 05/31/2018
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。