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

QUIC & HTTP/3 support #1558

Open
ozyman42 opened this issue Jan 22, 2019 · 26 comments
Open

QUIC & HTTP/3 support #1558

ozyman42 opened this issue Jan 22, 2019 · 26 comments
Labels
ext/fetch related to the ext/fetch ext/http related to ext/http public API related to "Deno" namespace in JS suggestion suggestions for new features (yet to be agreed)

Comments

@ozyman42
Copy link

It would be nice if the Deno standard library had QUIC protocol support out-of-the-box, implemented in Rust underneath. QUIC will likely be the UDP-based alternative to TCP used as the foundation for the Internet Engineering Task Force (IETF)'s upcoming HTTP3 spec. Essentially QUIC is a more efficient implementation of the combined capabilities of TCP and TLS, and a less mature version of QUIC has been used by Google for years in requests from Chrome to its own webservers. Node.js has an open issue for adding in QUIC support, but based on the discussion there I'm assuming that the priority is low for them. They may not understand the significance of adding support.

@ry
Copy link
Member

ry commented Jan 22, 2019

I agree - would be great - and seems relatively accessible with
https://github.com/djc/quinn
I’m open to anyone who wants to attempt this. And if someone doesn’t pick it up, I would try myself once a few other things have been taken care of (We still don’t have basic TLS support for example- that should come first)

@ry ry added this to the future milestone Jan 22, 2019
@kyranet kyranet mentioned this issue Jan 23, 2019
@ry ry mentioned this issue Jan 25, 2019
@xin-hao-2025
Copy link

Maybe we can also consider https://github.com/cloudflare/quiche

@trivikr
Copy link
Contributor

trivikr commented Sep 30, 2019

Existing implementations of QUIC: https://github.com/quicwg/base-drafts/wiki/Implementations

The ones (under active development) in Rust:

@95th
Copy link
Contributor

95th commented Jan 5, 2020

quiche seems to expose only mio based non-blocking API and not an async API.

@cretz
Copy link

cretz commented Jan 5, 2020

From my experience with quiche, it's only the CPU bound parts, you bring your own network IO. I have used it with a Tokio UDP socket and converted it to a modern Rust async futures stream+sink. The library is basically only the hard parts of state machine, parsing, and crypto pieces.

