如何从使用Android SDK中一个HTTPS服务器的响应? [英] How to get a response from a https server using android sdk?

查看:76
本文介绍了如何从使用Android SDK中一个HTTPS服务器的响应?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有SSL异常的一个问题,当我上传数据到HTTPS服务器。它上传数据到服务器正常,但是当我得到的回应上传后,抛出一个异常的SSL证书不被信任。我使用SAX解析器解析XML文件,我使用httppost()的方法。

I have a problem of ssl exception when i upload data to a https server. It uploaded the data to the server correctly but when i get the response after uploading it throws an exception of ssl certificate is not trusted. I'm using the SAX parser for parsing xml file and i am using httppost method().

推荐答案

您必须添加一个新的计划,以接受安全站点连接

you have to add a new scheme to accept Secure site connections

检查这一点,在那里你会发现没有检查cetificate另一种有用的样本...

check this, and there you will find another useful sample without checking the cetificate...

HTTPS连接的Andr​​oid

这篇关于如何从使用Android SDK中一个HTTPS服务器的响应?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