From 6c9db61696a9fd392340949543e32af8b82c537f Mon Sep 17 00:00:00 2001 From: Sven Vermeulen Date: Fri, 4 Sep 2015 21:50:42 +0200 Subject: Update on Gentoo hardening guide --- xml/SCAP/Makefile | 16 +- xml/SCAP/gentoo-oval.xml | 30 + xml/SCAP/gentoo-xccdf.xml | 4158 ++++++++++++++++++++++++--------------------- 3 files changed, 2239 insertions(+), 1965 deletions(-) diff --git a/xml/SCAP/Makefile b/xml/SCAP/Makefile index 208cd01..ad08a66 100644 --- a/xml/SCAP/Makefile +++ b/xml/SCAP/Makefile @@ -1,17 +1,12 @@ -location = "dev.gentoo.org:public_html/docs/security_benchmarks" +gentoo: report-gentoo-xccdf.html guide-gentoo-xccdf.html remediate-gentoo-xccdf.sh gentoo-ds.xml -all: report-gentoo-xccdf.html guide-gentoo-xccdf.html remediate-gentoo-xccdf.sh guide-gentoo-xccdf.docbook gentoo-ds.xml - -really_all: all report-gentoo-oval.xml +all_gentoo: gentoo report-gentoo-oval.xml report-gentoo-xccdf.html: gentoo-cpe.xml gentoo-xccdf.xml gentoo-oval.xml prep -pushd ~/tmp; oscap xccdf eval --cpe gentoo-cpe.xml --profile xccdf_org.gentoo.dev.swift_profile_default-oval --results results-gentoo-xccdf.xml --oval-results --check-engine-results --report report-gentoo-xccdf.html gentoo-xccdf.xml; popd guide-gentoo-xccdf.html: gentoo-cpe.xml gentoo-xccdf.xml gentoo-oval.xml prep - -pushd ~/tmp; oscap xccdf generate guide --profile xccdf_org.gentoo.dev.swift_profile_default-oval --output guide-gentoo-xccdf.html gentoo-xccdf.xml; popd - -guide-gentoo-xccdf.docbook: gentoo-cpe.xml gentoo-xccdf.xml gentoo-oval.xml prep - -pushd ~/tmp; oscap xccdf generate guide --profile xccdf_org.gentoo.dev.swift_profile_default-oval --format docbook --output guide-gentoo-xccdf.docbook gentoo-xccdf.xml; popd + -pushd ~/tmp; oscap xccdf generate guide --profile xccdf_org.gentoo.dev.swift_profile_default --output guide-gentoo-xccdf.html gentoo-xccdf.xml; popd remediate-gentoo-xccdf.sh: prep -pushd ~/tmp; oscap xccdf generate fix --output remediate-gentoo-xccdf.sh results-gentoo-xccdf.xml chmod 0644 remediate-gentoo-xccdf.sh; popd @@ -33,7 +28,4 @@ prep: -sed -i "s|@@VERSION@@|`date +%Y%m%d`|g" ~/tmp/gentoo-xccdf.xml -sed -i "s|@@DATE@@|`date +%Y-%m-%d`|g" ~/tmp/gentoo-xccdf.xml -upload: - -pushd ~/tmp; scp gentoo-cpe.xml gentoo-xccdf.xml gentoo-oval.xml gentoo-ds.xml guide-gentoo-xccdf.html report-gentoo-oval.html report-gentoo-xccdf.html $(location)/; popd; - -.PHONY: all prep upload really_all +.PHONY: gentoo prep all_gentoo diff --git a/xml/SCAP/gentoo-oval.xml b/xml/SCAP/gentoo-oval.xml index 427e5c1..c4a9da5 100644 --- a/xml/SCAP/gentoo-oval.xml +++ b/xml/SCAP/gentoo-oval.xml @@ -612,6 +612,22 @@ + + + The / file system is mounted with the nodev option + + Gentoo Linux + + + This definition tests whether the / partition is mounted with the nodev + mount option. + + + + + + + @@ -946,6 +962,15 @@ + + + + + + + @@ -1117,6 +1142,11 @@ + + / + + diff --git a/xml/SCAP/gentoo-xccdf.xml b/xml/SCAP/gentoo-xccdf.xml index aa85c1e..35ea6c0 100644 --- a/xml/SCAP/gentoo-xccdf.xml +++ b/xml/SCAP/gentoo-xccdf.xml @@ -1,2018 +1,2270 @@ - draft - Gentoo Security Benchmark - - This benchmarks helps people in improving their system configuration to be - more resilient against attacks and vulnerabilities. - - - @@VERSION@@ - - - - - Intensive validation profile - - This profile extends the default server profile by including tests that - are more intensive to run on a system. Tests such as full file system - scans to find world-writable files or directories have an otherwise too - large impact on the performance of a server. Tests include scripted - validationn. - - - - - - Default server setup settings (non-scripted) - - In this profile, we verify common settings for Gentoo Linux - configurations. The tests that are enabled in this profile can be ran - without visibly impacting the performance of the system. No scripted - checks are executed. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Default server setup settings - - In this profile, common settings for Gentoo Linux configurations are validated. - The tests can be ran without visibly impacting the performance of the system, and - also includes the scripted evaluation checks (SCE). - - - + + + +Intensive validation profile (non-scripted) + +This profile extends the default server profile by including tests that +are more intensive to run on a system. Tests such as full file system +scans to find world-writable files or directories have an otherwise too +large impact on the performance of a server. Tests do not include +scripted validation. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +Default server setup settings + +In this profile, common settings for Gentoo Linux configurations are validated. +The tests can be ran without visibly impacting the performance of the system, and +also includes the scripted evaluation checks (SCE). + + +