Skip to content

audit_open_ports

Audit WAN-facing exposure (port forwards and WAN_IN accept rules).

Side effects: None (read-only).

Cross-references firewall rules and port forwards to summarise what is reachable from the public internet:

  • Active port forwards (DNAT into the LAN).
  • WAN_IN accept rules, excluding the boilerplate established/related rule.

Useful as a “did I leave something open?” sanity check before publishing a service or shipping a config.

audit_open_ports(controller="default")
ParameterTypeRequiredDefaultDescription
controllerstringno”default”Name of the UniFi controller to target. Defaults to "default".