Family rt-rule
netlink specification¶
Summary¶
FIB rule management over rtnetlink.
Operations¶
newrule¶
Add new FIB rule
- attribute-set:
- do:
- request
- attributes:
[
iifname
,oifname
,priority
,fwmark
,flow
,tun-id
,fwmask
,table
,suppress-prefixlen
,suppress-ifgroup
,goto
,l3mdev
,uid-range
,protocol
,ip-proto
,sport-range
,dport-range
,dscp
]
newrule-ntf¶
Notify a rule creation
- value:
32
- notify:
newrule
delrule¶
Remove an existing FIB rule
- attribute-set:
- do:
- request
- attributes:
[
iifname
,oifname
,priority
,fwmark
,flow
,tun-id
,fwmask
,table
,suppress-prefixlen
,suppress-ifgroup
,goto
,l3mdev
,uid-range
,protocol
,ip-proto
,sport-range
,dport-range
,dscp
]
delrule-ntf¶
Notify a rule deletion
- value:
33
- notify:
delrule
getrule¶
Dump all FIB rules
- attribute-set:
- dump:
request
- reply
- attributes:
[
iifname
,oifname
,priority
,fwmark
,flow
,tun-id
,fwmask
,table
,suppress-prefixlen
,suppress-ifgroup
,goto
,l3mdev
,uid-range
,protocol
,ip-proto
,sport-range
,dport-range
,dscp
]
Multicast groups¶
rtnlgrp-ipv4-rule
rtnlgrp-ipv6-rule
Definitions¶
rtgenmsg¶
- type:
struct
- members:
- family (
u8
):
- family (
fib-rule-hdr¶
- type:
struct
- members:
- family (
u8
): - dst-len (
u8
): - src-len (
u8
): - tos (
u8
): - table (
u8
): - res1 (
pad
): - res2 (
pad
): - action (
u8
): - flags (
u32
):
- family (
fr-act¶
- type:
enum
- entries:
unspec
to-tbl
goto
nop
res3
res4
blackhole
unreachable
prohibit
fib-rule-port-range¶
- type:
struct
- members:
- start (
u16
): - end (
u16
):
- start (
fib-rule-uid-range¶
- type:
struct
- members:
- start (
u32
): - end (
u32
):
- start (
Attribute sets¶
fib-rule-attrs¶
dst (u32
)¶
src (u32
)¶
iifname (string
)¶
goto (u32
)¶
unused2 (pad
)¶
priority (u32
)¶
unused3 (pad
)¶
unused4 (pad
)¶
unused5 (pad
)¶
fwmark (u32
)¶
- display-hint:
hex
flow (u32
)¶
tun-id (u64
)¶
suppress-ifgroup (u32
)¶
suppress-prefixlen (u32
)¶
- display-hint:
hex
table (u32
)¶
fwmask (u32
)¶
- display-hint:
hex
oifname (string
)¶
pad (pad
)¶
l3mdev (u8
)¶
uid-range (binary
)¶
- struct:
protocol (u8
)¶
ip-proto (u8
)¶
sport-range (binary
)¶
- struct:
dport-range (binary
)¶
- struct: