Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

手机连代理抓包,上传图片失败,如何解决呢? #487

Open
hust-twj opened this issue Jul 25, 2022 · 4 comments
Open

手机连代理抓包,上传图片失败,如何解决呢? #487

hust-twj opened this issue Jul 25, 2022 · 4 comments

Comments

@hust-twj
Copy link

hust-twj commented Jul 25, 2022

错误信息:
{ver:8.4.2,ResponseInfo:1658735114477872,status:-1200, reqId:, xlog:null, xvia:null, host:api.qiniu.com, time:1658735227,error:java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.}

看类似的 issue,说是SSL 要求时间必须匹配,但我手机的时间是没问题的。

ps:手机连代理后,抓其他的接口都可以,唯独这个上传图片的失败。

@hust-twj hust-twj changed the title 上传图片,连代理抓包就上传失败,如何解决呢? 手机连代理抓包,上传图片失败,如何解决呢? Jul 25, 2022
@YangSen-qn
Copy link
Contributor

@hust-twj 抓包时使用 http 请求:

Configuration configuration = new Configuration.Builder()
                .useHttps(false)
                .build();

@hust-twj
Copy link
Author

@hust-twj 抓包时使用 http 请求:

Configuration configuration = new Configuration.Builder()
                .useHttps(false)
                .build();

用 http 还是不行,仍然报错:
{ver:8.4.2,ResponseInfo:1658801322050626,status:-1009, reqId:, xlog:null, xvia:null, host:null, time:1658801374,error:check origin statusCode:-1200 error:java.security.cert.CertPathValidatorException: Trust anchor for certification path not found.}

@YangSen-qn
Copy link
Contributor

YangSen-qn commented Jul 28, 2022

@hust-twj 上传使用姿势方便发下吗?我们这边测试 https 和 http 抓包都是可以正常上传的,且使用 useHttps(false) 后正常会走 http 进行上传,并不会涉及 ssl 证书问题了。

@hust-twj
Copy link
Author

可以先关了吧

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants