ansible/ansible — pull request #7967 by urbaniak (2014-06-27 23:31:23+00:00)
Title: Add port knocking

Hi,

I'm using port knocking which opens ssh port, to avoid some garbage in logs and "protect" from some bots trying to access ssh.

It's done by those simple iptables rules:
```
iptables -A INPUT -p tcp -m state --state NEW -m tcp --dport 22 -m recent --update --seconds 300 --name SSH --rsource -j ACCEPT
iptables -I INPUT -p tcp -m state --state NEW -m tcp --dport 1234 -m recent --remove --name SSH --rsource
iptables -I INPUT -p tcp -m state --state NEW -m tcp --dport 1235 -m recent --set --name SSH --rsource
iptables -I INPUT -p tcp -m state --state NEW -m tcp --dport 1236 -m recent --remove --name SSH --rsource
```
It will be quite good to have a variable which defines a port on which ansible will "knock" before trying to ssh there.