Commit 3a5625dda3 for openssl.org

commit 3a5625dda316dfa781c011c199c938e6cb335a1f
Author: Jakub Zelenka <jakub.zelenka@openssl.foundation>
Date:   Thu Aug 27 17:29:48 2026 +0200

    quic-radix: add thread-assisted data transfer test

    Add a radix vignette migrating the data-transfer half of the
    QUIC_TSERVER-based thread-assist coverage: a client created with
    OSSL_QUIC_client_thread_method() writes on the default stream and
    concludes it, the server reads to EOS and answers with its own write and
    conclude, and the client reads the reply and observes EOS.

    Per-op ticking is disabled on the client for the whole transfer, so it
    runs like a real thread-assisted application: no SSL_handle_events()
    calls, with progress coming only from API-call autoticks and the assist
    thread. The assist thread cannot be the sole driver here as it only
    wakes on timer deadlines, not on datagram arrival.

    Also add an OP_SIMPLE_PAIR_CONN_TA() op for the shared thread-assisted
    client setup, used by the follow-up thread-assist vignettes.

    Assisted-by: Claude:claude-fable-5
    Reviewed-by: Tomas Mraz <tomas@openssl.foundation>
    Reviewed-by: Andrew Dinh <andrewd@openssl.org>
    Merge-date: Mon Nov 16 17:41:42 2026
    Merged-from: https://github.com/openssl/openssl/pull/32550

diff --git a/test/radix/quic_ops.c b/test/radix/quic_ops.c
index 12c274897a..3088a812d1 100644
--- a/test/radix/quic_ops.c
+++ b/test/radix/quic_ops.c
@@ -2043,6 +2043,14 @@ err:
     (OP_SIMPLE_PAIR_CONN(),      \
         OP_SET_DEFAULT_STREAM_MODE(C, SSL_DEFAULT_STREAM_MODE_NONE))

+/* Thread-assisted client and listener linked by an in-memory dgram pair. */
+#define OP_SIMPLE_PAIR_CONN_TA()  \
+    (OP_NEW_SSL_L_MEM(L),         \
+        OP_NEW_SSL_C_TA_MEM(C),   \
+        OP_LINK_DGRAM_PAIR(C, L), \
+        OP_LISTEN(L),             \
+        OP_CONNECT_WAIT(C))
+
 #define OP_NEW_STREAM(conn_name, stream_name, flags) \
     (OP_SELECT_SSL(0, conn_name),                    \
         OP_PUSH_PZ(#stream_name),                    \
diff --git a/test/radix/quic_tests.c b/test/radix/quic_tests.c
index ae6e92033d..3dbe37e26a 100644
--- a/test/radix/quic_tests.c
+++ b/test/radix/quic_tests.c
@@ -1503,6 +1503,32 @@ DEF_SCRIPT(check_thread_assisted_idle,
     OP_TICK_ENABLE(C);
 }

+/*
+ * With per-op ticking disabled the client runs like a real thread-assisted
+ * app: progress comes only from API-call autoticks and the assist thread.
+ * Cover a full-duplex default-stream transfer with conclude/EOS both ways.
+ */
+DEF_SCRIPT(check_thread_assisted_transfer,
+    "thread-assisted client full-duplex transfer with conclude/EOS")
+{
+    OP_SIMPLE_PAIR_CONN_TA();
+    OP_ACCEPT_CONN_WAIT(L, Sa, 0);
+
+    OP_TICK_DISABLE(C);
+
+    OP_WRITE_B(C, "raspberry");
+    OP_CONCLUDE(C);
+    OP_READ_EXPECT_B(Sa, "raspberry");
+    OP_EXPECT_FIN(Sa);
+
+    OP_WRITE_B(Sa, "elderberry");
+    OP_CONCLUDE(Sa);
+    OP_READ_EXPECT_B(C, "elderberry");
+    OP_EXPECT_FIN(C);
+
+    OP_TICK_ENABLE(C);
+}
+
 DEF_FUNC(check_stream_reset_5)
 {
     int ok = 0;
@@ -6142,6 +6168,7 @@ static SCRIPT_INFO *const scripts[] = {
     USE(check_pc_flood),
     USE(check_ctx_cbks),
     USE(check_thread_assisted_idle),
+    USE(check_thread_assisted_transfer),
     USE(script_5),
     USE(script_6),
     USE(script_7),