Search code examples
apachesslhttpshttp2

http/2.0 doesn't work after I upgrade to apache httpd 2.4.25


Previously I use http/2.0 well on apache httpd2.4.18. Today I upgrade in to httpd2.4.25 and found that all my webpages went back to http/1.1 with a Upgrade: "h2" response head on my Firefox v53.0. I've tried Browser won't upgrade to H2 altough "Upgrade" headers are sent but it didn't work.

The resopnse head is:

Date: Tue, 13 Jun 2017 04:40:05 GMT
Server: Apache/2.4.25 (Red Hat) OpenSSL/1.0.1e-fips mod_fcgid/2.3.9 Phusion_Passenger/5.0.18 mod_wsgi/4.5.7 Python/2.6
Upgrade: h2
Connection: Upgrade, Keep-Alive
Accept-Ranges: bytes
Vary: Accept-Encoding
Content-Encoding: gzip
Content-Length: 3489
Keep-Alive: timeout=5, max=100
Content-Type: text/html; charset=UTF-8

Why so? I did't change any configurations of my httpd server.


Solution

  • This has nothing to do with your upgrade and this wouldn't work under your set up for 2.4.18 either.

    The reason is not working for you is that Firefox 53 has removed HTTP/2 Support over the older NPN method and now requires ALPN as detailed in the release notes.

    This brings it inline to Chrome which has already dropped NPN support.

    Unfortunately this means, you now must use openssl 1.0.2 or above as 1.0.1 which you are using does not support ALPN. However this is a bit tricky since Red Hat does not provide anything later than 1.0.1e through the official repos. RedHat 7.4 is due to get it hopefully but until then your options are to use an unofficial repo, or install from source (I've a blog post on how to do the latter). I imagine you are already doing this somewhat to get Apache 2.4.25 since it is not available on Red Hat either through the official repos.