send the maximum packet size in the TLS transport parameters

This commit is contained in:
Marten Seemann
2017-09-29 18:11:03 +07:00
parent 8d273d30af
commit dc6d1b6822
2 changed files with 5 additions and 1 deletions

View File

@@ -49,13 +49,14 @@ var _ = Describe("Params Negotiator (for TLS)", func() {
It("creates the parameters list", func() {
buf := make([]byte, 4)
values := paramsListToMap(pn.GetTransportParameters())
Expect(values).To(HaveLen(4))
Expect(values).To(HaveLen(5))
binary.BigEndian.PutUint32(buf, uint32(protocol.ReceiveStreamFlowControlWindow))
Expect(values).To(HaveKeyWithValue(initialMaxStreamDataParameterID, buf))
binary.BigEndian.PutUint32(buf, uint32(protocol.ReceiveConnectionFlowControlWindow))
Expect(values).To(HaveKeyWithValue(initialMaxDataParameterID, buf))
Expect(values).To(HaveKeyWithValue(initialMaxStreamIDParameterID, []byte{0xff, 0xff, 0xff, 0xff}))
Expect(values).To(HaveKeyWithValue(idleTimeoutParameterID, []byte{0x50, 0x0}))
Expect(values).To(HaveKeyWithValue(maxPacketSizeParameterID, []byte{0x5, 0xac})) // 1452 = 0x5ac
})
It("request ommision of the connection ID", func() {