Commit graph

184 commits

Author SHA1 Message Date
Marten Seemann
8c4e4a3208 remove complex checks performed on the tls.Config 2019-07-28 23:57:33 +07:00
spacewander
755a46d6e2 allow host without port passed as 'host' argument in Dial function.
Previously, if the given host doesn't contain port, dial with it will
result in error "missing port in address".
2019-07-06 15:52:26 +08:00
Marten Seemann
267d11ee66 add tracing for sent and received packets 2019-06-20 22:58:01 +08:00
Marten Seemann
a8633a952c introduce a type for the stream number 2019-06-05 17:45:17 +08:00
Marten Seemann
09111b45f9 reject a tls.Config without NextProtos for dialing 2019-06-02 14:58:41 +08:00
Marten Seemann
6c27967c8a include the timer granularity in the advertised max_ack_delay 2019-05-08 13:26:08 +09:00
Marten Seemann
af8c03ebaf advertize the max_ack_delay in the transport parameters 2019-05-08 13:22:37 +09:00
Marten Seemann
94046cdb4b implement sending of stateless resets 2019-03-08 18:10:15 +09:00
Marten Seemann
733dcb75eb rename the methods of the sessionRunner interface 2019-03-08 18:09:36 +09:00
Marten Seemann
9c09e84765 use IETF QUIC transport error codes 2019-03-06 13:43:18 +09:00
Marten Seemann
02e851bd11 cut coalesed packets in the session 2019-02-27 10:03:34 +09:00
Marten Seemann
df34e4496e identify version negotiation packets without parsing the header 2019-02-23 10:24:42 +08:00
Marten Seemann
17f4ebad64 handle Retry packets in the session 2019-02-04 15:38:47 +08:00
Marten Seemann
155ebd18a2 parse and send the ack_delay_exponent in the transport parameters 2019-01-28 16:09:47 +09:00
Marten Seemann
bb185a3ad2 add a function to close the packet handler map
Close will close the underlying connection and wait until listen has
returned. While not strictly necessary in production use, this will fix
a few race conditions in our tests.
2019-01-24 18:09:46 +07:00
Marten Seemann
178ac0dacb keep increasing the packet number after version negotiation and retry 2018-12-22 22:15:35 +06:30
Marten Seemann
f9218444a9 use a separate function to close the session after VN and retry 2018-12-21 23:47:10 +06:30
Marten Seemann
3f9831a93d
Merge pull request #1638 from lucas-clemente/improve-packet-handling
make packet handling as non-blocking as possible
2018-11-27 18:43:52 +07:00
Marten Seemann
8ea110d99b
Merge pull request #1642 from lucas-clemente/improve-packet-conn-documentation
improve the description of how we handle net.PacketConns
2018-11-27 17:24:38 +07:00
Marten Seemann
574126d0eb handle Retry packets in a separate Go routine 2018-11-27 17:19:21 +07:00
Marten Seemann
7fecf8e478 handle Version Negotiation packets in a separate Go routine 2018-11-27 17:19:21 +07:00
Marten Seemann
a8db148dbf don't lock the client mutex when handling regular packets 2018-11-27 17:19:21 +07:00
Marten Seemann
38548c137c remove unneeded check for destination connection ID in the client
The packetHandlerMap routes packets to the client based on the
destination connection ID, so we can be sure that packets that are
handled in the client have the right connection ID.
2018-11-27 17:19:21 +07:00
Marten Seemann
708aa165bc improve the description of how we handle net.PacketConns 2018-11-27 16:33:03 +07:00
Marten Seemann
37495d967a keep the connection IDs when receiving a version negotiation packet 2018-11-27 13:13:50 +07:00
Marten Seemann
c5ca6fd7e5 parse the extended header in the session 2018-11-26 15:57:54 +07:00
Marten Seemann
9bcedd988d move parsing of version negotiation packets to the wire.Header 2018-11-26 15:57:54 +07:00
Marten Seemann
bf96707f48 rename the wire.Header to ExtendedHeader
It's not encrypted yet.
2018-11-26 15:57:54 +07:00
Marten Seemann
65cca7b726 immediately remove sessions that were closed remotely
We only need to keep sessions that were closed locally, in order to
retransmit the CONNECTION_CLOSE packet. For sessions that were closed by
the peer, we don't need to wait for any more packets, and there's also
no CONNECTION_CLOSE to retransmit. The same applies for sessions that
were destroyed when receiving a Version Negotiation or a Retry packet.
2018-11-16 21:22:32 +07:00
Marten Seemann
a3831b2134 rename removing of connection IDs to retiring 2018-11-16 21:22:32 +07:00
Marten Seemann
c8ae4fada0 remove the close callback from the client 2018-11-16 21:22:32 +07:00
Marten Seemann
4b37ecb2b5 use the same default max flow control window sizes for client and server 2018-11-12 23:38:07 +07:00
Marten Seemann
190d1dcc59
Merge pull request #1595 from lucas-clemente/fix-1529
authenticate retries
2018-11-12 18:00:22 +07:00
Marten Seemann
3ffea5d8c4 internalize the qerr package 2018-11-11 12:44:16 +07:00
Marten Seemann
70cb67bd2a check that the server sends the correct original_connection_id 2018-11-11 11:00:40 +07:00
Marten Seemann
66a72a1199 use varints for numeric transport parameters 2018-11-05 12:33:32 +07:00
Marten Seemann
16848038be remove unnecessary initial packet number parameter 2018-11-02 17:14:31 +07:00
Marten Seemann
9981026839 split the flow control transport parameters 2018-11-01 13:09:29 +07:00
Marten Seemann
a1acfc3045 rename {Stream,Connection}FlowControlWindow to InitialMax{Stream}Data 2018-10-30 12:52:42 +07:00
Marten Seemann
3266e36811 drop support for gQUIC 2018-10-30 10:20:39 +07:00
Marten Seemann
82508f1562 use tls-tris instead of mint 2018-10-26 16:18:49 +07:00
Marten Seemann
a7f94d89b6 only allow a single retry 2018-10-24 23:48:33 +07:00
Marten Seemann
c1f55ba910 use tls.Config.ServerName for the passing the hostname around 2018-10-02 14:47:18 -07:00
Marten Seemann
c0d4f00b20 implement gQUIC 44 2018-08-28 08:49:29 +07:00
Marten Seemann
7bf5cb6e2a
Merge pull request #1487 from lucas-clemente/version-negotiate-ietf-and-gquic
allow version negotiation between IETF QUIC and gQUIC, and vice versa
2018-08-15 19:47:35 +07:00
Marten Seemann
c840bd4177 allow version negotiation between IETF QUIC and gQUIC, and vice versa 2018-08-15 17:10:05 +07:00
Marten Seemann
9608e8563f only accept 3 retries
While the server is allowed to perform multiple Retries, the client
should impose a limit in order to avoid being caught in an endless loop.
2018-08-14 18:35:25 +07:00
Marten Seemann
872e1747f4 always use connection IDs longer than 8 bytes when sending a Retry
A server is allowed to perform multiple Retries. There's little to gain
from doing so, but it's something our API allows. If a server performs
multiple Retries, it must use a connection ID that's at least 8 bytes
long. Only if it doesn't perform any further Retries it is allowed to
use shorter IDs. Therefore, we're on the safe side by always using a
long connection ID.
This shouldn't have a performance impact, since the server changes the
connection ID to a short value with the first Handshake packet it sends.
2018-08-14 17:34:21 +07:00
Marten Seemann
829edc04ab accept multiple Retries 2018-08-14 17:18:44 +07:00
Marten Seemann
f88b7bb175 implement the new Retry mechanism 2018-08-13 08:47:29 +07:00