<?xml version="1.0"?>
<ns0:data-stream-collection xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:html="http://www.w3.org/1999/xhtml" xmlns:ns0="http://scap.nist.gov/schema/scap/source/1.2" xmlns:ns1="http://www.w3.org/1999/xlink" xmlns:ns12="http://cpe.mitre.org/dictionary/2.0" xmlns:ns2="urn:oasis:names:tc:entity:xmlns:xml:catalog" xmlns:ns3="http://oval.mitre.org/XMLSchema/oval-definitions-5" xmlns:ns5="http://oval.mitre.org/XMLSchema/oval-common-5" xmlns:ns6="http://oval.mitre.org/XMLSchema/oval-definitions-5#independent" xmlns:ns7="http://oval.mitre.org/XMLSchema/oval-definitions-5#linux" xmlns:ns8="http://scap.nist.gov/schema/ocil/2.0" xmlns:ns9="http://checklists.nist.gov/xccdf/1.2" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="scap_org.open-scap_collection_from_xccdf_ssg-firefox-xccdf-1.2.xml" schematron-version="1.3">
  <ns0:data-stream id="scap_org.open-scap_datastream_from_xccdf_ssg-firefox-xccdf-1.2.xml" scap-version="1.3" use-case="OTHER">
    <ns0:dictionaries>
      <ns0:component-ref id="scap_org.open-scap_cref_ssg-firefox-cpe-dictionary.xml" ns1:href="#scap_org.open-scap_comp_ssg-firefox-cpe-dictionary.xml">
        <ns2:catalog>
          <ns2:uri name="ssg-firefox-cpe-oval.xml" uri="#scap_org.open-scap_cref_ssg-firefox-cpe-oval.xml"/>
        </ns2:catalog>
      </ns0:component-ref>
    </ns0:dictionaries>
    <ns0:checklists>
      <ns0:component-ref id="scap_org.open-scap_cref_ssg-firefox-xccdf-1.2.xml" ns1:href="#scap_org.open-scap_comp_ssg-firefox-xccdf-1.2.xml">
        <ns2:catalog>
          <ns2:uri name="ssg-firefox-oval.xml" uri="#scap_org.open-scap_cref_ssg-firefox-oval.xml"/>
          <ns2:uri name="ssg-firefox-ocil.xml" uri="#scap_org.open-scap_cref_ssg-firefox-ocil.xml"/>
        </ns2:catalog>
      </ns0:component-ref>
    </ns0:checklists>
    <ns0:checks>
      <ns0:component-ref id="scap_org.open-scap_cref_ssg-firefox-oval.xml" ns1:href="#scap_org.open-scap_comp_ssg-firefox-oval.xml"/>
      <ns0:component-ref id="scap_org.open-scap_cref_ssg-firefox-ocil.xml" ns1:href="#scap_org.open-scap_comp_ssg-firefox-ocil.xml"/>
      <ns0:component-ref id="scap_org.open-scap_cref_ssg-firefox-cpe-oval.xml" ns1:href="#scap_org.open-scap_comp_ssg-firefox-cpe-oval.xml"/>
    </ns0:checks>
  </ns0:data-stream>
  <ns0:component id="scap_org.open-scap_comp_ssg-firefox-oval.xml" timestamp="2020-01-16T13:55:21">
    <ns3:oval_definitions xsi:schemaLocation="http://oval.mitre.org/XMLSchema/oval-common-5 oval-common-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5 oval-definitions-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5#independent independent-definitions-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5#unix unix-definitions-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5#linux linux-definitions-schema.xsd">
      <ns3:generator>
        <ns5:product_name>combine_ovals.py from SCAP Security Guide</ns5:product_name>
        <ns5:product_version>ssg: [0, 1, 48], python: 3.7.6</ns5:product_version>
        <ns5:schema_version>5.11</ns5:schema_version>
        <ns5:timestamp>2020-01-16T13:51:04</ns5:timestamp>
      </ns3:generator>
      <ns3:definitions>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-verification:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Enable Certificate Verification</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>When a web site asks for a certificate for user authentication, Firefox must be configured to have the user choose which certificate to present. Websites within DOD require user authentication for access which increases security for DoD information. Access will be denied to the user if certificate management is not configured</ns3:description>
            <ns3:reference ref_id="firefox_preferences-verification" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="verification installed" test_ref="oval:ssg-test_firefox_preferences-verification:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-ssl_protocol_tls:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Enable TLS Usage in Firefox</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>DoD implementations of SSL must use TLS 1.0 in accordance with
      the Network Infrastructure STIG.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-ssl_protocol_tls" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="TLS is enabled" test_ref="oval:ssg-test_firefox_preferences-ssl_protocol_tls:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-javascript_context_menus:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable JavaScript Context Menus</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox should be configured to not allow JavaScript to
      disable or replace context menus.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-javascript_context_menus" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="disable javaScript context menus" test_ref="oval:ssg-test_firefox_preferences-javascript_context_menus:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-javascript_window_changes:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable JavaScript's Raise Or Lower Windows Capability</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox should be configured to not allow JavaScript to
      raise or lower windows.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-javascript_window_changes" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="raise or lower windows disabled" test_ref="oval:ssg-test_firefox_preferences-javascript_window_changes:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-home_page:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Default Firefox Home Page Configured</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>The default homepage for Firefox is set and cannot be changed.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-home_page" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="home page configured" test_ref="oval:ssg-test_firefox_preferences-home_page:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-pop-up_windows:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Enable Firefox Pop-up Blocker</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>The Firefox Pop-up blocker should be enabled as windows may be
      used to launch an attack within a new browser window with altered settings.
      </ns3:description>
            <ns3:reference ref_id="firefox_preferences-pop-up_windows" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="pop-up_windows installed" test_ref="oval:ssg-test_firefox_preferences-pop-up_windows:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-installed_firefox_version_supported:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Supported Version of Firefox Installed</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Use of versions of an application which are not
      supported by the vendor are not permitted. Vendors respond to
      security flaws with updates and patches. These updates are not
      available for unsupported versions which can leave the application
      vulnerable to attack.</ns3:description>
            <ns3:reference ref_id="installed_firefox_version_supported" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="installed version of firefox supported" test_ref="oval:ssg-test_supported_version_of_firefox:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-search_update:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable Installed Search Plugins Update Checking</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Search plugins can be automatically configured to check for
      updates. Updates need to be controlled and installed from authorized and
      trusted servers.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-search_update" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Disable search plugin update capability" test_ref="oval:ssg-test_firefox_preferences-search_update:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-non-secure_page_warning:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Enable Non-Secure Page Warnings</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox is not configured to provide warnings when a user switches
      from a secure (SSL-enabled) to a non-secure page.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-non-secure_page_warning" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="non-secure page warning configured" test_ref="oval:ssg-test_firefox_preferences-non-secure_page_warning:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-auto-download_actions:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable Automatic Downloads of MIME Types</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox automatically executes or downloads MIME types which are
      not authorized for auto-download.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-auto-download_actions" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Auto download actions of mime type is disabled" test_ref="oval:ssg-test_firefox_preferences-auto-download_actions:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-javascript_window_resizing:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable JavaScript's Moving Or Resizing Windows Capability</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>FireFox should not be configured to allow JavaScript to move
      or resize windows.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-javascript_window_resizing" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="move or resize windows disabled" test_ref="oval:ssg-test_firefox_preferences-javascript_window_resizing:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-shell_protocol:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable Firefox Access to Shell Protocols</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox can be configured to access systems shells which
      could potentially allow Firefox and other users to access to the
      underlying system.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-shell_protocol" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Disable Firefox Shell Protocol Access" test_ref="oval:ssg-test_firefox_preferences-shell_protocol:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-password_store:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable the Firefox Password Store</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>The Firefox password store should be disabled.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-password_store" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="password_store disabled" test_ref="oval:ssg-test_firefox_preferences-password_store:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-open_confirmation:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Enable Downloading and Opening File Confirmation</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox is not configured to prompt user before downloading and
      opening required file types.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-open_confirmation" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="open_confirmation configured" test_ref="oval:ssg-test_firefox_preferences-open_confirmation:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-ssl_version_3:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable SSL Version 3 in Firefox</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Earlier versions of SSL have known security vulnerabilities
      and are not authorized for use in DOD.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-ssl_version_3" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="SSL V3 installed" test_ref="oval:ssg-test_firefox_preferences-ssl_version_3:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-addons_plugin_updates:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable Addons Plugin Updates</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox automatically updates installed
      add-ons and plugins.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-addons_plugin_updates" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="addons plugin updates configured" test_ref="oval:ssg-test_firefox_preferences-addons_plugin_updates:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-ssl_version_2:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable SSL Version 2.0 in Firefox</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>SSL 2.0 and SSL 3.0 contain a number of security flaws.
      Therefore, SSL 2.0 should be disabled.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-ssl_version_2" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="SSL 2.0 protocol disabled" test_ref="oval:ssg-test_firefox_preferences-ssl_version_2:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-autofill_passwords:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable User Ability To Autofill Passwords</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox should not be configured to autofill passwords.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-autofill_passwords" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="autofill_passwords disabled" test_ref="oval:ssg-test_firefox_preferences-autofill_passwords:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-javascript_status_bar_changes:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable JavaScript's Ability To Change The Status Bar</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox should be configured to not allow JavaScript to
      hide or change the status bar.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-javascript_status_bar_changes" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="disable hiding or changing status bar menus" test_ref="oval:ssg-test_firefox_preferences-javascript_status_bar_changes:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-javascript_status_bar_text:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable JavaScript's Ability To Modify The Browser Appearance</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox should be configured not to allow JavaScript
      to change the status bar text.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-javascript_status_bar_text" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="disable changing the status bar text" test_ref="oval:ssg-test_firefox_preferences-javascript_status_bar_text:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-auto-update_of_firefox:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable Firefox Auto-Update Capability</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox should not be able to automatically
      update itself.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-auto-update_of_firefox" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="auto-update is disabled" test_ref="oval:ssg-test_firefox_preferences-auto-update_of_firefox:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-autofill_forms:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable Autofill Form Assistance</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Firefox formfill assistance option is disabled.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-autofill_forms" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="autofill_forms disabled" test_ref="oval:ssg-test_firefox_preferences-autofill_forms:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-cookies_clear:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Clear Cookies And Other Data When Firefox Closes</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Set browser preferences to perform a Clear Private Data
      operation when closing the browser in order to clear cookies and other
      data installed by websites visited during the session.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-cookies_clear" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="enabled sanitizeOnShutdown" test_ref="oval:ssg-test_firefox_preferences-cookies_shutdown_sanitize:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-cookies_user_notice:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Disable User Prompt For Clearing Cookies And Other Data</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Users should not be prompted about data and cookies being
      cleared when the browser is closed.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-cookies_user_notice" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="disable promptOnSanitize" test_ref="oval:ssg-test_firefox_preferences-cookies_sanitize_prompt:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-lock_settings_obscure:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Prevent Users from Changing Firefox Configuration Settings</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Locked settings prevents users from accessing about:config and
      changing the security settings set by the system administrator.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-lock_settings_obscure" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Do not obscure locked file content with ROT-13" test_ref="oval:ssg-test_firefox_preferences-obscure_value:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="compliance" id="oval:ssg-firefox_preferences-lock_settings_config_file:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Prevent Users from Changing Firefox Configuration Settings</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>Locked settings prevents users from accessing about:config and
      changing the security settings set by the system administrator.</ns3:description>
            <ns3:reference ref_id="firefox_preferences-lock_settings_config_file" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Configuration file is set" test_ref="oval:ssg-test_firefox_preferences-config_filename:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="inventory" id="oval:ssg-installed_app_is_firefox:def:1" version="2">
          <ns3:metadata>
            <ns3:title>Mozilla Firefox</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:reference ref_id="cpe:/a:mozilla:firefox" source="CPE"/>
            <ns3:description>The application installed on the system is firefox.</ns3:description>
            <ns3:reference ref_id="installed_app_is_firefox" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria operator="AND">
            <ns3:extend_definition comment="Installed OS is part of the Unix family" definition_ref="oval:ssg-installed_OS_is_part_of_Unix_family:def:1"/>
            <ns3:criterion comment="Firefox is installed" test_ref="oval:ssg-test_firefox:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="inventory" id="oval:ssg-installed_OS_is_part_of_Unix_family:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Installed operating system is part of the Unix family</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>The operating system installed on the system is part of the Unix OS family</ns3:description>
            <ns3:reference ref_id="installed_OS_is_part_of_Unix_family" source="ssg"/>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Installed operating system is part of the unix family" test_ref="oval:ssg-test_unix_family:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
      </ns3:definitions>
      <ns3:tests>
        <ns6:textfilecontent54_test check="all" comment="Enable Certification verification" id="oval:ssg-test_firefox_preferences-verification:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-verification:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check if TLS is enabled" id="oval:ssg-test_firefox_preferences-ssl_protocol_tls:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-ssl_protocol_tls:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for disable javaScript context menu is disabled" id="oval:ssg-test_firefox_preferences-javascript_context_menus:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-javascript_context_menus:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="raise or lower windows is disabled" id="oval:ssg-test_firefox_preferences-javascript_window_changes:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-javascript_window_changes:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for home page configured" id="oval:ssg-test_firefox_preferences-home_page:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-home_page:obj:1"/>
          <ns6:state state_ref="oval:ssg-state_firefox_preferences-home_page:ste:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for pop-up_windows installed" id="oval:ssg-test_firefox_preferences-pop-up_windows:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-pop-up_windows:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns7:rpminfo_test check="all" check_existence="any_exist" comment="Installed version of firefox is greater than ESR 31.5" id="oval:ssg-test_supported_version_of_firefox:tst:1" version="1">
          <ns7:object object_ref="oval:ssg-obj_supported_version_of_firefox:obj:1"/>
          <ns7:state state_ref="oval:ssg-state_supported_version_of_firefox:ste:1"/>
        </ns7:rpminfo_test>
        <ns6:textfilecontent54_test check="all" comment="Check search plugin update capability is disabled" id="oval:ssg-test_firefox_preferences-search_update:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-search_update:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for non-secure page warning configured" id="oval:ssg-test_firefox_preferences-non-secure_page_warning:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-non-secure_page_warning:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for Auto download Actions installed" id="oval:ssg-test_firefox_preferences-auto-download_actions:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-auto-download_actions:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for move or resize windows disabled" id="oval:ssg-test_firefox_preferences-javascript_window_resizing:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-javascript_window_resizing:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check that the hell_protocol is disabled" id="oval:ssg-test_firefox_preferences-shell_protocol:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-shell_protocol:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check that the password_store is disabled" id="oval:ssg-test_firefox_preferences-password_store:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-password_store:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for open_confirmation configured" id="oval:ssg-test_firefox_preferences-open_confirmation:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-open_confirmation:obj:1"/>
          <ns6:state state_ref="oval:ssg-state_firefox_preferences-open_confirmation:ste:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for SSL Version 3 preferences" id="oval:ssg-test_firefox_preferences-ssl_version_3:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-ssl_version_3:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for addons plugin updates" id="oval:ssg-test_firefox_preferences-addons_plugin_updates:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-addons_plugin_updates:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check SSL 2.0 protocol disabled" id="oval:ssg-test_firefox_preferences-ssl_version_2:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-ssl_version_2:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for autofill_passwords disabled" id="oval:ssg-test_firefox_preferences-autofill_passwords:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-autofill_passwords:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check that hiding or changing status bar is disabled" id="oval:ssg-test_firefox_preferences-javascript_status_bar_changes:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-javascript_status_bar_changes:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check that changing the status bar text is disabled" id="oval:ssg-test_firefox_preferences-javascript_status_bar_text:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-javascript_status_bar_text:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check that auto-update of firefox is disabled" id="oval:ssg-test_firefox_preferences-auto-update_of_firefox:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-auto-update_of_firefox:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for autofill_forms disabled" id="oval:ssg-test_firefox_preferences-autofill_forms:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-autofill_forms:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for sanitizeOnShutdown enabled" id="oval:ssg-test_firefox_preferences-cookies_shutdown_sanitize:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-cookies_shutdown_sanitize:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for promptOnSanitize disabled" id="oval:ssg-test_firefox_preferences-cookies_sanitize_prompt:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-cookies_sanitize_prompt:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for obscure_value" id="oval:ssg-test_firefox_preferences-obscure_value:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-obscure_value:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns6:textfilecontent54_test check="all" comment="Check for configuration filename" id="oval:ssg-test_firefox_preferences-config_filename:tst:1" version="2">
          <ns6:object object_ref="oval:ssg-object_firefox_preferences-config_filename:obj:1"/>
        </ns6:textfilecontent54_test>
        <ns7:rpminfo_test check="all" check_existence="at_least_one_exists" comment="Firefox is installed" id="oval:ssg-test_firefox:tst:1" version="1">
          <ns7:object object_ref="oval:ssg-obj_firefox:obj:1"/>
        </ns7:rpminfo_test>
        <ns6:family_test check="all" check_existence="at_least_one_exists" comment="Test installed OS is part of the unix family" id="oval:ssg-test_unix_family:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_unix_family:obj:1"/>
          <ns6:state state_ref="oval:ssg-state_unix_family:ste:1"/>
        </ns6:family_test>
      </ns3:tests>
      <ns3:objects>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-verification:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("security.default_personal_cert",[\s]+"Ask Every Time"\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-ssl_protocol_tls:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("security.enable_tls",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-javascript_context_menus:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("dom.event.contextmenu.enabled",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-javascript_window_changes:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("dom.disable_window_flip",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-home_page:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("browser.startup.homepage",[\s]+"(\S+)"\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-pop-up_windows:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("dom.disable_window_open_feature.status",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns7:rpminfo_object id="oval:ssg-obj_supported_version_of_firefox:obj:1" version="1">
          <ns7:name>firefox</ns7:name>
        </ns7:rpminfo_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-search_update:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("browser.search.update",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-non-secure_page_warning:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("security.warn_leaving_secure",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-auto-download_actions:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("browser.helperApps.alwaysAsk.force",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-javascript_window_resizing:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("dom.disable_window_move_resize",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-shell_protocol:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("network.protocol-handler.external.shell",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-password_store:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("signon.rememberSignons",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-open_confirmation:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("plugin.disable_full_page_plugin_for_types",[\s]+"(\S+)"\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-ssl_version_3:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("security.enable_ssl3",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-addons_plugin_updates:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("extensions.update.enabled",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-ssl_version_2:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("security.enable_ssl2",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-autofill_passwords:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("signon.prefillForms",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-javascript_status_bar_changes:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("dom.disable_window_status_change",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-javascript_status_bar_text:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("dom.disable_window_open_feature.status",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-auto-update_of_firefox:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("app.update.enabled",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-autofill_forms:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("browser.formfill.enable",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-cookies_shutdown_sanitize:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("privacy.sanitize.sanitizeOnShutdown",[\s]+true\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-cookies_sanitize_prompt:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox</ns6:path>
          <ns6:filename operation="pattern match">^.*\.cfg$</ns6:filename>
          <ns6:pattern operation="pattern match">^lockPref\("privacy.sanitize.promptOnSanitize",[\s]+false\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-obscure_value:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox\/defaults\/(preferences|pref)</ns6:path>
          <ns6:filename operation="pattern match">^.*\.js$</ns6:filename>
          <ns6:pattern operation="pattern match">^pref\("general.config.obscure_value",[\s]+0\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns6:textfilecontent54_object id="oval:ssg-object_firefox_preferences-config_filename:obj:1" version="1">
          <ns6:path operation="pattern match">^\/usr\/(|local\/)lib(|64)\/firefox\/defaults\/(preferences|pref)</ns6:path>
          <ns6:filename operation="pattern match">^.*\.js$</ns6:filename>
          <ns6:pattern operation="pattern match">^pref\("general.config.filename",[\s]+"(\S+)\.cfg"\);$</ns6:pattern>
          <ns6:instance datatype="int">1</ns6:instance>
        </ns6:textfilecontent54_object>
        <ns7:rpminfo_object id="oval:ssg-obj_firefox:obj:1" version="1">
          <ns7:name>firefox</ns7:name>
        </ns7:rpminfo_object>
        <ns6:family_object id="oval:ssg-object_unix_family:obj:1" version="1"/>
      </ns3:objects>
      <ns3:states>
        <ns6:textfilecontent54_state id="oval:ssg-state_firefox_preferences-home_page:ste:1" version="1">
          <ns6:subexpression datatype="string" operation="equals" var_check="all" var_ref="oval:ssg-var_default_home_page:var:1"/>
        </ns6:textfilecontent54_state>
        <ns7:rpminfo_state id="oval:ssg-state_supported_version_of_firefox:ste:1" version="1">
          <ns7:evr datatype="evr_string" operation="greater than">3.0.0</ns7:evr>
        </ns7:rpminfo_state>
        <ns6:textfilecontent54_state id="oval:ssg-state_firefox_preferences-open_confirmation:ste:1" version="1">
          <ns6:subexpression operation="equals" var_check="all" var_ref="oval:ssg-var_required_file_types:var:1"/>
        </ns6:textfilecontent54_state>
        <ns6:family_state id="oval:ssg-state_unix_family:ste:1" version="1">
          <ns6:family>unix</ns6:family>
        </ns6:family_state>
      </ns3:states>
      <ns3:variables>
        <ns3:external_variable comment="Expected default home page" datatype="string" id="oval:ssg-var_default_home_page:var:1" version="1"/>
        <ns3:external_variable comment="Expected file types" datatype="string" id="oval:ssg-var_required_file_types:var:1" version="1"/>
      </ns3:variables>
    </ns3:oval_definitions>
  </ns0:component>
  <ns0:component id="scap_org.open-scap_comp_ssg-firefox-ocil.xml" timestamp="2020-01-16T13:55:21">
    <ns8:ocil>
      <ns8:generator>
        <ns8:product_name>xccdf-create-ocil.xslt from SCAP Security Guide</ns8:product_name>
        <ns8:product_version>ssg: 0.1.48</ns8:product_version>
        <ns8:schema_version>2.0</ns8:schema_version>
        <ns8:timestamp>2020-01-16T00:00:00Z</ns8:timestamp>
      </ns8:generator>
      <ns8:questionnaires>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-home_page_ocil:questionnaire:1">
          <ns8:title>Default Firefox Home Page Configured</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-home_page_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-non-secure_page_warning_ocil:questionnaire:1">
          <ns8:title>Enable Non-Secure Page Warnings</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-non-secure_page_warning_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-ssl_version_3_ocil:questionnaire:1">
          <ns8:title>Disable SSL Version 3.0 in Firefox</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-ssl_version_3_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-password_store_ocil:questionnaire:1">
          <ns8:title>Disable the Firefox Password Store</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-password_store_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-installed_firefox_version_supported_ocil:questionnaire:1">
          <ns8:title>Supported Version of Firefox Installed</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-installed_firefox_version_supported_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-auto-download_actions_ocil:questionnaire:1">
          <ns8:title>Disable Automatic Downloads of MIME Types</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-auto-download_actions_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-javascript_context_menus_ocil:questionnaire:1">
          <ns8:title>Disable JavaScript Context Menus</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-javascript_context_menus_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-open_confirmation_ocil:questionnaire:1">
          <ns8:title>Enable Downloading and Opening File Confirmation</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-open_confirmation_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-verification_ocil:questionnaire:1">
          <ns8:title>Enable Certificate Verification</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-verification_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-javascript_window_resizing_ocil:questionnaire:1">
          <ns8:title>Disable JavaScript's Moving Or Resizing Windows Capability</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-javascript_window_resizing_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-search_update_ocil:questionnaire:1">
          <ns8:title>Disable Installed Search Plugins Update Checking</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-search_update_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-autofill_forms_ocil:questionnaire:1">
          <ns8:title>Disable Autofill Form Assistance</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-autofill_forms_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-shell_protocol_ocil:questionnaire:1">
          <ns8:title>Disable Firefox Access to Shell Protocols</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-shell_protocol_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-addons_plugin_updates_ocil:questionnaire:1">
          <ns8:title>Disable Addons Plugin Updates</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-addons_plugin_updates_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-autofill_passwords_ocil:questionnaire:1">
          <ns8:title>Disable User Ability To Autofill Passwords</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-autofill_passwords_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-ssl_version_2_ocil:questionnaire:1">
          <ns8:title>Disable SSL Version 2.0 in Firefox</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-ssl_version_2_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-ssl_protocol_tls_ocil:questionnaire:1">
          <ns8:title>Enable TLS Usage in Firefox</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-ssl_protocol_tls_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-javascript_status_bar_text_ocil:questionnaire:1">
          <ns8:title>Disable JavaScript's Ability To Modify The Browser Appearance</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-javascript_status_bar_text_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-javascript_window_changes_ocil:questionnaire:1">
          <ns8:title>Disable JavaScript's Raise Or Lower Windows Capability</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-javascript_window_changes_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-javascript_status_bar_changes_ocil:questionnaire:1">
          <ns8:title>Disable JavaScript's Ability To Change The Status Bar</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-javascript_status_bar_changes_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-auto-update_of_firefox_ocil:questionnaire:1">
          <ns8:title>Disable Firefox Auto-Update Capability</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-auto-update_of_firefox_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-pop-up_windows_ocil:questionnaire:1">
          <ns8:title>Enable Firefox Pop-up Blocker</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-pop-up_windows_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-lock_settings_config_file_ocil:questionnaire:1">
          <ns8:title>Set Firefox Configuration File Location</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-lock_settings_config_file_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-lock_settings_obscure_ocil:questionnaire:1">
          <ns8:title>Disable Firefox Configuration File ROT-13 Encoding</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-lock_settings_obscure_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-enable_ca_trust_ocil:questionnaire:1">
          <ns8:title>Enable Shared System Certificates</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-enable_ca_trust_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-dod_root_certificate_installed_ocil:questionnaire:1">
          <ns8:title>The DoD Root Certificate Exists</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-dod_root_certificate_installed_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-cookies_clear_ocil:questionnaire:1">
          <ns8:title>Clear Data When Firefox Closes</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-cookies_clear_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
        <ns8:questionnaire id="ocil:ssg-firefox_preferences-cookies_user_notice_ocil:questionnaire:1">
          <ns8:title>Disable User Prompt When Data Is Cleared</ns8:title>
          <ns8:actions>
            <ns8:test_action_ref>ocil:ssg-firefox_preferences-cookies_user_notice_action:testaction:1</ns8:test_action_ref>
          </ns8:actions>
        </ns8:questionnaire>
      </ns8:questionnaires>
      <ns8:test_actions>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-home_page_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-home_page_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-non-secure_page_warning_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-non-secure_page_warning_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-ssl_version_3_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-ssl_version_3_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-password_store_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-password_store_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-installed_firefox_version_supported_action:testaction:1" question_ref="ocil:ssg-installed_firefox_version_supported_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-auto-download_actions_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-auto-download_actions_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-javascript_context_menus_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-javascript_context_menus_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-open_confirmation_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-open_confirmation_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-verification_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-verification_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-javascript_window_resizing_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-javascript_window_resizing_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-search_update_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-search_update_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-autofill_forms_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-autofill_forms_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-shell_protocol_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-shell_protocol_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-addons_plugin_updates_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-addons_plugin_updates_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-autofill_passwords_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-autofill_passwords_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-ssl_version_2_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-ssl_version_2_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-ssl_protocol_tls_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-ssl_protocol_tls_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-javascript_status_bar_text_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-javascript_status_bar_text_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-javascript_window_changes_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-javascript_window_changes_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-javascript_status_bar_changes_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-javascript_status_bar_changes_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-auto-update_of_firefox_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-auto-update_of_firefox_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-pop-up_windows_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-pop-up_windows_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-lock_settings_config_file_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-lock_settings_config_file_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-lock_settings_obscure_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-lock_settings_obscure_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-enable_ca_trust_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-enable_ca_trust_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-dod_root_certificate_installed_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-dod_root_certificate_installed_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-cookies_clear_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-cookies_clear_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
        <ns8:boolean_question_test_action id="ocil:ssg-firefox_preferences-cookies_user_notice_action:testaction:1" question_ref="ocil:ssg-firefox_preferences-cookies_user_notice_question:question:1">
          <ns8:when_true>
            <ns8:result>PASS</ns8:result>
          </ns8:when_true>
          <ns8:when_false>
            <ns8:result>FAIL</ns8:result>
          </ns8:when_false>
        </ns8:boolean_question_test_action>
      </ns8:test_actions>
      <ns8:questions>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-home_page_question:question:1">
          <ns8:question_text>To verify that default home page is set,
run the following command:
$ grep 'browser.startup.homepage' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("browser.startup.homepage", "");
      Is it the case that it is not configured?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-non-secure_page_warning_question:question:1">
          <ns8:question_text>To verify that non-secure page warnings are enabled,
run the following command:
$ grep 'security.warn_leaving_secure' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("security.warn_leaving_secure", "true");
      Is it the case that it is not enabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-ssl_version_3_question:question:1">
          <ns8:question_text>To verify that SSL version 3 is disabled,
run the following command:
$ grep 'security.enable_ssl3' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("security.enable_ssl3", "false");
      Is it the case that it is not enabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-password_store_question:question:1">
          <ns8:question_text>To verify that the password store is disabled,
run the following command:
$ grep 'signon.rememberSignons' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("signon.rememberSignons", "false");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-installed_firefox_version_supported_question:question:1">
          <ns8:question_text>If the system is joined to the Red Hat Network, a Red Hat Satellite Server, or
a yum server which provides updates, invoking the following command will
indicate if updates are available:
$ sudo yum check-update
If the system is not configured to update from one of these sources,
run the following command to list when each package was last updated:
$ rpm -qa -last
Compare this to Red Hat Security Advisories (RHSA) listed at

    https://access.redhat.com/security/updates/active/https://access.redhat.com/security/updates/active/
to determine if the system is missing applicable updates.
      Is it the case that it is not updated?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-auto-download_actions_question:question:1">
          <ns8:question_text>To verify that user interaction is required for the downloading of MIME types,
run the following command:
$ grep 'browser.helperApps.alwaysAsk.force' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("browser.helperApps.alwaysAsk.force", "true");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-javascript_context_menus_question:question:1">
          <ns8:question_text>To verify that JavaScript cannot change context menus,
run the following command:
$ grep 'dom.event.contextmenu.enabled' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("dom.event.contextmenu.enabled", "false");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-open_confirmation_question:question:1">
          <ns8:question_text>To verify that downloading and opening file confirmation is enabled,
run the following command:
$ grep 'plugin.disable_full_page_plugin_for_types' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("plugin.disable_full_page_plugin_for_types", "");
      Is it the case that it is not set or application listing is incorrect?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-verification_question:question:1">
          <ns8:question_text>To verify that certificate verification is enabled, run the following command:
$ grep 'security.default_personal_cert' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("security.default_personal_cert", "Ask Every Time");
      Is it the case that it is not enabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-javascript_window_resizing_question:question:1">
          <ns8:question_text>To verify that JavaScript cannot change windows sizing,
run the following command:
$ grep 'dom.disable_window_move_resize' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("dom.disable_window_move_resize", "true");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-search_update_question:question:1">
          <ns8:question_text>To verify that search plugins cannot automatically update,
run the following command:
$ grep 'browser.search.update' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("browser.search.update", "false");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-autofill_forms_question:question:1">
          <ns8:question_text>To verify that Autofill Form Assistance is disabled,
run the following command:
$ grep 'browser.formfill.enable' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("browser.formfill.enable", false);
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-shell_protocol_question:question:1">
          <ns8:question_text>To verify that the shell protocol access is disabled,
run the following command:
$ grep 'network.protocol-handler.external.shell' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("network.protocol-handler.external.shell", "false");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-addons_plugin_updates_question:question:1">
          <ns8:question_text>To verify that add-ons and plugins cannot automatically update,
run the following command:
$ grep 'extensions.update.enabled' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("extensions.update.enabled", false);
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-autofill_passwords_question:question:1">
          <ns8:question_text>To verify that password autofill is disabled,
run the following command:
$ grep 'signon.prefillForms' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("signon.prefillForms", false);
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-ssl_version_2_question:question:1">
          <ns8:question_text>To verify that SSL version 2.0 is disabled,
run the following command:
$ grep 'security.enable_ssl2' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("security.enable_ssl2", "false");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-ssl_protocol_tls_question:question:1">
          <ns8:question_text>To verify that TLS is enabled, run the following command:
$ grep 'security.enable_tls' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("security.enable_tls", "true");
      Is it the case that it is not enabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-javascript_status_bar_text_question:question:1">
          <ns8:question_text>To verify that JavaScript cannot change the browser appearance,
run the following command:
$ grep 'dom.disable_window_open_feature.status' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("dom.disable_window_open_feature.status", "true");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-javascript_window_changes_question:question:1">
          <ns8:question_text>To verify that JavaScript cannot change windows sizing,
run the following command:
$ grep 'dom.disable_window_flip' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("dom.disable_window_flip", "true");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-javascript_status_bar_changes_question:question:1">
          <ns8:question_text>To verify that JavaScript cannot change the status bar,
run the following command:
$ grep 'dom.disable_window_status_change' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("dom.disable_window_status_change", "true");
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-auto-update_of_firefox_question:question:1">
          <ns8:question_text>To verify that Firefox cannot auto-update,
run the following command:
$ grep 'app.update.enable' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("app.update.enable", false);
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-pop-up_windows_question:question:1">
          <ns8:question_text>To verify that pop-up blocker is enabled,
run the following command:
$ grep 'dom.disable_window_open_feature.status' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("dom.disable_window_open_feature.status", "true");
      Is it the case that it is not enabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-lock_settings_config_file_question:question:1">
          <ns8:question_text>To verify that configuration filename is set, run the following command:
$ grep 'filename' FIREFOX_INSTALL_DIR/defaults/preferences/*.js
The output should return something similar to:
pref("general.config.filename", "mozilla.cfg");
      Is it the case that users can change mandatory settings?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-lock_settings_obscure_question:question:1">
          <ns8:question_text>To verify that ROT-13 encoding is disabled, run the following command:
$ grep 'obscure_value' FIREFOX_INSTALL_DIR/defaults/preferences/*.js
The output should return something similar to:
pref("general.config.obscure_value", 0);
      Is it the case that users can change mandatory settings?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-enable_ca_trust_question:question:1">
          <ns8:question_text>To verify that the central system cerificate authority store is enabled,
run the following command:
$ ls -l /etc/alternatives/libnssckbi.so.x86_64
The output should return something similar to:
lrwxrwxrwx. 1 root root 34 Apr 30 09:19 /etc/alternatives/libnssckbi.so.x86_64 -&gt; /usr/lib64/pkcs11/p11-kit-trust.so
      Is it the case that it is not enabled?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-dod_root_certificate_installed_question:question:1">
          <ns8:question_text>To verify that the DoD root certificate is installed,
list all certificates in /etc/pki/ca-trust/source/anchors
and compare them to the DoD root certificate. If there is a match
to the DoD root certificate, then the DoD root certificate is 
installed.
      Is it the case that it is not installed?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-cookies_clear_question:question:1">
          <ns8:question_text>To verify that Firefox clears data on exit,
run the following command:
$ grep 'privacy.sanitize.sanitizeOnShutdown' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("privacy.sanitize.sanitizeOnShutdown", true);
      Is it the case that it is not set to clear?
      </ns8:question_text>
        </ns8:boolean_question>
        <ns8:boolean_question id="ocil:ssg-firefox_preferences-cookies_user_notice_question:question:1">
          <ns8:question_text>To verify that Firefox does not prompt users about data being cleared,
run the following command:
$ grep 'privacy.sanitize.promptOnSanitize' FIREFOX_INSTALL_DIR/*.cfg
The output should return:
lockPref("privacy.sanitize.promptOnSanitize", false);
      Is it the case that it is not disabled?
      </ns8:question_text>
        </ns8:boolean_question>
      </ns8:questions>
    </ns8:ocil>
  </ns0:component>
  <ns0:component id="scap_org.open-scap_comp_ssg-firefox-xccdf-1.2.xml" timestamp="2020-01-16T13:55:38">
    <ns9:Benchmark id="xccdf_org.ssgproject.content_benchmark_FIREFOX" resolved="1" style="SCAP_1.2" xml:lang="en-US">
      <ns9:status date="2020-01-16">draft</ns9:status>
      <ns9:title xml:lang="en-US">Guide to the Secure Configuration of Firefox</ns9:title>
      <ns9:description xml:lang="en-US">This guide presents a catalog of security-relevant
configuration settings for Firefox. It is a rendering of
content structured in the eXtensible Configuration Checklist Description Format (XCCDF)
in order to support security automation.  The SCAP content is
is available in the <html:code>scap-security-guide</html:code> package which is developed at

    <html:a href="https://www.open-scap.org/security-policies/scap-security-guide">https://www.open-scap.org/security-policies/scap-security-guide</html:a>.
<html:br/><html:br/>
Providing system administrators with such guidance informs them how to securely
configure systems under their control in a variety of network roles. Policy
makers and baseline creators can use this catalog of settings, with its
associated references to higher-level security control catalogs, in order to
assist them in security baseline creation. This guide is a <html:em>catalog, not a
checklist</html:em>, and satisfaction of every item is not likely to be possible or
sensible in many operational scenarios. However, the XCCDF format enables
granular selection and adjustment of settings, and their association with OVAL
and OCIL content provides an automated checking capability. Transformations of
this document, and its associated automated checking content, are capable of
providing baselines that meet a diverse set of policy objectives. Some example
XCCDF <html:em>Profiles</html:em>, which are selections of items that form checklists and
can be used as baselines, are available with this guide. They can be
processed, in an automated fashion, with tools that support the Security
Content Automation Protocol (SCAP). The DISA STIG for Firefox,
which provides required settings for US Department of Defense systems, is
one example of a baseline created from this guidance.
</ns9:description>
      <ns9:notice id="terms_of_use" xml:lang="en-US">Do not attempt to implement any of the settings in
this guide without first testing them in a non-operational environment. The
creators of this guidance assume no responsibility whatsoever for its use by
other parties, and makes no guarantees, expressed or implied, about its
quality, reliability, or any other characteristic.
</ns9:notice>
      <ns9:front-matter xml:lang="en-US">The SCAP Security Guide Project<html:br/>

    <html:a href="https://www.open-scap.org/security-policies/scap-security-guide">https://www.open-scap.org/security-policies/scap-security-guide</html:a>
</ns9:front-matter>
      <ns9:rear-matter xml:lang="en-US">Red Hat and Red Hat Enterprise Linux are either registered
trademarks or trademarks of Red Hat, Inc. in the United States and other
countries. All other names are registered trademarks or trademarks of their
respective companies.
</ns9:rear-matter>
      <ns9:platform idref="cpe:/a:mozilla:firefox"/>
      <ns9:version update="https://github.com/OpenSCAP/scap-security-guide/releases/latest">0.1.48</ns9:version>
      <ns9:metadata>
        <dc:publisher>SCAP Security Guide Project</dc:publisher>
        <dc:creator>SCAP Security Guide Project</dc:creator>
        <dc:contributor>Frank J Cameron (CAM1244) &lt;cameron@ctc.com&gt;</dc:contributor>
        <dc:contributor>0x66656c6978 &lt;0x66656c6978@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Gabe Alford &lt;redhatrises@gmail.com&gt;</dc:contributor>
        <dc:contributor>Firas AlShafei &lt;firas.alshafei@us.abb.com&gt;</dc:contributor>
        <dc:contributor>Christopher Anderson &lt;cba@fedoraproject.org&gt;</dc:contributor>
        <dc:contributor>angystardust &lt;angystardust@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Chuck Atkins &lt;chuck.atkins@kitware.com&gt;</dc:contributor>
        <dc:contributor>Ryan Ballanger &lt;root@rballang-admin-2.fastenal.com&gt;</dc:contributor>
        <dc:contributor>Alex Baranowski &lt;alex@euro-linux.com&gt;</dc:contributor>
        <dc:contributor>Molly Jo Bault &lt;Molly.Jo.Bault@ballardtech.com&gt;</dc:contributor>
        <dc:contributor>Gabriel Becker &lt;ggasparb@redhat.com&gt;</dc:contributor>
        <dc:contributor>Alexander Bergmann &lt;abergmann@suse.com&gt;</dc:contributor>
        <dc:contributor>Jose Luis BG &lt;bgjoseluis@gmail.com&gt;</dc:contributor>
        <dc:contributor>Joseph Bisch &lt;joseph.bisch@gmail.com&gt;</dc:contributor>
        <dc:contributor>Jeffrey Blank &lt;blank@eclipse.ncsc.mil&gt;</dc:contributor>
        <dc:contributor>Olivier Bonhomme &lt;ptitoliv@ptitoliv.net&gt;</dc:contributor>
        <dc:contributor>Ted Brunell &lt;tbrunell@redhat.com&gt;</dc:contributor>
        <dc:contributor>Blake Burkhart &lt;blake.burkhart@us.af.mil&gt;</dc:contributor>
        <dc:contributor>Patrick Callahan &lt;pmc@patrickcallahan.com&gt;</dc:contributor>
        <dc:contributor>Nick Carboni &lt;ncarboni@redhat.com&gt;</dc:contributor>
        <dc:contributor>James Cassell &lt;james.cassell@ll.mit.edu&gt;</dc:contributor>
        <dc:contributor>Frank Caviggia &lt;fcaviggi@ra.iad.redhat.com&gt;</dc:contributor>
        <dc:contributor>Eric Christensen &lt;echriste@redhat.com&gt;</dc:contributor>
        <dc:contributor>Jayson Cofell &lt;1051437+70k10@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Caleb Cooper &lt;coopercd@ornl.gov&gt;</dc:contributor>
        <dc:contributor>Deric Crago &lt;deric.crago@gmail.com&gt;</dc:contributor>
        <dc:contributor>Maura Dailey &lt;maura@eclipse.ncsc.mil&gt;</dc:contributor>
        <dc:contributor>Klaas Demter &lt;demter@atix.de&gt;</dc:contributor>
        <dc:contributor>dhanushkar-wso2 &lt;dhanushkar@wso2.com&gt;</dc:contributor>
        <dc:contributor>Andrew DiPrinzio &lt;andrew.diprinzio@jhuapl.edu&gt;</dc:contributor>
        <dc:contributor>dom &lt;dominique.blaze@devinci.fr&gt;</dc:contributor>
        <dc:contributor>Jean-Baptiste Donnette &lt;jean-baptiste.donnette@epita.fr&gt;</dc:contributor>
        <dc:contributor>drax &lt;applezip@gmail.com&gt;</dc:contributor>
        <dc:contributor>Sebastian Dunne &lt;sdunne@redhat.com&gt;</dc:contributor>
        <dc:contributor>Greg Elin &lt;gregelin@gitmachines.com&gt;</dc:contributor>
        <dc:contributor>Alexis Facques &lt;alexis.facques@mythalesgroup.io&gt;</dc:contributor>
        <dc:contributor>Leah Fisher &lt;lfisher047@gmail.com&gt;</dc:contributor>
        <dc:contributor>Alijohn Ghassemlouei &lt;alijohn.ghassemlouei@sapns2.com&gt;</dc:contributor>
        <dc:contributor>ghylock &lt;ghylock@gmail.com&gt;</dc:contributor>
        <dc:contributor>Andrew Gilmore &lt;agilmore2@gmail.com&gt;</dc:contributor>
        <dc:contributor>Joshua Glemza &lt;jglemza@nasa.gov&gt;</dc:contributor>
        <dc:contributor>Loren Gordon &lt;lorengordon@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Patrik Greco &lt;sikevux@sikevux.se&gt;</dc:contributor>
        <dc:contributor>Steve Grubb &lt;sgrubb@redhat.com&gt;</dc:contributor>
        <dc:contributor>Marek Haicman &lt;mhaicman@redhat.com&gt;</dc:contributor>
        <dc:contributor>Rebekah Hayes &lt;rhayes@corp.rivierautilities.com&gt;</dc:contributor>
        <dc:contributor>Trey Henefield &lt;thenefield@gmail.com&gt;</dc:contributor>
        <dc:contributor>Henning Henkel &lt;henning.henkel@helvetia.ch&gt;</dc:contributor>
        <dc:contributor>hex2a &lt;hex2a@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>John Hooks &lt;jhooks@starscream.pa.jhbcomputers.com&gt;</dc:contributor>
        <dc:contributor>Jakub Hrozek &lt;jhrozek@redhat.com&gt;</dc:contributor>
        <dc:contributor>De Huo &lt;De.Huo@windriver.com&gt;</dc:contributor>
        <dc:contributor>Robin Price II &lt;robin@redhat.com&gt;</dc:contributor>
        <dc:contributor>Yasir Imam &lt;yimam@redhat.com&gt;</dc:contributor>
        <dc:contributor>Jiri Jaburek &lt;jjaburek@redhat.com&gt;</dc:contributor>
        <dc:contributor>Keith Jackson &lt;keithkjackson@gmail.com&gt;</dc:contributor>
        <dc:contributor>Jeremiah Jahn &lt;jeremiah@goodinassociates.com&gt;</dc:contributor>
        <dc:contributor>Stephan Joerrens &lt;Stephan.Joerrens@fiduciagad.de&gt;</dc:contributor>
        <dc:contributor>Jono &lt;jono@ubuntu-18.localdomain&gt;</dc:contributor>
        <dc:contributor>Kai Kang &lt;kai.kang@windriver.com&gt;</dc:contributor>
        <dc:contributor>Charles Kernstock &lt;charles.kernstock@ultra-ats.com&gt;</dc:contributor>
        <dc:contributor>Yuli Khodorkovskiy &lt;ykhodorkovskiy@tresys.com&gt;</dc:contributor>
        <dc:contributor>Nathan Kinder &lt;nkinder@redhat.com&gt;</dc:contributor>
        <dc:contributor>Lee Kinser &lt;lee.kinser@gmail.com&gt;</dc:contributor>
        <dc:contributor>Evgeny Kolesnikov &lt;ekolesni@redhat.com&gt;</dc:contributor>
        <dc:contributor>Peter 'Pessoft' Kol&#xED;nek &lt;github@pessoft.com&gt;</dc:contributor>
        <dc:contributor>Luke Kordell &lt;luke.t.kordell@lmco.com&gt;</dc:contributor>
        <dc:contributor>Malte Kraus &lt;malte.kraus@suse.com&gt;</dc:contributor>
        <dc:contributor>kspargur &lt;kspargur@kspargur.csb&gt;</dc:contributor>
        <dc:contributor>Amit Kumar &lt;amitkuma@redhat.com&gt;</dc:contributor>
        <dc:contributor>Fen Labalme &lt;fen@civicactions.com&gt;</dc:contributor>
        <dc:contributor>Ian Lee &lt;lee1001@llnl.gov&gt;</dc:contributor>
        <dc:contributor>Jarrett Lee &lt;jarrettl@umd.edu&gt;</dc:contributor>
        <dc:contributor>Jan Lieskovsky &lt;jlieskov@redhat.com&gt;</dc:contributor>
        <dc:contributor>&#x160;imon Luka&#x161;&#xED;k &lt;slukasik@redhat.com&gt;</dc:contributor>
        <dc:contributor>Milan Lysonek &lt;mlysonek@redhat.com&gt;</dc:contributor>
        <dc:contributor>Fredrik Lys&#xE9;n &lt;fredrik@pipemore.se&gt;</dc:contributor>
        <dc:contributor>Matus Marhefka &lt;mmarhefk@redhat.com&gt;</dc:contributor>
        <dc:contributor>Jamie Lorwey Martin &lt;jlmartin@redhat.com&gt;</dc:contributor>
        <dc:contributor>Robert McAllister &lt;rmcallis@redhat.com&gt;</dc:contributor>
        <dc:contributor>Michael McConachie &lt;michael@redhat.com&gt;</dc:contributor>
        <dc:contributor>Khary Mendez &lt;kharyam@gmail.com&gt;</dc:contributor>
        <dc:contributor>Rodney Mercer &lt;rmercer@harris.com&gt;</dc:contributor>
        <dc:contributor>Matt Micene &lt;nzwulfin@gmail.com&gt;</dc:contributor>
        <dc:contributor>Brian Millett &lt;bmillett@gmail.com&gt;</dc:contributor>
        <dc:contributor>Mixer9 &lt;35545791+Mixer9@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>mmosel &lt;mmosel@kde.example.com&gt;</dc:contributor>
        <dc:contributor>Zbynek Moravec &lt;zmoravec@redhat.com&gt;</dc:contributor>
        <dc:contributor>Kazuo Moriwaka &lt;moriwaka@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Michael Moseley &lt;michael@eclipse.ncsc.mil&gt;</dc:contributor>
        <dc:contributor>Joe Nall &lt;joe@nall.com&gt;</dc:contributor>
        <dc:contributor>Neiloy &lt;neiloy@redhat.com&gt;</dc:contributor>
        <dc:contributor>Axel Nennker &lt;axel@nennker.de&gt;</dc:contributor>
        <dc:contributor>Michele Newman &lt;mnewman@redhat.com&gt;</dc:contributor>
        <dc:contributor>Sean O'Keeffe &lt;seanokeeffe797@gmail.com&gt;</dc:contributor>
        <dc:contributor>Ilya Okomin &lt;ilya.okomin@oracle.com&gt;</dc:contributor>
        <dc:contributor>Kaustubh Padegaonkar &lt;theTuxRacer@gmail.com&gt;</dc:contributor>
        <dc:contributor>Michael Palmiotto &lt;mpalmiotto@tresys.com&gt;</dc:contributor>
        <dc:contributor>Max R.D. Parmer &lt;maxp@trystero.is&gt;</dc:contributor>
        <dc:contributor>Jan Pazdziora &lt;jpazdziora@redhat.com&gt;</dc:contributor>
        <dc:contributor>pcactr &lt;paul.c.arnold4.ctr@mail.mil&gt;</dc:contributor>
        <dc:contributor>Kenneth Peeples &lt;kennethwpeeples@gmail.com&gt;</dc:contributor>
        <dc:contributor>Nathan Peters &lt;Nathaniel.Peters@ca.com&gt;</dc:contributor>
        <dc:contributor>Frank Lin PIAT &lt;fpiat@klabs.be&gt;</dc:contributor>
        <dc:contributor>Stefan Pietsch &lt;mail.ipv4v6+gh@gmail.com&gt;</dc:contributor>
        <dc:contributor>Vojtech Polasek &lt;vpolasek@redhat.com&gt;</dc:contributor>
        <dc:contributor>Martin Preisler &lt;mpreisle@redhat.com&gt;</dc:contributor>
        <dc:contributor>Wesley Ceraso Prudencio &lt;wcerasop@redhat.com&gt;</dc:contributor>
        <dc:contributor>Raphael Sanchez Prudencio &lt;rsprudencio@redhat.com&gt;</dc:contributor>
        <dc:contributor>T.O. Radzy Radzykewycz &lt;radzy@windriver.com&gt;</dc:contributor>
        <dc:contributor>Kenyon Ralph &lt;kenyon@kenyonralph.com&gt;</dc:contributor>
        <dc:contributor>Mike Ralph &lt;mralph@redhat.com&gt;</dc:contributor>
        <dc:contributor>Rick Renshaw &lt;Richard_Renshaw@xtoenergy.com&gt;</dc:contributor>
        <dc:contributor>Chris Reynolds &lt;c.reynolds82@gmail.com&gt;</dc:contributor>
        <dc:contributor>rhayes &lt;rhayes@rivierautilities.com&gt;</dc:contributor>
        <dc:contributor>Pat Riehecky &lt;riehecky@fnal.gov&gt;</dc:contributor>
        <dc:contributor>rlucente-se-jboss &lt;rlucente@redhat.com&gt;</dc:contributor>
        <dc:contributor>Jesse Roland &lt;j.roland277@gmail.com&gt;</dc:contributor>
        <dc:contributor>Joshua Roys &lt;roysjosh@gmail.com&gt;</dc:contributor>
        <dc:contributor>rrenshaw &lt;bofh69@yahoo.com&gt;</dc:contributor>
        <dc:contributor>Chris Ruffalo &lt;chris.ruffalo@gmail.com&gt;</dc:contributor>
        <dc:contributor>Ray Shaw (Cont ARL/CISD) rvshaw &lt;rvshaw@esme.arl.army.mil&gt;</dc:contributor>
        <dc:contributor>Willy Santos &lt;wsantos@redhat.com&gt;</dc:contributor>
        <dc:contributor>Gautam Satish &lt;gautams@hpe.com&gt;</dc:contributor>
        <dc:contributor>Watson Sato &lt;wsato@redhat.com&gt;</dc:contributor>
        <dc:contributor>Satoru SATOH &lt;satoru.satoh@gmail.com&gt;</dc:contributor>
        <dc:contributor>Alexander Scheel &lt;ascheel@redhat.com&gt;</dc:contributor>
        <dc:contributor>Bryan Schneiders &lt;pschneiders@trisept.com&gt;</dc:contributor>
        <dc:contributor>shaneboulden &lt;shane.boulden@gmail.com&gt;</dc:contributor>
        <dc:contributor>Spencer Shimko &lt;sshimko@tresys.com&gt;</dc:contributor>
        <dc:contributor>Mark Shoger &lt;mshoger@redhat.com&gt;</dc:contributor>
        <dc:contributor>Thomas Sj&#xF6;gren &lt;konstruktoid@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Francisco Slavin &lt;fslavin@tresys.com&gt;</dc:contributor>
        <dc:contributor>David Smith &lt;dsmith@eclipse.ncsc.mil&gt;</dc:contributor>
        <dc:contributor>Kevin Spargur &lt;kspargur@redhat.com&gt;</dc:contributor>
        <dc:contributor>Kenneth Stailey &lt;kstailey.lists@gmail.com&gt;</dc:contributor>
        <dc:contributor>Leland Steinke &lt;leland.j.steinke.ctr@mail.mil&gt;</dc:contributor>
        <dc:contributor>Justin Stephenson &lt;jstephen@redhat.com&gt;</dc:contributor>
        <dc:contributor>Brian Stinson &lt;brian@bstinson.com&gt;</dc:contributor>
        <dc:contributor>Jake Stookey &lt;jakestookey@gmail.com&gt;</dc:contributor>
        <dc:contributor>Jonathan Sturges &lt;jsturges@jsturges.remote.csb&gt;</dc:contributor>
        <dc:contributor>Philippe Thierry &lt;phil@reseau-libre.net&gt;</dc:contributor>
        <dc:contributor>Derek Thurston &lt;thegrit@gmail.com&gt;</dc:contributor>
        <dc:contributor>tianzhenjia &lt;jiatianzhen@cmss.chinamobile.com&gt;</dc:contributor>
        <dc:contributor>Paul Tittle &lt;ptittle@cmf.nrl.navy.mil&gt;</dc:contributor>
        <dc:contributor>tomas.hudik &lt;tomas.hudik@embedit.cz&gt;</dc:contributor>
        <dc:contributor>Jeb Trayer &lt;jeb.d.trayer@uscg.mil&gt;</dc:contributor>
        <dc:contributor>Mat&#x11B;j T&#xFD;&#x10D; &lt;matyc@redhat.com&gt;</dc:contributor>
        <dc:contributor>VadimDor &lt;29509093+VadimDor@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Shawn Wells &lt;shawn@redhat.com&gt;</dc:contributor>
        <dc:contributor>Daniel E. White &lt;linuxdan@users.noreply.github.com&gt;</dc:contributor>
        <dc:contributor>Roy Williams &lt;roywilli@roywilli.redhat.com&gt;</dc:contributor>
        <dc:contributor>Rob Wilmoth &lt;rwilmoth@redhat.com&gt;</dc:contributor>
        <dc:contributor>Lucas Yamanishi &lt;lucas.yamanishi@onyxpoint.com&gt;</dc:contributor>
        <dc:contributor>Xirui Yang &lt;xirui.yang@oracle.com&gt;</dc:contributor>
        <dc:contributor>Kevin Zimmerman &lt;kevin.zimmerman@kitware.com&gt;</dc:contributor>
        <dc:contributor>Jan &#x10C;ern&#xFD; &lt;jcerny@redhat.com&gt;</dc:contributor>
        <dc:contributor>Michal &#x160;ruba&#x159; &lt;msrubar@redhat.com&gt;</dc:contributor>
        <dc:source>https://github.com/OpenSCAP/scap-security-guide/releases/latest</dc:source>
      </ns9:metadata>
      <ns9:model system="urn:xccdf:scoring:default"/>
      <ns9:Profile id="xccdf_org.ssgproject.content_profile_stig">
        <ns9:title override="true" xml:lang="en-US">Upstream Firefox STIG</ns9:title>
        <ns9:description override="true" xml:lang="en-US">This profile is developed under the DoD consensus model and DISA FSO Vendor STIG process,
serving as the upstream development environment for the Firefox STIG.

As a result of the upstream/downstream relationship between the SCAP Security Guide project
and the official DISA FSO STIG baseline, users should expect variance between SSG and DISA FSO content.
For official DISA FSO STIG content, refer to https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance.

While this profile is packaged by Red Hat as part of the SCAP Security Guide package, please note
that commercial support of this SCAP content is NOT available. This profile is provided as example
SCAP content with no endorsement for suitability or production readiness. Support for this
profile is provided by the upstream SCAP Security Guide community on a best-effort basis. The
upstream project homepage is https://www.open-scap.org/security-policies/scap-security-guide/.</ns9:description>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-dod_root_certificate_installed" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-enable_ca_trust" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-addons_plugin_updates" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-auto-download_actions" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-autofill_forms" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-autofill_passwords" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-auto-update_of_firefox" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-cookies_clear" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-cookies_user_notice" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-lock_settings_obscure" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-lock_settings_config_file" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-open_confirmation" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-password_store" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-search_update" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-shell_protocol" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-ssl_version_2" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-ssl_protocol_tls" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-verification" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-ssl_version_3" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-home_page" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_installed_firefox_version_supported" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_status_bar_text" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_context_menus" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_status_bar_changes" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_window_resizing" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_window_changes" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-non-secure_page_warning" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_rule_firefox_preferences-pop-up_windows" selected="true"/>
        <ns9:select idref="xccdf_org.ssgproject.content_group_remediation_functions" selected="false"/>
        <ns9:refine-value idref="xccdf_org.ssgproject.content_value_var_default_home_page" selector="about_blank"/>
      </ns9:Profile>
      <ns9:Group id="xccdf_org.ssgproject.content_group_remediation_functions">
        <ns9:title xml:lang="en-US">Remediation functions used by the SCAP Security Guide Project</ns9:title>
        <ns9:description xml:lang="en-US">XCCDF form of the various remediation functions as used by remediation scripts from the SCAP Security Guide Project.</ns9:description>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_include_merge_files_by_lines" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function include_merge_files_by_lines</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value>function include_merge_files_by_lines {
	:
}

# 1: Filename of the "master" file
# 2: Filename of the newly created file
function create_empty_file_like {
	local lines_count
	lines_count=$(cat "$1" | wc -l)
	for _ in $(seq 1 "$lines_count"); do
		printf '\n' &gt;&gt; "$2"
	done
}


# 1: Filename of the "master" file
# 2: Filename of sample flie
function second_file_is_same_except_newlines {
	local lines_of_master lines_of_sample len_of_master line_number i
	readarray -t lines_of_master &lt; "$1"
	readarray -t lines_of_sample &lt; "$2"

	len_of_master="${#lines_of_master[@]}"
	if test "$len_of_master" != "${#lines_of_sample[@]}"; then
		echo "Files '$1' and '$2' have different number of lines, $len_of_master and ${#lines_of_sample[@]} respectively."
		return 1
	fi

	for line_number in $(seq 1 "$len_of_master"); do
		i=$((line_number - 1))
		test -n "${lines_of_sample[$i]}" || continue
		if test "${lines_of_master[$i]}" != "${lines_of_sample[$i]}"; then
			echo "Line $line_number is different in files '$1' and '$2'."
			return 1
		fi
	done
}


# 1: Filename of the "master" file
# 2: Filename of sample flie
# 3: List of indices (1-based, space-separated string)
function merge_first_lines_to_second_on_indices {
	local lines_of_master lines_of_sample line_number i
	test -f "$2" || create_empty_file_like "$1" "$2"

	readarray -t lines_of_master &lt; "$1"
	readarray -t lines_of_sample &lt; "$2"

	error_msg="$(second_file_is_same_except_newlines "$1" "$2")"
	if test $? != 0; then
		echo "Error merging lines into '$2': $error_msg" &gt;&amp;2
		return 1
	fi

	for line_number in $3; do
		i=$((line_number - 1))
		lines_of_sample[$i]="${lines_of_master[$i]}"
	done

	printf "%s\n" "${lines_of_sample[@]}" &gt; "$2"
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_perform_audit_adjtimex_settimeofday_stime_remediation" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function perform_audit_adjtimex_settimeofday_stime_remediation</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># Function to fix syscall audit rule for given system call. It is
# based on example audit syscall rule definitions as outlined in
# /usr/share/doc/audit-2.3.7/stig.rules file provided with the audit
# package. It will combine multiple system calls belonging to the same
# syscall group into one audit rule (rather than to create audit rule per
# different system call) to avoid audit infrastructure performance penalty
# in the case of 'one-audit-rule-definition-per-one-system-call'. See:
#
#   https://www.redhat.com/archives/linux-audit/2014-November/msg00009.html
#
# for further details.
#
# Expects five arguments (each of them is required) in the form of:
# * audit tool				tool used to load audit rules,
# 					either 'auditctl', or 'augenrules
# * audit rules' pattern		audit rule skeleton for same syscall
# * syscall group			greatest common string this rule shares
# 					with other rules from the same group
# * architecture			architecture this rule is intended for
# * full form of new rule to add	expected full form of audit rule as to be
# 					added into audit.rules file
#
# Note: The 2-th up to 4-th arguments are used to determine how many existing
# audit rules will be inspected for resemblance with the new audit rule
# (5-th argument) the function is going to add. The rule's similarity check
# is performed to optimize audit.rules definition (merge syscalls of the same
# group into one rule) to avoid the "single-syscall-per-audit-rule" performance
# penalty.
#
# Example call:
#
#	See e.g. 'audit_rules_file_deletion_events.sh' remediation script
#
function fix_audit_syscall_rule {

# Load function arguments into local variables
local tool="$1"
local pattern="$2"
local group="$3"
local arch="$4"
local full_rule="$5"

# Check sanity of the input
if [ $# -ne "5" ]
then
	echo "Usage: fix_audit_syscall_rule 'tool' 'pattern' 'group' 'arch' 'full rule'"
	echo "Aborting."
	exit 1
fi

# Create a list of audit *.rules files that should be inspected for presence and correctness
# of a particular audit rule. The scheme is as follows:
# 
# -----------------------------------------------------------------------------------------
#  Tool used to load audit rules | Rule already defined  |  Audit rules file to inspect    |
# -----------------------------------------------------------------------------------------
#        auditctl                |     Doesn't matter    |  /etc/audit/audit.rules         |
# -----------------------------------------------------------------------------------------
#        augenrules              |          Yes          |  /etc/audit/rules.d/*.rules     |
#        augenrules              |          No           |  /etc/audit/rules.d/$key.rules  |
# -----------------------------------------------------------------------------------------
#
declare -a files_to_inspect

retval=0

# First check sanity of the specified audit tool
if [ "$tool" != 'auditctl' ] &amp;&amp; [ "$tool" != 'augenrules' ]
then
	echo "Unknown audit rules loading tool: $1. Aborting."
	echo "Use either 'auditctl' or 'augenrules'!"
	return 1
# If audit tool is 'auditctl', then add '/etc/audit/audit.rules'
# file to the list of files to be inspected
elif [ "$tool" == 'auditctl' ]
then
	files_to_inspect+=('/etc/audit/audit.rules' )
# If audit tool is 'augenrules', then check if the audit rule is defined
# If rule is defined, add '/etc/audit/rules.d/*.rules' to the list for inspection
# If rule isn't defined yet, add '/etc/audit/rules.d/$key.rules' to the list for inspection
elif [ "$tool" == 'augenrules' ]
then
	# Extract audit $key from audit rule so we can use it later
	key=$(expr "$full_rule" : '.*-k[[:space:]]\([^[:space:]]\+\)' '|' "$full_rule" : '.*-F[[:space:]]key=\([^[:space:]]\+\)')
	readarray -t matches &lt; &lt;(sed -s -n -e "\;${pattern};!d" -e "/${arch}/!d" -e "/${group}/!d;F" /etc/audit/rules.d/*.rules)
	if [ $? -ne 0 ]
	then
		retval=1
	fi
	for match in "${matches[@]}"
	do
		files_to_inspect+=("${match}")
	done
	# Case when particular rule isn't defined in /etc/audit/rules.d/*.rules yet
	if [ ${#files_to_inspect[@]} -eq "0" ]
	then
		file_to_inspect="/etc/audit/rules.d/$key.rules"
		files_to_inspect=("$file_to_inspect")
		if [ ! -e "$file_to_inspect" ]
		then
			touch "$file_to_inspect"
			chmod 0640 "$file_to_inspect"
		fi
	fi
fi

#
# Indicator that we want to append $full_rule into $audit_file by default
local append_expected_rule=0

for audit_file in "${files_to_inspect[@]}"
do
	# Filter existing $audit_file rules' definitions to select those that:
	# * follow the rule pattern, and
	# * meet the hardware architecture requirement, and
	# * are current syscall group specific
	readarray -t existing_rules &lt; &lt;(sed -e "\;${pattern};!d" -e "/${arch}/!d" -e "/${group}/!d"  "$audit_file")
	if [ $? -ne 0 ]
	then
		retval=1
	fi

	# Process rules found case-by-case
	for rule in "${existing_rules[@]}"
	do
		# Found rule is for same arch &amp; key, but differs (e.g. in count of -S arguments)
		if [ "${rule}" != "${full_rule}" ]
		then
			# If so, isolate just '(-S \w)+' substring of that rule
			rule_syscalls=$(echo "$rule" | grep -o -P '(-S \w+ )+')
			# Check if list of '-S syscall' arguments of that rule is subset
			# of '-S syscall' list of expected $full_rule
			if grep -q -- "$rule_syscalls" &lt;&lt;&lt; "$full_rule"
			then
				# Rule is covered (i.e. the list of -S syscalls for this rule is
				# subset of -S syscalls of $full_rule =&gt; existing rule can be deleted
				# Thus delete the rule from audit.rules &amp; our array
				sed -i -e "\;${rule};d" "$audit_file"
				if [ $? -ne 0 ]
				then
					retval=1
				fi
				existing_rules=("${existing_rules[@]//$rule/}")
			else
				# Rule isn't covered by $full_rule - it besides -S syscall arguments
				# for this group contains also -S syscall arguments for other syscall
				# group. Example: '-S lchown -S fchmod -S fchownat' =&gt; group='chown'
				# since 'lchown' &amp; 'fchownat' share 'chown' substring
				# Therefore:
				# * 1) delete the original rule from audit.rules
				# (original '-S lchown -S fchmod -S fchownat' rule would be deleted)
				# * 2) delete the -S syscall arguments for this syscall group, but
				# keep those not belonging to this syscall group
				# (original '-S lchown -S fchmod -S fchownat' would become '-S fchmod'
				# * 3) append the modified (filtered) rule again into audit.rules
				# if the same rule not already present
				#
				# 1) Delete the original rule
				sed -i -e "\;${rule};d" "$audit_file"
				if [ $? -ne 0 ]
				then
					retval=1
				fi

				# 2) Delete syscalls for this group, but keep those from other groups
				# Convert current rule syscall's string into array splitting by '-S' delimiter
				IFS_BKP="$IFS"
				IFS=$'-S'
				read -a rule_syscalls_as_array &lt;&lt;&lt; "$rule_syscalls"
				# Reset IFS back to default
				IFS="$IFS_BKP"
				# Splitting by "-S" can't be replaced by the readarray functionality easily

				# Declare new empty string to hold '-S syscall' arguments from other groups
				new_syscalls_for_rule=''
				# Walk through existing '-S syscall' arguments
				for syscall_arg in "${rule_syscalls_as_array[@]}"
				do
					# Skip empty $syscall_arg values
					if [ "$syscall_arg" == '' ]
					then
						continue
					fi
					# If the '-S syscall' doesn't belong to current group add it to the new list
					# (together with adding '-S' delimiter back for each of such item found)
					if grep -q -v -- "$group" &lt;&lt;&lt; "$syscall_arg"
					then
						new_syscalls_for_rule="$new_syscalls_for_rule -S $syscall_arg"
					fi
				done
				# Replace original '-S syscall' list with the new one for this rule
				updated_rule=${rule//$rule_syscalls/$new_syscalls_for_rule}
				# Squeeze repeated whitespace characters in rule definition (if any) into one
				updated_rule=$(echo "$updated_rule" | tr -s '[:space:]')
				# 3) Append the modified / filtered rule again into audit.rules
				#    (but only in case it's not present yet to prevent duplicate definitions)
				if ! grep -q -- "$updated_rule" "$audit_file"
				then
					echo "$updated_rule" &gt;&gt; "$audit_file"
				fi
			fi
		else
			# $audit_file already contains the expected rule form for this
			# architecture &amp; key =&gt; don't insert it second time
			append_expected_rule=1
		fi
	done

	# We deleted all rules that were subset of the expected one for this arch &amp; key.
	# Also isolated rules containing system calls not from this system calls group.
	# Now append the expected rule if it's not present in $audit_file yet
	if [[ ${append_expected_rule} -eq "0" ]]
	then
		echo "$full_rule" &gt;&gt; "$audit_file"
	fi
done

return $retval

}


# Function to perform remediation for the 'adjtimex', 'settimeofday', and 'stime' audit
# system calls on RHEL, Fedora or OL systems.
# Remediation performed for both possible tools: 'auditctl' and 'augenrules'.
#
# Note: 'stime' system call isn't known at 64-bit arch (see "$ ausyscall x86_64 stime" 's output)
# therefore excluded from the list of time group system calls to be audited on this arch
#
# Example Call:
#
#      perform_audit_adjtimex_settimeofday_stime_remediation
#
function perform_audit_adjtimex_settimeofday_stime_remediation {

# Retrieve hardware architecture of the underlying system
[ "$(getconf LONG_BIT)" = "32" ] &amp;&amp; RULE_ARCHS=("b32") || RULE_ARCHS=("b32" "b64")

for ARCH in "${RULE_ARCHS[@]}"
do

	PATTERN="-a always,exit -F arch=${ARCH} -S .* -k *"
	# Create expected audit group and audit rule form for particular system call &amp; architecture
	if [ ${ARCH} = "b32" ]
	then
		# stime system call is known at 32-bit arch (see e.g "$ ausyscall i386 stime" 's output)
		# so append it to the list of time group system calls to be audited
		GROUP="\(adjtimex\|settimeofday\|stime\)"
		FULL_RULE="-a always,exit -F arch=${ARCH} -S adjtimex -S settimeofday -S stime -k audit_time_rules"
	elif [ ${ARCH} = "b64" ]
	then
		# stime system call isn't known at 64-bit arch (see "$ ausyscall x86_64 stime" 's output)
		# therefore don't add it to the list of time group system calls to be audited
		GROUP="\(adjtimex\|settimeofday\)"
		FULL_RULE="-a always,exit -F arch=${ARCH} -S adjtimex -S settimeofday -k audit_time_rules"
	fi
	# Perform the remediation for both possible tools: 'auditctl' and 'augenrules'
	fix_audit_syscall_rule "auditctl" "$PATTERN" "$GROUP" "$ARCH" "$FULL_RULE"
	fix_audit_syscall_rule "augenrules" "$PATTERN" "$GROUP" "$ARCH" "$FULL_RULE"
done

}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_fix_audit_watch_rule" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function fix_audit_watch_rule</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># Function to fix audit file system object watch rule for given path:
# * if rule exists, also verifies the -w bits match the requirements
# * if rule doesn't exist yet, appends expected rule form to $files_to_inspect
#   audit rules file, depending on the tool which was used to load audit rules
#
# Expects four arguments (each of them is required) in the form of:
# * audit tool				tool used to load audit rules,
# 					either 'auditctl', or 'augenrules'
# * path                        	value of -w audit rule's argument
# * required access bits        	value of -p audit rule's argument
# * key                         	value of -k audit rule's argument
#
# Example call:
#
#       fix_audit_watch_rule "auditctl" "/etc/localtime" "wa" "audit_time_rules"
#
function fix_audit_watch_rule {

# Load function arguments into local variables
local tool="$1"
local path="$2"
local required_access_bits="$3"
local key="$4"

# Check sanity of the input
if [ $# -ne "4" ]
then
	echo "Usage: fix_audit_watch_rule 'tool' 'path' 'bits' 'key'"
	echo "Aborting."
	exit 1
fi

# Create a list of audit *.rules files that should be inspected for presence and correctness
# of a particular audit rule. The scheme is as follows:
#
# -----------------------------------------------------------------------------------------
# Tool used to load audit rules	| Rule already defined	|  Audit rules file to inspect	  |
# -----------------------------------------------------------------------------------------
#	auditctl		|     Doesn't matter	|  /etc/audit/audit.rules	  |
# -----------------------------------------------------------------------------------------
# 	augenrules		|          Yes		|  /etc/audit/rules.d/*.rules	  |
# 	augenrules		|          No		|  /etc/audit/rules.d/$key.rules  |
# -----------------------------------------------------------------------------------------
declare -a files_to_inspect
files_to_inspect=()

# Check sanity of the specified audit tool
if [ "$tool" != 'auditctl' ] &amp;&amp; [ "$tool" != 'augenrules' ]
then
	echo "Unknown audit rules loading tool: $1. Aborting."
	echo "Use either 'auditctl' or 'augenrules'!"
	exit 1
# If the audit tool is 'auditctl', then add '/etc/audit/audit.rules'
# into the list of files to be inspected
elif [ "$tool" == 'auditctl' ]
then
	files_to_inspect+=('/etc/audit/audit.rules')
# If the audit is 'augenrules', then check if rule is already defined
# If rule is defined, add '/etc/audit/rules.d/*.rules' to list of files for inspection.
# If rule isn't defined, add '/etc/audit/rules.d/$key.rules' to list of files for inspection.
elif [ "$tool" == 'augenrules' ]
then
	readarray -t matches &lt; &lt;(grep -P "[\s]*-w[\s]+$path" /etc/audit/rules.d/*.rules)

	# For each of the matched entries
	for match in "${matches[@]}"
	do
		# Extract filepath from the match
		rulesd_audit_file=$(echo $match | cut -f1 -d ':')
		# Append that path into list of files for inspection
		files_to_inspect+=("$rulesd_audit_file")
	done
	# Case when particular audit rule isn't defined yet
	if [ "${#files_to_inspect[@]}" -eq "0" ]
	then
		# Append '/etc/audit/rules.d/$key.rules' into list of files for inspection
		local key_rule_file="/etc/audit/rules.d/$key.rules"
		# If the $key.rules file doesn't exist yet, create it with correct permissions
		if [ ! -e "$key_rule_file" ]
		then
			touch "$key_rule_file"
			chmod 0640 "$key_rule_file"
		fi

		files_to_inspect+=("$key_rule_file")
	fi
fi

# Finally perform the inspection and possible subsequent audit rule
# correction for each of the files previously identified for inspection
for audit_rules_file in "${files_to_inspect[@]}"
do

	# Check if audit watch file system object rule for given path already present
	if grep -q -P -- "[\s]*-w[\s]+$path" "$audit_rules_file"
	then
		# Rule is found =&gt; verify yet if existing rule definition contains
		# all of the required access type bits

		# Escape slashes in path for use in sed pattern below
		local esc_path=${path//$'/'/$'\/'}
		# Define BRE whitespace class shortcut
		local sp="[[:space:]]"
		# Extract current permission access types (e.g. -p [r|w|x|a] values) from audit rule
		current_access_bits=$(sed -ne "s/$sp*-w$sp\+$esc_path$sp\+-p$sp\+\([rxwa]\{1,4\}\).*/\1/p" "$audit_rules_file")
		# Split required access bits string into characters array
		# (to check bit's presence for one bit at a time)
		for access_bit in $(echo "$required_access_bits" | grep -o .)
		do
			# For each from the required access bits (e.g. 'w', 'a') check
			# if they are already present in current access bits for rule.
			# If not, append that bit at the end
			if ! grep -q "$access_bit" &lt;&lt;&lt; "$current_access_bits"
			then
				# Concatenate the existing mask with the missing bit
				current_access_bits="$current_access_bits$access_bit"
			fi
		done
		# Propagate the updated rule's access bits (original + the required
		# ones) back into the /etc/audit/audit.rules file for that rule
		sed -i "s/\($sp*-w$sp\+$esc_path$sp\+-p$sp\+\)\([rxwa]\{1,4\}\)\(.*\)/\1$current_access_bits\3/" "$audit_rules_file"
	else
		# Rule isn't present yet. Append it at the end of $audit_rules_file file
		# with proper key

		echo "-w $path -p $required_access_bits -k $key" &gt;&gt; "$audit_rules_file"
	fi
done
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_set_faillock_option_to_value_in_pam_file" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function set_faillock_option_to_value_in_pam_file</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value>function set_faillock_option_to_value_in_pam_file {
	# If invoked with no arguments, exit. This is an intentional behavior.
	[ $# -gt 1 ] || return 0
	[ $# -ge 3 ] || die "$0 requires exactly zero, three, or four arguments"
	[ $# -le 4 ] || die "$0 requires exactly zero, three, or four arguments"
	local _pamFile="$1" _option="$2" _value="$3" _insert_lines_callback="$4"
	# pam_faillock.so already present?
	if grep -q "^auth.*pam_faillock.so.*" "$_pamFile"; then

		# pam_faillock.so present, is the option present?
		if grep -q "^auth.*[default=die].*pam_faillock.so.*authfail.*$_option=" "$_pamFile"; then

			# both pam_faillock.so &amp; option present, just correct option to the right value
			sed -i --follow-symlinks "s/\(^auth.*required.*pam_faillock.so.*preauth.*silent.*\)\($_option *= *\).*/\1\2$_value/" "$_pamFile"
			sed -i --follow-symlinks "s/\(^auth.*[default=die].*pam_faillock.so.*authfail.*\)\($_option *= *\).*/\1\2$_value/" "$_pamFile"

		# pam_faillock.so present, but the option not yet
		else

			# append correct option value to appropriate places
			sed -i --follow-symlinks "/^auth.*required.*pam_faillock.so.*preauth.*silent.*/ s/$/ $_option=$_value/" "$_pamFile"
			sed -i --follow-symlinks "/^auth.*[default=die].*pam_faillock.so.*authfail.*/ s/$/ $_option=$_value/" "$_pamFile"
		fi

	# pam_faillock.so not present yet
	else
		test -z "$_insert_lines_callback" || "$_insert_lines_callback" "$_option" "$_value" "$_pamFile"
		# insert pam_faillock.so preauth &amp; authfail rows with proper value of the option in question
	fi
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_create_audit_remediation_unsuccessful_file_modification_detailed" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function create_audit_remediation_unsuccessful_file_modification_detailed</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value>function create_audit_remediation_unsuccessful_file_modification_detailed {
	mkdir -p "$(dirname "$1")"
	# The - option to mark a here document limit string (&lt;&lt;-EOF) suppresses leading tabs (but not spaces) in the output.
	cat &lt;&lt;-EOF &gt; "$1"
		## This content is a section of an Audit config snapshot recommended for RHEL8 sytems that target OSPP compliance.
		## The following content has been retreived on 2019-03-11 from: https://github.com/linux-audit/audit-userspace/blob/master/rules/30-ospp-v42.rules

		## The purpose of these rules is to meet the requirements for Operating
		## System Protection Profile (OSPP)v4.2. These rules depends on having
		## 10-base-config.rules, 11-loginuid.rules, and 43-module-load.rules installed.

		## Unsuccessful file creation (open with O_CREAT)
		-a always,exit -F arch=b32 -S openat,open_by_handle_at -F a2&amp;0100 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b64 -S openat,open_by_handle_at -F a2&amp;0100 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b32 -S open -F a1&amp;0100 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b64 -S open -F a1&amp;0100 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b32 -S openat,open_by_handle_at -F a2&amp;0100 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b64 -S openat,open_by_handle_at -F a2&amp;0100 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b32 -S open -F a1&amp;0100 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b64 -S open -F a1&amp;0100 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b32 -S creat -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b64 -S creat -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b32 -S creat -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create
		-a always,exit -F arch=b64 -S creat -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-create

		## Unsuccessful file modifications (open for write or truncate)
		-a always,exit -F arch=b32 -S openat,open_by_handle_at -F a2&amp;01003 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b64 -S openat,open_by_handle_at -F a2&amp;01003 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b32 -S open -F a1&amp;01003 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b64 -S open -F a1&amp;01003 -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b32 -S openat,open_by_handle_at -F a2&amp;01003 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b64 -S openat,open_by_handle_at -F a2&amp;01003 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b32 -S open -F a1&amp;01003 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b64 -S open -F a1&amp;01003 -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b32 -S truncate,ftruncate -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b64 -S truncate,ftruncate -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b32 -S truncate,ftruncate -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification
		-a always,exit -F arch=b64 -S truncate,ftruncate -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-modification

		## Unsuccessful file access (any other opens) This has to go last.
		-a always,exit -F arch=b32 -S open,creat,truncate,ftruncate,openat,open_by_handle_at -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-access
		-a always,exit -F arch=b64 -S open,creat,truncate,ftruncate,openat,open_by_handle_at -F exit=-EACCES -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-access
		-a always,exit -F arch=b32 -S open,creat,truncate,ftruncate,openat,open_by_handle_at -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-access
		-a always,exit -F arch=b64 -S open,creat,truncate,ftruncate,openat,open_by_handle_at -F exit=-EPERM -F auid&gt;=1000 -F auid!=unset -F key=unsuccesful-access
	EOF
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_perform_audit_rules_privileged_commands_remediation" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function perform_audit_rules_privileged_commands_remediation</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># Function to perform remediation for 'audit_rules_privileged_commands' rule
#
# Expects two arguments:
#
# audit_tool		tool used to load audit rules
# 			One of 'auditctl' or 'augenrules'
#
# min_auid		Minimum original ID the user logged in with
# 			'500' for RHEL-6 and before, '1000' for RHEL-7 and after.
#
# Example Call(s):
#
#      perform_audit_rules_privileged_commands_remediation "auditctl" "500"
#      perform_audit_rules_privileged_commands_remediation "augenrules"	"1000"
#
function perform_audit_rules_privileged_commands_remediation {
#
# Load function arguments into local variables
local tool="$1"
local min_auid="$2"

# Check sanity of the input
if [ $# -ne "2" ]
then
	echo "Usage: perform_audit_rules_privileged_commands_remediation 'auditctl | augenrules' '500 | 1000'"
	echo "Aborting."
	exit 1
fi

declare -a files_to_inspect=()

# Check sanity of the specified audit tool
if [ "$tool" != 'auditctl' ] &amp;&amp; [ "$tool" != 'augenrules' ]
then
	echo "Unknown audit rules loading tool: $1. Aborting."
	echo "Use either 'auditctl' or 'augenrules'!"
	exit 1
# If the audit tool is 'auditctl', then:
# * add '/etc/audit/audit.rules'to the list of files to be inspected,
# * specify '/etc/audit/audit.rules' as the output audit file, where
#   missing rules should be inserted
elif [ "$tool" == 'auditctl' ]
then
	files_to_inspect=("/etc/audit/audit.rules")
	output_audit_file="/etc/audit/audit.rules"
#
# If the audit tool is 'augenrules', then:
# * add '/etc/audit/rules.d/*.rules' to the list of files to be inspected
#   (split by newline),
# * specify /etc/audit/rules.d/privileged.rules' as the output file, where
#   missing rules should be inserted
elif [ "$tool" == 'augenrules' ]
then
	readarray -t files_to_inspect &lt; &lt;(find /etc/audit/rules.d -maxdepth 1 -type f -name '*.rules' -print)
	output_audit_file="/etc/audit/rules.d/privileged.rules"
fi

# Obtain the list of SUID/SGID binaries on the particular system (split by newline)
# into privileged_binaries array
readarray -t privileged_binaries &lt; &lt;(find / -xdev -type f -perm -4000 -o -type f -perm -2000 2&gt;/dev/null)

# Keep list of SUID/SGID binaries that have been already handled within some previous iteration
declare -a sbinaries_to_skip=()

# For each found sbinary in privileged_binaries list
for sbinary in "${privileged_binaries[@]}"
do

	# Check if this sbinary wasn't already handled in some of the previous sbinary iterations
	# Return match only if whole sbinary definition matched (not in the case just prefix matched!!!)
	if [[ $(sed -ne "\|${sbinary}|p" &lt;&lt;&lt; "${sbinaries_to_skip[*]}") ]]
	then
		# If so, don't process it second time &amp; go to process next sbinary
		continue
	fi

	# Reset the counter of inspected files when starting to check
	# presence of existing audit rule for new sbinary
	local count_of_inspected_files=0

	# Define expected rule form for this binary
	expected_rule="-a always,exit -F path=${sbinary} -F perm=x -F auid&gt;=${min_auid} -F auid!=unset -k privileged"

	# If list of audit rules files to be inspected is empty, just add new rule and move on to next binary
	if [[ ${#files_to_inspect[@]} -eq 0 ]]; then
		echo "$expected_rule" &gt;&gt; "$output_audit_file"
		continue
	fi

	# Replace possible slash '/' character in sbinary definition so we could use it in sed expressions below
	sbinary_esc=${sbinary//$'/'/$'\/'}

	# For each audit rules file from the list of files to be inspected
	for afile in "${files_to_inspect[@]}"
	do

		# Search current audit rules file's content for match. Match criteria:
		# * existing rule is for the same SUID/SGID binary we are currently processing (but
		#   can contain multiple -F path= elements covering multiple SUID/SGID binaries)
		# * existing rule contains all arguments from expected rule form (though can contain
		#   them in arbitrary order)
	
		base_search=$(sed -e '/-a always,exit/!d' -e '/-F path='"${sbinary_esc}"'/!d'		\
				-e '/-F path=[^[:space:]]\+/!d'   -e '/-F perm=.*/!d'						\
				-e '/-F auid&gt;='"${min_auid}"'/!d' -e '/-F auid!=\(4294967295\|unset\)/!d'	\
				-e '/-k \|-F key=/!d' "$afile")

		# Increase the count of inspected files for this sbinary
		count_of_inspected_files=$((count_of_inspected_files + 1))

		# Require execute access type to be set for existing audit rule
		exec_access='x'

		# Search current audit rules file's content for presence of rule pattern for this sbinary
		if [[ $base_search ]]
		then

			# Current audit rules file already contains rule for this binary =&gt;
			# Store the exact form of found rule for this binary for further processing
			concrete_rule=$base_search

			# Select all other SUID/SGID binaries possibly also present in the found rule

			readarray -t handled_sbinaries &lt; &lt;(grep -o -e "-F path=[^[:space:]]\+" &lt;&lt;&lt; "$concrete_rule")
			handled_sbinaries=("${handled_sbinaries[@]//-F path=/}")

			# Merge the list of such SUID/SGID binaries found in this iteration with global list ignoring duplicates
			readarray -t sbinaries_to_skip &lt; &lt;(for i in "${sbinaries_to_skip[@]}" "${handled_sbinaries[@]}"; do echo "$i"; done | sort -du)

			# Separate concrete_rule into three sections using hash '#'
			# sign as a delimiter around rule's permission section borders
			concrete_rule="$(echo "$concrete_rule" | sed -n "s/\(.*\)\+\(-F perm=[rwax]\+\)\+/\1#\2#/p")"

			# Split concrete_rule into head, perm, and tail sections using hash '#' delimiter

			rule_head=$(cut -d '#' -f 1 &lt;&lt;&lt; "$concrete_rule")
			rule_perm=$(cut -d '#' -f 2 &lt;&lt;&lt; "$concrete_rule")
			rule_tail=$(cut -d '#' -f 3 &lt;&lt;&lt; "$concrete_rule")

			# Extract already present exact access type [r|w|x|a] from rule's permission section
			access_type=${rule_perm//-F perm=/}

			# Verify current permission access type(s) for rule contain 'x' (execute) permission
			if ! grep -q "$exec_access" &lt;&lt;&lt; "$access_type"
			then

				# If not, append the 'x' (execute) permission to the existing access type bits
				access_type="$access_type$exec_access"
				# Reconstruct the permissions section for the rule
				new_rule_perm="-F perm=$access_type"
				# Update existing rule in current audit rules file with the new permission section
				sed -i "s#${rule_head}\(.*\)${rule_tail}#${rule_head}${new_rule_perm}${rule_tail}#" "$afile"

			fi

		# If the required audit rule for particular sbinary wasn't found yet, insert it under following conditions:
		#
		# * in the "auditctl" mode of operation insert particular rule each time
		#   (because in this mode there's only one file -- /etc/audit/audit.rules to be inspected for presence of this rule),
		#
		# * in the "augenrules" mode of operation insert particular rule only once and only in case we have already
		#   searched all of the files from /etc/audit/rules.d/*.rules location (since that audit rule can be defined
		#   in any of those files and if not, we want it to be inserted only once into /etc/audit/rules.d/privileged.rules file)
		#
		elif [ "$tool" == "auditctl" ] || [[ "$tool" == "augenrules" &amp;&amp; $count_of_inspected_files -eq "${#files_to_inspect[@]}" ]]
		then

			# Check if this sbinary wasn't already handled in some of the previous afile iterations
			# Return match only if whole sbinary definition matched (not in the case just prefix matched!!!)
			if [[ ! $(sed -ne "\|${sbinary}|p" &lt;&lt;&lt; "${sbinaries_to_skip[*]}") ]]
			then
				# Current audit rules file's content doesn't contain expected rule for this
				# SUID/SGID binary yet =&gt; append it
				echo "$expected_rule" &gt;&gt; "$output_audit_file"
			fi

			continue
		fi

	done

done
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_fix_audit_syscall_rule" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function fix_audit_syscall_rule</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># Function to fix syscall audit rule for given system call. It is
# based on example audit syscall rule definitions as outlined in
# /usr/share/doc/audit-2.3.7/stig.rules file provided with the audit
# package. It will combine multiple system calls belonging to the same
# syscall group into one audit rule (rather than to create audit rule per
# different system call) to avoid audit infrastructure performance penalty
# in the case of 'one-audit-rule-definition-per-one-system-call'. See:
#
#   https://www.redhat.com/archives/linux-audit/2014-November/msg00009.html
#
# for further details.
#
# Expects five arguments (each of them is required) in the form of:
# * audit tool				tool used to load audit rules,
# 					either 'auditctl', or 'augenrules
# * audit rules' pattern		audit rule skeleton for same syscall
# * syscall group			greatest common string this rule shares
# 					with other rules from the same group
# * architecture			architecture this rule is intended for
# * full form of new rule to add	expected full form of audit rule as to be
# 					added into audit.rules file
#
# Note: The 2-th up to 4-th arguments are used to determine how many existing
# audit rules will be inspected for resemblance with the new audit rule
# (5-th argument) the function is going to add. The rule's similarity check
# is performed to optimize audit.rules definition (merge syscalls of the same
# group into one rule) to avoid the "single-syscall-per-audit-rule" performance
# penalty.
#
# Example call:
#
#	See e.g. 'audit_rules_file_deletion_events.sh' remediation script
#
function fix_audit_syscall_rule {

# Load function arguments into local variables
local tool="$1"
local pattern="$2"
local group="$3"
local arch="$4"
local full_rule="$5"

# Check sanity of the input
if [ $# -ne "5" ]
then
	echo "Usage: fix_audit_syscall_rule 'tool' 'pattern' 'group' 'arch' 'full rule'"
	echo "Aborting."
	exit 1
fi

# Create a list of audit *.rules files that should be inspected for presence and correctness
# of a particular audit rule. The scheme is as follows:
# 
# -----------------------------------------------------------------------------------------
#  Tool used to load audit rules | Rule already defined  |  Audit rules file to inspect    |
# -----------------------------------------------------------------------------------------
#        auditctl                |     Doesn't matter    |  /etc/audit/audit.rules         |
# -----------------------------------------------------------------------------------------
#        augenrules              |          Yes          |  /etc/audit/rules.d/*.rules     |
#        augenrules              |          No           |  /etc/audit/rules.d/$key.rules  |
# -----------------------------------------------------------------------------------------
#
declare -a files_to_inspect

retval=0

# First check sanity of the specified audit tool
if [ "$tool" != 'auditctl' ] &amp;&amp; [ "$tool" != 'augenrules' ]
then
	echo "Unknown audit rules loading tool: $1. Aborting."
	echo "Use either 'auditctl' or 'augenrules'!"
	return 1
# If audit tool is 'auditctl', then add '/etc/audit/audit.rules'
# file to the list of files to be inspected
elif [ "$tool" == 'auditctl' ]
then
	files_to_inspect+=('/etc/audit/audit.rules' )
# If audit tool is 'augenrules', then check if the audit rule is defined
# If rule is defined, add '/etc/audit/rules.d/*.rules' to the list for inspection
# If rule isn't defined yet, add '/etc/audit/rules.d/$key.rules' to the list for inspection
elif [ "$tool" == 'augenrules' ]
then
	# Extract audit $key from audit rule so we can use it later
	key=$(expr "$full_rule" : '.*-k[[:space:]]\([^[:space:]]\+\)' '|' "$full_rule" : '.*-F[[:space:]]key=\([^[:space:]]\+\)')
	readarray -t matches &lt; &lt;(sed -s -n -e "\;${pattern};!d" -e "/${arch}/!d" -e "/${group}/!d;F" /etc/audit/rules.d/*.rules)
	if [ $? -ne 0 ]
	then
		retval=1
	fi
	for match in "${matches[@]}"
	do
		files_to_inspect+=("${match}")
	done
	# Case when particular rule isn't defined in /etc/audit/rules.d/*.rules yet
	if [ ${#files_to_inspect[@]} -eq "0" ]
	then
		file_to_inspect="/etc/audit/rules.d/$key.rules"
		files_to_inspect=("$file_to_inspect")
		if [ ! -e "$file_to_inspect" ]
		then
			touch "$file_to_inspect"
			chmod 0640 "$file_to_inspect"
		fi
	fi
fi

#
# Indicator that we want to append $full_rule into $audit_file by default
local append_expected_rule=0

for audit_file in "${files_to_inspect[@]}"
do
	# Filter existing $audit_file rules' definitions to select those that:
	# * follow the rule pattern, and
	# * meet the hardware architecture requirement, and
	# * are current syscall group specific
	readarray -t existing_rules &lt; &lt;(sed -e "\;${pattern};!d" -e "/${arch}/!d" -e "/${group}/!d"  "$audit_file")
	if [ $? -ne 0 ]
	then
		retval=1
	fi

	# Process rules found case-by-case
	for rule in "${existing_rules[@]}"
	do
		# Found rule is for same arch &amp; key, but differs (e.g. in count of -S arguments)
		if [ "${rule}" != "${full_rule}" ]
		then
			# If so, isolate just '(-S \w)+' substring of that rule
			rule_syscalls=$(echo "$rule" | grep -o -P '(-S \w+ )+')
			# Check if list of '-S syscall' arguments of that rule is subset
			# of '-S syscall' list of expected $full_rule
			if grep -q -- "$rule_syscalls" &lt;&lt;&lt; "$full_rule"
			then
				# Rule is covered (i.e. the list of -S syscalls for this rule is
				# subset of -S syscalls of $full_rule =&gt; existing rule can be deleted
				# Thus delete the rule from audit.rules &amp; our array
				sed -i -e "\;${rule};d" "$audit_file"
				if [ $? -ne 0 ]
				then
					retval=1
				fi
				existing_rules=("${existing_rules[@]//$rule/}")
			else
				# Rule isn't covered by $full_rule - it besides -S syscall arguments
				# for this group contains also -S syscall arguments for other syscall
				# group. Example: '-S lchown -S fchmod -S fchownat' =&gt; group='chown'
				# since 'lchown' &amp; 'fchownat' share 'chown' substring
				# Therefore:
				# * 1) delete the original rule from audit.rules
				# (original '-S lchown -S fchmod -S fchownat' rule would be deleted)
				# * 2) delete the -S syscall arguments for this syscall group, but
				# keep those not belonging to this syscall group
				# (original '-S lchown -S fchmod -S fchownat' would become '-S fchmod'
				# * 3) append the modified (filtered) rule again into audit.rules
				# if the same rule not already present
				#
				# 1) Delete the original rule
				sed -i -e "\;${rule};d" "$audit_file"
				if [ $? -ne 0 ]
				then
					retval=1
				fi

				# 2) Delete syscalls for this group, but keep those from other groups
				# Convert current rule syscall's string into array splitting by '-S' delimiter
				IFS_BKP="$IFS"
				IFS=$'-S'
				read -a rule_syscalls_as_array &lt;&lt;&lt; "$rule_syscalls"
				# Reset IFS back to default
				IFS="$IFS_BKP"
				# Splitting by "-S" can't be replaced by the readarray functionality easily

				# Declare new empty string to hold '-S syscall' arguments from other groups
				new_syscalls_for_rule=''
				# Walk through existing '-S syscall' arguments
				for syscall_arg in "${rule_syscalls_as_array[@]}"
				do
					# Skip empty $syscall_arg values
					if [ "$syscall_arg" == '' ]
					then
						continue
					fi
					# If the '-S syscall' doesn't belong to current group add it to the new list
					# (together with adding '-S' delimiter back for each of such item found)
					if grep -q -v -- "$group" &lt;&lt;&lt; "$syscall_arg"
					then
						new_syscalls_for_rule="$new_syscalls_for_rule -S $syscall_arg"
					fi
				done
				# Replace original '-S syscall' list with the new one for this rule
				updated_rule=${rule//$rule_syscalls/$new_syscalls_for_rule}
				# Squeeze repeated whitespace characters in rule definition (if any) into one
				updated_rule=$(echo "$updated_rule" | tr -s '[:space:]')
				# 3) Append the modified / filtered rule again into audit.rules
				#    (but only in case it's not present yet to prevent duplicate definitions)
				if ! grep -q -- "$updated_rule" "$audit_file"
				then
					echo "$updated_rule" &gt;&gt; "$audit_file"
				fi
			fi
		else
			# $audit_file already contains the expected rule form for this
			# architecture &amp; key =&gt; don't insert it second time
			append_expected_rule=1
		fi
	done

	# We deleted all rules that were subset of the expected one for this arch &amp; key.
	# Also isolated rules containing system calls not from this system calls group.
	# Now append the expected rule if it's not present in $audit_file yet
	if [[ ${append_expected_rule} -eq "0" ]]
	then
		echo "$full_rule" &gt;&gt; "$audit_file"
	fi
done

return $retval

}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_populate" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function populate</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># The populate function isn't directly used by SSG at the moment but it can be 
# used for testing purposes and will be used in SSG Testsuite in the future.

function populate {
# code to populate environment variables needed (for unit testing)
if [ -z "${!1}" ]; then
	echo "$1 is not defined. Exiting."
	exit
fi
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_include_mount_options_functions" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function include_mount_options_functions</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value>function include_mount_options_functions {
	:
}

# $1: type of filesystem
# $2: new mount point option
# $3: filesystem of new mount point (used when adding new entry in fstab)
# $4: mount type of new mount point (used when adding new entry in fstab)
function ensure_mount_option_for_vfstype {
        local _vfstype="$1" _new_opt="$2" _filesystem=$3 _type=$4 _vfstype_points=()
        readarray -t _vfstype_points &lt; &lt;(grep -E "[[:space:]]${_vfstype}[[:space:]]" /etc/fstab | awk '{print $2}')

        for _vfstype_point in "${_vfstype_points[@]}"
        do
                ensure_mount_option_in_fstab "$_vfstype_point" "$_new_opt" "$_filesystem" "$_type"
        done
}

# $1: mount point
# $2: new mount point option
# $3: device or virtual string (used when adding new entry in fstab)
# $4: mount type of mount point (used when adding new entry in fstab)
function ensure_mount_option_in_fstab {
	local _mount_point="$1" _new_opt="$2" _device=$3 _type=$4
	local _mount_point_match_regexp="" _previous_mount_opts=""
	_mount_point_match_regexp="$(get_mount_point_regexp "$_mount_point")"

	if [ "$(grep -c "$_mount_point_match_regexp" /etc/fstab)" -eq 0 ]; then
		# runtime opts without some automatic kernel/userspace-added defaults
		_previous_mount_opts=$(grep "$_mount_point_match_regexp" /etc/mtab | head -1 |  awk '{print $4}' \
					| sed -E "s/(rw|defaults|seclabel|${_new_opt})(,|$)//g;s/,$//")
		[ "$_previous_mount_opts" ] &amp;&amp; _previous_mount_opts+=","
		echo "${_device} ${_mount_point} ${_type} defaults,${_previous_mount_opts}${_new_opt} 0 0" &gt;&gt; /etc/fstab
	elif [ "$(grep "$_mount_point_match_regexp" /etc/fstab | grep -c "$_new_opt")" -eq 0 ]; then
		_previous_mount_opts=$(grep "$_mount_point_match_regexp" /etc/fstab | awk '{print $4}')
		sed -i "s|\(${_mount_point_match_regexp}.*${_previous_mount_opts}\)|\1,${_new_opt}|" /etc/fstab
	fi
}

# $1: mount point
function get_mount_point_regexp {
		printf "[[:space:]]%s[[:space:]]" "$1"
}

# $1: mount point
function assert_mount_point_in_fstab {
	local _mount_point_match_regexp
	_mount_point_match_regexp="$(get_mount_point_regexp "$1")"
	grep "$_mount_point_match_regexp" -q /etc/fstab \
		|| { echo "The mount point '$1' is not even in /etc/fstab, so we can't set up mount options" &gt;&amp;2; return 1; }
}

# $1: mount point
function remove_defaults_from_fstab_if_overriden {
	local _mount_point_match_regexp
	_mount_point_match_regexp="$(get_mount_point_regexp "$1")"
	if grep "$_mount_point_match_regexp" /etc/fstab | grep -q "defaults,"
	then
		sed -i "s|\(${_mount_point_match_regexp}.*\)defaults,|\1|" /etc/fstab
	fi
}

# $1: mount point
function ensure_partition_is_mounted {
	local _mount_point="$1"
	mkdir -p "$_mount_point" || return 1
	if mountpoint -q "$_mount_point"; then
		mount -o remount --target "$_mount_point"
	else
		mount --target "$_mount_point"
	fi
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_replace_or_append" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function replace_or_append</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># Function to replace configuration setting in config file or add the configuration setting if
# it does not exist.
#
# Expects arguments:
#
# config_file:		Configuration file that will be modified
# key:			Configuration option to change
# value:		Value of the configuration option to change
# cce:			The CCE identifier or '@CCENUM@' if no CCE identifier exists
# format:		The printf-like format string that will be given stripped key and value as arguments,
#			so e.g. '%s=%s' will result in key=value subsitution (i.e. without spaces around =)
#
# Optional arugments:
#
# format:		Optional argument to specify the format of how key/value should be
# 			modified/appended in the configuration file. The default is key = value.
#
# Example Call(s):
#
#     With default format of 'key = value':
#     replace_or_append '/etc/sysctl.conf' '^kernel.randomize_va_space' '2' '@CCENUM@'
#
#     With custom key/value format:
#     replace_or_append '/etc/sysconfig/selinux' '^SELINUX=' 'disabled' '@CCENUM@' '%s=%s'
#
#     With a variable:
#     replace_or_append '/etc/sysconfig/selinux' '^SELINUX=' $var_selinux_state '@CCENUM@' '%s=%s'
#
function replace_or_append {
  local default_format='%s = %s' case_insensitive_mode=yes sed_case_insensitive_option='' grep_case_insensitive_option=''
  local config_file=$1
  local key=$2
  local value=$3
  local cce=$4
  local format=$5

  if [ "$case_insensitive_mode" = yes ]; then
    sed_case_insensitive_option="i"
    grep_case_insensitive_option="-i"
  fi
  [ -n "$format" ] || format="$default_format"
  # Check sanity of the input
  [ $# -ge "3" ] || { echo "Usage: replace_or_append &lt;config_file_location&gt; &lt;key_to_search&gt; &lt;new_value&gt; [&lt;CCE number or literal '@CCENUM@' if unknown&gt;] [printf-like format, default is '$default_format']" &gt;&amp;2; exit 1; }

  # Test if the config_file is a symbolic link. If so, use --follow-symlinks with sed.
  # Otherwise, regular sed command will do.
  sed_command=('sed' '-i')
  if test -L "$config_file"; then
    sed_command+=('--follow-symlinks')
  fi

  # Test that the cce arg is not empty or does not equal @CCENUM@.
  # If @CCENUM@ exists, it means that there is no CCE assigned.
  if [ -n "$cce" ] &amp;&amp; [ "$cce" != '@CCENUM@' ]; then
    cce="${cce}"
  else
    cce="CCE"
  fi

  # Strip any search characters in the key arg so that the key can be replaced without
  # adding any search characters to the config file.
  stripped_key=$(sed 's/[\^=\$,;+]*//g' &lt;&lt;&lt; "$key")

  # shellcheck disable=SC2059
  printf -v formatted_output "$format" "$stripped_key" "$value"

  # If the key exists, change it. Otherwise, add it to the config_file.
  # We search for the key string followed by a word boundary (matched by \&gt;),
  # so if we search for 'setting', 'setting2' won't match.
  if LC_ALL=C grep -q -m 1 $grep_case_insensitive_option -e "${key}\\&gt;" "$config_file"; then
    "${sed_command[@]}" "s/${key}\\&gt;.*/$formatted_output/g$sed_case_insensitive_option" "$config_file"
  else
    # \n is precaution for case where file ends without trailing newline
    printf '\n# Per %s: Set %s in %s\n' "$cce" "$formatted_output" "$config_file" &gt;&gt; "$config_file"
    printf '%s\n' "$formatted_output" &gt;&gt; "$config_file"
  fi
}</ns9:value>
        </ns9:Value>
        <ns9:Value hidden="true" id="xccdf_org.ssgproject.content_value_function_die" operator="equals" prohibitChanges="true" type="string">
          <ns9:title xml:lang="en-US">Remediation function die</ns9:title>
          <ns9:description xml:lang="en-US">Shared bash remediation function. Not intended to be changed by tailoring.</ns9:description>
          <ns9:value># Print a message to stderr and exit the shell
# $1: The message to print.
# $2: The error code (optional, default is 1)
function die {
	local _message="$1" _rc="${2:-1}"
	printf '%s\n' "$_message" &gt;&amp;2
	exit "$_rc"
}</ns9:value>
        </ns9:Value>
      </ns9:Group>
      <ns9:Group id="xccdf_org.ssgproject.content_group_firefox">
        <ns9:title xml:lang="en-US">Firefox</ns9:title>
        <ns9:description xml:lang="en-US">Firefox is an open-source web browser and developed by Mozilla.
Web browsers such as Firefox are used for a number of reasons. This section
provides settings for configuring Firefox policies to meet compliance
settings for Firefox running on Red Hat Enterprise Linux systems.

<html:ul>Refer to <html:li><html:a href="http://kb.mozillazine.org/Firefox_:_FAQs_:_About:config_Entries">http://kb.mozillazine.org/Firefox_:_FAQs_:_About:config_Entries</html:a></html:li>
for a list of currently supported Firefox settings.</html:ul></ns9:description>
        <ns9:Value id="xccdf_org.ssgproject.content_value_var_required_file_types" type="string">
          <ns9:title xml:lang="en-US">The Default Required Firefox File Types</ns9:title>
          <ns9:description xml:lang="en-US">The default required file types that need to request usage
confirmation in Firefox.</ns9:description>
          <ns9:value>application/pdf,application/doc,application/xls,application/bat,application/ppt,application/mdb,application/mde,application/fdf,application/xfdf,application/lsl,application/lso,appliation/lss,application/iqy,application/rqy,application/xlk,application/pot,application/pps,application/dot,application/wbk,application/ps,application/eps,application/wch,application/wcm,application/wbi,application/wb1,application/wb3,application/rtf,application/wch,application/wcm,application/ad,application/adp,application/xlt,application/dos,application/wks</ns9:value>
        </ns9:Value>
        <ns9:Value id="xccdf_org.ssgproject.content_value_var_default_home_page" type="string">
          <ns9:title xml:lang="en-US">The Default Firefox Home Page</ns9:title>
          <ns9:description xml:lang="en-US">The default home page for Firefox users.</ns9:description>
          <ns9:value selector="about_blank">about:blank</ns9:value>
          <ns9:value>None</ns9:value>
        </ns9:Value>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-home_page" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Default Firefox Home Page Configured</ns9:title>
          <ns9:description xml:lang="en-US">The default home page is set to a vendor's defined website or
Firefox's own website. This can be changed to an organizationally defined website
or <html:code>about:blank</html:code>. To set the default home page, set
<html:code>browser.startup.homepage</html:code> to <html:code><ns9:sub idref="xccdf_org.ssgproject.content_value_var_default_home_page" use="legacy"/></html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF017</ns9:reference>
          <ns9:rationale xml:lang="en-US">The browser home page parameter specifies the web page that is to be
displayed when the browser is started explicitly and when product-specific
buttons or key sequences for the home page are accessed. This helps to
mitigate the possibility of automatic inadvertent execution of scripts 
added to a previously safe site.</ns9:rationale>
          <ns9:fix id="firefox_preferences-home_page" system="urn:xccdf:fix:script:sh">
var_default_home_page="<ns9:sub idref="xccdf_org.ssgproject.content_value_var_default_home_page" use="legacy"/>"


firefox_cfg="stig.cfg"
value="\"${var_default_home_page}\""
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("browser.startup.homepage", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("browser.startup.homepage".*/lockPref("browser.startup.homepage", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("browser.startup.homepage", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-export export-name="oval:ssg-var_default_home_page:var:1" value-id="xccdf_org.ssgproject.content_value_var_default_home_page"/>
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-home_page:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-home_page_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-non-secure_page_warning" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Enable Non-Secure Page Warnings</ns9:title>
          <ns9:description xml:lang="en-US">When users browse websites, web pages can switch in between secure and 
non-secure protocols. Users can be warned each time by
setting <html:code>security.warn_leaving_secure</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF130</ns9:reference>
          <ns9:rationale xml:lang="en-US">Users may not be aware that the information being viewed under secure
conditions in a previous page are not currently being viewed under
the same security settings.</ns9:rationale>
          <ns9:fix id="firefox_preferences-non-secure_page_warning" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("security.warn_leaving_secure", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("security.warn_leaving_secure".*/lockPref("security.warn_leaving_secure", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("security.warn_leaving_secure", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-non-secure_page_warning:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-non-secure_page_warning_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-ssl_version_3" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable SSL Version 3.0 in Firefox</ns9:title>
          <ns9:description xml:lang="en-US">SSL version 3.0 is vulnerable and should be disabled by setting
<html:code>security.enable_ssl3</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF020</ns9:reference>
          <ns9:rationale xml:lang="en-US">Earlier versions of SSL have known security vulnerabilities and are not
authorized for use in DOD.</ns9:rationale>
          <ns9:fix id="firefox_preferences-ssl_version_3" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("security.enable_ssl3", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("security.enable_ssl3".*/lockPref("security.enable_ssl3", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("security.enable_ssl3", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-ssl_version_3:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-ssl_version_3_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-password_store" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable the Firefox Password Store</ns9:title>
          <ns9:description xml:lang="en-US">Firefox allows users to store passwords whether or not a master password
is set for the password store. To disable the storing of passwords, set
<html:code>signon.rememberSignons</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF160</ns9:reference>
          <ns9:rationale xml:lang="en-US">Autofill of a password can be enabled when a site is visited. This feature could also
be used to autofill the certificate pin which could lead to compromise of DoD information.</ns9:rationale>
          <ns9:fix id="firefox_preferences-password_store" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("signon.rememberSignons", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("signon.rememberSignons".*/lockPref("signon.rememberSignons", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("signon.rememberSignons", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-password_store:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-password_store_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_installed_firefox_version_supported" selected="false" severity="high">
          <ns9:title xml:lang="en-US">Supported Version of Firefox Installed</ns9:title>
          <ns9:description xml:lang="en-US">If the system is joined to the Red Hat Network, a Red Hat Satellite Server,
or a yum server, run the following command to install updates:
<html:pre>$ sudo yum update</html:pre>
If the system is not configured to use one of these sources, updates (in the form of RPM packages)
can be manually downloaded and installed using <html:code>rpm</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">DCMC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF003</ns9:reference>
          <ns9:rationale xml:lang="en-US">Use of versions of an application which are not supported by the vendor
are not permitted. Vendors respond to security flaws with updates and
patches. These updates are not available for unsupported version which
can leave the application vulnerable to attack.</ns9:rationale>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-installed_firefox_version_supported:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-installed_firefox_version_supported_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-auto-download_actions" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable Automatic Downloads of MIME Types</ns9:title>
          <ns9:description xml:lang="en-US">MIME type files are automatically downloaded or executed in Firefox. This
can be disabled by setting <html:code>browser.helperApps.alwaysAsk.force</html:code> to
<html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">DCMC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF100</ns9:reference>
          <ns9:rationale xml:lang="en-US">The default action for file types for which a plugin is installed is to
automatically download and execute the file using the associated plugin.
Firefox allows users to change the specified download action so that the
file is opened with a selected external application or saved to disk
instead.</ns9:rationale>
          <ns9:fix id="firefox_preferences-auto-download_actions" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("browser.helperApps.alwaysAsk.force", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("browser.helperApps.alwaysAsk.force".*/lockPref("browser.helperApps.alwaysAsk.force", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("browser.helperApps.alwaysAsk.force", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-auto-download_actions:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-auto-download_actions_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_context_menus" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable JavaScript Context Menus</ns9:title>
          <ns9:description xml:lang="en-US">JavaScript can configure and make changes to the web browser's appearance by
specifically disabling or replacing context menus. This can be disabled by
setting <html:code>dom.event.contextmenu.enabled</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF183</ns9:reference>
          <ns9:rationale xml:lang="en-US">A website may execute JavaScript that can make changes to these
context menus. This can help disguise an attack.</ns9:rationale>
          <ns9:fix id="firefox_preferences-javascript_context_menus" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("dom.event.contextmenu.enabled", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("dom.event.contextmenu.enabled".*/lockPref("dom.event.contextmenu.enabled", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("dom.event.contextmenu.enabled", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-javascript_context_menus:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-javascript_context_menus_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-open_confirmation" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Enable Downloading and Opening File Confirmation</ns9:title>
          <ns9:description xml:lang="en-US">To have an action dialog box appear promping users what action to take when
certain types of files are downloaded or opened, set
<html:code>plugin.disable_full_page_plugin_for_types</html:code> to
<html:code><ns9:sub idref="xccdf_org.ssgproject.content_value_var_required_file_types" use="legacy"/></html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF110</ns9:reference>
          <ns9:rationale xml:lang="en-US">When the user receives a dialog box asking if they want to save the file
or open it with a specified application, this indicates that a plugin does
not exist. Also, the user has not previously selected a download action or helper
application to automatically use for that type of file. When prompted, if the user
checks the option to 'Do this automatically for files like this from now on', then
an entry will appear for that type of file in the plugins listing, and this file
type is automatically opened in the future. This can be a security issue. New file
types cannot be added directly to the Application plugin listing.</ns9:rationale>
          <ns9:fix id="firefox_preferences-open_confirmation" system="urn:xccdf:fix:script:sh">
var_required_file_types="<ns9:sub idref="xccdf_org.ssgproject.content_value_var_required_file_types" use="legacy"/>"


firefox_cfg="stig.cfg"
value="\"${var_required_file_types}\""
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("plugin.disable_full_page_plugin_for_types", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's|lockPref("plugin.disable_full_page_plugin_for_types".*|lockPref("plugin.disable_full_page_plugin_for_types", '"$value)"';|g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("plugin.disable_full_page_plugin_for_types", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-export export-name="oval:ssg-var_required_file_types:var:1" value-id="xccdf_org.ssgproject.content_value_var_required_file_types"/>
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-open_confirmation:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-open_confirmation_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-verification" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Enable Certificate Verification</ns9:title>
          <ns9:description xml:lang="en-US">Firefox can be configured to prompt the user to choose a certificate
to present to a website when asked. To enable certificate verification, 
set <html:code>security.default_personal_cert</html:code> to <html:code>Ask Every Time</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF050</ns9:reference>
          <ns9:rationale xml:lang="en-US">Websites within DoD require user authentication for access which increases
security for DoD information. Access will be denied to the user if
certificate management is not configured.</ns9:rationale>
          <ns9:fix id="firefox_preferences-verification" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="\"Ask Every Time\""
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("security.default_personal_cert", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("security.default_personal_cert".*/lockPref("security.default_personal_cert", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("security.default_personal_cert", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-verification:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-verification_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_window_resizing" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable JavaScript's Moving Or Resizing Windows Capability</ns9:title>
          <ns9:description xml:lang="en-US">JavaScript can configure and make changes to the web browser's appearance by
specifically moving and resizing browser windows. This can be disabled by
setting <html:code>dom.disable_window_move_resize</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF181</ns9:reference>
          <ns9:rationale xml:lang="en-US">JavaScript can make changes to the browser&#x2019;s appearance. This activity
can help disguise an attack taking place in a minimized background window.</ns9:rationale>
          <ns9:fix id="firefox_preferences-javascript_window_resizing" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("dom.disable_window_move_resize", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("dom.disable_window_move_resize".*/lockPref("dom.disable_window_move_resize", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("dom.disable_window_move_resize", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-javascript_window_resizing:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-javascript_window_resizing_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-search_update" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable Installed Search Plugins Update Checking</ns9:title>
          <ns9:description xml:lang="en-US">Firefox automatically checks for updated versions of search plugins.
To disable the automatic updates of plugins, set
<html:code>browser.search.update</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF085</ns9:reference>
          <ns9:rationale xml:lang="en-US">Updates need to be controlled and installed from authorized and trusted servers.
This setting overrides a number of other settings which may direct the application
to access external URLs.</ns9:rationale>
          <ns9:fix id="firefox_preferences-search_update" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("browser.search.update", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("browser.search.update".*/lockPref("browser.search.update", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("browser.search.update", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-search_update:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-search_update_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-autofill_forms" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable Autofill Form Assistance</ns9:title>
          <ns9:description xml:lang="en-US">Firefox provides tools to auto-fill forms from prefilled information.
This can be disabled by setting <html:code>browser.formfill.enable</html:code> to
<html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF140</ns9:reference>
          <ns9:rationale xml:lang="en-US">In order to protect privacy and sensitive data, Firefox provides
the ability to configure Firefox such that data entered into forms
is not saved. This mitigates the risk of a website gleaning private
information from prefilled information.</ns9:rationale>
          <ns9:fix id="firefox_preferences-autofill_forms" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("browser.formfill.enable", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("browser.formfill.enable".*/lockPref("browser.formfill.enable", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("browser.formfill.enable", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-autofill_forms:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-autofill_forms_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-shell_protocol" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable Firefox Access to Shell Protocols</ns9:title>
          <ns9:description xml:lang="en-US">Access to the shell is disabled by default but can be changed.
To prevent shell access from being enabled, set
<html:code>network.protocol-handler.external.shell</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF105</ns9:reference>
          <ns9:rationale xml:lang="en-US">If enabled, this setting would allow the browser to access the Windows shell.
This could allow access to the underlying system.</ns9:rationale>
          <ns9:fix id="firefox_preferences-shell_protocol" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("network.protocol-handler.external.shell", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("network.protocol-handler.external.shell".*/lockPref("network.protocol-handler.external.shell", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("network.protocol-handler.external.shell", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-shell_protocol:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-shell_protocol_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-addons_plugin_updates" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable Addons Plugin Updates</ns9:title>
          <ns9:description xml:lang="en-US">Firefox automatically updates installed add-ons and plugins which 
can be disabled by setting <html:code>extensions.update.enabled</html:code> to
<html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF090</ns9:reference>
          <ns9:rationale xml:lang="en-US">Automatic updates from untrusted sites puts the enclave at
risk of attack and may override security settings.</ns9:rationale>
          <ns9:fix id="firefox_preferences-addons_plugin_updates" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("extensions.update.enabled", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("extensions.update.enabled".*/lockPref("extensions.update.enabled", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("extensions.update.enabled", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-addons_plugin_updates:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-addons_plugin_updates_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-autofill_passwords" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable User Ability To Autofill Passwords</ns9:title>
          <ns9:description xml:lang="en-US">Firefox automatically allows users to save passwords to be auto-filled
into password forms. This can be disabled by setting
<html:code>signon.prefillForms</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF150</ns9:reference>
          <ns9:rationale xml:lang="en-US">While on the internet, it may be possible for an attacker to view
the saved password files and gain access to the user's accounts on
various hosts.</ns9:rationale>
          <ns9:fix id="firefox_preferences-autofill_passwords" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("signon.prefillForms", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("signon.prefillForms".*/lockPref("signon.prefillForms", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("signon.prefillForms", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-autofill_passwords:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-autofill_passwords_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-ssl_version_2" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable SSL Version 2.0 in Firefox</ns9:title>
          <ns9:description xml:lang="en-US">SSL version 2 is not enabled by default and should not be enabled.
To prevent SSL version 2 from being enabled set
<html:code>security.enable_ssl2</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF010</ns9:reference>
          <ns9:rationale xml:lang="en-US">Use of versions prior to TLS 1.0 are not permitted because these versions are
non-standard. SSL 2.0 and SSL 3.0 contain a number of security flaws.</ns9:rationale>
          <ns9:fix id="firefox_preferences-ssl_version_2" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("security.enable_ssl2", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("security.enable_ssl2".*/lockPref("security.enable_ssl2", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("security.enable_ssl2", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-ssl_version_2:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-ssl_version_2_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-ssl_protocol_tls" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Enable TLS Usage in Firefox</ns9:title>
          <ns9:description xml:lang="en-US">To enable TLS, set <html:code>security.enable_tls</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF030</ns9:reference>
          <ns9:rationale xml:lang="en-US">Earlier versions of SSL have known security vulnerabilities and are not
authorized for use in DOD environments.</ns9:rationale>
          <ns9:fix id="firefox_preferences-ssl_protocol_tls" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("security.enable_tls", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("security.enable_tls".*/lockPref("security.enable_tls", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("security.enable_tls", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-ssl_protocol_tls:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-ssl_protocol_tls_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_status_bar_text" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable JavaScript's Ability To Modify The Browser Appearance</ns9:title>
          <ns9:description xml:lang="en-US">JavaScript can configure and make changes to the web browser's appearance by
specifically hiding the status bar from view. This can disabled by 
setting <html:code>dom.disable_window_open_feature.status</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF185</ns9:reference>
          <ns9:rationale xml:lang="en-US">JavaScript can make changes to the browser&#x2019;s appearance. This activity
can help disguise an attack taking place in a minimized background window.
Webpage authors can disable many features of a popup window that they open.
This setting prevents the status bar from being hidden.</ns9:rationale>
          <ns9:fix id="firefox_preferences-javascript_status_bar_text" system="urn:xccdf:fix:script:sh">


firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("dom.disable_window_open_feature.status", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("dom.disable_window_open_feature.status".*/lockPref("dom.disable_window_open_feature.status", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("dom.disable_window_open_feature.status", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-javascript_status_bar_text:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-javascript_status_bar_text_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_window_changes" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable JavaScript's Raise Or Lower Windows Capability</ns9:title>
          <ns9:description xml:lang="en-US">JavaScript can configure and make changes to the web browser's appearance by
specifically raising and lowering windows. This can be disabled by
setting <html:code>dom.disable_window_flip</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF182</ns9:reference>
          <ns9:rationale xml:lang="en-US">JavaScript can make changes to the browser&#x2019;s appearance. Allowing a website
to use JavaScript to raise and lower browser windows may disguise an attack.</ns9:rationale>
          <ns9:fix id="firefox_preferences-javascript_window_changes" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("dom.disable_window_flip", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("dom.disable_window_flip".*/lockPref("dom.disable_window_flip", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("dom.disable_window_flip", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-javascript_window_changes:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-javascript_window_changes_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-javascript_status_bar_changes" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable JavaScript's Ability To Change The Status Bar</ns9:title>
          <ns9:description xml:lang="en-US">JavaScript can configure and make changes to the web browser's appearance by
specifically hiding or changing the status bar. This can be disabled by
setting <html:code>dom.disable_window_status_change</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF184</ns9:reference>
          <ns9:rationale xml:lang="en-US">When a user visits some webpages, JavaScript can hide or make changes
to the browser&#x2019;s appearance to hide unauthorized activity. This activity
can help disguise an attack taking place in a minimized background window.</ns9:rationale>
          <ns9:fix id="firefox_preferences-javascript_status_bar_changes" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("dom.disable_window_status_change", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("dom.disable_window_status_change".*/lockPref("dom.disable_window_status_change", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("dom.disable_window_status_change", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-javascript_status_bar_changes:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-javascript_status_bar_changes_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-auto-update_of_firefox" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Disable Firefox Auto-Update Capability</ns9:title>
          <ns9:description xml:lang="en-US">Firefox can be set to automatically update as new updates. This can be
disabled by setting <html:code>app.update.enable</html:code> to <html:code>false</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF080</ns9:reference>
          <ns9:rationale xml:lang="en-US">Allowing software updates from non-trusted sites can introduce settings
that will override a secured installation of the application. This can
place DoD information at risk. If this setting is enabled, then there are
many other default settings which point to untrusted sites which must be
changed to point to an authorized update site that is not publicly accessible.</ns9:rationale>
          <ns9:fix id="firefox_preferences-auto-update_of_firefox" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("app.update.enabled", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("app.update.enabled".*/lockPref("app.update.enabled", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("app.update.enabled", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-auto-update_of_firefox:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-auto-update_of_firefox_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-pop-up_windows" selected="false" severity="medium">
          <ns9:title xml:lang="en-US">Enable Firefox Pop-up Blocker</ns9:title>
          <ns9:description xml:lang="en-US">The pop-up blocker can be enabled by setting
<html:code>dom.disable_window_open_feature.status</html:code> to <html:code>true</html:code>.</ns9:description>
          <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
          <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF180</ns9:reference>
          <ns9:rationale xml:lang="en-US">Popup windows may be used to launch an attack within a new browser window
with altered settings.</ns9:rationale>
          <ns9:fix id="firefox_preferences-pop-up_windows" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("dom.disable_window_open_feature.status", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("dom.disable_window_open_feature.status".*/lockPref("dom.disable_window_open_feature.status", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("dom.disable_window_open_feature.status", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
          <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
            <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-pop-up_windows:def:1"/>
          </ns9:check>
          <ns9:check system="http://scap.nist.gov/schema/ocil/2">
            <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-pop-up_windows_ocil:questionnaire:1"/>
          </ns9:check>
        </ns9:Rule>
        <ns9:Group id="xccdf_org.ssgproject.content_group_firefox_preferences-lock_settings">
          <ns9:title xml:lang="en-US">Prevent Users from Changing Firefox Configuration Settings</ns9:title>
          <ns9:description xml:lang="en-US">Firefox required security preferences cannot be changed by users.</ns9:description>
          <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-lock_settings_config_file" selected="false" severity="medium">
            <ns9:title xml:lang="en-US">Set Firefox Configuration File Location</ns9:title>
            <ns9:description xml:lang="en-US">Specify the Firefox configuration file location by setting 
<html:code>general.config.filename</html:code> to the configuration (i.e. <html:code>mozilla.cfg</html:code>)
filename that contains the Firefox security preferences.</ns9:description>
            <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
            <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF070</ns9:reference>
            <ns9:rationale xml:lang="en-US">Locked settings prevents users from accessing about:config and changing
the security settings set by the system administrator.</ns9:rationale>
            <ns9:fix id="firefox_preferences-lock_settings_config_file" system="urn:xccdf:fix:script:sh">

value="\"stig.cfg\""
firefox_js="stig_settings.js"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"
firefox_pref="/defaults/pref"
firefox_preferences="/defaults/preferences"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Different versions of Firefox have different preferences directories, check for them and set the right one
        if [ -d "${firefox_dir}/${firefox_pref}" ] ; then
            firefox_pref_dir="${firefox_dir}/${firefox_pref}"
        elif [ -d "${firefox_dir}/${firefox_preferences}" ] ; then
            firefox_pref_dir="${firefox_dir}/${firefox_preferences}"
        else
            mkdir -m 755 -p "${firefox_dir}/${firefox_preferences}"
            firefox_pref_dir="${firefox_dir}/${firefox_preferences}"
        fi

        # Make sure the Firefox .js file exists and has the appropriate permissions
        if ! [ -f "${firefox_pref_dir}/${firefox_js}" ] ; then
            touch "${firefox_pref_dir}/${firefox_js}"
            chmod 644 "${firefox_pref_dir}/${firefox_js}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^pref("general.config.filename", ' "${firefox_pref_dir}/${firefox_js}"; then
            sed -i 's/pref("general.config.filename".*/pref("general.config.filename", '"$value)"';/g' "${firefox_pref_dir}/${firefox_js}"
        else
            echo 'pref("general.config.filename", '"$value"');' &gt;&gt; "${firefox_pref_dir}/${firefox_js}"
        fi
    fi
done
</ns9:fix>
            <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
              <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-lock_settings_config_file:def:1"/>
            </ns9:check>
            <ns9:check system="http://scap.nist.gov/schema/ocil/2">
              <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-lock_settings_config_file_ocil:questionnaire:1"/>
            </ns9:check>
          </ns9:Rule>
          <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-lock_settings_obscure" selected="false" severity="medium">
            <ns9:title xml:lang="en-US">Disable Firefox Configuration File ROT-13 Encoding</ns9:title>
            <ns9:description xml:lang="en-US">Disable ROT-13 encoding by setting <html:code>general.config.obscure_value</html:code>
to <html:code>0</html:code>.</ns9:description>
            <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
            <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF070</ns9:reference>
            <ns9:rationale xml:lang="en-US">ROT-13 encoded prevents system adminstrators from easily configuring
and deploying Firefox configuration settings. It also prevents validating
settings easily from automated security tools.</ns9:rationale>
            <ns9:fix id="firefox_preferences-lock_settings_obscure" system="urn:xccdf:fix:script:sh">

value="0"
firefox_js="stig_settings.js"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"
firefox_pref="/defaults/pref"
firefox_preferences="/defaults/preferences"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Different versions of Firefox have different preferences directories, check for them and set the right one
        if [ -d "${firefox_dir}/${firefox_pref}" ] ; then
            firefox_pref_dir="${firefox_dir}/${firefox_pref}"
        elif [ -d "${firefox_dir}/${firefox_preferences}" ] ; then
            firefox_pref_dir="${firefox_dir}/${firefox_preferences}"
        else
            mkdir -m 755 -p "${firefox_dir}/${firefox_preferences}"
            firefox_pref_dir="${firefox_dir}/${firefox_preferences}"
        fi

        # Make sure the Firefox .js file exists and has the appropriate permissions
        if ! [ -f "${firefox_pref_dir}/${firefox_js}" ] ; then
            touch "${firefox_pref_dir}/${firefox_js}"
            chmod 644 "${firefox_pref_dir}/${firefox_js}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^pref("general.config.obscure_value", ' "${firefox_pref_dir}/${firefox_js}"; then
            sed -i 's/pref("general.config.obscure_value".*/pref("general.config.obscure_value", '"$value)"';/g' "${firefox_pref_dir}/${firefox_js}"
        else
            echo 'pref("general.config.obscure_value", '"$value"');' &gt;&gt; "${firefox_pref_dir}/${firefox_js}"
        fi
    fi
done
</ns9:fix>
            <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
              <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-lock_settings_obscure:def:1"/>
            </ns9:check>
            <ns9:check system="http://scap.nist.gov/schema/ocil/2">
              <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-lock_settings_obscure_ocil:questionnaire:1"/>
            </ns9:check>
          </ns9:Rule>
        </ns9:Group>
        <ns9:Group id="xccdf_org.ssgproject.content_group_firefox_preferences-dod_root_certificate">
          <ns9:title xml:lang="en-US">The DoD Root Certificate Is Required</ns9:title>
          <ns9:description xml:lang="en-US">The Shared System Certificates store contains certificates that
applications can access for a single certificate repository.
If enabled, Firefox can access that single system certificate
repository. If the DoD root certificate is also installed into
the shared system certificate repository, Firefox will see and 
use the DoD root certificate as a valid certificate authority.</ns9:description>
          <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-enable_ca_trust" selected="false" severity="medium">
            <ns9:title xml:lang="en-US">Enable Shared System Certificates</ns9:title>
            <ns9:description xml:lang="en-US">The Shared System Certificates store makes NSS, GnuTLS, OpenSSL, and Java
share a default source for retrieving system certificate anchors and blacklist
information. Firefox has the capability of using this centralized store for its
CA certificates. If the Shared System Certificates store is disabled, it can
be enabled by running the following command:
<html:pre>$ sudo update-ca-trust enable</html:pre></ns9:description>
            <ns9:reference href="https://public.cyber.mil/stigs/cci/">CCI-000054</ns9:reference>
            <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">AC-10</ns9:reference>
            <ns9:rationale xml:lang="en-US">The DOD root certificate will ensure that the trust chain is
established for server certificates issued from the DOD CA.</ns9:rationale>
            <ns9:ident system="https://nvd.nist.gov/cce/index.cfm">CCE-82057-1</ns9:ident>
            <ns9:fix id="firefox_preferences-enable_ca_trust" system="urn:xccdf:fix:script:sh">P11=$(readlink /etc/alternatives/libnssckbi.so*)
P11LIB="/usr/lib/pkcs11/p11-kit-trust.so"
P11LIB64="/usr/lib64/pkcs11/p11-kit-trust.so"

if ! [[ ${P11} == "${P11LIB64}" ]] || ! [[ ${P11} == "${P11LIB}" ]] ; then
   /usr/bin/update-ca-trust enable
fi
</ns9:fix>
            <ns9:check system="http://scap.nist.gov/schema/ocil/2">
              <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-enable_ca_trust_ocil:questionnaire:1"/>
            </ns9:check>
          </ns9:Rule>
          <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-dod_root_certificate_installed" selected="false" severity="medium">
            <ns9:title xml:lang="en-US">The DoD Root Certificate Exists</ns9:title>
            <ns9:description xml:lang="en-US">The DoD root certificate should be installed in the Shared System Certificates store
for Firefox to be able to access the DoD certificate. To install the root certificated
into the Shared System Certificates store, copy the DoD root certificate into
<html:code>/etc/pki/ca-trust/source/anchors</html:code>. Once the file is copied, run the following
command:
<html:pre>$ sudo update-ca-trust extract</html:pre></ns9:description>
            <ns9:reference href="https://public.cyber.mil/stigs/cci/">CCI-000054</ns9:reference>
            <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">AC-10</ns9:reference>
            <ns9:rationale xml:lang="en-US">The DOD root certificate will ensure that the trust chain is
established for server certificates issued from the DOD CA.</ns9:rationale>
            <ns9:ident system="https://nvd.nist.gov/cce/index.cfm">CCE-82056-3</ns9:ident>
            <ns9:check system="http://scap.nist.gov/schema/ocil/2">
              <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-dod_root_certificate_installed_ocil:questionnaire:1"/>
            </ns9:check>
          </ns9:Rule>
        </ns9:Group>
        <ns9:Group id="xccdf_org.ssgproject.content_group_firefox_preferences-cookies">
          <ns9:title xml:lang="en-US">Clearing Cookies And Other Data</ns9:title>
          <ns9:description xml:lang="en-US">Browser preferences should be set to perform a Clear Private Data
operation when closing the browser in order to clear cookies and other
data installed by websites visited during the session.</ns9:description>
          <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-cookies_clear" selected="false" severity="medium">
            <ns9:title xml:lang="en-US">Clear Data When Firefox Closes</ns9:title>
            <ns9:description xml:lang="en-US">When a user browses to a website, cookies and other types of data
get stored on the system. This can be disabled by setting
<html:code>privacy.sanitize.sanitizeOnShutdown</html:code> to <html:code>true</html:code>.</ns9:description>
            <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
            <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF170</ns9:reference>
            <ns9:rationale xml:lang="en-US">Cookies can help websites perform better but can also be part of spyware.
To mitigate this risk, set browser preferences to perform a Clear Private
Data operation when closing the browser in order to clear cookies and
other data installed by websites visited during the session.</ns9:rationale>
            <ns9:fix id="firefox_preferences-cookies_clear" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="true"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("privacy.sanitize.sanitizeOnShutdown", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("privacy.sanitize.sanitizeOnShutdown".*/lockPref("privacy.sanitize.sanitizeOnShutdown", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("privacy.sanitize.sanitizeOnShutdown", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
            <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
              <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-cookies_clear:def:1"/>
            </ns9:check>
            <ns9:check system="http://scap.nist.gov/schema/ocil/2">
              <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-cookies_clear_ocil:questionnaire:1"/>
            </ns9:check>
          </ns9:Rule>
          <ns9:Rule id="xccdf_org.ssgproject.content_rule_firefox_preferences-cookies_user_notice" selected="false" severity="medium">
            <ns9:title xml:lang="en-US">Disable User Prompt When Data Is Cleared</ns9:title>
            <ns9:description xml:lang="en-US">By default, users are asked if it is okay to clear out cookies and data
when Firefox closes. This can be disabled by 
setting <html:code>privacy.sanitize.promptOnSanitize</html:code> to <html:code>false</html:code>.</ns9:description>
            <ns9:reference href="http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-53r4.pdf">ECSC-1</ns9:reference>
            <ns9:reference href="https://public.cyber.mil/stigs/downloads/?_dl_facet_stigs=app-security%2Cbrowser-guidance">FIREFOX-DTBF170</ns9:reference>
            <ns9:rationale xml:lang="en-US">Cookies can help websites perform better but can also be part of spyware.
To mitigate this risk, set browser preferences to perform a Clear Private
Data operation when closing the browser in order to clear cookies and
other data installed by websites visited during the session.</ns9:rationale>
            <ns9:fix id="firefox_preferences-cookies_user_notice" system="urn:xccdf:fix:script:sh">

firefox_cfg="stig.cfg"
value="false"
firefox_dirs="/usr/lib/firefox /usr/lib64/firefox /usr/local/lib/firefox /usr/local/lib64/firefox"

# Check the possible Firefox install directories
for firefox_dir in ${firefox_dirs}; do
    # If the Firefox directory exists, then Firefox is installed
    if [ -d "${firefox_dir}" ]; then
        # Make sure the Firefox .cfg file exists and has the appropriate permissions
        if ! [ -f "${firefox_dir}/${firefox_cfg}" ] ; then
            touch "${firefox_dir}/${firefox_cfg}"
            chmod 644 "${firefox_dir}/${firefox_cfg}"
        fi

        # If the key exists, change it. Otherwise, add it to the config_file.
        if LC_ALL=C grep -m 1 -q '^lockPref("privacy.sanitize.promptOnSanitize", ' "${firefox_dir}/${firefox_cfg}"; then
            sed -i 's/lockPref("privacy.sanitize.promptOnSanitize".*/lockPref("privacy.sanitize.promptOnSanitize", '"$value)"';/g' "${firefox_dir}/${firefox_cfg}"
        else
            echo 'lockPref("privacy.sanitize.promptOnSanitize", '"$value"');' &gt;&gt; "${firefox_dir}/${firefox_cfg}"
        fi
    fi
done
</ns9:fix>
            <ns9:check system="http://oval.mitre.org/XMLSchema/oval-definitions-5">
              <ns9:check-content-ref href="ssg-firefox-oval.xml" name="oval:ssg-firefox_preferences-cookies_user_notice:def:1"/>
            </ns9:check>
            <ns9:check system="http://scap.nist.gov/schema/ocil/2">
              <ns9:check-content-ref href="ssg-firefox-ocil.xml" name="ocil:ssg-firefox_preferences-cookies_user_notice_ocil:questionnaire:1"/>
            </ns9:check>
          </ns9:Rule>
        </ns9:Group>
      </ns9:Group>
    </ns9:Benchmark>
  </ns0:component>
  <ns0:component id="scap_org.open-scap_comp_ssg-firefox-cpe-oval.xml" timestamp="2020-01-16T13:51:05">
    <ns3:oval_definitions xsi:schemaLocation="http://oval.mitre.org/XMLSchema/oval-common-5 oval-common-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5 oval-definitions-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5#independent independent-definitions-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5#unix unix-definitions-schema.xsd         http://oval.mitre.org/XMLSchema/oval-definitions-5#linux linux-definitions-schema.xsd">
      <ns3:generator>
        <ns5:product_name>combine_ovals.py from SCAP Security Guide</ns5:product_name>
        <ns5:product_version>ssg: [0, 1, 48], python: 3.7.6</ns5:product_version>
        <ns5:schema_version>5.11</ns5:schema_version>
        <ns5:timestamp>2020-01-16T13:51:04</ns5:timestamp>
      </ns3:generator>
      <ns3:definitions>
        <ns3:definition class="inventory" id="oval:ssg-installed_app_is_firefox:def:1" version="2">
          <ns3:metadata>
            <ns3:title>Mozilla Firefox</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:reference ref_id="cpe:/a:mozilla:firefox" source="CPE"/>
            <ns3:description>The application installed on the system is firefox.</ns3:description>
          </ns3:metadata>
          <ns3:criteria operator="AND">
            <ns3:extend_definition comment="Installed OS is part of the Unix family" definition_ref="oval:ssg-installed_OS_is_part_of_Unix_family:def:1"/>
            <ns3:criterion comment="Firefox is installed" test_ref="oval:ssg-test_firefox:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
        <ns3:definition class="inventory" id="oval:ssg-installed_OS_is_part_of_Unix_family:def:1" version="1">
          <ns3:metadata>
            <ns3:title>Installed operating system is part of the Unix family</ns3:title>
            <ns3:affected family="unix">
              <ns3:product>Firefox</ns3:product>
            </ns3:affected>
            <ns3:description>The operating system installed on the system is part of the Unix OS family</ns3:description>
          </ns3:metadata>
          <ns3:criteria>
            <ns3:criterion comment="Installed operating system is part of the unix family" test_ref="oval:ssg-test_unix_family:tst:1"/>
          </ns3:criteria>
        </ns3:definition>
      </ns3:definitions>
      <ns3:tests>
        <ns7:rpminfo_test check="all" check_existence="at_least_one_exists" comment="Firefox is installed" id="oval:ssg-test_firefox:tst:1" version="1">
          <ns7:object object_ref="oval:ssg-obj_firefox:obj:1"/>
        </ns7:rpminfo_test>
        <ns6:family_test check="all" check_existence="at_least_one_exists" comment="Test installed OS is part of the unix family" id="oval:ssg-test_unix_family:tst:1" version="1">
          <ns6:object object_ref="oval:ssg-object_unix_family:obj:1"/>
          <ns6:state state_ref="oval:ssg-state_unix_family:ste:1"/>
        </ns6:family_test>
      </ns3:tests>
      <ns3:objects>
        <ns7:rpminfo_object id="oval:ssg-obj_firefox:obj:1" version="1">
          <ns7:name>firefox</ns7:name>
        </ns7:rpminfo_object>
        <ns6:family_object id="oval:ssg-object_unix_family:obj:1" version="1"/>
      </ns3:objects>
      <ns3:states>
        <ns6:family_state id="oval:ssg-state_unix_family:ste:1" version="1">
          <ns6:family>unix</ns6:family>
        </ns6:family_state>
      </ns3:states>
    </ns3:oval_definitions>
  </ns0:component>
  <ns0:component id="scap_org.open-scap_comp_ssg-firefox-cpe-dictionary.xml" timestamp="2020-01-16T13:51:05">
    <ns12:cpe-list xsi:schemaLocation="http://cpe.mitre.org/dictionary/2.0 http://cpe.mitre.org/files/cpe-dictionary_2.1.xsd">
      <ns12:cpe-item name="cpe:/a:mozilla:firefox">
        <ns12:title xml:lang="en-us">Mozilla Firefox</ns12:title>
        <ns12:check href="ssg-firefox-cpe-oval.xml" system="http://oval.mitre.org/XMLSchema/oval-definitions-5">oval:ssg-installed_app_is_firefox:def:1</ns12:check>
      </ns12:cpe-item>
    </ns12:cpe-list>
  </ns0:component>
</ns0:data-stream-collection>
