I recently set up a new CentOS 5 server, which has OpenSSH installed by default.

When I connect with PuTTY, the SSH server tells me "access denied" before prompting me for a password. Once I provide the password I log in to my shell fine. It never used to work seemingly out of order like that before, and there's nothing strange in the security log when I log in, just a successful login.

login as: admin
Access denied
admin@gold's password:
Last login: Sun Jul 17 00:26:50 2011 from pool-xxx-xx-xxx-xx.phlapa.fios.verizon.net

I made one change in the default config to change PermitRootLogin to no.

I also upgraded PuTTY to the latest version on the same day as setting up the server, though that's probably unrelated.

link|improve this question
look at/post the output of ssh -v your-server and tail -f /var/log/secure – Lmwangi Jul 17 '11 at 5:29
feedback

4 Answers

up vote 4 down vote accepted

Uncheck "Attempt GSSAPI authentication (SSH-2 only)" under SSH -> Auth -> GSSAPI.

link|improve this answer
feedback

Is it possible that it's trying some other authentication method, such as public-key, before falling back to password? I'm wondering if maybe your permissions on ~/.ssh/ (and the usual files inside there) are wrong on either the client or the server end. Maybe it's saying "access denied" because it wasn't allowed to read your id_rsa.pub on the server side, or your id_rsa on the client side.

link|improve this answer
feedback

I bet on a PAM module. Which modules are in the ssh auth chain?

link|improve this answer
feedback

In putty UNCHECK Attempt Auth Using Pageant in your connection.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.