【问题标题】:how to trust certificate based on CA, not on thumbprint bases in android application如何信任基于 CA 的证书,而不是基于 Android 应用程序中的指纹基础
【发布时间】:2017-03-30 04:51:51
【问题描述】:

我已按照链接 https://developer.android.com/training/articles/security-ssl.html#UnknownCa 中提到的说明连接到具有自签名证书的 HTTPS 服务器。 我已将证书上传到 azure 服务并在 android 应用程序中添加了相同的证书,然后它工作正常,但是当我从服务中的同一个 CA 更改证书时,它停止工作。它给出了一个错误 javax.net.ssl.SSLHandshakeException: java.security.cert.CertPathValidatorException: Trust anchor for certificate path not found

但根据 Google 文章,应用程序应该信任来自同一 CA 的所有证书。

我还检查了此链接http://www.codeproject.com/Articles/826045/Android-security-Implementation-of-Self-signed-SSL(请参阅本页的 DRAWBACK 部分),acc。到此页面无法在服务和应用程序中与不同的证书进行通信。

请让我知道我可以信任基于 CA 的 android 应用程序中的证书吗?

【问题讨论】:

    标签: android azure ssl-certificate ca


    【解决方案1】:

    当您可以从Let's Encrypt 免费获得受信任的 SSL 证书时,为什么还要尝试使用自签名证书。然后你就不必处理这些事情了。

    【讨论】:

    • 你是对的,但我想用自签名证书来做。
    猜你喜欢
    • 2013-10-16
    • 1970-01-01
    • 2021-09-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多