ssh证书登录错误

Fri 10 August 2012

错误描述

使用证书ssh链接的时候提示下面错误信息

Permission denied (publickey,gssapi-keyex,gssapi-with-mic,password). 可能原因

authorizedkeys 或.ssh的权限太open .ssh 目录改成755 权限 authorizedkeys 改成600

解决

查看日志: cat /var/log/secure 发现 Aug 8 17:15:13 CentOS62 sshd[5624]: Authentication refused: bad ownership or modes for file /home/abc/.ssh/authorized_keys 查看.ssh权限为775 .ssh 手动创建的时候是775权限,改成755权限后正常 # chmod 755 ~/.ssh

Category: Linux Tagged: 证书 权限 ssh authorized_keys

Comments

Fork me on GitHub