1
0
mirror of https://github.com/pavel-odintsov/fastnetmon synced 2024-11-23 09:12:14 +01:00

Unified ExaBGP ban logic to ban for ban and unban

This commit is contained in:
Pavel Odintsov 2023-07-09 15:08:21 +01:00
parent fc77d5351d
commit 4f5523ab7e

@ -1513,15 +1513,13 @@ void call_blackhole_actions_per_host(
}
if (attack_action == attack_action_t::ban) {
if (exabgp_enabled && ipv4) {
logger << log4cpp::Priority::INFO << "Call ExaBGP for ban client started: " << client_ip_as_string;
if (exabgp_enabled && ipv4) {
logger << log4cpp::Priority::INFO << "Call ExaBGP for " << action_name << " client started: " << client_ip_as_string;
boost::thread exabgp_thread(exabgp_ban_manage, "ban", client_ip_as_string, current_attack);
exabgp_thread.detach();
boost::thread exabgp_thread(exabgp_ban_manage, action_name, client_ip_as_string, current_attack);
exabgp_thread.detach();
logger << log4cpp::Priority::INFO << "Call to ExaBGP for ban client is finished: " << client_ip_as_string;
}
logger << log4cpp::Priority::INFO << "Call to ExaBGP for " << action_name << "client is finished: " << client_ip_as_string;
}
if (attack_action == attack_action_t::ban) {