美文网首页
Permissions 0644 for '/home/

Permissions 0644 for '/home/

作者: 文曜繁星 | 来源:发表于2017-11-27 13:37 被阅读18次

    拷贝本机的id_rsa文件到服务器执行 git clone命令的时候出现以下的异常

    Permissions 0644 for '/home/admin/.ssh/id_rsa' are too open.
    It is recommended that your private key files are NOT accessible by others.
    This private key will be ignored.
    bad permissions: ignore key: /home/admin/.ssh/id_rsa
    Enter passphrase for key '/home/admin/.ssh/id_rsa':
    Permission denied (publickey).
    fatal: Could not read from remote repository.
    
    

    出现以上的错误,需要将私钥的权限降级到0600,执行以下命令即可。

    chmod 0600 id_rsa
    

    参考资料:ssh-keygen 密钥

    相关文章

      网友评论

          本文标题:Permissions 0644 for '/home/

          本文链接:https://www.haomeiwen.com/subject/xetdbxtx.html