Internet -- Router -- SmoothSec -- Switch -- Personal ComputersNetwork Card 0 and 1 will be bridged up while Network Card 2 will be a management interface. Step 1 : First of all, SmoothSec (Network Card 2) is connected to the Switch while Network Card 0 and 1 do not connect to the router. It is because you need to connect to the internet for the installation. Step 2 : Install SmoothSec as usual or follow the wiki. During the installation, you may be prompted some firmware are missing, you just ignore it as some firmware for Realtek 8169 are missing. It is harmless to do so. After installed, the box will be reboot. Login as "
root" with password "
toor". Step 2a : To improve the SmoothSec :
apt-get --purge remove arpwatch apt-get install arpalert openjdk-7-jre fail2ban cd /etc/arpalert/ mv oui.txt oui.txt.old wget http://standards.ieee.org/regauth/oui/oui.txtStep 3 (Configuration of Suricata) : Suricata
nano /etc/suricata/suricata.yamlLocate "
- fast:" and change "
enabled: no" to "
enabled: yes". Locate "
- drop:" and change "
enabled: no" to "
enabled: yes". Time Zone for Snorby If your time zone is not UTC, you should run the following command :
dpkg-reconfigure tzdataSet the time zone for "
UTC" at "
None of the above"; otherwise, the Snorby will reported wrong timestamp. Set your time zone at the Snorby web interface when it is available after Step 5. Email feature of Snorby
apt-get install postfixConfigure the Postfix properly according to your network at "
nano /var/www/snorby/config/initializers/mail_config.rbUncomment the lines just below "
# Sendmail Example:". Step 4 : Connect Network Card 0 to router and Network Card 1 to Switch. Normally, Network Card 0 will be eth0, Network Card 1 will be eth1 and Network Card 2 will be eth2.
nano /etc/network/interfacesComment all about
eth2entries. Append the following :
auto eth2 iface eth2 inet static address 192.168.0.120 netmask 255.255.255.0 gateway 192.168.0.1* where the "
address" is your SmoothSec IP address and "
gateway" is the IP address of your router.
nano /etc/init.d/bridgeChange "
net1=eth1" to "
net1=eth0" Change "
net2=eth2" to "
net2=eth1" Change "
brctl addif $br eth1" to "
brctl addif $br eth0" Change "
brctl addif $br eth2" to "
brctl addif $br eth1"
update-rc.d bridge defaultsStep 5: Run the script "
smoothsec.first.setup" in the terminal. Type "
br0" when asking for monitor network interface. Select "
Snort" or "
Suricata" as IDS Engine. I choose "
Suricata". Email address and password are for Snorby web interface login. Then reboot. Once boot up, go to one of the Personal Computers and browse "
https://192.168.0.120". Then set the time zone and your report email address accordingly. Step 6: To update SmoothSec, you need to do the following commands (you can make a script to do so). The rules will be updated automatically in the early morning every day.
apt-get update apt-get dist-upgrade apt-get --purge autoclean apt-get --purge autoremove # update SmoothSec cd /root/updates/ git pull origin master
Debug the mailing feature Do not run the following commands unless you really need to.
bundle exec rails c production Snorby::Jobs::SensorCacheJob.new(true).perform Known Issue Pigsty will crash randomly. As a result, no capture in Snorby. The problem has been reported, see here.
--> The workaround is to run a testing bash script on every 5 minutes to start Pigsty again.Update Developers just fixed the problem. You just upgrade the Pigsty with the following command :
nano /root/chkpigstylog #!/bin/bash # Check if "Error: " in pigsty.log or not. If yes, start Pigsty again. STRING="Error: " if grep -R "$STRING" /var/log/pigsty.log then /root/runpigsty fi
nano /root/runpigsty #!/bin/bash /usr/local/bin/pigsty -c /etc/pigsty/suricata.pigsty.config.js -i eth0 -n "Suricata" -d /var/log/suricata/ -m unified2.alert.* -D
crontab -e */5 * * * * /root/chkpigstylog
npm update pigsty-mysql -g npm update pigsty -gReference Snorby GitHub Suricata SmoothSec Pigsty SmoothSec WiKi - for installation That's all! See you.