]> git.ipfire.org Git - thirdparty/openssl.git/commit
Don't reserve an unused cid for NEW_TOKENS
authorNeil Horman <nhorman@openssl.org>
Mon, 27 Jan 2025 21:32:32 +0000 (16:32 -0500)
committerNeil Horman <nhorman@openssl.org>
Tue, 4 Feb 2025 14:15:28 +0000 (09:15 -0500)
commit56d0ca6791ea660b962ee4a25e7c0bfed9eed9c6
tree53d965f85b212bbe9270f4de9dc6fa2fccc524c6
parent671bb043222fbcd9fa83c47c0fc617879ac19a6d
Don't reserve an unused cid for NEW_TOKENS

Just realized that NEW_TOKEN tokens don't need a reserved rscid.

Because a client might use a received NEW_TOKEN for multiple subsequent
connections, we allocate a cid when we validate the token on new
connection establishment (in fact we just use the one that the client
sends).  As such the allocated rscid never gets used, and just sits
there until it ages out.

Instead, fill the rscid with random data to mutate subsequently
generated NEW_TOKENS's, since it won't ever be part of the validation
process anyway.

Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Saša Nedvědický <sashan@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/26517)
ssl/quic/quic_port.c