OPNexusdocs

Deploying rules safely

In this chapter#

  • The flow — Centrally maintained rules (Policy › Rules) always follow the same path:
  • Table view, usage and overlaps — The rule list has two views (switch at the top right, your choice is remembered in the browser): Cards and the compact Table (the default). The table shows one line per r
  • Deploying several rules at once — Tick the rules in the list (or Select all shown) and click Review and deploy (N), at most 50 at a time. The dialog loads the preview of every rule; rules with nothing to
  • Keyboard and bulk changes on the rules page — With the table or the cards shown, the list can be used without the mouse. j / k (or the arrow keys once a row is marked) move a cursor through the rules that are shown;
  • Management path check — The automatic rollback runs inside OPNexus and needs the way from OPNexus to the firewall's API. A rule that blocks exactly that way cannot be taken back automatically. S
  • Comment on deploy — Every deploy (single and bulk) takes an optional comment (why does this go out now? ticket number). It is kept in the audit entries of the deployment and shown in the aud
  • Position in the rule list — Firewalls evaluate rules from top to bottom; the first match wins. OPNsense puts new rules at the end; a block rule behind a matching allow rule therefore never takes eff
  • Viewing the order, moving and editing rules — The Live across all hosts tab shows per firewall (an HA pair together, single firewalls on their own) all rules in the order in which the firewall evaluates them. A badge
  • Rules that exist only on individual firewalls — Below the list of central rules, the collapsible section Only on individual firewalls shows the rules that were created by hand directly on a firewall and are not central
  • States of a rule — The backend computes the state from targets and deployments: targets missing, target hosts disabled, changes pending, confirmation pending, check error, *check
  • Cleaning up targets — Under "Preview & push" former targets can be removed individually: OPNexus deletes the rule only on that host; the central rule and its other deployments remain. This tak
  • Live view and drift
  • Adopting hand-made rules — Rules that the model would distort are not adopted: inverted interface, source or destination, several or no interface, "received on", non-quick rule, direction neither i
  • Adopting aliases and NAT from the firewall — Like rules, aliases and NAT rules (port forward, 1:1, outbound) that were created by hand in OPNsense can be adopted: on the respective page Adopt from firewall, choose t