# HG changeset patch # User Michiel Broek # Date 1369223209 -7200 # Node ID 65656789da08e31c23da0ecd0c72294dfa6f0029 # Parent 37f217a8bcce7dc07d0d3c9a32ba1224edd95ccc Removed uptime script, changed passwd test, minimized sensors output, bumped to version 0.18 diff -r 37f217a8bcce -r 65656789da08 cron.daily/security --- a/cron.daily/security Mon Feb 18 19:47:24 2013 +0100 +++ b/cron.daily/security Wed May 22 13:46:49 2013 +0200 @@ -4,9 +4,6 @@ # Copyright (C) 2005-2013 # # Michiel Broek -# Beekmansbos 10 -# 1971 BV IJmuiden -# the Netherlands # # This file is part of SlackSecCheckSripts. # @@ -25,7 +22,7 @@ # Software Foundation, 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. ############################################################################# -VERSION=0.17 +VERSION=0.18 export PATH=/bin:/usr/bin:/sbin:/usr/sbin umask 077 LANG=C; export LANG diff -r 37f217a8bcce -r 65656789da08 security.d/chk_aliases --- a/security.d/chk_aliases Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_aliases Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_clamav --- a/security.d/chk_clamav Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_clamav Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_exports --- a/security.d/chk_exports Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_exports Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_group --- a/security.d/chk_group Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_group Wed May 22 13:46:49 2013 +0200 @@ -1,12 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# Beekmansbos 10 -# 1971 BV IJmuiden -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_homedirs --- a/security.d/chk_homedirs Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_homedirs Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_homespace --- a/security.d/chk_homespace Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_homespace Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_logs --- a/security.d/chk_logs Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_logs Wed May 22 13:46:49 2013 +0200 @@ -4,7 +4,6 @@ # Copyright (C) 2005-2013 # # Michiel Broek -# the Netherlands # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_mailbox --- a/security.d/chk_mailbox Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_mailbox Wed May 22 13:46:49 2013 +0200 @@ -4,7 +4,6 @@ # Copyright (C) 2005-2013 # # Michiel Broek -# the Netherlands # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_mailqueue --- a/security.d/chk_mailqueue Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_mailqueue Wed May 22 13:46:49 2013 +0200 @@ -4,7 +4,6 @@ # Copyright (C) 2005-2013 # # Michiel Broek -# the Netherlands # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_passwd --- a/security.d/chk_passwd Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_passwd Wed May 22 13:46:49 2013 +0200 @@ -1,12 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# Beekmansbos 10 -# 1971 BV IJmuiden -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # @@ -102,7 +99,7 @@ printf "\tLogin %s does not have a shell\n", $1; if ($7 != "" && ! shells[$7] && $8 !~ /!/ && $8 != "*") printf "\tLogin %s does not have a valid shell (%s)\n", $1, $7; - if ($7 != "" && shells[$7] && ($8 ~ /!/ && $8 = "*")) + if ($7 != "" && shells[$7] && ($8 ~ /!/ && $8 = "*") && ($4 == 100)) printf "\tLogin %s account is locked.\n", $1; if ($8 == "") printf "\tLogin %s has no password.\n", $1; diff -r 37f217a8bcce -r 65656789da08 security.d/chk_pkgs --- a/security.d/chk_pkgs Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_pkgs Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_plussigns --- a/security.d/chk_plussigns Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_plussigns Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_rootdotfiles --- a/security.d/chk_rootdotfiles Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_rootdotfiles Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_sensors --- a/security.d/chk_sensors Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_sensors Wed May 22 13:46:49 2013 +0200 @@ -1,12 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# Beekmansbos 10 -# 1971 BV IJmuiden -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # @@ -44,8 +41,8 @@ if [ -x /usr/bin/sensors ]; then if [ ! -n "$(sensors -s 2>&1)" ]; then result=`sensors 2>&1` - echo "$result" if echo "$result" |grep -q "ALARM"; then + echo "$result" echo "" echo "** WARNING: One or more sensors show ALARM! **" fi diff -r 37f217a8bcce -r 65656789da08 security.d/chk_setid --- a/security.d/chk_setid Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_setid Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_smart --- a/security.d/chk_smart Mon Feb 18 19:47:24 2013 +0100 +++ b/security.d/chk_smart Wed May 22 13:46:49 2013 +0200 @@ -1,10 +1,9 @@ #!/bin/bash # ############################################################################# -# Copyright (C) 2005-2012 +# Copyright (C) 2005-2013 # -# Michiel Broek -# the Netherlands +# Michiel Broek # # This file is part of SlackSecCheckScripts. # diff -r 37f217a8bcce -r 65656789da08 security.d/chk_uptime --- a/security.d/chk_uptime Mon Feb 18 19:47:24 2013 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,43 +0,0 @@ -#!/bin/bash -# -############################################################################# -# Copyright (C) 2005-2012 -# -# Michiel Broek -# the Netherlands -# -# This file is part of SlackSecCheckScripts. -# -# This package is free software; you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by the -# Free Software Foundation; either version 2, or (at your option) any -# later version. -# -# SlackSecCheckScripts 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 MBSE BBS; see the file COPYING. If not, write to the Free -# Software Foundation, 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA. -############################################################################# - -PATH=/sbin:/usr/sbin:/bin:/usr/bin - -umask 077 -TZ=UTC; export TZ -LANG=C; export LANG - -SECUREDIR=`mktemp -d /tmp/_securedir.XXXXXX` || exit 1 - -trap "/bin/rm -rf $SECUREDIR ; exit 0" EXIT INT QUIT PIPE - -if ! cd "$SECUREDIR"; then - echo "Can not cd to $SECUREDIR". - exit 1 -fi - -printf "\nUptime: " -uptime -