At my organisation we’ve set up a linux server which runs one of our sites. It’s been working fine and I have been able to SSH through into it (using Terminal on OSX) no problem.
As of earlier when I tried to ssh root@123.123.123.123 (not my real IP) I was rejected with: ssh_exchange_identification: Connection closed by remote host
Having a look at the /etc/hosts.deny file I can see: sshd: 123.123.123.123 in the list.
This means the IP which I have been using for months no problem has suddenly appeared in the list. I removed it, and was able to SSH in fine, ONCE, then on my second try I was rejected and looking at the list again, I can see we have been added to the list once more!
I have added our IP to the hosts.allow file, but no luck – still no access.
Why do IP’s appear in the hosts.deny file?
How can I stop our IP appearing there?
As mentioned, probably a
fail2banor similar (look fordenyhoststoo – another popular).The usual fix is to append your IP address to /etc/hosts.allow
This works for denyhosts at least