包含 html 框架和 apache 反向代理的混合内容的浏览器阻止请求?
Blocked Request by browser with mixed content with html frame and apache reversed proxy?
我是 运行 apache 反向代理后面的网络应用程序(Sonatype 的 Nexus):
ProxyRequests Off
ProxyPreserveHost Off
ProxyPass /nexus http://127.0.0.1:8081/nexus
ProxyPassReverse /nexus http://127.0.0.1:8081/nexus
该网页使用几个框架来显示 nexus 网站(只是一个管理站点):
<frameset>
<frame src="quickMenu.html" />
<frame src="../nexus" />
</frameset>
加载此网页时,它告诉我它阻止了 ../nexus link,因为它是通过 http 加载的,而该网站是通过 https:
Mixed Content: The page at 'https://dev.bla.nl/apps/nexusFrame.html' was loaded over HTTPS, but requested an insecure resource 'http://dev.bla.nl/nexus/'. This request has been blocked; the content must be served over HTTPS.
我不明白这个错误,因为页面是作为 https 页面加载的,并且 nexus 站点是作为相对路径包含的。
如果我直接打开页面 https://dev.bla.nl/nexus,它工作得很好 :(
我玩过像 ProxyRequests/ProxyPreserveHost 这样的反向代理设置,但没有成功。
知道如何解决这个问题吗?
注意:在 Nexus 应用 运行 在 Tomcat 容器中之前,我使用 Ajp 作为代理通道,效果很好,即:
ProxyPass /nexus ajp://127.0.0.1:8080/nexus
ProxyPassReverse /nexus ajp://127.0.0.1:8080/nexus
知道如何解决这个问题吗?
我建议使用简单代理而不是将 Nexus 嵌入框架中。有关如何配置的详细信息可以是 found in the documentation.
通过反向代理配置将传入请求 header 添加为 x-forwarded-proto: https
这应该可以解决混合内容问题,因为 Nexus 将通过 https 协议而不是 http
请求所有资源
我是 运行 apache 反向代理后面的网络应用程序(Sonatype 的 Nexus):
ProxyRequests Off
ProxyPreserveHost Off
ProxyPass /nexus http://127.0.0.1:8081/nexus
ProxyPassReverse /nexus http://127.0.0.1:8081/nexus
该网页使用几个框架来显示 nexus 网站(只是一个管理站点):
<frameset>
<frame src="quickMenu.html" />
<frame src="../nexus" />
</frameset>
加载此网页时,它告诉我它阻止了 ../nexus link,因为它是通过 http 加载的,而该网站是通过 https:
Mixed Content: The page at 'https://dev.bla.nl/apps/nexusFrame.html' was loaded over HTTPS, but requested an insecure resource 'http://dev.bla.nl/nexus/'. This request has been blocked; the content must be served over HTTPS.
我不明白这个错误,因为页面是作为 https 页面加载的,并且 nexus 站点是作为相对路径包含的。
如果我直接打开页面 https://dev.bla.nl/nexus,它工作得很好 :( 我玩过像 ProxyRequests/ProxyPreserveHost 这样的反向代理设置,但没有成功。 知道如何解决这个问题吗?
注意:在 Nexus 应用 运行 在 Tomcat 容器中之前,我使用 Ajp 作为代理通道,效果很好,即:
ProxyPass /nexus ajp://127.0.0.1:8080/nexus
ProxyPassReverse /nexus ajp://127.0.0.1:8080/nexus
知道如何解决这个问题吗?
我建议使用简单代理而不是将 Nexus 嵌入框架中。有关如何配置的详细信息可以是 found in the documentation.
通过反向代理配置将传入请求 header 添加为 x-forwarded-proto: https
这应该可以解决混合内容问题,因为 Nexus 将通过 https 协议而不是 http