The bigger problem with using quiche is that they require BoringSSL and have multiple times stated they are unlikely to change (see cloudflare/quiche#129 (comment) and cloudflare/quiche#16 (comment)). But there is an old PR open yet on hold for OpenSSL so maybe there's hope for rustls.

@akshatagarwl
Copy link
Contributor

@ry Is anyone working on this issue? I could give this a shot. Can't give any guarantees though.

@kitsonk
Copy link
Contributor

kitsonk commented Mar 22, 2020

Make sure you check out #3995 as it is more comprehensive of an issue (I missed this one when I opened that) and Ry had some thoughts on implementation.

@fimbault
Copy link

An empirical study on QUIC implementations that's worth reading https://qlog.edm.uhasselt.be/epiq
And a summary if you don't have much time https://qlog.edm.uhasselt.be/epiq/images/summary.png

@kitsonk
Copy link
Contributor

kitsonk commented Sep 25, 2020

Even though #3995 came after this one, let's close it in lieu of #3995 as it is more comprehensive.

@kitsonk kitsonk closed this as completed Sep 25, 2020
@balupton
Copy link
Contributor

balupton commented Jan 29, 2021

@kitsonk kitsonk reopened this Apr 20, 2021
@kitsonk kitsonk added public API related to "Deno" namespace in JS suggestion suggestions for new features (yet to be agreed) labels Apr 20, 2021
@waldyrious
Copy link
Contributor

For reference, this issue has been reopened following @ry's comment when closing #3995 (which this issue had been closed as a duplicate/subset of):

HTTP/2 shipped in v1.9.0 (see #9935)

HTTP/3 and QUIC can be discussed in a new issue.

@lucacasonato lucacasonato changed the title QUIC support QUIC & HTTP/3 support Jun 27, 2022
@rektide
Copy link

rektide commented Sep 13, 2022

hyper underpins deno's native http extensions. there is hyperium/hyper#1818 for http3 support in the hyper framework. there's an experimental implementation, hyperium/h3.

@ahmadkakarr
Copy link

when http/3 can be implemented in deno?

@mmastrac mmastrac added ext/fetch related to the ext/fetch ext/http related to ext/http labels Nov 7, 2023
@trusktr
Copy link

trusktr commented Nov 28, 2023

What's interesting about HTTP/3 is that people will make ESM CDN servers that can server-push module graphs to clients and possibly beat bundlers, and this highly aligns with Deno's vanilla-esm-and-importmaps philosophy. The sooner we have HTTP/3, the sooner we might have even better vanilla ESM support in Deno (and others) where module downloads will be very optimized (f.e. all gzipped and cached from the CDN).

@devsnek
Copy link
Member

devsnek commented Jan 15, 2024

i'm working on an initial implementation of QUIC here #21942

@masx200
Copy link

masx200 commented Mar 19, 2024

caddyserver/caddy#5086

@masx200
Copy link

masx200 commented Mar 19, 2024

Many of Cloudflare's websites have been blocked.

any update?
I found that the https TLS connection of the existing website was attacked by a man-in-the-middle, and the connection was disconnected, and the connection was successful only by using quic "xxxxxxxxxxx.xxxxxxxxxxxxxxxxx.xxxxxxxxx.workers.dev"!

我发现有的网站的https的tls连接被中间人攻击了,连接被断开了,只有使用quic才能连接成功!比如说"xxxxxxxxxxx.xxxxxxxxxxxxxxxxx.xxxxxxxxx.workers.dev".

At present, browsers Firefox, Chrome, and Edge already support HTTP3, and there is also a query of HTTPS type through DNS, and you can find out the server's support for HTTP3.

目前浏览器firefox,chrome,edge都已经支持http3了,还有通过dns查询https类型,可以查到服务器对于http3的支持情况.

I found that Chrome was able to open Cloudflare's workers.dev website, but deno couldn't access workers.dev.

@highlyrecommand
Copy link

highlyrecommand commented Jul 26, 2024

@masx200

Many of Cloudflare's websites have been blocked.

any update? I found that the https TLS connection of the existing website was attacked by a man-in-the-middle, and the connection was disconnected, and the connection was successful only by using quic "xxxxxxxxxxx.xxxxxxxxxxxxxxxxx.xxxxxxxxx.workers.dev"!

我发现有的网站的https的tls连接被中间人攻击了,连接被断开了,只有使用quic才能连接成功!比如说"xxxxxxxxxxx.xxxxxxxxxxxxxxxxx.xxxxxxxxx.workers.dev".

At present, browsers Firefox, Chrome, and Edge already support HTTP3, and there is also a query of HTTPS type through DNS, and you can find out the server's support for HTTP3.

目前浏览器firefox,chrome,edge都已经支持http3了,还有通过dns查询https类型,可以查到服务器对于http3的支持情况.

I found that Chrome was able to open Cloudflare's workers.dev website, but deno couldn't access workers.dev.

Your issue is not related to Deno, as it is caused by the Great Firewall of China. The Great Firewall is an IDS (Intrusion Detection System) bypass detector that can reassemble TCP packets and then perform struct decode and matching. Additionally, TLS handshake packets are not encrypted, and it contain SNI (Server Name Indication) field. The Great Firewall can easily identify and block subsequent connections. Moreover, I can tell you that the Initial Packet of HTTP/3 (QUIC) is also not encrypted (pseudo-encrypted), so the Great Firewall can potentially recognize and block HTTP/3 connections in future updates.

@SerJaimeLannister
Copy link

Any updates on this?

@o-t-w
Copy link

o-t-w commented Nov 2, 2024

All web browsers now support HTTP/3 so support in Deno would be great. https://caniuse.com/http3

@CyanChanges
Copy link

This was merged which implemented QUIC API in Deno.
#21942

@SerJaimeLannister
Copy link

Yes this is awesome , any way of accessing this right now in deno since I am excited in trying out the quic api.

Also since you've supported quic , does your api also support http/3 ?

and can I use this directly with the deno.serve -ish?

Deno.serve((_req) => {
  return new Response("Hello, World!");
});
``

like I would love it , if we could simply replace it directly with another function or  a cli flag Deno.serve_http3 or maybe

deno run --http3  main.ts ? 

or something like this.


This is really good and I thank you for building this from my side.

Hope that you achieve the best in the world!

@CyanChanges
Copy link

Yes this is awesome , any way of accessing this right now in deno since I am excited in trying out the quic api.

Also since you've supported quic , does your api also support http/3 ?

and can I use this directly with the deno.serve -ish?

Deno.serve((_req) => {
  return new Response("Hello, World!");
});
``

like I would love it , if we could simply replace it directly with another function or  a cli flag Deno.serve_http3 or maybe

deno run --http3  main.ts ? 

or something like this.


This is really good and I thank you for building this from my side.

Hope that you achieve the best in the world!

I guess there's only something like Deno.openQuic
There's no HTTP/3 support yet ig?

@SerJaimeLannister
Copy link

SerJaimeLannister commented Dec 21, 2024

How hard is http/3 support though? if Quic has been supported ?

@unixfox
Copy link

unixfox commented Dec 21, 2024

@SerJaimeLannister please do not spam the users subscribed to this issue.

Only the QUIC interface has been merged, now there are still work in progress to be able to use "fetch" using HTTP3. You can follow the work here: #27431

Once there will be something concrete I think it will be announced here.

@devsnek
Copy link
Member

devsnek commented Dec 21, 2024

HTTP/3 is on the 2025 roadmap for hyper (the http library used by deno). As that moves along, we will be able to hook it up with the QUIC layer in the various places you would expect it to be.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ext/fetch related to the ext/fetch ext/http related to ext/http public API related to "Deno" namespace in JS suggestion suggestions for new features (yet to be agreed)
Projects
None yet
Development

No branches or pull requests