]> git.kaiwu.me - haproxy.git/commit
REGTESTS: http-messaging: Add a test for the CONNECT tunnels
authorChristopher Faulet <cfaulet@haproxy.com>
Fri, 18 Sep 2026 16:24:45 +0000 (18:24 +0200)
committerChristopher Faulet <cfaulet@haproxy.com>
Fri, 18 Sep 2026 16:24:45 +0000 (18:24 +0200)
commitd75b8423483883561eea79e3dcd5f5210382856a
treee3ae978e0c28c8f29447e97cfd9d908be94dc433
parentbff44ff3d23e0de34e42fb6dc77d0c205041e871
REGTESTS: http-messaging: Add a test for the CONNECT tunnels

This test checks the CONNECT tunnels handling, on the H1 and H2 sides. For a
tunneled stream, the end of the HTTP message is reported just after the
headers, so the tunneled data are exchanged after the end of the message.
Four cases are covered:

  * A H1 CONNECT with tunneled data exchanged in both directions.

  * A H2 CONNECT with the tunneled data sent in the same segment than the
    headers. This way, they are received by the H2 multiplexer before the
    request was forwarded.

  * A H2 CONNECT followed by a bogus trailers block. It must be rejected
    because the message was already ended. Tunneled data are sent first, so
    the end of the message is reported on the HTX message whether the headers
    part was already consumed or not. A barrier is used to be sure the tunnel
    is established when the trailers are sent.

  * A H2 CONNECT refused by the server with a payload and trailers. Here the
    tunnel attempt is aborted, so the response is a regular one and its
    trailers must be forwarded.
reg-tests/http-messaging/connect_tunnels.vtc [new file with mode: 0644]