Threat Detection позволяет "мониторить вторжения" и информирует Администратора о возможных атаках.
Threat Detection не является заменой IDS/IPS, и используется в случае недоступности функций IDS/IPS.
Существуют следующие компоненты Threat Detection:
Basic Threat Detection имеет чисто информационный характер, и не выполняет каких-то действий для предотвращения атак.
Basic Threat Detection заключается в общем мониторинге dropped packets для следующих events:
Packes denied by Access Lists (ACL Drop).
Bad packet format (such as invalid-ip-header or invalid-tcp-hdr-length).
Connection limits exceeded (both system-wide resource limits, and limits set in theconfiguration).
DoS attack detected (such as an invalid SPI, Stateful Firewall check failure).
Basic firewall checks failed (This option is a combined rate that includes all firewallrelated packet drops in this bulleted list. It does not include non-firewall-related drops such as interface overload, packets failed at application inspection, and scanning attack detected.)
Suspicious ICMP packets detected.
Packets failed application inspection.
Interface overload.
Scanning attack detected (This option monitors scanning attacks; for example, the first TCP packet is not a SYN packet, or the TCP connection failed the 3-way handshake. Full scanning threat detection takes this scanning attack rate information and acts on it by classifying hosts as attackers and automatically shunning them, for example.)
SYN Attack Detection. Incomplete session detection such as TCP SYN attack detected or no data UDP session attack detected.
Как работает Threat Detection.
Average Rate Interval (ARI) - это интервал времени, в котором измеряются количество Packet Drop.
Если в интервале ARI количество Packet Drop превышает заданный уровень threshold, ASA считает что произошел threat, - и генерит в лог system log message (733100).
Basic threat detection включает два threshold, которые можно настраивать:
Basic Threat Detection включена по умолчанию.
Вручную включить можно командой:
threat-detection basic-threat
Либо через ASDM: Configuration>Firewall>Threat Detection
Просмотр статистики:
show threat-detection rate Average(eps) Current(eps) Trigger Total events 10-min ACL drop: 2 0 0 1334 1-hour ACL drop: 0 2 0 2017 10-min SYN attck: 0 0 0 267 1-hour SYN attck: 0 0 0 699 10-min Scanning: 3 1 4 1926 1-hour Scanning: 1 3 0 3726 10-min Bad pkts: 0 0 0 18 1-hour Bad pkts: 0 0 0 65 10-min Firewall: 2 1 0 1659 1-hour Firewall: 0 2 0 3027 10-min DoS attck: 0 0 0 307 1-hour DoS attck: 0 0 0 945 10-min Interface: 2 0 0 1720 1-hour Interface: 1 1 0 3671
Здесь нас больше всего интересует столбец Trigger: в данном примере было обнаружено 4 атаки типа Scanning.
Посмотреть установки Basic Threat Detection events:
show running-config all threat-detection
Установки можно поменять.
Advanced threat detection - это также лишь статистика, но более подробная.
Advanced Threat Detection позволяет определить traffic rates для hosts, ports, protocols, ACLs.
Advanced threat detection может перегрузить ресурсы системы!!!
Включение:
Здесь number-of-rate означает количество отслеживаемых rate intervals. Доступно 1-3 и чем больше, тем больше необходимо ресурсов.
1-отслеживается за 1 hour.
2-отслеживается за 1 hour, 8 hours.
3-отслеживается за 1 hour, 8 hours, and 24 hours.
threat-detection statistics port number-of-rate 1 threat-detection statistics protocol number-of-rate 1 threat-detection statistics host number-of-rate 1 threat-detection statistics access-list threat-detection statistics tcp-intercept hpm topN enable
Scanning Threat Detection способна также и блокировать attacker.
Scanning Threat Detection может перегрузить ресурсы системы!!!
Конфигурация:
threat-detection scanning-threat shun threat-detection scanning-threat shun duration 3600 threat-detection scanning-threat shun except ip-address 10.1.1.1 255.255.255.0
Проверка:
show threat-detection shun
show threat-detection scanning-threat
В случае подозрения что у нас какие-то проблемы, первое что следует сделать - открыть ASDM, и посмотреть Firewall Dashboard.
Ниже приведён пример реакции ASA на сканирование извне через nmap. Поскольку при сканировании перебираются порты, мы получим массу ACL Dropped и Possble Scans.
Далее смотрим логи:
May 05 2017 10:41:03: %ASA-4-733100: [ Scanning] drop rate-1 exceeded. Current burst rate is 4 per second, max configured rate is 10; Current average rate is 12 per second, max configured rate is 5; Cumulative total count is 7530
May 05 2017 10:41:03: %ASA-4-733100: [ Scanning] drop rate-2 exceeded. Current burst rate is 0 per second, max configured rate is 8; Current average rate is 5 per second, max configured rate is 4; Cumulative tota