1# SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) 2--- 3name: rt-route 4protocol: netlink-raw 5uapi-header: linux/rtnetlink.h 6protonum: 0 7 8doc: 9 Route configuration over rtnetlink. 10 11definitions: 12 - 13 name: rtm-type 14 name-prefix: rtn- 15 enum-name: 16 type: enum 17 entries: 18 - unspec 19 - unicast 20 - local 21 - broadcast 22 - anycast 23 - multicast 24 - blackhole 25 - unreachable 26 - prohibit 27 - throw 28 - nat 29 - xresolve 30 - 31 name: rtmsg 32 type: struct 33 members: 34 - 35 name: rtm-family 36 type: u8 37 - 38 name: rtm-dst-len 39 type: u8 40 - 41 name: rtm-src-len 42 type: u8 43 - 44 name: rtm-tos 45 type: u8 46 - 47 name: rtm-table 48 type: u8 49 - 50 name: rtm-protocol 51 type: u8 52 - 53 name: rtm-scope 54 type: u8 55 - 56 name: rtm-type 57 type: u8 58 enum: rtm-type 59 - 60 name: rtm-flags 61 type: u32 62 - 63 name: rta-cacheinfo 64 type: struct 65 members: 66 - 67 name: rta-clntref 68 type: u32 69 - 70 name: rta-lastuse 71 type: u32 72 - 73 name: rta-expires 74 type: u32 75 - 76 name: rta-error 77 type: u32 78 - 79 name: rta-used 80 type: u32 81 82attribute-sets: 83 - 84 name: route-attrs 85 name-prefix: rta- 86 attributes: 87 - 88 name: dst 89 type: binary 90 display-hint: ipv4 91 - 92 name: src 93 type: binary 94 display-hint: ipv4 95 - 96 name: iif 97 type: u32 98 - 99 name: oif 100 type: u32 101 - 102 name: gateway 103 type: binary 104 display-hint: ipv4 105 - 106 name: priority 107 type: u32 108 - 109 name: prefsrc 110 type: binary 111 display-hint: ipv4 112 - 113 name: metrics 114 type: nest 115 nested-attributes: metrics 116 - 117 name: multipath 118 type: binary 119 - 120 name: protoinfo # not used 121 type: binary 122 - 123 name: flow 124 type: u32 125 - 126 name: cacheinfo 127 type: binary 128 struct: rta-cacheinfo 129 - 130 name: session # not used 131 type: binary 132 - 133 name: mp-algo # not used 134 type: binary 135 - 136 name: table 137 type: u32 138 - 139 name: mark 140 type: u32 141 - 142 name: mfc-stats 143 type: binary 144 - 145 name: via 146 type: binary 147 - 148 name: newdst 149 type: binary 150 - 151 name: pref 152 type: u8 153 - 154 name: encap-type 155 type: u16 156 - 157 name: encap 158 type: binary # tunnel specific nest 159 - 160 name: expires 161 type: u32 162 - 163 name: pad 164 type: binary 165 - 166 name: uid 167 type: u32 168 - 169 name: ttl-propagate 170 type: u8 171 - 172 name: ip-proto 173 type: u8 174 - 175 name: sport 176 type: u16 177 - 178 name: dport 179 type: u16 180 - 181 name: nh-id 182 type: u32 183 - 184 name: flowlabel 185 type: u32 186 byte-order: big-endian 187 display-hint: hex 188 - 189 name: metrics 190 name-prefix: rtax- 191 attributes: 192 - 193 name: unspec 194 type: unused 195 value: 0 196 - 197 name: lock 198 type: u32 199 - 200 name: mtu 201 type: u32 202 - 203 name: window 204 type: u32 205 - 206 name: rtt 207 type: u32 208 - 209 name: rttvar 210 type: u32 211 - 212 name: ssthresh 213 type: u32 214 - 215 name: cwnd 216 type: u32 217 - 218 name: advmss 219 type: u32 220 - 221 name: reordering 222 type: u32 223 - 224 name: hoplimit 225 type: u32 226 - 227 name: initcwnd 228 type: u32 229 - 230 name: features 231 type: u32 232 - 233 name: rto-min 234 type: u32 235 - 236 name: initrwnd 237 type: u32 238 - 239 name: quickack 240 type: u32 241 - 242 name: cc-algo 243 type: string 244 - 245 name: fastopen-no-cookie 246 type: u32 247 248operations: 249 enum-model: directional 250 fixed-header: rtmsg 251 name-prefix: rtm- 252 list: 253 - 254 name: getroute 255 doc: Dump route information. 256 attribute-set: route-attrs 257 do: 258 request: 259 value: 26 260 attributes: 261 - src 262 - dst 263 - iif 264 - oif 265 - ip-proto 266 - sport 267 - dport 268 - mark 269 - uid 270 - flowlabel 271 reply: 272 value: 24 273 attributes: &all-route-attrs 274 - dst 275 - src 276 - iif 277 - oif 278 - gateway 279 - priority 280 - prefsrc 281 - metrics 282 - multipath 283 - flow 284 - cacheinfo 285 - table 286 - mark 287 - mfc-stats 288 - via 289 - newdst 290 - pref 291 - encap-type 292 - encap 293 - expires 294 - pad 295 - uid 296 - ttl-propagate 297 - ip-proto 298 - sport 299 - dport 300 - nh-id 301 - flowlabel 302 dump: 303 request: 304 value: 26 305 attributes: [] 306 reply: 307 value: 24 308 attributes: *all-route-attrs 309 - 310 name: newroute 311 doc: Create a new route 312 attribute-set: route-attrs 313 do: 314 request: 315 value: 24 316 attributes: *all-route-attrs 317 - 318 name: delroute 319 doc: Delete an existing route 320 attribute-set: route-attrs 321 do: 322 request: 323 value: 25 324 attributes: *all-route-attrs 325