<div dir="ltr"><div><div>Hello,<br><br></div>       Just wondering if someone can review this as I would like to push it soon if it is ack&#39;ed.<br><br></div>Thanks,<br><br>Gabe<br></div><div class="gmail_extra"><br><br>
<div class="gmail_quote">On Tue, Aug 5, 2014 at 4:29 PM, Gabe <span dir="ltr">&lt;<a href="mailto:redhatrises@gmail.com" target="_blank">redhatrises@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
- add aide oval check to check /etc/crontab and files in /etc/cron.d/<br>
- add aide bash fix<br>
- enable aide oval check in scan<br>
<br>
Signed-off-by: Gabe &lt;<a href="mailto:redhatrises@gmail.com">redhatrises@gmail.com</a>&gt;<br>
---<br>
 .../6/input/checks/aide_periodic_cron_checking.xml | 39 ++++++++++++++++++++++<br>
 .../fixes/bash/aide_periodic_cron_checking.sh      |  1 +<br>
 RHEL/6/input/system/software/integrity.xml         |  1 +<br>
 3 files changed, 41 insertions(+)<br>
 create mode 100644 RHEL/6/input/checks/aide_periodic_cron_checking.xml<br>
 create mode 100644 RHEL/6/input/fixes/bash/aide_periodic_cron_checking.sh<br>
