升级到Android 16(SDK 36)后API调用出现CertPathValidatorException问题求助
升级到Android 16(SDK 36)后API调用出现CertPathValidatorException问题求助
各位好,我最近把应用适配到Android 16(SDK 36)之后,遇到了一个棘手的问题:所有API调用都会触发SSL握手失败,抛出的异常信息如下:
Caused by: java.security.cert.CertPathValidatorException: Response is unreliable: its validity interval is out-of-date at sun.security.provider.certpath.PKIXMasterCertPathValidator.validate(PKIXMasterCertPathValidator.java:135) at sun.security.provider.certpath.PKIXCertPathValidator.validate(PKIXCertPathValidator.java:222) at com.android.org.conscrypt.TrustManagerImpl.verifyChain(TrustManagerImpl.java:705)
目前我已经做了这些排查和尝试,但问题依然存在:
- 确认了在Android 16以下的版本中,完全没有这个问题
- 在多台运行Android 16的实体设备和模拟器上都复现了该异常
- 已经升级了OkHttp、Retrofit以及所有相关Android依赖到最新版本
有没有朋友遇到过类似的情况?或者能给我一些下一步排查的方向?非常感谢!
内容来源于stack exchange
相关产品推荐
相关产品推荐

