]> git.ipfire.org Git - thirdparty/man-pages.git/commitdiff
man/man7/tcp.7: Add TCP_SAVE_SYN and TCP_SAVED_SYN
authorValdikSS <iam@valdikss.org.ru>
Wed, 15 Oct 2025 21:48:25 +0000 (00:48 +0300)
committerAlejandro Colomar <alx@kernel.org>
Tue, 28 Oct 2025 23:43:10 +0000 (00:43 +0100)
Document TCP_SAVE_SYN and TCP_SAVED_SYN options based on git commit
linux.git cd8ae85299d5 (2015-05-05; "tcp: provide SYN headers for
passive connections") which introduced it.

Link: <https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=cd8ae85299d54155702a56811b2e035e63064d3d>
Cc: Eric Dumazet <edumazet@google.com>
Signed-off-by: ValdikSS <iam@valdikss.org.ru>
Message-ID: <20251015214826.70750-1-iam@valdikss.org.ru>
Signed-off-by: Alejandro Colomar <alx@kernel.org>
man/man7/tcp.7

index 4d8026c4f922e17834d9892c2240e02a0cf6a66b..e89c00dafab9fb7039da9d58ec7b4d9728f269b8 100644 (file)
 .\"       commit 6e9250f59ef9efb932c84850cd221f22c2a03c4a
 .\"       Author: Eric Dumazet <edumazet@google.com>
 .\"
-.\"    TCP_SAVE_SYN, TCP_SAVED_SYN (4.2)
-.\"        commit cd8ae85299d54155702a56811b2e035e63064d3d
-.\"        Author: Eric Dumazet <edumazet@google.com>
-.\"
 .TH tcp 7 (date) "Linux man-pages (unreleased)"
 .SH NAME
 tcp \- TCP protocol
@@ -1202,6 +1198,23 @@ aborting the attempt to connect.
 It cannot exceed 255.
 This option should not be used in code intended to be portable.
 .TP
+.BR TCP_SAVE_SYN " (since Linux 4.3)"
+Saves incoming SYN packet contents of the listening socket
+until it is read with
+.B TCP_SAVED_SYN
+once.
+Could be set before or after the
+.BR listen (2)
+call.
+.TP
+.BR TCP_SAVED_SYN " (since Linux 4.3)"
+Reads SYN packet contents saved by
+.BR TCP_SAVE_SYN .
+The saved SYN headers are freed after the first call.
+The data returned in
+.B TCP_SAVED_SYN
+are network (IPv4/IPv6) and TCP headers.
+.TP
 .BR TCP_USER_TIMEOUT " (since Linux 2.6.37)"
 .\"        commit dca43c75e7e545694a9dd6288553f55c53e2a3a3
 .\"        Author: Jerry Chu <hkchu@google.com>