aboutsummaryrefslogtreecommitdiffstats
path: root/cron-sh
diff options
context:
space:
mode:
authorFrederic Lepied <flepied@mandriva.com>2005-08-10 06:33:05 +0000
committerFrederic Lepied <flepied@mandriva.com>2005-08-10 06:33:05 +0000
commit4e27185aceecea6bb0786fbe4eac9a00da9d58d7 (patch)
tree7c84c54bd0493210e4f5736eeae1154104ecc0da /cron-sh
parentc90915ce7930066d70f5c7d80168eb21436eaf8e (diff)
downloadmsec-4e27185aceecea6bb0786fbe4eac9a00da9d58d7.tar
msec-4e27185aceecea6bb0786fbe4eac9a00da9d58d7.tar.gz
msec-4e27185aceecea6bb0786fbe4eac9a00da9d58d7.tar.bz2
msec-4e27185aceecea6bb0786fbe4eac9a00da9d58d7.tar.xz
msec-4e27185aceecea6bb0786fbe4eac9a00da9d58d7.zip
Mandriva Linux
Diffstat (limited to 'cron-sh')
-rwxr-xr-xcron-sh/security_check.sh7
1 files changed, 4 insertions, 3 deletions
diff --git a/cron-sh/security_check.sh b/cron-sh/security_check.sh
index ec6bbeb..2960e23 100755
--- a/cron-sh/security_check.sh
+++ b/cron-sh/security_check.sh
@@ -67,12 +67,13 @@ while read username uid homedir; do
if ! expr "$homedir" : "$FILTER" > /dev/null; then
for f in ${list} ; do
file="${homedir}/${f}"
- if [[ -f ${file} ]] ; then
- printf "${uid} ${username} ${file} `ls -LldcGn ${file}`\n"
+ if [[ -f "${file}" ]] ; then
+ res=`ls -LldcGn "${file}"`
+ printf "${uid}:${username}:${file}:${res}\n"
fi
done
fi
-done | awk '$1 != $6 && $6 != "0" \
+done | awk -F: '$1 != $6 && $6 != "0" \
{ print "\t\t- " $3 " : file is owned by uid " $6 "." }
$4 ~ /^-...r/ \
{ print "\t\t- " $3 " : file is group readable." }