mirror of
https://github.com/CISOfy/lynis.git
synced 2025-07-31 01:34:23 +02:00
Removing deprecated strings and cleaning up
This commit is contained in:
parent
95d08a735a
commit
afaecd9512
@ -5,8 +5,8 @@
|
|||||||
# Lynis
|
# Lynis
|
||||||
# ------------------
|
# ------------------
|
||||||
#
|
#
|
||||||
# Copyright 2007-2015, Michael Boelen (michael@rootkit.nl), The Netherlands
|
# Copyright 2007-2015, Michael Boelen (michael.boelen@cisofy.com)
|
||||||
# Web site: http://www.rootkit.nl
|
# Web site: https://cisofy.com
|
||||||
#
|
#
|
||||||
# Lynis comes with ABSOLUTELY NO WARRANTY. This is free software, and you are
|
# 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.
|
# welcome to redistribute it under the terms of the GNU General Public License.
|
||||||
@ -326,15 +326,6 @@
|
|||||||
fi
|
fi
|
||||||
#
|
#
|
||||||
#################################################################################
|
#################################################################################
|
||||||
#
|
|
||||||
# Test : ACCT-9658
|
|
||||||
# Description : Check required audit files in /etc/security
|
|
||||||
#if [ ${SOLARIS_AUDITD_RUNNING} -eq 1 ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
|
|
||||||
#Register --test-no ACCT-9658 --os Solaris --preqs-met ${PREQS_MET} --weight L --network NO --description "Check required audit files"
|
|
||||||
#if [ ${SKIPTEST} -eq 0 ]; then
|
|
||||||
#fi
|
|
||||||
#
|
|
||||||
#################################################################################
|
|
||||||
#
|
#
|
||||||
# Test : ACCT-9662
|
# Test : ACCT-9662
|
||||||
# Description : Check location for audit events
|
# Description : Check location for audit events
|
||||||
@ -367,22 +358,6 @@
|
|||||||
fi
|
fi
|
||||||
#
|
#
|
||||||
#################################################################################
|
#################################################################################
|
||||||
#
|
|
||||||
# Test : ACCT-96xx
|
|
||||||
# Description : Check which events are audited
|
|
||||||
#if [ ${SOLARIS_AUDITD_RUNNING} -eq 1 ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
|
|
||||||
#Register --test-no ACCT-96xx --os Solaris --preqs-met ${PREQS_MET} --weight L --network NO --description "Check BSM auditing in module list"
|
|
||||||
#if [ ${SKIPTEST} -eq 0 ]; then
|
|
||||||
#
|
|
||||||
#################################################################################
|
|
||||||
#
|
|
||||||
# Test : ACCT-96xx
|
|
||||||
# Description : Check user specific event auditing
|
|
||||||
#if [ ${SOLARIS_AUDITD_RUNNING} -eq 1 ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
|
|
||||||
#Register --test-no ACCT-96xx --os Solaris --preqs-met ${PREQS_MET} --weight L --network NO --description "Check user specific event auditing"
|
|
||||||
#if [ ${SKIPTEST} -eq 0 ]; then
|
|
||||||
#
|
|
||||||
#################################################################################
|
|
||||||
#
|
#
|
||||||
# Test : ACCT-9672
|
# Test : ACCT-9672
|
||||||
# Description : check auditstat
|
# Description : check auditstat
|
||||||
@ -405,26 +380,6 @@
|
|||||||
#################################################################################
|
#################################################################################
|
||||||
#
|
#
|
||||||
|
|
||||||
# Test : ACCT-9680
|
|
||||||
# Description : Check if required packages are installed
|
|
||||||
#if [ ${SOLARIS_AUDITD_RUNNING} -eq 1 ]; then PREQS_MET="YES"; else PREQS_MET="NO"; fi
|
|
||||||
#Register --test-no ACCT-9662 --os Solaris --preqs-met ${PREQS_MET} --weight L --network NO --description "Check BSM auditing in module list"
|
|
||||||
#if [ ${SKIPTEST} -eq 0 ]; then
|
|
||||||
#
|
|
||||||
# Solaris 10 packages
|
|
||||||
# bash-3.00# pkginfo | egrep 'SUNWcar|SUNWcsr|SUNWcsu|SUNWhea|SUNWman'
|
|
||||||
#system SUNWcar Core Architecture, (Root)
|
|
||||||
#system SUNWcsr Core Solaris, (Root)
|
|
||||||
#system SUNWcsu Core Solaris, (Usr)
|
|
||||||
#system SUNWhea SunOS Header Files
|
|
||||||
#system SUNWman On-Line Manual Pages
|
|
||||||
|
|
||||||
#
|
|
||||||
#################################################################################
|
|
||||||
#
|
|
||||||
# Check psacct package (ac, lastcomm, accton, sa)
|
|
||||||
# Check auditd (auditctl, ausearch, aureport)
|
|
||||||
|
|
||||||
wait_for_keypress
|
wait_for_keypress
|
||||||
|
|
||||||
#
|
#
|
||||||
|
@ -58,10 +58,8 @@
|
|||||||
#
|
#
|
||||||
# Test : AUTH-9208
|
# Test : AUTH-9208
|
||||||
# Description : Check non-unique accounts
|
# Description : Check non-unique accounts
|
||||||
Register --test-no AUTH-9208 --weight L --network NO --description "Check non-unique accounts"
|
Register --test-no AUTH-9208 --weight L --network NO --description "Check non-unique accounts in passwd file"
|
||||||
if [ ${SKIPTEST} -eq 0 ]; then
|
if [ ${SKIPTEST} -eq 0 ]; then
|
||||||
logtext "Test: ${USER_PASSWD_DOUBLEUID_AUDIT_TITLE}"
|
|
||||||
logtext "Description: ${USER_PASSWD_DOUBLEUID_AUDIT_DESCRIPTION}"
|
|
||||||
logtext "Test: Checking for non-unique accounts"
|
logtext "Test: Checking for non-unique accounts"
|
||||||
if [ "${OS}" = "DragonFly" -o "${OS}" = "FreeBSD" -o "${OS}" = "NetBSD" ]; then
|
if [ "${OS}" = "DragonFly" -o "${OS}" = "FreeBSD" -o "${OS}" = "NetBSD" ]; then
|
||||||
PASSWD_FILE="/etc/master.passwd"
|
PASSWD_FILE="/etc/master.passwd"
|
||||||
@ -84,7 +82,7 @@
|
|||||||
Display --indent 2 --text "- Checking UIDs" --result SKIPPED --color WHITE
|
Display --indent 2 --text "- Checking UIDs" --result SKIPPED --color WHITE
|
||||||
logtext "Result: test skipped, ${PASSWD_FILE} file not available"
|
logtext "Result: test skipped, ${PASSWD_FILE} file not available"
|
||||||
fi
|
fi
|
||||||
logtext "Remarks: ${USER_PASSWD_DOUBLEUID_AUDIT_TEXT}"
|
logtext "Remarks: Non unique UIDs can riskful for the system or part of a configuration mistake"
|
||||||
fi
|
fi
|
||||||
#
|
#
|
||||||
#################################################################################
|
#################################################################################
|
||||||
|
@ -69,7 +69,7 @@
|
|||||||
logtext "Info: above files could be redirected files to avoid logging and should be investigated"
|
logtext "Info: above files could be redirected files to avoid logging and should be investigated"
|
||||||
ReportWarning ${TEST_NO} "M" "Incorrect file type found for shell history file"
|
ReportWarning ${TEST_NO} "M" "Incorrect file type found for shell history file"
|
||||||
fi
|
fi
|
||||||
logtext "Remarks: ${HOME_HISTORY_LOG_TEXT}"
|
logtext "Remarks: History files are normally of the type 'file'. Symbolic links and other types can be riskful."
|
||||||
else
|
else
|
||||||
Display --indent 2 --text "- Checking shell history files" --result SKIPPED --color WHITE
|
Display --indent 2 --text "- Checking shell history files" --result SKIPPED --color WHITE
|
||||||
logtext "Result: Homedirs is empty, test will be skipped"
|
logtext "Result: Homedirs is empty, test will be skipped"
|
||||||
|
@ -286,8 +286,8 @@
|
|||||||
Register --test-no KRNL-5745 --os FreeBSD --weight L --network NO --description "Checking FreeBSD loaded kernel modules"
|
Register --test-no KRNL-5745 --os FreeBSD --weight L --network NO --description "Checking FreeBSD loaded kernel modules"
|
||||||
if [ ${SKIPTEST} -eq 0 ]; then
|
if [ ${SKIPTEST} -eq 0 ]; then
|
||||||
Display --indent 2 --text "- Checking active kernel modules"
|
Display --indent 2 --text "- Checking active kernel modules"
|
||||||
logtext "Test: ${KERNEL_ACTIVE_MODULES_TITLE}"
|
logtext "Test: Active kernel modules (KLDs)"
|
||||||
logtext "Description: ${KERNEL_ACTIVE_MODULES_DESCRIPTION}"
|
logtext "Description: View all active kernel modules (including kernel)"
|
||||||
logtext "Test: Checking modules"
|
logtext "Test: Checking modules"
|
||||||
if [ -f /sbin/kldstat ]; then
|
if [ -f /sbin/kldstat ]; then
|
||||||
FIND=`kldstat | grep -v 'Name' | tr -s ' ' | cut -d ' ' -f6`
|
FIND=`kldstat | grep -v 'Name' | tr -s ' ' | cut -d ' ' -f6`
|
||||||
|
Loading…
x
Reference in New Issue
Block a user