Marten Seemann
fbaa941ea1
protocol: rename VersionNumber to Version ( #4295 )
2024-01-31 21:57:33 -08:00
Marten Seemann
69ba7acb9f
ackhandler: don't delay ACKs for Initial and Handshake packets ( #4288 )
...
* ackhandler: don't delay ACKs for Initial and Handshake packets
* ackhandler: embed the receivedPacketHistory
2024-01-31 19:13:53 -08:00
Marten Seemann
72c79dbdf5
testutils: expose aliases for all frame types ( #4293 )
2024-01-30 21:47:03 -08:00
Marten Seemann
86441f1fdc
ci: make Codecov ignore testutils and testdata ( #4292 )
2024-01-30 21:22:40 -08:00
Marten Seemann
e65e99f1d6
ci: remove unused depguard check for qtls ( #4291 )
...
Fortunately, qtls is a thing of the past.
2024-01-30 19:30:11 -08:00
Marten Seemann
da25787a3d
testutils: make the package public ( #4290 )
...
This package can be useful outside of quic-go. We're not making any API
guarantees at this point.
2024-01-30 19:00:08 -08:00
Marten Seemann
d330d2e30d
remove unused RTTStats from the received packet handler ( #4287 )
2024-01-30 01:02:30 -08:00
Marten Seemann
be4838bd64
wire: remove FrameParser interface, expose FrameParser struct ( #4284 )
...
Instead, expose the FrameParser struct. This allows us to embed it
directly into the connection struct, avoiding a pointer indirection.
2024-01-28 22:34:28 -08:00
Marten Seemann
34c4d89e8b
fix flaky outgoing streams map test ( #4283 )
2024-01-28 21:52:32 -08:00
Marten Seemann
03ba124241
testutils: add a perspective function parameter to ComposeInitialPacket ( #4276 )
...
Currently not used, but this is useful when crafting Initial packets
sent from the client. No functional change expected.
2024-01-28 21:30:23 -08:00
Marten Seemann
940feef063
only log the discarding of Handshake keys once ( #4274 )
2024-01-28 20:51:22 -08:00
Marten Seemann
9b83ac230b
fix flaky handshake limiting test ( #4281 )
2024-01-28 20:26:03 -08:00
Marten Seemann
c82c37a31c
fix flaky accept queue test ( #4280 )
2024-01-28 20:14:02 -08:00
taoso
808f849ca2
http3: only use :protocol pseudo-header for Extended CONNECT ( #4261 )
...
* Fix protocol
The default value should be "HTTP/3.0".
* Reject normal request with :protocol header
The :protocol pseudo header is only defined for
Extended Connect requests (RFC 9220).
* save one branch check
* Fix review issue
2024-01-25 19:07:35 -08:00
Marten Seemann
d3974e1674
fix flaky handshake limiting test ( #4270 )
2024-01-25 00:53:20 -08:00
Marten Seemann
baeec0f41c
ci: update to Go 1.22rc2 ( #4267 )
2024-01-24 19:16:17 -08:00
Marten Seemann
2a7a11f4c0
remove unneeded nil check for new connections in the server ( #4260 )
2024-01-23 21:45:03 -08:00
Marten Seemann
a968e254a1
fix incorrect statement about connection ID lengths in the Transport ( #4247 )
2024-01-23 21:22:28 -08:00
Marten Seemann
a2cf43d75c
remove the RequireAddressValidation callback from the Config ( #4253 )
2024-01-22 21:24:07 -08:00
Marten Seemann
892851eb8c
add Transport config options to limit the number of handshakes ( #4248 )
...
* add Transport config options to limit the number of handshakes
* fix accounting for failed handshakes
* increase handshake limits, improve documentation
2024-01-22 21:04:25 -08:00
putyWang
bda5b7e6dc
handshake: fix documentation for updatableAEAD.SetWriteKey ( #4256 )
2024-01-22 19:30:50 -08:00
Marten Seemann
4407c60f04
handshake: unexport Set{Read,Write}Key methods on the cryptoSetup ( #4254 )
...
No functional change expected.
These methods were exported since they were passed to the old qtls API.
2024-01-19 20:44:09 -08:00
Marten Seemann
594440b04c
don't remove closed connections from the server's accept queue ( #4245 )
2024-01-18 22:45:38 -08:00
Marten Seemann
cb1775a08a
send out the CONNECTION_REFUSED error when refusing a connection ( #4250 )
...
So far, we used Connection.destroy, which destroys a connection without
sending out a CONNECTION_CLOSE frame. This is useful (for example) when
receiving a stateless reset, but it's not what we want when the server
refuses an incoming connection. In this case, we want to send out a
packet with a CONNECTION_CLOSE frame to inform the client that the
connection attempt is being rejected.
2024-01-18 22:29:22 -08:00
Marten Seemann
b3eb375bc1
remove shutdown method on the Connection ( #4249 )
...
There's no need to have a dedicated shutdown method, as the use case
(shutting down an outgoing connection attempt on context cancellation)
can be achieved by using Connection.destroy.
2024-01-18 22:06:04 -08:00
Marten Seemann
d3c2020ecd
http3: add a basic README ( #4246 )
v0.41.0
2024-01-16 19:34:10 -08:00
Marten Seemann
3449ace5a6
example: remove -qlog flag in favor of QLOGDIR ( #4243 )
2024-01-13 18:30:59 -08:00
Marten Seemann
13327521a5
example: remove -v flag and custom logger configuration ( #4242 )
...
Users can adjust the log level using the QUIC_GO_LOG_LEVEL environment
variable. This is more representative of how quic-go would actually be
used, since the logger is part of an internal package.
2024-01-13 01:59:58 -08:00
Benedikt Spies
2cd9ed38f1
qlog: add a default tracer that writes to QLOGDIR ( #4233 )
...
* add qlog default tracer which writes to QLOGDIR
* gofumpt
* add qlog default tracer which writes to QLOGDIR
* fix flaky tests
* Update README.md
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
* Update README.md
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
* Update README.md
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
* Update README.md
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
---------
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
2024-01-12 03:11:53 -08:00
Marten Seemann
1e874896cd
wire: improve logging of connection ID retirements ( #4241 )
2024-01-10 21:53:25 -08:00
Marten Seemann
0a922b4e7d
example: add config flag for TLS key and cert for the server ( #4237 )
2024-01-05 02:21:42 -08:00
Robin Thellend
3ff50295ce
http3: add ConnContext to the server ( #4230 )
...
* Add ConnContext to http3.Server
ConnContext can be used to modify the context used by a new http
Request.
* Make linter happy
* Add nil check and integration test
* Add the ServerContextKey check to the ConnContext func
* Update integrationtests/self/http_test.go
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
* Update http3/server.go
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
---------
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
2024-01-04 19:13:53 -08:00
Marten Seemann
f1b3bdbcb0
fix race condition when dropping Initial packet with short connection ID ( #4236 )
2024-01-04 18:59:39 -08:00
Marten Seemann
54d6f7dc51
ackhandler: refactor ACK queueing logic ( #4225 )
...
Once an ACK has been queued, there's no need to check futher conditions that
would lead to queueing of an ACK.
2024-01-03 18:39:09 -08:00
Marten Seemann
8cad3d2ea5
wire: use netip.AddrPort to encode the IPs in the Preferred Address ( #4232 )
2024-01-02 21:56:25 -08:00
Marten Seemann
59ed51704a
README: add RoadRunner to list of projects ( #4226 )
2024-01-02 21:32:58 -08:00
Marten Seemann
1083d1fb8f
handshake: remove unneeded mutex in cryptoSetup ( #4227 )
2024-01-01 23:52:08 -08:00
Marten Seemann
22b7f7744e
use a ring buffer for the datagram queue ( #4223 )
2023-12-31 20:50:26 -08:00
Marten Seemann
1fce81f8bb
queue up to 32 DATAGRAM frames to send ( #4222 )
2023-12-31 19:58:41 -08:00
Marten Seemann
7f080dd54b
discard DATAGRAM frames that don't fit into packets without an ACK ( #4221 )
...
If the packet doesn't contain an ACK (i.e. the payload is empty),
there's no point retrying to pack it later. It's extremely unlikely that
the available packet size will suddenly increase.
2023-12-31 19:17:25 -08:00
Marten Seemann
d6e3f3229f
qtls: remove unneeded type alias for the tls.QUICEncryptionLevel ( #4220 )
...
* qtls: remove unneeded type alias for the tls.QUICEncryptionLevel
* handshake: make cryptoSetup.WriteRecord private
2023-12-28 18:59:56 -08:00
Vladimir Varankin
a937959fbf
http3: fix channel size in ListenAndServe ( #4219 )
...
* http3: typo in ListenAndServe docs
Also, partially prevent a goroutine leak on an error from one of the
listeners.
* http3: improve documentation for ListenAndServe
---------
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
2023-12-28 18:35:46 -08:00
Marten Seemann
22411e16d5
utils: switch to standard library min and max functions ( #4218 )
...
These functions were added in Go 1.21.
2023-12-27 21:19:13 -08:00
Marten Seemann
18c591c75a
utils: use time.Duration.Abs ( #4217 )
...
This function was added in Go 1.19, and covers some corner cases that
our custom implementation didn't.
2023-12-27 20:49:47 -08:00
Marten Seemann
d795250479
drop support for Go 1.20, build on Go 1.22rc1 on CI ( #4195 )
...
* drop support for Go 1.20
* ci: udpate CircleCI to Go 1.21
* qtls: remove unnecessary type aliases
* ci: build using Go 1.22rc1
2023-12-27 20:31:58 -08:00
Benedikt Spies
31a677cacd
qlog: add support for alpn_information event ( #4216 )
...
* qlog chosen alpn
* qlog chosen alpn
* qlog: fix capitalization of ALPN
---------
Co-authored-by: Marten Seemann <martenseemann@gmail.com >
2023-12-25 21:02:47 -08:00
Marten Seemann
2243fdefbf
http3: return the context cancellation error from RoundTrip ( #4203 )
2023-12-20 20:16:30 -08:00
Constantine Shablia
d3c5f389d4
http3: improve debug message when determining the listener port fails ( #4214 )
...
Fixes : #4212
2023-12-18 21:03:28 -08:00
Constantine Shablia
5d6bf7e206
http3: don't use error string as a format string in debug log message ( #4211 )
...
Fixes : #4209
2023-12-18 19:27:07 -08:00
WeidiDeng
e0bf13be01
http3: reset stream when a handler panics ( #4181 )
...
* interrupt the stream when a panick happened
* move the declaration of errPanicked
* check what's read is a prefix of what's written
* check errPanicked
* use MatchError instead of Equal
* use channel to notify the response has been received
2023-12-15 19:39:49 -08:00