Project

AuditPolicy

AuditPolicy module aims to replace auditpol.exe to get or set Auditing Policies in Windows in more native PowerShell way

Stars11
Forks2
Open issues0
PowerShell Gallery downloads23373
Releasev0.0.6
Language: PowerShell Updated: 2026-02-14T21:44:05.0000000+00:00

Curated Examples

Review audit policy settings

Read Windows audit policy settings by category and by policy name.

This pattern is useful when you need to understand the current local audit policy state before making changes.

It is adapted from Examples/GetAuditPolicies.ps1.

Example

Import-Module AuditPolicy

$auditPolicies = Get-SystemAuditPolicy -Categories
$auditPolicies | Format-Table

$auditPolicies.AccountLogon | Format-Table
$auditPolicies.LogonLogoff | Format-Table
$auditPolicies.PolicyChange | Format-Table

Get-SystemAuditPolicy -Policy 'Application Group Management'

What this demonstrates

  • reading audit policy grouped by category
  • narrowing the output to a single policy
  • creating a quick review point before changes

Source