Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Networking & Security
  • Search

Invalid/denied users are immediately rejected by sshd server

Having problems getting connected to the internet or running a server? Wondering about securing your box? Ask here.
Post Reply
Advanced search
2 posts • Page 1 of 1
Author
Message
fafner2000
n00b
n00b
Posts: 7
Joined: Sat Feb 16, 2013 1:47 pm

Invalid/denied users are immediately rejected by sshd server

  • Quote

Post by fafner2000 » Fri Feb 27, 2026 6:21 pm

I have a weird problem with a gentoo virtual machine that I just installed: if I try to login with an invalid or denied user, the sshd server will close the connection without authenticating. By comparison, a recent debian 13 trixie installation asks for authentication without outright closing the connection.
client shell:
$ ssh -l abcd 192.168.1.214
Connection closed by 192.168.1.214 port 22

server log:
Feb 15 16:15:14 baldur sshd-session[2201]: Invalid user abcd from 192.168.1.130 port 36434
Feb 15 16:15:14 baldur sshd-session[2201]: fatal: PAM user mismatch
client shell:
$ ssh -l my_denied_user 192.168.1.214
Connection closed by 192.168.1.214 port 22

server log:
Feb 15 16:16:49 baldur sshd-session[2396]: User my_denied_user from 192.168.1.130 not allowed because listed in DenyUsers
Feb 15 16:16:49 baldur sshd-session[2396]: fatal: PAM user mismatch
Is it considered normal behavior ? Personally I would consider that a security risk, as it will give a clue to attackers which users can actually login, instead of letting them hammering invalid users.
Top
NeddySeagoon
Administrator
Administrator
User avatar
Posts: 56094
Joined: Sat Jul 05, 2003 9:37 am
Location: 56N 3W

  • Quote

Post by NeddySeagoon » Fri Feb 27, 2026 6:40 pm

fafner2000,

I get the same behaviour now but I use keys for ssh, not username/password pairs.
I'm sure it used to do the password dance for any user, valid or not.
Regards,

NeddySeagoon

Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail.
Top
Post Reply

2 posts • Page 1 of 1

Return to “Networking & Security”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic