Marten Seemann
8bd6168511
never increase the flow control limit for the crypto stream
2018-09-19 09:00:23 -04:00
Marten Seemann
c0d4f00b20
implement gQUIC 44
2018-08-28 08:49:29 +07:00
Marten Seemann
70992684af
use server generated connection IDs when accepting a connection
2018-08-13 08:47:29 +07:00
Marten Seemann
f88b7bb175
implement the new Retry mechanism
2018-08-13 08:47:29 +07:00
Marten Seemann
04147d86da
rename the cryptoStreamI interface to cryptoStream
2018-08-11 12:45:43 +07:00
Marten Seemann
defafec71e
use retransmissions as TLP packets
2018-08-09 22:28:28 +07:00
Marten Seemann
2b1dce4b37
Merge pull request #1465 from lucas-clemente/fix-public-reset-logging
...
fix logging of the connection ID for PUBLIC_RESETs
2018-08-08 08:43:27 +07:00
Marten Seemann
1ecce9c288
log keep alive packets
2018-08-07 18:38:08 +07:00
Marten Seemann
1472d2a143
fix logging of the connection ID for PUBLIC_RESETs
2018-08-03 10:41:10 +07:00
Marten Seemann
6d3d6dc47d
pass an error code to Session.CloseWithError
2018-07-06 15:51:38 +07:00
Marten Seemann
8b2992a243
split the Session.Close(error) in Close() and CloseWithError(error)
2018-07-06 15:51:35 +07:00
Marten Seemann
0928e91e4d
remove closed clients from the multiplexer
2018-07-03 17:30:49 +07:00
Marten Seemann
fc57bf6c35
only set the destination connection ID for the Public Header
2018-06-24 16:47:59 +07:00
Marten Seemann
b3fd768a61
use a smaller packetHandler interface
...
The packetHandler interface just needs two methods: one for handling
packets, and one for closing.
2018-06-23 08:16:51 +07:00
Marten Seemann
e5746e0881
drop packets with different source connection IDs
...
The server can change the connection ID with the first Handshake packet.
Afterwards, packets with different source connection IDs have to be
ignored. Otherwise, for example the retransmission of the Initial packet
might create two sessions on the server with different source connection
IDs on the server side, but the same connection ID on the client side.
2018-06-11 21:37:56 +02:00
Marten Seemann
d32665af9d
remove FHL2 experiment
...
FHL2 was an experiment in Chrome, run in Q036, which introduced HOL
blocking. This experiment is over, so we can remove the code to send a
PUBLIC_RESET when a peer initiates this experiment.
2018-06-10 17:02:06 +02:00
Marten Seemann
3e03055a7d
use varint packet numbers in IETF QUIC headers
2018-06-06 16:07:47 +02:00
Marten Seemann
ec6118f7a0
use the connection ID provided by the server in first Handshake packet
2018-05-30 21:37:05 +08:00
Marten Seemann
733e2e952b
use callbacks for signaling the session status
...
Instead of exposing a session.handshakeStatus() <-chan error, it's
easier to pass a callback to the session which is called when the
handshake is done.
The removeConnectionID callback is in preparation for IETF QUIC, where a
connection can have multiple connection IDs over its lifetime.
2018-05-29 21:27:08 +08:00
Marten Seemann
c7119b2adf
move logging of connection closing to the session
2018-05-29 21:24:24 +08:00
Marten Seemann
02db7817fb
make the peer completing the handshake last send a forward-secure packet
...
In gQUIC, the server completes the handshake first (after sending the
SHLO). In TLS 1.3, the client completes the handshake first (after
sending the CFIN).
They need to have some way to learn that the peer successfully completed
the handshake, so they can stop retransmitting the handshake packets
containing the SHLO or the CFIN, respectively. To achieve that, the peer
finishing the handshake last will send a PING frame in a forward-secure
packet.
2018-05-29 20:51:29 +08:00
Marten Seemann
bd483c75e5
don't save anything about a packet before authenticating it
2018-05-16 18:59:43 +09:00
Marten Seemann
d1dd2a4a60
add logging to the ackhandler
2018-05-14 11:05:37 +09:00
Marten Seemann
08160ab18f
queue connection-level window updates from the flow controller directly
...
It is not sufficient to check for connection-level window updates every
time a packet is sent. When a connection-level window update needs to be
sent, we need to make sure that it gets sent immediately (i.e. call
scheduleSending() in the session).
2018-05-08 15:17:45 +09:00
Marten Seemann
2e8a5807ba
queue stream-level window updates from the flow controller directly
2018-05-08 15:17:45 +09:00
Marten Seemann
903747fdc7
remove stray commented code in the session
2018-04-29 20:48:03 +09:00
Marten Seemann
1420b138d5
implement TLPs
2018-04-25 20:47:18 +09:00
Marten Seemann
0c014c0aff
fix deadlock when receiving two packets with diversification nonces
2018-04-24 21:14:58 +09:00
Marten Seemann
0e58a679d6
Merge pull request #1319 from lucas-clemente/fix-1307
...
use different source and destination connection IDs
2018-04-23 17:29:45 +09:00
Marten Seemann
e813d41376
handle PATH_CHALLENGE frames, reject PATH_RESPONSE frames
2018-04-23 16:41:06 +09:00
Marten Seemann
fae32101a0
use different source and destination connection IDs
2018-04-23 15:23:01 +09:00
Marten Seemann
d47124d14d
add more methods to the protocol.ConnectionID
...
This will make it easier to change the underlying type of the connection
ID (potentially an array is faster than a byte slice).
2018-04-19 16:08:06 +09:00
Marten Seemann
52d31dd7ef
implement the new header format
...
Currently, we're only sending and accepting packets with matching source
and destination connection IDs.
2018-04-19 13:46:54 +09:00
Marten Seemann
f052861775
only allow sending of retransmissions if these are RTO probe packets
2018-04-17 19:58:53 +09:00
Marten Seemann
a23c94dd87
fix race condition when the handshake completes
...
When the handshake completes, the crypto setup closes the handshakeEvent
channel. We need to make sure that the session run loop immediately
selects this case, and not any other case (especially the packet
reception case). Otherwise, the server crypto setup will deadlock,
because the sentSHLO channel won't be closed, and opening of
forward-secure packets will block indefinitely on that channel.
2018-04-16 13:36:06 +09:00
Marten Seemann
948eef3e42
create a logger interface and use it everywhere
2018-04-04 13:03:28 +07:00
Marten Seemann
302d2a1715
don't use trial decryption for IETF QUIC
2018-03-31 14:29:44 +07:00
Marten Seemann
6c1eba5848
generate the diversification nonce when creating the server crypto setup
2018-03-31 14:29:44 +07:00
Marten Seemann
69f6427d3c
refactor session to use a much smaller crypto setup
2018-03-31 14:29:44 +07:00
Marten Seemann
c6526ad927
replace the SetDiversificationNonce crypto setup method by a chan
2018-03-31 14:29:44 +07:00
Marten Seemann
2fbc994d29
move the unencrypted STREAM frame check from the unpacker to the session
2018-03-31 14:29:44 +07:00
Marten Seemann
fed3bf503e
keep track of which packets were sent as retransmissions
...
When an ACK for a packet that was retransmitted arrives, we don't need
to retransmit the retransmission, even if it was lost.
2018-03-16 16:54:39 +01:00
Marten Seemann
56720edc34
report retransmissions separately to the sent packet handler
2018-03-14 11:15:52 +01:00
Marten Seemann
555fa8ec8e
Merge pull request #1232 from lucas-clemente/packet-sending-modes
...
implement packet send modes to determine what kind of packets are sent
2018-03-13 17:39:20 +01:00
Marten Seemann
b5977236ff
implement packet send modes to determine what kind of packets are sent
2018-03-13 14:49:48 +01:00
Marten Seemann
9d18d30931
use the peer's max_packet_size when packing packets
2018-03-10 14:27:07 +07:00
Marten Seemann
6ccc76a130
send packets with maximum IPv4 and IPv6 packet size
2018-03-09 22:36:44 +07:00
Marten Seemann
abf57a5551
calculate the packet number length in the sent packet handler
2018-03-07 15:56:18 +07:00
Marten Seemann
ca2471e78d
remove explicit error for duplicate or out of order ACKs
2018-03-07 09:30:05 +07:00
Marten Seemann
5c98332e90
implement ACK decimation
...
ACK generation closely follows Chrome's QuicConnection::MaybeQueueAck()
in ACK_DECIMATION_WITH_REORDERING mode.
2018-03-05 19:56:19 +07:00