Managing and Configuring DHCP Filters

Overview of DHCP Filters

  • DHCP filters are available for IPv4 within the DHCP management console (such as on server DC1), but are not available for IPv6.
  • A red arrow pointing down on a filter indicates that it is currently disabled.
  • Filters can be enabled via the right-click shortcut menu.
  • DHCP filters are categorized into two types:
    • Allow Filter: Functions as a whitelist (implicit deny).
    • Deny Filter: Functions as a blacklist (implicit allow).

Filter Types and MAC Address Configuration

  • Allow Filters:
    • Deny IP address requests from all devices unless their MAC address is explicitly listed.
    • Require MAC addresses to be formatted as six pairs of numbers separated by dashes, with an optional description.
    • Ideal for high-security environments, but present high management overhead due to requiring manual updates for every client or network card change.
  • Deny Filters:
    • Allow IP addresses to be issued to all clients except MAC addresses specified in the list.
    • Used to restrict rogue (unauthorized) devices from acquiring DHCP leases (does not prevent static IP configuration).

NetSH Command Line Configuration

  • Administration requires launching Command Prompt as an administrator.
  • Enable/Disable Filters:
    • netsh dhcp server v4 set filter enforceallowlist=1 enforcedenylist=0
    • Both enforceallowlist and enforcedenylist options must be specified together to avoid errors (1 turns the list on, 0 turns it off).
  • Add MAC Address to Allow List:
    • netsh dhcp server v4 add filter allow <MAC Address> <Description>

PowerShell Configuration

  • Administration requires launching PowerShell as an administrator.
  • Enable/Disable Filters:
    • Set-DhcpServerv4FilterList -ComputerName DC1 -Allow true -Deny false
  • Add MAC Address to Allow List:
    • Add-DhcpServerv4Filter specifying the target list (allow), MAC address, and description.

Operational Considerations

  • Administrative changes in the GUI require refreshing the console to view updated filter states and entries.
  • If clients encounter unexpected issues receiving IP addresses, active DHCP filter configurations should be inspected first.