Home > Blockchain >  Android studio SSL certificate problem: unable to get local issuer certificate (LONGTERM SOLUTION)
Android studio SSL certificate problem: unable to get local issuer certificate (LONGTERM SOLUTION)

Time:01-29

I know this is known issue. I am trying to do the git pull in my android studio with current project and I get this warning. So I generated my key on macbook with command:

ssh-keygen -t rsa

than I copy it and added to bitbucket profile in ssh keys. Also I added certificate to the android studio settings (tools -> server certificates).

Still I get this issue. I tried with changing git.config but also without success.

with command:

git config --global http.sslVerify false

it works well, but I don't want solutions like this since it is bad and not secure. Does anyone has any good suggestion. Thanks!

CodePudding user response:

After long time spent I found the solution. This can be very helpful so try it out if you have same problem.

Situation was that in my android studio I added HTTPS URL (e.g., https://bitbucket.org/username/repo.git) instead of SSH URL (e.g., [email protected]:username/repo.git). You can change this in Git -> Manage remotes. Copy the SSH URL from bitbucket (or any other VCS by clicking on clone option and selecting ssh instead of https)

So Even though everything is set up well, SSL protocol (used to transfer securely data) is unable to connect (in these situations SSH protocol is used. It allows executing commands, not only sending data like SSL. It is usually used for log in situations like this)

Hope this helps, have a good day coding.

  • Related