2014-10-05 564 views
0

无法检查我的服务器RSA指纹。我究竟做错了什么?/etc/ssh/ssh_host_rsa_key.pub不是公钥文件

$ ls /etc/ssh 
moduli  ssh_host_dsa_key ssh_host_key.pub 
ssh_config ssh_host_dsa_key.pub ssh_host_rsa_key 
sshd_config ssh_host_key ssh_host_rsa_key.pub 
$ ssh-keygen -lf /etc/ssh/ssh_host_rsa_key.pub 
/etc/ssh/ssh_host_rsa_key.pub is not a public key file. 
$ ssh-keygen -lf /etc/ssh/ssh_host_rsa_key 
/etc/ssh/ssh_host_rsa_key is not a public key file. 

回答

0

这是一个文件权限问题。

$ cat /etc/ssh/ssh_host_rsa_key.pub 
/etc/ssh/ssh_host_rsa_key.pub: Permission denied