admin管理员组

文章数量:1615372

mac系统出了新版本 13.0.1 后,androidstudio push, pull 代码一直报错:

如下:

Permission denied (publickey).

fatal: Could not read from remote repository.

Please make sure you have the correct access rights

and the repository exists.

经过几翻操作,重新生成id_rsa.pub 也是不行,

最后发现是rsa加密方式的问题,苹果mac升级系统后,默认不支持rsa方式加密git通讯,

所以如果要继续使用这个pub文件加密的方式,则要手动添加cofig配置文件来支持:

如下在 ~/.ssh/ 目录下新增config文件,

然后在 ~/.ssh/config 中新增:

Host *
    PubkeyAcceptedKeyTypes +ssh-rsa
    HostKeyAlgorithms +ssh-rsa

 

 

本文标签: 报错代码系统电脑Mac