Azurel
Silver Pleskian
It is possible to add client-ip to fail2ban per plesk-php? My php script detects unqiue attacks and I would wish to add instantly the client-ip to a fail2ban jail. The same for banned users that create a account again and again.
on command-line for fail2ban
I found ip_ban: IP Address Banning (Fail2Ban) but actual this not support add a banip.
I have tested this, but I get no results, because my vhost-user is not in sudoers
The vhost-user should not get generally access to sudo. He should only get access to fail2ban.
on command-line for fail2ban
Is this working fine with plesk extension of fail2ban?# fail2ban-client set <JAIL> banip <IP>
# fail2ban-client set <JAIL> unbanip <IP>
# fail2ban-client status <JAIL>
I found ip_ban: IP Address Banning (Fail2Ban) but actual this not support add a banip.
I have tested this, but I get no results, because my vhost-user is not in sudoers
Code:
$exec = exec('sudo -u root -S fail2ban-client status recidive < /etc/psa/.psa.shadow', $output, $return);
Last edited: