Commit Graph

2485 Commits

Author SHA1 Message Date
Marten Seemann
73ab97aa95 simplify the stream by directly popping STREAM frames from it 2017-12-12 18:48:08 +07:00
Marten Seemann
b75e1df4f0 Merge pull request #1011 from lucas-clemente/crypto-stream-is-special
remove unneeded function from the crypto stream interface
2017-12-12 18:40:12 +07:00
Marten Seemann
7fd0157e1f Merge pull request #1006 from lucas-clemente/more-window-updates
decrease the threshold to send MAX_{STREAM}_DATA frames
2017-12-12 18:30:55 +07:00
Marten Seemann
cd5e7ae177 remove unneeded function from the crypto stream interface 2017-12-12 18:30:08 +07:00
Marten Seemann
3d47284e1c Merge pull request #1007 from lucas-clemente/min-streamframe-size
don't add more STREAM frames to a packet if remaining size is too small
2017-12-12 18:22:23 +07:00
Marten Seemann
16d610417b don't send every MAX_{STREAM}_DATA twice 2017-12-12 18:06:55 +07:00
Marten Seemann
eb3e253be2 send MAX_{STREAM}_DATA frames more frequently
WINDOW_UPDATEs are relatively small, and it doesn't cost much to grant
the peer more flow control credit earlier.
2017-12-12 18:06:49 +07:00
Marten Seemann
4aca4d64b7 don't add more STREAM frames to a packet if remaining size is too small 2017-12-12 18:00:05 +07:00
Marten Seemann
9b4cdf66fc Merge pull request #1009 from lucas-clemente/fix-1008
correctly handle frames for the crypto stream
2017-12-12 17:56:49 +07:00
Marten Seemann
bf53bf8815 Merge pull request #1016 from lucas-clemente/remove-frame-minlength-error
remove the error return value from wire.Frame.MinLength
2017-12-12 17:50:45 +07:00
Marten Seemann
dfa2181657 reject RST_STREAM frames for the crypto stream 2017-12-12 17:37:15 +07:00
Marten Seemann
81e13e52fd reject STREAM frames that would close the crypto stream 2017-12-12 17:37:15 +07:00
Marten Seemann
5a36a287de handle MAX_STREAM_DATA frames for the crypto stream 2017-12-12 17:36:59 +07:00
Marten Seemann
4b4e487486 remove the error return value from wire.Frame.MinLength
No functional change expected.
The error was only non-nil if some required values for the STOP_WAITING
frame were not set. It should be sufficient to throw an error when
attempting to write an invalid STOP_WAITING frame.
2017-12-12 17:33:04 +07:00
Marten Seemann
ded0eb4f6f Merge pull request #1018 from lucas-clemente/milestone-0.6
release 0.6.0
v0.6.0
2017-12-12 17:29:19 +07:00
Marten Seemann
e8d9de0e79 release 0.6.0 2017-12-12 17:03:43 +07:00
Marten Seemann
5f5ba2c02f Merge pull request #1010 from lucas-clemente/simplify-frame-handling
simplify frame handling
2017-12-12 16:44:35 +07:00
Marten Seemann
632040bd2b Merge pull request #1001 from lucas-clemente/min-packet-size
implement the minimum packet size requirements
2017-12-12 16:37:53 +07:00
Marten Seemann
51c5cc46d8 remove the internal error for RST_STREAM frames for closed streams 2017-12-10 23:34:09 +07:00
Marten Seemann
ba4e980876 remove the internal error for MAX_STREAM_DATA frames for closed streams 2017-12-10 23:29:01 +07:00
Marten Seemann
489ea7fa1a Merge pull request #997 from lucas-clemente/stream-refactoring
refactor sending of stream data
2017-12-08 22:55:42 +07:00
Marten Seemann
7e627d38ea Merge pull request #999 from lucas-clemente/reject-version-0
reject packets with version 0 sent by the client
2017-12-08 22:54:08 +07:00
Marten Seemann
aa1d541fbd Merge pull request #1000 from lucas-clemente/remove-getbyteorder
remove unused utils.GetByteOrder
2017-12-08 22:53:32 +07:00
Marten Seemann
e5a1a650b9 Merge pull request #1005 from julienschmidt/handleRequest
shorten blocking call of h2quic.Server.handleRequest
2017-12-08 16:16:29 +07:00
Julien Schmidt
feab6e8450 shorten blocking call of Server.handleRequest 2017-12-08 09:41:57 +01:00
Marten Seemann
8e8892b064 remove the SentFin method from the stream
When a FIN is dequeued from the stream by the streamFramer, it is
guaranteed to be sent out. There's no need to explicitely signal that to
the stream.
2017-12-08 14:05:16 +07:00
Marten Seemann
71af5758e2 remove the ShouldSendFin method from the stream
GetDataForWriting now has two return parameters: the data and if a FIN
should be sent.
2017-12-08 14:05:14 +07:00
Marten Seemann
085624be20 replace stream.LenOfDataForWriting by HasDataForWriting
The return value (the length of data for writing) was only used to
determine if the stream has data for writing. Therefore it's easier to
just return a bool.

No functional change expected.
2017-12-08 14:04:00 +07:00
Marten Seemann
ef89e7aa17 drop Initial packets that don't fulfill the min size requirement 2017-12-08 12:37:04 +07:00
Marten Seemann
23ce5a8554 drop packets for new gQUIC connections that are too small 2017-12-08 12:34:59 +07:00
Marten Seemann
6019634286 pad Initial packets to the required minimum size (1200 bytes) 2017-12-08 11:50:43 +07:00
Marten Seemann
f8cbb0ae03 remove unused utils.GetByteOrder
This function was needed when we supported both Q039 (using big endian
encoding) and ealier versions (using little endian encoding).
2017-12-08 11:33:40 +07:00
Marten Seemann
62a664f5f4 Merge pull request #967 from lucas-clemente/varint-encoding
implement the new varint frame types
2017-12-08 09:46:50 +07:00
Marten Seemann
d7ceebd644 implement parsing and writing of the new ACK frame 2017-12-08 09:35:55 +07:00
Marten Seemann
11f746a183 implement parsing and writing of the new STREAM frames 2017-12-08 09:20:47 +07:00
Marten Seemann
1a515d1371 implement the new variable integer length frame types 2017-12-08 09:18:54 +07:00
Marten Seemann
759b0d87b1 refactor packet unpacking
This replaces version.UsesMaxDataFrame by versoin.UsesIETFFrameFormat.
That way, we can have two separate code paths in the unpacker to unpack
either gQUIC frames or IETF frames.
2017-12-08 09:18:54 +07:00
Marten Seemann
0ac728f96e implement the new variable integer length encoding 2017-12-08 09:18:54 +07:00
Marten Seemann
62b0d99dcd reject packets with version 0 sent by the client
Version 0 is an invalid version. For packets sent by the server, it is
used to identify the Version Negotiation Packet.
2017-12-08 09:14:41 +07:00
Marten Seemann
2b5573fe82 Merge pull request #980 from lucas-clemente/stateless-retry
implement stateless handling of Initial packets for the TLS server
2017-12-08 09:05:58 +07:00
Marten Seemann
25a6dc9654 implement stateless handling of Initial packets for the TLS server 2017-12-08 08:45:54 +07:00
Marten Seemann
57c6f3ceb5 don't return the handshakeChan from the session constructor 2017-12-08 07:34:57 +07:00
Marten Seemann
c65f055ec1 Merge pull request #970 from lucas-clemente/fix-872
allow packet number 0
2017-12-07 21:46:57 +07:00
Marten Seemann
2905a37928 handle ACKs for packet number 0 2017-12-07 21:33:34 +07:00
Marten Seemann
0219193a07 accept packet 0 in the ReceivedPacketHandler and generate ACKs for it 2017-12-07 21:33:34 +07:00
Marten Seemann
f90029ef64 change ReceivedPacketHandler such that it can generate ACKs for packet number 0 2017-12-07 21:33:34 +07:00
Marten Seemann
a79e9ee35e parse and write STOP_WAITING frames for packet number 0 2017-12-07 21:33:34 +07:00
Marten Seemann
6ce3336be5 parse and write ACKs that for packet number 0 2017-12-07 21:33:34 +07:00
Marten Seemann
cc3bfc1fa7 remove bug check for increasing packet number in SentPacketHandler 2017-12-07 21:33:34 +07:00
Marten Seemann
6695983a43 remove error var and internalize member variable in SentPacketHandler 2017-12-07 21:33:34 +07:00