From: Juan Agustin Niccolini <juanagusnicco@gmail.com>
To: davem@davemloft.net, edumazet@kernel.org, kuba@kernel.org,
pabeni@redhat.com
Cc: horms@kernel.org, ncardwell@google.com, kuniyu@google.com,
josef@toxicpanda.com, jbacik@fb.com, shuah@kernel.org,
linux-kselftest@vger.kernel.org, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org,
Juan Agustin Niccolini <juanagusnicco@gmail.com>
Subject: [PATCH net v2 0/2] tcp: Fix the SO_REUSEPORT bind cache admitting a conflicting socket
Date: Wed, 11 Nov 2026 12:47:02 -0500 [thread overview]
Message-ID: <20261111174704.24312-1-juanagusnicco@gmail.com> (raw)
The SO_REUSEPORT bind cache (tb->fast_*) can let a socket skip a bind
conflict check that it would fail, so an unprivileged user can bind and
listen on a port that another user is listening on.
Patch 1 fixes it. Patch 2 adds the reproducer as a selftest.
v2:
- Shorten the changelog (Eric Dumazet)
- Add reproducer as selftest (Eric Dumazet)
v1: https://lore.kernel.org/all/20261110080008.26112-1-juanagusnicco@gmail.com/
Juan Agustin Niccolini (2):
tcp: Fix the SO_REUSEPORT bind cache admitting a conflicting socket
selftests: net: Add SO_REUSEPORT bind cache test to bind_wildcard.c
include/net/inet_hashtables.h | 2 +
net/ipv4/inet_connection_sock.c | 15 ++++--
tools/testing/selftests/net/bind_wildcard.c | 54 +++++++++++++++++++++
3 files changed, 68 insertions(+), 3 deletions(-)
base-commit: 19a227903e65c7a9c179156485660a4e017575fe
--
2.43.0
next reply other threads:[~2026-11-11 17:47 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-11 17:47 Juan Agustin Niccolini [this message]
2026-11-11 17:47 ` [PATCH net v2 1/2] " Juan Agustin Niccolini
2026-11-11 17:47 ` [PATCH net v2 2/2] selftests: net: Add SO_REUSEPORT bind cache test to bind_wildcard.c Juan Agustin Niccolini
2026-11-11 17:51 ` [PATCH net v2 0/2] tcp: Fix the SO_REUSEPORT bind cache admitting a conflicting socket netdev-bot+sinfo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261111174704.24312-1-juanagusnicco@gmail.com \
--to=juanagusnicco@gmail.com \
--cc=davem@davemloft.net \
--cc=edumazet@kernel.org \
--cc=horms@kernel.org \
--cc=jbacik@fb.com \
--cc=josef@toxicpanda.com \
--cc=kuba@kernel.org \
--cc=kuniyu@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
--cc=ncardwell@google.com \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=shuah@kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®