Hello,
Why Suricata-IDS doesn’t have any rule to block scanners? When I launch Arachni scanner then it cause the server CPU usage become 100%. Anyone here can help me to block it?
Provide some rules to block this kind of program make Suricata-IDS more popular.
If Arachni.pcap is a pcap file you have generated, yes. But if you need to generate the pcap you can either use the pcap dump feature of Suricata or just use tcpdump to capture that specific pcap from your tests.
For tcpdump I would recommend the manpage of tcpdump but the basic command would look like:
sudo tcpdump -i $INTERFACE -w file.pcap
Where $INTERFACE is your interface where you want to capture and ideally you add some sort of bpf filter to narrow it down to that specific traffic you test.
There are a few ET OPEN (Community/Free) rules concerning this which would live in the emerging-scan.rules file. The rules are setup as External->Internal and will not fire if you are scanning internal->internal. As @bwoodberg stated, if you find something that needs coverage, we are happy to work on it and provide the rule back to the community.
alert http $EXTERNAL_NET any -> HOME_NET any (msg:"ET SCAN Arachni Scanner Web Scan"; flow:established,to_server; threshold: type limit, track by_src, count 1, seconds 300; http.user_agent; content:"Arachni/"; pcre:"/Arachni\/v?\d\.\d\.\d/i"; reference:url,arachni-scanner.com; reference:url,github.com/Zapotek/arachni; classtype:attempted-recon; sid:2014869; rev:6; metadata:created_at 2012_06_07, updated_at 2020_06_09;)
#alert http $EXTERNAL_NET any -> $HTTP_SERVERS any (msg:“ET SCAN Arachni Web Scan”; flow:established,to_server; content:"/Arachni-"; http_uri; threshold: type limit, track by_src, seconds 60, count 1; reference:url,www.arachni-scanner.com/; classtype:attempted-recon; sid:2017142; rev:2; metadata:created_at 2013_07_12, updated_at 2013_07_12;)
Those are the rules that exist at present from a quick search. If you want to send us a pcap with some traffic, please send it to our submission portal at https://feedback.emergingthreats.net - Thanks!
It’s your choice whether you add a rule to an existing rule file or create a new one – Suricata supports both methods. Choose the approach that works best for you and your situation.
If you use multiple rule files, make sure that the rule file is recognized by Suricata.
In the Suricata configuration file, you’ll see
rule-files:
- suricata.rules
If you add a rule file, make sure it’s in the proper directory – ensure that new rule files are in the directory default-rule-path
##
## Configure Suricata to load Suricata-Update managed rules.
##
## If this section is completely commented out move down to the "Advanced rule
## file configuration".
##
default-rule-path: /var/lib/suricata/rules
rule-files:
- suricata.rules