declare the handshake confirmed when receiving an ACK for a 1-RTT packet

... on the client side. Both the receipt of HANDSHAKE_DONE and the
receipt of an ACK for a 1-RTT packet are sufficient for declaring
confirmation of the handshake.
This commit is contained in:
Marten Seemann
2021-04-14 22:26:03 +07:00
parent 3138a45fde
commit 17d9860db6
6 changed files with 154 additions and 65 deletions

View File

@@ -27,7 +27,7 @@ type Packet struct {
type SentPacketHandler interface {
// SentPacket may modify the packet
SentPacket(packet *Packet)
ReceivedAck(ackFrame *wire.AckFrame, encLevel protocol.EncryptionLevel, recvTime time.Time) error
ReceivedAck(ackFrame *wire.AckFrame, encLevel protocol.EncryptionLevel, recvTime time.Time) (bool /* 1-RTT packet acked */, error)
ReceivedBytes(protocol.ByteCount)
DropPackets(protocol.EncryptionLevel)
ResetForRetry() error