- patches.kabi/0001-Revert-tcp-RFC-5961-5.2-Blind-Data-Injection-Attack-.patch:
[opensuse:kernel-source.git] / patches.kabi / 0003-Revert-tcp-refine-SYN-handling-in-tcp_validate_incom.patch
1 From: Jiri Slaby <jslaby@suse.cz>
2 Subject: Revert "tcp: refine SYN handling in tcp_validate_incoming"
3 Patch-mainline: never, kABI
4
5 This reverts commit 282190eab6442da4789ae3c3037c7b19d65eaf52, upstream
6 commit e371589917011efe6ff8c7dfb4e9e81934ac5855. We cannot take these
7 patches as they change public SNMP interface indices.
8
9 Signed-off-by: Jiri Slaby <jslaby@suse.cz>
10 ---
11  net/ipv4/tcp_input.c |    6 +-----
12  1 file changed, 1 insertion(+), 5 deletions(-)
13
14 --- a/net/ipv4/tcp_input.c
15 +++ b/net/ipv4/tcp_input.c
16 @@ -5223,11 +5223,8 @@ static bool tcp_validate_incoming(struct
17                  * an acknowledgment should be sent in reply (unless the RST
18                  * bit is set, if so drop the segment and return)".
19                  */
20 -               if (!th->rst) {
21 -                       if (th->syn)
22 -                               goto syn_challenge;
23 +               if (!th->rst)
24                         tcp_send_dupack(sk, skb);
25 -               }
26                 goto discard;
27         }
28  
29 @@ -5252,7 +5249,6 @@ static bool tcp_validate_incoming(struct
30          * RFC 5691 4.2 : Send a challenge ack
31          */
32         if (th->syn) {
33 -syn_challenge:
34                 if (syn_inerr)
35                         TCP_INC_STATS_BH(sock_net(sk), TCP_MIB_INERRS);
36                 NET_INC_STATS_BH(sock_net(sk), LINUX_MIB_TCPSYNCHALLENGE);