【备忘录】配置ssh公钥登录

cat idrsa.pub >> ~/.ssh/authorized_keys
vim /etc/ssh/sshd_config
service sshd restart

config:

RSAAuthentication yes
PubkeyAuthentication yes

PermitRootLogin yes  #root 用户能否通过 SSH 登录
PasswordAuthentication no  #禁用密码登录
posted @ 2024-10-19 20:22  oblivionl  阅读(4)  评论(0编辑  收藏  举报