google v2 ct list deprecated - android

I have implemented Certificate transparency using com.appmattus.certificatetransparency:certificatetransparency library. Now v2 list is not supported by google and every API is giving this error
Failure: Unable to load log servers with log-list.json failed to load with java.io.IOException: Invalid response 404
at com.appmattus.certificatetransparency.internal.loglist.CallExtKt$await$2$1$1.onResponse(CallExt.kt:45)
at okhttp3.internal.connection.RealCall$AsyncCall.run(RealCall.kt:519)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
at java.lang.Thread.run(Thread.java:1012)
How can I solve this?

Related

Can not communicate with Firebase server APIs due to invalid configuration. update Firebase process and set valid options (API key, Project ID ..)

E/Firebase-Installations: Firebase Installations can not communicate with Firebase server APIs due to invalid configuration. Please update your Firebase initialization process and set valid Firebase options (API key, Project ID, Application ID) when initializing Firebase.
E/FirebaseMessaging: Failed to get FIS auth token
java.util.concurrent.ExecutionException: com.google.firebase.installations.FirebaseInstallationsException
at com.google.android.gms.tasks.Tasks.zza(com.google.android.gms:play-services-tasks##18.0.2:5)
at com.google.android.gms.tasks.Tasks.await(com.google.android.gms:play-services-tasks##18.0.2:8)
at com.google.firebase.messaging.GmsRpc.setDefaultAttributesToBundle(com.google.firebase:firebase-messaging##23.0.0:10)
at com.google.firebase.messaging.GmsRpc.startRpc(com.google.firebase:firebase-messaging##23.0.0:1)
at com.google.firebase.messaging.GmsRpc.getToken(com.google.firebase:firebase-messaging##23.0.0:1)
at com.google.firebase.messaging.FirebaseMessaging.lambda$blockingGetToken$9$com-google-firebase-messaging-FirebaseMessaging(com.google.firebase:firebase-messaging##23.0.0:1)
at com.google.firebase.messaging.FirebaseMessaging$$ExternalSyntheticLambda5.start(Unknown Source:6)
at com.google.firebase.messaging.RequestDeduplicator.getOrStartGetTokenRequest(com.google.firebase:firebase-messaging##23.0.0:6)
at com.google.firebase.messaging.FirebaseMessaging.blockingGetToken(com.google.firebase:firebase-messaging##23.0.0:7)
at com.google.firebase.messaging.SyncTask.maybeRefreshToken(com.google.firebase:firebase-messaging##23.0.0:1)
at com.google.firebase.messaging.SyncTask.run(com.google.firebase:firebase-messaging##23.0.0:10)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:463)
at java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:307)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
at com.google.android.gms.common.util.concurrent.zza.run(com.google.android.gms:play-services-basement##18.1.0:2)
at java.lang.Thread.run(Thread.java:1012)
Caused by: com.google.firebase.installations.FirebaseInstallationsException
at com.google.firebase.installations.FirebaseInstallations.doNetworkCallIfNecessary(FirebaseInstallations.java:417)
at com.google.firebase.installations.FirebaseInstallations.lambda$doRegistrationOrRefresh$3$com-google-firebase-installations-FirebaseInstallations(FirebaseInstallations.java:375)
at com.google.firebase.installations.FirebaseInstallations$$ExternalSyntheticLambda0.run(Unknown Source:4)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1137)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:637)
at java.lang.Thread.run(Thread.java:1012) 
I've cleared caches, changed API key from google cloud platform, updated google-services.json with latest keys. In main branch it didn't get this error but in specific branch. this issue comes.

React native video unable to play m3u8 file

Problem
I'm trying to stream a m3u8 file in a react native app (for android TV) and I'm getting this error:
LOG {"error": {"errorCode": "22004", "errorException": "com.google.android.exoplayer2.ExoPlaybackException: Source error", "errorStackTrace": "com.google.android.exoplayer2.ExoPlaybackException: Source error
at com.google.android.exoplayer2.ExoPlayerImplInternal.handleIoException(ExoPlayerImplInternal.java:632)
at com.google.android.exoplayer2.ExoPlayerImplInternal.handleMessage(ExoPlayerImplInternal.java:604)
at android.os.Handler.dispatchMessage(Handler.java:102)
at android.os.Looper.loop(Looper.java:223)
at android.os.HandlerThread.run(HandlerThread.java:67)
Caused by: com.google.android.exoplayer2.upstream.HttpDataSource$InvalidResponseCodeException: Response code: 403
at com.google.android.exoplayer2.ext.okhttp.OkHttpDataSource.open(OkHttpDataSource.java:329)
at com.google.android.exoplayer2.upstream.DefaultDataSource.open(DefaultDataSource.java:258)
at com.google.android.exoplayer2.upstream.StatsDataSource.open(StatsDataSource.java:84)
at com.google.android.exoplayer2.upstream.DataSourceInputStream.checkOpened(DataSourceInputStream.java:99)
at com.google.android.exoplayer2.upstream.DataSourceInputStream.open(DataSourceInputStream.java:62)
at com.google.android.exoplayer2.upstream.ParsingLoadable.load(ParsingLoadable.java:174)
at com.google.android.exoplayer2.upstream.Loader$LoadTask.run(Loader.java:412)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:923)
", "errorString": "ExoPlaybackException: ERROR_CODE_IO_BAD_HTTP_STATUS"}}
I don't know java so from the above traceback I'm guessing that the server is responding with an HTTP 403 and therefore it is unable to stream the file.
What I've tried
This one is not much of a solution but I tried switching to the react-native-video-player instead of react-native-video but that didn't work.
I tried passing the type: 'm3u8' and type: 'hls' inside the source attribute of the video tag along with the uri and this didn't help at all.
Tried to check if another m3u8 url (i.e. from another domain/server) is working, and it is working.
Downgrading react-native-video version, problem persists with different error message.
I decided to ssh into my android TV and directly use curl to fetch the m3u8 file and it responds with this:
curl: (60) SSL certificate problem: certificate has expired
More details here: https://curl.haxx.se/docs/sslcerts.html
curl failed to verify the legitimacy of the server and therefore could not
establish a secure connection to it. To learn more about this situation and
how to fix it, please visit the web page mentioned above.
Moreover, many of the issues I found on github having a similar problem contain a URL that gives the same response when fetched directly with curl. Interestingly, if I use the fetch API in JS to console log the response from the m3u8 url, it works perfectly. So I'm guessing the problem is somewhere in exoplayer.
Specs
react-native : 'npm:react-native-tvos#0.69.6-0'
react-native-video : '^6.0.0-alpha.3'
Android TV : Tested both on a Raspberry Pi running Android TV (LineageOS I think) and an actual android tv set top box with same results.
The issue was with the user-agent header, exoplayer was setting a user-agent which was causing an HTTP 403. I had to use a proxy to figure this out and still have no clue as per why android studio was not showing the request that had an error.

Error returned from API. code: 403 - Firebase App Check Android

Our app has Firebase app check, but some users have this error, and the app crashes
Thanks
Caused by com.google.firebase.FirebaseException: Error returned from API. code: 403 body: App attestation failed.
at com.google.firebase.appcheck.internal.NetworkClient.exchangeAttestationForAppCheckToken(NetworkClient.java:140)
at com.google.firebase.appcheck.safetynet.internal.SafetyNetAppCheckProvider.lambda$exchangeSafetyNetJwsResultForToken$1$SafetyNetAppCheckProvider(SafetyNetAppCheckProvider.java:178)
at com.google.firebase.appcheck.safetynet.internal.SafetyNetAppCheckProvider$$ExternalSyntheticLambda1.call(:4)
at com.google.android.gms.tasks.zzy.run(com.google.android.gms:play-services-tasks##17.1.0:2)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
at java.lang.Thread.run(Thread.java:919)

Google Drive upload error : "I/O error during system call, Software caused connection abort"

I have developed an Android application using which the user can upload large files (~1 to 2 GB in size) to his/her Google Drive account.
I am using the Google Drive Rest API for Android. Sometimes, the upload operation fails with following exception:
javax.net.ssl.SSLException: Read error: ssl=0xcfe9ee80: I/O error during system call, Software caused connection abort
at com.android.org.conscrypt.NativeCrypto.SSL_read(Native Method)
at com.android.org.conscrypt.OpenSSLSocketImpl$SSLInputStream.read(OpenSSLSocketImpl.java:758)
at com.android.okhttp.okio.Okio$2.read(Okio.java:141)
at com.android.okhttp.okio.AsyncTimeout$2.read(AsyncTimeout.java:211)
at com.android.okhttp.okio.RealBufferedSource.indexOf(RealBufferedSource.java:316)
at com.android.okhttp.okio.RealBufferedSource.indexOf(RealBufferedSource.java:310)
at com.android.okhttp.okio.RealBufferedSource.readUtf8LineStrict(RealBufferedSource.java:206)
at com.android.okhttp.internal.http.HttpConnection.readResponse(HttpConnection.java:239)
at com.android.okhttp.internal.http.HttpTransport.readResponseHeaders(HttpTransport.java:104)
at com.android.okhttp.internal.http.HttpEngine.readNetworkResponse(HttpEngine.java:1156)
at com.android.okhttp.internal.http.HttpEngine.readResponse(HttpEngine.java:976)
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.execute(HttpURLConnectionImpl.java:509)
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getResponse(HttpURLConnectionImpl.java:438)
at com.android.okhttp.internal.huc.HttpURLConnectionImpl.getResponseCode(HttpURLConnectionImpl.java:567)
at com.android.okhttp.internal.huc.DelegatingHttpsURLConnection.getResponseCode(DelegatingHttpsURLConnection.java:105)
at com.android.okhttp.internal.huc.HttpsURLConnectionImpl.getResponseCode(HttpsURLConnectionImpl.java)
at com.google.api.client.http.javanet.NetHttpResponse.<init>(NetHttpResponse.java:37)
at com.google.api.client.http.javanet.NetHttpRequest.execute(NetHttpRequest.java:94)
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:981)
at com.google.api.client.googleapis.media.MediaHttpUploader.executeCurrentRequestWithoutGZip(MediaHttpUploader.java:545)
at com.google.api.client.googleapis.media.MediaHttpUploader.resumableUpload(MediaHttpUploader.java:417)
at com.google.api.client.googleapis.media.MediaHttpUploader.upload(MediaHttpUploader.java:336)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:427)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:469)
I have following questions:
What are the reasons for such error?
Is this the issue related to network speed?
Is this is the problem with Google Drive API? If yes, how to avoid this error?
I testing the app with Android 7.0.
I would appreciate any suggestions and thoughts on this topic. Thank you.

APK upload from jenkins failed - language is not associated

I have a Jenkins job configured to upload APK to the Play Market. It produces an error log:
Assigning APK(s) to beta release track...
The beta release track will now contain the APK(s): 164
Applying changes to Google Play...
Upload failed: Tried to set recent changes text for APK version 164 for language de-DE.
Language is not associated with the app.
No changes have been applied to the Google Play account
ERROR: Step ‘Upload Android APK to Google Play’ failed: APK upload failed
Finished: FAILURE
How this could be fixed?
UPDATE: I've added DE to app's languages on Google Play (should this 'associate' language with the app???).
Now Jenkins job gives me this error:
Applying changes to Google Play...
Upload failed: org.jenkinsci.plugins.googleplayandroidpublisher.PublisherApiException: com.google.api.client.googleapis.json.GoogleJsonResponseException: 500 Internal Server Error
{
"code" : 500,
"message" : null
}
at org.jenkinsci.plugins.googleplayandroidpublisher.AbstractPublisherTask.call(AbstractPublisherTask.java:36)
at hudson.FilePath.act(FilePath.java:1083)
at org.jenkinsci.plugins.googleplayandroidpublisher.ApkPublisher.publishApk(ApkPublisher.java:313)
at org.jenkinsci.plugins.googleplayandroidpublisher.ApkPublisher.perform(ApkPublisher.java:183)
at hudson.tasks.BuildStepCompatibilityLayer.perform(BuildStepCompatibilityLayer.java:78)
at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20)
at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:779)
at hudson.model.AbstractBuild$AbstractBuildExecution.performAllBuildSteps(AbstractBuild.java:720)
at hudson.model.Build$BuildExecution.post2(Build.java:185)
at hudson.model.AbstractBuild$AbstractBuildExecution.post(AbstractBuild.java:665)
at hudson.model.Run.execute(Run.java:1753)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
at hudson.model.ResourceController.execute(ResourceController.java:98)
at hudson.model.Executor.run(Executor.java:404)
Caused by: com.google.api.client.googleapis.json.GoogleJsonResponseException: 500 Internal Server Error
{
"code" : 500,
"message" : null
}
at com.google.api.client.googleapis.json.GoogleJsonResponseException.from(GoogleJsonResponseException.java:145)
at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:113)
at com.google.api.client.googleapis.services.json.AbstractGoogleJsonClientRequest.newExceptionOnError(AbstractGoogleJsonClientRequest.java:40)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest$1.interceptResponse(AbstractGoogleClientRequest.java:312)
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:1049)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:410)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:343)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:460)
at org.jenkinsci.plugins.googleplayandroidpublisher.ApkUploadTask.execute(ApkUploadTask.java:146)
at org.jenkinsci.plugins.googleplayandroidpublisher.ApkUploadTask.execute(ApkUploadTask.java:35)
at org.jenkinsci.plugins.googleplayandroidpublisher.AbstractPublisherTask.call(AbstractPublisherTask.java:33)
... 13 more
- No changes have been applied to the Google Play account
ERROR: Step ‘Upload Android APK to Google Play’ failed: APK upload failed
Finished: FAILURE
What could help in this case?
Found that similar problem was reported here and here.
Some magic has happened and the error #500 has gone, apk is now accepted by the Google Play.

Categories

Resources