Git push keep getting permission denied after mac 10.9.2 update

ぃ、小莉子 提交于 2019-12-04 08:44:51

问题


Wondering if anyone experiencing the same issue with OSX 10.9.2 Update. After installing that update, I couldn't do git push anymore, keep getting permission denied(public key).

Have tried to generate a new ssh pair, and reenter the new key to server, but still no luck.

Also tried to do it on another git hosting after inserting a new key, still doesnt work. So I guess its not a server problem, but a OSX 10.9.2 issue.

Any suggestion would be appreciated.

Thanks!


回答1:


I ran into the same problem with the Mavericks 10.9.2 update. Anything using your ssh public key (ssh, git, svn, etc) will have a problem. It seems that the ssh agent somehow forgot about your key.

Running ssh-add from the terminal fixed it for me. From these sources:

https://help.github.com/articles/error-agent-admitted-failure-to-sign
http://www.cyberciti.biz/faq/unix-appleosx-linux-bsd-agent-admitted-failuretosignusingkey/

Cheers




回答2:


Add your ssh keys to your Keychain by running ssh-add -K ~/.ssh/<keyfile>.

You can use * as key file to add all keys. This will ask for a passphrase for files which are not private keys. Just press enter for those files.

This adds keychain entries even for non-encrypted keys, i.e. keys that don't require a passphrase. After that it is not required to add the keys to the ssh-agent. So you can remove all keys from the agent by running ssh-add -D and public key authentication still works.



来源:https://stackoverflow.com/questions/22085581/git-push-keep-getting-permission-denied-after-mac-10-9-2-update

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!