# Ensure 'Windows Firewall: Private: Settings: Display a notification' is set to 'No'

The necessity of this setting is to prevent users from inadvertently creating security vulnerabilities. When the firewall blocks an application, a notification can prompt a user to create an exception. Disabling these notifications ensures that firewall policies are enforced without user intervention, reducing the risk of unauthorized access or malware propagation. The audit script checks the current state of the notification setting for the private network profile. The remediation script modifies this setting to either enable or disable notifications based on the provided argument. The recommended state for Basic, Moderate, and Strict levels is 'No' because allowing notifications introduces a significant risk. Any security posture requires that centrally managed firewall rules are not circumvented by end-users, making the disabling of notifications a fundamental security requirement.

## Recommended State Configuration

| Security Level | Value |
|----------------|-------|
| **Basic** | `['No']` |
| **Moderate** | `['No']` |
| **Strict** | `['No']` |
| **Type** | `ENUM` |

## Audit Script Working

PowerShell script to query the Windows Defender Firewall configuration for the 'Private' network profile. The script must retrieve the value of the 'DisableNotifications' property using the 'Get-NetFirewallProfile' cmdlet. The output should be 'No' if the property is 'True' (notifications disabled), and 'Yes' if it is 'False' (notifications enabled), with no additional text or labels.

## Remediation Script Working

PowerShell script that accepts a single positional argument ('Yes' or 'No') to configure the firewall notification setting for the 'Private' profile. The script must use the 'Set-NetFirewallProfile' cmdlet to set the '-DisableNotifications' parameter to '$true' if the input is 'No', and to '$false' if the input is 'Yes'. The script must return '$true' on success and '$false' on failure.

