是否可以在android webview中存储SSL证书
在我正在开发的应用程序中,我必须向网络服务器发送 HTTPS 请求。当我直接执行此操作(没有 webview)时,我收到了证书不受信任的错误。
但是,当我使用 android webview 加载 HTTPS URL 时,
public void onReceivedSslError (WebView view, SslErrorHandler handler, SslError error) {
handler.proceed() ;
}
当我收到 SSL 证书不可信错误时,我可以继续连接。
我的疑问是
1)如果我使用上述方法,Android Webview 是否会将证书实际存储在其密钥库中?
2)同样的 Webview 是否能够使用其密钥库中的证书来接受与同一个 HTTPS 服务器的进一步连接?
3)我们能否以编程方式将一些证书放入 webview 的密钥库中,以便它接受与启用 HTTPS 的服务器的所有连接?
我对很多问题感到困惑问题。
请帮忙。
In the app I'm working on, I have to make an HTTPS post to a web server. I was getting certificate not trusted errors when i do it directly(without webview).
But when i use android webview to load the HTTPS URL i can do
public void onReceivedSslError (WebView view, SslErrorHandler handler, SslError error) {
handler.proceed() ;
}
to proceed with the connection when i get a SSL certificate not trusted error.
My doubt is
1)if i use the above method will Android Webview actually store the certificate in its keystore?
2)Also will the same Webview be able to use the certificate in its keystore to accept the further connections to the same HTTPS server?
3)Can we programatically put some certificate in the webview's keystore so that it accepts all connections to an HTTPS enabled server?
I am confused with lot of questions.
Please help.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论