send large max_datagram_frame size, introduce a DatagramTooLargeError error (#4143)

The size can be overwritten to a lower value for testing.
This commit is contained in:
chungthuang
2023-12-02 14:27:15 +00:00
committed by GitHub
parent 2d7ea37672
commit 7b9d21fbe6
6 changed files with 41 additions and 16 deletions

View File

@@ -503,7 +503,7 @@ var _ = Describe("Transport Parameters", func() {
MaxBidiStreamNum: protocol.StreamNum(getRandomValueUpTo(int64(protocol.MaxStreamCount))),
MaxUniStreamNum: protocol.StreamNum(getRandomValueUpTo(int64(protocol.MaxStreamCount))),
ActiveConnectionIDLimit: 2 + getRandomValueUpTo(math.MaxInt64-2),
MaxDatagramFrameSize: protocol.ByteCount(getRandomValueUpTo(int64(protocol.MaxDatagramFrameSize))),
MaxDatagramFrameSize: protocol.ByteCount(getRandomValueUpTo(int64(MaxDatagramSize))),
}
Expect(params.ValidFor0RTT(params)).To(BeTrue())
b := params.MarshalForSessionTicket(nil)