]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
selftests/landlock: Add test for TCP fast open
authorMatthieu Buffet <matthieu@buffet.re>
Wed, 1 Jul 2026 21:46:28 +0000 (23:46 +0200)
committerMickaël Salaün <mic@digikod.net>
Fri, 10 Jul 2026 10:59:09 +0000 (12:59 +0200)
commitf4b30e0b1d488e7ffd8ea28d1365b9ba8e551edb
tree64f789db6bec5beac982f18b8d353afc6d671f57
parent33cb713db0161b54f04fe830e062c9e102c29a04
selftests/landlock: Add test for TCP fast open

Enforce that TCP Fast Open is controlled by
LANDLOCK_ACCESS_NET_CONNECT_TCP. Semantics of connect() and
sendmsg(MSG_FASTOPEN) should be identical from Landlock's perspective.
Also enforce error code consistency, since UDP sockets ignore the
MSG_FASTOPEN flag while Unix sockets reject it.

Signed-off-by: Matthieu Buffet <matthieu@buffet.re>
Link: https://patch.msgid.link/20260701214628.33319-2-matthieu@buffet.re
Cc: stable@vger.kernel.org
[mic: Fix formatting]
Signed-off-by: Mickaël Salaün <mic@digikod.net>
tools/testing/selftests/landlock/net_test.c