skip to Main Content

Is there any way I can implement HTTP/3 in Apache?

Edit:

The QUIC protocol has now been made an RFC, see RFC 9000. Waiting for HTTP/3…

OpenSSL said somewhere that they will begin working on QUIC after they release OpenSSL 3.0. Not sure when OpenSSL 3.0 is going to be released.

Until that, maybe we can integrate BoringSSL into Apache, and start testing stuff with QUIC.

2

Answers


  1. Chosen as BEST ANSWER

    Temporary solution until Apache supports HTTP/3:

    Note: Compile NGINX with quiche, only use this solution when you want to test HTTP/3, as it is not very reliable.

    One solution I got is, you can run NGINX using HTTP/3 only on 443 with only QUIC, so it will use UDP.

    And, you can use Apache on 443 which will use TCP.

    So, you can make Apache send the Alt-Svc header, and make it handle HTTP/0.9, HTTP/1.0, HTTP/1.1 and HTTP/2.0.

    And, you can make NGINX like a wrapper around Apache using:

    listen 1.2.3.4:443 quic reuseport;
    location / {
         proxy_pass https://your-apache-server.tld:443;
    }
    

    This just makes you allowed to run:

    • HTTP/0.9
    • HTTP/1.0
    • HTTP/1.1
    • HTTP/2.0 with TLS
    • HTTP/2.0 without TLS, using Upgrade: h2c header to upgrade to it
    • HTTP/2.0 without TLS, using H2Direct in Apache to enable http2-prior-knowledge (not sure what its actually called).
    • HTTP/3.0

    FAQ

    • Well, why would you want to do this? Instead just use NGINX!
      If you need some features that apache offers, like HTTP/2 clear text (http upgrade: header or directly), if you don't need those features, you can just stick with NGINX.
      Or if you just want to use Apache for all the main stuff.

    Issues

    • I've noticed that nginx has some issues with serving POST requests when the current configuration is deployed.

  2. No there is no way at present. Apache has not committed to doing the work required here at this time.

    LiteSpeed is an Apache alternative supporting many of the same features, but with strong QUIC and HTTP/3 support.

    Nginx also has only made vague comments about QUIC and HTTP/3 but Cloudflare have made an Nginx patch available that adds QUIC and HTTP/3 support. (Edit Nginx have since previewed HTTP/3 support built independently of Cloudflare’s implementation).

    Or alternatively Caddy is another alternative server with QUIC and HTTP/3 support.

    However, if I were looking to enable, or even just experiment, with QUIC and HTTP/3 I would look to a CDN as they will be the simplest way to enable this and ensure you have optimal settings. Cloudflare have a free plan that (I think) also includes HTTP/3 and QUIC support so is easy to set up in front of a site you own.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search