SSH 实用技巧与远程图形桌面应用指南
1. SSH 密钥相关操作
1.1 修改密钥密码
若要修改 SSH 密钥的密码,可使用 ssh-keygen 命令搭配 -p 开关:
$ ssh-keygen -p -f ~/.ssh/id_dsa
Enter old passphrase:
Key has comment '/home/pinball/.ssh/id_dsa'
Enter new passphrase (empty for no passphrase):
Enter same passphrase again:
Your identification has been saved with the new passphrase.
需注意,密码无法恢复,若丢失密码,只能创建新密钥并设置新密码。
1.2 获取密钥指纹
当发送公钥给其他用户,需对方验证密钥真实性时,可通过以下步骤获取密钥指纹:
[carla@windbag:~/.ssh]$ ssh-keygen -l
Enter file in which the key is (/home/carla/.ssh/id_rsa): id_mailserver
1024 ce:5e:38:ba:fb:ec:e7:80:83:3e:11:1a:6f:b1:97:8b id_mailserver.pub
在传输密钥指纹
超级会员免费看
订阅专栏 解锁全文
1372

被折叠的 条评论
为什么被折叠?



