mirror of
https://github.com/docker/docker-bench-security.git
synced 2025-01-19 00:32:34 +01:00
Merge pull request #81 from konstruktoid/tee_file_missing
missing file as non-root user
This commit is contained in:
commit
dafd938d19
1 changed files with 14 additions and 14 deletions
|
@ -42,16 +42,6 @@ usage () {
|
||||||
EOF
|
EOF
|
||||||
}
|
}
|
||||||
|
|
||||||
yell "# ------------------------------------------------------------------------------
|
|
||||||
# Docker Bench for Security v1.0.0
|
|
||||||
#
|
|
||||||
# Docker, Inc. (c) 2015
|
|
||||||
#
|
|
||||||
# Checks for dozens of common best-practices around deploying Docker containers in production.
|
|
||||||
# Inspired by the CIS Docker 1.6 Benchmark:
|
|
||||||
# https://benchmarks.cisecurity.org/tools2/docker/CIS_Docker_1.6_Benchmark_v1.0.0.pdf
|
|
||||||
# ------------------------------------------------------------------------------"
|
|
||||||
|
|
||||||
# Get the flags
|
# Get the flags
|
||||||
# If you add an option here, please
|
# If you add an option here, please
|
||||||
# remember to update usage() above.
|
# remember to update usage() above.
|
||||||
|
@ -64,6 +54,20 @@ do
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
|
|
||||||
|
if [ -z "$logger" ]; then
|
||||||
|
logger="${myname}.log"
|
||||||
|
fi
|
||||||
|
|
||||||
|
yell "# ------------------------------------------------------------------------------
|
||||||
|
# Docker Bench for Security v1.0.0
|
||||||
|
#
|
||||||
|
# Docker, Inc. (c) 2015
|
||||||
|
#
|
||||||
|
# Checks for dozens of common best-practices around deploying Docker containers in production.
|
||||||
|
# Inspired by the CIS Docker 1.6 Benchmark:
|
||||||
|
# https://benchmarks.cisecurity.org/tools2/docker/CIS_Docker_1.6_Benchmark_v1.0.0.pdf
|
||||||
|
# ------------------------------------------------------------------------------"
|
||||||
|
|
||||||
# Warn if not root
|
# Warn if not root
|
||||||
ID=$(id -u)
|
ID=$(id -u)
|
||||||
if [ "x$ID" != "x0" ]; then
|
if [ "x$ID" != "x0" ]; then
|
||||||
|
@ -71,10 +75,6 @@ if [ "x$ID" != "x0" ]; then
|
||||||
sleep 3
|
sleep 3
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ -z "$logger" ]; then
|
|
||||||
logger="${myname}.log"
|
|
||||||
fi
|
|
||||||
|
|
||||||
logit "Initializing $(date)\n"
|
logit "Initializing $(date)\n"
|
||||||
|
|
||||||
# Load all the tests from tests/ and run them
|
# Load all the tests from tests/ and run them
|
||||||
|
|
Loading…
Reference in a new issue