xshell连接需要公钥【已解决】

这是一个小问题,但是不得其门而入就会很累。
解决连接问题 首先要想到的是/etc/ssh/sshd_config目录;
至于免密互连则是 ~/.ssh目录
在这里插入图片描述
我解决就是将其他机器的/etc/ssh/sshd_config的sshd_config给copy过来了

具体配置文件如下
·
1 HostKey /etc/ssh/ssh_host_rsa_key
2 #HostKey /etc/ssh/ssh_host_dsa_key
3 HostKey /etc/ssh/ssh_host_ecdsa_key
4 HostKey /etc/ssh/ssh_host_ed25519_key
6 SyslogFacility AUTHPRIV
7 # but this is overridden so installations will only check .ssh/authorized_keys
8 AuthorizedKeysFile .ssh/authorized_keys
9 #PermitEmptyPasswords no
10 PasswordAuthentication yes
11 #ChallengeResponseAuthentication yes
12 ChallengeResponseAuthentication no
13 # GSSAPI options
14 GSSAPIAuthentication yes
15 GSSAPICleanupCredentials no
16 # problems.
17 UsePAM yes
18 #GatewayPorts no
19 X11Forwarding yes
20 #ShowPatchLevel no
21 UseDNS no
22 #Banner none
23 RSAAuthentication yes
24 PubkeyAuthentication no
25 # Accept locale-related environment variables
26 AcceptEnv LANG LC_CTYPE LC_NUMERIC LC_TIME LC_COLLATE LC_MONETARY LC_MESSAGES
27 AcceptEnv LC_PAPER LC_NAME LC_ADDRESS LC_TELEPHONE LC_MEASUREMENT
28 AcceptEnv LC_IDENTIFICATION LC_ALL LANGUAGE
29 AcceptEnv XMODIFIERS
30 # override default of no subsystems

猜你喜欢

转载自blog.csdn.net/weixin_42644102/article/details/85256975
今日推荐