]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch from 4.4 and 4.9
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 30 Jan 2022 19:24:09 +0000 (20:24 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 30 Jan 2022 19:24:09 +0000 (20:24 +0100)
queue-4.4/ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch [deleted file]
queue-4.4/series
queue-4.9/ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch [deleted file]
queue-4.9/series

diff --git a/queue-4.4/ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch b/queue-4.4/ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch
deleted file mode 100644 (file)
index b3183f2..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-From 2afc3b5a31f9edf3ef0f374f5d70610c79c93a42 Mon Sep 17 00:00:00 2001
-From: Xin Long <lucien.xin@gmail.com>
-Date: Sat, 22 Jan 2022 06:40:56 -0500
-Subject: ping: fix the sk_bound_dev_if match in ping_lookup
-
-From: Xin Long <lucien.xin@gmail.com>
-
-commit 2afc3b5a31f9edf3ef0f374f5d70610c79c93a42 upstream.
-
-When 'ping' changes to use PING socket instead of RAW socket by:
-
-   # sysctl -w net.ipv4.ping_group_range="0 100"
-
-the selftests 'router_broadcast.sh' will fail, as such command
-
-  # ip vrf exec vrf-h1 ping -I veth0 198.51.100.255 -b
-
-can't receive the response skb by the PING socket. It's caused by mismatch
-of sk_bound_dev_if and dif in ping_rcv() when looking up the PING socket,
-as dif is vrf-h1 if dif's master was set to vrf-h1.
-
-This patch is to fix this regression by also checking the sk_bound_dev_if
-against sdif so that the packets can stil be received even if the socket
-is not bound to the vrf device but to the real iif.
-
-Fixes: c319b4d76b9e ("net: ipv4: add IPPROTO_ICMP socket kind")
-Reported-by: Hangbin Liu <liuhangbin@gmail.com>
-Signed-off-by: Xin Long <lucien.xin@gmail.com>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- net/ipv4/ping.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
---- a/net/ipv4/ping.c
-+++ b/net/ipv4/ping.c
-@@ -223,7 +223,8 @@ static struct sock *ping_lookup(struct n
-                       continue;
-               }
--              if (sk->sk_bound_dev_if && sk->sk_bound_dev_if != dif)
-+              if (sk->sk_bound_dev_if && sk->sk_bound_dev_if != dif &&
-+                  sk->sk_bound_dev_if != inet_sdif(skb))
-                       continue;
-               sock_hold(sk);
index d19cdbbce8bdbc2fcccdce0cc2bfb47488d2d788..18d3a4413b0f6b484885c20f1b25c4ab0b04cac7 100644 (file)
@@ -14,7 +14,6 @@ scsi-bnx2fc-flush-destroy_work-queue-before-calling-bnx2fc_interface_put.patch
 ipv6_tunnel-rate-limit-warning-messages.patch
 arm-9170-1-fix-panic-when-kasan-and-kprobe-are-enabled.patch
 net-fix-information-leakage-in-proc-net-ptype.patch
-ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch
 ipv4-avoid-using-shared-ip-generator-for-connected-sockets.patch
 net-procfs-show-net-devices-bound-packet-types.patch
 drm-msm-fix-wrong-size-calculation.patch
diff --git a/queue-4.9/ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch b/queue-4.9/ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch
deleted file mode 100644 (file)
index bc77f01..0000000
+++ /dev/null
@@ -1,46 +0,0 @@
-From 2afc3b5a31f9edf3ef0f374f5d70610c79c93a42 Mon Sep 17 00:00:00 2001
-From: Xin Long <lucien.xin@gmail.com>
-Date: Sat, 22 Jan 2022 06:40:56 -0500
-Subject: ping: fix the sk_bound_dev_if match in ping_lookup
-
-From: Xin Long <lucien.xin@gmail.com>
-
-commit 2afc3b5a31f9edf3ef0f374f5d70610c79c93a42 upstream.
-
-When 'ping' changes to use PING socket instead of RAW socket by:
-
-   # sysctl -w net.ipv4.ping_group_range="0 100"
-
-the selftests 'router_broadcast.sh' will fail, as such command
-
-  # ip vrf exec vrf-h1 ping -I veth0 198.51.100.255 -b
-
-can't receive the response skb by the PING socket. It's caused by mismatch
-of sk_bound_dev_if and dif in ping_rcv() when looking up the PING socket,
-as dif is vrf-h1 if dif's master was set to vrf-h1.
-
-This patch is to fix this regression by also checking the sk_bound_dev_if
-against sdif so that the packets can stil be received even if the socket
-is not bound to the vrf device but to the real iif.
-
-Fixes: c319b4d76b9e ("net: ipv4: add IPPROTO_ICMP socket kind")
-Reported-by: Hangbin Liu <liuhangbin@gmail.com>
-Signed-off-by: Xin Long <lucien.xin@gmail.com>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
----
- net/ipv4/ping.c |    3 ++-
- 1 file changed, 2 insertions(+), 1 deletion(-)
-
---- a/net/ipv4/ping.c
-+++ b/net/ipv4/ping.c
-@@ -225,7 +225,8 @@ static struct sock *ping_lookup(struct n
-                       continue;
-               }
--              if (sk->sk_bound_dev_if && sk->sk_bound_dev_if != dif)
-+              if (sk->sk_bound_dev_if && sk->sk_bound_dev_if != dif &&
-+                  sk->sk_bound_dev_if != inet_sdif(skb))
-                       continue;
-               sock_hold(sk);
index 5676a4f3817834e69fdbeacf0238d65ac6666049..2b2923d5203918f3eae14b12306adc150e1ed203 100644 (file)
@@ -16,7 +16,6 @@ scsi-bnx2fc-flush-destroy_work-queue-before-calling-bnx2fc_interface_put.patch
 ipv6_tunnel-rate-limit-warning-messages.patch
 arm-9170-1-fix-panic-when-kasan-and-kprobe-are-enabled.patch
 net-fix-information-leakage-in-proc-net-ptype.patch
-ping-fix-the-sk_bound_dev_if-match-in-ping_lookup.patch
 ipv4-avoid-using-shared-ip-generator-for-connected-sockets.patch
 nfsv4-handle-case-where-the-lookup-of-a-directory-fails.patch
 nfsv4-nfs_atomic_open-can-race-when-looking-up-a-non-regular-file.patch