[PATCH bpf-next 0/2] bpf: tcp: Reject TCP_NODELAY from BPF hdr opt callbacks

KaFai Wan
2026-04-14T11:24:02Z

This small patchset is about avoid infinite recursion in bpf_skops_hdr_opt_len()
via TCP_NODELAY setsockopt.

---
KaFai Wan (2):
bpf: tcp: Reject TCP_NODELAY from BPF hdr opt callbacks
selftests/bpf: Cover TCP_NODELAY in hdr opt callback

net/ipv4/tcp.c | 5 ++-
.../bpf/prog_tests/tcp_hdr_options.c | 34 +++++++++++++++++++
.../bpf/progs/test_misc_tcp_hdr_options.c | 18 ++++++++++
3 files changed, 56 insertions(+), 1 deletion(-)

--
2.43.0