Android Okhttp请求https配置信任证书

okhttp请求https配置证书


    /**
     * 配置https证书
     *
     * @return
     */
    public SSLSocketFactory getSSLSocketFactory() {
   
    
    
        try {
   
    
    
            CertificateFactory cf;
            cf = CertificateFactory.getInstance("X.509");

            Certificate ca;
            InputStream caInput = new BufferedInputStream(getAssets

猜你喜欢

转载自blog.csdn.net/Chen_xiaobao/article/details/126378686
今日推荐