服务器发送http不响应,虽然服务器在响应头中发送“Upgrade:h2”,但无法向Apache服务器发出http2请求 - apache代码 - 源码查...

该博客讲述了在Apache Web Server上启用HTTP/2后,浏览器仍然使用HTTP/1.1的情况。问题在于服务器发送了Upgrade头,但浏览器未升级到HTTP/2。解决方案是更新SSL配置,使用特定的加密套件,并确保不使用黑名单中的加密算法。在更改httpd配置文件并重启服务后,应避免出现NS_ERROR_NET_INADEQUATE_SECURITY错误。
摘要由CSDN通过智能技术生成

问题

I have enabled mod_http2 for the Apache Web Server, and made the necessary changes in the conf, still any request made from a browser to the server follows http/1.1 Protocol

The server sends a Upgrade:h2 header field but the browser still continues to make http/1.1 requests.

IwgOj.png

rrW7q.png

How can i make a h2 request from Mozilla/Chrome?

I'm using Mozilla Firefox 48.0

解决方法

The HTTP/2 standard imposes some extra requirements on https, no cipher from a specified black list may be used.

An acceptable Apache SSL configuration regarding this is:

SSLCipherSuite ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-AES256-GCM-SHA384:DHE-RSA-AES128-GCM-SHA256:DHE-DSS-AES128-GCM-SHA256:kEDH+AESGCM:ECDHE-RSA-AES128-SHA256:ECDHE-ECDSA-AES128-SHA256:ECDHE-RSA-AES128-SHA:ECDHE-ECDSA-AES128-SHA:ECDHE-RSA-AES256-SHA384:ECDHE-ECDSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:ECDHE-ECDSA-AES256-SHA:DHE-RSA-AES128-SHA256:DHE-RSA-AES128-SHA:DHE-DSS-AES128-SHA256:DHE-RSA-AES256-SHA256:DHE-DSS-AES256-SHA:DHE-RSA-AES256-SHA:!aNULL:!eNULL:!EXPORT:!DES:!RC4:!3DES:!MD5:!PSK

SSLProtocol All -SSLv2 -SSLv3

This needs to be changed in the httpd config file and NS_ERROR_NET_INADEQUATE_SECURITY should not occur after httpd restart.

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值