Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-users] How to test HTTP/3?

On 7/27/22 07:41, Michał Niklas wrote:
After some problems with private key I started my Jetty server listening on both HTTP/2 and HTTP/3.

I can see HTTP/2 on TCP port 18443 and HTTP/3 un UDP 18444:

[mn:~] $ netstat -lnp | grep 22019

tcp6  0 0 :::18443  :::*  LISTEN  22019/java

udp6  0 0 :::18444  :::*          22019/java

Not an expert with Jetty.  I can't say for sure that Jetty isn't the problem, but it seems more likely that it's a network issue.

Do you have a firewall on the server?  If so, does it allow UDP/18444 inbound?  Is there another firewall involved?  For instance, if the server is in AWS, the traffic must be allowed in the AWS security settings as well as on the server itself.  Have you done a packet capture to see whether UDP/18444 packets are being received by the server?

Exactly what do you have in the alt-svc header?  This is the line in my haproxy config that creates the header for my setup.  I use UDP/443:

        http-response add-header alt-svc 'h3=":443"; ma=7200' if http3

Is there a firewall on the client system and/or the network for the client?  If so, is outbound UDP/18444 allowed?

The first requests that the browser sends will be TCP, likely HTTP/2.  Then if the browser gets a valid alt-svc header and everything is set up right, it will switch subsequent requests to HTTP/3.

TLDR:

I saw something saying Chrome can only do http3 on port 443.  But that doesn't explain Firefox not working.  (Saw it on https://www.haproxy.org, text "Chrome only accepts H3 on port 443")

There is at least one http3 checker website out there that will tell you whether the server is properly set up for http3.  This URL runs a check against one of my websites.  If your site is reachable from the open Internet, you can use it to check your site too:

https://http3check.net/?host=https%3A%2F%2Fhttp3test.elyograg.org%2F

If you decide to actually try my test site at https://http3test.elyograg.org/ it will tell you that it's not using HTTP3 when you first access it, but if you reload (not shift-reload) the site, it should change.

I have an extension in my browsers that displays an indicator so the HTTP version used for the site is readily apparent.  The one for firefox is called "HTTP Version Indicator" and the one for Chrome is called "HTTP Indicator."

Thanks,
Shawn



Back to the top