]> www.infradead.org Git - users/jedix/linux-maple.git/commitdiff
netlink: specs: nftables: allow decode of tailscale ruleset
authorDonald Hunter <donald.hunter@gmail.com>
Wed, 4 Sep 2024 09:10:24 +0000 (10:10 +0100)
committerJakub Kicinski <kuba@kernel.org>
Fri, 6 Sep 2024 01:43:56 +0000 (18:43 -0700)
Fill another small gap in the nftables spec so that it is possible to
dump a tailscale ruleset with:

  tools/net/ynl/cli.py --spec \
     Documentation/netlink/specs/nftables.yaml --dump getrule

This adds support for the 'target' expression.

Signed-off-by: Donald Hunter <donald.hunter@gmail.com>
Link: https://patch.msgid.link/20240904091024.3138-1-donald.hunter@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Documentation/netlink/specs/nftables.yaml

index 4acf30cf8385accf63b490817833de225a2ad10e..bd938bd01b6bf2ca32061226ca025ef17cf1a43e 100644 (file)
@@ -1027,6 +1027,19 @@ attribute-sets:
       -
         name: icmp-code
         type: u8
+  -
+    name: expr-target-attrs
+    attributes:
+      -
+        name: name
+        type: string
+      -
+        name: rev
+        type: u32
+        byte-order: big-endian
+      -
+        name: info
+        type: binary
   -
     name: expr-tproxy-attrs
     attributes:
@@ -1113,6 +1126,9 @@ sub-messages:
       -
         value: reject
         attribute-set: expr-reject-attrs
+      -
+        value: target
+        attribute-set: expr-target-attrs
       -
         value: tproxy
         attribute-set: expr-tproxy-attrs