使用ssh,ssh查看~/.ssh/known_hosts密钥信息

・1 分钟阅读

查看~/.ssh/known_hosts密钥信息

ssh-keygen -l -f ~/.ssh/known_hosts
将返回~/.ssh/known_hosts文件中每个主机的SSH服务器密钥信息,包括密钥大小,密钥指纹,密钥IP地址或域名以及密钥类型,
示例输出
2048 33:3c:db:04:96:f8:c0:dc:3b:c5:eb:8a:29:32:90:74 10.5.20.213 (RSA)
2048 1f:5c:f1:0f:6a:77:b8:ab:22:13:6f:9f:4e:16:1f:b9 10.5.20.214 (RSA)
2048 3a:01:a8:a1:23:cd:73:0d:7e:1e:bf:70:da:a0:e9:ab 10.5.20.212 (RSA)
2048 16:7a:81:3a:96:6a:65:a5:b6:37:15:35:c0:09:56:e4 10.5.20.216 (RSA)
2048 a1:5b:b8:10:86:4b:6f:5d:d8:77:d3:da:a0:ce:0d:3f 10.5.20.217 (RSA)
2048 0e:4d:d6:09:95:97:29:94:9f:59:78:e8:59:65:83:60 10.5.20.219 (RSA)
2048 d9:fc:1d:46:63:57:f7:07:54:23:bf:88:af:3a:4a:71 10.5.20.215 (RSA)
2048 7b:81:21:60:27:63:a4:38:34:42:08:22:70:16:19:70 10.5.20.218 (RSA)
Hujiuxiang profile image