Raulp
Raulp

Reputation: 8136

Android Studio : Error:Cause: unable to find valid certification path to requested target

Where to get more information about this error in Android Studio

Error:Cause: unable to find valid certification path to requested target

I dont know from where it is coming and what to look for?

Below is the snippet from my Build.gradle.

buildscript {
    repositories {
        jcenter() {
            url "http://jcenter.bintray.com/"

        }
      //  mavenCentral()
        maven { url 'https://maven.fabric.io/public' }
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.2.2'
        classpath 'io.fabric.tools:gradle:1.+'
    }
}

allprojects {
    repositories {
        jcenter() {
            url "http://jcenter.bintray.com/"
        }
      //  mavenCentral()
        maven { url 'https://maven.fabric.io/public' }
    }
}

apply plugin: 'com.android.application'
apply plugin: 'io.fabric'

repositories {
    jcenter() {
        url "http://jcenter.bintray.com/"

    }
    maven { url 'https://maven.fabric.io/public' }  }

Upvotes: 7

Views: 9867

Answers (3)

mostafa ahmed
mostafa ahmed

Reputation: 11

Check your internet connection. This happened to me when I was connected to a corporate restricted internet.

Connect to a non-restricted internet solved my problem.

Upvotes: 1

Abdul Rafay
Abdul Rafay

Reputation: 276

I hope resolved that issue, may be my answer will help others. This issue i faced because of Charles proxy, so the solution is just close the charles proxy tool and Android Studio also, then first open Android Studio it will work fine.

Upvotes: 1

Ivor
Ivor

Reputation: 578

The only way I got this running is going to letsencrypt generate my certificate and then set it up in the server from where the repo is consume, but for I see there just add Https in all of them as is a known repo/s, if you're behind a proxy use a vpn to connect to internet so you are directly passing through the proxy and will work

Upvotes: 0

Related Questions