#!/bin/sh

#################################################################################
#
#   Lynis
# ------------------
#
# Copyright 2007-2008, Michael Boelen (michael@rootkit.nl), The Netherlands
# Web site: http://www.rootkit.nl
#
# Lynis comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
# welcome to redistribute it under the terms of the GNU General Public License.
# See LICENSE file for usage of this software.
#
#################################################################################
#
# Databases
#
#################################################################################
#
    InsertSection "Databases"
#
#################################################################################
#
    # Test        : DBS-1804
    # Description : Check if MySQL is being used
    Register --test-no DBS-1804 --weight L --network NO --description "Checking active MySQL process"
    if [ ${SKIPTEST} -eq 0 ]; then
	FIND=`ps ax | egrep "mysqld|mysqld_safe"`
	if [ "${FIND}" = "" ]; then
	    Display --indent 2 --text "- MySQL process status..." --result RUNNING --color GREEN
	    logtext "Result: MySQL is active"
	    MYSQL_RUNNING=1
	fi
    fi
#
#################################################################################
#
    # Test        : DBS-1806
    # Description : Check data directory
    #Register --test-no DBS-1806 --weight L --network NO --description "Checking MySQL data directory"
    #if [ ${SKIPTEST} -eq 0 ]; then
    #fi
#
#################################################################################
#
    # Test        : DBS-1808
    # Description : Check data directory permissions
    #Register --test-no DBS-1808 --weight L --network NO --description "Checking MySQL data directory permissions"
    #if [ ${SKIPTEST} -eq 0 ]; then
    #fi
#
#################################################################################
#

wait_for_keypress

#
#================================================================================
# Lynis - Copyright 2007-2008, Michael Boelen - www.rootkit.nl - The Netherlands
