Chrome 和 IE 中的自签名证书问题,但在 Firefox 中正常

Self signed certificate in Chrome and IE issue, but fine in Firefox

我正在使用自签名证书来开发 Open Layer 3 实施。

OL3 正在使用 https://localhost:8443, and the website is being hosted at https://localhost:444 从 Geoserver 读取图层。为此,我正在使用 Apache 和 Tomcat 7。

这在 Firefox 中一切正常。虽然我收到了关于证书的初步警告。但接受风险后,它可以毫无问题地通过 https 连接,并且所有内容都已正确传送。

在 Chrome 和 IE 中,但是我在控制台中收到以下错误,并且站点没有从 Geoserver 接收内容:

https://localhost:8443/geoserver/
Failed to load resource: net::ERR_INSECURE_RESPONSE

这与端口 8443 相关联,Tomcat 正在使用它来传送 Open Layer 3 内容。

事实证明,原因是 Chrome 和 IE 使用证书存储,它会检查该证书存储以验证证书,而 Firefox 不会。您必须将自签名证书分配给证书存储,以允许将任何数据传输到 IE 和 Chrome.

中的客户端

在IE中可以左键点击证书错误->查看证书->安装证书,然后在Trusted Root Certification Authorities文件夹中安装证书。刷新,它对我有用。