Script to increase the limit of login failure block
Script to increase the limit of login failure block
Take a copy of csf.conf before editing.
cp -r /etc/csf/csf.conf /etc/csf/csf.conf _bak
Run the following commands.
sed -i 's/LF_SSHD = "5"/LF_SSHD = "30"/' /etc/csf/csf.conf sed -i 's/LF_FTPD = "10"/LF_FTPD = "30"/' /etc/csf/csf.conf sed -i 's/LF_SMTPAUTH = "5"/LF_SMTPAUTH = "30"/' /etc/csf/csf.conf sed -i 's/LF_POP3D = "10"/LF_POP3D = "30"/' /etc/csf/csf.conf sed -i 's/LF_IMAPD = "10"/LF_IMAPD = "30"/' /etc/csf/csf.conf sed -i 's/LF_HTACCESS = "5"/LF_HTACCESS = "30"/' /etc/csf/csf.conf sed -i 's/LF_CPANEL = "5"/LF_CPANEL = "30"/' /etc/csf/csf.conf sed -i 's/LF_MODSEC = "5"/LF_MODSEC = "30"/' /etc/csf/csf.conf
Restart the csf/Lfd
/etc/init.d/lfd restart csf -r
That’s all……… 🙂