diff options
Diffstat (limited to 'meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch')
-rw-r--r-- | meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch | 65 |
1 files changed, 0 insertions, 65 deletions
diff --git a/meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch b/meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch deleted file mode 100644 index 180edb350..000000000 --- a/meta-networking/recipes-filter/nftables/files/0004-src-allow-update-of-net-base-w.-meta-l4proto-icmpv6.patch +++ /dev/null | |||
@@ -1,65 +0,0 @@ | |||
1 | From 9a1f2bbf3cd2417e0c10d18578e224abe2071d68 Mon Sep 17 00:00:00 2001 | ||
2 | From: Florian Westphal <fw@strlen.de> | ||
3 | Date: Tue, 21 Mar 2017 19:47:22 +0100 | ||
4 | Subject: [PATCH 2/4] src: allow update of net base w. meta l4proto icmpv6 | ||
5 | |||
6 | nft add rule ip6 f i meta l4proto ipv6-icmp icmpv6 type nd-router-advert | ||
7 | <cmdline>:1:50-60: Error: conflicting protocols specified: unknown vs. icmpv6 | ||
8 | |||
9 | add icmpv6 to nexthdr list so base gets updated correctly. | ||
10 | |||
11 | Reported-by: Thomas Woerner <twoerner@redhat.com> | ||
12 | Signed-off-by: Florian Westphal <fw@strlen.de> | ||
13 | --- | ||
14 | Upstream-Status: Backport | ||
15 | Signed-off-by: André Draszik <adraszik@tycoint.com> | ||
16 | src/proto.c | 1 + | ||
17 | tests/py/any/meta.t | 1 + | ||
18 | tests/py/any/meta.t.payload | 7 +++++++ | ||
19 | 3 files changed, 9 insertions(+) | ||
20 | |||
21 | diff --git a/src/proto.c b/src/proto.c | ||
22 | index 79e9dbf..fcdfbe7 100644 | ||
23 | --- a/src/proto.c | ||
24 | +++ b/src/proto.c | ||
25 | @@ -779,6 +779,7 @@ const struct proto_desc proto_inet_service = { | ||
26 | PROTO_LINK(IPPROTO_TCP, &proto_tcp), | ||
27 | PROTO_LINK(IPPROTO_DCCP, &proto_dccp), | ||
28 | PROTO_LINK(IPPROTO_SCTP, &proto_sctp), | ||
29 | + PROTO_LINK(IPPROTO_ICMPV6, &proto_icmp6), | ||
30 | }, | ||
31 | .templates = { | ||
32 | [0] = PROTO_META_TEMPLATE("l4proto", &inet_protocol_type, NFT_META_L4PROTO, 8), | ||
33 | diff --git a/tests/py/any/meta.t b/tests/py/any/meta.t | ||
34 | index c3ac0a4..2ff942f 100644 | ||
35 | --- a/tests/py/any/meta.t | ||
36 | +++ b/tests/py/any/meta.t | ||
37 | @@ -38,6 +38,7 @@ meta l4proto { 33, 55, 67, 88};ok;meta l4proto { 33, 55, 67, 88} | ||
38 | meta l4proto != { 33, 55, 67, 88};ok | ||
39 | meta l4proto { 33-55};ok | ||
40 | meta l4proto != { 33-55};ok | ||
41 | +meta l4proto ipv6-icmp icmpv6 type nd-router-advert;ok;icmpv6 type nd-router-advert | ||
42 | |||
43 | meta priority root;ok | ||
44 | meta priority none;ok | ||
45 | diff --git a/tests/py/any/meta.t.payload b/tests/py/any/meta.t.payload | ||
46 | index e432656..871f1ad 100644 | ||
47 | --- a/tests/py/any/meta.t.payload | ||
48 | +++ b/tests/py/any/meta.t.payload | ||
49 | @@ -187,6 +187,13 @@ ip test-ip4 input | ||
50 | [ byteorder reg 1 = hton(reg 1, 2, 1) ] | ||
51 | [ lookup reg 1 set __set%d 0x1 ] | ||
52 | |||
53 | +# meta l4proto ipv6-icmp icmpv6 type nd-router-advert | ||
54 | +ip test-ip4 input | ||
55 | + [ meta load l4proto => reg 1 ] | ||
56 | + [ cmp eq reg 1 0x0000003a ] | ||
57 | + [ payload load 1b @ transport header + 0 => reg 1 ] | ||
58 | + [ cmp eq reg 1 0x00000086 ] | ||
59 | + | ||
60 | # meta mark 0x4 | ||
61 | ip test-ip4 input | ||
62 | [ meta load mark => reg 1 ] | ||
63 | -- | ||
64 | 2.11.0 | ||
65 | |||