Copyright (C) 2011, 2012, 2013 Gene Guinter
SNĒZ is free software: you can redistribute
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
SNĒZ is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/.
Contact the copyright holder at gene@geneguinter.com.
SECURITY
While SNEZ is tested with web vulnerability scanners, do not allow SNEZ to be accessed from the Internet
or an untrusted or insecure network.
REQUIREMENTS and PRE-REQS
Snort, Apache, MySQL, PHP.
When configuring Snort, output type must be MySQL or barnyard2 to MySQL.
NEW INSTALL (See below for upgrades)
Create SNEZ database and install package-
1. mkdir /opt/SNEZ
2. cd /opt/SNEZ
3. cp [download location]/SNEZ-[ver].[rel].tar.gz ./
4. tar -xzvf SNEZ-[ver].[rel].tar.gz
5. cd SNEZ-[ver].[rel]
6. ./SNEZcreate or bash SNEZcreate (This will create and populate your SNEZ db.
Supply password for root@localhost when prompted;
then supply a password for access to your SNEZ DB when prompted.
You will enter this password in the config file in the next step).
7. vi ./SNEZconfig.php. Add the SNEZ database password selected in the previous step to the line
SNEZ.password=
Modify other parameters as needed, especially your sniffer interface (See CONFIG FILE later in the README)
8. ./SNEZinstall or bash SNEZinstall
9. Create logins and populate malware active ip list-
a. In a browser- http://[ip address of server]/SNEZ/SNEZlogin.php
b. Login as 'admin' using password of 'admin'
c. Click on the Admin Functions tab and add an administrator
that can add users (be sure to check the box)
d. From the browser, log off and log on with the new administrator id from step 3.
e. Go to Admin Functions and delete user admin.
10. Click on the box to load malware active ip list from malwaredomainlist.com
11. Use visudo to make the additions and changes so certain root commands can be executed. (Caution! Read the sudo and visudo documentation.
Mistakes here can render your system inoperable. Never edit the sudoers file with vi or another editor. You skip this if you don't
want to use the tcpdump or logrotate-on-demand capabilities of SNEZ, or are uncomfortable making the changes, or concerned about security implications of allowing
a non-root user running tcpdump or logrotate).
hostname (get hostname of your system)
visudo (add the following lines, adjusting for your system appropriately)
apache hostname=NOPASSWD:/usr/sbin/tcpdump (substitue your host name for hostname)
apache hostname=NOPASSWD:/bin/ps
apache hostname=NOPASSWD:/bin/kill
apache hosthame=NOPASSWD:/usr/sbin/logrotate
(comment out the following line)
Defaults requiretty
!wq (or q! if you make mistakes and want to start over)
CONFIG FILE (after install, the config file can be changed at any time, and then run SNEZconfiginstall from
/opt/SNEZ/SNEZ-v.r.m)
Settings in the SNEZconfig.php file-
[settings]
encrypt = none none or an existing, installed php hash function for password
NOTE: if you change this on a running system, login first,
run SNEZconfiginstall, and immediately add new users
inactive = 900 page timeout
SNEZ.password password to the SNEZ database chosen at install time; must be set
gmt= -5 GMT offset; default to USA Eastern
max.rowlimit=10000 default maximum db rows read before page displayed
dns.rowlimit=1000 default max db rows read before page displayed when DNS resolution used;
(can be lowered for speed)
summary.rowlimit = 10000 number of db rows to read before fully collapsed summary view page displayed
php.max.execution.time = 120 overrides php.ini max execution time
sniffer.interface = eth1 sniffer interface for optional use of tcpdump (*Note)
min.user.pwd.len = 8 minimum password length for users
pwd.complexity = strong default is strong, letter, number, caps, special chars; can change to simple
whois = SNEZdoc.php?page"="whois whois or reputation lookup site; select your personal favorite *
(whois2 through whois9 can be added to for up to 10 reputation or lookup sites)
* You can cut from the SNEZ page and paste into the lookup site, however, keyword substitution is also provided
for ip address and domain lookup information.
Use keyword SNEZip to substitute ip address, and SNEZdns for domain lookup.
You will need to manually visit the site to determine the path and the proper location in the URI for the parameters.
Escape equal signs and ampersand characters by enclosing them in double-quotes.
This feature is offered as a convenience, and you are solely responsible for accessing the chosen site properly and
according to the chosen site's terms of use.
Format
whois = http://favoritelookupdomain.com/....path.../SNEZdns
whois = http://favoriteantimalwaresite.com/...path.../SNEZip
Examples:
whois = http://www.ipvoid.com/scan/SNEZip/
whois = http://www.google.com/safebrowsing/diagnostic?site"="SNEZdns
whois = http://www.siteadvisor.com/sites/SNEZdns
UPGRADES
1. cd /opt/SNEZ
3. cp [download location]/SNEZ-[ver].[rel].tar.gz ./
4. tar -xzvf SNEZ-[ver].[rel].tar.gz
5. cd SNEZ-[ver].[rel]
6. ./SNEZinstall or bash SNEZinstall
If config file SNEZconfig.php exists, it will not be overwritten (ie. upgrade)
(steps 7 and 8 only if config file needs changed)
7. vi ./SNEZconfig.php and make changes
8. ./SNEZconfiginstall
9. only if upgrading from < or = SNEZ 1.6.x, ./SNEZ17update
10. ./SNEZ18update
UNINSTALL
Can be used to uninstall product permanently or clean for fresh install
./opt/SNEZ/SNEZ-[ver].[rel]/SNEZuninstall
SNEZ-1.8.1 CHANGES
Bugs fixed-
Analysis view passed resolved name instead of ip address to detail view
Analysis view whois and ns links were not consistent with summary view
Enhancements-
Programs/Modules changed:
READEME, BUGS, SNEZabout.php, SNEZsiganalysis.php
Programs/Modules added:
Programs/Modules deprecated:
SNEZ-1.8 CHANGES
Bugs fixed-
Uninstall (SNEZuninstall) left old logs in /var/log/
Add icon for apple browsers
Cleanup httpd error log entries
Some browsers rendered malware ip addresses as telephone number links
favicon.ico missing on some pages
Enhancements-
whois when dns resolution is on provides access to all lookup sites in SNEZconfig.php
supports strong passwords as the default
force password change on first login
provide for password expiry
Programs/Modules changed:
README, BUGS, SNEZdns.php, SNEZabout.php, SNEZ.php, SNEZ_adduser_totable.php, SNEZadmin,php,
SNEZ_process_chgpwd.php, SNEZconfig.php, SNEZ_process_login.php, SNEZinstall, SNEZmdlupdate.php,
SNEZuninstall
Programs/Modules added:
SNEZ18update, SNEZ_modify_members
Programs/Modules deprecated:
SNEZ-1.7.0.1 CHANGES
Updated copyright information.
SNEZ-1.7 CHANGES
Bugs fixed-
Enhancements-
IP address lookups in malware domain list
Allow ip address and dns resolution to be parsed into favorite whois lookup to replace cut/paste
Allow up to 10 lookup and reputation sites
Programs/Modules changed:
README, BUGS, SNEZabout.php, SNEZ.php, SNEZadmin.php, SNEZconfig.php, SNEZcreatetables, SNEZdns.php, SNEZdoc.php,
SNEZsiganalysis.php
Programs/Modules added:
SNEZmdlupdate.php, SNEZ17update, SNEZcreatemdl
Programs/Modules deprecated:
Source: README, updated 2013-03-30