community.windows.win_audit_policy_system – Used to make changes to the system wide Audit Policy¶
Note
This plugin is part of the community.windows collection (version 1.3.0).
To install it use: ansible-galaxy collection install community.windows
.
To use it in a playbook, specify: community.windows.win_audit_policy_system
.
Parameters¶
Notes¶
Note
It is recommended to take a backup of the policies before adjusting them for the first time.
See this page for in depth information https://technet.microsoft.com/en-us/library/cc766468.aspx.
See Also¶
See also
- community.windows.win_audit_rule
The official documentation on the community.windows.win_audit_rule module.
Examples¶
- name: Enable failure auditing for the subcategory "File System"
community.windows.win_audit_policy_system:
subcategory: File System
audit_type: failure
- name: Enable all auditing types for the category "Account logon events"
community.windows.win_audit_policy_system:
category: Account logon events
audit_type: success, failure
- name: Disable auditing for the subcategory "File System"
community.windows.win_audit_policy_system:
subcategory: File System
audit_type: none
Return Values¶
Common return values are documented here, the following are the fields unique to this module:
Key | Returned | Description |
---|---|---|
current_audit_policy
dictionary
|
always |
details on the policy being targetted
Sample:
{
"File Share":"failure"
}
|
Authors¶
Noah Sparks (@nwsparks)