且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

重定向已从Https降级为Http

更新时间:2023-10-30 23:22:34

我终于找到了问题.基本上就是 Apache conf中的这一行:

I finally found the issue. Basically it was this line in the Apache conf:

ProxyPreserveHost on

由于我们系统内所有重定向的请求都丢失了 Https 协议,因此正在更改标头 Location .此后,所有发送回的重定向都使用 Http .

It was changing the header Location as all requests redirected inside our system lose the Https protocol. All redirects sent back were using Http after this.

一种继续使用此配置的解决方案是使用以下命令手动覆盖 Apache conf中的 Http :

A solution to keep using this configuration is to manually override Http in the Apache conf with this:

Header edit Location ^http://(.*)$ https://$1