net :: ERR_INSECURE_RESPONSE从node-webkit发出ajax请求时
当我试图用jquery发出ajax请求时:
https://localhost:8443/uri
我收到此错误:
net::ERR_INSECURE_RESPONSE
我在package.json中使用自签名证书我有以下参数:
"chromium-args": "--ignore-certificate-errors --auth-schemes='basic --auth-server-whitelist='*localhost:8443' --auth-negotiate-delegate-whitelist='*localhost:8443'''",
有谁知道如何将自签名证书添加到node-webkit的信任库!
操作系统:ubuntu 14.10
这里的问题是浏览器阻止对该服务器的调用,因为该服务器具有无效的证书。 由于它是本地主机服务器,因此它是一个自签名证书 。 解决这个问题的最佳方法是尝试以下方法之一……
- 更改localhost:8443服务器以使用有效证书
- 在浏览器中加载页面https:// localhost:8443 / ,接受无效证书,然后尝试ajax调用。