[PATCH] fixed bug which unnecessarily prepended "oval:" to IDs

Jeffrey Blank blank at eclipse.ncsc.mil
Tue Feb 5 20:41:19 UTC 2013


Signed-off-by: Jeffrey Blank <blank at eclipse.ncsc.mil>
---
 RHEL6/input/checks/testcheck.py |   10 +---------
 1 files changed, 1 insertions(+), 9 deletions(-)

diff --git a/RHEL6/input/checks/testcheck.py b/RHEL6/input/checks/testcheck.py
index 3b410dd..66b8381 100755
--- a/RHEL6/input/checks/testcheck.py
+++ b/RHEL6/input/checks/testcheck.py
@@ -102,20 +102,12 @@ def main():
             if element.getchildren():
                 ovaltree.append(element)
         # re-map all the element ids from meaningful names to meaningless numbers
-        testtranslator = idtranslate.idtranslator("testids.ini", "oval:scap-security-guide.testing")
+        testtranslator = idtranslate.idtranslator("testids.ini", "scap-security-guide.testing")
         ovaltree = testtranslator.translate(ovaltree)
         (ovalfile, fname) = tempfile.mkstemp(prefix=defname,suffix=".xml")
         os.write(ovalfile, ET.tostring(ovaltree))
         os.close(ovalfile)
         print "Evaluating with OVAL tempfile : " + fname
-	# temporary workaround for fedora/redhat oscap version differences
-        # (distname, distversion, distcodename) = platform.linux_distribution(full_distribution_name=0)
-        # if distname == 'redhat':
-        #    subprocess.call("oscap oval eval --result-file "+ fname + "-results " + fname, shell=True)
-        # else:
-
-        # content requires OVAL 5.8 support, which is only supported by openscap 0.8 or later
-        # for RHEL 6, this implies installing openscap from source until RPM is released
         subprocess.call("oscap oval eval --results "+ fname + "-results " + fname, shell=True)
         # perhaps delete tempfile?
         definitions = ET.Element("definitions")
-- 
1.7.1



More information about the scap-security-guide mailing list