Cert Validation Path Error When Debugging In Android Studio
I just generated the sample app from https://flutter.dev/docs/get-started/codelab When i hit the debug button in Android Studio i get the following error: Exception in thread 'main
Solution 1:
The only workaround i found yet is to change the jcenter() in build.gradle to mavenCentral()
repositories {
mavenCentral()
google()
}
Solution 2:
First thing you need to know, Android Studio has its own jre.
so you need to add certificate to it.
- find your android studio path and jre/lib/security/cacerts.
in my case(windows) : C:\Program Files\Android\Android Studio\jre\jre\lib\security
- add certificate
keytool -import -alias mycertificate -keystore path_to_keystore -file android studio certificate_file
Solution 3:
I was getting same error while building flutter sample app.
It is a gradle sync issue. Just try Invalidate cache from studio settings and update distribution url in gradlewrraper.properties file and do resync.
Post a Comment for "Cert Validation Path Error When Debugging In Android Studio"