]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
selftest: packetdrill: Import TFO server basic tests.
authorKuniyuki Iwashima <kuniyu@google.com>
Sat, 27 Sep 2025 21:29:42 +0000 (21:29 +0000)
committerJakub Kicinski <kuba@kernel.org>
Tue, 30 Sep 2025 01:41:38 +0000 (18:41 -0700)
commit0b8f164eb264184bf8820cc0c59cf6089d0201b3
treef6ca0f542a4d834aedddce839c71a414c4f3b358
parent97b3b8306f782af80b4666d7137c75be9dba9219
selftest: packetdrill: Import TFO server basic tests.

This imports basic TFO server tests from google/packetdrill.

The repository has two versions of tests for most scenarios; one uses
the non-experimental option (34), and the other uses the experimental
option (255) with 0xF989.

This only imports the following tests of the non-experimental version
placed in [0].  I will add a specific test for the experimental option
handling later.

                             | TFO | Cookie | Payload |
  ---------------------------+-----+--------+---------+
  basic-rw.pkt               | yes |  yes   |   yes   |
  basic-zero-payload.pkt     | yes |  yes   |    no   |
  basic-cookie-not-reqd.pkt  | yes |   no   |   yes   |
  basic-non-tfo-listener.pkt |  no |  yes   |   yes   |
  pure-syn-data.pkt          | yes |   no   |   yes   |

The original pure-syn-data.pkt missed setsockopt(TCP_FASTOPEN) and did
not test TFO server in some scenarios unintentionally, so setsockopt()
is added where needed.  In addition, non-TFO scenario is stripped as
it is covered by basic-non-tfo-listener.pkt.  Also, I added basic- prefix.

Link: https://github.com/google/packetdrill/tree/bfc96251310f/gtests/net/tcp/fastopen/server/opt34
Signed-off-by: Kuniyuki Iwashima <kuniyu@google.com>
Reviewed-by: Willem de Bruijn <willemb@google.com>
Link: https://patch.msgid.link/20250927213022.1850048-5-kuniyu@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
tools/testing/selftests/net/packetdrill/tcp_fastopen_server_basic-cookie-not-reqd.pkt [new file with mode: 0644]
tools/testing/selftests/net/packetdrill/tcp_fastopen_server_basic-non-tfo-listener.pkt [new file with mode: 0644]
tools/testing/selftests/net/packetdrill/tcp_fastopen_server_basic-pure-syn-data.pkt [new file with mode: 0644]
tools/testing/selftests/net/packetdrill/tcp_fastopen_server_basic-rw.pkt [new file with mode: 0644]
tools/testing/selftests/net/packetdrill/tcp_fastopen_server_basic-zero-payload.pkt [new file with mode: 0644]