Optional
dportSelect the destination port value to match. Supports port range.
Optional
fromSelect the source prefix to match.
Optional
fwmarkSelect the fwmark value to match.
Optional
gotoAttribute is used to jump to a rule with a specified priority. It essentially alters the typical sequence in which rules are evaluated.
Optional
iifSelect the incoming device to match.
If the interface is loopback, the rule only matches packets originating from this host. This means that you may create separate routing tables for forwarded and local packets and, hence, completely segregate them.
Optional
ipprotoSelect the ip protocol value to match.
Optional
l3mdevPertains to layer 3 master device-based routing, particularly relevant when using Virtual Routing and Forwarding (VRF) tables.
Optional
natThe base of the IP address block to translate (for source addresses). The ADDRESS may be either the start of the block of NAT addresses (selected by NAT routes) or a local host address (or even zero).
In the last case the router does not translate the packets, but masquerades them to this address.
Using map-to
instead of nat
means the same thing.
Optional
notInvert the rule.
Optional
oifSselect the outgoing device to match. The outgoing interface is only available for packets originating from local sockets that are bound to a device.
Optional
preferenceThe priority of this rule.
PREFERENCE is an unsigned integer value, higher number means lower priority, and rules get processed in order of increasing number.
Each rule should have an explicitly set unique priority value. The options preference and order are synonyms with priority.
Optional
protocolThe routing protocol who installed the rule in question. As an example when zebra installs a rule it would get RTPROT_ZEBRA as the installing protocol.
Optional
realmsRealms to select if the rule matched and the routing table lookup succeeded. Realm TO is only used if the route did not select any realm.
Optional
sportSelect the source port value to match. Supports port range.
Optional
suppress_Reject routing decisions that use a device belonging to the interface group GROUP.
Optional
suppress_Reject routing decisions that have a prefix length of NUMBER or less.
Optional
tableThe routing table identifier to lookup if the rule selector matches. It is also possible to use lookup instead of table.
Optional
toSelect the destination prefix to match.
Optional
tosSelect the TOS value to match.
Optional
tun_Attribute is used to match packets based on their tunnel ID, typically relevant for VXLAN (Virtual eXtensible Local Area Network) or other tunneling protocols that utilize tunnel IDs. The tunnel ID helps identify individual tunnels in scenarios where multiple tunnels are used.
Optional
typeThe type of this rule.
Optional
uidrangeSelect the uid value to match.
Generated using TypeDoc
Rule add options.