[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aMrXqeATjFj2Ak4c@krikkit>
Date: Wed, 17 Sep 2025 17:45:45 +0200
From: Sabrina Dubroca <sd@...asysnail.net>
To: Kuniyuki Iwashima <kuniyu@...gle.com>
Cc: "David S. Miller" <davem@...emloft.net>,
Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>,
Simon Horman <horms@...nel.org>,
Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org,
John Fastabend <john.fastabend@...il.com>,
Ilya Lesokhin <ilyal@...lanox.com>
Subject: Re: [PATCH v2 net-next 5/7] tls: Use __sk_dst_get() and
dst_dev_rcu() in get_netdev_for_sock().
2025-09-16, 21:47:23 +0000, Kuniyuki Iwashima wrote:
> get_netdev_for_sock() is called during setsockopt(),
> so not under RCU.
>
> Using sk_dst_get(sk)->dev could trigger UAF.
>
> Let's use __sk_dst_get() and dst_dev_rcu().
>
> Note that the only ->ndo_sk_get_lower_dev() user is
> bond_sk_get_lower_dev(), which uses RCU.
>
> Fixes: e8f69799810c ("net/tls: Add generic NIC offload infrastructure")
> Signed-off-by: Kuniyuki Iwashima <kuniyu@...gle.com>
Reviewed-by: Sabrina Dubroca <sd@...asysnail.net>
--
Sabrina
Powered by blists - more mailing lists