Hardening SSH login in apex #217
@ -57,6 +57,18 @@
|
||||
};
|
||||
};
|
||||
|
||||
services.fail2ban = {
|
||||
enable = true;
|
||||
maxretry = 5;
|
||||
bantime-increment = {
|
||||
enable = true; # Double ban time on each attack
|
||||
maxtime = "7d"; # Ban up to a week
|
||||
};
|
||||
};
|
||||
|
||||
# Disable SSH login with password, allow only keypair
|
||||
services.openssh.settings.PasswordAuthentication = false;
|
||||
|
||||
networking.firewall = {
|
||||
extraCommands = ''
|
||||
# Blackhole BSC vulnerability scanner (OpenVAS) as it is spamming our
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user