]> git.ipfire.org Git - thirdparty/openssl.git/commit
Fixup tests to properly check version negotiation
authorNeil Horman <nhorman@openssl.org>
Fri, 15 Nov 2024 19:32:56 +0000 (14:32 -0500)
committerNeil Horman <nhorman@openssl.org>
Mon, 17 Feb 2025 16:27:33 +0000 (11:27 -0500)
commitc7b82a725070061a67b4fae4825ac837d4daa163
tree289bd5f5c80492c2ac5bfea69e1186a791830089
parent78702fb7d63b6dc423266672dbe605cc694bdb44
Fixup tests to properly check version negotiation

Currently the quic_multistream_test tests version negotiation..sort of.

It uses a packet injector to force the tserver to send a version
negotiation packet back to the client.  Thats no longer needed as the
server will respond to an invalid version properly.

So alter script_74 to, instead of using the injector, use a quic channel
mutator to invalidate the version provided in the initial packet.  Then
we attempt to connect.  If the server responds with a version
negotiation packet and the client restarts with the proper version, then
the test passes, as the connection is extablished.

Also, while we're in here, update the gen_version_neg function to
properly insert a 0 version into the packet header for script_75, as
version negotiation packets require that to be set, otherwise script_75
will fail now when the server notices this discrepancy.

Reviewed-by: Tomas Mraz <tomas@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/25968)
test/quic_multistream_test.c