Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Error When Clone/Push Git Repos 443: Bad access, but no proxy used

I am having really strange issue when do these operations clone/push with git remote repo.

Let's say I'm trying to push my changes to remote repo.

git push origin master

Then I will get this error.

fatal: unable to access '[Remote_Repo]': Failed to connect to github.com port 443: Bad access

I checked this issue and everyone saying this related to proxy. But I am quiet sure that I am not using a proxy.

like image 701
Rukshan Dangalla Avatar asked Mar 09 '23 20:03

Rukshan Dangalla


2 Answers

Here what happened. Kaspersky internet security blocked the connection to the git server and that's why I got that error.

So anyone facing the similer kind of issue, try disabling your anti virus first.

like image 196
Rukshan Dangalla Avatar answered Apr 07 '23 13:04

Rukshan Dangalla


It depends on the nature of the remote server (here github.com)

That could simply means an issue on the remote server side (even though there is no recent alert).
Locally, it could be a firewall issue or an host of other causes (make sure your Windows is up-to-date with the latest patches

As the OP Rukshan Dangalla confirms in the comments, the anti-virus (Kaspersky internet security) was blocking 443.
You can see an example of such an interference in this issue, where it seems like the antivirus interferes with connection attempts, leading git to think connections were unsuccessful.
Adding git to a whitelist in the AV can be a good workaround.
(Do not disable the AV!)


Also check from the command-line if you have a credential helper (which might have cached the wrong credentials)

git config -l|grep credential

See "How to sign out in Git Bash console in Windows?": That is Git for Windows using the latest Microsoft Git Credential Manager for Windows.

From the discussion:

I tried the cloning in another machine which connected to same network and it worked. Issue is in my machine :(


As a last resort, You can also try and use an ssh url (if you have registered a public key on the server side)

git remote set-url origin [email protected]:<username>/<reponame>
like image 38
VonC Avatar answered Apr 07 '23 15:04

VonC