On 8/1/2016 2:56 AM, thufir wrote:
How can I configure fail2ban on a GCP instance?
The same way on any other system.
When I look at docs for Digital Ocean:
The maxretry variable sets the number of tries a client has to
authenticate within a window of time defined by findtime, before being
banned. With the default settings, the fail2ban service will ban a
client that unsuccessfully attempts to log in 3 times within a 10
minute window.
destemail = root@localhost
sendername = Fail2Ban
mta = sendmail
However, google blocks port 25:
https://cloud.google.com/compute/docs/tutorials/sending-mail/
You seem to be confusing blocking with sending an email. After a block
has occurred it can send an email notification.
In the Digital Ocean docs you posted it is sending to root@localhost,
and localhost = IP address 127.0.0.1, which is not going to be blocked.
However, if you wish to send to another host, or TLD just follow the
instructions on the link you posted:
"Although standard email ports are blocked, you can choose a
non-standard port to send email through. You can also take advantage of
the mail services offered by Compute Engine partners."
Seems like a chicken-or-the-egg problem.
How do others solve this?
thanks,
Thufir
||
------------------------------------------------------------------------------
_______________________________________________
Fail2ban-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fail2ban-users
------------------------------------------------------------------------------
_______________________________________________
Fail2ban-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fail2ban-users