]> Cypherpunks.ru repositories - gostls13.git/commit
crypto/tls: add WrapSession and UnwrapSession
authorFilippo Valsorda <filippo@golang.org>
Mon, 22 May 2023 08:49:07 +0000 (10:49 +0200)
committerFilippo Valsorda <filippo@golang.org>
Wed, 24 May 2023 23:56:55 +0000 (23:56 +0000)
commit6824765b4b981291712ae6d60702f6f0350f57d5
tree0de9f313a7a137e950ee6c748db81d0f2f60dd68
parent371ebe731bf6ebae3d6914835674e276d98254f5
crypto/tls: add WrapSession and UnwrapSession

There was a bug in TestResumption: the first ExpiredSessionTicket was
inserting a ticket far in the future, so the second ExpiredSessionTicket
wasn't actually supposed to fail. However, there was a bug in
checkForResumption->sendSessionTicket, too: if a session was not resumed
because it was too old, its createdAt was still persisted in the next
ticket. The two bugs used to cancel each other out.

For #60105
Fixes #19199

Change-Id: Ic9b2aab943dcbf0de62b8758a6195319dc286e2f
Reviewed-on: https://go-review.googlesource.com/c/go/+/496821
Run-TryBot: Filippo Valsorda <filippo@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
Reviewed-by: Roland Shoemaker <roland@golang.org>
Reviewed-by: Damien Neil <dneil@google.com>
api/next/60105.txt
src/crypto/tls/common.go
src/crypto/tls/handshake_client_test.go
src/crypto/tls/handshake_server.go
src/crypto/tls/handshake_server_tls13.go
src/crypto/tls/ticket.go
src/crypto/tls/tls_test.go