correctly pack packets with sealers with different overheads

This commit is contained in:
Marten Seemann
2017-09-04 10:17:44 +08:00
parent 7cbef3cb1b
commit 8bcabe0ba9
9 changed files with 89 additions and 109 deletions

View File

@@ -6,9 +6,6 @@ import "time"
// This is the value used by Chromium for a QUIC packet sent using IPv6 (for IPv4 it would be 1370)
const MaxPacketSize ByteCount = 1350
// MaxFrameAndPublicHeaderSize is the maximum size of a QUIC frame plus PublicHeader
const MaxFrameAndPublicHeaderSize = MaxPacketSize - 12 /*crypto signature*/
// NonForwardSecurePacketSizeReduction is the number of bytes a non forward-secure packet has to be smaller than a forward-secure packet
// This makes sure that those packets can always be retransmitted without splitting the contained StreamFrames
const NonForwardSecurePacketSizeReduction = 50