Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android SDK installation issue - Peer not authenticated

I am trying to install the Android SDK and I get the following error in the SDK Manager Logs -

Fetching https://dl-ssl.google.com/android/repository/addons_list-1.xml Failed to fetch URL https://dl-ssl.google.com/android/repository/addons_list-1.xml, reason: peer not authenticated Fetched Add-ons List successfully Fetching URL: https://dl-ssl.google.com/android/repository/repository-5.xml Failed to fetch URL https://dl-ssl.google.com/android/repository/repository-5.xml, reason: peer not authenticated Done loading packages. 

The error has something to do with proxy settings etc. I am running Ubuntu 11.10 and I had installed the SDK comfortably on the same setup yesterday.

like image 507
Vikesh Avatar asked Jan 25 '12 21:01

Vikesh


People also ask

How do I fix Android SDK not found?

The Cause for this error -SDK tools package might not be installed. Quick fix: Go to the Tools –> SDK manager –> SDK tools. Deselect Hide obsolete packages option on the right bottom and further install Android SDK Tools(obsolete). A new folder named Tools is now generated in the SDK directory.

How do I fix Android SDK file not found ADB?

To solve this Error:Make sure you have installed "Android SDK Platform-Tools". When you install "Android SDK Platform-Tools", it will fix Android SDK file not found: adb error.

How do I reinstall Android SDK?

Install the SDKClick Tools > SDK Manager. In the SDK Platforms tab, select Android 12. In the SDK Tools tab, select Android SDK Build-Tools 31. Click OK to install the SDK.

Do I need to install Android SDK separately?

Installing the Android SDK (Manual Way) You will need to download the Android SDK without Android Studio bundled. Go to Android SDK and navigate to the SDK Tools Only section. Copy the URL for the download that's appropriate for your build machine OS.


2 Answers

As a workaround, I enabled the "Force https://... sources to be fetched using http://..." setting in the SDK Manager Tools > Options menu.

If you use Android Studio instead of the standalone SDK Manager, Choose "SDK Update Sites" in the "Android SDK" settings and click the checkbox in the lower part of the screen.

That seems to help. I suspect it is a server side problem, but I'm not sure about that.

Edit: Please note that using http instead of https is not really the best idea! In the worst case, a man-in-the-middle attack could inject malicious code into your Android SDK libraries that ends up in your APK. That's why it's called a workaround :)

like image 120
Danilo Bargen Avatar answered Sep 22 '22 13:09

Danilo Bargen


In my particular case, I had the "Peer not authenticated" error on my android device as the system time on my device was set in the past, no issues with your system time?

Thanks to this page for pointing out the seemingly obvious... :)

like image 23
mlo55 Avatar answered Sep 19 '22 13:09

mlo55