Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RunQUIC does not connect via browser #3976

Open
vbackeberg opened this issue May 23, 2024 · 2 comments
Open

RunQUIC does not connect via browser #3976

vbackeberg opened this issue May 23, 2024 · 2 comments

Comments

@vbackeberg
Copy link

vbackeberg commented May 23, 2024

Description

Not an issue, yet, but I think the upcoming QUIC implementation won't work in the browser.

@thinkerou, @appleboy
Have you tested it in the browser?
I believe you will need to use http3.ListenAndServeTLS instead of http3.ListenAndServeQuic here:

gin/gin.go

Line 572 in 24d6764

func (engine *Engine) RunQUIC(addr, certFile, keyFile string) (err error) {

The reason is the server first needs to advertise the QUIC support over TCP, apparently.
The issue was discussed here:
quic-go/quic-go#3890

I have made a few tests of your code and some own implementation and came across this issue.

Expectations

Browser connects

Actual result

Browser does not connect with NS_ERROR_CONNECTION_REFUSED

Environment

  • go version: 1.22.3
  • gin version (or commit ref): 3ac729d
  • operating system: windows
@wangshiben
Copy link

I also meet this problem, QUIC protocol will not take effect in the Chrome browser's core. But you can test it in firefox core.And I also made a framework to support quic server(as high-performance as Gin, or even faster, and also support http1.0 to http 2.0).

QuicFrameWork

Test Documentation

@aitay721822
Copy link

It is possible to use goroutines to simultaneously serve both HTTP/2 and QUIC servers, while also setting the ALT-SVC header in the HTTP/2 server.

I recently learned that DNS SVCB records can be used to discover QUIC servers, so a TCP connection might not be necessary I think

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants