[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CANn89iKaOrkdaKYnjFx2B08Cw5idMW0+-181_WK6Go3J8DXNXQ@mail.gmail.com>
Date: Tue, 28 Nov 2023 16:12:08 +0100
From: Eric Dumazet <edumazet@...gle.com>
To: Kuniyuki Iwashima <kuniyu@...zon.com>
Cc: "David S. Miller" <davem@...emloft.net>, Jakub Kicinski <kuba@...nel.org>,
Paolo Abeni <pabeni@...hat.com>, Simon Horman <horms@...nel.org>,
Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: Re: [PATCH v2 net-next 4/8] tcp: Don't pass cookie to __cookie_v[46]_check().
On Sat, Nov 25, 2023 at 2:18 AM Kuniyuki Iwashima <kuniyu@...zon.com> wrote:
>
> tcp_hdr(skb) and SYN Cookie are passed to __cookie_v[46]_check(), but
> none of the callers passes cookie other than ntohl(th->ack_seq) - 1.
>
> Let's fetch it in __cookie_v[46]_check() instead of passing the cookie
> over and over.
>
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...zon.com>
> Reviewed-by: Simon Horman <horms@...nel.org>
> ---
> include/linux/netfilter_ipv6.h | 8 ++++----
> include/net/tcp.h | 6 ++----
> net/core/filter.c | 15 ++++-----------
> net/ipv4/syncookies.c | 15 ++++++++-------
> net/ipv6/syncookies.c | 15 ++++++++-------
> net/netfilter/nf_synproxy_core.c | 4 ++--
> 6 files changed, 28 insertions(+), 35 deletions(-)
Reviewed-by: Eric Dumazet <edumazet@...gle.com>
Powered by blists - more mailing lists