SSH and iptables



I am looking for iptables rules to do the following:

When an SSH connection attempt (at the standard port) from a given IP
address fails, no further SSH connections will be accepted from that IP
address for 60 seconds.

If, on the other hand, the connection attempt succeeds, then that IP
address is free to start as many (successful) SSH connections within the
next 60 seconds (and beyond, in fact).

Is this possible? I am aware of numerous iptables rules that can do
something similar. The catch is that they can't tell whether or not a
connection attempt was unsuccessful.


.



Relevant Pages

  • Re: SSH and iptables
    ... When an SSH connection attempt (at the standard port) from a given IP ... address fails, no further SSH connections will be accepted from that IP ... I'm not taking into account the possible cpu overhead related ...
    (comp.os.linux.networking)
  • Re: IOSTAT=127
    ... Just the opposite. ... while logged in via ssh connections from other computers. ... and it fails for him. ... allow User C to write to Disk B, and Program D allows User C to write ...
    (comp.lang.fortran)
  • Re: SSH and iptables
    ... Steven Jones wrote: ... address fails, no further SSH connections will be accepted from that IP ... which the authentification fails 3 times within 10 minutes for another ...
    (comp.os.linux.networking)
  • Re: SSH and iptables
    ... address fails, no further SSH connections will be accepted from that IP ... I am aware of numerous iptables rules that can do ... Are these rules able to tell between successful and nonsuccessful ...
    (comp.os.linux.networking)