Manage Mangle Rule
manage_mangle_ruleAdd, remove, enable, or disable firewall mangle rules with comment-based idempotency and optional dry-run mode.
Instructions
Add, remove, enable, or disable a firewall mangle rule. Uses comment as idempotency key. Supports dry-run mode.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| routerId | Yes | Target router identifier from the router registry | |
| action | Yes | Action to perform | |
| comment | Yes | Idempotency key — uniquely identifies this mangle rule | |
| chain | No | Mangle chain (required on add): prerouting, input, forward, output, postrouting | |
| dryRun | No | Preview changes without applying | |
| srcAddress | No | Source IP/CIDR to match | |
| dstAddress | No | Destination IP/CIDR to match | |
| srcAddressList | No | Source address list name to match | |
| dstAddressList | No | Destination address list name to match | |
| protocol | No | Protocol to match (e.g. tcp, udp) | |
| srcPort | No | Source port or range | |
| dstPort | No | Destination port or range | |
| inInterface | No | Incoming interface to match | |
| outInterface | No | Outgoing interface to match | |
| newRoutingMark | No | Routing mark to set | |
| newConnectionMark | No | Connection mark to set | |
| newDscpValue | No | DSCP value to set (0–63) | |
| passthrough | No | Whether to continue matching subsequent rules |