I am trying to unblock an IP from which I was doing some tests. I have followed the tutorials on the net:
$ sudo /etc/init.d/denyhosts stop
$ sudo vim /etc/deny.hosts
[remove the last line where I can see my IP to clear]
$ cd /var/lib/denyhosts/
$ sudo vim *
[remove any occurences of my IP to clear]
$ sudo /etc/init.d/denyhosts start
At this moment my IP appears back into /etc/deny.hosts. I tried also:
$ cd /var/lib/denyhosts/
$ echo '123.456.789.122' >> /var/lib/denyhosts/allowed-hosts
I also tried:
$ echo 'my.ip.to.clear' >> /etc/hosts.allow
Unfortunately the hosts.deny always takes precedence, and refuse ssh connection, as can be seen from the log file:
Feb 10 10:06:24 ks123456 sshd[22875]: refused connect from 123.456.789.122 (123.456.789.122)
ref: debian/6.0.4, denyhosts 2.6-10