[PATCH 11/22] accounts_* remediation update

Shawn Wells shawn.d.wells at gmail.com
Mon Sep 16 01:32:27 UTC 2013


-------------- next part --------------
>From a9eaf154b3616b78aa2a97a67c46cff7cb0fa88c Mon Sep 17 00:00:00 2001
From: Shawn Wells <shawn at redhat.com>
Date: Wed, 11 Sep 2013 20:22:42 -0400
Subject: [PATCH 11/22] accounts_* remediation update
 Needed to append filename after echo statement

---
 .../fixes/bash/accounts_maximum_age_login_defs.sh  |    2 +-
 .../fixes/bash/accounts_minimum_age_login_defs.sh  |    2 +-
 .../bash/accounts_password_minlen_login_defs.sh    |    2 +-
 .../bash/accounts_password_warn_age_login_defs.sh  |    2 +-
 4 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/RHEL6/input/fixes/bash/accounts_maximum_age_login_defs.sh b/RHEL6/input/fixes/bash/accounts_maximum_age_login_defs.sh
index 968b7c0..7daa487 100644
--- a/RHEL6/input/fixes/bash/accounts_maximum_age_login_defs.sh
+++ b/RHEL6/input/fixes/bash/accounts_maximum_age_login_defs.sh
@@ -4,5 +4,5 @@ populate var_password_max_age
 grep -q ^PASS_MAX_DAYS /etc/login.defs && \
   sed -i "s/PASS_MAX_DAYS.*/PASS_MAX_DAYS     $var_password_max_age/g" /etc/login.defs
 if ! [ $? -eq 0 ]; then
-    echo "PASS_MAX_DAYS      $var_password_max_age"
+    echo "PASS_MAX_DAYS      $var_password_max_age" >> /etc/login.defs
 fi
diff --git a/RHEL6/input/fixes/bash/accounts_minimum_age_login_defs.sh b/RHEL6/input/fixes/bash/accounts_minimum_age_login_defs.sh
index 245267e..1c4a136 100644
--- a/RHEL6/input/fixes/bash/accounts_minimum_age_login_defs.sh
+++ b/RHEL6/input/fixes/bash/accounts_minimum_age_login_defs.sh
@@ -4,5 +4,5 @@ populate var_password_min_age
 grep -q ^PASS_MIN_AGE /etc/login.defs && \
   sed -i "s/PASS_MIN_AGE.*/PASS_MIN_AGE     $var_password_min_age/g" /etc/login.defs
 if ! [ $? -eq 0 ]; then
-    echo "PASS_MIN_AGE      $var_password_min_age"
+    echo "PASS_MIN_AGE      $var_password_min_age" >> /etc/login.defs
 fi
diff --git a/RHEL6/input/fixes/bash/accounts_password_minlen_login_defs.sh b/RHEL6/input/fixes/bash/accounts_password_minlen_login_defs.sh
index 401cef1..69b50e5 100644
--- a/RHEL6/input/fixes/bash/accounts_password_minlen_login_defs.sh
+++ b/RHEL6/input/fixes/bash/accounts_password_minlen_login_defs.sh
@@ -4,5 +4,5 @@ populate var_password_min_len
 grep -q ^PASS_MIN_LEN /etc/login.defs && \
   sed -i "s/PASS_MIN_LEN.*/PASS_MIN_LEN     $var_password_min_len/g" /etc/login.defs
 if ! [ $? -eq 0 ]; then
-    echo "PASS_MIN_LEN      $var_password_min_len"
+    echo "PASS_MIN_LEN      $var_password_min_len" >> /etc/login.defs
 fi
diff --git a/RHEL6/input/fixes/bash/accounts_password_warn_age_login_defs.sh b/RHEL6/input/fixes/bash/accounts_password_warn_age_login_defs.sh
index 0437705..6377bcc 100644
--- a/RHEL6/input/fixes/bash/accounts_password_warn_age_login_defs.sh
+++ b/RHEL6/input/fixes/bash/accounts_password_warn_age_login_defs.sh
@@ -4,5 +4,5 @@ populate var_password_warn_age
 grep -q ^PASS_WARN_DAYS /etc/login.defs && \
   sed -i "s/PASS_WARN_DAYS.*/PASS_WARN_DAYS     $var_password_warn_age/g" /etc/login.defs
 if ! [ $? -eq 0 ]; then
-    echo "PASS_WARN_DAYS      $var_password_warn_age"
+    echo "PASS_WARN_DAYS      $var_password_warn_age" >> /etc/login.defs
 fi
-- 
1.7.1



More information about the scap-security-guide mailing list