gpt4 book ai didi

android - ParseObject 测试因安全异常而失败

转载 作者:太空狗 更新时间:2023-10-29 14:05:47 27 4
gpt4 key购买 nike

我正在按照快速入门指南进行操作,但出现错误

private void parseServerTest(){

 ParseObject testObject = new ParseObject("TestObject");

testObject.put("foo","bar");

 testObject.saveInBackground(new SaveCallback() {

@Override

 public void done(ParseException e) {

 if(null != e){

e.printStackTrace();

 }else{

 Log.d(TAG,"no parse error.")

}

}


 });

}

Unless the instructions is missing something, I think I have done everything to the letter

以防万一,我的应用正在开发中,Playstore 上还没有:甚至还没有草稿

这是错误轨迹:

com.parse.ParseRequest$ParseRequestException: i/o 失败在 com.parse.ParseRequest.newTemporaryException (ParseRequest.java:368)在 com.parse.ParseRequest$2.then(ParseRequest.java:206)在 com.parse.ParseRequest$2.then(ParseRequest.java:198)在 bolts.Task$14.run(Task.java:796)在 java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1112)在 java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:587)在 java.lang.Thread.run(Thread.java:818)原因:javax.net.ssl.SSLHandshakeException:java.security.cert.CertPathValidatorException:找不到证书路径的信任 anchor 。在 com.android.org.conscrypt.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:324)在 android.net.SSLCertificateSocketFactory.verifyHostname(SSLCertificateSocketFactory.java:235)在 android.net.SSLCertificateSocketFactory.createSocket(SSLCertificateSocketFactory.java:486)在 com.android.okhttp.Connection.upgradeToTls(Connection.java:1259)在 com.android.okhttp.Connection.connect(Connection.java:1197)在 com.android.okhttp.internal.http.HttpEngine.connect(HttpEngine.java:392)在 com.android.okhttp.internal.http.HttpEngine.sendRequest(HttpEngine.java:295)在 com.android.okhttp.internal.http.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:373)在 com.android.okhttp.internal.http.HttpURLConnectionImpl.connect(HttpURLConnectionImpl.java:106)在 com.android.okhttp.internal.http.HttpURLConnectionImpl.getOutputStream(HttpURLConnectionImpl.java:208)在 com.android.okhttp.internal.http.DelegatingHttpsURLConnection.getOutputStream(DelegatingHttpsURLConnection.java:218)在 com.android.okhttp.internal.http.HttpsURLConnectionImpl.getOutputStream(HttpsURLConnectionImpl.java:25)在 com.parse.ParseURLConnectionHttpClient.executeInternal(ParseURLConnectionHttpClient.java:42)在 com.parse.ParseHttpClient$ParseNetworkInterceptorChain.proceed(ParseHttpClient.java:155)在 com.parse.ParsePlugins$1.intercept(ParsePlugins.java:111)在 com.parse.ParseHttpClient$ParseNetworkInterceptorChain.proceed(ParseHttpClient.java:144)在 com.parse.ParseHttpClient.execute(ParseHttpClient.java:119)在 com.parse.ParseRequest$3.then(ParseRequest.java:195)在 com.parse.ParseRequest$3.then(ParseRequest.java:192)在 bolts.Task$14.run(Task.java:796)在 bolts.BoltsExecutors$ImmediateExecutor.execute(BoltsExecutors.java:105)在 bolts.Task.completeAfterTask(Task.java:787)在 bolts.Task.continueWithTask(Task.java:599)在 bolts.Task.continueWithTask(Task.java:610)在 bolts.Task$12.then(Task.java:702)在 bolts.Task$12.then(Task.java:690)... 还有 4 个原因:java.security.cert.CertificateException:java.security.cert.CertPathValidatorException:找不到证书路径的信任 anchor 。在 com.android.org.conscrypt.TrustManagerImpl.checkTrusted(TrustManagerImpl.java:318)在 com.android.org.conscrypt.TrustManagerImpl.checkServerTrusted(TrustManagerImpl.java:219)在 com.android.org.conscrypt.Platform.checkServerTrusted(Platform.java:113)在 com.android.org.conscrypt.OpenSSLSocketImpl.verifyCertificateChain(OpenSSLSocketImpl.java:574)在 com.android.org.conscrypt.NativeCrypto.SSL_do_handshake( native 方法)在 com.android.org.conscrypt.OpenSSLSocketImpl.startHandshake(OpenSSLSocketImpl.java:320)... 29 更多原因:java.security.cert.CertPathValidatorException:未找到证书路径的信任 anchor 。... 还有 35 个

最佳答案

好像有时间延迟。我继续做别的事情。现在四个小时后,我运行了非常相同的代码并且它可以工作。我什么都没改变。所以新开的parse账户肯定有某种时间延迟。

关于android - ParseObject 测试因安全异常而失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32510578/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com