Commit c12af940 authored by latham's avatar latham
Browse files

Fail2ban config start: Then the egg

parent 5eb43f4a
...@@ -105,6 +105,10 @@ class installer extends installer_base { ...@@ -105,6 +105,10 @@ class installer extends installer_base {
parent::configure_apache(); parent::configure_apache();
} }
public function configure_fail2ban() {
copy('tpl/dovecot-pop3imap.conf.master',"/etc/fail2ban/filter.d/dovecot-pop3imap.conf");
copy('tpl/dovecot_fail2ban_jail.local.master','/etc/fail2ban/jail.local');
}
} }
?> ?>
\ No newline at end of file
...@@ -200,7 +200,6 @@ if($install_mode == 'standard') { ...@@ -200,7 +200,6 @@ if($install_mode == 'standard') {
swriteln('Configuring Getmail'); swriteln('Configuring Getmail');
$inst->configure_getmail(); $inst->configure_getmail();
//* Configure Pureftpd //* Configure Pureftpd
swriteln('Configuring Pureftpd'); swriteln('Configuring Pureftpd');
$inst->configure_pureftpd(); $inst->configure_pureftpd();
...@@ -244,6 +243,11 @@ if($install_mode == 'standard') { ...@@ -244,6 +243,11 @@ if($install_mode == 'standard') {
swriteln('Configuring Ubuntu Firewall'); swriteln('Configuring Ubuntu Firewall');
$inst->configure_ufw_firewall(); $inst->configure_ufw_firewall();
} }
//* Configure Fail2ban
if($conf['fail2ban']['installed'] == true) {
swriteln('Configuring Fail2ban');
$inst->configure_fail2ban();
if($conf['squid']['installed'] == true) { if($conf['squid']['installed'] == true) {
$conf['services']['proxy'] = true; $conf['services']['proxy'] = true;
...@@ -544,4 +548,4 @@ if($install_mode == 'standard') { ...@@ -544,4 +548,4 @@ if($install_mode == 'standard') {
echo "Installation completed.\n"; echo "Installation completed.\n";
?> ?>
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment