Help me - I am locked out of SSH because of DenyHosts
Hi,
I got locked out of my own server because (I think) I tried to login with wrong username/password too many times. I have file access through the control panel to the server but /etc/denyhosts.conf is locked down for some reason. Where does DenyHosts keep its blacklist file, maybe I can delete that manually? Any ideas? Thanks |
probably in ~/.ssh/known_hosts - check /etc/ssh/ssh_config and /etc/ssh/sshd_config to verify.
|
Quote:
Here's a copy of my file /etc/ssh/sshd_config file: Code:
# Package generated configuration file |
Assuming you have a normal user on your box, add that user to the last line of your sshd.conf. Not sure if you have to read sshd to make it take effect but I think you have to. Next try to login.
I guess that this is an internet facing box in which case it's not really advisable (put it politely) to have permitrootlogin set to yes and add root to allowusers. Once you're in fix that as the root account is what one usually tries to hack. Login as normal user and su to root when you have to. |
Quote:
This may be within the denyhosts.conf file itself. I'd check but I'm at work and can't log into my machine at the moment. |
Quote:
Checking my box, I've a file called allowed-hosts. I've added IPs to this file so that I don't end up blocking myself. Try that. |
DenyHosts is much like an IP based limitation.
If I'm right, you could have a try from another network to bypass the IP based ACL. |
All times are GMT -5. The time now is 12:02 PM. |