Commit 019da4b6 authored by Josh Grancell's avatar Josh Grancell

1.7.0-d19 updates

parent 0801b35d
# -------------------------------------------------
#
# Package: Malscan
# Author: Josh Grancell <josh@joshgrancell.com>
# Description: Linux malware scanner for web servers
# Copyright: 2015-2016 Josh Grancell
# License: MIT License
#
# -------------------------------------------------
## Malscan freshclam configuration
# Path to the database directory.
# WARNING: It must match clamd.conf's directive!
# Default: hardcoded (depends on installation options)
DatabaseDirectory /var/lib/malscan
# Path to the log file (make sure it has proper permissions)
# Default: disabled
UpdateLogFile /var/log/malscan/update.log
# By default when started freshclam drops privileges and switches to the
# "clamav" user. This directive allows you to change the database owner.
# Default: clamav (may depend on installation options)
DatabaseOwner malscan
# database.clamav.net is a round-robin record which points to our most
# reliable mirrors. It's used as a fall back in case db.XY.clamav.net is
# not working. DO NOT TOUCH the following line unless you know what you
# are doing.
DatabaseMirror database.clamav.net
\ No newline at end of file
This diff is collapsed.
......@@ -9,13 +9,13 @@
#
# -------------------------------------------------
VERSION="1.7.0-dev18"
DATE="June 08, 2016"
VERSION=$(cat )
# -------------------------------------------------
## Loading the configuration file from the Malscan directory
source /etc/malscan.conf
VERSION=$(cat "$APPLICATION_DIRECTORY/version.txt" || echo "unknown")
## Setting up some default binary locations
FRESHCLAM_BINARY_LOCATION=$(which freshclam)
......@@ -167,7 +167,7 @@ function updater {
echo ""
echo -e "\033[37m - Update: Updating ClamAV definitions. This can take a long time."
"$FRESHCLAM_BINARY_LOCATION" --datadir="$SIGNATURES_DIRECTORY" >> /dev/null 2>&1
"$FRESHCLAM_BINARY_LOCATION" --datadir="$SIGNATURES_DIRECTORY" --config-file="$CONFIGURATION_DIRECTORY/freshclam.conf" >> /dev/null 2>&1
echo -e "\033[32m - Update: ClamAV malware definitions have been updated.\033[37m"
echo ""
......@@ -190,19 +190,19 @@ function config_view {
## Displaying all of our configuration options
echo ""
echo "Application Configuration Settings"
echo "APPLICATION_DIRECTORY - $APPLICATION_DIRECTORY"
echo "CONFIGURATION_FILE - $CONFIGURATION_FILE"
echo "SIGNATURES_DIRECTORY - $SIGNATURES_DIRECTORY"
echo "LOGGING_DIRECTORY - $LOGGING_DIRECTORY"
echo "QUARANTINE_DIRECTORY - $QUARANTINE_DIRECTORY"
echo "APPLICATION_DIRECTORY - $APPLICATION_DIRECTORY"
echo "CONFIGURATION_DIRECTORY - $CONFIGURATION_DIRECTORY"
echo "SIGNATURES_DIRECTORY - $SIGNATURES_DIRECTORY"
echo "LOGGING_DIRECTORY - $LOGGING_DIRECTORY"
echo "QUARANTINE_DIRECTORY - $QUARANTINE_DIRECTORY"
echo ""
echo "Notification Settings"
echo "EMAIL_NOTIFICATIONS - $EMAIL_NOTIFICATIONS"
echo "NOTIFICATION_ADDRESSES - $NOTIFICATION_ADDRESSES"
echo "MALSCAN_SENDER_ADDRESS - $MALSCAN_SENDER_ADDRESS"
echo "EMAIL_NOTIFICATIONS - $EMAIL_NOTIFICATIONS"
echo "NOTIFICATION_ADDRESSES - $NOTIFICATION_ADDRESSES"
echo "MALSCAN_SENDER_ADDRESS - $MALSCAN_SENDER_ADDRESS"
echo ""
echo "Scanning Settings"
echo "STRING_LENGTH_MINIMUM - $STRING_LENGTH_MINIMUM"
echo "STRING_LENGTH_MINIMUM - $STRING_LENGTH_MINIMUM"
}
......@@ -210,7 +210,7 @@ function config_set {
if [[ "$SET_TARGET" != "" && "$SET_VALUE" != "" ]]; then
sed -i "s|^$SET_TARGET.*$|$SET_TARGET=\"$SET_VALUE\"|m" "$CONFIGURATION_FILE"
sed -i "s|^$SET_TARGET.*$|$SET_TARGET=\"$SET_VALUE\"|m" "$CONFIGURATION_DIRECTORY/malscan.conf"
echo " * Configuration: $SET_TARGET has been updated to $SET_VALUE"
......
......@@ -13,7 +13,8 @@
SIGNATURES_DIRECTORY="/var/lib/malscan"
APPLICATION_DIRECTORY="/usr/local/share/malscan"
LOGGING_DIRECTORY="/var/log/malscan"
CONFIGURATION_FILE="/etc/malscan.conf"
CONFIGURATION_DIRECTORY="/etc/malscan"
FRESHCLAM_CONFIG_FILE="/etc/malscan/freshclam.conf"
QUARANTINE_DIRECTORY="/root/.malscan/quarantine"
## Email Notifications
......
1.7.0-d19
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment