ssh公钥验证的过程及遇到的问题
1.创建一对密钥;
2.将公钥复制并添加到~/.ssh/authorized_keys;
3.设定ssh客户端采用私钥进行登陆验证。
ssh公钥生效需满足的两个条件:
1) .ssh目录的权限必须是700
2) .ssh/authorized_keys文件权限必须是600
ssh的man page:
FILES
【ssh公钥验证的过程及遇到的问题】 ~/.ssh/
This directory is the default location for all user-specific configuration and authentication information. There is no general requirement to keep the entire contents of this directory secret,but the recommended permissions are read/write/execute for the user, and not accessible by others.
~/.ssh/authorized_keys
Lists the public keys (RSA/ECDSA/DSA) that can be used for logging in as this user. The format of this file is described in the sshd(8) manual page. This file is not highly sensitive, but the recommended permissions are read/write for the user, and not accessible by others.
转载于:https://www.cnblogs.com/freedom5wind/p/7470774.html
推荐阅读
- SSH|SSH 免密
- ssh生成公钥秘钥
- Pytorch学习|sklearn-SVM 模型保存、交叉验证与网格搜索
- 为Google|为Google Cloud配置深度学习环境(CUDA、cuDNN、Tensorflow2、VScode远程ssh等)
- 运维|如何限制IP 通过 SSH连接服务器
- 运维|Linux 禁止用户或 IP通过 SSH 登录
- 人工智能|【机器学习】深度盘点(详细介绍 Python 中的 7 种交叉验证方法!)
- 解决|解决 win 10 远程桌面身份验证错误问题
- macOS系统上,安装包安装权限不足或验证不过问题
- IC|数字IC后端真的不如前端设计和验证吗()