首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >SSH看上去连接,但密码提示没有来

问SSH看上去连接,但密码提示没有来
EN

Server Fault用户
提问于 2021-08-23 09:33:40
回答 1查看 2K关注 0票数 1

当SSH客户端尝试连接CentOS 7时,openssh服务器等待密码提示,但从未出现。调试时,连接日志和netstat显示已建立的连接。

下面是我的客户端调试:

代码语言:javascript
复制
tevfik@Darktower:~$ ssh -vvv root@10.40.4.19
OpenSSH_8.2p1 Ubuntu-4ubuntu0.3, OpenSSL 1.1.1f  31 Mar 2020
debug1: Reading configuration data /etc/ssh/ssh_config
debug1: /etc/ssh/ssh_config line 19: include /etc/ssh/ssh_config.d/*.conf matched no files
debug1: /etc/ssh/ssh_config line 21: Applying options for *
debug3: kex names ok: [diffie-hellman-group1-sha1,curve25519-sha256@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha1]
debug2: resolve_canonicalize: hostname 10.40.4.19 is address
debug2: ssh_connect_direct
debug1: Connecting to 10.40.4.19 [10.40.4.19] port 22.
debug1: Connection established.
debug1: identity file /home/tevfik/.ssh/id_rsa type -1
debug1: identity file /home/tevfik/.ssh/id_rsa-cert type -1
debug1: identity file /home/tevfik/.ssh/id_dsa type -1
debug1: identity file /home/tevfik/.ssh/id_dsa-cert type -1
debug1: identity file /home/tevfik/.ssh/id_ecdsa type -1
debug1: identity file /home/tevfik/.ssh/id_ecdsa-cert type -1
debug1: identity file /home/tevfik/.ssh/id_ecdsa_sk type -1
debug1: identity file /home/tevfik/.ssh/id_ecdsa_sk-cert type -1
debug1: identity file /home/tevfik/.ssh/id_ed25519 type -1
debug1: identity file /home/tevfik/.ssh/id_ed25519-cert type -1
debug1: identity file /home/tevfik/.ssh/id_ed25519_sk type -1
debug1: identity file /home/tevfik/.ssh/id_ed25519_sk-cert type -1
debug1: identity file /home/tevfik/.ssh/id_xmss type -1
debug1: identity file /home/tevfik/.ssh/id_xmss-cert type -1
debug1: Local version string SSH-2.0-OpenSSH_8.2p1 Ubuntu-4ubuntu0.3

下面是ssh服务器端netstat输出.

你知不知道?致以敬意,

EN

回答 1

Server Fault用户

回答已采纳

发布于 2021-08-23 10:47:28

如果您可以本地访问服务器端,则可以在服务器上停止sshd服务,然后以详细模式运行sshd服务,以查看在login.For上发生了什么,sshd服务的详细模式(调试模式)是-d或接近-ddd。

https://linux.die.net/man/8/sshd

https://unix.stackexchange.com/a/55481

另一件要检查的事情是,服务器被配置为允许密码ssh访问。这是PasswordAuthentication文件中的sshd_config选项。

https://linux.die.net/man/5/sshd_配置

检查安全日志和auth日志中的auth问题:

https://superuser.com/a/1293901/1178349

检查SELinux问题:

https://www.serverlab.ca/tutorials/linux/administration-linux/troubleshooting-selinux-centos-red-hat/

票数 3
EN
页面原文内容由Server Fault提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://serverfault.com/questions/1075376

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档