Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/CISOfy/lynis.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Boelen <michael.boelen@cisofy.com>2020-05-07 09:53:26 +0300
committerGitHub <noreply@github.com>2020-05-07 09:53:26 +0300
commite410d68ce6bed20e3d44e797ea0e10ff33ab9bb1 (patch)
tree285d612ce7e3ec3c4bcd63f2bb9d6e88808e0dfb
parentce3c80b44f418e28503e1aecaeb87c170d0c811c (diff)
parent51dfc34663b616b92ec1902f4474fff2129642a6 (diff)
Merge pull request #912 from konstruktoid/fileperms
accept more restrictive file permissions
-rw-r--r--include/functions4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/functions b/include/functions
index 58ddabe9..8d5a5ef8 100644
--- a/include/functions
+++ b/include/functions
@@ -1286,7 +1286,7 @@
CHECK_PERMISSION=$(echo "${CHECK_PERMISSION}" | ${AWKBINARY} '{printf "%03d",$1}')
# First try stat command
- LogText "Test: checking if file ${CHECKFILE} is ${CHECK_PERMISSION}"
+ LogText "Test: checking if file ${CHECKFILE} has the permissions set to ${CHECK_PERMISSION} or more restrictive"
if [ -n "${STATBINARY}" ]; then
case ${OS} in
@@ -1344,7 +1344,7 @@
DATA=$(echo "${DATA}" | ${AWKBINARY} '{printf "%03d",$1}')
if [ -n "${DATA}" ]; then
- if [ "${DATA}" = "${CHECK_PERMISSION}" ]; then
+ if [ "${DATA}" -le "${CHECK_PERMISSION}" ]; then
LogText "Outcome: correct permissions (${DATA})"
return 0
fi