[英]Disabling HTTP/2 / SPDY in HTTP.SYS and IIS in Windows 10
When testing on Windows 10 we were seeing lots of browser incompatibilities that I hadn't seen before with earlier Windows versions.在 Windows 10 上进行测试时,我们发现了许多浏览器不兼容问题,这是我以前在 Windows 早期版本中从未见过的。 Some browsers would work, but others would report ERR_SPDY_PROTOCOL_ERROR.
一些浏览器可以工作,但其他浏览器会报告 ERR_SPDY_PROTOCOL_ERROR。 My quick search for this problem showed I was not alone.
我对这个问题的快速搜索表明我并不孤单。
My app uses WWSAPI and HTTP.SYS with HTTPS (TLS).我的应用程序使用 WWSAPI 和 HTTP.SYS 与 HTTPS (TLS)。 Does anyone know how to disable SPDY / HTTP/2 in WWSAPI (which is using HTTP.SYS) on Windows 10?
有谁知道如何在 Windows 10 上的 WWSAPI(使用 HTTP.SYS)中禁用 SPDY/HTTP/2?
I'd also love to get a full up-to-date Windows 10 list of registry settings for HTTP.SYS.我也很想获得 HTTP.SYS 的完整最新的 Windows 10 注册表设置列表。
See below for my answer to this.我对此的回答见下文。 Hope this helps others too.
希望这对其他人也有帮助。
Mark标记
EDIT: disabling HTTP/2 will significantly slow down the speed of your website, this is not a permanent solution.编辑:禁用 HTTP/2 会显着降低您网站的速度,这不是永久性的解决方案。 The problem turned out to be caused by our webapp sending a wrong authentication header to the server.
问题原来是由我们的 webapp 向服务器发送错误的身份验证标头引起的。
To still disable HTTP/2, see below.要仍然禁用 HTTP/2,请参见下文。
(OP gave a helpful answer, but in the question. I moved the answer): (OP给出了一个有用的答案,但在问题中。我移动了答案):
I did work around my HTTP/2 problem by configuring Windows 10 HTTP.SYS in the registry to disable HTTP/2.
我确实通过在注册表中配置 Windows 10 HTTP.SYS 来禁用 HTTP/2 来解决我的 HTTP/2 问题。 Given that I didn't find info anywhere, I thought I'd share my solution to that problem here too.
鉴于我没有在任何地方找到信息,我想我也会在这里分享我对这个问题的解决方案。 I would like to find a way of doing this through WWSAPI though.
不过,我想找到一种通过 WWSAPI 执行此操作的方法。
If I turned off SPDY support in the client browser, it would work but I wanted to turn this off at the server side (HTTP.SYS on Windows 10) so that it wouldn't negotiate HTTP/2 but would use the older more compatible HTTP(S).
如果我在客户端浏览器中关闭 SPDY 支持,它会起作用,但我想在服务器端关闭它(Windows 10 上的 HTTP.SYS),这样它就不会协商 HTTP/2,但会使用更旧的更兼容HTTP(S)。
Discovered two new registry settings for HTTP.SYS in:
在以下位置发现 HTTP.SYS 的两个新注册表设置:
HKEY_LOCAL_MACHINE\\System\\CurrentControlSet\\Services\\HTTP\\Parameters
EnableHttp2Tls
REG_DWORD
0
EnableHttp2Tls
REG_DWORD
0
EnableHttp2Cleartext
REG_DWORD
0
EnableHttp2Cleartext
REG_DWORD
0
Adding these values and setting both to 0 in Windows 10 resulted in HTTP/2 / SPDY not being negotiated and my ERR_SPDY_PROTOCOL_ERROR problems went away without requiring browser configuration changes.
在 Windows 10 中添加这些值并将两者都设置为 0 导致无法协商 HTTP/2 / SPDY,并且我的 ERR_SPDY_PROTOCOL_ERROR 问题消失了,而无需更改浏览器配置。 I'm not suggesting there is anything wrong with Windows 10 HTTP/2, the problems may be with certain browsers.
我并不是说 Windows 10 HTTP/2 有什么问题,问题可能出在某些浏览器上。
This may work for IIS too, but I don't use that so I haven't tried and in any case there may be a better way to do this in IIS.
这也可能适用于 IIS,但我不使用它,所以我没有尝试过,无论如何在 IIS 中可能有更好的方法来做到这一点。
Hope this helps others too.
希望这对其他人也有帮助。
I can confirm this helps for IIS too, but I had to restart my computer .我可以确认这对 IIS 也有帮助,但我必须重新启动计算机。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.