# Ensure 'Computer Browser (Browser)' is set to 'Disabled' or 'Not Installed'

The 'Computer Browser' service is a legacy component that maintains a list of computers on a network using the outdated NetBIOS protocol. It is not necessary in modern networks that rely on DNS and Active Directory for name resolution and resource discovery. Enabling this service unnecessarily increases the network's attack surface, as it broadcasts information about network hosts that can be leveraged by attackers for reconnaissance. Misconfiguration leaves the system vulnerable to information disclosure and potential exploitation of the NetBIOS protocol. The audit script verifies the startup type of the 'Browser' service, returning its current state or 'Not Installed' if absent. The remediation script sets the service's startup type to 'Disabled', preventing it from running. The recommended state for all security levels (Basic, Moderate, and Strict) is consistently 'Disabled' or 'Not Installed'. This is because there is no secure use case for this service in a modern environment. Disabling it is a fundamental hardening step recommended by security benchmarks like CIS to reduce network exposure and eliminate a legacy vulnerability vector.

## Recommended State Configuration

| Security Level | Value |
|----------------|-------|
| **Basic** | `['Disabled', 'Not Installed']` |
| **Moderate** | `['Disabled', 'Not Installed']` |
| **Strict** | `['Disabled', 'Not Installed']` |
| **Type** | `ENUM` |

## Audit Script Working

PowerShell script that checks the startup type of the 'Computer Browser' service (service name 'Browser'). If the service does not exist, the script must return the string 'Not Installed'. Otherwise, it must return the current 'StartType' of the service (e.g., 'Disabled', 'Automatic'). The script must only output this value and nothing else.

## Remediation Script Working

PowerShell script that accepts one positional command-line argument: the desired state for the 'Computer Browser' service (service name 'Browser'). The script will set the service's 'StartType' to the provided value (e.g., 'Disabled'). If the service does not exist, the action is considered successful. The script must return `$true` on success or `$false` on failure.

