Android 是否支持与 SSLScoket/SSLEngine 的非加密连接?
在我的 Android 应用程序中,我想使用 SSLSocket 或 SSLEngine 和 TLSv1.2 支持与 TLS/SSL 的未加密连接。在这种情况下,仅执行身份验证,但连接将保持非私有或未加密。
它可以通过简单地启用空密码套件(例如 TLS_RSA_WITH_NULL_SHA、TLS_RSA_WITH_NULL_SHA256 和 TLS_ECDH_RSA_WITH_NULL_SHA 等)在其他平台(如 iOS、Windows 和 Mac)上实现。
但不幸的是,Android 不允许其中任何一个使用 SSLParameters 进行配置并抛出 IIlegalArgument 异常不支持空密码。
还有什么办法呢?我可以配置任何空密码并实现未加密的连接吗?
In my android app, I want to support an unencrypted connection with TLS/SSL using SSLSocket or SSLEngine with TLSv1.2. In this case, only authentication will be performed but the connection will remain non-private or unencrypted.
It can be achieved with other platforms like iOS, Windows, and Mac by simply enabling a null cipher suite i.e TLS_RSA_WITH_NULL_SHA, TLS_RSA_WITH_NULL_SHA256, and TLS_ECDH_RSA_WITH_NULL_SHA, etc.
But unfortunately, Android doesn't allow any of them to configure with SSLParameters and throws IIlegalArgument Exception of Null Cipher not supported.
What is another way around? Can I configure any of the null ciphers and achieve an unencrypted connection?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论