大网数据广告活动
Windows排障命令

auditpol resourceSACL

· 52CE 我爱测

Reference article for the auditpol resourceSACL command, which configures global resource system access control lists (SAcls).

Configures global resource system access control lists (SACLs).

To perform resourceSACL operations, you must have Write or Full Control permissions for that object set in the security descriptor. You can also perform resourceSACL operations if you have the Manage auditing and security log (SeSecurityPrivilege) user right.

Syntax

auditpol /resourceSACL
[/set /type:<resource> [/success] [/failure] /user:<user> [/access:<access flags>]]
[/remove /type:<resource> /user:<user> [/type:<resource>]]
[/clear [/type:<resource>]]
[/view [/user:<user>] [/type:<resource>]]

Parameters

Parameter Description
/set Adds a new entry to or updates an existing entry in the resource SACL for the resource type specified.
/remove Removes all entries for the given user in the global object access auditing list.
/clear Removes all entries from the global object access auditing list.
/view Lists the global object access auditing entries in a resource SACL. The user and resource types are optional.
/? Displays help at the command prompt.

Arguments

Argument Description
/type The resource for which object access auditing is being configured. The supported, case-sensitive, argument values are File (for directories and files) and Key (for registry keys).
/success Specifies success auditing.
/failure Specifies failure auditing.
/user Specifies a user in one of the following forms:<ul><li> DomainName\Account (such as DOM\Administrators)</li><li>StandaloneServer\Group Account (see LookupAccountName function)</li><li>{S-1-x-x-x-x} (x is expressed in decimal, and the entire SID must be enclosed in curly braces). For example: {S-1-5-21-5624481-130208933-164394174-1001}Note: If the SID form is used, no check is done to verify the existence of this account.</li></ul>
/access Specifies a permission mask that can be specified through:Generic access rights, including:<ul><li>GA - GENERIC ALL</li><li>GR - GENERIC READ</li><li>GW - GENERIC WRITE</li><li>GX - GENERIC EXECUTE</li></ul>Access rights for files, including:<ul><li>FA - FILE ALL ACCESS</li><li>FR - FILE GENERIC READ</li><li>FW - FILE GENERIC WRITE</li><li>FX - FILE GENERIC EXECUTE</li></ul>Access rights for registry keys, including:<ul><li>KA - KEY ALL ACCESS</li><li>KR - KEY READ</li><li>KW - KEY WRITE</li><li>KX - KEY EXECUTE</li></ul>For example: /access:FRFW enables audit events for read and write operations.A hexadecimal value representing the access mask (such as 0x1200a9)This is useful when using resource-specific bit masks that are not part of the security descriptor definition language (SDDL) standard. If omitted, Full access is used.

Examples

To set a global resource SACL to audit successful access attempts by a user on a registry key:

auditpol /resourceSACL /set /type:Key /user:MYDOMAIN\myuser /success

To set a global resource SACL to audit successful and failed attempts by a user to perform generic read and write functions on files or folders:

auditpol /resourceSACL /set /type:File /user:MYDOMAIN\myuser /success /failure /access:FRFW

To remove all global resource SACL entries for files or folders:

auditpol /resourceSACL /type:File /clear

To remove all global resource SACL entries for a particular user from files or folders:

auditpol /resourceSACL /remove /type:File /user:{S-1-5-21-56248481-1302087933-1644394174-1001}

To list the global object access auditing entries set on files or folders:

auditpol /resourceSACL /type:File /view

To list the global object access auditing entries for a particular user that are set on files or folders:

auditpol /resourceSACL /type:File /view /user:MYDOMAIN\myuser

Related links

Source: Microsoft Learn / Windows Server documentation by Microsoft and contributors (upstream author metadata: robinharwood). 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 Server documentation
适用范围
Windows Server · Source date 10/16/2017
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

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

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