<br>
diff --git a/RHEL/6/input/checks/aide_periodic_cron_checking.xml b/RHEL/6/input/checks/aide_periodic_cron_checking.xml<br>
new file mode 100644<br>
index 0000000..4a4dbff<br>
--- /dev/null<br>
+++ b/RHEL/6/input/checks/aide_periodic_cron_checking.xml<br>
@@ -0,0 +1,39 @@<br>
+&lt;def-group&gt;<br>
+  &lt;definition class=&quot;compliance&quot; id=&quot;aide_periodic_cron_checking&quot; version=&quot;1&quot;&gt;<br>
+    &lt;metadata&gt;<br>
+      &lt;title&gt;Configure Periodic Execution of AIDE&lt;/title&gt;<br>
+      &lt;affected family=&quot;unix&quot;&gt;<br>
+        &lt;platform&gt;Red Hat Enterprise Linux 6&lt;/platform&gt;<br>
+      &lt;/affected&gt;<br>
+      &lt;description&gt;By default, AIDE does not install itself for periodic<br>
+      execution. Periodically running AIDE is necessary to reveal<br>
+      unexpected changes in installed files.<br>
+      &lt;/description&gt;<br>
+      &lt;reference source=&quot;MED&quot; ref_id=&quot;20130928&quot; ref_url=&quot;test_attestation&quot; /&gt;<br>
+    &lt;/metadata&gt;<br>
+    &lt;criteria operator=&quot;OR&quot;&gt;<br>
+      &lt;extend_definition comment=&quot;Aide is installed&quot; negate=&quot;true&quot; definition_ref=&quot;package_aide_installed&quot; /&gt;<br>
+      &lt;criterion comment=&quot;run aide daily with cron&quot; test_ref=&quot;test_aide_periodic_cron_checking&quot; /&gt;<br>
+      &lt;criterion comment=&quot;run aide daily with cron&quot; test_ref=&quot;test_aide_crond_checking&quot; /&gt;<br>
+    &lt;/criteria&gt;<br>
+  &lt;/definition&gt;<br>
+<br>
+  &lt;ind:textfilecontent54_test check=&quot;all&quot; check_existence=&quot;all_exist&quot; comment=&quot;run aide daily with cron&quot; id=&quot;test_aide_periodic_cron_checking&quot; version=&quot;1&quot;&gt;<br>
+    &lt;ind:object object_ref=&quot;object_test_aide_periodic_cron_checking&quot; /&gt;<br>
+  &lt;/ind:textfilecontent54_test&gt;<br>
+  &lt;ind:textfilecontent54_object comment=&quot;run aide daily with cron&quot; id=&quot;object_test_aide_periodic_cron_checking&quot; version=&quot;1&quot;&gt;<br>
+    &lt;ind:filepath&gt;/etc/crontab&lt;/ind:filepath&gt;<br>
+    &lt;ind:pattern operation=&quot;pattern match&quot;&gt;^[0-9]*[\s]*[0-9]*[\s]*\*[\s]*\*[\s]*\*[\s]*root[\s]*/usr/sbin/aide[\s]*\-\-check+$&lt;/ind:pattern&gt;<br>
+    &lt;ind:instance datatype=&quot;int&quot; operation=&quot;greater than or equal&quot;&gt;1&lt;/ind:instance&gt;<br>
+  &lt;/ind:textfilecontent54_object&gt;<br>
+<br>
+  &lt;ind:textfilecontent54_test check=&quot;all&quot; check_existence=&quot;all_exist&quot; comment=&quot;run aide daily with cron&quot; id=&quot;test_aide_crond_checking&quot; version=&quot;1&quot;&gt;<br>
+    &lt;ind:object object_ref=&quot;object_test_aide_crond_checking&quot; /&gt;<br>
+  &lt;/ind:textfilecontent54_test&gt;<br>
+  &lt;ind:textfilecontent54_object comment=&quot;run aide daily with cron&quot; id=&quot;object_test_aide_crond_checking&quot; version=&quot;1&quot;&gt;<br>
+    &lt;ind:path&gt;/etc/cron.d&lt;/ind:path&gt;<br>
+    &lt;ind:filename operation=&quot;pattern match&quot;&gt;^.*$&lt;/ind:filename&gt;<br>
+    &lt;ind:pattern operation=&quot;pattern match&quot;&gt;^[0-9]*[\s]*[0-9]*[\s]*\*[\s]*\*[\s]*\*[\s]*root[\s]*/usr/sbin/aide[\s]*\-\-check+$&lt;/ind:pattern&gt;<br>
+    &lt;ind:instance datatype=&quot;int&quot; operation=&quot;greater than or equal&quot;&gt;1&lt;/ind:instance&gt;<br>
+  &lt;/ind:textfilecontent54_object&gt;<br>
+&lt;/def-group&gt;<br>
diff --git a/RHEL/6/input/fixes/bash/aide_periodic_cron_checking.sh b/RHEL/6/input/fixes/bash/aide_periodic_cron_checking.sh<br>
new file mode 100644<br>
index 0000000..f62ef72<br>
--- /dev/null<br>
+++ b/RHEL/6/input/fixes/bash/aide_periodic_cron_checking.sh<br>
@@ -0,0 +1 @@<br>
+echo &quot;05 4 * * * root /usr/sbin/aide --check&quot; &gt;&gt; /etc/crontab<br>
diff --git a/RHEL/6/input/system/software/integrity.xml b/RHEL/6/input/system/software/integrity.xml<br>
index 55bf115..ab9f44d 100644<br>
--- a/RHEL/6/input/system/software/integrity.xml<br>
+++ b/RHEL/6/input/system/software/integrity.xml<br>
@@ -100,6 +100,7 @@ To determine that periodic AIDE execution has been scheduled, run the following<br>
 By default, AIDE does not install itself for periodic execution. Periodically<br>
 running AIDE is necessary to reveal unexpected changes in installed files.<br>
 &lt;/rationale&gt;<br>
+&lt;oval id=&quot;aide_periodic_cron_checking&quot; /&gt;<br>
 &lt;ident cce=&quot;27222-9&quot; /&gt;<br>
 &lt;ref nist=&quot;CM-3(d),CM-3(e),CM-6(d),CM-6(3),SC-28,SI-7&quot; disa=&quot;374,416,1069,1263,1297,1589&quot;/&gt;<br>
 &lt;/Rule&gt;<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.0.0<br>
<br>
</font></span></blockquote></div><br></div>