opn_update_firewall_rule
Modify a firewall rule's settings via UUID; unconfirmed changes automatically revert after 60 seconds.
Instructions
Update an existing MVC firewall rule by UUID with savepoint protection.
Use this when you need to modify a firewall rule's action, source/destination, protocol, ports, or other properties. Only the parameters you provide are changed; all other settings are preserved.
Changes auto-revert in 60 seconds unless confirmed with opn_confirm_changes. Use opn_list_firewall_rules first to find the UUID.
Parameters:
uuid: rule UUID (from opn_list_firewall_rules)
action: 'pass', 'block', or 'reject'
direction: 'in' or 'out'
interface: interface name (e.g. 'lan', 'wan', 'opt1')
ip_protocol: 'inet' (IPv4), 'inet6' (IPv6), or 'inet46' (dual-stack)
protocol: 'any', 'TCP', 'UDP', 'TCP/UDP', 'ICMP', etc.
source_net: source address/network or 'any'
source_not: invert source match
source_port: source port number or range
destination_net: destination address/network or 'any'
destination_not: invert destination match
destination_port: port number or range
gateway: force traffic via specific gateway, or empty to clear
log: enable/disable logging
quick: first-match wins (True) or last-match-wins (False)
sequence: rule ordering within priority group
categories: comma-separated category UUIDs
description: human-readable rule description
enabled: enable/disable the rule
Returns: dict with 'revision' (str), 'uuid' (str), and 'result' (str).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| uuid | Yes | ||
| action | No | ||
| direction | No | ||
| interface | No | ||
| ip_protocol | No | ||
| protocol | No | ||
| source_net | No | ||
| source_not | No | ||
| source_port | No | ||
| destination_net | No | ||
| destination_not | No | ||
| destination_port | No | ||
| gateway | No | ||
| log | No | ||
| quick | No | ||
| sequence | No | ||
| categories | No | ||
| description | No | ||
| enabled | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||