diff --git a/.github/workflows/automatus-cs9.yaml b/.github/workflows/automatus-cs9.yaml index 08e494a96134..06c3e048eb32 100644 --- a/.github/workflows/automatus-cs9.yaml +++ b/.github/workflows/automatus-cs9.yaml @@ -19,11 +19,11 @@ jobs: - name: Install deps python run: pip install gitpython xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -40,7 +40,7 @@ jobs: - name: Test if there are no content changes run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -58,7 +58,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product rhel9 --derivatives - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -71,9 +71,9 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install cmake ninja-build libopenscap8 libxml2-utils xsltproc python3-jinja2 python3-yaml ansible-lint podman - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json @@ -130,7 +130,7 @@ jobs: with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -151,7 +151,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ @@ -167,7 +167,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ diff --git a/.github/workflows/automatus-debian12.yaml b/.github/workflows/automatus-debian12.yaml index 396b65549587..deba2d2a2cdf 100644 --- a/.github/workflows/automatus-debian12.yaml +++ b/.github/workflows/automatus-debian12.yaml @@ -1,9 +1,11 @@ name: Automatus Debian 12 on: pull_request: - branches: [ master, 'stabilization*' ] + branches: [master, 'stabilization*'] concurrency: - group: ${{ github.workflow }}-${{ github.event.number || github.run_id }} + group: >- + ${{ github.workflow }}-${{ + github.event.number || github.run_id }} cancel-in-progress: true env: DATASTREAM: ssg-debian12-ds.xml @@ -13,32 +15,62 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Install Deps - run: sudo apt-get update && sudo apt-get install -y cmake ninja-build python3-yaml python3-jinja2 git python3-deepdiff python3-requests jq python3-pip libxml2-utils xsltproc ansible-lint wget libdbus-1-dev libdbus-glib-1-dev libcurl4-openssl-dev libgcrypt20-dev libselinux1-dev libxslt1-dev libgconf2-dev libacl1-dev libblkid-dev libcap-dev libxml2-dev libldap2-dev libpcre3-dev python3 swig libxml-parser-perl libxml-xpath-perl libperl-dev libbz2-dev librpm-dev g++ libyaml-dev libxmlsec1-dev libxmlsec1-openssl + run: | + sudo apt-get update && sudo apt-get install -y \ + cmake ninja-build python3-yaml \ + python3-jinja2 git python3-deepdiff \ + python3-requests jq python3-pip \ + libxml2-utils xsltproc ansible-lint wget \ + libdbus-1-dev libdbus-glib-1-dev \ + libcurl4-openssl-dev libgcrypt20-dev \ + libselinux1-dev libxslt1-dev \ + libgconf2-dev libacl1-dev libblkid-dev \ + libcap-dev libxml2-dev libldap2-dev \ + libpcre3-dev python3 swig \ + libxml-parser-perl libxml-xpath-perl \ + libperl-dev libbz2-dev librpm-dev g++ \ + libyaml-dev libxmlsec1-dev \ + libxmlsec1-openssl - name: Install deps python - run: pip3 install gitpython xmldiff compliance-trestle==2.4.0 lxml lxml-stubs requests + run: pip3 install gitpython xmldiff lxml lxml-stubs requests - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf # https://github.com/actions/checkout/issues/766 - name: Set git safe directory - run: git config --global --add safe.directory "$GITHUB_WORKSPACE" + run: >- + git config --global --add safe.directory + "$GITHUB_WORKSPACE" - name: Find forking point env: BASE_BRANCH: ${{ github.base_ref }} - run: echo "FORK_POINT=$(git merge-base origin/$BASE_BRANCH ${{ github.event.pull_request.head.sha }})" >> $GITHUB_OUTPUT + run: | + FORK_POINT=$(git merge-base \ + origin/$BASE_BRANCH \ + ${{ github.event.pull_request.head.sha }}) + echo "FORK_POINT=$FORK_POINT" >> $GITHUB_OUTPUT id: fork_point - name: Detect content changes in the PR - run: python3 ./ctf/content_test_filtering.py pr --base ${{ steps.fork_point.outputs.FORK_POINT }} --remote_repo ${{ github.server_url }}/${{ github.repository }} --verbose --rule --output json ${{ github.event.pull_request.number }} > output.json + run: | + python3 ./ctf/content_test_filtering.py pr \ + --base ${{ steps.fork_point.outputs.FORK_POINT }} \ + --remote_repo \ + ${{ github.server_url }}/${{ github.repository }} \ + --verbose --rule --output json \ + ${{ github.event.pull_request.number }} \ + > output.json - name: Test if there are no content changes - run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT + run: >- + echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" + output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -49,12 +81,15 @@ jobs: - name: Get product attribute if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: product + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'product' - name: Download OpenSCAP - run: wget https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz + run: | + wget \ + https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz - name: Extract OpenSCAP run: tar xf openscap-1.3.10.tar.gz - name: Build OpenSCAP @@ -65,7 +100,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product debian12 - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -76,19 +111,36 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Install Deps - run: sudo apt update && sudo apt install -y cmake ninja-build libxml2-utils xsltproc python3-jinja2 python3-yaml ansible-lint podman wget libdbus-1-dev libdbus-glib-1-dev libcurl4-openssl-dev libgcrypt20-dev libselinux1-dev libxslt1-dev libgconf2-dev libacl1-dev libblkid-dev libcap-dev libxml2-dev libldap2-dev libpcre3-dev python3 swig libxml-parser-perl libxml-xpath-perl libperl-dev libbz2-dev librpm-dev g++ libyaml-dev libxmlsec1-dev libxmlsec1-openssl + run: | + sudo apt update && sudo apt install -y \ + cmake ninja-build libxml2-utils xsltproc \ + python3-jinja2 python3-yaml ansible-lint \ + podman wget \ + libdbus-1-dev libdbus-glib-1-dev \ + libcurl4-openssl-dev libgcrypt20-dev \ + libselinux1-dev libxslt1-dev \ + libgconf2-dev libacl1-dev libblkid-dev \ + libcap-dev libxml2-dev libldap2-dev \ + libpcre3-dev python3 swig \ + libxml-parser-perl libxml-xpath-perl \ + libperl-dev libbz2-dev librpm-dev g++ \ + libyaml-dev libxmlsec1-dev \ + libxmlsec1-openssl - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json - # continue even if the file is unavailable that - # means there are no changes detected by CTF in the previous job + # continue even if the file is unavailable; + # that means there are no changes detected + # by CTF in the previous job continue-on-error: true - name: Download OpenSCAP - run: wget https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz + run: | + wget \ + https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz - name: Extract OpenSCAP run: tar xf openscap-1.3.10.tar.gz - name: Build OpenSCAP @@ -97,21 +149,33 @@ jobs: cmake -Bbuild -DCMAKE_INSTALL_PREFIX=/usr . sudo cmake --build build --target install - name: Test if there are no content changes - if: ${{ steps.get_ctf_output.outcome == 'success' }} - run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT + if: >- + ${{ steps.get_ctf_output.outcome == 'success' }} + run: >- + echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" + output.json)" >> $GITHUB_OUTPUT id: ctf - name: Print changes to content detected if any - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: cat output.json - name: Generate id_rsa key - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ssh-keygen -N '' -t rsa -f ~/.ssh/id_rsa - name: Build test suite container - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: podman build --build-arg "CLIENT_PUBLIC_KEY=$(cat ~/.ssh/id_rsa.pub)" -t ssg_test_suite -f test_suite-debian12 + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + run: | + podman build \ + --build-arg \ + "CLIENT_PUBLIC_KEY=$(cat ~/.ssh/id_rsa.pub)" \ + -t ssg_test_suite \ + -f test_suite-debian12 working-directory: ./Dockerfiles - name: Get oscap-ssh - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: | wget https://raw.githubusercontent.com/OpenSCAP/openscap/maint-1.3/utils/oscap-ssh sudo chmod 755 oscap-ssh @@ -119,77 +183,135 @@ jobs: sudo chown root:root /usr/local/bin/oscap-ssh rm -f oscap-ssh - name: Get rule ids to be tested - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: rules + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'rules' - name: Get product attribute - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: product + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'product' - name: Get bash attribute - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: bash + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'bash' - name: Get ansible attribute - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: ansible + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} - name: Run tests in a container - Bash - if: ${{steps.bash.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: tests/test_rule_in_container.sh --no-make-applicable-in-containers --dontclean --logdir logs_bash --remediate-using bash --name ssg_test_suite --datastream $DATASTREAM ${{join(fromJSON(steps.rules.outputs.prop))}} + if: >- + ${{steps.bash.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + run: | + tests/test_rule_in_container.sh \ + --no-make-applicable-in-containers \ + --dontclean \ + --logdir logs_bash \ + --remediate-using bash \ + --name ssg_test_suite \ + --datastream $DATASTREAM \ + ${{join(fromJSON(steps.rules.outputs.prop))}} env: - ADDITIONAL_TEST_OPTIONS: "--duplicate-templates --remove-fips-certified" + ADDITIONAL_TEST_OPTIONS: >- + --duplicate-templates + --remove-fips-certified - name: Check for ERROR in logs - if: ${{steps.bash.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{steps.bash.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: grep -q "^ERROR" logs_bash/test_suite.log id: check_results_bash - # when grep returns 1 means it didn't find the ^ERROR string in the test_suite.log file - # and this means tests finished successfully without errors. So the job needs to keep going. - # By using continue-on-error: true the "conclusion" parameter is set to true so it's not possible to use - # it to determine whether the task has failed or succeed. The "outcome" parameter has to be used instead. + # when grep returns 1 means it didn't find the + # ^ERROR string in the test_suite.log file and + # this means tests finished successfully without + # errors. So the job needs to keep going. + # By using continue-on-error: true the + # "conclusion" parameter is set to true so it's + # not possible to use it to determine whether + # the task has failed or succeed. The "outcome" + # parameter has to be used instead. # See the step below continue-on-error: true - name: Upload logs in case of failure - if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + if: >- + ${{steps.bash.outputs.prop == 'True' + && steps.check_results_bash.outcome == 'success' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ - name: Run tests in a container - Ansible - if: ${{ steps.ansible.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: tests/test_rule_in_container.sh --no-make-applicable-in-containers --dontclean --logdir logs_ansible --remediate-using ansible --name ssg_test_suite --datastream $DATASTREAM ${{join(fromJSON(steps.rules.outputs.prop))}} + if: >- + ${{ steps.ansible.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + run: | + tests/test_rule_in_container.sh \ + --no-make-applicable-in-containers \ + --dontclean \ + --logdir logs_ansible \ + --remediate-using ansible \ + --name ssg_test_suite \ + --datastream $DATASTREAM \ + ${{join(fromJSON(steps.rules.outputs.prop))}} env: - ADDITIONAL_TEST_OPTIONS: "--duplicate-templates --remove-fips-certified --product debian12" + ADDITIONAL_TEST_OPTIONS: >- + --duplicate-templates + --remove-fips-certified + --product debian12 - name: Check for ERROR in logs - if: ${{steps.ansible.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{steps.ansible.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: grep -q "^ERROR" logs_ansible/test_suite.log id: check_results_ansible continue-on-error: true - name: Upload logs in case of failure - if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + if: >- + ${{ steps.ansible.outputs.prop == 'True' + && steps.check_results_ansible.outcome == 'success' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ - - name: Fail in case of ERROR present in logs_bash/test_suite.log or logs_ansible/test_suite.log - if: ${{ (steps.check_results_bash.outcome == 'success' || steps.check_results_ansible.outcome == 'success') && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + - name: Fail if ERROR in test logs + if: >- + ${{ (steps.check_results_bash.outcome == 'success' + || steps.check_results_ansible.outcome == 'success') + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: | - [[ -f logs_bash/test_suite.log ]] && echo "---------Bash Remediation Logs---------" && cat logs_bash/test_suite.log | grep -v "DEBUG - " - [[ -f logs_ansible/test_suite.log ]] && echo "---------Ansible Remediation Logs---------" && cat logs_ansible/test_suite.log | grep -v "DEBUG - " + [[ -f logs_bash/test_suite.log ]] \ + && echo "---Bash Remediation Logs---" \ + && cat logs_bash/test_suite.log \ + | grep -v "DEBUG - " + [[ -f logs_ansible/test_suite.log ]] \ + && echo "---Ansible Remediation Logs---" \ + && cat logs_ansible/test_suite.log \ + | grep -v "DEBUG - " exit 1 diff --git a/.github/workflows/automatus-sanity.yaml b/.github/workflows/automatus-sanity.yaml index c5e958fb7d5f..b80a8f0e955d 100644 --- a/.github/workflows/automatus-sanity.yaml +++ b/.github/workflows/automatus-sanity.yaml @@ -17,12 +17,12 @@ jobs: - name: Install Deps run: dnf install -y cmake make openscap-utils python3-pyyaml python3-jinja2 git python3-pip python3-setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Build product run: ./build_product fedora --debug - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: ${{ env.DATASTREAM }} path: build/${{ env.DATASTREAM }} @@ -35,7 +35,7 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install cmake ninja-build libopenscap8 libxml2-utils xsltproc python3-jinja2 python3-yaml ansible-lint podman - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Generate id_rsa key run: ssh-keygen -N '' -t rsa -f ~/.ssh/id_rsa - name: Build test suite container @@ -49,7 +49,7 @@ jobs: sudo chown root:root /usr/local/bin/oscap-ssh rm -f oscap-ssh - name: Get Datastream - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 with: name: ${{ env.DATASTREAM }} - name: Check One Rule diff --git a/.github/workflows/automatus-sle15.yaml b/.github/workflows/automatus-sle15.yaml index a0d833cec24b..d6811e28a118 100644 --- a/.github/workflows/automatus-sle15.yaml +++ b/.github/workflows/automatus-sle15.yaml @@ -27,11 +27,11 @@ jobs: - name: Install deps python run: pip install json2html sphinxcontrib.jinjadomain GitPython deepdiff Jinja2 xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -48,7 +48,7 @@ jobs: - name: Test if there are no content changes run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -66,7 +66,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product sle15 - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -79,9 +79,9 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install cmake ninja-build libopenscap8 libxml2-utils xsltproc python3-jinja2 python3-yaml ansible-lint podman - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json @@ -138,7 +138,7 @@ jobs: with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -159,7 +159,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ @@ -175,7 +175,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ diff --git a/.github/workflows/automatus-ubi8.yaml b/.github/workflows/automatus-ubi8.yaml index 411e2ea05700..0c2d99861dac 100644 --- a/.github/workflows/automatus-ubi8.yaml +++ b/.github/workflows/automatus-ubi8.yaml @@ -19,11 +19,11 @@ jobs: - name: Install deps python run: pip install gitpython xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -40,7 +40,7 @@ jobs: - name: Test if there are no content changes run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -58,7 +58,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product rhel8 --derivatives - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -71,9 +71,9 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install cmake ninja-build libopenscap8 libxml2-utils xsltproc python3-jinja2 python3-yaml ansible-lint podman - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json @@ -130,7 +130,7 @@ jobs: with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -151,7 +151,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ @@ -167,7 +167,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ diff --git a/.github/workflows/automatus-ubuntu2204.yaml b/.github/workflows/automatus-ubuntu2204.yaml index e43f19b9b6b0..3143df3ee9a3 100644 --- a/.github/workflows/automatus-ubuntu2204.yaml +++ b/.github/workflows/automatus-ubuntu2204.yaml @@ -1,9 +1,11 @@ name: Automatus Ubuntu 22.04 on: pull_request: - branches: [ master, 'stabilization*' ] + branches: [master, 'stabilization*'] concurrency: - group: ${{ github.workflow }}-${{ github.event.number || github.run_id }} + group: >- + ${{ github.workflow }}-${{ + github.event.number || github.run_id }} cancel-in-progress: true env: DATASTREAM: ssg-ubuntu2204-ds.xml @@ -13,32 +15,62 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Install Deps - run: sudo apt-get update && sudo apt-get install -y cmake ninja-build python3-yaml python3-jinja2 git python3-deepdiff python3-requests jq python3-pip libxml2-utils xsltproc ansible-lint wget libdbus-1-dev libdbus-glib-1-dev libcurl4-openssl-dev libgcrypt20-dev libselinux1-dev libxslt1-dev libgconf2-dev libacl1-dev libblkid-dev libcap-dev libxml2-dev libldap2-dev libpcre3-dev python3 swig libxml-parser-perl libxml-xpath-perl libperl-dev libbz2-dev librpm-dev g++ libyaml-dev libxmlsec1-dev libxmlsec1-openssl + run: | + sudo apt-get update && sudo apt-get install -y \ + cmake ninja-build python3-yaml \ + python3-jinja2 git python3-deepdiff \ + python3-requests jq python3-pip \ + libxml2-utils xsltproc ansible-lint wget \ + libdbus-1-dev libdbus-glib-1-dev \ + libcurl4-openssl-dev libgcrypt20-dev \ + libselinux1-dev libxslt1-dev \ + libgconf2-dev libacl1-dev libblkid-dev \ + libcap-dev libxml2-dev libldap2-dev \ + libpcre3-dev python3 swig \ + libxml-parser-perl libxml-xpath-perl \ + libperl-dev libbz2-dev librpm-dev g++ \ + libyaml-dev libxmlsec1-dev \ + libxmlsec1-openssl - name: Install deps python - run: pip3 install gitpython xmldiff compliance-trestle==2.4.0 lxml lxml-stubs requests + run: pip3 install gitpython xmldiff lxml lxml-stubs requests - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf # https://github.com/actions/checkout/issues/766 - name: Set git safe directory - run: git config --global --add safe.directory "$GITHUB_WORKSPACE" + run: >- + git config --global --add safe.directory + "$GITHUB_WORKSPACE" - name: Find forking point env: BASE_BRANCH: ${{ github.base_ref }} - run: echo "FORK_POINT=$(git merge-base origin/$BASE_BRANCH ${{ github.event.pull_request.head.sha }})" >> $GITHUB_OUTPUT + run: | + FORK_POINT=$(git merge-base \ + origin/$BASE_BRANCH \ + ${{ github.event.pull_request.head.sha }}) + echo "FORK_POINT=$FORK_POINT" >> $GITHUB_OUTPUT id: fork_point - name: Detect content changes in the PR - run: python3 ./ctf/content_test_filtering.py pr --base ${{ steps.fork_point.outputs.FORK_POINT }} --remote_repo ${{ github.server_url }}/${{ github.repository }} --verbose --rule --output json ${{ github.event.pull_request.number }} > output.json + run: | + python3 ./ctf/content_test_filtering.py pr \ + --base ${{ steps.fork_point.outputs.FORK_POINT }} \ + --remote_repo \ + ${{ github.server_url }}/${{ github.repository }} \ + --verbose --rule --output json \ + ${{ github.event.pull_request.number }} \ + > output.json - name: Test if there are no content changes - run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT + run: >- + echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" + output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -49,12 +81,15 @@ jobs: - name: Get product attribute if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: product + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'product' - name: Download OpenSCAP - run: wget https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz + run: | + wget \ + https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz - name: Extract OpenSCAP run: tar xf openscap-1.3.10.tar.gz - name: Build OpenSCAP @@ -65,7 +100,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product ubuntu2204 - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -76,19 +111,36 @@ jobs: runs-on: ubuntu-22.04 steps: - name: Install Deps - run: sudo apt update && sudo apt install -y cmake ninja-build libxml2-utils xsltproc python3-jinja2 python3-yaml ansible-lint podman wget libdbus-1-dev libdbus-glib-1-dev libcurl4-openssl-dev libgcrypt20-dev libselinux1-dev libxslt1-dev libgconf2-dev libacl1-dev libblkid-dev libcap-dev libxml2-dev libldap2-dev libpcre3-dev python3 swig libxml-parser-perl libxml-xpath-perl libperl-dev libbz2-dev librpm-dev g++ libyaml-dev libxmlsec1-dev libxmlsec1-openssl + run: | + sudo apt update && sudo apt install -y \ + cmake ninja-build libxml2-utils xsltproc \ + python3-jinja2 python3-yaml ansible-lint \ + podman wget \ + libdbus-1-dev libdbus-glib-1-dev \ + libcurl4-openssl-dev libgcrypt20-dev \ + libselinux1-dev libxslt1-dev \ + libgconf2-dev libacl1-dev libblkid-dev \ + libcap-dev libxml2-dev libldap2-dev \ + libpcre3-dev python3 swig \ + libxml-parser-perl libxml-xpath-perl \ + libperl-dev libbz2-dev librpm-dev g++ \ + libyaml-dev libxmlsec1-dev \ + libxmlsec1-openssl - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json - # continue even if the file is unavailable that - # means there are no changes detected by CTF in the previous job + # continue even if the file is unavailable; + # that means there are no changes detected + # by CTF in the previous job continue-on-error: true - name: Download OpenSCAP - run: wget https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz + run: | + wget \ + https://github.com/OpenSCAP/openscap/releases/download/1.3.10/openscap-1.3.10.tar.gz - name: Extract OpenSCAP run: tar xf openscap-1.3.10.tar.gz - name: Build OpenSCAP @@ -97,21 +149,33 @@ jobs: cmake -Bbuild -DCMAKE_INSTALL_PREFIX=/usr . sudo cmake --build build --target install - name: Test if there are no content changes - if: ${{ steps.get_ctf_output.outcome == 'success' }} - run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT + if: >- + ${{ steps.get_ctf_output.outcome == 'success' }} + run: >- + echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" + output.json)" >> $GITHUB_OUTPUT id: ctf - name: Print changes to content detected if any - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: cat output.json - name: Generate id_rsa key - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ssh-keygen -N '' -t rsa -f ~/.ssh/id_rsa - name: Build test suite container - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: podman build --build-arg "CLIENT_PUBLIC_KEY=$(cat ~/.ssh/id_rsa.pub)" -t ssg_test_suite -f test_suite-ubuntu2204 + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + run: | + podman build \ + --build-arg \ + "CLIENT_PUBLIC_KEY=$(cat ~/.ssh/id_rsa.pub)" \ + -t ssg_test_suite \ + -f test_suite-ubuntu2204 working-directory: ./Dockerfiles - name: Get oscap-ssh - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: | wget https://raw.githubusercontent.com/OpenSCAP/openscap/maint-1.3/utils/oscap-ssh sudo chmod 755 oscap-ssh @@ -119,77 +183,135 @@ jobs: sudo chown root:root /usr/local/bin/oscap-ssh rm -f oscap-ssh - name: Get rule ids to be tested - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: rules + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'rules' - name: Get product attribute - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: product + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'product' - name: Get bash attribute - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: bash + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'bash' - name: Get ansible attribute - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} id: ansible + # yamllint disable-line rule:line-length uses: notiz-dev/github-action-json-property@a5a9c668b16513c737c3e1f8956772c99c73f6e8 # v0.2.0 with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 - if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 + if: >- + ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} - name: Run tests in a container - Bash - if: ${{steps.bash.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: tests/test_rule_in_container.sh --no-make-applicable-in-containers --dontclean --logdir logs_bash --remediate-using bash --name ssg_test_suite --datastream $DATASTREAM ${{join(fromJSON(steps.rules.outputs.prop))}} + if: >- + ${{steps.bash.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + run: | + tests/test_rule_in_container.sh \ + --no-make-applicable-in-containers \ + --dontclean \ + --logdir logs_bash \ + --remediate-using bash \ + --name ssg_test_suite \ + --datastream $DATASTREAM \ + ${{join(fromJSON(steps.rules.outputs.prop))}} env: - ADDITIONAL_TEST_OPTIONS: "--duplicate-templates --remove-fips-certified" + ADDITIONAL_TEST_OPTIONS: >- + --duplicate-templates + --remove-fips-certified - name: Check for ERROR in logs - if: ${{steps.bash.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{steps.bash.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: grep -q "^ERROR" logs_bash/test_suite.log id: check_results_bash - # when grep returns 1 means it didn't find the ^ERROR string in the test_suite.log file - # and this means tests finished successfully without errors. So the job needs to keep going. - # By using continue-on-error: true the "conclusion" parameter is set to true so it's not possible to use - # it to determine whether the task has failed or succeed. The "outcome" parameter has to be used instead. + # when grep returns 1 means it didn't find the + # ^ERROR string in the test_suite.log file and + # this means tests finished successfully without + # errors. So the job needs to keep going. + # By using continue-on-error: true the + # "conclusion" parameter is set to true so it's + # not possible to use it to determine whether + # the task has failed or succeed. The "outcome" + # parameter has to be used instead. # See the step below continue-on-error: true - name: Upload logs in case of failure - if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + if: >- + ${{steps.bash.outputs.prop == 'True' + && steps.check_results_bash.outcome == 'success' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ - name: Run tests in a container - Ansible - if: ${{ steps.ansible.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: tests/test_rule_in_container.sh --no-make-applicable-in-containers --dontclean --logdir logs_ansible --remediate-using ansible --name ssg_test_suite --datastream $DATASTREAM ${{join(fromJSON(steps.rules.outputs.prop))}} + if: >- + ${{ steps.ansible.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + run: | + tests/test_rule_in_container.sh \ + --no-make-applicable-in-containers \ + --dontclean \ + --logdir logs_ansible \ + --remediate-using ansible \ + --name ssg_test_suite \ + --datastream $DATASTREAM \ + ${{join(fromJSON(steps.rules.outputs.prop))}} env: - ADDITIONAL_TEST_OPTIONS: "--duplicate-templates --remove-fips-certified --product ubuntu2204" + ADDITIONAL_TEST_OPTIONS: >- + --duplicate-templates + --remove-fips-certified + --product ubuntu2204 - name: Check for ERROR in logs - if: ${{steps.ansible.outputs.prop == 'True' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + if: >- + ${{steps.ansible.outputs.prop == 'True' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: grep -q "^ERROR" logs_ansible/test_suite.log id: check_results_ansible continue-on-error: true - name: Upload logs in case of failure - if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + if: >- + ${{ steps.ansible.outputs.prop == 'True' + && steps.check_results_ansible.outcome == 'success' + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ - - name: Fail in case of ERROR present in logs_bash/test_suite.log or logs_ansible/test_suite.log - if: ${{ (steps.check_results_bash.outcome == 'success' || steps.check_results_ansible.outcome == 'success') && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} + - name: Fail if ERROR in test logs + if: >- + ${{ (steps.check_results_bash.outcome == 'success' + || steps.check_results_ansible.outcome == 'success') + && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: | - [[ -f logs_bash/test_suite.log ]] && echo "---------Bash Remediation Logs---------" && cat logs_bash/test_suite.log | grep -v "DEBUG - " - [[ -f logs_ansible/test_suite.log ]] && echo "---------Ansible Remediation Logs---------" && cat logs_ansible/test_suite.log | grep -v "DEBUG - " + [[ -f logs_bash/test_suite.log ]] \ + && echo "---Bash Remediation Logs---" \ + && cat logs_bash/test_suite.log \ + | grep -v "DEBUG - " + [[ -f logs_ansible/test_suite.log ]] \ + && echo "---Ansible Remediation Logs---" \ + && cat logs_ansible/test_suite.log \ + | grep -v "DEBUG - " exit 1 diff --git a/.github/workflows/automatus-ubuntu2404.yml b/.github/workflows/automatus-ubuntu2404.yml index 95a264ffb007..36e5042da416 100644 --- a/.github/workflows/automatus-ubuntu2404.yml +++ b/.github/workflows/automatus-ubuntu2404.yml @@ -19,11 +19,11 @@ jobs: - name: Install deps python run: pip3 install gitpython xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -40,7 +40,7 @@ jobs: - name: Test if there are no content changes run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -58,7 +58,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product ubuntu2404 --datastream-only - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -71,9 +71,9 @@ jobs: - name: Install test deps run: sudo apt-get update && sudo apt-get install -y cmake ninja-build xsltproc libxml2-utils python3-yaml python3-jinja2 openscap-utils podman - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json @@ -122,7 +122,7 @@ jobs: with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ${{ env.DATASTREAM }} @@ -143,7 +143,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ @@ -159,7 +159,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ diff --git a/.github/workflows/automatus.yaml b/.github/workflows/automatus.yaml index ad3c7dcc319b..63879471742e 100644 --- a/.github/workflows/automatus.yaml +++ b/.github/workflows/automatus.yaml @@ -17,11 +17,11 @@ jobs: - name: Install deps python run: pip install gitpython xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -38,7 +38,7 @@ jobs: - name: Test if there are no content changes run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: output.json @@ -56,7 +56,7 @@ jobs: - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product ${{steps.product.outputs.prop}} --datastream-only - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ssg-${{steps.product.outputs.prop}}-ds.xml @@ -71,9 +71,9 @@ jobs: - name: Install deps python run: pip install ansible setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Get cached CTF output - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 id: get_ctf_output with: name: output.json @@ -130,7 +130,7 @@ jobs: with: path: 'output.json' prop_path: 'ansible' - - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v4 + - uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ssg-${{steps.product.outputs.prop}}-ds.xml @@ -151,7 +151,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{steps.bash.outputs.prop == 'True' && steps.check_results_bash.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_bash path: logs_bash/ @@ -167,7 +167,7 @@ jobs: continue-on-error: true - name: Upload logs in case of failure if: ${{ steps.ansible.outputs.prop == 'True' && steps.check_results_ansible.outcome == 'success' && steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: logs_ansible path: logs_ansible/ diff --git a/.github/workflows/ci_lint.yml b/.github/workflows/ci_lint.yml index 7ff16b73dc4f..81e6ee92aa6f 100644 --- a/.github/workflows/ci_lint.yml +++ b/.github/workflows/ci_lint.yml @@ -3,17 +3,17 @@ on: pull_request: branches: [master, 'stabilization*'] permissions: - contents: read + contents: read jobs: yamllint: - name: Yaml Lint on Changed Controls and Profiles Files + name: Yaml Lint on Changed yaml files runs-on: ubuntu-latest steps: - name: Install Git run: sudo apt-get update && sudo apt-get install -y git - name: Checkout Repository - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3 with: repository: ${{ github.repository }} fetch-depth: 0 @@ -27,37 +27,43 @@ jobs: url="repos/$repo/pulls/$pr_number/files" response=$(gh api "$url" --paginate) echo "$response" | jq -r '.[].filename' > filenames.txt - cat filenames.txt - - if grep -q "controls/" filenames.txt; then - echo "CONTROLS_CHANGES=true" >> $GITHUB_ENV - else - echo "CONTROLS_CHANGES=false" >> $GITHUB_ENV - fi - if grep -q "\.profile" filenames.txt; then - echo "PROFILES_CHANGES=true" >> $GITHUB_ENV - else - echo "PROFILES_CHANGES=false" >> $GITHUB_ENV - fi env: GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Install yamllint - if: ${{ env.CONTROLS_CHANGES == 'true' || env.PROFILES_CHANGES == 'true' }} run: pip install yamllint - - name: Run yamllint in Control Files Modified by PR - if: ${{ env.CONTROLS_CHANGES == 'true' }} - run: | - for control_file in $(cat filenames.txt | grep "controls/"); do - echo "Running yamllint on $control_file..." - yamllint "$control_file" - done - - - name: Run yamllint in Profile Files Modified by PR - if: ${{ env.PROFILES_CHANGES == 'true' }} + - name: Run yamllint on files modified by the PR run: | - for profile_file in $(cat filenames.txt | grep "\.profile"); do - echo "Running yamllint on $profile_file..." - yamllint "$profile_file" + exit_code=0 + for file in $(grep -E '\.(yml|yaml|fmf|profile)$' filenames.txt); do + if [[ ! -f "$file" ]]; then + continue + fi + echo "Running yamllint on $file..." + if grep -qP '\{\{[%{#]' "$file"; then + # File contains Jinja2 constructs — strip them before linting. + # yamllint -s exits: 0 = clean, 1 = errors, 2 = warnings only. + # Use "|| rc=$?" to prevent set -e from killing the script before + # we can capture the exit code and print the diagnostic output. + rc=0 + output=$(python3 utils/strip_jinja_for_yamllint.py "$file" \ + | yamllint -s -c .yamllint - 2>&1) || rc=$? + # Show all output (warnings and errors), replacing "stdin" + # with the actual filename since yamllint reads from a pipe. + if [ -n "$output" ]; then + echo "$output" | sed "s|^stdin|$file|" + fi + # Fail only on errors (exit code 1), not warnings (exit code 2). + if [ "$rc" -eq 1 ]; then + exit_code=1 + fi + else + rc=0 + yamllint -s -c .yamllint "$file" || rc=$? + if [ "$rc" -eq 1 ]; then + exit_code=1 + fi + fi done + exit $exit_code diff --git a/.github/workflows/cis-nist-sync.yml b/.github/workflows/cis-nist-sync.yml new file mode 100644 index 000000000000..7ee6ae22b42c --- /dev/null +++ b/.github/workflows/cis-nist-sync.yml @@ -0,0 +1,124 @@ +name: CIS-NIST Control File Sync + +on: + pull_request: + branches: + - master + schedule: + # Run every Sunday at 2:00 PM UTC + - cron: '0 14 * * 0' + workflow_dispatch: # Allow manual trigger + +jobs: + generate-and-validate: + name: Generate CIS-NIST Control File and Profiles + runs-on: ubuntu-latest + container: + image: fedora:latest + + steps: + - name: Install system dependencies + run: | + dnf install -y \ + cmake \ + make \ + ninja-build \ + openscap-utils \ + python3-pyyaml \ + python3-jinja2 \ + python3-pip \ + git \ + gcc \ + gcc-c++ \ + python3-devel \ + libxml2-devel \ + libxslt-devel \ + python3-setuptools \ + libxml2 \ + expat \ + gh + + - name: Checkout repository + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 + with: + token: ${{ secrets.GITHUB_TOKEN }} + fetch-depth: 0 + + - name: Configure git + run: | + git config --global user.name "github-actions[bot]" + git config --global user.email "github-actions[bot]@users.noreply.github.com" + git config --global --add safe.directory "$GITHUB_WORKSPACE" + + - name: Install Python dependencies + run: | + pip install --upgrade pip + pip install ruamel.yaml PyPDF2 + + - name: Download OSCAL catalog + run: | + cd utils/nist_sync + python3 download_oscal.py + + - name: Run CIS-NIST workflow + id: workflow + run: | + cd utils/nist_sync + echo "Running workflow for products: rhel8 rhel9 rhel10" + ./generate_cis_nist_workflow.sh --products "rhel8 rhel9 rhel10" + + - name: Verify control files + run: ./utils/nist_sync/ci_sync.sh verify + + - name: Render policies and generate HTML tables + run: | + cd build + ninja render-policies + cd .. + mkdir -p artifacts/tables artifacts/rendered-policies + for product in rhel8 rhel9 rhel10; do + SRC="build/$product/rendered-policies/nist_800_53.html" + DEST="artifacts/rendered-policies/nist_800_53-$product.html" + [ -f "$SRC" ] && cp "$SRC" "$DEST" + done + + - name: Collect artifacts + run: ./utils/nist_sync/ci_sync.sh collect-artifacts + + - name: Upload artifacts + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1 + with: + name: cis-nist-artifacts-${{ github.run_number }} + path: artifacts/ + retention-days: 90 + + - name: Generate summary report + run: ./utils/nist_sync/ci_sync.sh summarize + + - name: Check for changes in CIS reference + id: changes + run: ./utils/nist_sync/ci_sync.sh check-changes + + - name: Show diff summary + if: steps.changes.outputs.has_changes == 'true' + run: ./utils/nist_sync/ci_sync.sh show-diff + + - name: Create Pull Request for scheduled runs + if: >- + (github.event_name == 'schedule' || + github.event_name == 'workflow_dispatch') && + steps.changes.outputs.has_changes == 'true' + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GHA_EVENT_NAME: ${{ github.event_name }} + GHA_RUN_ID: ${{ github.run_id }} + GHA_REPOSITORY: ${{ github.repository }} + run: ./utils/nist_sync/ci_sync.sh create-pr + + - name: Workflow Summary + if: always() + env: + GHA_EVENT_NAME: ${{ github.event_name }} + GHA_RUN_ID: ${{ github.run_id }} + HAS_CHANGES: ${{ steps.changes.outputs.has_changes }} + run: ./utils/nist_sync/ci_sync.sh workflow-summary diff --git a/.github/workflows/compare-ds-build.yml b/.github/workflows/compare-ds-build.yml index 55eafa329eca..1fe6d1cb3857 100644 --- a/.github/workflows/compare-ds-build.yml +++ b/.github/workflows/compare-ds-build.yml @@ -18,12 +18,12 @@ jobs: - name: Install deps python run: pip install gitpython xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 with: ref: ${{ github.event.pull_request.head.sha }} fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -49,7 +49,7 @@ jobs: with: path: 'output.json' prop_path: 'product' - - name: Build product ${{ github.base_ref }} (${{ steps.fork_point.outputs.FORK_POINT }}) + - name: Build product PR ${{ github.event.pull_request.head.sha }} if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product ${{steps.product.outputs.prop}} --datastream-only - name: Create Artifact @@ -61,9 +61,9 @@ jobs: tar -czvf artifacts.tar.gz artifacts - name: Upload artifacts if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: - name: pr-artifacts-${{ github.event.pull_request.head.sha }} + name: pr-artifacts retention-days: 1 path: artifacts.tar.gz - name: Save PR info @@ -74,7 +74,7 @@ jobs: echo "${{ github.base_ref }}" > pr-info/base-branch.txt echo "${{ steps.fork_point.outputs.FORK_POINT }}" > pr-info/fork-point.txt - name: Upload PR info - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: pr-info retention-days: 1 diff --git a/.github/workflows/compare-ds.yaml b/.github/workflows/compare-ds.yaml index 19b9aac39258..5ffb19914ce1 100644 --- a/.github/workflows/compare-ds.yaml +++ b/.github/workflows/compare-ds.yaml @@ -8,8 +8,9 @@ permissions: pull-requests: write contents: read actions: read + checks: write jobs: - build-content: + compare_ds_job: name: Generate Diff runs-on: ubuntu-latest container: @@ -20,7 +21,7 @@ jobs: - name: Install deps python run: pip install gitpython xmldiff - name: Download PR info - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 with: github-token: ${{ secrets.GITHUB_TOKEN }} run-id: ${{ github.event.workflow_run.id }} @@ -30,25 +31,38 @@ jobs: id: pr_info run: | PR_NUMBER=$(cat pr-info/pr-number.txt) + PR_SHA=$(cat pr-info/pr-sha.txt) BASE_BRANCH=$(cat pr-info/base-branch.txt) FORK_POINT=$(cat pr-info/fork-point.txt) echo "pr_number=${PR_NUMBER}" >> $GITHUB_OUTPUT + echo "pr_sha=${PR_SHA}" >> $GITHUB_OUTPUT echo "base_branch=${BASE_BRANCH}" >> $GITHUB_OUTPUT echo "fork_point=${FORK_POINT}" >> $GITHUB_OUTPUT echo "PR Number: ${PR_NUMBER}" + echo "PR SHA: ${PR_SHA}" echo "Base Branch: ${BASE_BRANCH}" echo "Fork Point: ${FORK_POINT}" - - name: Checkout master - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + - name: Create GitHub check run + uses: LouisBrunner/checks-action@937cbbcde3259005b50746dc91cde29098aac2ff # v3.1.0 + id: create_check + with: + token: ${{ secrets.GITHUB_TOKEN }} + name: Compare DS + status: in_progress + sha: ${{ steps.pr_info.outputs.pr_sha }} + output: | + {"summary":"Compare DS started. Job: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}."} + - name: Checkout forking point (${{ steps.pr_info.outputs.fork_point }}) + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repo: ComplianceAsCode/content - ref: master + ref: ${{ steps.pr_info.outputs.fork_point }} fetch-depth: 0 # https://github.com/actions/checkout/issues/766 - name: Set git safe directory run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -72,21 +86,21 @@ jobs: prop_path: 'product' - name: Download built product ${{ steps.pr_info.outputs.base_branch }} (${{ steps.pr_info.outputs.fork_point }}) if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7 + uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1 with: github-token: ${{ secrets.GITHUB_TOKEN }} - name: pr-artifacts-${{ github.event.workflow_run.head_sha }} + name: pr-artifacts path: pr_artifacts run-id: ${{ github.event.workflow_run.id }} - name: Unpack built artifacts if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: tar -xvzf pr_artifacts/artifacts.tar.gz -C pr_artifacts/unpacked_artifacts + run: tar -xvzf pr_artifacts/artifacts.tar.gz -C pr_artifacts - name: Build product if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} run: ./build_product ${{steps.product.outputs.prop}} --datastream-only - name: Compare datastreams if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: utils/compare_ds.py pr_artifacts/unpacked_artifacts/ssg-${{steps.product.outputs.prop}}-ds.xml build/ssg-${{steps.product.outputs.prop}}-ds.xml | tee diff.log + run: utils/compare_ds.py build/ssg-${{steps.product.outputs.prop}}-ds.xml pr_artifacts/artifacts/ssg-${{steps.product.outputs.prop}}-ds.xml | tee diff.log env: PYTHONPATH: ${{ github.workspace }} - name: Test if there are datastream changes @@ -158,7 +172,7 @@ jobs: token: ${{ secrets.GITHUB_TOKEN }} - name: Compare Ansible playbook shell commands if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} - run: utils/ansible_shell_diff.py ssg-${{steps.product.outputs.prop}}-ds.xml build/ssg-${{steps.product.outputs.prop}}-ds.xml | tee diff.log + run: utils/ansible_shell_diff.py build/ssg-${{steps.product.outputs.prop}}-ds.xml pr_artifacts/artifacts/ssg-${{steps.product.outputs.prop}}-ds.xml | tee diff.log env: PYTHONPATH: ${{ github.workspace }} - name: Test if there are Ansible shell module changes @@ -188,3 +202,13 @@ jobs: type: delete comment_id: ${{ steps.shell_diff.outputs.comment-id }} token: ${{ secrets.GITHUB_TOKEN }} + - name: Compare DS + if: always() + uses: LouisBrunner/checks-action@937cbbcde3259005b50746dc91cde29098aac2ff # v3.1.0 + with: + token: ${{ secrets.GITHUB_TOKEN }} + conclusion: ${{ job.status }} + check_id: ${{ steps.create_check.outputs.check_id }} + sha: ${{ steps.pr_info.outputs.pr_sha }} + output: | + {"summary":"Compare DS completed. Job: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}."} diff --git a/.github/workflows/ctf.yaml b/.github/workflows/ctf.yaml index 431aa666e1bd..3a1757d703ef 100644 --- a/.github/workflows/ctf.yaml +++ b/.github/workflows/ctf.yaml @@ -10,7 +10,7 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install git python3-jinja2 python3-yaml python3-setuptools python3-deepdiff python3-git python3-github python3-requests xmldiff python3-setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: ref: ${{ github.event.pull_request.head.sha }} fetch-depth: 0 @@ -23,12 +23,12 @@ jobs: run: echo "FORK_POINT=$(git merge-base origin/$BASE_BRANCH ${{ github.event.pull_request.head.sha }})" >> $GITHUB_OUTPUT id: fork_point - name: Checkout fork point - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: ref: ${{ steps.fork_point.outputs.FORK_POINT }} fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf diff --git a/.github/workflows/gate-lint-ansible-roles.yaml b/.github/workflows/gate-lint-ansible-roles.yaml index 4677e8c16fd9..58272fb4628b 100644 --- a/.github/workflows/gate-lint-ansible-roles.yaml +++ b/.github/workflows/gate-lint-ansible-roles.yaml @@ -15,12 +15,12 @@ jobs: - name: Install Deps run: dnf install -y cmake make ninja-build openscap-utils python3-pyyaml python3-setuptools python3-jinja2 python3-pygithub ansible ansible-lint libxslt git python3-setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Configure run: cmake -DSSG_PRODUCT_RHEL8=ON -DSSG_PRODUCT_RHEL9=ON -DSSG_PRODUCT_RHEL10=ON -G Ninja .. working-directory: ./build - name: Build - run: ninja -j2 rhel10-profile-playbooks rhel9-profile-playbooks rhel8-profile-playbooks + run: ninja -j$(nproc) rhel10-profile-playbooks rhel9-profile-playbooks rhel8-profile-playbooks working-directory: ./build - name: Build Ansible Roles run: PYTHONPATH=. python3 utils/ansible_playbook_to_role.py --build-playbooks-dir ./build/ansible/ --dry-run ./build/ansible_roles diff --git a/.github/workflows/gate.yaml b/.github/workflows/gate.yaml index ac71f9dcd90c..7a82d691657b 100644 --- a/.github/workflows/gate.yaml +++ b/.github/workflows/gate.yaml @@ -11,7 +11,7 @@ concurrency: cancel-in-progress: true jobs: validate-sle: - name: Build, Test on SLE 15 (Container) + name: Build, Test on SLE Latest (Container) runs-on: ubuntu-latest container: image: registry.suse.com/bci/bci-base:latest @@ -33,11 +33,11 @@ jobs: - name: Install deps python run: pip install pytest pytest-cov - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Build - run: ./build_product sle12 sle15 + run: ./build_product sle12 sle15 sle16 - name: Test - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids working-directory: ./build validate-suse: @@ -49,13 +49,13 @@ jobs: - name: Install Deps run: zypper install -y git cmake make openscap-utils python3-PyYAML bats python3-pytest python3-pytest-cov python3-Jinja2 python3-setuptools libxslt-tools libxml2-tools ShellCheck - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Build run: ./build_product opensuse env: ADDITIONAL_CMAKE_OPTIONS: "-DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF" - name: Test - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids working-directory: ./build validate-debian: @@ -69,7 +69,7 @@ jobs: - name: Install Deps run: apt-get install -y ansible-lint bats check cmake openscap-scanner openscap-utils libxml2-utils ninja-build python3-pip xsltproc libxslt1-dev libxml2-dev zlib1g-dev python3.11-venv - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Upgrade pip python run: pip install --upgrade pip --break-system-packages - name: Install deps python @@ -81,7 +81,7 @@ jobs: ./build_product debian11 debian12 debian13 - name: Test working-directory: ./build - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids validate-ubuntu-22-04: name: Build, Test on Ubuntu 22.04 @@ -90,7 +90,7 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install -y cmake ninja-build libopenscap8 libxml2-utils xsltproc ansible-lint bats python3-github python3-jinja2 python3-pip python3-pytest python3-pytest-cov python3-setuptools python3-yaml shellcheck - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install deps python run: pip3 install -r requirements.txt -r test-requirements.txt - name: Build @@ -99,7 +99,7 @@ jobs: run: |- ./build_product ubuntu2204 - name: Test - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids working-directory: ./build validate-ubuntu-24-04: @@ -109,7 +109,7 @@ jobs: - name: Install Deps run: sudo apt-get update && sudo apt-get install -y cmake ninja-build openscap-utils libxml2-utils xsltproc ansible-lint bats python3-github python3-jinja2 python3-pip python3-pytest python3-pytest-cov python3-setuptools python3-yaml shellcheck - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install deps python run: pip3 install -r requirements.txt -r test-requirements.txt - name: Build @@ -118,7 +118,7 @@ jobs: run: |- ./build_product ubuntu2404 - name: Test - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids working-directory: ./build validate-fedora-rawhide: @@ -132,7 +132,7 @@ jobs: - name: Install Deps run: dnf install -y cmake make openscap-utils bats ansible python3-pip ShellCheck git python3-devel gcc-c++ libxml2-devel libxslt-devel python3-setuptools gawk - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install deps python run: pip install -r requirements-base.txt -r test-requirements.txt - name: Build @@ -141,5 +141,5 @@ jobs: env: ADDITIONAL_CMAKE_OPTIONS: "-DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF" - name: Test - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids working-directory: ./build diff --git a/.github/workflows/gate_fedora.yml b/.github/workflows/gate_fedora.yml index 22c686c8f9d4..87f6220e48be 100644 --- a/.github/workflows/gate_fedora.yml +++ b/.github/workflows/gate_fedora.yml @@ -19,12 +19,12 @@ jobs: - name: Install Deps run: dnf install -y cmake make openscap-utils python3-pyyaml bats ansible python3-pip ShellCheck git gcc gcc-c++ python3-devel libxml2-devel libxslt-devel python3-setuptools gawk - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install deps python run: pip install pcre2==0.4.0 -r requirements.txt -r test-requirements.txt - name: Build run: |- - ./build_product -j2 \ + ./build_product -j$(nproc) \ al2023 \ alinux2 \ alinux3 \ @@ -49,7 +49,7 @@ jobs: env: ADDITIONAL_CMAKE_OPTIONS: "-DSSG_ANSIBLE_PLAYBOOKS_PER_RULE_ENABLED:BOOL=ON -DSSG_SCAP_VALIDATION_ENABLED:BOOL=OFF -DENABLE_CHECK_RULE_REMOVAL:BOOL=ON -DOLD_RELEASE_DIR=/__w/content/content/old_release -DENABLE_PYTHON_COVERAGE:BOOL=ON" - name: Get Latest Release - uses: actions/github-script@ed597411d8f924073f98dfc5c65a23a2325f34cd # v8.0.0 + uses: actions/github-script@3a2844b7e9c422d3c10d287c895573f7108da1b3 # v9.0.0 with: script: | const fs = require('fs'); @@ -69,16 +69,9 @@ jobs: unzip /__w/content/content/old_release.zip -d /__w/content/content/old_release mv /__w/content/content/old_release/*/* /__w/content/content/old_release/ - name: Test - run: ctest -j2 --output-on-failure -E unique-stigids + run: ctest -j$(nproc) --output-on-failure -E unique-stigids working-directory: ./build - name: "Set git safe directory, ref: https://github.com/actions/checkout/issues/760" run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - - name: Upload coverage to Qlty # Requires: git package - if: ${{ github.repository == 'ComplianceAsCode/content' }} - uses: qltysh/qlty-action/coverage@a19242102d17e497f437d7466aa01b528537e899 # v2.2.0 - with: - token: qltcp_kdIPsqNZzW5rYoxq - files: build/tests/coverage.xml - strip-prefix: /__w/content/content - name: Validate gitmailmap run: grep -E "\S" .mailmap | grep -Ev '^#' | git check-mailmap --stdin diff --git a/.github/workflows/gate_thin_ds.yml b/.github/workflows/gate_thin_ds.yml index a20f51594bd9..f0b9621de733 100644 --- a/.github/workflows/gate_thin_ds.yml +++ b/.github/workflows/gate_thin_ds.yml @@ -19,7 +19,7 @@ jobs: - name: Install Deps run: dnf install -y cmake make openscap-utils python3-pyyaml bats ansible python3-pip ShellCheck git gcc gcc-c++ python3-devel python3-lxml python3-pytest python3-setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install deps python # pytest-xdist is used for parallel execution of thin ds test run: pip install pcre2==0.4.0 pytest-xdist -r requirements.txt -r test-requirements.txt diff --git a/.github/workflows/gh-pages.yaml b/.github/workflows/gh-pages.yaml index b18fbe5a6814..de2e322464c6 100644 --- a/.github/workflows/gh-pages.yaml +++ b/.github/workflows/gh-pages.yaml @@ -1,11 +1,11 @@ name: Github Pages on: push: - branches: [ 'master' ] + branches: ['master'] pull_request: - branches: [ 'master', 'oscal-update-*' ] + branches: ['master', 'oscal-update-*'] merge_group: - branches: [ 'master' ] + branches: ['master'] concurrency: group: ${{ github.workflow }}-${{ github.event.number || github.run_id }} cancel-in-progress: true @@ -19,27 +19,37 @@ jobs: PAGES_DIR: __pages steps: - name: Install Deps - run: dnf install -y cmake git ninja-build openscap-utils python3-pyyaml python3-jinja2 python3-pytest ansible-lint libxslt python3-pip rsync python3-lxml python3-setuptools + run: | + dnf install -y \ + cmake git ninja-build openscap-utils python3-pyyaml \ + python3-jinja2 python3-pytest ansible-lint libxslt \ + python3-pip rsync python3-lxml python3-setuptools - name: Install deps python run: pip3 install json2html prometheus_client - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3 with: - persist-credentials: false + persist-credentials: false - name: Build run: cmake .. -G Ninja -DCMAKE_BUILD_TYPE=Debug working-directory: ./build - name: Build Guides and Mapping Tables - run: ninja -j2 + run: ninja -j$(nproc) working-directory: ./build - name: Build Statistics - run: ninja html-stats html-profile-stats -j2 + run: ninja html-stats html-profile-stats -j$(nproc) working-directory: ./build - name: Render Policies (Using control files) - run: ninja render-policies -j2 + run: ninja render-policies -j$(nproc) + working-directory: ./build + - name: Generate NIST 800-53 Control Viewer + run: ninja nist-viewer working-directory: ./build - name: Generate Prometheus Metrics - run: utils/controleval_metrics.py prometheus -p fedora ocp4 rhcos4 rhel10 rhel9 rhel8 sle12 sle15 -f ./build/policies_metrics + run: | + utils/controleval_metrics.py prometheus \ + -p fedora ocp4 rhcos4 rhel10 rhel9 rhel8 sle12 sle15 \ + -f ./build/policies_metrics env: PYTHONPATH: ${{ github.workspace }} - name: Generate HTML pages @@ -51,8 +61,11 @@ jobs: run: git config --global --add safe.directory "$GITHUB_WORKSPACE" - name: Deploy - if: ${{ github.event_name == 'push' && github.repository == 'ComplianceAsCode/content' && github.ref == 'refs/heads/master' }} - uses: JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f # v4.8.0 + if: >- + ${{ github.event_name == 'push' && + github.repository == 'ComplianceAsCode/content' && + github.ref == 'refs/heads/master' }} + uses: JamesIves/github-pages-deploy-action@d92aa235d04922e8f08b40ce78cc5442fcfbfa2f with: branch: main # The branch the action should deploy to. folder: ${{ env.PAGES_DIR }} # The folder the action should deploy. @@ -63,7 +76,7 @@ jobs: git-config-name: openscap-ci git-config-email: openscap-ci@gmail.com - name: Upload artifact if the event is pull request - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: built-content diff --git a/.github/workflows/nightly_build.yml b/.github/workflows/nightly_build.yml index be4ec6457e5f..cd5c8ab77204 100644 --- a/.github/workflows/nightly_build.yml +++ b/.github/workflows/nightly_build.yml @@ -13,26 +13,26 @@ jobs: - name: Install Dependencies run: dnf install -y cmake ninja-build openscap-utils python3-pip python3-devel gcc-c++ ansible-lint libxslt ansible python3-setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install python deps run: pip install -r requirements-base.txt -r test-requirements.txt - name: Configure run: cmake -G Ninja .. working-directory: ./build - name: Build All - run: ninja -j2 all + run: ninja -j$(nproc) all working-directory: ./build - name: Build ZIP - run: ninja -j2 zipfile + run: ninja -j$(nproc) zipfile working-directory: ./build - name: Test - run: ctest -j2 --output-on-failure -E linkchecker + run: ctest -j$(nproc) --output-on-failure -E linkchecker working-directory: ./build - name: Build Package Source - run: ninja -j2 package_source + run: ninja -j$(nproc) package_source working-directory: ./build - name: 'Upload Artifact' - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 with: name: Nightly Build path: | diff --git a/.github/workflows/no_merge_commits.yaml b/.github/workflows/no_merge_commits.yaml index c6eb6b0ed4b4..aa3baa2eea67 100644 --- a/.github/workflows/no_merge_commits.yaml +++ b/.github/workflows/no_merge_commits.yaml @@ -17,8 +17,8 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Check for Merge Commits - uses: NexusPHP/no-merge-commits@8c8c0fc273903ab75038323e3959179e89db480b # v2.2.1 + uses: NexusPHP/no-merge-commits@109a3342781ddcf26b2fa739f29e8ee9f68b7d8e # v2.4.1 with: token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/ocp-test-profiles.yaml b/.github/workflows/ocp-test-profiles.yaml index d294af997921..75900a3e8910 100644 --- a/.github/workflows/ocp-test-profiles.yaml +++ b/.github/workflows/ocp-test-profiles.yaml @@ -19,11 +19,11 @@ jobs: - name: Install deps python run: pip install gitpython xmldiff - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: fetch-depth: 0 - name: Checkout (CTF) - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 with: repository: ComplianceAsCode/content-test-filtering path: ctf @@ -40,7 +40,7 @@ jobs: - name: Test if there are no content changes run: echo "CTF_OUTPUT_SIZE=$(stat --printf="%s" ctf-output.json)" >> $GITHUB_OUTPUT id: ctf - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' }} with: name: ctf-output @@ -58,7 +58,7 @@ jobs: - name: Build product OCP and RHCOS content if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' && (contains(steps.product.outputs.prop, 'ocp4') || contains(steps.product.outputs.prop, 'rhcos4')) }} - run: ./build_product -d ocp4 rhcos4 + run: ./build_product --datastream ocp4 rhcos4 --cel-content=ocp4 - name: Process list of rules into a list of product-profiles to test if: ${{ steps.ctf.outputs.CTF_OUTPUT_SIZE != '0' && (contains(steps.product.outputs.prop, 'ocp4') || contains(steps.product.outputs.prop, 'rhcos4')) }} diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 71bec17c9275..b29d5313e941 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -12,23 +12,23 @@ jobs: - name: Install Deps run: dnf install -y cmake ninja-build openscap-utils python3-pip python3-devel gcc-c++ ansible ansible-lint libxslt - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Install python deps run: pip install -r requirements-base.txt -r test-requirements.txt - name: Configure run: cmake .. working-directory: ./build - name: Build All - run: make -j2 all + run: make -j$(nproc) all working-directory: ./build - name: Build ZIP - run: make -j2 zipfile + run: make -j$(nproc) zipfile working-directory: ./build - name: Test - run: ctest -j2 --output-on-failure -E linkchecker + run: ctest -j$(nproc) --output-on-failure -E linkchecker working-directory: ./build - name: Build Package Source - run: make -j2 package_source + run: make -j$(nproc) package_source working-directory: ./build - name: Set Version id: set_version @@ -39,13 +39,13 @@ jobs: GITHUB_REF: ${{ github.ref }} - name: Build Changelog id: build_changelog - uses: mikepenz/release-changelog-builder-action@6faf020194b7c8853f9e55c4fd92e40b02122a04 # v4 + uses: mikepenz/release-changelog-builder-action@348e88fab4c37338b1e803ceb2d4a7a5db6c0833 # v4 with: configuration: .github/workflows/release-changelog.json env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Release - uses: softprops/action-gh-release@a06a81a03ee405af7f2048a818ed3f03bbf83c7b # v2.5.0 + uses: softprops/action-gh-release@b4309332981a82ec1c5618f44dd2e27cc8bfbfda # v3.0.0 with: draft: True name: Content ${{ steps.set_version.outputs.ver }} diff --git a/.github/workflows/ruff.yaml b/.github/workflows/ruff.yaml index 6e5c72b0e5c4..d43ca1baf9dc 100644 --- a/.github/workflows/ruff.yaml +++ b/.github/workflows/ruff.yaml @@ -16,7 +16,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd #v6.0.2 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 #v6.0.3 - name: Install ruff run: python3 -m pip install ruff - name: Run ruff check diff --git a/.github/workflows/srg-mapping-table.yaml b/.github/workflows/srg-mapping-table.yaml index 9a53ef550953..7541e60e38a0 100644 --- a/.github/workflows/srg-mapping-table.yaml +++ b/.github/workflows/srg-mapping-table.yaml @@ -23,14 +23,14 @@ jobs: - name: Install deps python run: pip3 install pandas openpyxl - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v6.0.3 with: persist-credentials: false - name: Setup Build run: cmake .. -G Ninja working-directory: ./build - name: Build - run: ninja -j2 rhel10 rhel9 ocp4 + run: ninja -j$(nproc) rhel10 rhel9 ocp4 working-directory: ./build - name: Build rule dir json run: python3 utils/rule_dir_json.py @@ -62,33 +62,33 @@ jobs: run: python3 utils/create_srg_export.py -c controls/srg_gpos.yml -p rhel10 -m shared/references/disa-os-srg-v3r2.xml --out-format html --output $PAGES_DIR/srg-mapping-rhel10.html env: PYTHONPATH: ${{ github.workspace }} - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: srg-mapping-rhel9.xlsx path: ${{ env.PAGES_DIR }}/srg-mapping-rhel9.xlsx - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: srg-mapping-rhel9.html path: ${{ env.PAGES_DIR }}/srg-mapping-rhel9.html - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: srg-mapping-rhel10.xlsx path: ${{ env.PAGES_DIR }}/srg-mapping-rhel10.xlsx - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: srg-mapping-rhel10.html path: ${{ env.PAGES_DIR }}/srg-mapping-rhel10.html - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: srg-mapping-ocp4.xlsx path: ${{ env.PAGES_DIR }}/srg-mapping-ocp4.xlsx - - uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v4 + - uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v4 if: ${{ github.event_name == 'pull_request' }} with: name: srg-mapping-ocp4.html diff --git a/.github/workflows/stabilize.yaml b/.github/workflows/stabilize.yaml index ca18e3a388c4..1f6b555d625e 100644 --- a/.github/workflows/stabilize.yaml +++ b/.github/workflows/stabilize.yaml @@ -19,12 +19,12 @@ jobs: - name: Install Deps run: dnf install -y cmake ninja-build openscap-utils python3-pyyaml python3-jinja2 python3-pytest ansible libxslt python3-ansible-lint linkchecker java-latest-openjdk unar wget python-unversioned-command git-core python3-setuptools - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 + uses: actions/checkout@df4cb1c069e1874edd31b4311f1884172cec0e10 # v4 - name: Configure run: cmake -DSSG_OVAL_SCHEMATRON_VALIDATION_ENABLED=OFF -DANSIBLE_CHECKS=ON -DENABLE_SCAPVAL13=ON -DSCAPVAL_PATH='/opt/scapval/SCAP-Content-Validation-Tool-1.3.5/scapval-1.3.5.jar' .. working-directory: ./build - name: Build All - run: make -j2 all + run: make -j$(nproc) all working-directory: ./build - name: Get SCAPVAL run: wget $SCAPVAL_URL/$SCAPVAL_FILENAME.zip @@ -32,12 +32,12 @@ jobs: run: mkdir -p /opt/scapval/ && unar $SCAPVAL_FILENAME.zip -o /opt/scapval/ - name: Run SCAPVal # Runs SCAPVal on all built datastream - run: ctest -j2 -R scapval --output-on-failure + run: ctest -j$(nproc) -R scapval --output-on-failure - name: Lint Check # Performs ansible-lint and yamllint checks on generated ansible playbooks - run: ctest -j2 -R ansible-playbook --output-on-failure + run: ctest -j$(nproc) -R ansible-playbook --output-on-failure working-directory: ./build - name: Link Check # Performs linkcheck across all build tables and html guides to ensure there are no broken references. - run: ctest -j2 -R linkchecker --output-on-failure + run: ctest -j$(nproc) -R linkchecker --output-on-failure working-directory: ./build diff --git a/.github/workflows/sync-cac-oscal.yml b/.github/workflows/sync-cac-oscal.yml deleted file mode 100644 index ae952046f5ae..000000000000 --- a/.github/workflows/sync-cac-oscal.yml +++ /dev/null @@ -1,390 +0,0 @@ -name: Sync CaC content to OSCAL content -permissions: - contents: write - pull-requests: read -on: - push: - branches: - - master -jobs: - sync-cac-updates-to-oscal-content: - runs-on: ubuntu-latest - steps: - # Step 1: Set up Python 3 - - name: Set up Python 3 - uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0 - with: - python-version: '3.9' - # Step 2: Install Git - - name: Install Git - run: sudo apt-get update && sudo apt-get install -y git - # Step 3: Checkout the CaC repo - - name: Checkout CaC repo - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - repository: ${{ github.repository }} - path: cac-content - - name: Get the commit message and PR number - run: | - cd cac-content - # Get the latest commit message - COMMIT_MSG=$(git log -1 --pretty=%B) - # Extract the PR number from the commit message (if it's a merge commit) - PR_NUMBER=$(echo "$COMMIT_MSG" | grep -oP '#\K\d+') - if [ -n "$PR_NUMBER" ]; then - echo "Found PR number: $PR_NUMBER" - echo "PR_NUMBER=$PR_NUMBER" >> $GITHUB_ENV - echo "SKIP=false" >> $GITHUB_ENV - PR_INFO=$(curl -s "https://api.github.com/repos/${{ github.repository }}/pulls/${PR_NUMBER}") - # Extract PR title from the response - PR_TITLE=$(echo "$PR_INFO" | jq -r .title) - echo "PR Title: $PR_TITLE" - if [[ "$PR_TITLE" == *"Auto-generated PR from OSCAL"* ]]; then - echo "The PR comes from OSCAL content. The task of Sync CaC content to OSCAL will exit." - echo "Skipping further checks." - echo "SKIP=true" >> $GITHUB_ENV - fi - fi - # Step 4: Get the access token for content write permission to OSCAL content - - name: Get GitHub app token - if: ${{ env.SKIP == 'false' }} - uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2.2.1 - id: app-token - with: - app-id: ${{ secrets.APP_ID }} - private-key: ${{ secrets.PRIVATE_KEY }} - owner: ${{ github.repository_owner }} - repositories: | - content - oscal-content - # Step 5: Checkout complyscribe and setup the environment - - name: Checkout complyscribe repo - if: ${{ env.SKIP == 'false' }} - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - repository: complytime/complyscribe - path: complyscribe - - name: Setup complyscribe - if: ${{ env.SKIP == 'false' }} - run: | - cd complyscribe && python3 -m venv venv && source venv/bin/activate - python3 -m pip install --no-cache-dir "poetry==1.7.1" - poetry install - # Step 6: Get changed files and detect updates - - name: Get changed files - if: ${{ env.SKIP == 'false' }} - uses: tj-actions/changed-files@e0021407031f5be11a464abee9a0776171c79891 # v47.0.1 - id: changed-files - with: - path: "cac-content" - - name: Detect updates in changed files - if: ${{ env.SKIP == 'false' }} - run: | - OWNER="ComplianceAsCode" - REPO="content" - echo "CHANGE_FOUND=false" >> $GITHUB_ENV - source complyscribe/venv/bin/activate - cd cac-content - has_change() { - local file="$1" - local key="$2" - ! python utils/compare_rule_var.py \ - --owner "$OWNER" \ - --repo "$REPO" \ - "${{ env.PR_NUMBER }}" \ - "$file" \ - "$key" - } - for file in ${ALL_CHANGED_FILES}; do - # Exclude files containing 'tests/data/' - if [[ "$file" == *tests/data/* ]]; then - continue - fi - case "$file" in - *controls/*|*.profile*) - echo "$file" >> updated_filenames.txt - ;; - *rule.yml) - if has_change "$file" "title"; then - echo "Change detected: The title in '$file' was updated." - echo "$file" >> updated_filenames.txt - fi - ;; - *.var) - if has_change "$file" "description" || has_change "$file" "options"; then - echo "Change detected: The description or options in '$file' were updated." - echo "$file" >> updated_filenames.txt - fi - ;; - esac - done - if [[ -f updated_filenames.txt ]]; then - echo "Shows updated_filenames:" - cat updated_filenames.txt - echo "CHANGE_FOUND=true" >> $GITHUB_ENV - fi - env: - ALL_CHANGED_FILES: "${{ steps.changed-files.outputs.all_changed_files }}" - GH_TOKEN: ${{ steps.app-token.outputs.token }} - - name: Checkout OSCAL content repo - if: ${{ env.CHANGE_FOUND == 'true' }} - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2 - with: - repository: ComplianceAsCode/oscal-content - path: oscal-content - token: ${{ steps.app-token.outputs.token }} - fetch-depth: 0 - - name: Set RH_PRODUCTS - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - echo "RH_PRODUCTS=(rhel8 rhel9 rhel10 ocp4 fedora)" >> $GITHUB_ENV - # Step 7: Get profiles, controls and level mapping - - name: Get profiles, controls and level mapping - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd complyscribe && source venv/bin/activate - RH_PRODUCTS=${{ env.RH_PRODUCTS }} - for product in "${RH_PRODUCTS[@]}"; do - echo "The map for $product..." - map_file=$product"_map.json" - python -W ignore scripts/get_mappings_profile_control_levels.py $product "$GITHUB_WORKSPACE/cac-content" > $map_file 2>&1 - cat $map_file - done - # Step 8: Get product available controls - - name: Get product controls - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd complyscribe && source venv/bin/activate - RH_PRODUCTS=${{ env.RH_PRODUCTS }} - for product in "${RH_PRODUCTS[@]}"; do - echo "All available controls of $product..." - controls_file=$product"_controls" - python -W ignore scripts/get_product_controls.py $product "$GITHUB_WORKSPACE/cac-content" > $controls_file 2>&1 - cat $controls_file - done - # Step 9: Handle the detected updates - # 1. Get the updated controls - # 2. Get the updated profiles - # 3. Get the controls and profiles are impacted by rules and vars - - name: Handle the detected updates - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - python cac-content/utils/handle_detected_updates.py 'cac-content/updated_filenames.txt' > updates 2>&1 - cd complyscribe && source venv/bin/activate - RH_PRODUCTS=${{ env.RH_PRODUCTS }} - i=0 - while IFS= read -r line; do - i=$((i + 1)) - if [[ $i -eq 1 ]]; then - # 1. Get the updated controls - echo $line > updated_controls - elif [[ $i -eq 2 ]]; then - # 2. Get the updated profiles - profiles=($(echo "$line"| sed "s/{'/{\"/g; s/': '/\":\"/g; s/', '/\",\"/g; s/'}/\"}/g;")) - for profile in "${profiles[@]}"; do - product=$(echo "$profile" | jq -r '.product') - profile_name=$(echo "$profile" | jq -r '.profile_name') - echo $profile_name >> $product"_updated_profiles" - done - elif [[ $i -eq 3 ]]; then - # 3. Get the updated rule and variables, - # then convert them to impacted controls and profiles - rules=($line) - for rule in "${rules[@]}"; do - python -W ignore scripts/get_rule_impacted_files.py rh-products "$GITHUB_WORKSPACE/cac-content" $rule control >> rule_impacted_controls 2>&1 - for product in "${RH_PRODUCTS[@]}"; do - python -W ignore scripts/get_rule_impacted_files.py $product "$GITHUB_WORKSPACE/cac-content" $rule profile >> $product"_rule_impacted_profiles" 2>&1 - done - done - fi - done < "$GITHUB_WORKSPACE"/updates - # Step 10: Check if there is any existing open PR - - name: Check if there is any existing open PR - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd oscal-content - # Use the GitHub CLI to search for an open PR. - # The 'jq' query filters for PRs where the branch name contains "sync_cac_pr". - # We take the first result found. - PR_BRANCH=$(gh pr list --state open --json headRefName --jq '.[] | select(.headRefName | contains("sync_cac_pr")) | .headRefName' | head -n 1) - if [[ -n "$PR_BRANCH" ]]; then - echo "Found matching PR branch: $PR_BRANCH" - # Set the branch name as the PR_BRANCH. - echo "BRANCH_NAME=$PR_BRANCH" >> $GITHUB_ENV - else - echo "No open PR found with 'sync_cac_pr' in the branch name." - BRANCH_NAME="sync_cac_pr${{ env.PR_NUMBER }}" - echo "BRANCH_NAME=$BRANCH_NAME" >> $GITHUB_ENV - fi - env: - GH_TOKEN: ${{ steps.app-token.outputs.token }} - # Step 11: Check if the OSCAL content branch exists - - name: Check if the OSCAL content branch exists - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd oscal-content - git fetch --all - if git show-ref --verify --quiet refs/remotes/origin/"${{ env.BRANCH_NAME }}"; then - git checkout -b "${{ env.BRANCH_NAME }}" origin/${{ env.BRANCH_NAME }} - else - echo "OSCAL content branch $BRANCH_NAME doesn't exist" - fi - # Get the base commit HASH - base_commit=$(git log -1 --format=%H) - echo "base_commit=$base_commit" >> $GITHUB_ENV - - # Step 12: Sync updated controls to OSCAL content - - name: Sync updated controls to OSCAL content - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd complyscribe && source venv/bin/activate - RH_PRODUCTS=${{ env.RH_PRODUCTS }} - # 1.1 Get the updated controls to array - file="updated_controls" - if [ -f "$file" ] && [ -s "$file" ]; then - updated_controls=($(cat "$file")) - # Output all the updated controls in the PR - echo "The updated controls: ${updated_controls[@]}" - fi - # 1.2 Sync the updated controls to OSCAL content - for product in "${RH_PRODUCTS[@]}"; do - for policy_id in "${updated_controls[@]}"; do - # This sync depends on the specific product available controls - available_controls=($(cat $product"_controls")) # Get all the available controls of the product - for pc in "${available_controls[@]}"; do - if [[ "$pc" == "$policy_id" ]]; then - # 1.2.1 Sync the updated controls to OSCAL catalog - poetry run complyscribe sync-cac-content catalog --repo-path ../oscal-content --committer-email "openscap-ci@gmail.com" --committer-name "openscap-ci" --branch "${{ env.BRANCH_NAME }}" --cac-content-root "$GITHUB_WORKSPACE/cac-content" --cac-policy-id "$policy_id" --oscal-catalog "$policy_id" - # 1.2.2 Sync the updated controls to OSCAL profile - poetry run complyscribe sync-cac-content profile --repo-path ../oscal-content --committer-email "openscap-ci@gmail.com" --committer-name "openscap-ci" --branch "${{ env.BRANCH_NAME }}" --cac-content-root "$GITHUB_WORKSPACE/cac-content" --product "$product" --cac-policy-id "$policy_id" --oscal-catalog "$policy_id" - fi - done - # 1.2.3 Sync the updated controls to OSCAL component-definition - # This sync depends on the control assoicated profile and levels - sh ../cac-content/utils/complyscribe-cli-compd.sh true $policy_id $product ${{ env.BRANCH_NAME }} $GITHUB_WORKSPACE $product"_map.json" - done - done - # Step 13: Sync updated profiles to OSCAL content - - name: Sync updated profiles to OSCAL content - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd complyscribe && source venv/bin/activate - RH_PRODUCTS=${{ env.RH_PRODUCTS }} - pr_number="${{ env.PR_NUMBER }}" - # 1. Get the updated profiles - # 2. Sync the updated profiles to OSCAL profile and component-definition - for product in "${RH_PRODUCTS[@]}"; do - file=$product"_updated_profiles" - if [ -f "$file" ] && [ -s "$file" ]; then - updated_profiles=($(cat "$file" | tr ' ' '\n' | sort | uniq | tr '\n' ' ' | sed 's/ $//')) - echo "The updated profiles for product $product: ${updated_profiles[@]}" - for profile in "${updated_profiles[@]}"; do - # 2.1 Sync CaC profile to OSCAL prifile - while IFS= read -r line; do - map=${line//\'/\"} - policy_id=$(echo "$map" | jq -r '.policy_id') - profile_name=$(echo "$map" | jq -r '.profile_name') - if [[ "$profile" == "$profile_name" ]]; then - poetry run complyscribe sync-cac-content profile --repo-path ../oscal-content --committer-email "openscap-ci@gmail.com" --committer-name "openscap-ci" --branch "${{ env.BRANCH_NAME }}" --cac-content-root "$GITHUB_WORKSPACE/cac-content" --product "$product" --cac-policy-id "$policy_id" --oscal-catalog "$policy_id" - fi - done < $product"_map.json" - # 2.2 Sync CaC profile to OSCAL component-definition - sh ../cac-content/utils/complyscribe-cli-compd.sh false $profile $product ${{ env.BRANCH_NAME }} $GITHUB_WORKSPACE $product"_map.json" - done - fi - done - # Step 14: Sync rule updates to OSCAL component-definition - - name: Sync rule updates to OSCAL component-definition - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd complyscribe && source venv/bin/activate - RH_PRODUCTS=${{ env.RH_PRODUCTS }} - pr_number="${{ env.PR_NUMBER }}" - # 1. Get the rule impacted controls - file="rule_impacted_controls" - if [ -f "$file" ] && [ -s "$file" ]; then - rule_impacted_controls=($(cat "$file" | tr ' ' '\n' | sort | uniq | tr '\n' ' ' | sed 's/ $//')) - echo "The rule impacted controls: ${rule_impacted_controls[@]}" - # 2. Sync the rule impacted controls to OSCAL component-definition - for product in "${RH_PRODUCTS[@]}"; do - # Sync CAC controls' updates to OSCAL content - for policy_id in "${rule_impacted_controls[@]}"; do - sh ../cac-content/utils/complyscribe-cli-compd.sh true $policy_id $product ${{ env.BRANCH_NAME }} $GITHUB_WORKSPACE $product"_map.json" - done - done - fi - # 3. Get the rule impacted profiles - for product in "${RH_PRODUCTS[@]}"; do - file=$product"_rule_impacted_profiles" - if [ -f "$file" ] && [ -s "$file" ]; then - rule_impacted_profiles=($(cat $file | tr ' ' '\n' | sort | uniq | tr '\n' ' ' | sed 's/ $//')) - echo "The rule impacted profiles for $product: ${rule_impacted_profiles[@]}" - # 4. Sync the rule impacted profiles to OSCAL component-definition - for profile in "${rule_impacted_profiles[@]}"; do - sh ../cac-content/utils/complyscribe-cli-compd.sh false $profile $product ${{ env.BRANCH_NAME }} $GITHUB_WORKSPACE $product"_map.json" - done - fi - done - # Step 15: Squash multiple commits for each run - - name: Squash multiple commits - if: ${{ env.CHANGE_FOUND == 'true' }} - run: | - cd oscal-content - git config user.name "openscap-ci" - git config user.email "openscap-ci@gmail.com" - echo "PR_SKIP=false" >> $GITHUB_ENV - if [ "$(git branch --show-current)" == "${{ env.BRANCH_NAME }}" ]; then - SQUASH_COUNT=$(git rev-list --count ${{ env.base_commit }}..HEAD) - echo "SQUASH_COUNT=$SQUASH_COUNT" >> $GITHUB_ENV - if [[ "$SQUASH_COUNT" -eq 0 ]]; then - echo "No commit from the CAC PR ${{ env.PR_NUMBER }}." - echo "PR_SKIP=true" >> $GITHUB_ENV - elif [[ "$SQUASH_COUNT" -eq 1 ]]; then - echo "::notice::Branch has 1 commit. No squashing needed." - else - # Call the squash script using the commit count - $GITHUB_WORKSPACE/complyscribe/scripts/squash.sh "$SQUASH_COUNT" - fi - else - echo "PR_SKIP=true" >> $GITHUB_ENV - echo "No branch ${{ env.BRANCH_NAME }}. Skipping squash and create PR." - fi - shell: bash - env: - GH_TOKEN: ${{ env.INSTALLATION_TOKEN }} - # Step 16: Create PR or update PR in OSCAL content - - name: Create a Pull Request in OSCAL content - if: ${{ env.PR_SKIP == 'false' }} - run: | - cd oscal-content - OWNER="ComplianceAsCode" - REPO="oscal-content" - CAC_PR_URL="https://github.com/$OWNER/content/pull/${{ env.PR_NUMBER }}" - commit=$(git log -1 --format=%H) - PR_BODY="This is an auto-generated commit $commit from CAC PR [${{ env.PR_NUMBER }}]("$CAC_PR_URL")" - if [[ "$(git branch --show-current)" == "${{ env.BRANCH_NAME }}" ]]; then - if [ "${{ env.SQUASH_COUNT }}" -eq 0 ]; then - echo "No commits from the CAC PR ${{ env.PR_NUMBER }}. Skipping PR creation." - else - # Check if the PR exists - PR_EXISTS=$(gh pr list --repo $OWNER/$REPO \ - --head $BRANCH_NAME --state open --json id \ - | jq length) - if [ "$PR_EXISTS" -gt 0 ]; then - echo "PR ${{ env.BRANCH_NAME }} already exists. Skipping PR creation." - echo "Add a comment for the CAC PR ${{ env.PR_NUMBER }}." - gh pr comment ${{ env.BRANCH_NAME }} --body "${PR_BODY}" - else - echo "Creating PR for new branch: ${{ env.BRANCH_NAME }}" - gh pr create --repo $OWNER/$REPO \ - --title "Auto-generated PR from CAC ${{ env.PR_NUMBER }}" \ - --head "${{ env.BRANCH_NAME }}" \ - --base "main" \ - --body "${PR_BODY}" - fi - fi - else - echo "No branch ${{ env.BRANCH_NAME }}. Skipping PR creation." - fi - env: - GH_TOKEN: ${{ steps.app-token.outputs.token }} diff --git a/.github/workflows/update-oscal.yml b/.github/workflows/update-oscal.yml deleted file mode 100644 index 9c0c7d7d293b..000000000000 --- a/.github/workflows/update-oscal.yml +++ /dev/null @@ -1,62 +0,0 @@ -name: Update vendored OSCAL content - -on: - workflow_dispatch: - schedule: - # Run weekly at 05:00 on Sunday - - cron: "0 5 * * 0" - -jobs: - update-oscal: - name: Update content - runs-on: ubuntu-latest - permissions: - contents: write - pull-requests: write - strategy: - matrix: - variables: - - catalog-source: "https://raw.githubusercontent.com/usnistgov/oscal-content/690f517daaf3a6cbb4056d3cde6eae2756765620/nist.gov/SP800-53/rev5/json/NIST_SP-800-53_rev5_catalog.json" - profile-source: "https://raw.githubusercontent.com/GSA/fedramp-automation/master/dist/content/rev5/baselines/json/FedRAMP_rev5_HIGH-baseline_profile.json" - profile-name: "fedramp_rev5_high" - catalog-name: "nist_rev5_800_53" - - catalog-source: "https://raw.githubusercontent.com/usnistgov/oscal-content/690f517daaf3a6cbb4056d3cde6eae2756765620/nist.gov/SP800-53/rev4/json/NIST_SP-800-53_rev4_catalog.json" - profile-source: "https://raw.githubusercontent.com/GSA/fedramp-automation/master/dist/content/rev4/baselines/json/FedRAMP_rev4_HIGH-baseline_profile.json" - profile-name: "fedramp_rev4_high" - catalog-name: "nist_rev4_800_53" - steps: - - name: Checkout - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4 - - name: Install Python - uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v5 - with: - python-version: '3.9' - - name: Install python deps - run: pip3 install requests compliance-trestle==2.4.0 - - name: Update catalogs - run: | - rm -rf "catalogs/${{ matrix.variables.catalog-name }}" - trestle import -f "${{ matrix.variables.catalog-source }}" -o "${{ matrix.variables.catalog-name }}" - working-directory: ./shared/references/oscal - - name: Update profiles - run: | - rm -rf "profiles/${{ matrix.variables.profile-name }}" - trestle import -f "${{ matrix.variables.profile-source }}" -o "${{ matrix.variables.profile-name }}" - trestle href --name "${{ matrix.variables.profile-name }}" -hr "trestle://catalogs/${{ matrix.variables.catalog-name }}/catalog.json" - working-directory: ./shared/references/oscal - - name: Update content - uses: peter-evans/create-pull-request@c0f553fe549906ede9cf27b5156039d195d2ece0 # v8.1.0 - with: - base: master - branch: "oscal-update-${{ github.run_id }}" - delete-branch: true - commit-message: "Update OSCAL content in shared/references/oscal" - title: "Update upstream OSCAL content from usnistogv and GSA" - body: | - Updates upstream OSCAL content - - usnistgov NIST 800-53 from "${{ matrix.variables.catalog-source }}" - - GSA FedRAMP OSCAL profiles from "${{ matrix.variables.profile-source }}" - - Auto-generated by the [update-oscal](https://github.com/ComplianceAsCode/content/blob/master/.github/workflows/update-oscal.yml) workflow. - add-paths: | - shared/references/oscal/ diff --git a/.gitignore b/.gitignore index cafff35ee5ea..5e3eb1f8bfe5 100644 --- a/.gitignore +++ b/.gitignore @@ -80,5 +80,6 @@ ocp4/profiles/test.profile .coverage coverage.xml -# Trestle specfic -shared/references/oscal/.trestle/cache + +# Ignore user-specific CLAUDE preferences +CLAUDE.local.md diff --git a/.packit.yaml b/.packit.yaml index 8d456d18d276..267650da5db4 100644 --- a/.packit.yaml +++ b/.packit.yaml @@ -23,138 +23,36 @@ jobs: trigger: commit branch: "gh-readonly-queue/.*" -- &test-static-checks +- &contest-oscap job: tests trigger: pull_request - fmf_path: tests/tmt - identifier: /static-checks - tmt_plan: /plans/contest/static-checks$ + fmf_url: https://github.com/RHSecurityCompliance/contest.git + fmf_ref: main + tmt_plan: /plans/upstream-parallel/oscap + identifier: contest-oscap targets: centos-stream-8: {} centos-stream-9: {} centos-stream-10: {} + tf_extra_params: + settings: + pipeline: + parallel-limit: 32 -# when modifying this, modify also tests/tmt-plans/ +- <<: *contest-oscap + tmt_plan: /plans/upstream-parallel/ansible + identifier: contest-ansible -- <<: *test-static-checks - identifier: /rpmbuild-ctest-fedora - tmt_plan: /plans/contest/rpmbuild-ctest-fedora$ - targets: - fedora-all: {} -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/anssi_bp28_high - tmt_plan: /plans/contest/hardening/host-os/ansible/anssi_bp28_high$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/bsi - tmt_plan: /plans/contest/hardening/host-os/ansible/bsi$ - targets: - centos-stream-9: {} - centos-stream-10: {} -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/ccn_advanced - tmt_plan: /plans/contest/hardening/host-os/ansible/ccn_advanced$ - targets: - centos-stream-9: {} -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/cis - tmt_plan: /plans/contest/hardening/host-os/ansible/cis$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/cis_server_l1 - tmt_plan: /plans/contest/hardening/host-os/ansible/cis_server_l1$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/cis_workstation_l1 - tmt_plan: /plans/contest/hardening/host-os/ansible/cis_workstation_l1$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/cis_workstation_l2 - tmt_plan: /plans/contest/hardening/host-os/ansible/cis_workstation_l2$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/cui - tmt_plan: /plans/contest/hardening/host-os/ansible/cui$ - targets: - centos-stream-8: {} - centos-stream-9: {} -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/e8 - tmt_plan: /plans/contest/hardening/host-os/ansible/e8$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/hipaa - tmt_plan: /plans/contest/hardening/host-os/ansible/hipaa$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/ism_o - tmt_plan: /plans/contest/hardening/host-os/ansible/ism_o$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/ism_o_top_secret - tmt_plan: /plans/contest/hardening/host-os/ansible/ism_o_top_secret$ - targets: - centos-stream-10: {} -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/ospp - tmt_plan: /plans/contest/hardening/host-os/ansible/ospp$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/pci-dss - tmt_plan: /plans/contest/hardening/host-os/ansible/pci-dss$ -- <<: *test-static-checks - identifier: /hardening/host-os/ansible/stig - tmt_plan: /plans/contest/hardening/host-os/ansible/stig$ +- <<: *contest-oscap + tmt_plan: /plans/upstream-parallel/other + identifier: contest-other -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/anssi_bp28_high - tmt_plan: /plans/contest/hardening/host-os/oscap/anssi_bp28_high$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/bsi - tmt_plan: /plans/contest/hardening/host-os/oscap/bsi$ - targets: - centos-stream-9: {} - centos-stream-10: {} -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/ccn_advanced - tmt_plan: /plans/contest/hardening/host-os/oscap/ccn_advanced$ - targets: - centos-stream-9: {} -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/cis - tmt_plan: /plans/contest/hardening/host-os/oscap/cis$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/cis_server_l1 - tmt_plan: /plans/contest/hardening/host-os/oscap/cis_server_l1$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/cis_workstation_l1 - tmt_plan: /plans/contest/hardening/host-os/oscap/cis_workstation_l1$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/cis_workstation_l2 - tmt_plan: /plans/contest/hardening/host-os/oscap/cis_workstation_l2$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/cui - tmt_plan: /plans/contest/hardening/host-os/oscap/cui$ - targets: - centos-stream-8: {} - centos-stream-9: {} -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/e8 - tmt_plan: /plans/contest/hardening/host-os/oscap/e8$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/hipaa - tmt_plan: /plans/contest/hardening/host-os/oscap/hipaa$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/ism_o - tmt_plan: /plans/contest/hardening/host-os/oscap/ism_o$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/ism_o_top_secret - tmt_plan: /plans/contest/hardening/host-os/oscap/ism_o_top_secret$ - targets: - centos-stream-10: {} -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/ospp - tmt_plan: /plans/contest/hardening/host-os/oscap/ospp$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/pci-dss - tmt_plan: /plans/contest/hardening/host-os/oscap/pci-dss$ -- <<: *test-static-checks - identifier: /hardening/host-os/oscap/stig - tmt_plan: /plans/contest/hardening/host-os/oscap/stig$ +# when modifying anything below, modify also tests/tmt/ -- <<: *test-static-checks +- job: tests + trigger: pull_request + fmf_path: tests/tmt + tmt_plan: /fedora-cis/plan$ identifier: fedora-cis - tmt_plan: /plans/fedora-cis$ targets: fedora-all: {} diff --git a/.tekton/compliance-operator-content-dev-pull-request.yaml b/.tekton/compliance-operator-content-dev-pull-request.yaml index 6af5703904f6..0f10b1d27abf 100644 --- a/.tekton/compliance-operator-content-dev-pull-request.yaml +++ b/.tekton/compliance-operator-content-dev-pull-request.yaml @@ -56,7 +56,7 @@ spec: - name: name value: show-sbom - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-show-sbom:0.1@sha256:beb0616db051952b4b861dd8c3e00fa1c0eccbd926feddf71194d3bb3ace9ce7 + value: quay.io/konflux-ci/tekton-catalog/task-show-sbom:0.1@sha256:04994df487ee886adbe60a8a5866647fbdfd53cc26f7b2554272ba51bf7af29e - name: kind value: task resolver: bundles @@ -79,10 +79,6 @@ spec: description: Path to the Dockerfile inside the context specified by parameter path-context name: dockerfile type: string - - default: "false" - description: Force rebuild image - name: rebuild - type: string - default: "false" description: Skip checks against built image name: skip-checks @@ -148,12 +144,6 @@ spec: tasks: - name: init params: - - name: image-url - value: $(params.output-image) - - name: rebuild - value: $(params.rebuild) - - name: skip-checks - value: $(params.skip-checks) - name: enable-cache-proxy value: $(params.enable-cache-proxy) taskRef: @@ -161,7 +151,7 @@ spec: - name: name value: init - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-init:0.2@sha256:b349d24cb896573695802d6913d311640b44675ec082b3ad167721946a6a0a71 + value: quay.io/konflux-ci/tekton-catalog/task-init:0.4@sha256:288f3106118edc1d0f0c79a89c960abf5841a4dd8bc3f38feb10527253105b19 - name: kind value: task resolver: bundles @@ -182,15 +172,10 @@ spec: - name: name value: git-clone-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-git-clone-oci-ta:0.1@sha256:0a89e1a6304076525e9766f63a4cd006763d21d5aca6863281fc427537a23c6f + value: quay.io/konflux-ci/tekton-catalog/task-git-clone-oci-ta:0.1@sha256:2c388d28651457db60bb90287e7d8c3680303197196e4476878d98d81e8b6dc9 - name: kind value: task resolver: bundles - when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" workspaces: - name: basic-auth workspace: git-auth @@ -213,7 +198,7 @@ spec: - name: name value: prefetch-dependencies-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-prefetch-dependencies-oci-ta:0.2@sha256:3e5e834290a1ed57fd14c0082e5a10789c8fe382ed682ef7f981475a7b316b49 + value: quay.io/konflux-ci/tekton-catalog/task-prefetch-dependencies-oci-ta:0.3@sha256:9917d11f0a38c844184042d504b3d5605c009e6e43785fa113caae8b4c99b75e - name: kind value: task resolver: bundles @@ -269,23 +254,14 @@ spec: - name: name value: buildah-remote-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-buildah-remote-oci-ta:0.7@sha256:ef1c062b10c9fb17951350de76bce6bb54a4ea75fca4f37ea136d626c444bf78 + value: quay.io/konflux-ci/tekton-catalog/task-buildah-remote-oci-ta:0.9@sha256:4b3b76822c67fb734a9b3a5112e3810e271ee09d2777720a277a33870d3b038b - name: kind value: task resolver: bundles - when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" - name: build-image-index params: - name: IMAGE value: $(params.output-image) - - name: COMMIT_SHA - value: $(tasks.clone-repository.results.commit) - - name: IMAGE_EXPIRES_AFTER - value: $(params.image-expires-after) - name: ALWAYS_BUILD_INDEX value: $(params.build-image-index) - name: IMAGES @@ -300,15 +276,10 @@ spec: - name: name value: build-image-index - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-build-image-index:0.2@sha256:39561ac43e325159497c10c0284cf61dfddf39e39100ca5e3df6b73c5d96db8b + value: quay.io/konflux-ci/tekton-catalog/task-build-image-index:0.3@sha256:ae3fa44f005054d4901d33413972227b5642d376968a67791535cdcc2e98473d - name: kind value: task resolver: bundles - when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" - name: build-source-image params: - name: BINARY_IMAGE @@ -326,15 +297,11 @@ spec: - name: name value: source-build-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-source-build-oci-ta:0.3@sha256:4abb2dbc9dcfad52d56b490a2f25f99989a2cb2bbd9881223025272db60fd75e + value: quay.io/konflux-ci/tekton-catalog/task-source-build-oci-ta:0.3@sha256:362f0475df00e7dfb5f15dea0481d1b68b287f60411718d70a23da3c059a5613 - name: kind value: task resolver: bundles when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" - input: $(params.build-source-image) operator: in values: @@ -352,7 +319,7 @@ spec: - name: name value: deprecated-image-check - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-deprecated-image-check:0.5@sha256:462baed733dfc38aca5395499e92f19b6f13a74c2e88fe5d86c3cffa2f899b57 + value: quay.io/konflux-ci/tekton-catalog/task-deprecated-image-check:0.5@sha256:5ff16b7e6b4a8aa1adb352e74b9f831f77ff97bafd1b89ddb0038d63335f1a67 - name: kind value: task resolver: bundles @@ -379,7 +346,7 @@ spec: - name: name value: clair-scan - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-clair-scan:0.3@sha256:a5fa66ed5b8c107e7bc29cb084edcc07e394f818cc59ef2db2f9dcb0cd1fa3dc + value: quay.io/konflux-ci/tekton-catalog/task-clair-scan:0.3@sha256:89924756c91ded746cf9ccc9f07907595e5b2454ddda0219132913a4875a5f59 - name: kind value: task resolver: bundles @@ -399,7 +366,7 @@ spec: - name: name value: ecosystem-cert-preflight-checks - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-ecosystem-cert-preflight-checks:0.2@sha256:04f75593558f79a27da2336400bc63d460bf0c5669e3c13f40ee2fb650b1ad1e + value: quay.io/konflux-ci/tekton-catalog/task-ecosystem-cert-preflight-checks:0.2@sha256:b4ac586edea81dcd25dfc17f1bd57899825be2b443e48d572cd05ce058f153bb - name: kind value: task resolver: bundles @@ -432,7 +399,7 @@ spec: - name: name value: sast-snyk-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-snyk-check-oci-ta:0.4@sha256:0eca130f289a1a1069a1b92943479f79aa7324e4e68d6396fd777ccd97058f50 + value: quay.io/konflux-ci/tekton-catalog/task-sast-snyk-check-oci-ta:0.4@sha256:2ad986f28d0b724dabcf76c4de649f058f0e66998c7d2f61b66de46533bdbcad - name: kind value: task resolver: bundles @@ -454,7 +421,7 @@ spec: - name: name value: clamav-scan - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-clamav-scan:0.3@sha256:f3d2d179cddcc07d0228d9f52959a233037a3afa2619d0a8b2effbb467db80c3 + value: quay.io/konflux-ci/tekton-catalog/task-clamav-scan:0.3@sha256:9f18b216ce71a66909e7cb17d9b34526c02d73cf12884ba32d1f10614f7b9f5a - name: kind value: task resolver: bundles @@ -504,7 +471,7 @@ spec: - name: name value: sast-coverity-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-coverity-check-oci-ta:0.3@sha256:78f5244a8cfd28c890ed62db7e4ff1fc97ff39876d37fb19f1b0c2c286a4002c + value: quay.io/konflux-ci/tekton-catalog/task-sast-coverity-check-oci-ta:0.3@sha256:e92d00ed858233d0096627861192d3e4fc013cf1559c0d0b0ea0657d3377ce75 - name: kind value: task resolver: bundles @@ -525,7 +492,7 @@ spec: - name: name value: coverity-availability-check - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-coverity-availability-check:0.2@sha256:36400873d3031df128c55aa71ee11d322c3e55fd8f13dc5779098fbc117c0aa3 + value: quay.io/konflux-ci/tekton-catalog/task-coverity-availability-check:0.2@sha256:8b501440a960aec446db2ebc6625a49d0317a9fc7bf0f7bd9b18cb63052db7de - name: kind value: task resolver: bundles @@ -551,7 +518,7 @@ spec: - name: name value: sast-shell-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-shell-check-oci-ta:0.1@sha256:d44336d7bcbd1f7cedee639357a493bd1f661e2859e49e11a34644bdf6819c4e + value: quay.io/konflux-ci/tekton-catalog/task-sast-shell-check-oci-ta:0.1@sha256:c4ef47e3b4e0508572d266fb745be7e374c29dc02580328cbe9f4d472a8aca57 - name: kind value: task resolver: bundles @@ -577,7 +544,7 @@ spec: - name: name value: sast-unicode-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-unicode-check-oci-ta:0.3@sha256:e5a8d3e8e7be7246a1460385b95c084ea6e8fe7520d40fe4389deb90f1bf5176 + value: quay.io/konflux-ci/tekton-catalog/task-sast-unicode-check-oci-ta:0.4@sha256:0854d9261760b2dc8f092569739685a5ab0a5c620e9cb8c1b78fef9e2d077a29 - name: kind value: task resolver: bundles @@ -599,7 +566,7 @@ spec: - name: name value: apply-tags - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-apply-tags:0.2@sha256:e4017ec351a0891ef95989f35bd20b8c3f091fa1a3da364c4d4e975e99f3063c + value: quay.io/konflux-ci/tekton-catalog/task-apply-tags:0.3@sha256:aa62b41861c09e2e59c69cc6e9a1f740bf0c81e6a1eb03f57f59dfda0f65840e - name: kind value: task resolver: bundles @@ -622,7 +589,7 @@ spec: - name: name value: push-dockerfile-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-push-dockerfile-oci-ta:0.1@sha256:08bba4a659ecd48f871bef00b80af58954e5a09fcbb28a1783ddd640c4f6535e + value: quay.io/konflux-ci/tekton-catalog/task-push-dockerfile-oci-ta:0.3@sha256:1bc2d0f26b89259db090a47bb38217c82c05e335d626653d184adf1d196ca131 - name: kind value: task resolver: bundles @@ -639,7 +606,7 @@ spec: - name: name value: rpms-signature-scan - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-rpms-signature-scan:0.2@sha256:0b10508c82ccb0f5a06a66ce7af56e9bfd40651ddefdf0f499988e897771ee28 + value: quay.io/konflux-ci/tekton-catalog/task-rpms-signature-scan:0.2@sha256:7f2e8ed5c2d8b2433cc9a7779ce7c617de7eb0dc8f16d07d2a792cee816ed503 - name: kind value: task resolver: bundles diff --git a/.tekton/compliance-operator-content-dev-push.yaml b/.tekton/compliance-operator-content-dev-push.yaml index 289cc20338a0..db06746b8f3a 100644 --- a/.tekton/compliance-operator-content-dev-push.yaml +++ b/.tekton/compliance-operator-content-dev-push.yaml @@ -54,7 +54,7 @@ spec: - name: name value: show-sbom - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-show-sbom:0.1@sha256:beb0616db051952b4b861dd8c3e00fa1c0eccbd926feddf71194d3bb3ace9ce7 + value: quay.io/konflux-ci/tekton-catalog/task-show-sbom:0.1@sha256:04994df487ee886adbe60a8a5866647fbdfd53cc26f7b2554272ba51bf7af29e - name: kind value: task resolver: bundles @@ -77,10 +77,6 @@ spec: description: Path to the Dockerfile inside the context specified by parameter path-context name: dockerfile type: string - - default: "false" - description: Force rebuild image - name: rebuild - type: string - default: "false" description: Skip checks against built image name: skip-checks @@ -141,19 +137,12 @@ spec: value: $(tasks.clone-repository.results.commit) tasks: - name: init - params: - - name: image-url - value: $(params.output-image) - - name: rebuild - value: $(params.rebuild) - - name: skip-checks - value: $(params.skip-checks) taskRef: params: - name: name value: init - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-init:0.2@sha256:b349d24cb896573695802d6913d311640b44675ec082b3ad167721946a6a0a71 + value: quay.io/konflux-ci/tekton-catalog/task-init:0.4@sha256:288f3106118edc1d0f0c79a89c960abf5841a4dd8bc3f38feb10527253105b19 - name: kind value: task resolver: bundles @@ -174,15 +163,10 @@ spec: - name: name value: git-clone-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-git-clone-oci-ta:0.1@sha256:0a89e1a6304076525e9766f63a4cd006763d21d5aca6863281fc427537a23c6f + value: quay.io/konflux-ci/tekton-catalog/task-git-clone-oci-ta:0.1@sha256:2c388d28651457db60bb90287e7d8c3680303197196e4476878d98d81e8b6dc9 - name: kind value: task resolver: bundles - when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" workspaces: - name: basic-auth workspace: git-auth @@ -205,7 +189,7 @@ spec: - name: name value: prefetch-dependencies-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-prefetch-dependencies-oci-ta:0.2@sha256:3e5e834290a1ed57fd14c0082e5a10789c8fe382ed682ef7f981475a7b316b49 + value: quay.io/konflux-ci/tekton-catalog/task-prefetch-dependencies-oci-ta:0.3@sha256:9917d11f0a38c844184042d504b3d5605c009e6e43785fa113caae8b4c99b75e - name: kind value: task resolver: bundles @@ -257,23 +241,14 @@ spec: - name: name value: buildah-remote-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-buildah-remote-oci-ta:0.7@sha256:ef1c062b10c9fb17951350de76bce6bb54a4ea75fca4f37ea136d626c444bf78 + value: quay.io/konflux-ci/tekton-catalog/task-buildah-remote-oci-ta:0.9@sha256:4b3b76822c67fb734a9b3a5112e3810e271ee09d2777720a277a33870d3b038b - name: kind value: task resolver: bundles - when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" - name: build-image-index params: - name: IMAGE value: $(params.output-image) - - name: COMMIT_SHA - value: $(tasks.clone-repository.results.commit) - - name: IMAGE_EXPIRES_AFTER - value: $(params.image-expires-after) - name: ALWAYS_BUILD_INDEX value: $(params.build-image-index) - name: IMAGES @@ -288,15 +263,10 @@ spec: - name: name value: build-image-index - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-build-image-index:0.2@sha256:39561ac43e325159497c10c0284cf61dfddf39e39100ca5e3df6b73c5d96db8b + value: quay.io/konflux-ci/tekton-catalog/task-build-image-index:0.3@sha256:ae3fa44f005054d4901d33413972227b5642d376968a67791535cdcc2e98473d - name: kind value: task resolver: bundles - when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" - name: build-source-image params: - name: BINARY_IMAGE @@ -314,15 +284,11 @@ spec: - name: name value: source-build-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-source-build-oci-ta:0.3@sha256:4abb2dbc9dcfad52d56b490a2f25f99989a2cb2bbd9881223025272db60fd75e + value: quay.io/konflux-ci/tekton-catalog/task-source-build-oci-ta:0.3@sha256:362f0475df00e7dfb5f15dea0481d1b68b287f60411718d70a23da3c059a5613 - name: kind value: task resolver: bundles when: - - input: $(tasks.init.results.build) - operator: in - values: - - "true" - input: $(params.build-source-image) operator: in values: @@ -340,7 +306,7 @@ spec: - name: name value: deprecated-image-check - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-deprecated-image-check:0.5@sha256:462baed733dfc38aca5395499e92f19b6f13a74c2e88fe5d86c3cffa2f899b57 + value: quay.io/konflux-ci/tekton-catalog/task-deprecated-image-check:0.5@sha256:5ff16b7e6b4a8aa1adb352e74b9f831f77ff97bafd1b89ddb0038d63335f1a67 - name: kind value: task resolver: bundles @@ -367,7 +333,7 @@ spec: - name: name value: clair-scan - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-clair-scan:0.3@sha256:a5fa66ed5b8c107e7bc29cb084edcc07e394f818cc59ef2db2f9dcb0cd1fa3dc + value: quay.io/konflux-ci/tekton-catalog/task-clair-scan:0.3@sha256:89924756c91ded746cf9ccc9f07907595e5b2454ddda0219132913a4875a5f59 - name: kind value: task resolver: bundles @@ -387,7 +353,7 @@ spec: - name: name value: ecosystem-cert-preflight-checks - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-ecosystem-cert-preflight-checks:0.2@sha256:04f75593558f79a27da2336400bc63d460bf0c5669e3c13f40ee2fb650b1ad1e + value: quay.io/konflux-ci/tekton-catalog/task-ecosystem-cert-preflight-checks:0.2@sha256:b4ac586edea81dcd25dfc17f1bd57899825be2b443e48d572cd05ce058f153bb - name: kind value: task resolver: bundles @@ -420,7 +386,7 @@ spec: - name: name value: sast-snyk-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-snyk-check-oci-ta:0.4@sha256:0eca130f289a1a1069a1b92943479f79aa7324e4e68d6396fd777ccd97058f50 + value: quay.io/konflux-ci/tekton-catalog/task-sast-snyk-check-oci-ta:0.4@sha256:2ad986f28d0b724dabcf76c4de649f058f0e66998c7d2f61b66de46533bdbcad - name: kind value: task resolver: bundles @@ -442,7 +408,7 @@ spec: - name: name value: clamav-scan - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-clamav-scan:0.3@sha256:f3d2d179cddcc07d0228d9f52959a233037a3afa2619d0a8b2effbb467db80c3 + value: quay.io/konflux-ci/tekton-catalog/task-clamav-scan:0.3@sha256:9f18b216ce71a66909e7cb17d9b34526c02d73cf12884ba32d1f10614f7b9f5a - name: kind value: task resolver: bundles @@ -492,7 +458,7 @@ spec: - name: name value: sast-coverity-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-coverity-check-oci-ta:0.3@sha256:78f5244a8cfd28c890ed62db7e4ff1fc97ff39876d37fb19f1b0c2c286a4002c + value: quay.io/konflux-ci/tekton-catalog/task-sast-coverity-check-oci-ta:0.3@sha256:e92d00ed858233d0096627861192d3e4fc013cf1559c0d0b0ea0657d3377ce75 - name: kind value: task resolver: bundles @@ -513,7 +479,7 @@ spec: - name: name value: coverity-availability-check - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-coverity-availability-check:0.2@sha256:36400873d3031df128c55aa71ee11d322c3e55fd8f13dc5779098fbc117c0aa3 + value: quay.io/konflux-ci/tekton-catalog/task-coverity-availability-check:0.2@sha256:8b501440a960aec446db2ebc6625a49d0317a9fc7bf0f7bd9b18cb63052db7de - name: kind value: task resolver: bundles @@ -539,7 +505,7 @@ spec: - name: name value: sast-shell-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-shell-check-oci-ta:0.1@sha256:d44336d7bcbd1f7cedee639357a493bd1f661e2859e49e11a34644bdf6819c4e + value: quay.io/konflux-ci/tekton-catalog/task-sast-shell-check-oci-ta:0.1@sha256:c4ef47e3b4e0508572d266fb745be7e374c29dc02580328cbe9f4d472a8aca57 - name: kind value: task resolver: bundles @@ -565,7 +531,7 @@ spec: - name: name value: sast-unicode-check-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-sast-unicode-check-oci-ta:0.3@sha256:e5a8d3e8e7be7246a1460385b95c084ea6e8fe7520d40fe4389deb90f1bf5176 + value: quay.io/konflux-ci/tekton-catalog/task-sast-unicode-check-oci-ta:0.4@sha256:0854d9261760b2dc8f092569739685a5ab0a5c620e9cb8c1b78fef9e2d077a29 - name: kind value: task resolver: bundles @@ -590,7 +556,7 @@ spec: - name: name value: apply-tags - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-apply-tags:0.2@sha256:e4017ec351a0891ef95989f35bd20b8c3f091fa1a3da364c4d4e975e99f3063c + value: quay.io/konflux-ci/tekton-catalog/task-apply-tags:0.3@sha256:aa62b41861c09e2e59c69cc6e9a1f740bf0c81e6a1eb03f57f59dfda0f65840e - name: kind value: task resolver: bundles @@ -613,7 +579,7 @@ spec: - name: name value: push-dockerfile-oci-ta - name: bundle - value: quay.io/konflux-ci/tekton-catalog/task-push-dockerfile-oci-ta:0.1@sha256:08bba4a659ecd48f871bef00b80af58954e5a09fcbb28a1783ddd640c4f6535e + value: quay.io/konflux-ci/tekton-catalog/task-push-dockerfile-oci-ta:0.3@sha256:1bc2d0f26b89259db090a47bb38217c82c05e335d626653d184adf1d196ca131 - name: kind value: task resolver: bundles @@ -630,7 +596,7 @@ spec: - name: name value: rpms-signature-scan - name: bundle - value: quay.io/konflux-ci/konflux-vanguard/task-rpms-signature-scan:0.2@sha256:0b10508c82ccb0f5a06a66ce7af56e9bfd40651ddefdf0f499988e897771ee28 + value: quay.io/konflux-ci/tekton-catalog/task-rpms-signature-scan:0.2@sha256:7f2e8ed5c2d8b2433cc9a7779ce7c617de7eb0dc8f16d07d2a792cee816ed503 - name: kind value: task resolver: bundles diff --git a/.yamllint b/.yamllint index 7a97bcd9229b..d739d0536d28 100644 --- a/.yamllint +++ b/.yamllint @@ -1,13 +1,22 @@ --- extends: default +locale: en_US.UTF-8 +yaml-files: + - "*.yaml" + - "*.yml" + - "*.fmf" + - "*.profile" # https://yamllint.readthedocs.io/en/stable/rules.html rules: - comments: disable - comments-indentation: disable - document-start: disable + truthy: disable # do not check for strict true / false boolean values + comments: disable # disable syntax checking of comments + comments-indentation: disable # disable indentation checks for comments + document-start: disable # do not require the document start marker empty-lines: - level: warning + level: warning # only warn about empty lines indentation: + # pass if spaces are used for indentation and number of spaces is consistent through a file spaces: consistent - line-length: disable + line-length: + max: 99 # allow lines up to 99 chars diff --git a/CMakeLists.txt b/CMakeLists.txt index 48b206911bb3..22b05a236dd1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -33,7 +33,7 @@ include(SSGCommon) # Define Version values set(SSG_MAJOR_VERSION 0) set(SSG_MINOR_VERSION 1) -set(SSG_PATCH_VERSION 80) +set(SSG_PATCH_VERSION 82) set(SSG_VERSION "${SSG_MAJOR_VERSION}.${SSG_MINOR_VERSION}.${SSG_PATCH_VERSION}") set(SSG_VENDOR "ssgproject" CACHE STRING "Specify the XCCDF 1.2 vendor string.") @@ -96,6 +96,7 @@ option(SSG_PRODUCT_EKS "If enabled, the EKS SCAP content will be built" ${SSG_PR option(SSG_PRODUCT_EXAMPLE "If enabled, the Example SCAP content will be built" FALSE) option(SSG_PRODUCT_FEDORA "If enabled, the Fedora SCAP content will be built" ${SSG_PRODUCT_DEFAULT}) option(SSG_PRODUCT_FIREFOX "If enabled, the Firefox SCAP content will be built" ${SSG_PRODUCT_DEFAULT}) +option(SSG_PRODUCT_HUMMINGBIRD "If enabled, the Hummingbird SCAP content will be built" ${SSG_PRODUCT_DEFAULT}) option(SSG_PRODUCT_KYLINSERVER10 "If enabled, the Kylin Server V10 content will be built" ${SSG_PRODUCT_DEFAULT}) option(SSG_PRODUCT_OCP4 "If enabled, the OCP4 SCAP content will be built" ${SSG_PRODUCT_DEFAULT}) option(SSG_PRODUCT_OL7 "If enabled, the Oracle Linux 7 SCAP content will be built" ${SSG_PRODUCT_DEFAULT}) @@ -183,10 +184,7 @@ endif() # prometheus_metrics requirements find_python_module(prometheus_client) -# compliance-trestle requirements find_python_module(requests) -find_python_module(trestle) - # OCP4 requires non-standard extensions. Vanilla OpenSCAP 1.2 doesn't support it. # See also: https://github.com/ComplianceAsCode/content/issues/6798 @@ -230,7 +228,6 @@ message(STATUS "python: ${Python_EXECUTABLE} (version: ${Python_VERSION})") message(STATUS "python yaml module: ${PY_YAML}") message(STATUS "python jinja2 module: ${PY_JINJA2}") # Optional Python Tools -message(STATUS "python compliance-trestle module (optional): ${PY_TRESTLE}") message(STATUS "python cmakelint module (optional): ${PY_CMAKELINT}") message(STATUS "python github (PyGitHub) module (optional): ${PY_GITHUB}") message(STATUS "python json2html module (optional): ${PY_JSON2HTML}") @@ -333,6 +330,7 @@ message(STATUS "Example: ${SSG_PRODUCT_EXAMPLE}") message(STATUS "EKS: ${SSG_PRODUCT_EKS}") message(STATUS "Fedora: ${SSG_PRODUCT_FEDORA}") message(STATUS "Firefox: ${SSG_PRODUCT_FIREFOX}") +message(STATUS "Hummingbird: ${SSG_PRODUCT_HUMMINGBIRD}") message(STATUS "Kylin Server V10: ${SSG_PRODUCT_KYLINSERVER10}") message(STATUS "OCP4: ${SSG_PRODUCT_OCP4}") message(STATUS "RHCOS4: ${SSG_PRODUCT_RHCOS4}") @@ -347,9 +345,9 @@ message(STATUS "RHEL 8: ${SSG_PRODUCT_RHEL8}") message(STATUS "RHEL 9: ${SSG_PRODUCT_RHEL9}") message(STATUS "RHEL 10: ${SSG_PRODUCT_RHEL10}") message(STATUS "RHV 4: ${SSG_PRODUCT_RHV4}") -message(STATUS "SUSE 12: ${SSG_PRODUCT_SLE12}") -message(STATUS "SUSE 15: ${SSG_PRODUCT_SLE15}") -message(STATUS "SUSE 16: ${SSG_PRODUCT_SLE16}") +message(STATUS "SLES 12: ${SSG_PRODUCT_SLE12}") +message(STATUS "SLES 15: ${SSG_PRODUCT_SLE15}") +message(STATUS "SLES 16: ${SSG_PRODUCT_SLE16}") message(STATUS "SLE Micro 5: ${SSG_PRODUCT_SLMICRO5}") message(STATUS "SLE Micro 6: ${SSG_PRODUCT_SLMICRO6}") message(STATUS "TencentOS Server 4: ${SSG_PRODUCT_TENCENTOS4}") @@ -377,6 +375,9 @@ add_custom_target(html-profile-stats) add_custom_target(render-policies) +# NIST 800-53 Control Viewer with Gap Analysis +ssg_generate_nist_viewer() + ssg_build_man_page() if(SSG_PRODUCT_AL2023) @@ -418,6 +419,9 @@ endif() if(SSG_PRODUCT_FIREFOX) add_subdirectory("products/firefox" "firefox") endif() +if(SSG_PRODUCT_HUMMINGBIRD) + add_subdirectory("products/hummingbird" "hummingbird") +endif() if(SSG_PRODUCT_KYLINSERVER10) add_subdirectory("products/kylinserver10" "kylinserver10") endif() diff --git a/Contributors.md b/Contributors.md index 55250d73f1a4..238d34e41d83 100644 --- a/Contributors.md +++ b/Contributors.md @@ -1,5 +1,5 @@ The following people have contributed to the SCAP Security Guide project @@ -46,6 +46,7 @@ The following people have contributed to the SCAP Security Guide project * Olivier Bonhomme * bontreger * Lance Bragstad +* Vickey Brown * Ted Brunell * Marcus Burghardt * Matthew Burket @@ -72,7 +73,9 @@ The following people have contributed to the SCAP Security Guide project * cueball23 * cyarbrough76 <42849651+cyarbrough76@users.noreply.github.com> * Maura Dailey +* Harold Dean * Benjamin Deering +* Shane Dell * Klaas Demter * denknorr * dhanushkar-wso2 @@ -82,6 +85,7 @@ The following people have contributed to the SCAP Security Guide project * Marco De Donno * dperrone * drax +* Qingmin Duanmu * Sebastian Dunne * François Duthilleul * Greg Elin @@ -91,6 +95,8 @@ The following people have contributed to the SCAP Security Guide project * Evelyn * Alexis Facques * Jan Fader +* felixmarch +* Asser Schrøder Femø * Henry Finucane * Leah Fisher * Marco Fortina @@ -135,6 +141,7 @@ The following people have contributed to the SCAP Security Guide project * Simon John * Hunter Jones * Jono +* julius.ish * justchris1 * Kacper * Kai Kang @@ -169,6 +176,7 @@ The following people have contributed to the SCAP Security Guide project * Milan Lysonek * Fredrik Lysén * Mackemania <8738793+Mackemania@users.noreply.github.com> +* Peter Macko * Caitlin Macleod * Dmitry Makovey * Nick Maludy @@ -192,6 +200,7 @@ The following people have contributed to the SCAP Security Guide project * Zbynek Moravec * Kazuo Moriwaka * Michael Moseley +* Samir MOUHOUNE * Nathan Moyer * Ross Murphy * Renaud Métrich @@ -286,6 +295,7 @@ The following people have contributed to the SCAP Security Guide project * Nathan Strahs <135379779+nathanstrahs@users.noreply.github.com> * Jonathan Sturges * svet-se +* taimurhafeez * Kaushik Talathi * teacup-on-rockingchair <315160+teacup-on-rockingchair@users.noreply.github.com> * Ian Tewksbury @@ -303,6 +313,7 @@ The following people have contributed to the SCAP Security Guide project * Nico Truzzolino * Brian Turek * Matěj Týč +* Jörgen Uhr * VadimDor <29509093+VadimDor@users.noreply.github.com> * Trevor Vaughan * vtrubovics <82443408+vtrubovics@users.noreply.github.com> diff --git a/Contributors.xml b/Contributors.xml index edbff6a8b209..c18bfd4374f3 100644 --- a/Contributors.xml +++ b/Contributors.xml @@ -1,5 +1,5 @@ @@ -44,6 +44,7 @@ Last Modified: 2025-11-20 08:44 UTC Olivier Bonhomme <ptitoliv@ptitoliv.net> bontreger <bontreger@users.noreply.github.com> Lance Bragstad <lbragstad@gmail.com> +Vickey Brown <vibrown@redhat.com> Ted Brunell <tbrunell@redhat.com> Marcus Burghardt <maburgha@redhat.com> Matthew Burket <mburket@redhat.com> @@ -70,7 +71,9 @@ Last Modified: 2025-11-20 08:44 UTC cueball23 <christoph.alms@westnetz.de> cyarbrough76 <42849651+cyarbrough76@users.noreply.github.com> Maura Dailey <maura@eclipse.ncsc.mil> +Harold Dean <hdean3@users.noreply.github.com> Benjamin Deering <ben_deering@jeepingben.net> +Shane Dell <shanedell100@gmail.com> Klaas Demter <demter@atix.de> denknorr <dennis.knorr@suse.com> dhanushkar-wso2 <dhanushkar@wso2.com> @@ -80,6 +83,7 @@ Last Modified: 2025-11-20 08:44 UTC Marco De Donno <mdedonno1337@gmail.com> dperrone <dperrone@redhat.com> drax <applezip@gmail.com> +Qingmin Duanmu <qduanmu@redhat.com> Sebastian Dunne <sdunne@redhat.com> François Duthilleul <francoisduthilleul@gmail.com> Greg Elin <gregelin@gitmachines.com> @@ -89,6 +93,8 @@ Last Modified: 2025-11-20 08:44 UTC Evelyn <evansvevelyn@gmail.com> Alexis Facques <alexis.facques@mythalesgroup.io> Jan Fader <jan.fader@web.de> +felixmarch <felixmarch@users.noreply.github.com> +Asser Schrøder Femø <asser@asser.org> Henry Finucane <hfinucane@zscaler.com> Leah Fisher <lfisher047@gmail.com> Marco Fortina <marco_fortina@hotmail.it> @@ -133,6 +139,7 @@ Last Modified: 2025-11-20 08:44 UTC Simon John <sjohn@tuxcare.com> Hunter Jones <hjones2199@gmail.com> Jono <jono@ubuntu-18.localdomain> +julius.ish <julius.ish@zetier.com> justchris1 <justchris1@justchris1.email> Kacper <kacper@kacper.se> Kai Kang <kai.kang@windriver.com> @@ -167,6 +174,7 @@ Last Modified: 2025-11-20 08:44 UTC Milan Lysonek <mlysonek@redhat.com> Fredrik Lysén <fredrik@pipemore.se> Mackemania <8738793+Mackemania@users.noreply.github.com> +Peter Macko <pmacko@redhat.com> Caitlin Macleod <caitelatte@gmail.com> Dmitry Makovey <dmakovey@yahoo.com> Nick Maludy <nmaludy@gmail.com> @@ -190,6 +198,7 @@ Last Modified: 2025-11-20 08:44 UTC Zbynek Moravec <zmoravec@redhat.com> Kazuo Moriwaka <moriwaka@users.noreply.github.com> Michael Moseley <michael@eclipse.ncsc.mil> +Samir MOUHOUNE <samir.mouhoune@nav-timing.safrangroup.com> Nathan Moyer <nmoyer@spectric.com> Ross Murphy <RossMurphy@ibm.com> Renaud Métrich <rmetrich@redhat.com> @@ -284,6 +293,7 @@ Last Modified: 2025-11-20 08:44 UTC Nathan Strahs <135379779+nathanstrahs@users.noreply.github.com> Jonathan Sturges <jsturges@redhat.com> svet-se <svetlin.boychev@suse.com> +taimurhafeez <taimurhafeez93@gmail.com> Kaushik Talathi <kaushik.talathi1@ibm.com> teacup-on-rockingchair <315160+teacup-on-rockingchair@users.noreply.github.com> Ian Tewksbury <itewk@redhat.com> @@ -301,6 +311,7 @@ Last Modified: 2025-11-20 08:44 UTC Nico Truzzolino <nico.truzzolino@gmx.de> Brian Turek <brian.turek@gmail.com> Matěj Týč <matyc@redhat.com> +Jörgen Uhr <jorgen.uhr@sitevision.se> VadimDor <29509093+VadimDor@users.noreply.github.com> Trevor Vaughan <tvaughan@onyxpoint.com> vtrubovics <82443408+vtrubovics@users.noreply.github.com> diff --git a/Dockerfiles/compliance-operator-content-konflux.Containerfile b/Dockerfiles/compliance-operator-content-konflux.Containerfile index 1ad5605840c1..2dd1802a0c02 100644 --- a/Dockerfiles/compliance-operator-content-konflux.Containerfile +++ b/Dockerfiles/compliance-operator-content-konflux.Containerfile @@ -84,8 +84,8 @@ RUN grep -lr 'documentation_complete: false' ./products | xargs -I '{}' \ # Build the OpenShift and RHCOS content for x86, aarch64 and ppc64le architectures. # Only build OpenShift content for s390x architectures. RUN if [ "$(uname -m)" = "x86_64" ] || [ "$(uname -m)" = "aarch64" ] || [ "$(uname -m)" = "ppc64le" ]; then \ - ./build_product ocp4 rhcos4 --datastream-only; \ - else ./build_product ocp4 --datastream-only; \ + ./build_product ocp4 rhcos4 --datastream --cel-content=ocp4; \ + else ./build_product ocp4 --datastream --cel-content=ocp4; \ fi FROM registry.redhat.io/ubi9/ubi-minimal:latest @@ -110,3 +110,4 @@ LABEL \ WORKDIR / COPY --from=builder /go/src/github.com/ComplianceAsCode/content/LICENSE /licenses/LICENSE COPY --from=builder /go/src/github.com/ComplianceAsCode/content/build/ssg-*-ds.xml . +COPY --from=builder /go/src/github.com/ComplianceAsCode/content/build/*-cel-content.yaml . diff --git a/Dockerfiles/ocp4_content b/Dockerfiles/ocp4_content index 9ab62bf94882..7ec35c995f9f 100644 --- a/Dockerfiles/ocp4_content +++ b/Dockerfiles/ocp4_content @@ -20,6 +20,7 @@ RUN if [ "$(uname -m)" == "x86_64" ] || [ "$(uname -m)" == "aarch64" ]; then \ products/ocp4/profiles/pci-dss-node.profile \ products/ocp4/profiles/pci-dss.profile \ products/ocp4/profiles/cis-node.profile \ + products/ocp4/profiles/cis-vm-extension.profile \ products/ocp4/profiles/cis.profile \ products/ocp4/profiles/moderate-node.profile \ products/ocp4/profiles/moderate.profile \ @@ -41,13 +42,14 @@ RUN if [ "$(uname -m)" == "x86_64" ] || [ "$(uname -m)" == "aarch64" ]; then \ # OpenShift content for ppc64le and s390x architectures since we're not # including any RHCOS profiles on those architectures right now anyway. RUN if [ "$(uname -m)" = "x86_64" ] || [ "$(uname -m)" == "aarch64" ]; then \ - ./build_product ocp4 rhcos4 eks --datastream-only; \ + ./build_product ocp4 rhcos4 eks --datastream --cel-content=ocp4; \ elif [ "$(uname -m)" = "ppc64le" ]; then \ - ./build_product ocp4 rhcos4 --datastream-only; \ - else ./build_product ocp4 --datastream-only; \ + ./build_product ocp4 rhcos4 --datastream --cel-content=ocp4; \ + else ./build_product ocp4 --datastream --cel-content=ocp4; \ fi FROM registry.access.redhat.com/ubi8/ubi-micro:latest WORKDIR / COPY --from=builder /content/build/ssg-*-ds.xml . +COPY --from=builder /content/build/*-cel-content.yaml . diff --git a/Dockerfiles/quay_publish b/Dockerfiles/quay_publish index 0f13a96090b8..abbd579ca23d 100644 --- a/Dockerfiles/quay_publish +++ b/Dockerfiles/quay_publish @@ -3,10 +3,11 @@ FROM fedora:38 as builder RUN dnf -y install cmake make git /usr/bin/python3 python3-pyyaml python3-jinja2 openscap-utils RUN git clone --depth 1 https://github.com/ComplianceAsCode/content WORKDIR /content -RUN ./build_product --datastream-only --debug ocp4 rhcos4 eks +RUN ./build_product --datastream --debug ocp4 rhcos4 eks --cel-content=ocp4 FROM registry.access.redhat.com/ubi8/ubi-minimal WORKDIR / COPY --from=builder /content/build/ssg-ocp4-ds.xml . COPY --from=builder /content/build/ssg-rhcos4-ds.xml . COPY --from=builder /content/build/ssg-eks-ds.xml . +COPY --from=builder /content/build/ocp4-cel-content.yaml . diff --git a/Dockerfiles/test_suite-al2023 b/Dockerfiles/test_suite-al2023 new file mode 100644 index 000000000000..2ce4baecf74a --- /dev/null +++ b/Dockerfiles/test_suite-al2023 @@ -0,0 +1,25 @@ +# This Dockerfile is a minimal example for a RHEL-based SSG test suite target container. +FROM amazonlinux:2023 + +ENV AUTH_KEYS=/root/.ssh/authorized_keys + +ARG CLIENT_PUBLIC_KEY +ARG ADDITIONAL_PACKAGES + +# Install Python so Ansible remediations can work +# Don't clean all, as the test scenario may require package install. +RUN true \ + && dnf install -y openssh-clients openssh-server openscap-scanner tar \ + python \ + $ADDITIONAL_PACKAGES \ + && true + +RUN true \ + && for key_type in rsa ecdsa; do ssh-keygen -N '' -t $key_type -f /etc/ssh/ssh_host_${key_type}_key; done \ + && mkdir -p /root/.ssh \ + && printf "%s\n" "$CLIENT_PUBLIC_KEY" >> "$AUTH_KEYS" \ + && chmod og-rw /root/.ssh "$AUTH_KEYS" \ + && sed -i '/session\s\+required\s\+pam_loginuid.so/d' /etc/pam.d/sshd \ +&& true + +RUN echo 'PermitRootLogin yes' >> /etc/ssh/sshd_config diff --git a/Dockerfiles/test_suite-ubuntu2204 b/Dockerfiles/test_suite-ubuntu2204 index 1aab55c4e4fa..bd312a61a3c3 100644 --- a/Dockerfiles/test_suite-ubuntu2204 +++ b/Dockerfiles/test_suite-ubuntu2204 @@ -26,11 +26,9 @@ RUN true \ RUN true \ && ssh-keygen -A \ && mkdir -p /root/.ssh \ + && mkdir /run/sshd && chmod 0755 /run/sshd \ && printf "%s\n" "$CLIENT_PUBLIC_KEY" >> "$AUTH_KEYS" \ && chmod og-rw /root/.ssh "$AUTH_KEYS" \ && sed -i '/session\s\+required\s\+pam_loginuid.so/d' /etc/pam.d/sshd \ && echo CPE_NAME="cpe:/o:canonical:ubuntu_linux:22.04" >> /etc/os-release \ && true - -RUN mkdir /run/sshd -CMD ["/usr/sbin/sshd", "-D"] diff --git a/Dockerfiles/test_suite-ubuntu2404 b/Dockerfiles/test_suite-ubuntu2404 index 8b922eaa1828..8186af8740ca 100644 --- a/Dockerfiles/test_suite-ubuntu2404 +++ b/Dockerfiles/test_suite-ubuntu2404 @@ -19,10 +19,9 @@ RUN true \ RUN true \ && ssh-keygen -A \ && mkdir -p /root/.ssh \ + && mkdir /run/sshd && chmod 0755 /run/sshd \ && printf "%s\n" "$CLIENT_PUBLIC_KEY" >> "$AUTH_KEYS" \ && chmod og-rw /root/.ssh "$AUTH_KEYS" \ && sed -i '/session\s\+required\s\+pam_loginuid.so/d' /etc/pam.d/sshd \ - && echo CPE_NAME="cpe:/o:canonical:ubuntu_linux:24.04" >> /etc/os-release - -RUN mkdir /run/sshd -CMD ["/usr/sbin/sshd", "-D"] + && echo CPE_NAME="cpe:/o:canonical:ubuntu_linux:24.04" >> /etc/os-release \ +&& true diff --git a/README.md b/README.md index 3540958fa734..0c55f58224ea 100644 --- a/README.md +++ b/README.md @@ -41,6 +41,12 @@ profiles. These are meant to be run on machines to put them into compliance. We recommend using other formats but understand that for some deployment scenarios bash is the only option. +*"CEL content"* refers to compliance content using the Common Expression Language (CEL) +for Kubernetes and OpenShift platforms. CEL content is generated as YAML files and is +designed for native Kubernetes resource evaluation through the compliance-operator, +without requiring shell access to nodes. This format is used for platform-level +compliance checks on container orchestration systems. + ### Why? We want multiple organizations to be able to efficiently develop security diff --git a/applications/openshift-virtualization/group.yml b/applications/openshift-virtualization/group.yml new file mode 100644 index 000000000000..30b60e8a5a15 --- /dev/null +++ b/applications/openshift-virtualization/group.yml @@ -0,0 +1,7 @@ +documentation_complete: true + +title: 'OpenShift Virtualization' + +description: |- + This section contains security recommendations for OpenShift Virtualization + (KubeVirt) configuration and virtual machine management. diff --git a/applications/openshift-virtualization/kubevirt-enforce-trusted-tls-registries/cel/shared.yml b/applications/openshift-virtualization/kubevirt-enforce-trusted-tls-registries/cel/shared.yml new file mode 100644 index 000000000000..45f28e2bc972 --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-enforce-trusted-tls-registries/cel/shared.yml @@ -0,0 +1,17 @@ +check_type: Platform + +failure_reason: |- + There are registries not using TLS in '.spec.storageImport.insecureRegistries' in + the 'kubevirt-hyperconverged' resource. + +inputs: + - name: hco + kubernetes_input_spec: + api_version: hco.kubevirt.io/v1beta1 + resource: hyperconvergeds + resource_name: kubevirt-hyperconverged + resource_namespace: openshift-cnv + +expression: |- + !has(hco.spec.storageImport) || + hco.spec.storageImport.insecureRegistries.size() == 0 diff --git a/applications/openshift-virtualization/kubevirt-enforce-trusted-tls-registries/rule.yml b/applications/openshift-virtualization/kubevirt-enforce-trusted-tls-registries/rule.yml new file mode 100644 index 000000000000..aee19baf6f50 --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-enforce-trusted-tls-registries/rule.yml @@ -0,0 +1,28 @@ +documentation_complete: true + +title: 'Only Trusted Registries Using TLS Can Be Used' + +description: |- + By only pulling container images from trusted registries using TLS, organizations + can reduce the risk of introducing unknown vulnerabilities or malicious + software into their systems. This helps ensure that their applications and systems + remain secure and stable. All container image registries used by KubeVirt should + require TLS connections to protect the integrity and authenticity of images. + +rationale: |- + When the .spec.storageImport.insecureRegistries field contains entries in + the kubevirt-hyperconverged resource, KubeVirt is configured to allow + connections to container registries that do not use TLS encryption. This creates + a significant security risk as images could be intercepted or tampered with during + transit. Man-in-the-middle attacks could result in malicious images being pulled + and executed within virtual machines. To maintain security, only registries using + TLS should be permitted, and the insecureRegistries list should be empty. + +severity: medium + +ocil_clause: 'insecure registries are configured' + +ocil: |- + Run the following command to check for insecure registries: +
$ oc get hyperconverged kubevirt-hyperconverged -n openshift-cnv -o jsonpath='{.spec.storageImport.insecureRegistries}'
+ The output should be empty or the field should not exist. diff --git a/applications/openshift-virtualization/kubevirt-no-permitted-host-devices/cel/shared.yml b/applications/openshift-virtualization/kubevirt-no-permitted-host-devices/cel/shared.yml new file mode 100644 index 000000000000..35314927e40e --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-no-permitted-host-devices/cel/shared.yml @@ -0,0 +1,26 @@ +check_type: Platform + +failure_reason: |- + The '.spec.permittedHostDevices' field is set in the 'kubevirt-hyperconverged' + resource, allowing host devices to be used by virtualization workloads. + +inputs: + - name: hcoList + kubernetes_input_spec: + api_version: hco.kubevirt.io/v1beta1 + resource: hyperconvergeds + +expression: | + hcoList.items.filter(h, + h.metadata.name == 'kubevirt-hyperconverged' && + h.metadata.namespace == 'openshift-cnv' + ).size() == 1 && + hcoList.items.filter(h, + h.metadata.name == 'kubevirt-hyperconverged' && + h.metadata.namespace == 'openshift-cnv' + ).all(h, + !has(h.spec.permittedHostDevices) || + h.spec.permittedHostDevices == null || + (has(h.spec.permittedHostDevices.pciHostDevices) && size(h.spec.permittedHostDevices.pciHostDevices) == 0) && + (has(h.spec.permittedHostDevices.mediatedDevices) && size(h.spec.permittedHostDevices.mediatedDevices) == 0) + ) diff --git a/applications/openshift-virtualization/kubevirt-no-permitted-host-devices/rule.yml b/applications/openshift-virtualization/kubevirt-no-permitted-host-devices/rule.yml new file mode 100644 index 000000000000..74801c0044fc --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-no-permitted-host-devices/rule.yml @@ -0,0 +1,31 @@ +documentation_complete: true + +title: 'KubeVirt Must Not Permit Host Devices' + +description: |- + Host devices should not be permitted to virtualization workloads unless + absolutely necessary for workload execution. Allowing host devices provides + direct access to host hardware, which can introduce security risks including + unauthorized access to sensitive hardware resources, potential for privilege + escalation, and bypass of virtualization security boundaries. + + By default, no host devices should be trusted or permitted for use by + virtualization workloads. + +rationale: |- + The .spec.permittedHostDevices field in the kubevirt-hyperconverged + resource controls which host devices can be used by virtualization workloads. + Permitting host devices allows virtual machines to bypass virtualization boundaries + and directly access host hardware, which introduces significant security risks. + This can lead to unauthorized access to sensitive hardware resources, privilege + escalation opportunities, and potential compromise of the host system. Unless + explicitly required, no host devices should be permitted. + +severity: medium + +ocil_clause: 'permittedHostDevices are configured in kubevirt-hyperconverged' + +ocil: |- + Run the following command to check the HyperConverged configuration: +
$ oc get hyperconverged kubevirt-hyperconverged -n openshift-cnv -o jsonpath='{.spec.permittedHostDevices}'
+ The output should be empty or show empty lists for both pciHostDevices and mediatedDevices. diff --git a/applications/openshift-virtualization/kubevirt-no-vms-overcommitting-guest-memory/cel/shared.yml b/applications/openshift-virtualization/kubevirt-no-vms-overcommitting-guest-memory/cel/shared.yml new file mode 100644 index 000000000000..05abb3954b91 --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-no-vms-overcommitting-guest-memory/cel/shared.yml @@ -0,0 +1,21 @@ +check_type: Platform + +failure_reason: |- + The '.spec.template.spec.domain.resources.overcommitGuestOverhead' field exists and is + set to "true" in the 'VirtualMachine' resource, allowing VMs to + overcommit KubeVirt's memory which may lead to guests crashing and + interrupting workloads causing malfunctions. + +inputs: + - name: vms + kubernetes_input_spec: + api_version: kubevirt.io/v1 + resource: VirtualMachine + +expression: | + vms.all(h, + !has(h.spec.template.spec.domain.resources) || + !has(h.spec.template.spec.domain.resources.overcommitGuestOverhead) || + (has(h.spec.template.spec.domain.resources.overcommitGuestOverhead) && + h.spec.template.spec.domain.resources.overcommitGuestOverhead == false) + ) diff --git a/applications/openshift-virtualization/kubevirt-no-vms-overcommitting-guest-memory/rule.yml b/applications/openshift-virtualization/kubevirt-no-vms-overcommitting-guest-memory/rule.yml new file mode 100644 index 000000000000..e3f5a1b96164 --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-no-vms-overcommitting-guest-memory/rule.yml @@ -0,0 +1,28 @@ +documentation_complete: true + +title: 'VMs Must Not Overcommit Guest Memory' + +description: |- + The overcommitGuestOverhead configuration option enables the request for + additional virtual machine management memory inside the virt-launcher pod. + The overcommit feature is used to increase virtual machine density on the + node, as long as the virtual machine doesn't request all the memory that it + would need if fully loaded. However, if the VM were to use all of the + memory it could, this would lead to the OpenShift Scheduler killing the + workload. + +rationale: |- + When the .spec.template.spec.domain.resources.overcommitGuestOverhead field is + set to true in the VirtualMachine resource, VMs are allowed to + overcommit KubeVirt's memory which may lead to guests crashing and + interrupting workloads causing malfunctions. To prevent memory-related failures + and ensure workload stability, this setting should not be enabled. + +severity: medium + +ocil_clause: 'VMs have overcommitGuestOverhead set to true' + +ocil: |- + Run the following command to check VirtualMachine configurations: +
$ oc get virtualmachines -A -o jsonpath='{range .items[*]}{.metadata.namespace}{"/"}{.metadata.name}{": "}{.spec.template.spec.domain.resources.overcommitGuestOverhead}{"\n"}{end}'
+ Make sure no VirtualMachine has overcommitGuestOverhead set to true. diff --git a/applications/openshift-virtualization/kubevirt-nonroot-feature-gate-is-enabled/cel/shared.yml b/applications/openshift-virtualization/kubevirt-nonroot-feature-gate-is-enabled/cel/shared.yml new file mode 100644 index 000000000000..e9903f0d59bb --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-nonroot-feature-gate-is-enabled/cel/shared.yml @@ -0,0 +1,25 @@ +check_type: Platform + +failure_reason: |- + The '.spec.featureGates.nonRoot' field is missing or not set to 'true' in + the 'kubevirt-hyperconverged' resource. + +inputs: + - name: hcoList + kubernetes_input_spec: + api_version: hco.kubevirt.io/v1beta1 + resource: hyperconvergeds + +expression: | + hcoList.items.filter(h, + h.metadata.name == 'kubevirt-hyperconverged' && + h.metadata.namespace == 'openshift-cnv' + ).size() == 1 && + hcoList.items.filter(h, + h.metadata.name == 'kubevirt-hyperconverged' && + h.metadata.namespace == 'openshift-cnv' + ).all(h, + has(h.spec.featureGates) && + has(h.spec.featureGates.nonRoot) && + h.spec.featureGates.nonRoot == true + ) diff --git a/applications/openshift-virtualization/kubevirt-nonroot-feature-gate-is-enabled/rule.yml b/applications/openshift-virtualization/kubevirt-nonroot-feature-gate-is-enabled/rule.yml new file mode 100644 index 000000000000..754602e9cf0c --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-nonroot-feature-gate-is-enabled/rule.yml @@ -0,0 +1,28 @@ +documentation_complete: true + +title: 'KubeVirt nonRoot Feature Gate Must Be Enabled' + +description: |- + The nonRoot feature gate in KubeVirt enables restrictions that prevent + virtual machines from running with root privileges. This feature enforces + security boundaries and helps prevent privilege escalation attacks. All virtual + machines should operate with the minimum necessary privileges, and the nonRoot + feature gate ensures this principle is enforced at the platform level. + +rationale: |- + Unauthorized access to a root account without restrictions implemented by + the nonRoot feature introduces the risk of unintended or unauthorized + access to privilege elevation and the ability to perform administrative + tasks. When the .spec.featureGates.nonRoot field is set to true + in the kubevirt-hyperconverged resource, KubeVirt enforces non-root + execution for virtual machine workloads, significantly reducing the attack + surface and limiting the potential impact of security vulnerabilities. + +severity: medium + +ocil_clause: 'nonRoot feature gate is not set to true' + +ocil: |- + Run the following command to check the feature gate configuration: +
$ oc get hyperconverged kubevirt-hyperconverged -n openshift-cnv -o jsonpath='{.spec.featureGates.nonRoot}'
+ The output should be true. diff --git a/applications/openshift-virtualization/kubevirt-persistent-reservation-disabled/cel/shared.yml b/applications/openshift-virtualization/kubevirt-persistent-reservation-disabled/cel/shared.yml new file mode 100644 index 000000000000..2df3d6626eff --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-persistent-reservation-disabled/cel/shared.yml @@ -0,0 +1,25 @@ +check_type: Platform + +failure_reason: |- + The '.spec.featureGates.persistentReservation' field is missing, not set, + or not set to 'false' in the 'kubevirt-hyperconverged' resource. + +inputs: + - name: hcoList + kubernetes_input_spec: + api_version: hco.kubevirt.io/v1beta1 + resource: hyperconvergeds + +expression: | + hcoList.items.filter(h, + h.metadata.name == 'kubevirt-hyperconverged' && + h.metadata.namespace == 'openshift-cnv' + ).size() == 1 && + hcoList.items.filter(h, + h.metadata.name == 'kubevirt-hyperconverged' && + h.metadata.namespace == 'openshift-cnv' + ).all(h, + has(h.spec.featureGates) && + has(h.spec.featureGates.persistentReservation) && + h.spec.featureGates.persistentReservation == false + ) diff --git a/applications/openshift-virtualization/kubevirt-persistent-reservation-disabled/rule.yml b/applications/openshift-virtualization/kubevirt-persistent-reservation-disabled/rule.yml new file mode 100644 index 000000000000..d7fe137b55be --- /dev/null +++ b/applications/openshift-virtualization/kubevirt-persistent-reservation-disabled/rule.yml @@ -0,0 +1,30 @@ +documentation_complete: true + +title: 'KubeVirt Persistent Reservation Feature Gate Must Be Disabled' + +description: |- + The persistent reservation feature gate in KubeVirt allows virtual machines + to use SCSI persistent reservations, which provide exclusive access to shared + storage. This feature should be disabled unless explicitly required for + workload operation, as it can introduce security risks by allowing VMs to + claim exclusive access to storage resources, potentially impacting availability + and enabling resource manipulation outside normal access controls. + +rationale: |- + The .spec.featureGates.persistentReservation field in the + kubevirt-hyperconverged resource controls whether virtual machines can + use SCSI persistent reservations. When enabled, this feature allows VMs to claim + exclusive access to shared storage resources, which can be exploited to cause + denial of service conditions or manipulate storage access in ways that bypass + normal Kubernetes access controls. Unless this capability is explicitly required + for specific workload requirements, it should remain disabled to minimize the + attack surface. + +severity: medium + +ocil_clause: 'persistentReservation feature gate is not explicitly set to false' + +ocil: |- + Run the following command to check the feature gate configuration: +
$ oc get hyperconverged kubevirt-hyperconverged -n openshift-cnv -o jsonpath='{.spec.featureGates.persistentReservation}'
+ The output should be false. diff --git a/applications/openshift/accounts/accounts_restrict_service_account_tokens/rule.yml b/applications/openshift/accounts/accounts_restrict_service_account_tokens/rule.yml index d600683ecc07..a8f222cc695d 100644 --- a/applications/openshift/accounts/accounts_restrict_service_account_tokens/rule.yml +++ b/applications/openshift/accounts/accounts_restrict_service_account_tokens/rule.yml @@ -17,7 +17,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.1.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/accounts/accounts_unique_service_account/rule.yml b/applications/openshift/accounts/accounts_unique_service_account/rule.yml index e50e7997c822..ed7a3842a607 100644 --- a/applications/openshift/accounts/accounts_unique_service_account/rule.yml +++ b/applications/openshift/accounts/accounts_unique_service_account/rule.yml @@ -23,7 +23,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.1.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_alwaysadmit/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_alwaysadmit/rule.yml index f94503707996..5b407eb1b1f6 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_alwaysadmit/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_alwaysadmit/rule.yml @@ -27,7 +27,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_alwayspullimages/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_alwayspullimages/rule.yml index a5b638de4ef2..5ff105a1224c 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_alwayspullimages/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_alwayspullimages/rule.yml @@ -43,7 +43,6 @@ rationale: |- severity: high references: - cis@ocp4: 1.2.11 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_namespacelifecycle/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_namespacelifecycle/rule.yml index 20251d97eadd..8be66f23a2b5 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_namespacelifecycle/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_namespacelifecycle/rule.yml @@ -28,7 +28,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.13 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_noderestriction/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_noderestriction/rule.yml index 5056b6d0e22a..e4b87e669048 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_noderestriction/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_noderestriction/rule.yml @@ -31,7 +31,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.15 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_scc/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_scc/rule.yml index 2170370276c7..4629b83beb63 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_scc/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_scc/rule.yml @@ -31,7 +31,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.14 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_securitycontextdeny/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_securitycontextdeny/rule.yml index 6a57b8b41c93..3808bc30e3d5 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_securitycontextdeny/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_securitycontextdeny/rule.yml @@ -35,7 +35,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.13 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_admission_control_plugin_service_account/rule.yml b/applications/openshift/api-server/api_server_admission_control_plugin_service_account/rule.yml index 0baa69da1adf..0a8babd347ce 100644 --- a/applications/openshift/api-server/api_server_admission_control_plugin_service_account/rule.yml +++ b/applications/openshift/api-server/api_server_admission_control_plugin_service_account/rule.yml @@ -31,7 +31,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.12 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_anonymous_auth/rule.yml b/applications/openshift/api-server/api_server_anonymous_auth/rule.yml index e2f4dcf67019..7b918cc4aa06 100644 --- a/applications/openshift/api-server/api_server_anonymous_auth/rule.yml +++ b/applications/openshift/api-server/api_server_anonymous_auth/rule.yml @@ -34,7 +34,6 @@ rationale: |- severity: medium references: - cis@ocp4: 1.2.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_api_priority_flowschema_catch_all/rule.yml b/applications/openshift/api-server/api_server_api_priority_flowschema_catch_all/rule.yml index 7607d38b1331..59531c757d72 100644 --- a/applications/openshift/api-server/api_server_api_priority_flowschema_catch_all/rule.yml +++ b/applications/openshift/api-server/api_server_api_priority_flowschema_catch_all/rule.yml @@ -28,7 +28,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_api_priority_v1_flowschema_catch_all/rule.yml b/applications/openshift/api-server/api_server_api_priority_v1_flowschema_catch_all/rule.yml index 6bcac7761fcc..1676935b6f49 100644 --- a/applications/openshift/api-server/api_server_api_priority_v1_flowschema_catch_all/rule.yml +++ b/applications/openshift/api-server/api_server_api_priority_v1_flowschema_catch_all/rule.yml @@ -29,7 +29,6 @@ platform: ocp4.16 severity: medium references: - cis@ocp4: 1.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_api_priority_v1alpha1_flowschema_catch_all/rule.yml b/applications/openshift/api-server/api_server_api_priority_v1alpha1_flowschema_catch_all/rule.yml index ff27cb0aaf41..53148c6f75ee 100644 --- a/applications/openshift/api-server/api_server_api_priority_v1alpha1_flowschema_catch_all/rule.yml +++ b/applications/openshift/api-server/api_server_api_priority_v1alpha1_flowschema_catch_all/rule.yml @@ -31,7 +31,6 @@ platform: ocp4.6 or ocp4.7 severity: medium references: - cis@ocp4: 1.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_api_priority_v1beta1_flowschema_catch_all/rule.yml b/applications/openshift/api-server/api_server_api_priority_v1beta1_flowschema_catch_all/rule.yml index b5262de0a905..0d257d6c2157 100644 --- a/applications/openshift/api-server/api_server_api_priority_v1beta1_flowschema_catch_all/rule.yml +++ b/applications/openshift/api-server/api_server_api_priority_v1beta1_flowschema_catch_all/rule.yml @@ -30,7 +30,6 @@ platform: ocp4.8 or ocp4.9 or ocp4.10 severity: medium references: - cis@ocp4: 1.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_api_priority_v1beta2_flowschema_catch_all/rule.yml b/applications/openshift/api-server/api_server_api_priority_v1beta2_flowschema_catch_all/rule.yml index db8db128c2e5..80fa082dda3a 100644 --- a/applications/openshift/api-server/api_server_api_priority_v1beta2_flowschema_catch_all/rule.yml +++ b/applications/openshift/api-server/api_server_api_priority_v1beta2_flowschema_catch_all/rule.yml @@ -30,7 +30,6 @@ platform: ocp4.11 or ocp4.12 or ocp4.13 or ocp4.14 or ocp4.15 severity: medium references: - cis@ocp4: 1.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_audit_log_maxbackup/rule.yml b/applications/openshift/api-server/api_server_audit_log_maxbackup/rule.yml index aa793f57ee20..c4f80625b609 100644 --- a/applications/openshift/api-server/api_server_audit_log_maxbackup/rule.yml +++ b/applications/openshift/api-server/api_server_audit_log_maxbackup/rule.yml @@ -37,7 +37,6 @@ identifiers: severity: low references: - cis@ocp4: 1.2.22 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_audit_log_maxsize/rule.yml b/applications/openshift/api-server/api_server_audit_log_maxsize/rule.yml index d76509c64a3c..9f5d21d85dc5 100644 --- a/applications/openshift/api-server/api_server_audit_log_maxsize/rule.yml +++ b/applications/openshift/api-server/api_server_audit_log_maxsize/rule.yml @@ -37,7 +37,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.23 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_audit_log_path/rule.yml b/applications/openshift/api-server/api_server_audit_log_path/rule.yml index 9b6a02958667..c00d5a6c9df5 100644 --- a/applications/openshift/api-server/api_server_audit_log_path/rule.yml +++ b/applications/openshift/api-server/api_server_audit_log_path/rule.yml @@ -36,7 +36,6 @@ identifiers: severity: high references: - cis@ocp4: 1.2.20 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_auth_mode_no_aa/rule.yml b/applications/openshift/api-server/api_server_auth_mode_no_aa/rule.yml index 0a4148be2b53..006d4b74b041 100644 --- a/applications/openshift/api-server/api_server_auth_mode_no_aa/rule.yml +++ b/applications/openshift/api-server/api_server_auth_mode_no_aa/rule.yml @@ -21,7 +21,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.7 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_auth_mode_node/rule.yml b/applications/openshift/api-server/api_server_auth_mode_node/rule.yml index d5984df449ef..4ec8d05db1a9 100644 --- a/applications/openshift/api-server/api_server_auth_mode_node/rule.yml +++ b/applications/openshift/api-server/api_server_auth_mode_node/rule.yml @@ -23,7 +23,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_auth_mode_rbac/rule.yml b/applications/openshift/api-server/api_server_auth_mode_rbac/rule.yml index f9674834e9d8..b48e6b8b6b55 100644 --- a/applications/openshift/api-server/api_server_auth_mode_rbac/rule.yml +++ b/applications/openshift/api-server/api_server_auth_mode_rbac/rule.yml @@ -28,7 +28,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_basic_auth/rule.yml b/applications/openshift/api-server/api_server_basic_auth/rule.yml index 0fd241fff800..3a6cf7125144 100644 --- a/applications/openshift/api-server/api_server_basic_auth/rule.yml +++ b/applications/openshift/api-server/api_server_basic_auth/rule.yml @@ -41,7 +41,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_bind_address/rule.yml b/applications/openshift/api-server/api_server_bind_address/rule.yml index 25d3be1bb9aa..bf01dfa340c3 100644 --- a/applications/openshift/api-server/api_server_bind_address/rule.yml +++ b/applications/openshift/api-server/api_server_bind_address/rule.yml @@ -26,7 +26,6 @@ identifiers: severity: low references: - cis@ocp4: 1.2.18 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_client_ca/rule.yml b/applications/openshift/api-server/api_server_client_ca/rule.yml index 71cee9acf7eb..a0be00577867 100644 --- a/applications/openshift/api-server/api_server_client_ca/rule.yml +++ b/applications/openshift/api-server/api_server_client_ca/rule.yml @@ -38,7 +38,6 @@ rationale: |- severity: medium references: - cis@ocp4: 1.2.29 nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_encryption_provider_cipher/rule.yml b/applications/openshift/api-server/api_server_encryption_provider_cipher/rule.yml index 3025941a6743..09749a1e8d2a 100644 --- a/applications/openshift/api-server/api_server_encryption_provider_cipher/rule.yml +++ b/applications/openshift/api-server/api_server_encryption_provider_cipher/rule.yml @@ -58,7 +58,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.31,2.8 nerc-cip: CIP-003-8 R4.2 nist: SC-28,SC-28(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_etcd_ca/rule.yml b/applications/openshift/api-server/api_server_etcd_ca/rule.yml index 512a0d5b6a53..35e325ddd778 100644 --- a/applications/openshift/api-server/api_server_etcd_ca/rule.yml +++ b/applications/openshift/api-server/api_server_etcd_ca/rule.yml @@ -41,7 +41,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.30 nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_etcd_cert/rule.yml b/applications/openshift/api-server/api_server_etcd_cert/rule.yml index f20394a01cd5..535b4aaa4e02 100644 --- a/applications/openshift/api-server/api_server_etcd_cert/rule.yml +++ b/applications/openshift/api-server/api_server_etcd_cert/rule.yml @@ -39,7 +39,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.27 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_etcd_key/rule.yml b/applications/openshift/api-server/api_server_etcd_key/rule.yml index 1170c32491f4..aeb2c53a446a 100644 --- a/applications/openshift/api-server/api_server_etcd_key/rule.yml +++ b/applications/openshift/api-server/api_server_etcd_key/rule.yml @@ -39,7 +39,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.27 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_https_for_kubelet_conn/rule.yml b/applications/openshift/api-server/api_server_https_for_kubelet_conn/rule.yml index a1da41915df5..c9f9607e8b52 100644 --- a/applications/openshift/api-server/api_server_https_for_kubelet_conn/rule.yml +++ b/applications/openshift/api-server/api_server_https_for_kubelet_conn/rule.yml @@ -25,7 +25,6 @@ rationale: |- severity: medium references: - cis: 1.2.4 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.3 diff --git a/applications/openshift/api-server/api_server_insecure_bind_address/rule.yml b/applications/openshift/api-server/api_server_insecure_bind_address/rule.yml index cf0ae528d223..5b4a326c77ce 100644 --- a/applications/openshift/api-server/api_server_insecure_bind_address/rule.yml +++ b/applications/openshift/api-server/api_server_insecure_bind_address/rule.yml @@ -36,7 +36,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.16 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_kube_no_unsupported_config_overrides/rule.yml b/applications/openshift/api-server/api_server_kube_no_unsupported_config_overrides/rule.yml index 8e1b5a96ed4f..aadea31e8f99 100644 --- a/applications/openshift/api-server/api_server_kube_no_unsupported_config_overrides/rule.yml +++ b/applications/openshift/api-server/api_server_kube_no_unsupported_config_overrides/rule.yml @@ -19,9 +19,6 @@ severity: medium identifiers: cce@ocp4: CCE-89304-0 -references: - cis@ocp4: 1.2.31 - {{% set jqfilter = '[.items[] | select(.spec.unsupportedConfigOverrides != null and .spec.unsupportedConfigOverrides != {}) | .metadata.name]' %}} ocil_clause: 'Unsupported Kubernetes API server configuration overrides are detected' diff --git a/applications/openshift/api-server/api_server_kubelet_certificate_authority/rule.yml b/applications/openshift/api-server/api_server_kubelet_certificate_authority/rule.yml index 86c5195d15cb..15a4201528f1 100644 --- a/applications/openshift/api-server/api_server_kubelet_certificate_authority/rule.yml +++ b/applications/openshift/api-server/api_server_kubelet_certificate_authority/rule.yml @@ -40,7 +40,6 @@ identifiers: severity: high references: - cis@ocp4: 1.2.6 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_kubelet_client_cert/rule.yml b/applications/openshift/api-server/api_server_kubelet_client_cert/rule.yml index 0a053c21227e..4490fe20a331 100644 --- a/applications/openshift/api-server/api_server_kubelet_client_cert/rule.yml +++ b/applications/openshift/api-server/api_server_kubelet_client_cert/rule.yml @@ -38,7 +38,6 @@ platform: not ocp4-on-hypershift-hosted severity: high references: - cis@ocp4: 1.2.5 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_kubelet_client_key/rule.yml b/applications/openshift/api-server/api_server_kubelet_client_key/rule.yml index 54421c207e36..f2de2ec8298a 100644 --- a/applications/openshift/api-server/api_server_kubelet_client_key/rule.yml +++ b/applications/openshift/api-server/api_server_kubelet_client_key/rule.yml @@ -38,7 +38,6 @@ platform: not ocp4-on-hypershift-hosted severity: high references: - cis@ocp4: 1.2.5 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_no_adm_ctrl_plugins_disabled/rule.yml b/applications/openshift/api-server/api_server_no_adm_ctrl_plugins_disabled/rule.yml index cb14b4e7df17..5b52dd541242 100644 --- a/applications/openshift/api-server/api_server_no_adm_ctrl_plugins_disabled/rule.yml +++ b/applications/openshift/api-server/api_server_no_adm_ctrl_plugins_disabled/rule.yml @@ -30,7 +30,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.13,1.2.14,1.2.14,1.2.15,1.2.16,1.2.17 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_no_unsupported_config_overrides/rule.yml b/applications/openshift/api-server/api_server_no_unsupported_config_overrides/rule.yml index d6d1a20e9f96..252374c718cf 100644 --- a/applications/openshift/api-server/api_server_no_unsupported_config_overrides/rule.yml +++ b/applications/openshift/api-server/api_server_no_unsupported_config_overrides/rule.yml @@ -19,9 +19,6 @@ severity: medium identifiers: cce@ocp4: CCE-89950-0 -references: - cis@ocp4: 1.2.31 - {{% set jqfilter = '[.items[] | select(.spec.unsupportedConfigOverrides != null and .spec.unsupportedConfigOverrides != {}) | .metadata.name]' %}} ocil_clause: 'Unsupported OpenShift API server configuration overrides are detected' diff --git a/applications/openshift/api-server/api_server_oauth_https_serving_cert/rule.yml b/applications/openshift/api-server/api_server_oauth_https_serving_cert/rule.yml index 386f58bec03a..17a0541a29bf 100644 --- a/applications/openshift/api-server/api_server_oauth_https_serving_cert/rule.yml +++ b/applications/openshift/api-server/api_server_oauth_https_serving_cert/rule.yml @@ -19,7 +19,6 @@ rationale: |- severity: medium references: - cis@ocp4: 1.2.4 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_openshift_https_serving_cert/rule.yml b/applications/openshift/api-server/api_server_openshift_https_serving_cert/rule.yml index 11ed528fe76e..c33e8e60387b 100644 --- a/applications/openshift/api-server/api_server_openshift_https_serving_cert/rule.yml +++ b/applications/openshift/api-server/api_server_openshift_https_serving_cert/rule.yml @@ -19,7 +19,6 @@ rationale: |- severity: medium references: - cis@ocp4: 1.2.4 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_profiling_protected_by_rbac/rule.yml b/applications/openshift/api-server/api_server_profiling_protected_by_rbac/rule.yml index d4bcaed378a2..0a64ee665feb 100644 --- a/applications/openshift/api-server/api_server_profiling_protected_by_rbac/rule.yml +++ b/applications/openshift/api-server/api_server_profiling_protected_by_rbac/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-84212-0 references: - cis@ocp4: 1.2.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_request_timeout/rule.yml b/applications/openshift/api-server/api_server_request_timeout/rule.yml index 01fa46206000..a7651e7447a2 100644 --- a/applications/openshift/api-server/api_server_request_timeout/rule.yml +++ b/applications/openshift/api-server/api_server_request_timeout/rule.yml @@ -37,7 +37,6 @@ rationale: |- severity: medium references: - cis@ocp4: 1.2.24 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_service_account_lookup/rule.yml b/applications/openshift/api-server/api_server_service_account_lookup/rule.yml index c4e9a714200a..b171a3aa7f80 100644 --- a/applications/openshift/api-server/api_server_service_account_lookup/rule.yml +++ b/applications/openshift/api-server/api_server_service_account_lookup/rule.yml @@ -28,7 +28,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.25 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/api_server_service_account_public_key/rule.yml b/applications/openshift/api-server/api_server_service_account_public_key/rule.yml index ce569f550045..756df88a1929 100644 --- a/applications/openshift/api-server/api_server_service_account_public_key/rule.yml +++ b/applications/openshift/api-server/api_server_service_account_public_key/rule.yml @@ -39,7 +39,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.26 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_tls_cert/rule.yml b/applications/openshift/api-server/api_server_tls_cert/rule.yml index 53332478a6e0..50afdb8491ec 100644 --- a/applications/openshift/api-server/api_server_tls_cert/rule.yml +++ b/applications/openshift/api-server/api_server_tls_cert/rule.yml @@ -39,7 +39,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.28 nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_tls_cipher_suites/rule.yml b/applications/openshift/api-server/api_server_tls_cipher_suites/rule.yml index cb41de1fa050..4d05932142e2 100644 --- a/applications/openshift/api-server/api_server_tls_cipher_suites/rule.yml +++ b/applications/openshift/api-server/api_server_tls_cipher_suites/rule.yml @@ -41,7 +41,6 @@ rationale: |- severity: medium references: - cis@ocp4: 1.2.32 nist: CM-6 pcidss: Req-2.2,Req-2.2.3,Req-2.3 srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/api-server/api_server_tls_private_key/rule.yml b/applications/openshift/api-server/api_server_tls_private_key/rule.yml index f0fc2363c6ca..f01b4e839125 100644 --- a/applications/openshift/api-server/api_server_tls_private_key/rule.yml +++ b/applications/openshift/api-server/api_server_tls_private_key/rule.yml @@ -39,7 +39,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.28 nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/api-server/api_server_token_auth/rule.yml b/applications/openshift/api-server/api_server_token_auth/rule.yml index 6f529a4ceaa8..5fc872228db5 100644 --- a/applications/openshift/api-server/api_server_token_auth/rule.yml +++ b/applications/openshift/api-server/api_server_token_auth/rule.yml @@ -39,7 +39,6 @@ identifiers: severity: high references: - cis@ocp4: 1.2.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/api-server/audit_log_forwarding_enabled/rule.yml b/applications/openshift/api-server/audit_log_forwarding_enabled/rule.yml index 13b185d752a4..e6584fbaec32 100644 --- a/applications/openshift/api-server/audit_log_forwarding_enabled/rule.yml +++ b/applications/openshift/api-server/audit_log_forwarding_enabled/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-84076-9 references: - cis@ocp4: 1.2.21 nerc-cip: CIP-003-8 R5.2,CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-004-6 R3.3,CIP-007-3 R.1.3,CIP-007-3 R5,CIP-007-3 R5.1.1,CIP-007-3 R5.2,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3,CIP-007-3 R6.5 nist: AC-2(12),AU-3(2),AU-5(1),AU-6,AU-6(1),AU-6(3),AU-9(2),SI-4(16),AU-4(1),AU-11,AU-7,AU-7(1),SI-4(20) pcidss: Req-2.2,Req-10.5.3,Req-10.5.4 diff --git a/applications/openshift/api-server/audit_log_forwarding_enabled_logging_api/rule.yml b/applications/openshift/api-server/audit_log_forwarding_enabled_logging_api/rule.yml index db08bd2ffd8e..b5441347719c 100644 --- a/applications/openshift/api-server/audit_log_forwarding_enabled_logging_api/rule.yml +++ b/applications/openshift/api-server/audit_log_forwarding_enabled_logging_api/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-86258-1 references: - cis@ocp4: 1.2.21 nerc-cip: CIP-003-8 R5.2,CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-004-6 R3.3,CIP-007-3 R.1.3,CIP-007-3 R5,CIP-007-3 R5.1.1,CIP-007-3 R5.2,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3,CIP-007-3 R6.5 nist: AC-2(12),AU-3(2),AU-5(1),AU-6,AU-6(1),AU-6(3),AU-9(2),SI-4(16),AU-4(1),AU-11,AU-7,AU-7(1),SI-4(20) pcidss: Req-2.2,Req-10.5.3,Req-10.5.4 diff --git a/applications/openshift/api-server/audit_log_forwarding_enabled_observability_api/rule.yml b/applications/openshift/api-server/audit_log_forwarding_enabled_observability_api/rule.yml index 30426e49d764..fc3fa7311fa2 100644 --- a/applications/openshift/api-server/audit_log_forwarding_enabled_observability_api/rule.yml +++ b/applications/openshift/api-server/audit_log_forwarding_enabled_observability_api/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-86265-6 references: - cis@ocp4: 1.2.21 nerc-cip: CIP-003-8 R5.2,CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-004-6 R3.3,CIP-007-3 R.1.3,CIP-007-3 R5,CIP-007-3 R5.1.1,CIP-007-3 R5.2,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3,CIP-007-3 R6.5 nist: AC-2(12),AU-3(2),AU-5(1),AU-6,AU-6(1),AU-6(3),AU-9(2),SI-4(16),AU-4(1),AU-11,AU-7,AU-7(1),SI-4(20) pcidss: Req-2.2,Req-10.5.3,Req-10.5.4 diff --git a/applications/openshift/api-server/audit_log_forwarding_webhook/rule.yml b/applications/openshift/api-server/audit_log_forwarding_webhook/rule.yml index 1a42d8f30f07..2c591d979c5e 100644 --- a/applications/openshift/api-server/audit_log_forwarding_webhook/rule.yml +++ b/applications/openshift/api-server/audit_log_forwarding_webhook/rule.yml @@ -30,7 +30,6 @@ identifiers: cce@ocp4: CCE-86103-9 references: - cis@ocp4: 1.2.21 pcidss: Req-2.2,Req-10.5.3,Req-10.5.4 platform: ocp4-on-hypershift diff --git a/applications/openshift/api-server/audit_log_forwarding_webhook_logging_api/rule.yml b/applications/openshift/api-server/audit_log_forwarding_webhook_logging_api/rule.yml index 55df55406f8b..14f0f2513e4a 100644 --- a/applications/openshift/api-server/audit_log_forwarding_webhook_logging_api/rule.yml +++ b/applications/openshift/api-server/audit_log_forwarding_webhook_logging_api/rule.yml @@ -24,7 +24,6 @@ identifiers: cce@ocp4: CCE-86658-2 references: - cis@ocp4: 1.2.21 pcidss: Req-2.2,Req-10.5.3,Req-10.5.4 platform: ocp4-on-hypershift diff --git a/applications/openshift/api-server/audit_log_forwarding_webhook_observability_api/rule.yml b/applications/openshift/api-server/audit_log_forwarding_webhook_observability_api/rule.yml index bcfc04d1448b..033f48138d22 100644 --- a/applications/openshift/api-server/audit_log_forwarding_webhook_observability_api/rule.yml +++ b/applications/openshift/api-server/audit_log_forwarding_webhook_observability_api/rule.yml @@ -24,7 +24,6 @@ identifiers: cce@ocp4: CCE-86660-8 references: - cis@ocp4: 1.2.21 pcidss: Req-2.2,Req-10.5.3,Req-10.5.4 platform: ocp4-on-hypershift diff --git a/applications/openshift/authentication/idp_is_configured/rule.yml b/applications/openshift/authentication/idp_is_configured/rule.yml index 5c10b47ceaf1..e72d054052e5 100644 --- a/applications/openshift/authentication/idp_is_configured/rule.yml +++ b/applications/openshift/authentication/idp_is_configured/rule.yml @@ -63,7 +63,6 @@ identifiers: references: - cis@ocp4: 3.1.1 nerc-cip: CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-007-3 R.1.3,CIP-007-3 R5,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2,CIP-007-3 R5.1.3,CIP-007-3 R5.2,CIP-007-3 R5.2.1,CIP-007-3 R5.2.3,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3 nist: AC-2,AC-2(1),AC-2(2),AC-2(3),AC-2(4),AC-2(5),AC-2(6),AC-2(7),AC-2(8),AC-7,AC-12(1),IA-2(8),IA-2(9),SC-12(1) pcidss: Req-2.2,Req-8.1.1 diff --git a/applications/openshift/controller/controller_insecure_port_disabled/rule.yml b/applications/openshift/controller/controller_insecure_port_disabled/rule.yml index c14754fdbefa..e0dd4b4f79c7 100644 --- a/applications/openshift/controller/controller_insecure_port_disabled/rule.yml +++ b/applications/openshift/controller/controller_insecure_port_disabled/rule.yml @@ -54,7 +54,6 @@ ocil: |- Verify that it's true in the console output (the value will be true if the insecure port is bind to loopback address or disabled) . references: - cis@ocp4: 1.3.5 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/controller/controller_secure_port/rule.yml b/applications/openshift/controller/controller_secure_port/rule.yml index cbf6fdf795d7..2dc1d37cad5c 100644 --- a/applications/openshift/controller/controller_secure_port/rule.yml +++ b/applications/openshift/controller/controller_secure_port/rule.yml @@ -48,7 +48,6 @@ ocil: |- Verify that it's using an appropriate port (the value is not
0
). references: - cis@ocp4: 1.3.5 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/controller/controller_service_account_ca/rule.yml b/applications/openshift/controller/controller_service_account_ca/rule.yml index c4fa7046863d..04f72e7511c4 100644 --- a/applications/openshift/controller/controller_service_account_ca/rule.yml +++ b/applications/openshift/controller/controller_service_account_ca/rule.yml @@ -38,7 +38,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.3.4 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/controller/controller_service_account_private_key/rule.yml b/applications/openshift/controller/controller_service_account_private_key/rule.yml index 1572ded0d5d0..a1d0ae10ee36 100644 --- a/applications/openshift/controller/controller_service_account_private_key/rule.yml +++ b/applications/openshift/controller/controller_service_account_private_key/rule.yml @@ -40,7 +40,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.3.3 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/controller/controller_use_service_account/rule.yml b/applications/openshift/controller/controller_use_service_account/rule.yml index 03b7761b988e..07cd871b34b4 100644 --- a/applications/openshift/controller/controller_use_service_account/rule.yml +++ b/applications/openshift/controller/controller_use_service_account/rule.yml @@ -42,7 +42,6 @@ identifiers: cce@ocp4: CCE-84208-8 references: - cis@ocp4: 1.3.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/etcd/etcd_auto_tls/rule.yml b/applications/openshift/etcd/etcd_auto_tls/rule.yml index 1a8435468dc1..f728925aff60 100644 --- a/applications/openshift/etcd/etcd_auto_tls/rule.yml +++ b/applications/openshift/etcd/etcd_auto_tls/rule.yml @@ -31,7 +31,6 @@ identifiers: cce@ocp4: CCE-84199-9 references: - cis@ocp4: '2.3' nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/etcd/etcd_cert_file/rule.yml b/applications/openshift/etcd/etcd_cert_file/rule.yml index 53d7db44d674..465001857826 100644 --- a/applications/openshift/etcd/etcd_cert_file/rule.yml +++ b/applications/openshift/etcd/etcd_cert_file/rule.yml @@ -31,7 +31,6 @@ identifiers: cce@ocp4: CCE-83553-8 references: - cis@ocp4: '2.1' nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/etcd/etcd_client_cert_auth/rule.yml b/applications/openshift/etcd/etcd_client_cert_auth/rule.yml index 663e565381ca..382ee21c2ee9 100644 --- a/applications/openshift/etcd/etcd_client_cert_auth/rule.yml +++ b/applications/openshift/etcd/etcd_client_cert_auth/rule.yml @@ -29,7 +29,6 @@ identifiers: cce@ocp4: CCE-84077-7 references: - cis@ocp4: '2.2' nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/etcd/etcd_key_file/rule.yml b/applications/openshift/etcd/etcd_key_file/rule.yml index 1b3940eeb37d..a16dd7b15425 100644 --- a/applications/openshift/etcd/etcd_key_file/rule.yml +++ b/applications/openshift/etcd/etcd_key_file/rule.yml @@ -31,7 +31,6 @@ identifiers: cce@ocp4: CCE-83745-0 references: - cis@ocp4: '2.1' nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/etcd/etcd_peer_auto_tls/rule.yml b/applications/openshift/etcd/etcd_peer_auto_tls/rule.yml index 325bebeba5a8..171e5e7e32ef 100644 --- a/applications/openshift/etcd/etcd_peer_auto_tls/rule.yml +++ b/applications/openshift/etcd/etcd_peer_auto_tls/rule.yml @@ -31,7 +31,6 @@ identifiers: cce@ocp4: CCE-84184-1 references: - cis@ocp4: '2.6' nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/etcd/etcd_peer_cert_file/rule.yml b/applications/openshift/etcd/etcd_peer_cert_file/rule.yml index 6e7a7b86225e..745eed1d0aad 100644 --- a/applications/openshift/etcd/etcd_peer_cert_file/rule.yml +++ b/applications/openshift/etcd/etcd_peer_cert_file/rule.yml @@ -31,7 +31,6 @@ identifiers: cce@ocp4: CCE-83847-4 references: - cis@ocp4: '2.4' nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/etcd/etcd_peer_client_cert_auth/rule.yml b/applications/openshift/etcd/etcd_peer_client_cert_auth/rule.yml index caa097b41a3f..52ae608da8f9 100644 --- a/applications/openshift/etcd/etcd_peer_client_cert_auth/rule.yml +++ b/applications/openshift/etcd/etcd_peer_client_cert_auth/rule.yml @@ -29,7 +29,6 @@ identifiers: cce@ocp4: CCE-83465-5 references: - cis@ocp4: '2.5' nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/etcd/etcd_peer_key_file/rule.yml b/applications/openshift/etcd/etcd_peer_key_file/rule.yml index 86de972061c6..8c810591a461 100644 --- a/applications/openshift/etcd/etcd_peer_key_file/rule.yml +++ b/applications/openshift/etcd/etcd_peer_key_file/rule.yml @@ -31,7 +31,6 @@ identifiers: cce@ocp4: CCE-83711-2 references: - cis@ocp4: '2.4' nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/etcd/etcd_unique_ca/rule.yml b/applications/openshift/etcd/etcd_unique_ca/rule.yml index feadfb3777c7..a34ddb87a1da 100644 --- a/applications/openshift/etcd/etcd_unique_ca/rule.yml +++ b/applications/openshift/etcd/etcd_unique_ca/rule.yml @@ -22,7 +22,6 @@ identifiers: cce@ocp4: CCE-87514-6 references: - cis@ocp4: '2.7' nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/general/general_apply_scc/rule.yml b/applications/openshift/general/general_apply_scc/rule.yml index 60e955cccdbe..c7a9a609347e 100644 --- a/applications/openshift/general/general_apply_scc/rule.yml +++ b/applications/openshift/general/general_apply_scc/rule.yml @@ -27,7 +27,6 @@ ocil: |- build your own, please refer to the {{{ weblink(link="https://docs.openshift.com/container-platform/4.11/authentication/managing-security-context-constraints.html", text="OpenShift security constraints documentation") }}}. references: - cis@ocp4: 5.7.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/general/general_default_namespace_use/rule.yml b/applications/openshift/general/general_default_namespace_use/rule.yml index 36de9f55ce6f..0ca38a7dec2c 100644 --- a/applications/openshift/general/general_default_namespace_use/rule.yml +++ b/applications/openshift/general/general_default_namespace_use/rule.yml @@ -24,7 +24,6 @@ ocil: |- kubernetes and openshift service. references: - cis@ocp4: 5.7.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/general/general_default_seccomp_profile/rule.yml b/applications/openshift/general/general_default_seccomp_profile/rule.yml index 1a807bf0ecc3..8a3552cc125a 100644 --- a/applications/openshift/general/general_default_seccomp_profile/rule.yml +++ b/applications/openshift/general/general_default_seccomp_profile/rule.yml @@ -30,7 +30,6 @@ ocil: |- Security Context Constraints. references: - cis@ocp4: 5.7.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/general/general_namespaces_in_use/rule.yml b/applications/openshift/general/general_namespaces_in_use/rule.yml index 7f130b2f5b9a..d0939afbb97a 100644 --- a/applications/openshift/general/general_namespaces_in_use/rule.yml +++ b/applications/openshift/general/general_namespaces_in_use/rule.yml @@ -27,7 +27,6 @@ ocil: |- the ones you need and are adequately administered. references: - cis@ocp4: 5.7.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/general/kubeadmin_removed/rule.yml b/applications/openshift/general/kubeadmin_removed/rule.yml index 93fcb721b73c..8b54253998e8 100644 --- a/applications/openshift/general/kubeadmin_removed/rule.yml +++ b/applications/openshift/general/kubeadmin_removed/rule.yml @@ -22,7 +22,6 @@ identifiers: cce@ocp4: CCE-90387-2 references: - cis@ocp4: 3.1.1,5.1.1 nerc-cip: CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-007-3 R.1.3,CIP-007-3 R2,CIP-007-3 R5,CIP-007-3 R5.1.1,CIP-007-3 R5.1.3,CIP-007-3 R5.2.1,CIP-007-3 R5.2.3,CIP-007-3 R6.1,CIP-007-3 R6.2,CIP-007-3 R6.3,CIP-007-3 R6.4 nist: AC-2(2),AC-2(7),AC-2(9),AC-2(10),AC-12(1),IA-2(5),MA-4,SC-12(1) pcidss: Req-2.1 diff --git a/applications/openshift/kubelet/kubelet_anonymous_auth/rule.yml b/applications/openshift/kubelet/kubelet_anonymous_auth/rule.yml index fb5bd9353e6d..aadcb22cd771 100644 --- a/applications/openshift/kubelet/kubelet_anonymous_auth/rule.yml +++ b/applications/openshift/kubelet/kubelet_anonymous_auth/rule.yml @@ -36,7 +36,6 @@ severity: medium references: cis@eks: 3.2.1 - cis@ocp4: 4.2.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -54,7 +53,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.authentication.anonymous.enabled" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_authorization_mode/rule.yml b/applications/openshift/kubelet/kubelet_authorization_mode/rule.yml index f246164acfe6..56af3440b9ca 100644 --- a/applications/openshift/kubelet/kubelet_authorization_mode/rule.yml +++ b/applications/openshift/kubelet/kubelet_authorization_mode/rule.yml @@ -34,7 +34,6 @@ severity: medium references: cis@eks: 3.2.2 - cis@ocp4: 4.2.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -50,7 +49,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.authorization.mode" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_configure_client_ca/rule.yml b/applications/openshift/kubelet/kubelet_configure_client_ca/rule.yml index df0c6741d6e0..d5aace6946af 100644 --- a/applications/openshift/kubelet/kubelet_configure_client_ca/rule.yml +++ b/applications/openshift/kubelet/kubelet_configure_client_ca/rule.yml @@ -47,7 +47,6 @@ identifiers: references: cis@eks: 3.2.3 - cis@ocp4: 4.2.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -55,7 +54,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.authentication.x509.clientCAFile" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_configure_event_creation/rule.yml b/applications/openshift/kubelet/kubelet_configure_event_creation/rule.yml index 0b8e28cb2e65..ab9b95fd4b6d 100644 --- a/applications/openshift/kubelet/kubelet_configure_event_creation/rule.yml +++ b/applications/openshift/kubelet/kubelet_configure_event_creation/rule.yml @@ -52,7 +52,6 @@ ocil: |- The output should return {{ .var_event_record_qps }}. references: - cis@ocp4: 4.2.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -63,7 +62,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.eventRecordQPS" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_configure_event_creation/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_configure_event_creation/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_configure_event_creation/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_configure_event_creation/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_configure_event_creation/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_configure_event_creation/tests/nomatch.fail.sh index ce3c83159be3..75a5b15382dd 100644 --- a/applications/openshift/kubelet/kubelet_configure_event_creation/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_configure_event_creation/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_configure_tls_cert/rule.yml b/applications/openshift/kubelet/kubelet_configure_tls_cert/rule.yml index 98cc7255b14e..a37065814afd 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_cert/rule.yml +++ b/applications/openshift/kubelet/kubelet_configure_tls_cert/rule.yml @@ -29,7 +29,6 @@ identifiers: platform: not ocp4-on-hypershift-hosted references: - cis@ocp4: 4.2.9 nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/rule.yml b/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/rule.yml index 3d966c4b582d..d5a27a061375 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/rule.yml +++ b/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/rule.yml @@ -43,7 +43,6 @@ identifiers: cce@ocp4: CCE-86030-4 references: - cis@ocp4: 4.2.12 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -71,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.tlsCipherSuites[:]" xccdf_variable: var_kubelet_tls_cipher_suites_regex regex_data: true diff --git a/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/nomatch.fail.sh index 9a842a0ba4bf..14a073cc4591 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_configure_tls_cipher_suites/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_configure_tls_key/rule.yml b/applications/openshift/kubelet/kubelet_configure_tls_key/rule.yml index 550b52d0428a..e6690fba989d 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_key/rule.yml +++ b/applications/openshift/kubelet/kubelet_configure_tls_key/rule.yml @@ -29,7 +29,6 @@ identifiers: platform: not ocp4-on-hypershift-hosted references: - cis@ocp4: 4.2.9 nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-8,SC-8(1),SC-8(2) pcidss: Req-2.2,Req-2.2.3,Req-2.3 diff --git a/applications/openshift/kubelet/kubelet_configure_tls_min_version/rule.yml b/applications/openshift/kubelet/kubelet_configure_tls_min_version/rule.yml index cd8973972c60..f8b2f0655004 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_min_version/rule.yml +++ b/applications/openshift/kubelet/kubelet_configure_tls_min_version/rule.yml @@ -87,7 +87,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.tlsMinVersion" xccdf_variable: var_kubelet_tls_min_version_regex regex_data: true diff --git a/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/nomatch.fail.sh index c741d5e2088b..1e86b2f8f27b 100644 --- a/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_configure_tls_min_version/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS09","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_disable_hostname_override/rule.yml b/applications/openshift/kubelet/kubelet_disable_hostname_override/rule.yml index 2b89235432ba..4095435cc2ed 100644 --- a/applications/openshift/kubelet/kubelet_disable_hostname_override/rule.yml +++ b/applications/openshift/kubelet/kubelet_disable_hostname_override/rule.yml @@ -33,7 +33,6 @@ severity: low references: cis@eks: 3.2.8 - cis@ocp4: 4.2.8 nerc-cip: CIP-003-3 R6,CIP-004-3 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) @@ -41,7 +40,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.hostname-override" check_existence: "none_exist" values: diff --git a/applications/openshift/kubelet/kubelet_disable_readonly_port/rule.yml b/applications/openshift/kubelet/kubelet_disable_readonly_port/rule.yml index 84c06cf7d7f1..d94e72760a25 100644 --- a/applications/openshift/kubelet/kubelet_disable_readonly_port/rule.yml +++ b/applications/openshift/kubelet/kubelet_disable_readonly_port/rule.yml @@ -43,7 +43,6 @@ identifiers: cce@ocp4: CCE-83427-5 references: - cis@ocp4: 4.2.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/kubelet/kubelet_enable_cert_rotation/rule.yml b/applications/openshift/kubelet/kubelet_enable_cert_rotation/rule.yml index f42d5bed8b4f..f74ebe803f05 100644 --- a/applications/openshift/kubelet/kubelet_enable_cert_rotation/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_cert_rotation/rule.yml @@ -39,7 +39,6 @@ identifiers: references: cis@eks: 3.2.10 - cis@ocp4: 4.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -47,7 +46,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.rotateCertificates" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_enable_client_cert_rotation/rule.yml b/applications/openshift/kubelet/kubelet_enable_client_cert_rotation/rule.yml index 934325e14c2c..cf20531fa67f 100644 --- a/applications/openshift/kubelet/kubelet_enable_client_cert_rotation/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_client_cert_rotation/rule.yml @@ -40,7 +40,6 @@ identifiers: references: cis@eks: 3.2.10 - cis@ocp4: 4.2.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -48,7 +47,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.featureGates.RotateKubeletClientCertificate" check_existence: "any_exist" values: diff --git a/applications/openshift/kubelet/kubelet_enable_iptables_util_chains/rule.yml b/applications/openshift/kubelet/kubelet_enable_iptables_util_chains/rule.yml index ed7077280c3d..aa571bbe2bca 100644 --- a/applications/openshift/kubelet/kubelet_enable_iptables_util_chains/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_iptables_util_chains/rule.yml @@ -40,7 +40,6 @@ identifiers: references: cis@eks: 3.2.7 - cis@ocp4: 4.2.7 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -48,7 +47,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.makeIPTablesUtilChains" values: - value: "true" diff --git a/applications/openshift/kubelet/kubelet_enable_protect_kernel_defaults/rule.yml b/applications/openshift/kubelet/kubelet_enable_protect_kernel_defaults/rule.yml index cceb033c4591..bc2b459fe9dc 100644 --- a/applications/openshift/kubelet/kubelet_enable_protect_kernel_defaults/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_protect_kernel_defaults/rule.yml @@ -106,7 +106,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.protectKernelDefaults" values: - value: "true" diff --git a/applications/openshift/kubelet/kubelet_enable_server_cert_rotation/rule.yml b/applications/openshift/kubelet/kubelet_enable_server_cert_rotation/rule.yml index a142865f6cf8..79482877c34a 100644 --- a/applications/openshift/kubelet/kubelet_enable_server_cert_rotation/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_server_cert_rotation/rule.yml @@ -37,7 +37,6 @@ identifiers: references: cis@eks: 3.2.11 - cis@ocp4: 4.2.11 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -45,7 +44,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.serverTLSBootstrap" values: - value: "true" diff --git a/applications/openshift/kubelet/kubelet_enable_streaming_connections/rule.yml b/applications/openshift/kubelet/kubelet_enable_streaming_connections/rule.yml index cb5b0eebb70a..db7638e245c1 100644 --- a/applications/openshift/kubelet/kubelet_enable_streaming_connections/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_streaming_connections/rule.yml @@ -43,7 +43,6 @@ identifiers: references: cis@eks: 3.2.5 - cis@ocp4: 4.2.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -51,7 +50,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.streamingConnectionIdleTimeout" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/nomatch.fail.sh index 82a62511dbae..5b1d873b7926 100644 --- a/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_enable_streaming_connections/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_enable_streaming_connections_deprecated/rule.yml b/applications/openshift/kubelet/kubelet_enable_streaming_connections_deprecated/rule.yml index 15d46d9cd2b1..827ce668dabc 100644 --- a/applications/openshift/kubelet/kubelet_enable_streaming_connections_deprecated/rule.yml +++ b/applications/openshift/kubelet/kubelet_enable_streaming_connections_deprecated/rule.yml @@ -35,7 +35,6 @@ ocil: |- references: cis@eks: 3.2.5 - cis@ocp4: 4.2.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/rule.yml index 2ecf190bc1fc..56c1cb4c80dd 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/rule.yml @@ -55,7 +55,6 @@ identifiers: cce@ocp4: CCE-84144-5 references: - cis@ocp4: 4.2.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -71,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionHard['imagefs.available']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/nomatch.fail.sh index ce3c83159be3..75a5b15382dd 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_available/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_inodesfree/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_inodesfree/rule.yml index d40bd99eb83d..e5c2ad5bc6a6 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_inodesfree/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_imagefs_inodesfree/rule.yml @@ -70,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionHard['imagefs.inodesFree']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/rule.yml index e049d74f1764..b1fd29a4c280 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/rule.yml @@ -54,7 +54,6 @@ identifiers: cce@ocp4: CCE-84135-3 references: - cis@ocp4: 4.2.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -71,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionHard['memory.available']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/nomatch.fail.sh index ce3c83159be3..75a5b15382dd 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_memory_available/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/rule.yml index 6396d1ea2aec..1c59a959eed5 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/rule.yml @@ -54,7 +54,6 @@ identifiers: cce@ocp4: CCE-84138-7 references: - cis@ocp4: 4.2.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -71,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionHard['nodefs.available']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/nomatch.fail.sh index ce3c83159be3..75a5b15382dd 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_available/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/rule.yml index 316cece90314..e4b49762bf18 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/rule.yml @@ -54,7 +54,6 @@ identifiers: cce@ocp4: CCE-84141-1 references: - cis@ocp4: 4.2.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 @@ -71,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionHard['nodefs.inodesFree']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/match.pass.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/match.pass.sh index b84b1d4335e5..da19268519d4 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/match.pass.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/match.pass.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":5,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionHard":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionSoft":{"imagefs.available":"15%","imagefs.inodesfree":"15%","memory.available":"100Mi","nodefs.available":"10%","nodefs.inodesFree":"5%"},"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/nomatch.fail.sh b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/nomatch.fail.sh index ce3c83159be3..75a5b15382dd 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/nomatch.fail.sh +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_hard_nodefs_inodesfree/tests/nomatch.fail.sh @@ -1,8 +1,8 @@ #!/bin/bash # remediation = none -mkdir -p "/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig" +mkdir -p "/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig" -cat << EOF > /etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig +cat << EOF > /var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig/openscap-kubeletconfig {"kubeletconfig":{"enableServer":true,"staticPodPath":"/etc/kubernetes/manifests","syncFrequency":"1m0s","fileCheckFrequency":"20s","httpCheckFrequency":"20s","address":"0.0.0.0","port":10250,"tlsCipherSuites":["TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256","TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384","TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256","TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256"],"tlsMinVersion":"VersionTLS12","rotateCertificates":true,"serverTLSBootstrap":true,"authentication":{"x509":{"clientCAFile":"/etc/kubernetes/kubelet-ca.crt"},"webhook":{"enabled":true,"cacheTTL":"2m0s"},"anonymous":{"enabled":false}},"authorization":{"mode":"Webhook","webhook":{"cacheAuthorizedTTL":"5m0s","cacheUnauthorizedTTL":"30s"}},"registryPullQPS":5,"registryBurst":10,"eventRecordQPS":0,"eventBurst":10,"enableDebuggingHandlers":true,"healthzPort":10248,"healthzBindAddress":"127.0.0.1","oomScoreAdj":-999,"clusterDomain":"cluster.local","clusterDNS":["172.30.0.10"],"streamingConnectionIdleTimeout":"4h0m0s","nodeStatusUpdateFrequency":"10s","nodeStatusReportFrequency":"5m0s","nodeLeaseDurationSeconds":40,"imageMinimumGCAge":"2m0s","imageGCHighThresholdPercent":85,"imageGCLowThresholdPercent":80,"volumeStatsAggPeriod":"1m0s","systemCgroups":"/system.slice","cgroupRoot":"/","cgroupsPerQOS":true,"cgroupDriver":"systemd","cpuManagerPolicy":"none","cpuManagerReconcilePeriod":"10s","memoryManagerPolicy":"None","topologyManagerPolicy":"none","topologyManagerScope":"container","runtimeRequestTimeout":"2m0s","hairpinMode":"promiscuous-bridge","maxPods":250,"podPidsLimit":4096,"resolvConf":"/etc/resolv.conf","cpuCFSQuota":true,"cpuCFSQuotaPeriod":"100ms","nodeStatusMaxImages":50,"maxOpenFiles":1000000,"contentType":"application/vnd.kubernetes.protobuf","kubeAPIQPS":50,"kubeAPIBurst":100,"serializeImagePulls":false,"evictionPressureTransitionPeriod":"5m0s","enableControllerAttachDetach":true,"makeIPTablesUtilChains":true,"iptablesMasqueradeBit":14,"iptablesDropBit":15,"featureGates":{"APIPriorityAndFairness":true,"CSIMigrationAzureFile":false,"CSIMigrationvSphere":false,"DownwardAPIHugePages":true,"RotateKubeletServerCertificate":true},"failSwapOn":true,"memorySwap":{},"containerLogMaxSize":"50Mi","containerLogMaxFiles":5,"configMapAndSecretChangeDetectionStrategy":"Watch","systemReserved":{"cpu":"500m","ephemeral-storage":"1Gi","memory":"1Gi"},"enforceNodeAllocatable":["pods"],"volumePluginDir":"/etc/kubernetes/kubelet-plugins/volume/exec","providerID":"aws:///us-west-1b/i-0b15fe350572ea633","logging":{"format":"text","flushFrequency":5000000000,"verbosity":2,"options":{"json":{"infoBufferSize":"0"}}},"enableSystemLogHandler":true,"shutdownGracePeriod":"0s","shutdownGracePeriodCriticalPods":"0s","enableProfilingHandler":true,"enableDebugFlagsHandler":true,"seccompDefault":false,"memoryThrottlingFactor":0.8,"registerWithTaints":[{"key":"node-role.kubernetes.io/master","effect":"NoSchedule"}],"registerNode":true,"localStorageCapacityIsolation":true}} EOF diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_available/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_available/rule.yml index 55bdb05a7eac..074b2e0ec3e0 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_available/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_available/rule.yml @@ -70,7 +70,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionSoft['imagefs.available']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_inodesfree/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_inodesfree/rule.yml index 14d1b0c66214..00121d589a8b 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_inodesfree/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_imagefs_inodesfree/rule.yml @@ -69,7 +69,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionSoft['imagefs.inodesFree']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_memory_available/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_memory_available/rule.yml index 2c5430fb0041..6e395590689d 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_memory_available/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_memory_available/rule.yml @@ -69,7 +69,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionSoft['memory.available']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_available/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_available/rule.yml index 3a9a9c8242b8..25d2403f2d96 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_available/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_available/rule.yml @@ -69,7 +69,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionSoft['nodefs.available']" check_existence: "all_exist" xccdf_variable: var_event_record_qps diff --git a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_inodesfree/rule.yml b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_inodesfree/rule.yml index 584d7e4718b1..cf2296112dcd 100644 --- a/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_inodesfree/rule.yml +++ b/applications/openshift/kubelet/kubelet_eviction_thresholds_set_soft_nodefs_inodesfree/rule.yml @@ -69,7 +69,7 @@ ocil: |- template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.evictionSoft['nodefs.inodesFree']" check_existence: "all_exist" values: diff --git a/applications/openshift/kubelet/kubelet_read_only_port_secured/rule.yml b/applications/openshift/kubelet/kubelet_read_only_port_secured/rule.yml index c3d0368204ea..ea55e3f74a9f 100644 --- a/applications/openshift/kubelet/kubelet_read_only_port_secured/rule.yml +++ b/applications/openshift/kubelet/kubelet_read_only_port_secured/rule.yml @@ -35,7 +35,7 @@ references: template: name: yamlfile_value vars: - filepath: '/etc/kubernetes/compliance-operator/kubeletconfig/openscap-kubeletconfig' + filepath: '/var/run/compliance-operator/kubeletconfig/openscap-kubeletconfig' yamlpath: ".kubeletconfig.readOnlyPort" values: - value: "0" diff --git a/applications/openshift/logging/audit_logging_enabled/rule.yml b/applications/openshift/logging/audit_logging_enabled/rule.yml index fd8953bdf13e..3c8e89772c7c 100644 --- a/applications/openshift/logging/audit_logging_enabled/rule.yml +++ b/applications/openshift/logging/audit_logging_enabled/rule.yml @@ -24,7 +24,6 @@ identifiers: cce@ocp4: CCE-90619-8 references: - cis@ocp4: 3.2.1 nerc-cip: CIP-003-8 R4,CIP-003-8 R4.1,CIP-003-8 R4.2,CIP-003-8 R5.2,CIP-003-8 R6,CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-004-6 R3.3,CIP-007-3 R.1.3,CIP-007-3 R5,CIP-007-3 R5.1.1,CIP-007-3 R5.2,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3,CIP-007-3 R6.5 nist: AU-2,AU-3,AU-3(1),AU-6,AU-6(1),AU-7,AU-7(1),AU-8,AU-8(1),AU-9,AU-12,AU-12(1),AU-12(3),CM-5(1),SI-11,SI-12,SI-4(20),SI-4(23) pcidss: Req-2.2,Req-12.5.5 diff --git a/applications/openshift/logging/audit_profile_set/rule.yml b/applications/openshift/logging/audit_profile_set/rule.yml index 7fef7307738e..f78fe7f40a28 100644 --- a/applications/openshift/logging/audit_profile_set/rule.yml +++ b/applications/openshift/logging/audit_profile_set/rule.yml @@ -53,7 +53,6 @@ identifiers: cce@ocp4: CCE-83577-7 references: - cis@ocp4: 3.2.2 nerc-cip: CIP-003-8 R4,CIP-003-8 R4.1,CIP-003-8 R4.2,CIP-003-8 R5.2,CIP-003-8 R6,CIP-004-6 R2.2.2,CIP-004-6 R2.2.3,CIP-004-6 R3.3,CIP-007-3 R.1.3,CIP-007-3 R5,CIP-007-3 R5.1.1,CIP-007-3 R5.2,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3,CIP-007-3 R6.5 nist: AU-2,AU-3,AU-3(1),AU-6,AU-6(1),AU-7,AU-7(1),AU-8,AU-8(1),AU-9,AU-12,AU-12(1),AU-12(3),CM-5(1),SI-11,SI-12,SI-4(20),SI-4(23) pcidss: Req-2.2,Req-12.5.5 diff --git a/applications/openshift/master/file_groupowner_cni_conf/rule.yml b/applications/openshift/master/file_groupowner_cni_conf/rule.yml index a9729f37155e..73a10b170c6a 100644 --- a/applications/openshift/master/file_groupowner_cni_conf/rule.yml +++ b/applications/openshift/master/file_groupowner_cni_conf/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-84025-6 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_controller_manager_kubeconfig/rule.yml b/applications/openshift/master/file_groupowner_controller_manager_kubeconfig/rule.yml index cae73c6f42b5..52b763c6e838 100644 --- a/applications/openshift/master/file_groupowner_controller_manager_kubeconfig/rule.yml +++ b/applications/openshift/master/file_groupowner_controller_manager_kubeconfig/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.18 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_etcd_data_dir/rule.yml b/applications/openshift/master/file_groupowner_etcd_data_dir/rule.yml index 398389d25509..5f0db7e7d2d4 100644 --- a/applications/openshift/master/file_groupowner_etcd_data_dir/rule.yml +++ b/applications/openshift/master/file_groupowner_etcd_data_dir/rule.yml @@ -17,7 +17,6 @@ identifiers: cce@ocp4: CCE-83354-1 references: - cis@ocp4: 1.1.12 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_etcd_data_files/rule.yml b/applications/openshift/master/file_groupowner_etcd_data_files/rule.yml index 4a021650d872..0652f092fedd 100644 --- a/applications/openshift/master/file_groupowner_etcd_data_files/rule.yml +++ b/applications/openshift/master/file_groupowner_etcd_data_files/rule.yml @@ -17,7 +17,6 @@ identifiers: cce@ocp4: CCE-83816-9 references: - cis@ocp4: 1.1.12 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_etcd_member/rule.yml b/applications/openshift/master/file_groupowner_etcd_member/rule.yml index 23990f65419c..2973448f82da 100644 --- a/applications/openshift/master/file_groupowner_etcd_member/rule.yml +++ b/applications/openshift/master/file_groupowner_etcd_member/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-83664-3 references: - cis@ocp4: 1.1.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_etcd_pki_cert_files/rule.yml b/applications/openshift/master/file_groupowner_etcd_pki_cert_files/rule.yml index d197191e6817..057d667c802a 100644 --- a/applications/openshift/master/file_groupowner_etcd_pki_cert_files/rule.yml +++ b/applications/openshift/master/file_groupowner_etcd_pki_cert_files/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ip_allocations/rule.yml b/applications/openshift/master/file_groupowner_ip_allocations/rule.yml index 7b22db0ddb37..2887b2911a37 100644 --- a/applications/openshift/master/file_groupowner_ip_allocations/rule.yml +++ b/applications/openshift/master/file_groupowner_ip_allocations/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-84211-2 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_kube_apiserver/rule.yml b/applications/openshift/master/file_groupowner_kube_apiserver/rule.yml index 38c2c51e2cff..ea413441a1c5 100644 --- a/applications/openshift/master/file_groupowner_kube_apiserver/rule.yml +++ b/applications/openshift/master/file_groupowner_kube_apiserver/rule.yml @@ -16,7 +16,6 @@ identifiers: cce@ocp4: CCE-83530-6 references: - cis@ocp4: 1.1.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_kube_controller_manager/rule.yml b/applications/openshift/master/file_groupowner_kube_controller_manager/rule.yml index 91ab27869a66..03fc4ce75712 100644 --- a/applications/openshift/master/file_groupowner_kube_controller_manager/rule.yml +++ b/applications/openshift/master/file_groupowner_kube_controller_manager/rule.yml @@ -16,7 +16,6 @@ identifiers: cce@ocp4: CCE-83953-0 references: - cis@ocp4: 1.1.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_kube_scheduler/rule.yml b/applications/openshift/master/file_groupowner_kube_scheduler/rule.yml index 9721bde67f3c..808b63dcd82a 100644 --- a/applications/openshift/master/file_groupowner_kube_scheduler/rule.yml +++ b/applications/openshift/master/file_groupowner_kube_scheduler/rule.yml @@ -16,7 +16,6 @@ identifiers: cce@ocp4: CCE-83614-8 references: - cis@ocp4: 1.1.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_kubeconfig/rule.yml b/applications/openshift/master/file_groupowner_kubeconfig/rule.yml index f400291bccb4..2a461dce6bfa 100644 --- a/applications/openshift/master/file_groupowner_kubeconfig/rule.yml +++ b/applications/openshift/master/file_groupowner_kubeconfig/rule.yml @@ -15,9 +15,6 @@ severity: medium #identifiers: # cce@ocp4: 80633-1 -references: - cis@ocp4: 1.1.14 - ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/kubernetes/kubeconfig", group="root") }}}' ocil: |- diff --git a/applications/openshift/master/file_groupowner_master_admin_kubeconfigs/rule.yml b/applications/openshift/master/file_groupowner_master_admin_kubeconfigs/rule.yml index 3dcbe26da97a..53f062fe3fa7 100644 --- a/applications/openshift/master/file_groupowner_master_admin_kubeconfigs/rule.yml +++ b/applications/openshift/master/file_groupowner_master_admin_kubeconfigs/rule.yml @@ -22,7 +22,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.14 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_multus_conf/rule.yml b/applications/openshift/master/file_groupowner_multus_conf/rule.yml index 33786dcfc00f..f8b6671822ae 100644 --- a/applications/openshift/master/file_groupowner_multus_conf/rule.yml +++ b/applications/openshift/master/file_groupowner_multus_conf/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-83818-5 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_openshift_pki_cert_files/rule.yml b/applications/openshift/master/file_groupowner_openshift_pki_cert_files/rule.yml index 04be94b0c83d..4e6435ff6118 100644 --- a/applications/openshift/master/file_groupowner_openshift_pki_cert_files/rule.yml +++ b/applications/openshift/master/file_groupowner_openshift_pki_cert_files/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_openshift_pki_key_files/rule.yml b/applications/openshift/master/file_groupowner_openshift_pki_key_files/rule.yml index f43e58607454..004e2d4295aa 100644 --- a/applications/openshift/master/file_groupowner_openshift_pki_key_files/rule.yml +++ b/applications/openshift/master/file_groupowner_openshift_pki_key_files/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_openshift_sdn_cniserver_config/rule.yml b/applications/openshift/master/file_groupowner_openshift_sdn_cniserver_config/rule.yml index f4e70e86c1d4..6d739b70b74b 100644 --- a/applications/openshift/master/file_groupowner_openshift_sdn_cniserver_config/rule.yml +++ b/applications/openshift/master/file_groupowner_openshift_sdn_cniserver_config/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83605-6 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_openvswitch/rule.yml b/applications/openshift/master/file_groupowner_openvswitch/rule.yml index da78ea51076c..e577ba04025d 100644 --- a/applications/openshift/master/file_groupowner_openvswitch/rule.yml +++ b/applications/openshift/master/file_groupowner_openvswitch/rule.yml @@ -16,9 +16,6 @@ severity: medium #identifiers: # cce@ocp4: 82172-8 -references: - cis@ocp4: 1.1.10 - ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/openvswitch/.*", group="root") }}}' ocil: |- diff --git a/applications/openshift/master/file_groupowner_ovn_cni_server_sock/rule.yml b/applications/openshift/master/file_groupowner_ovn_cni_server_sock/rule.yml index e7a63d9b1b1e..327a293db2a8 100644 --- a/applications/openshift/master/file_groupowner_ovn_cni_server_sock/rule.yml +++ b/applications/openshift/master/file_groupowner_ovn_cni_server_sock/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-86222-7 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovn_db_files/rule.yml b/applications/openshift/master/file_groupowner_ovn_db_files/rule.yml index c82d6da59baf..9b78cbd34fd2 100644 --- a/applications/openshift/master/file_groupowner_ovn_db_files/rule.yml +++ b/applications/openshift/master/file_groupowner_ovn_db_files/rule.yml @@ -20,7 +20,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_conf_db_hugetlbfs/rule.yml b/applications/openshift/master/file_groupowner_ovs_conf_db_hugetlbfs/rule.yml index f4a18bb358d9..c8ea04b83f12 100644 --- a/applications/openshift/master/file_groupowner_ovs_conf_db_hugetlbfs/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_conf_db_hugetlbfs/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-88281-1 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_conf_db_lock_hugetlbfs/rule.yml b/applications/openshift/master/file_groupowner_ovs_conf_db_lock_hugetlbfs/rule.yml index 1deb2678b0f7..1dca8fa385e4 100644 --- a/applications/openshift/master/file_groupowner_ovs_conf_db_lock_hugetlbfs/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_conf_db_lock_hugetlbfs/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-85936-3 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_conf_db_lock_openvswitch/rule.yml b/applications/openshift/master/file_groupowner_ovs_conf_db_lock_openvswitch/rule.yml index 1110b896ed95..0a7b70f92e9d 100644 --- a/applications/openshift/master/file_groupowner_ovs_conf_db_lock_openvswitch/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_conf_db_lock_openvswitch/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-87632-6 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_conf_db_openvswitch/rule.yml b/applications/openshift/master/file_groupowner_ovs_conf_db_openvswitch/rule.yml index f750aa580d8c..d8b0c0da3ddb 100644 --- a/applications/openshift/master/file_groupowner_ovs_conf_db_openvswitch/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_conf_db_openvswitch/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-85927-2 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_pid/rule.yml b/applications/openshift/master/file_groupowner_ovs_pid/rule.yml index ea9e8e2f53e9..541b62b7124b 100644 --- a/applications/openshift/master/file_groupowner_ovs_pid/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_pid/rule.yml @@ -22,7 +22,6 @@ identifiers: cce@ocp4: CCE-83630-4 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_sys_id_conf_hugetlbfs/rule.yml b/applications/openshift/master/file_groupowner_ovs_sys_id_conf_hugetlbfs/rule.yml index 465928ed68a0..a5bffc83eacf 100644 --- a/applications/openshift/master/file_groupowner_ovs_sys_id_conf_hugetlbfs/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_sys_id_conf_hugetlbfs/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-85928-0 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_sys_id_conf_openvswitch/rule.yml b/applications/openshift/master/file_groupowner_ovs_sys_id_conf_openvswitch/rule.yml index 644435a7cb98..40312f6ce2e2 100644 --- a/applications/openshift/master/file_groupowner_ovs_sys_id_conf_openvswitch/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_sys_id_conf_openvswitch/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83677-5 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovs_vswitchd_pid/rule.yml b/applications/openshift/master/file_groupowner_ovs_vswitchd_pid/rule.yml index e4058048e9ea..6c6a0bd22958 100644 --- a/applications/openshift/master/file_groupowner_ovs_vswitchd_pid/rule.yml +++ b/applications/openshift/master/file_groupowner_ovs_vswitchd_pid/rule.yml @@ -22,7 +22,6 @@ identifiers: cce@ocp4: CCE-84129-6 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_ovsdb_server_pid/rule.yml b/applications/openshift/master/file_groupowner_ovsdb_server_pid/rule.yml index 050e2e7e378b..155dba270520 100644 --- a/applications/openshift/master/file_groupowner_ovsdb_server_pid/rule.yml +++ b/applications/openshift/master/file_groupowner_ovsdb_server_pid/rule.yml @@ -22,7 +22,6 @@ identifiers: cce@ocp4: CCE-84166-8 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_groupowner_scheduler_kubeconfig/rule.yml b/applications/openshift/master/file_groupowner_scheduler_kubeconfig/rule.yml index 412909773569..b28c3d6d1fb2 100644 --- a/applications/openshift/master/file_groupowner_scheduler_kubeconfig/rule.yml +++ b/applications/openshift/master/file_groupowner_scheduler_kubeconfig/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.16 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_cni_conf/rule.yml b/applications/openshift/master/file_owner_cni_conf/rule.yml index 7b141e2c07af..1bc9056102d3 100644 --- a/applications/openshift/master/file_owner_cni_conf/rule.yml +++ b/applications/openshift/master/file_owner_cni_conf/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-83460-6 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_controller_manager_kubeconfig/rule.yml b/applications/openshift/master/file_owner_controller_manager_kubeconfig/rule.yml index 02821ef35251..b61771608e87 100644 --- a/applications/openshift/master/file_owner_controller_manager_kubeconfig/rule.yml +++ b/applications/openshift/master/file_owner_controller_manager_kubeconfig/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.18 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_etcd_data_dir/rule.yml b/applications/openshift/master/file_owner_etcd_data_dir/rule.yml index 157151692886..d87b2d99336d 100644 --- a/applications/openshift/master/file_owner_etcd_data_dir/rule.yml +++ b/applications/openshift/master/file_owner_etcd_data_dir/rule.yml @@ -17,7 +17,6 @@ identifiers: cce@ocp4: CCE-83905-0 references: - cis@ocp4: 1.1.12 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_etcd_data_files/rule.yml b/applications/openshift/master/file_owner_etcd_data_files/rule.yml index 3500e567866b..c92ef469f3e7 100644 --- a/applications/openshift/master/file_owner_etcd_data_files/rule.yml +++ b/applications/openshift/master/file_owner_etcd_data_files/rule.yml @@ -17,7 +17,6 @@ identifiers: cce@ocp4: CCE-84010-8 references: - cis@ocp4: 1.1.12 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_etcd_member/rule.yml b/applications/openshift/master/file_owner_etcd_member/rule.yml index f7fd30b41117..4ba8fb25c380 100644 --- a/applications/openshift/master/file_owner_etcd_member/rule.yml +++ b/applications/openshift/master/file_owner_etcd_member/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-83988-6 references: - cis@ocp4: 1.1.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_etcd_pki_cert_files/rule.yml b/applications/openshift/master/file_owner_etcd_pki_cert_files/rule.yml index b22f0f8f5b3d..1f5bacd76311 100644 --- a/applications/openshift/master/file_owner_etcd_pki_cert_files/rule.yml +++ b/applications/openshift/master/file_owner_etcd_pki_cert_files/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ip_allocations/rule.yml b/applications/openshift/master/file_owner_ip_allocations/rule.yml index 74bec92f2373..178dbdd115a4 100644 --- a/applications/openshift/master/file_owner_ip_allocations/rule.yml +++ b/applications/openshift/master/file_owner_ip_allocations/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-84248-4 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_kube_apiserver/rule.yml b/applications/openshift/master/file_owner_kube_apiserver/rule.yml index 787a721ec7b8..6d9aae39ef2e 100644 --- a/applications/openshift/master/file_owner_kube_apiserver/rule.yml +++ b/applications/openshift/master/file_owner_kube_apiserver/rule.yml @@ -16,7 +16,6 @@ identifiers: cce@ocp4: CCE-83372-3 references: - cis@ocp4: 1.1.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_kube_controller_manager/rule.yml b/applications/openshift/master/file_owner_kube_controller_manager/rule.yml index 6d0b7ebf1b22..0b0da88bb78c 100644 --- a/applications/openshift/master/file_owner_kube_controller_manager/rule.yml +++ b/applications/openshift/master/file_owner_kube_controller_manager/rule.yml @@ -16,7 +16,6 @@ identifiers: cce@ocp4: CCE-83795-5 references: - cis@ocp4: 1.1.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_kube_scheduler/rule.yml b/applications/openshift/master/file_owner_kube_scheduler/rule.yml index b50d67488fb7..90fa29a6d0e4 100644 --- a/applications/openshift/master/file_owner_kube_scheduler/rule.yml +++ b/applications/openshift/master/file_owner_kube_scheduler/rule.yml @@ -16,7 +16,6 @@ identifiers: cce@ocp4: CCE-83393-9 references: - cis@ocp4: 1.1.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_kubeconfig/rule.yml b/applications/openshift/master/file_owner_kubeconfig/rule.yml index 52124d916048..6db348d3e8f0 100644 --- a/applications/openshift/master/file_owner_kubeconfig/rule.yml +++ b/applications/openshift/master/file_owner_kubeconfig/rule.yml @@ -15,9 +15,6 @@ severity: medium #identifiers: # cce@ocp4: 80633-1 -references: - cis@ocp4: 1.1.14 - ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/kubernetes/kubeconfig", owner="root") }}}' ocil: |- diff --git a/applications/openshift/master/file_owner_master_admin_kubeconfigs/rule.yml b/applications/openshift/master/file_owner_master_admin_kubeconfigs/rule.yml index d56b99f7b89e..1f0147b30fba 100644 --- a/applications/openshift/master/file_owner_master_admin_kubeconfigs/rule.yml +++ b/applications/openshift/master/file_owner_master_admin_kubeconfigs/rule.yml @@ -22,7 +22,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.14 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_multus_conf/rule.yml b/applications/openshift/master/file_owner_multus_conf/rule.yml index 5bfd65e206e5..f52230ef8c8b 100644 --- a/applications/openshift/master/file_owner_multus_conf/rule.yml +++ b/applications/openshift/master/file_owner_multus_conf/rule.yml @@ -19,7 +19,6 @@ identifiers: cce@ocp4: CCE-83603-1 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_openshift_pki_cert_files/rule.yml b/applications/openshift/master/file_owner_openshift_pki_cert_files/rule.yml index 457d69cd5b08..50808bbc946d 100644 --- a/applications/openshift/master/file_owner_openshift_pki_cert_files/rule.yml +++ b/applications/openshift/master/file_owner_openshift_pki_cert_files/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_openshift_pki_key_files/rule.yml b/applications/openshift/master/file_owner_openshift_pki_key_files/rule.yml index 7976d8242bb3..6a13ec144795 100644 --- a/applications/openshift/master/file_owner_openshift_pki_key_files/rule.yml +++ b/applications/openshift/master/file_owner_openshift_pki_key_files/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.19 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_openshift_sdn_cniserver_config/rule.yml b/applications/openshift/master/file_owner_openshift_sdn_cniserver_config/rule.yml index 9bf76ca6ad95..bcc26c2cf38a 100644 --- a/applications/openshift/master/file_owner_openshift_sdn_cniserver_config/rule.yml +++ b/applications/openshift/master/file_owner_openshift_sdn_cniserver_config/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83932-4 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_openvswitch/rule.yml b/applications/openshift/master/file_owner_openvswitch/rule.yml index da6245cf82e8..fcd1915a1e26 100644 --- a/applications/openshift/master/file_owner_openvswitch/rule.yml +++ b/applications/openshift/master/file_owner_openvswitch/rule.yml @@ -16,9 +16,6 @@ severity: medium #identifiers: # cce@ocp4: 82172-8 -references: - cis@ocp4: 1.1.10 - ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/openvswitch/.*", owner="root") }}}' ocil: |- diff --git a/applications/openshift/master/file_owner_ovn_cni_server_sock/rule.yml b/applications/openshift/master/file_owner_ovn_cni_server_sock/rule.yml index 7ccc7d4d5957..eb665df11c94 100644 --- a/applications/openshift/master/file_owner_ovn_cni_server_sock/rule.yml +++ b/applications/openshift/master/file_owner_ovn_cni_server_sock/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-86431-4 references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovn_db_files/rule.yml b/applications/openshift/master/file_owner_ovn_db_files/rule.yml index ab06bde7bd50..651a32c189ed 100644 --- a/applications/openshift/master/file_owner_ovn_db_files/rule.yml +++ b/applications/openshift/master/file_owner_ovn_db_files/rule.yml @@ -20,7 +20,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovs_conf_db/rule.yml b/applications/openshift/master/file_owner_ovs_conf_db/rule.yml index 9d217a9d5fde..8cc76e375dde 100644 --- a/applications/openshift/master/file_owner_ovs_conf_db/rule.yml +++ b/applications/openshift/master/file_owner_ovs_conf_db/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83489-5 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovs_conf_db_lock/rule.yml b/applications/openshift/master/file_owner_ovs_conf_db_lock/rule.yml index 3cdf3b325e81..39903a0bacea 100644 --- a/applications/openshift/master/file_owner_ovs_conf_db_lock/rule.yml +++ b/applications/openshift/master/file_owner_ovs_conf_db_lock/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83462-2 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovs_pid/rule.yml b/applications/openshift/master/file_owner_ovs_pid/rule.yml index fbee013776b4..dafed6103d1c 100644 --- a/applications/openshift/master/file_owner_ovs_pid/rule.yml +++ b/applications/openshift/master/file_owner_ovs_pid/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83937-3 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovs_sys_id_conf/rule.yml b/applications/openshift/master/file_owner_ovs_sys_id_conf/rule.yml index 6dd76a381a3f..8826cd26a2a2 100644 --- a/applications/openshift/master/file_owner_ovs_sys_id_conf/rule.yml +++ b/applications/openshift/master/file_owner_ovs_sys_id_conf/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-84085-0 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovs_vswitchd_pid/rule.yml b/applications/openshift/master/file_owner_ovs_vswitchd_pid/rule.yml index 207499e5c8c2..3b882658b5c9 100644 --- a/applications/openshift/master/file_owner_ovs_vswitchd_pid/rule.yml +++ b/applications/openshift/master/file_owner_ovs_vswitchd_pid/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83888-8 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_ovsdb_server_pid/rule.yml b/applications/openshift/master/file_owner_ovsdb_server_pid/rule.yml index 1ab840c1c84d..cfb4daef9194 100644 --- a/applications/openshift/master/file_owner_ovsdb_server_pid/rule.yml +++ b/applications/openshift/master/file_owner_ovsdb_server_pid/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83806-0 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_scheduler_kubeconfig/rule.yml b/applications/openshift/master/file_owner_scheduler_kubeconfig/rule.yml index 7cf962065918..1401d34f501a 100644 --- a/applications/openshift/master/file_owner_scheduler_kubeconfig/rule.yml +++ b/applications/openshift/master/file_owner_scheduler_kubeconfig/rule.yml @@ -17,7 +17,6 @@ identifiers: cce@ocp4: CCE-84017-3 references: - cis@ocp4: 1.1.16 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_owner_var_lib_etcd/rule.yml b/applications/openshift/master/file_owner_var_lib_etcd/rule.yml index a911c3bc4015..88cbfda5fee0 100644 --- a/applications/openshift/master/file_owner_var_lib_etcd/rule.yml +++ b/applications/openshift/master/file_owner_var_lib_etcd/rule.yml @@ -12,9 +12,6 @@ rationale: |- severity: medium -references: - cis@ocp4: 1.1.12 - ocil_clause: '{{{ ocil_clause_file_owner(file="/var/lib/etcd", owner="root") }}}' ocil: |- diff --git a/applications/openshift/master/file_permissions_cni_conf/rule.yml b/applications/openshift/master/file_permissions_cni_conf/rule.yml index ac3d1b5a7772..801a8286b1d1 100644 --- a/applications/openshift/master/file_permissions_cni_conf/rule.yml +++ b/applications/openshift/master/file_permissions_cni_conf/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83379-8 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_cni_conf_not_s390x/rule.yml b/applications/openshift/master/file_permissions_cni_conf_not_s390x/rule.yml index 1af6cb886b2c..05f6c432e230 100644 --- a/applications/openshift/master/file_permissions_cni_conf_not_s390x/rule.yml +++ b/applications/openshift/master/file_permissions_cni_conf_not_s390x/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-86593-1 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_cni_conf_s390x/rule.yml b/applications/openshift/master/file_permissions_cni_conf_s390x/rule.yml index 7d6bff12e90c..d864b506e550 100644 --- a/applications/openshift/master/file_permissions_cni_conf_s390x/rule.yml +++ b/applications/openshift/master/file_permissions_cni_conf_s390x/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-86597-2 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_controller_manager_kubeconfig/rule.yml b/applications/openshift/master/file_permissions_controller_manager_kubeconfig/rule.yml index e91d35860093..a501ff2d8b47 100644 --- a/applications/openshift/master/file_permissions_controller_manager_kubeconfig/rule.yml +++ b/applications/openshift/master/file_permissions_controller_manager_kubeconfig/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.17 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_etcd_data_dir/rule.yml b/applications/openshift/master/file_permissions_etcd_data_dir/rule.yml index 0c531830189a..bdd17195a78e 100644 --- a/applications/openshift/master/file_permissions_etcd_data_dir/rule.yml +++ b/applications/openshift/master/file_permissions_etcd_data_dir/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-84013-2 references: - cis@ocp4: 1.1.11 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_etcd_data_files/rule.yml b/applications/openshift/master/file_permissions_etcd_data_files/rule.yml index e1846652801b..552150f52fab 100644 --- a/applications/openshift/master/file_permissions_etcd_data_files/rule.yml +++ b/applications/openshift/master/file_permissions_etcd_data_files/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-83382-2 references: - cis@ocp4: 1.1.11 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_etcd_member/rule.yml b/applications/openshift/master/file_permissions_etcd_member/rule.yml index 2e52684f6953..731e0412af67 100644 --- a/applications/openshift/master/file_permissions_etcd_member/rule.yml +++ b/applications/openshift/master/file_permissions_etcd_member/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83973-8 references: - cis@ocp4: 1.1.7 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_etcd_pki_cert_files/rule.yml b/applications/openshift/master/file_permissions_etcd_pki_cert_files/rule.yml index 5fb4e0cd45d4..a7ba2a63db38 100644 --- a/applications/openshift/master/file_permissions_etcd_pki_cert_files/rule.yml +++ b/applications/openshift/master/file_permissions_etcd_pki_cert_files/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.20 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ip_allocations/rule.yml b/applications/openshift/master/file_permissions_ip_allocations/rule.yml index f1cdf9262096..264d54ca82fc 100644 --- a/applications/openshift/master/file_permissions_ip_allocations/rule.yml +++ b/applications/openshift/master/file_permissions_ip_allocations/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83469-7 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_kube_apiserver/rule.yml b/applications/openshift/master/file_permissions_kube_apiserver/rule.yml index 7fbb1106be6d..b104b15c068a 100644 --- a/applications/openshift/master/file_permissions_kube_apiserver/rule.yml +++ b/applications/openshift/master/file_permissions_kube_apiserver/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-83983-7 references: - cis@ocp4: 1.1.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_kube_controller_manager/rule.yml b/applications/openshift/master/file_permissions_kube_controller_manager/rule.yml index 41a820de5a0a..ad993adad345 100644 --- a/applications/openshift/master/file_permissions_kube_controller_manager/rule.yml +++ b/applications/openshift/master/file_permissions_kube_controller_manager/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-84161-9 references: - cis@ocp4: 1.1.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_kube_scheduler/rule.yml b/applications/openshift/master/file_permissions_kube_scheduler/rule.yml index 4d62bd1c91f4..a8497cc6ca70 100644 --- a/applications/openshift/master/file_permissions_kube_scheduler/rule.yml +++ b/applications/openshift/master/file_permissions_kube_scheduler/rule.yml @@ -17,9 +17,6 @@ severity: medium #identifiers: # cce@ocp4: -references: - cis@ocp4: 1.1.5 - ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/kubernetes/static-pod-resources/kube-scheduler-pod.yaml", perms="-rw-------") }}}' ocil: |- diff --git a/applications/openshift/master/file_permissions_kubeconfig/rule.yml b/applications/openshift/master/file_permissions_kubeconfig/rule.yml index 1f30b003a67e..c2ce8a5a1eb4 100644 --- a/applications/openshift/master/file_permissions_kubeconfig/rule.yml +++ b/applications/openshift/master/file_permissions_kubeconfig/rule.yml @@ -17,9 +17,6 @@ severity: medium #identifiers: # cce@ocp4: 80633-1 -references: - cis@ocp4: 1.1.13 - ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/kubernetes/kubeconfig", perms="-rw-------") }}}' ocil: |- diff --git a/applications/openshift/master/file_permissions_master_admin_kubeconfigs/rule.yml b/applications/openshift/master/file_permissions_master_admin_kubeconfigs/rule.yml index bab65483191c..b86181ddd6cf 100644 --- a/applications/openshift/master/file_permissions_master_admin_kubeconfigs/rule.yml +++ b/applications/openshift/master/file_permissions_master_admin_kubeconfigs/rule.yml @@ -22,7 +22,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.13 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_multus_conf/rule.yml b/applications/openshift/master/file_permissions_multus_conf/rule.yml index 160940f90a39..6b6a64085d67 100644 --- a/applications/openshift/master/file_permissions_multus_conf/rule.yml +++ b/applications/openshift/master/file_permissions_multus_conf/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83467-1 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_openshift_pki_cert_files/rule.yml b/applications/openshift/master/file_permissions_openshift_pki_cert_files/rule.yml index f3cb2410f276..2086eda6b18f 100644 --- a/applications/openshift/master/file_permissions_openshift_pki_cert_files/rule.yml +++ b/applications/openshift/master/file_permissions_openshift_pki_cert_files/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.20 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_openshift_pki_key_files/rule.yml b/applications/openshift/master/file_permissions_openshift_pki_key_files/rule.yml index 0f117f80017d..b819b3eebeb0 100644 --- a/applications/openshift/master/file_permissions_openshift_pki_key_files/rule.yml +++ b/applications/openshift/master/file_permissions_openshift_pki_key_files/rule.yml @@ -18,7 +18,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.21 nerc-cip: CIP-003-8 R1.3,CIP-003-8 R3,CIP-003-8 R3.1,CIP-003-8 R3.2,CIP-003-8 R3.3,CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.2.3,CIP-004-6 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.2,CIP-007-3 R5.2,CIP-007-3 R5.3.1,CIP-007-3 R5.3.2,CIP-007-3 R5.3.3 nist: CM-6,CM-6(1),IA-5(2) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_openvswitch/rule.yml b/applications/openshift/master/file_permissions_openvswitch/rule.yml index 876fc240fdc6..0842c7b7f31c 100644 --- a/applications/openshift/master/file_permissions_openvswitch/rule.yml +++ b/applications/openshift/master/file_permissions_openvswitch/rule.yml @@ -17,9 +17,6 @@ severity: medium #identifiers: # cce@ocp4: 82173-6 -references: - cis@ocp4: 1.4.9 - ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/openvswitch/.*", perms="-rw-r--r--") }}}' ocil: |- diff --git a/applications/openshift/master/file_permissions_ovn_cni_server_sock/rule.yml b/applications/openshift/master/file_permissions_ovn_cni_server_sock/rule.yml index 02d1227f0c42..e440b9f846a5 100644 --- a/applications/openshift/master/file_permissions_ovn_cni_server_sock/rule.yml +++ b/applications/openshift/master/file_permissions_ovn_cni_server_sock/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-86069-2 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovn_db_files/rule.yml b/applications/openshift/master/file_permissions_ovn_db_files/rule.yml index 534b305b189a..510dc77e7b38 100644 --- a/applications/openshift/master/file_permissions_ovn_db_files/rule.yml +++ b/applications/openshift/master/file_permissions_ovn_db_files/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-86653-3 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovs_conf_db/rule.yml b/applications/openshift/master/file_permissions_ovs_conf_db/rule.yml index d8720f7aa6ff..bdf56487424d 100644 --- a/applications/openshift/master/file_permissions_ovs_conf_db/rule.yml +++ b/applications/openshift/master/file_permissions_ovs_conf_db/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83788-0 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovs_conf_db_lock/rule.yml b/applications/openshift/master/file_permissions_ovs_conf_db_lock/rule.yml index c4e4b913719f..fea3fceb9c55 100644 --- a/applications/openshift/master/file_permissions_ovs_conf_db_lock/rule.yml +++ b/applications/openshift/master/file_permissions_ovs_conf_db_lock/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-84202-1 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovs_pid/rule.yml b/applications/openshift/master/file_permissions_ovs_pid/rule.yml index 85eb3735c7d8..662bff60e4f1 100644 --- a/applications/openshift/master/file_permissions_ovs_pid/rule.yml +++ b/applications/openshift/master/file_permissions_ovs_pid/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83666-8 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovs_sys_id_conf/rule.yml b/applications/openshift/master/file_permissions_ovs_sys_id_conf/rule.yml index d0fee0d3e9bd..a153a8b56640 100644 --- a/applications/openshift/master/file_permissions_ovs_sys_id_conf/rule.yml +++ b/applications/openshift/master/file_permissions_ovs_sys_id_conf/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83400-2 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovs_vswitchd_pid/rule.yml b/applications/openshift/master/file_permissions_ovs_vswitchd_pid/rule.yml index ec86248676fa..1d1238ffdfb3 100644 --- a/applications/openshift/master/file_permissions_ovs_vswitchd_pid/rule.yml +++ b/applications/openshift/master/file_permissions_ovs_vswitchd_pid/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83710-4 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_ovsdb_server_pid/rule.yml b/applications/openshift/master/file_permissions_ovsdb_server_pid/rule.yml index 9e31f05b1244..1a7510b15ce1 100644 --- a/applications/openshift/master/file_permissions_ovsdb_server_pid/rule.yml +++ b/applications/openshift/master/file_permissions_ovsdb_server_pid/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83679-1 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_scheduler/rule.yml b/applications/openshift/master/file_permissions_scheduler/rule.yml index 3d809e94625a..cc1916acecef 100644 --- a/applications/openshift/master/file_permissions_scheduler/rule.yml +++ b/applications/openshift/master/file_permissions_scheduler/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-84057-9 references: - cis@ocp4: 1.1.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_scheduler_kubeconfig/rule.yml b/applications/openshift/master/file_permissions_scheduler_kubeconfig/rule.yml index 042b23a02ac6..937565e10364 100644 --- a/applications/openshift/master/file_permissions_scheduler_kubeconfig/rule.yml +++ b/applications/openshift/master/file_permissions_scheduler_kubeconfig/rule.yml @@ -19,7 +19,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.1.15 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/master/file_permissions_var_lib_etcd/rule.yml b/applications/openshift/master/file_permissions_var_lib_etcd/rule.yml index 80c71bde4b0b..81742ad3cae4 100644 --- a/applications/openshift/master/file_permissions_var_lib_etcd/rule.yml +++ b/applications/openshift/master/file_permissions_var_lib_etcd/rule.yml @@ -13,9 +13,6 @@ rationale: |- severity: medium -references: - cis@ocp4: 1.1.11 - ocil_clause: '{{{ ocil_clause_file_permissions(file="/var/lib/etcd", perms="-rwx------") }}}' ocil: |- diff --git a/applications/openshift/master/file_perms_openshift_sdn_cniserver_config/rule.yml b/applications/openshift/master/file_perms_openshift_sdn_cniserver_config/rule.yml index 1169e0f85978..c1172a95a5e9 100644 --- a/applications/openshift/master/file_perms_openshift_sdn_cniserver_config/rule.yml +++ b/applications/openshift/master/file_perms_openshift_sdn_cniserver_config/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83927-4 references: - cis@ocp4: 1.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/networking/configure_network_policies/rule.yml b/applications/openshift/networking/configure_network_policies/rule.yml index e30efa56270b..fc5cd674a1a0 100644 --- a/applications/openshift/networking/configure_network_policies/rule.yml +++ b/applications/openshift/networking/configure_network_policies/rule.yml @@ -17,7 +17,6 @@ rationale: |- severity: high references: - cis@ocp4: 5.3.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-1.1.4,Req-1.2,Req-2.2 @@ -50,6 +49,5 @@ template: yamlpath: "[:]" check_existence: "any_exist" entity_check: "all" - values: - - value: "OpenShiftSDN|OVN|Calico" - operation: "pattern match" + regex_data: "true" + xccdf_variable: var_configure_network_policies_regex diff --git a/applications/openshift/networking/configure_network_policies_hypershift_hosted/rule.yml b/applications/openshift/networking/configure_network_policies_hypershift_hosted/rule.yml index 57fecae5e9d4..cad4d44214ba 100644 --- a/applications/openshift/networking/configure_network_policies_hypershift_hosted/rule.yml +++ b/applications/openshift/networking/configure_network_policies_hypershift_hosted/rule.yml @@ -25,7 +25,6 @@ identifiers: cce@ocp4: CCE-86104-7 references: - cis@ocp4: 5.3.2 pcidss: Req-1.1.4,Req-1.2,Req-1.2.1,Req-1.3.1,Req-1.3.2,Req-2.2 platform: ocp4-on-hypershift diff --git a/applications/openshift/networking/configure_network_policies_namespaces/rule.yml b/applications/openshift/networking/configure_network_policies_namespaces/rule.yml index 3804944cae51..02cff9280258 100644 --- a/applications/openshift/networking/configure_network_policies_namespaces/rule.yml +++ b/applications/openshift/networking/configure_network_policies_namespaces/rule.yml @@ -18,7 +18,6 @@ severity: high references: cis@eks: 4.3.2 - cis@ocp4: 5.3.2 nerc-cip: CIP-003-8 R4,CIP-003-8 R4.2,CIP-003-8 R5,CIP-003-8 R6,CIP-004-6 R2.2.4,CIP-004-6 R3,CIP-007-3 R2,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: AC-4,AC-4(21),CA-3(5),CM-6,CM-6(1),CM-7,CM-7(1),SC-7,SC-7(3),SC-7(5),SC-7(8),SC-7(12),SC-7(13),SC-7(18),SC-7(10),SI-4(22) pcidss: Req-1.1.4,Req-1.2,Req-1.2.1,Req-1.3.1,Req-1.3.2,Req-2.2 diff --git a/applications/openshift/networking/ingress_controller_tls_cipher_suites/rule.yml b/applications/openshift/networking/ingress_controller_tls_cipher_suites/rule.yml index 5e74b1740d69..752021380a8b 100644 --- a/applications/openshift/networking/ingress_controller_tls_cipher_suites/rule.yml +++ b/applications/openshift/networking/ingress_controller_tls_cipher_suites/rule.yml @@ -17,9 +17,6 @@ severity: medium #identifiers: # cce@ocp4: -references: - cis@ocp4: 4.2.12 - ocil_clause: "Ingress controller TLS cipher suite configuration is incomplete or possibly insecure" ocil: |- diff --git a/applications/openshift/networking/var_configure_network_policies_regex.var b/applications/openshift/networking/var_configure_network_policies_regex.var new file mode 100644 index 000000000000..d899bd0c4527 --- /dev/null +++ b/applications/openshift/networking/var_configure_network_policies_regex.var @@ -0,0 +1,20 @@ +documentation_complete: true + +title: 'Network Provider which provide Support for Network Policies' + +description: |- + Regular expression explicitly describing + which CNI plugins provide the cluster with the + network policies feature/capability + You can chose to either allow multiple providers + by adding them like "Provider1|Provider2" or only + allow one, by overwriting the value + +type: string + +operator: equals + +interactive: true + +options: + default: "OpenShiftSDN|OVN|Calico|Cilium" diff --git a/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxbackup/rule.yml b/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxbackup/rule.yml index 62cbb266ed80..bcc20173c0d5 100644 --- a/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxbackup/rule.yml +++ b/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxbackup/rule.yml @@ -37,7 +37,6 @@ identifiers: severity: low references: - cis@ocp4: 1.2.22 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxsize/rule.yml b/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxsize/rule.yml index 14c76cf49079..a2d6b3bdd9d7 100644 --- a/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxsize/rule.yml +++ b/applications/openshift/openshift-api-server/ocp_api_server_audit_log_maxsize/rule.yml @@ -37,7 +37,6 @@ identifiers: severity: medium references: - cis@ocp4: 1.2.23 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/openshift-api-server/openshift_api_server_audit_log_path/rule.yml b/applications/openshift/openshift-api-server/openshift_api_server_audit_log_path/rule.yml index 712ec6f322bb..3777e182a267 100644 --- a/applications/openshift/openshift-api-server/openshift_api_server_audit_log_path/rule.yml +++ b/applications/openshift/openshift-api-server/openshift_api_server_audit_log_path/rule.yml @@ -36,7 +36,6 @@ identifiers: severity: high references: - cis@ocp4: 1.2.20 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/rbac/rbac_debug_role_protects_pprof/rule.yml b/applications/openshift/rbac/rbac_debug_role_protects_pprof/rule.yml index 7da11a730408..07ce91163d31 100644 --- a/applications/openshift/rbac/rbac_debug_role_protects_pprof/rule.yml +++ b/applications/openshift/rbac/rbac_debug_role_protects_pprof/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-84182-5 references: - cis@ocp4: 1.3.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/rbac/rbac_least_privilege/rule.yml b/applications/openshift/rbac/rbac_least_privilege/rule.yml index 277343e6e3b2..6f084e176843 100644 --- a/applications/openshift/rbac/rbac_least_privilege/rule.yml +++ b/applications/openshift/rbac/rbac_least_privilege/rule.yml @@ -26,7 +26,6 @@ identifiers: cce@ocp4: CCE-90678-4 references: - cis@ocp4: 5.2.10 nist: AC-3,CM-5(6),IA-2,IA-2(5),AC-6(10),CM-11(2),CM-5(1),CM-7(5)(b) srg: SRG-APP-000033-CTR-000090,SRG-APP-000033-CTR-000095,SRG-APP-000033-CTR-000100,SRG-APP-000133-CTR-000290,SRG-APP-000133-CTR-000295,SRG-APP-000133-CTR-000300,SRG-APP-000133-CTR-000305,SRG-APP-000133-CTR-000310,SRG-APP-000148-CTR-000350,SRG-APP-000153-CTR-000375,SRG-APP-000340-CTR-000770,SRG-APP-000378-CTR-000880,SRG-APP-000378-CTR-000885,SRG-APP-000378-CTR-000890,SRG-APP-000380-CTR-000900,SRG-APP-000386-CTR-000920 diff --git a/applications/openshift/rbac/rbac_limit_cluster_admin/rule.yml b/applications/openshift/rbac/rbac_limit_cluster_admin/rule.yml index 145870c5560a..f1b6d97461bb 100644 --- a/applications/openshift/rbac/rbac_limit_cluster_admin/rule.yml +++ b/applications/openshift/rbac/rbac_limit_cluster_admin/rule.yml @@ -20,7 +20,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.1.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1),CM-8(3) pcidss: Req-2.2,Req-7.1.2,Req-10.5.1 diff --git a/applications/openshift/rbac/rbac_limit_secrets_access/rule.yml b/applications/openshift/rbac/rbac_limit_secrets_access/rule.yml index 58dedbe4bcec..4070144eb20a 100644 --- a/applications/openshift/rbac/rbac_limit_secrets_access/rule.yml +++ b/applications/openshift/rbac/rbac_limit_secrets_access/rule.yml @@ -21,7 +21,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.1.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/rbac/rbac_pod_creation_access/rule.yml b/applications/openshift/rbac/rbac_pod_creation_access/rule.yml index d30affe28464..525fec1562a1 100644 --- a/applications/openshift/rbac/rbac_pod_creation_access/rule.yml +++ b/applications/openshift/rbac/rbac_pod_creation_access/rule.yml @@ -16,7 +16,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.1.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/rbac/rbac_wildcard_use/rule.yml b/applications/openshift/rbac/rbac_wildcard_use/rule.yml index 9e589e15bce5..1b3473c90f86 100644 --- a/applications/openshift/rbac/rbac_wildcard_use/rule.yml +++ b/applications/openshift/rbac/rbac_wildcard_use/rule.yml @@ -20,7 +20,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.1.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/registry/ocp_allowed_registries/rule.yml b/applications/openshift/registry/ocp_allowed_registries/rule.yml index 3c828ed9d4d1..fd5f5401f629 100644 --- a/applications/openshift/registry/ocp_allowed_registries/rule.yml +++ b/applications/openshift/registry/ocp_allowed_registries/rule.yml @@ -33,7 +33,6 @@ ocil: |- make sure the output is not empty and matches the registries that you wish to allow. references: - cis@ocp4: '5.5.1' nist: CM-5(3),CM-7(2),CM-7(5),CM-11 srg: SRG-APP-000456-CTR-001125 diff --git a/applications/openshift/registry/ocp_allowed_registries_for_import/rule.yml b/applications/openshift/registry/ocp_allowed_registries_for_import/rule.yml index 600f96d8fee9..d0ceb868cd80 100644 --- a/applications/openshift/registry/ocp_allowed_registries_for_import/rule.yml +++ b/applications/openshift/registry/ocp_allowed_registries_for_import/rule.yml @@ -24,7 +24,6 @@ rationale: |- severity: medium references: - cis@ocp4: '5.5.1' nist: CM-5(3),CM-7(2),CM-7(5),CM-11 srg: SRG-APP-000456-CTR-001125 diff --git a/applications/openshift/registry/ocp_insecure_allowed_registries_for_import/rule.yml b/applications/openshift/registry/ocp_insecure_allowed_registries_for_import/rule.yml index cbb7dc2feb38..70137941dabb 100644 --- a/applications/openshift/registry/ocp_insecure_allowed_registries_for_import/rule.yml +++ b/applications/openshift/registry/ocp_insecure_allowed_registries_for_import/rule.yml @@ -30,7 +30,6 @@ identifiers: cce@ocp4: CCE-86235-9 references: - cis@ocp4: '5.5.1' nist: CM-5(3) srg: SRG-APP-000014-CTR-000035 diff --git a/applications/openshift/registry/ocp_insecure_registries/rule.yml b/applications/openshift/registry/ocp_insecure_registries/rule.yml index 955b671d2873..a034fd97277c 100644 --- a/applications/openshift/registry/ocp_insecure_registries/rule.yml +++ b/applications/openshift/registry/ocp_insecure_registries/rule.yml @@ -26,7 +26,6 @@ identifiers: cce@ocp4: CCE-86123-7 references: - cis@ocp4: '5.5.1' nist: CM-5(3) srg: SRG-APP-000014-CTR-000035 diff --git a/applications/openshift/scc/scc_drop_container_capabilities/rule.yml b/applications/openshift/scc/scc_drop_container_capabilities/rule.yml index 7ed4e5dfde89..815a023f2883 100644 --- a/applications/openshift/scc/scc_drop_container_capabilities/rule.yml +++ b/applications/openshift/scc/scc_drop_container_capabilities/rule.yml @@ -20,7 +20,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.2.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_container_allowed_capabilities/rule.yml b/applications/openshift/scc/scc_limit_container_allowed_capabilities/rule.yml index 647e58743cb7..4c7dcd1cfc27 100644 --- a/applications/openshift/scc/scc_limit_container_allowed_capabilities/rule.yml +++ b/applications/openshift/scc/scc_limit_container_allowed_capabilities/rule.yml @@ -50,7 +50,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.2.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_host_dir_volume_plugin/rule.yml b/applications/openshift/scc/scc_limit_host_dir_volume_plugin/rule.yml index a647219e09f5..dde3aa9ca4de 100644 --- a/applications/openshift/scc/scc_limit_host_dir_volume_plugin/rule.yml +++ b/applications/openshift/scc/scc_limit_host_dir_volume_plugin/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-86255-7 references: - cis@ocp4: 5.2.12 nist: AC-6,AC-6(1) srg: SRG-APP-000142-CTR-000330 diff --git a/applications/openshift/scc/scc_limit_ipc_namespace/rule.yml b/applications/openshift/scc/scc_limit_ipc_namespace/rule.yml index 4b4c512716de..d72c51d9bf89 100644 --- a/applications/openshift/scc/scc_limit_ipc_namespace/rule.yml +++ b/applications/openshift/scc/scc_limit_ipc_namespace/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-84042-1 references: - cis@ocp4: 5.2.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_net_raw_capability/rule.yml b/applications/openshift/scc/scc_limit_net_raw_capability/rule.yml index 9404c6e54145..f8021fa1a106 100644 --- a/applications/openshift/scc/scc_limit_net_raw_capability/rule.yml +++ b/applications/openshift/scc/scc_limit_net_raw_capability/rule.yml @@ -19,7 +19,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.2.7 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_network_namespace/rule.yml b/applications/openshift/scc/scc_limit_network_namespace/rule.yml index 91c795a992df..ac2c97207f0e 100644 --- a/applications/openshift/scc/scc_limit_network_namespace/rule.yml +++ b/applications/openshift/scc/scc_limit_network_namespace/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-83492-9 references: - cis@ocp4: 5.2.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_privilege_escalation/rule.yml b/applications/openshift/scc/scc_limit_privilege_escalation/rule.yml index 4d194c37b43b..be1ca4657443 100644 --- a/applications/openshift/scc/scc_limit_privilege_escalation/rule.yml +++ b/applications/openshift/scc/scc_limit_privilege_escalation/rule.yml @@ -22,7 +22,6 @@ identifiers: cce@ocp4: CCE-83447-3 references: - cis@ocp4: 5.2.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_privileged_containers/rule.yml b/applications/openshift/scc/scc_limit_privileged_containers/rule.yml index bd6c5e43072e..a987eb48a841 100644 --- a/applications/openshift/scc/scc_limit_privileged_containers/rule.yml +++ b/applications/openshift/scc/scc_limit_privileged_containers/rule.yml @@ -18,7 +18,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.2.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_process_id_namespace/rule.yml b/applications/openshift/scc/scc_limit_process_id_namespace/rule.yml index 44e38b05edfc..38b00bf9f7f1 100644 --- a/applications/openshift/scc/scc_limit_process_id_namespace/rule.yml +++ b/applications/openshift/scc/scc_limit_process_id_namespace/rule.yml @@ -17,7 +17,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.2.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scc/scc_limit_root_containers/rule.yml b/applications/openshift/scc/scc_limit_root_containers/rule.yml index df5727c4cd29..6569c5998b71 100644 --- a/applications/openshift/scc/scc_limit_root_containers/rule.yml +++ b/applications/openshift/scc/scc_limit_root_containers/rule.yml @@ -25,7 +25,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.2.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/scheduler/scheduler_no_bind_address/rule.yml b/applications/openshift/scheduler/scheduler_no_bind_address/rule.yml index 120d09335f4f..baf56cb218ca 100644 --- a/applications/openshift/scheduler/scheduler_no_bind_address/rule.yml +++ b/applications/openshift/scheduler/scheduler_no_bind_address/rule.yml @@ -26,7 +26,6 @@ rationale: |- components that monitor the kubelet health. references: - cis@ocp4: 1.4.2 nerc-cip: CIP-003-8 R4.2,CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R5.1,CIP-007-3 R6.1 nist: CM-6,CM-6(1),SC-8,SC-8(1) pcidss: Req-2.2 diff --git a/applications/openshift/scheduler/scheduler_port_is_zero/rule.yml b/applications/openshift/scheduler/scheduler_port_is_zero/rule.yml index 31dcace7ca2a..44cb196aaf27 100644 --- a/applications/openshift/scheduler/scheduler_port_is_zero/rule.yml +++ b/applications/openshift/scheduler/scheduler_port_is_zero/rule.yml @@ -25,9 +25,6 @@ rationale: |- the port of the localhost healthz endpoint. Changing this value may disrupt components that monitor the kubelet health. -references: - cis@ocp4: 1.4.2 - severity: medium platform: not ocp4-on-hypershift-hosted diff --git a/applications/openshift/scheduler/scheduler_profiling_protected_by_rbac/rule.yml b/applications/openshift/scheduler/scheduler_profiling_protected_by_rbac/rule.yml index 1ed57e009819..5770211f7114 100644 --- a/applications/openshift/scheduler/scheduler_profiling_protected_by_rbac/rule.yml +++ b/applications/openshift/scheduler/scheduler_profiling_protected_by_rbac/rule.yml @@ -6,8 +6,6 @@ description: |- rationale: |- The Scheduler API service which runs on port 10251/TCP by default is used for health and metrics information and is available without authentication or encryption. As such it should only be bound to a localhost interface, to minimize the cluster's attack surface severity: medium -references: - cis@ocp4: 1.4.1 ocil: |- In OpenShift 4, The Kubernetes Scheduler operator manages and updates the Kubernetes Scheduler deployed on top of OpenShift. By default, the operator exposes metrics via metrics service. The metrics are collected from the Kubernetes Scheduler operator. Profiling data is sent to `healthzPort`, the port of the localhost `healthz` endpoint. Changing this value may disrupt components that monitor the kubelet health. The default `healthz` `port` value is `10251`, and the `healthz` `bindAddress` is `127.0.0.1` diff --git a/applications/openshift/scheduler/scheduler_service_protected_by_rbac/rule.yml b/applications/openshift/scheduler/scheduler_service_protected_by_rbac/rule.yml index d8e348320f95..d724db7fe8af 100644 --- a/applications/openshift/scheduler/scheduler_service_protected_by_rbac/rule.yml +++ b/applications/openshift/scheduler/scheduler_service_protected_by_rbac/rule.yml @@ -5,8 +5,6 @@ description: 'Do not bind the scheduler service to non-loopback insecure address rationale: |- The Scheduler API service which runs on port 10251/TCP by default is used for health and metrics information and is available without authentication or encryption. As such it should only be bound to a localhost interface, to minimize the cluster's attack surface severity: medium -references: - cis@ocp4: 1.4.2 ocil: |- In OpenShift 4, The Kubernetes Scheduler operator manages and updates the Kubernetes Scheduler deployed on top of OpenShift. By default, the operator exposes metrics via metrics service. The metrics are collected from the Kubernetes Scheduler operator. Profiling data is sent to `healthzPort`, the port of the localhost `healthz` endpoint. Changing this value may disrupt components that monitor the kubelet health. The default `healthz` `port` value is `10251`, and the `healthz` `bindAddress` is `127.0.0.1` diff --git a/applications/openshift/secrets/secrets_consider_external_storage/rule.yml b/applications/openshift/secrets/secrets_consider_external_storage/rule.yml index e786d43da5d4..eaf0a77b193a 100644 --- a/applications/openshift/secrets/secrets_consider_external_storage/rule.yml +++ b/applications/openshift/secrets/secrets_consider_external_storage/rule.yml @@ -20,7 +20,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.4.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/secrets/secrets_no_environment_variables/rule.yml b/applications/openshift/secrets/secrets_no_environment_variables/rule.yml index d1847fd9eda7..e177c8fd0084 100644 --- a/applications/openshift/secrets/secrets_no_environment_variables/rule.yml +++ b/applications/openshift/secrets/secrets_no_environment_variables/rule.yml @@ -15,7 +15,6 @@ rationale: |- severity: medium references: - cis@ocp4: 5.4.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/worker/file_groupowner_kubelet_conf/rule.yml b/applications/openshift/worker/file_groupowner_kubelet_conf/rule.yml index 57bfbe483285..a646ba7c656e 100644 --- a/applications/openshift/worker/file_groupowner_kubelet_conf/rule.yml +++ b/applications/openshift/worker/file_groupowner_kubelet_conf/rule.yml @@ -24,7 +24,6 @@ identifiers: references: cis@eks: 3.1.4 - cis@ocp4: 4.1.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_groupowner_proxy_kubeconfig/rule.yml b/applications/openshift/worker/file_groupowner_proxy_kubeconfig/rule.yml index 6aed1d9d2980..aadd2c0aa0fa 100644 --- a/applications/openshift/worker/file_groupowner_proxy_kubeconfig/rule.yml +++ b/applications/openshift/worker/file_groupowner_proxy_kubeconfig/rule.yml @@ -31,7 +31,6 @@ severity: medium # cce@ocp4: 80633-1 references: - cis@ocp4: 4.1.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/worker/file_groupowner_worker_ca/rule.yml b/applications/openshift/worker/file_groupowner_worker_ca/rule.yml index 38414d9fa4d6..b9e1d34b445d 100644 --- a/applications/openshift/worker/file_groupowner_worker_ca/rule.yml +++ b/applications/openshift/worker/file_groupowner_worker_ca/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-83440-8 references: - cis@ocp4: 4.1.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_groupowner_worker_kubeconfig/rule.yml b/applications/openshift/worker/file_groupowner_worker_kubeconfig/rule.yml index aa1216029b04..ec89855049ab 100644 --- a/applications/openshift/worker/file_groupowner_worker_kubeconfig/rule.yml +++ b/applications/openshift/worker/file_groupowner_worker_kubeconfig/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-83409-3 references: - cis@ocp4: 4.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_groupowner_worker_service/rule.yml b/applications/openshift/worker/file_groupowner_worker_service/rule.yml index 1ed92064a513..8f57fb4820ef 100644 --- a/applications/openshift/worker/file_groupowner_worker_service/rule.yml +++ b/applications/openshift/worker/file_groupowner_worker_service/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83975-3 references: - cis@ocp4: 4.1.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_owner_kubelet/rule.yml b/applications/openshift/worker/file_owner_kubelet/rule.yml index a6f8d63a2951..4f7e90fb1381 100644 --- a/applications/openshift/worker/file_owner_kubelet/rule.yml +++ b/applications/openshift/worker/file_owner_kubelet/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-85900-9 references: - cis@ocp4: 4.1.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_owner_kubelet_conf/rule.yml b/applications/openshift/worker/file_owner_kubelet_conf/rule.yml index 9a26bb735ff7..37747ba2d393 100644 --- a/applications/openshift/worker/file_owner_kubelet_conf/rule.yml +++ b/applications/openshift/worker/file_owner_kubelet_conf/rule.yml @@ -25,7 +25,6 @@ identifiers: references: cis@eks: 3.1.4 - cis@ocp4: 4.1.6 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_owner_proxy_kubeconfig/rule.yml b/applications/openshift/worker/file_owner_proxy_kubeconfig/rule.yml index 2eefc9c95b70..7b241c523fb1 100644 --- a/applications/openshift/worker/file_owner_proxy_kubeconfig/rule.yml +++ b/applications/openshift/worker/file_owner_proxy_kubeconfig/rule.yml @@ -32,7 +32,6 @@ severity: medium # cce@ocp4: 80633-1 references: - cis@ocp4: 4.1.4 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/worker/file_owner_worker_ca/rule.yml b/applications/openshift/worker/file_owner_worker_ca/rule.yml index ace76a295150..7eb39f57a930 100644 --- a/applications/openshift/worker/file_owner_worker_ca/rule.yml +++ b/applications/openshift/worker/file_owner_worker_ca/rule.yml @@ -18,7 +18,6 @@ identifiers: cce@ocp4: CCE-83495-2 references: - cis@ocp4: 4.1.8 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_owner_worker_kubeconfig/rule.yml b/applications/openshift/worker/file_owner_worker_kubeconfig/rule.yml index 42a78549cfac..8edefaa5ebd2 100644 --- a/applications/openshift/worker/file_owner_worker_kubeconfig/rule.yml +++ b/applications/openshift/worker/file_owner_worker_kubeconfig/rule.yml @@ -19,7 +19,6 @@ identifiers: references: cis@eks: 3.1.2 - cis@ocp4: 4.1.10 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_owner_worker_service/rule.yml b/applications/openshift/worker/file_owner_worker_service/rule.yml index 103c7c508c1c..c6d16e6ff4fe 100644 --- a/applications/openshift/worker/file_owner_worker_service/rule.yml +++ b/applications/openshift/worker/file_owner_worker_service/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-84193-2 references: - cis@ocp4: 4.1.2 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_permissions_kubelet/rule.yml b/applications/openshift/worker/file_permissions_kubelet/rule.yml index 6e131af119eb..98a03f304b69 100644 --- a/applications/openshift/worker/file_permissions_kubelet/rule.yml +++ b/applications/openshift/worker/file_permissions_kubelet/rule.yml @@ -23,7 +23,6 @@ identifiers: cce@ocp4: CCE-85896-9 references: - cis@ocp4: 4.1.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_permissions_kubelet_conf/rule.yml b/applications/openshift/worker/file_permissions_kubelet_conf/rule.yml index fe7f58b3c1a3..7393d458ffd8 100644 --- a/applications/openshift/worker/file_permissions_kubelet_conf/rule.yml +++ b/applications/openshift/worker/file_permissions_kubelet_conf/rule.yml @@ -27,7 +27,6 @@ identifiers: references: cis@eks: 3.1.3 - cis@ocp4: 4.1.5 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_permissions_proxy_kubeconfig/rule.yml b/applications/openshift/worker/file_permissions_proxy_kubeconfig/rule.yml index 308b96351132..0193f0fbaace 100644 --- a/applications/openshift/worker/file_permissions_proxy_kubeconfig/rule.yml +++ b/applications/openshift/worker/file_permissions_proxy_kubeconfig/rule.yml @@ -38,7 +38,6 @@ identifiers: references: - cis@ocp4: 4.1.3 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) pcidss: Req-2.2 diff --git a/applications/openshift/worker/file_permissions_worker_ca/rule.yml b/applications/openshift/worker/file_permissions_worker_ca/rule.yml index 55c9c89d0649..d8d254489c5f 100644 --- a/applications/openshift/worker/file_permissions_worker_ca/rule.yml +++ b/applications/openshift/worker/file_permissions_worker_ca/rule.yml @@ -20,7 +20,6 @@ identifiers: cce@ocp4: CCE-83493-7 references: - cis@ocp4: 4.1.7 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_permissions_worker_kubeconfig/rule.yml b/applications/openshift/worker/file_permissions_worker_kubeconfig/rule.yml index 3519440aa85a..8dcb2f27eb86 100644 --- a/applications/openshift/worker/file_permissions_worker_kubeconfig/rule.yml +++ b/applications/openshift/worker/file_permissions_worker_kubeconfig/rule.yml @@ -29,7 +29,6 @@ identifiers: references: cis@eks: 3.1.1 - cis@ocp4: 4.1.9 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/applications/openshift/worker/file_permissions_worker_service/rule.yml b/applications/openshift/worker/file_permissions_worker_service/rule.yml index dec05ebc4dbe..05b8a861189c 100644 --- a/applications/openshift/worker/file_permissions_worker_service/rule.yml +++ b/applications/openshift/worker/file_permissions_worker_service/rule.yml @@ -21,7 +21,6 @@ identifiers: cce@ocp4: CCE-83455-6 references: - cis@ocp4: 4.1.1 nerc-cip: CIP-003-8 R6,CIP-004-6 R3,CIP-007-3 R6.1 nist: CM-6,CM-6(1) srg: SRG-APP-000516-CTR-001325 diff --git a/build-scripts/build_all_guides.py b/build-scripts/build_all_guides.py index 3cce8d293950..45a8af0d166f 100755 --- a/build-scripts/build_all_guides.py +++ b/build-scripts/build_all_guides.py @@ -1,7 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function - """ Takes given XCCDF or data stream and for every profile in it it generates one OpenSCAP HTML guide. Also generates an index file that lists all the profiles diff --git a/build-scripts/build_cel_content.py b/build-scripts/build_cel_content.py new file mode 100755 index 000000000000..74786b6b9185 --- /dev/null +++ b/build-scripts/build_cel_content.py @@ -0,0 +1,383 @@ +#!/usr/bin/python3 + +""" +Build CEL content YAML file for compliance scanning. + +This module generates a CEL content file containing rules that use +the Common Expression Language (CEL) scanner instead of OVAL checks. +""" + +import argparse +import logging +import os +import sys +import yaml + +import ssg.build_yaml +import ssg.products +import ssg.utils + +MESSAGE_FORMAT = "%(levelname)s: %(message)s" + + +def parse_args(): + parser = argparse.ArgumentParser( + description="Generates CEL content YAML file from resolved rules" + ) + parser.add_argument( + "--resolved-rules-dir", required=True, + help="Directory containing resolved rule json files. " + "e.g.: ~/scap-security-guide/build/rhel9/rules" + ) + parser.add_argument( + "--profiles-dir", required=True, + help="Directory containing resolved profile YAML files. " + "e.g.: ~/scap-security-guide/build/ocp4/profiles" + ) + parser.add_argument( + "--product-yaml", required=True, + help="YAML file with information about the product we are building. " + "e.g.: ~/scap-security-guide/build/ocp4/product.yml" + ) + parser.add_argument( + "--output", required=True, + help="Output CEL content YAML file. " + "e.g.: ~/scap-security-guide/build/ocp4/ssg-ocp4-cel-content.yaml" + ) + parser.add_argument( + "--log", + action="store", + default="WARNING", + choices=["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"], + help="write debug information to the log up to the LOG_LEVEL.", + ) + return parser.parse_args() + + +def setup_logging(log_level_str): + numeric_level = getattr(logging, log_level_str.upper(), None) + if not isinstance(numeric_level, int): + raise ValueError("Invalid log level: {}".format(log_level_str)) + logging.basicConfig(format=MESSAGE_FORMAT, level=numeric_level) + + +def load_cel_rules(rules_dir): + """ + Load all rules that use the CEL checking engine. + + Args: + rules_dir: Directory containing resolved rule JSON files + + Returns: + dict: Dictionary of rule_id -> rule object for rules with CEL checks + + Raises: + ValueError: If a rule with CEL checks is missing required fields + """ + cel_rules = {} + + if not os.path.isdir(rules_dir): + return cel_rules + + for rule_file in os.listdir(rules_dir): + rule_path = os.path.join(rules_dir, rule_file) + try: + rule = ssg.build_yaml.Rule.from_compiled_json(rule_path) + + # Check if this rule has CEL checks by looking for CEL-specific fields + # A rule uses CEL if it has both expression and inputs + # (loaded from cel/shared.yml during rule compilation) + has_expression = hasattr(rule, 'expression') and rule.expression + has_inputs = hasattr(rule, 'inputs') and rule.inputs + + if has_expression and has_inputs: + # Validate required CEL fields + rule_name = rule_id_to_name(rule.id_) + + if not hasattr(rule, 'check_type') or not rule.check_type: + logging.warning( + f"Rule '{rule_name}' with CEL checks in {rule_file} has no check_type, defaulting to 'Platform'" + ) + rule.check_type = 'Platform' + + cel_rules[rule.id_] = rule + except ssg.build_yaml.DocumentationNotComplete: + # Skip documentation-incomplete rules in non-debug builds + continue + except ValueError: + # Re-raise validation errors + raise + except Exception as e: + logging.warning("Failed to load rule from %s: %s", rule_file, e) + continue + + return cel_rules + + +def load_profiles(profiles_dir, cel_rule_ids): + """ + Load profiles that target the CEL checking engine (scanner_type: CEL). + + Args: + profiles_dir: Directory containing profile YAML files + cel_rule_ids: Set of rule IDs that have CEL checks + + Returns: + list: List of profile objects targeting CEL + + Raises: + ValueError: If a profile targeting CEL is missing required fields + """ + profiles = [] + + if not os.path.isdir(profiles_dir): + return profiles + + for profile_file in os.listdir(profiles_dir): + profile_path = os.path.join(profiles_dir, profile_file) + try: + profile = ssg.build_yaml.Profile.from_compiled_json(profile_path) + + # Only load profiles targeting the CEL checking engine + if hasattr(profile, 'scanner_type') and profile.scanner_type == 'CEL': + # Validate required profile fields + profile_name = rule_id_to_name(profile.id_) + + if not hasattr(profile, 'selected') or not profile.selected: + raise ValueError( + f"Profile '{profile_name}' targeting CEL in {profile_file} has no rules" + ) + + profiles.append(profile) + except ValueError: + # Re-raise validation errors + raise + except Exception as e: + logging.warning("Failed to load profile from %s: %s", profile_file, e) + continue + + return profiles + + +def rule_id_to_name(rule_id): + """Convert rule_id with underscores to name with hyphens.""" + return rule_id.replace('_', '-') + + +def extract_controls_from_references(references): + """ + Extract controls from references dict, keeping original keys. + + Args: + references: Dictionary of references like {"cis@ocp4": ["1.2.3"], "nist": ["AC-6"]} + + Returns: + dict: Controls dictionary grouped by framework + """ + if not references: + return {} + + controls = {} + for ref_key, ref_values in references.items(): + # Keep the original key format (e.g., "cis@ocp4", "nist") + if isinstance(ref_values, list): + controls[ref_key] = ref_values + elif isinstance(ref_values, str): + controls[ref_key] = [ref_values] + + return controls + + +def convert_inputs_to_camelcase(inputs): + """ + Convert kubernetes_input_spec fields from snake_case to camelCase for CRD compatibility. + + Args: + inputs: List of input dictionaries + + Returns: + list: Inputs with camelCase field names + """ + if not inputs: + return inputs + + converted_inputs = [] + for input_item in inputs: + converted_item = dict(input_item) + if 'kubernetes_input_spec' in converted_item: + spec = converted_item['kubernetes_input_spec'] + camel_spec = {} + + # Convert snake_case keys to camelCase + key_mapping = { + 'api_version': 'apiVersion', + 'resource_name': 'resourceName', + 'resource_namespace': 'resourceNamespace', + } + + for key, value in spec.items(): + camel_key = key_mapping.get(key, key) + camel_spec[camel_key] = value + + converted_item['kubernetesInputSpec'] = camel_spec + del converted_item['kubernetes_input_spec'] + + converted_inputs.append(converted_item) + + return converted_inputs + + +def rule_to_cel_dict(rule): + """ + Convert a Rule object to CEL content dictionary format. + + Args: + rule: Rule object + + Returns: + dict: Rule in CEL content format + """ + cel_rule = { + 'id': rule.id_, # Keep underscores for id + 'name': rule_id_to_name(rule.id_), # Convert to hyphens for name + 'title': rule.title, + 'description': rule.description, + 'rationale': rule.rationale, + 'severity': rule.severity, + 'checkType': rule.check_type if hasattr(rule, 'check_type') and rule.check_type else 'Platform', + } + + # Add instructions from ocil field + if hasattr(rule, 'ocil') and rule.ocil: + cel_rule['instructions'] = rule.ocil + + # Add failureReason if present + if hasattr(rule, 'failure_reason') and rule.failure_reason: + cel_rule['failureReason'] = rule.failure_reason + + # Add CEL expression + if hasattr(rule, 'expression') and rule.expression: + cel_rule['expression'] = rule.expression + + # Add inputs (convert to camelCase for CRD compatibility) + if hasattr(rule, 'inputs') and rule.inputs: + cel_rule['inputs'] = convert_inputs_to_camelcase(rule.inputs) + + # Add controls from references + controls = extract_controls_from_references(rule.references) + if controls: + cel_rule['controls'] = controls + + return cel_rule + + +def profile_to_cel_dict(profile, cel_rule_ids): + """ + Convert a Profile object to CEL content dictionary format. + + Args: + profile: Profile object + cel_rule_ids: Set of rule IDs that have CEL checks + + Returns: + dict: Profile in CEL content format + """ + # Filter selected rules to only include rules with CEL checks + profile_cel_rules = [rule_id_to_name(rid) for rid in profile.selected if rid in cel_rule_ids] + + if not profile_cel_rules: + return None + + cel_profile = { + 'id': profile.id_, + 'name': rule_id_to_name(profile.id_), + 'title': profile.title, + 'description': profile.description, + 'productType': 'Platform', # Default for OCP4 + 'rules': sorted(profile_cel_rules) + } + + return cel_profile + + +def generate_cel_content(cel_rules, profiles): + """ + Generate the complete CEL content structure. + + Args: + cel_rules: Dictionary of rules with CEL checks + profiles: List of profiles targeting the CEL checking engine + + Returns: + dict: Complete CEL content structure + + Raises: + ValueError: If duplicate rule names found or profile references unknown rules + """ + cel_rule_ids = set(cel_rules.keys()) + + # Generate rules section and check for duplicates + cel_rules_list = [] + rule_names_seen = set() + for rule_id in sorted(cel_rules.keys()): + rule = cel_rules[rule_id] + cel_rule = rule_to_cel_dict(rule) + + # Check for duplicate rule names + rule_name = cel_rule['name'] + if rule_name in rule_names_seen: + raise ValueError(f"duplicate rule name: {rule_name}") + rule_names_seen.add(rule_name) + + cel_rules_list.append(cel_rule) + + # Generate profiles section and validate rule references + cel_profiles = [] + for profile in profiles: + # Validate that all selected rules have CEL checks + profile_name = rule_id_to_name(profile.id_) + for rule_id in profile.selected: + if rule_id not in cel_rule_ids: + rule_name = rule_id_to_name(rule_id) + raise ValueError( + f"profile '{profile_name}' references unknown rule '{rule_name}'" + ) + + cel_profile = profile_to_cel_dict(profile, cel_rule_ids) + if cel_profile: + cel_profiles.append(cel_profile) + + # Build the complete structure + content = { + 'profiles': cel_profiles, + 'rules': cel_rules_list + } + + return content + + +def main(): + args = parse_args() + setup_logging(args.log) + + # Load rules with CEL checks + cel_rules = load_cel_rules(args.resolved_rules_dir) + + if not cel_rules: + content = {'profiles': [], 'rules': []} + else: + # Load profiles + profiles = load_profiles(args.profiles_dir, set(cel_rules.keys())) + + # Generate CEL content + content = generate_cel_content(cel_rules, profiles) + + # Write output YAML + os.makedirs(os.path.dirname(args.output), exist_ok=True) + + with open(args.output, 'w') as f: + yaml.dump(content, f, default_flow_style=False, sort_keys=False, allow_unicode=True) + + +if __name__ == "__main__": + main() diff --git a/build-scripts/build_sce.py b/build-scripts/build_sce.py index 25a99210c64a..2fc857e20f6a 100755 --- a/build-scripts/build_sce.py +++ b/build-scripts/build_sce.py @@ -26,7 +26,6 @@ will fail to interpret (thinking it is XML)! """ -from __future__ import print_function import argparse diff --git a/build-scripts/build_templated_content.py b/build-scripts/build_templated_content.py index eebf79647635..bb3f49b619ce 100644 --- a/build-scripts/build_templated_content.py +++ b/build-scripts/build_templated_content.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import argparse diff --git a/build-scripts/build_xccdf.py b/build-scripts/build_xccdf.py index 2711dea2f527..8ec32e4d33e1 100644 --- a/build-scripts/build_xccdf.py +++ b/build-scripts/build_xccdf.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import argparse import os diff --git a/build-scripts/collect_remediations.py b/build-scripts/collect_remediations.py index ecf3e867f00d..93eeb7b24f38 100755 --- a/build-scripts/collect_remediations.py +++ b/build-scripts/collect_remediations.py @@ -118,7 +118,7 @@ def collect_remediations( msg = ( "Failed to dispatch {lang} remediation for {rule_id}: {error}" .format(lang=lang, rule_id=rule.id_, error=str(exc))) - raise RuntimeError(msg) + raise RuntimeError(msg) from exc def main(): diff --git a/build-scripts/compile_all.py b/build-scripts/compile_all.py index 40ff00b7a206..80ca511e158b 100644 --- a/build-scripts/compile_all.py +++ b/build-scripts/compile_all.py @@ -1,4 +1,3 @@ -from __future__ import print_function import argparse import os.path diff --git a/build-scripts/cpe_generate.py b/build-scripts/cpe_generate.py index e3c5e9acbcee..837578e78fa5 100755 --- a/build-scripts/cpe_generate.py +++ b/build-scripts/cpe_generate.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import sys import os diff --git a/build-scripts/enable_derivatives.py b/build-scripts/enable_derivatives.py index 3d83aae9ea2a..5553c8f493e2 100755 --- a/build-scripts/enable_derivatives.py +++ b/build-scripts/enable_derivatives.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function """ Takes given XCCDF or data stream and adds RHEL derivative operating system(s) CPE name next diff --git a/build-scripts/expand_jinja.py b/build-scripts/expand_jinja.py index 086c49503dc4..284af36985ff 100644 --- a/build-scripts/expand_jinja.py +++ b/build-scripts/expand_jinja.py @@ -1,4 +1,3 @@ -from __future__ import print_function import os import sys diff --git a/build-scripts/generate_man_page.py b/build-scripts/generate_man_page.py index e144a9f5a5bb..daaa987b1f39 100755 --- a/build-scripts/generate_man_page.py +++ b/build-scripts/generate_man_page.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import argparse import ssg.build_profile diff --git a/build-scripts/generate_manifest.py b/build-scripts/generate_manifest.py index e40c68783830..42844a4b804a 100644 --- a/build-scripts/generate_manifest.py +++ b/build-scripts/generate_manifest.py @@ -1,4 +1,3 @@ -from __future__ import print_function import os import json diff --git a/build-scripts/generate_profile_remediations.py b/build-scripts/generate_profile_remediations.py index d6161bb7c9e7..8ea0afd34fa3 100755 --- a/build-scripts/generate_profile_remediations.py +++ b/build-scripts/generate_profile_remediations.py @@ -4,14 +4,15 @@ import collections import os import re +import textwrap import xml.etree.ElementTree as ET -import yaml import ssg.ansible import ssg.yaml from ssg.constants import ( ansible_system, bash_system, + hummingbird_system, datastream_namespace, OSCAP_PROFILE, OSCAP_RULE, @@ -21,9 +22,12 @@ DEFAULT_SELECTOR = "__DEFAULT" HASH_ROW = "#" * 79 -LANGUAGE_TO_SYSTEM = {"ansible": ansible_system, "bash": bash_system} -LANGUAGE_TO_TARGET = {"ansible": "playbook", "bash": "script"} -LANGUAGE_TO_EXTENSION = {"ansible": "yml", "bash": "sh"} +LANGUAGE_TO_SYSTEM = { + "ansible": ansible_system, + "bash": bash_system, + "hummingbird": hummingbird_system} +LANGUAGE_TO_TARGET = {"ansible": "playbook", "bash": "script", "hummingbird": "script"} +LANGUAGE_TO_EXTENSION = {"ansible": "yml", "bash": "sh", "hummingbird": "sh"} ANSIBLE_VAR_PATTERN = re.compile( "- name: XCCDF Value [^ ]+ # promote to variable\n set_fact:\n" " ([^:]+): !!str (.+)\n tags:\n - always\n") @@ -44,8 +48,8 @@ def parse_args(): help="Product ID, eg. 'rhel9'" ) parser.add_argument( - "--language", required=True, choices=["bash", "ansible"], - help="Remediation language, either 'bash' or 'ansible'" + "--language", required=True, choices=["bash", "ansible", "hummingbird"], + help="Remediation language, either 'bash' or 'ansible' or 'hummingbird'" ) args = parser.parse_args() return args @@ -125,7 +129,7 @@ def get_variable_values(variable): if selector is None: selector = DEFAULT_SELECTOR if value.text is None: - values["selector"] = "" + values[selector] = "" else: values[selector] = value.text return values @@ -206,8 +210,10 @@ def load_all_remediations(self, benchmark): def generate_profile_remediation_script(self, profile_el): if self.language == "ansible": output = self.create_output_ansible(profile_el) - elif self.language == "bash": - output = self.create_output_bash(profile_el) + elif self.language in ("bash", "hummingbird"): + output = self.create_output_linear(profile_el) + else: + raise ValueError("Unknown language %s" % self.language) file_path = self.get_output_file_path(profile_el) with open(file_path, "wb") as f: f.write(output.encode("utf-8")) @@ -254,20 +260,38 @@ def collect_ansible_vars_and_tasks(self, profile_el): all_tasks.extend(rule_tasks) return (all_vars, all_tasks) - def create_output_bash(self, profile): + def create_output_linear(self, profile): output = [] selected_rules = get_selected_rules(profile) refinements = get_value_refinenements(profile) header = self.create_header(profile) output.append(header) total = len(selected_rules) + if self.language == "hummingbird": + newroot_assign = textwrap.dedent( + """ + # The first argument is the root directory of the system + NEWROOT="$1" + if [[ -z "$NEWROOT" ]] ; then + echo "Missing required NEWROOT argument" >&2 + exit 1 + fi + """ + ) + output.append(newroot_assign) current = 1 for rule_id in self.remediations: if rule_id not in selected_rules: continue status = (current, total) - rule_remediation = self.generate_bash_rule_remediation( - rule_id, status, refinements) + if self.language == "bash": + rule_remediation = self.generate_bash_rule_remediation( + rule_id, status, refinements) + elif self.language == "hummingbird": + rule_remediation = self.generate_hummingbird_rule_remediation( + rule_id, refinements) + else: + raise ValueError("Unknown language %s" % self.language) output.append(rule_remediation) current += 1 return "".join(output) @@ -286,11 +310,26 @@ def create_header(self, profile): shebang_with_newline = "#!/usr/bin/env bash\n" remediation_type = "Bash Remediation Script" how_to_apply = "# $ sudo ./remediation-script.sh\n" + elif self.language == "hummingbird": + shebang_with_newline = "#!/usr/bin/env bash\n" + remediation_type = ( + "Bash Remediation Script for building Project Hummingbird " + "container images") + how_to_apply = "# RUN remediation-script.sh ${NEWROOT}\n" + else: + raise ValueError("Unknown language %s" % self.language) profile_title = profile.find("./{%s}title" % XCCDF12_NS).text description = profile.find("./{%s}description" % XCCDF12_NS).text commented_profile_description = comment(description) xccdf_version_name = "1.2" profile_id = profile.get("id") + if self.language == "bash": + generation_text = ( + "# This file can be generated by OpenSCAP using:\n" + "# $ oscap xccdf generate fix --profile %s --fix-type %s %s\n" + "#\n" % (profile_id, self.language, self.ds_file_name)) + else: + generation_text = "" fix_header = ( "%s" "%s\n" @@ -305,9 +344,7 @@ def create_header(self, profile): "# Benchmark Version: %s\n" "# XCCDF Version: %s\n" "#\n" - "# This file can be generated by OpenSCAP using:\n" - "# $ oscap xccdf generate fix --profile %s --fix-type %s %s\n" - "#\n" + "%s" "# This %s is generated from an XCCDF profile without" " preliminary evaluation.\n" "# It attempts to fix every selected rule, even if the system is" @@ -320,7 +357,7 @@ def create_header(self, profile): shebang_with_newline, HASH_ROW, remediation_type, profile_title, commented_profile_description, profile_id, self.benchmark_id, self.benchmark_version, xccdf_version_name, - profile_id, self.language, self.ds_file_name, + generation_text, remediation_type, remediation_type, how_to_apply, HASH_ROW)) return fix_header @@ -351,6 +388,29 @@ def generate_bash_rule_remediation(self, rule_id, status, refinements): output.append(end_msg) return "".join(output) + def generate_hummingbird_rule_remediation(self, rule_id, refinements): + fix_el = self.remediations[rule_id] + if fix_el is None: + return "" + expanded_remediation = expand_variables( + fix_el, refinements, self.variables) + # For Hummingbird we intentionally don't add any warning if the + # rule Hummingbird remediation is missing because we expect that + # it will be normal that most of rules won't have any Hummingbird + # remediation + if expanded_remediation is None: + return "" + output = [] + header = ( + "%s\n" + "# BEGIN fix for '%s'\n" + "%s\n" % (HASH_ROW, rule_id, HASH_ROW)) + output.append(header) + output.append(expanded_remediation) + end_msg = "\n# END fix for '%s'\n\n" % (rule_id) + output.append(end_msg) + return "".join(output) + def generate_ansible_rule_remediation(self, fix_el, refinements): rule_vars = {} tasks = [] diff --git a/build-scripts/profile_tool.py b/build-scripts/profile_tool.py index 235f0f48dd45..815fc187edbf 100755 --- a/build-scripts/profile_tool.py +++ b/build-scripts/profile_tool.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import argparse diff --git a/build-scripts/verify_references.py b/build-scripts/verify_references.py index 882b8d2b868b..dcf68b7fd555 100755 --- a/build-scripts/verify_references.py +++ b/build-scripts/verify_references.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import sys import optparse diff --git a/build_product b/build_product index 76e3d3a69854..df6acb1fa654 100755 --- a/build_product +++ b/build_product @@ -8,7 +8,9 @@ # ARG_OPTIONAL_BOOLEAN([derivatives],[],[Also build derivatives of products if applicable],[off]) # ARG_OPTIONAL_BOOLEAN([ansible-playbooks],[],[Build Ansible Playbooks for every profile],[on]) # ARG_OPTIONAL_BOOLEAN([bash-scripts],[],[Build Bash remediation scripts for every profile],[on]) -# ARG_OPTIONAL_BOOLEAN([datastream-only],[d],[Build the data stream only. Do not build any of the guides, tables, etc],[off]) +# ARG_OPTIONAL_BOOLEAN([datastream-only],[d],[Build the data stream only. Do not build any of the guides, tables, etc. (deprecated, use --datastream option)],[off]) +# ARG_OPTIONAL_ACTION([datastream],[],[Build the data stream. Do not build any of the guides, tables, etc]) +# ARG_OPTIONAL_SINGLE([cel-content],[],[Product(s) to build CEL content for (comma-separated)],[off]) # ARG_OPTIONAL_BOOLEAN([profiling],[p],[Use ninja and call the build_profiler.sh util],[off]) # ARG_USE_ENV([ADDITIONAL_CMAKE_OPTIONS],[],[Whitespace-separated string of arguments to pass to CMake]) # ARG_POSITIONAL_INF([product],[Products to build, ALL means all products],[0],[ALL]) @@ -64,6 +66,7 @@ _arg_ansible_playbooks="on" _arg_playbook_per_rule="off" _arg_bash_scripts="on" _arg_datastream_only="off" +_arg_cel_content="off" _arg_profiling="off" _arg_log="off" _arg_thin_datastream="off" @@ -73,7 +76,7 @@ _arg_render_test_scenarios="off" print_help() { printf '%s\n' "Wipes out contents of the 'build' directory and builds only and only the given products." - printf 'Usage: %s [-b|--builder ] [-j|--jobs ] [--(no-)debug] [--(no-)derivatives] [--(no-)ansible-playbooks] [--(no-)bash-scripts] [-d|--(no-)datastream-only] [-p|--(no-)profiling] [-h|--help] [] ... [] ...\n' "$0" + printf 'Usage: %s [-b|--builder ] [-j|--jobs ] [--(no-)debug] [--(no-)derivatives] [--(no-)ansible-playbooks] [--(no-)bash-scripts] [-d|--(no-)datastream-only] [--datastream] [-p|--(no-)profiling] [-h|--help] [] ... [] ...\n' "$0" printf '\t%s\n' ": Products to build, ALL means all products (defaults for : 'ALL')" printf '\t%s\n' "-b, --builder: Builder engine. Can be one of: 'make', 'ninja' and 'auto' (default: 'auto')" printf '\t%s\n' "-j, --jobs: Count of simultaneous jobs (default: 'auto')" @@ -84,7 +87,9 @@ print_help() printf '\t%s\n' "--bash-scripts, --no-bash-scripts: Build Bash remediation scripts for every profile (on by default)" printf '\t%s\n' "-t, --thin, --no-thin: Build thin data streams for each rule. Do not build any of the guides, tables, etc (off by default)" printf '\t%s\n' "-r, --rule-id: Rule ID: Build a thin data stream with the specified rule. Do not build any of the guides, tables, etc (off by default)" - printf '\t%s\n' "-d, --datastream-only, --no-datastream-only: Build the data stream only. Do not build any of the guides, tables, etc (off by default)" + printf '\t%s\n' "-d, --datastream-only, --no-datastream-only: Build the data stream only. Do not build any of the guides, tables, etc (deprecated, use --datastream option)(off by default)" + printf '\t%s\n' "--datastream: Build the data stream. Do not build any of the guides, tables, etc" + printf '\t%s\n' "--cel-content: Product(s) to build CEL content for (comma-separated) (default: 'off')" printf '\t%s\n' "--render-test-scenarios: render Automatus test scenarios for specified product and put them into the build directory (off by default)" printf '\t%s\n' "-p, --profiling, --no-profiling: Use ninja and call the build_profiler.sh util (off by default)" printf '\t%s\n' "-l, --log, --no-log: Logs all debugging messages (off by default)" @@ -179,6 +184,17 @@ parse_commandline() { begins_with_short_option "$_next" && shift && set -- "-d" "-${_next}" "$@"; } || die "The short option '$_key' can't be decomposed to ${_key:0:2} and -${_key:2}, because ${_key:0:2} doesn't accept value and '-${_key:2:1}' doesn't correspond to a short option." fi ;; + --datastream) + _arg_datastream_only="on" + ;; + --cel-content) + test $# -lt 2 && die "Missing value for the optional argument '$_key'." 1 + _arg_cel_content="$2" + shift + ;; + --cel-content=*) + _arg_cel_content="${_key##--cel-content=}" + ;; -p|--no-profiling|--profiling) _arg_profiling="on" test "${1:0:5}" = "--no-" && _arg_profiling="off" @@ -322,6 +338,12 @@ set_explict_build_targets() { EXPLICIT_BUILD_TARGETS+=("generate-ssg-$(to_lowercase "$chosen_product")-ds.xml") done fi + if test "$_arg_cel_content" != off ; then + IFS=',' read -ra CEL_PRODUCTS <<< "$_arg_cel_content" + for cel_product in "${CEL_PRODUCTS[@]}"; do + EXPLICIT_BUILD_TARGETS+=("generate-$(to_lowercase "$cel_product")-cel-content.yaml") + done + fi } # Get this using @@ -340,6 +362,7 @@ all_cmake_products=( EXAMPLE FEDORA FIREFOX + HUMMINGBIRD KYLINSERVER10 OCP4 OL7 diff --git a/cmake/SSGCommon.cmake b/cmake/SSGCommon.cmake index 9c28803eada0..1b64f4ca0e4f 100644 --- a/cmake/SSGCommon.cmake +++ b/cmake/SSGCommon.cmake @@ -258,7 +258,7 @@ macro(ssg_build_ansible_playbooks PRODUCT) endmacro() macro(ssg_build_remediations PRODUCT) - message(STATUS "Scanning for dependencies of ${PRODUCT} fixes (bash, ansible, puppet, anaconda, ignition, kubernetes and blueprint)...") + message(STATUS "Scanning for dependencies of ${PRODUCT} fixes (${PRODUCT_REMEDIATION_LANGUAGES})...") ssg_collect_remediations(${PRODUCT} "${PRODUCT_REMEDIATION_LANGUAGES}") @@ -528,6 +528,20 @@ macro(ssg_build_sds PRODUCT) endif() endmacro() +# Build CEL content YAML for products that support CEL scanning +macro(ssg_build_cel_content PRODUCT) + add_custom_command( + OUTPUT "${CMAKE_BINARY_DIR}/${PRODUCT}-cel-content.yaml" + COMMAND env "PYTHONPATH=$ENV{PYTHONPATH}" "${Python_EXECUTABLE}" "${SSG_BUILD_SCRIPTS}/build_cel_content.py" --resolved-rules-dir "${CMAKE_CURRENT_BINARY_DIR}/rules" --profiles-dir "${CMAKE_CURRENT_BINARY_DIR}/profiles" --product-yaml "${CMAKE_CURRENT_BINARY_DIR}/product.yml" --output "${CMAKE_BINARY_DIR}/${PRODUCT}-cel-content.yaml" + DEPENDS ${PRODUCT}-compile-all "${CMAKE_CURRENT_BINARY_DIR}/ssg_build_compile_all-${PRODUCT}" + COMMENT "[${PRODUCT}-content] generating CEL content YAML" + ) + add_custom_target( + generate-${PRODUCT}-cel-content.yaml + DEPENDS "${CMAKE_BINARY_DIR}/${PRODUCT}-cel-content.yaml" + ) +endmacro() + # Build per-product HTML guides to see the status of various profiles and # rules in the generated XCCDF guides. macro(ssg_build_html_guides PRODUCT) @@ -575,6 +589,20 @@ macro(ssg_build_profile_bash_scripts PRODUCT) DEPENDS "${CMAKE_BINARY_DIR}/bash/all-profile-bash-scripts-${PRODUCT}" ) endmacro() +macro(ssg_build_profile_hummingbird_scripts PRODUCT) + add_custom_command( + OUTPUT "${CMAKE_BINARY_DIR}/hummingbird_scripts/all-profile-hummingbird-scripts-${PRODUCT}" + COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_BINARY_DIR}/hummingbird_scripts" + COMMAND env "PYTHONPATH=$ENV{PYTHONPATH}" "${Python_EXECUTABLE}" "${SSG_BUILD_SCRIPTS}/generate_profile_remediations.py" --language hummingbird --data-stream "${CMAKE_BINARY_DIR}/ssg-${PRODUCT}-ds.xml" --output-dir "${CMAKE_BINARY_DIR}/hummingbird_scripts" --product "${PRODUCT}" + COMMAND ${CMAKE_COMMAND} -E touch "${CMAKE_BINARY_DIR}/hummingbird_scripts/all-profile-hummingbird-scripts-${PRODUCT}" + DEPENDS generate-ssg-${PRODUCT}-ds.xml "${CMAKE_BINARY_DIR}/ssg-${PRODUCT}-ds.xml" + COMMENT "[${PRODUCT}-hummingbird-scripts] generating hummingbird remediation scripts for all profiles in ssg-${PRODUCT}-ds.xml" + ) + add_custom_target( + generate-all-profile-hummingbird-scripts-${PRODUCT} + DEPENDS "${CMAKE_BINARY_DIR}/hummingbird_scripts/all-profile-hummingbird-scripts-${PRODUCT}" + ) +endmacro() # Build per-profile Ansible remediation scripts that can be used independently # of OpenSCAP execution. @@ -640,6 +668,25 @@ macro(ssg_render_policies_for_product PRODUCT) ) endmacro() +macro(ssg_generate_nist_viewer) + # Generate NIST 800-53 control viewer with gap analysis + # This generates for all RHEL products at once + set(NIST_PRODUCTS rhel8 rhel9 rhel10) + add_custom_command( + OUTPUT "${CMAKE_BINARY_DIR}/nist-controls-viewer/index.html" + COMMAND ${CMAKE_COMMAND} -E make_directory "${CMAKE_BINARY_DIR}/nist-controls-viewer" + COMMAND env "PYTHONPATH=$ENV{PYTHONPATH}" "${Python_EXECUTABLE}" "${CMAKE_SOURCE_DIR}/utils/nist_sync/generate_nist_viewer.py" + --products ${NIST_PRODUCTS} + --output-dir "${CMAKE_BINARY_DIR}/nist-controls-viewer" + --repo-root "${CMAKE_SOURCE_DIR}" + COMMENT "[nist-viewer] generating NIST 800-53 control viewer with gap analysis" + ) + + add_custom_target(nist-viewer + DEPENDS "${CMAKE_BINARY_DIR}/nist-controls-viewer/index.html" + ) +endmacro() + macro(ssg_make_all_tables PRODUCT) add_custom_command( OUTPUT "${CMAKE_BINARY_DIR}/tables/tables-${PRODUCT}-all.html" @@ -740,6 +787,11 @@ macro(ssg_build_product PRODUCT) ssg_build_xml_final(${PRODUCT} ocil) ssg_build_sds(${PRODUCT}) + # Build CEL content if enabled for this product + if(PRODUCT_CEL_ENABLED) + ssg_build_cel_content(${PRODUCT}) + endif() + define_validate_product("${PRODUCT}") if("${VALIDATE_PRODUCT}" OR "${FORCE_VALIDATE_EVERYTHING}") add_test( @@ -764,6 +816,15 @@ macro(ssg_build_product PRODUCT) add_dependencies(zipfile generate-ssg-${PRODUCT}-ds.xml) + # Add CEL content to dependencies if enabled + if(PRODUCT_CEL_ENABLED) + add_dependencies( + ${PRODUCT}-content + generate-${PRODUCT}-cel-content.yaml + ) + add_dependencies(zipfile generate-${PRODUCT}-cel-content.yaml) + endif() + if("${PRODUCT_ANSIBLE_REMEDIATION_ENABLED}" AND SSG_ANSIBLE_PLAYBOOKS_ENABLED) ssg_build_profile_playbooks(${PRODUCT}) add_custom_target( @@ -784,6 +845,16 @@ macro(ssg_build_product PRODUCT) add_dependencies(zipfile ${PRODUCT}-profile-bash-scripts) endif() + if("${PRODUCT_HUMMINGBIRD_REMEDIATION_ENABLED}") + ssg_build_profile_hummingbird_scripts(${PRODUCT}) + add_custom_target( + ${PRODUCT}-profile-hummingbird-scripts + DEPENDS generate-all-profile-hummingbird-scripts-${PRODUCT} "${CMAKE_BINARY_DIR}/hummingbird_scripts/all-profile-hummingbird-scripts-${PRODUCT}" + ) + add_dependencies(${PRODUCT} ${PRODUCT}-profile-hummingbird-scripts) + add_dependencies(zipfile ${PRODUCT}-profile-hummingbird-scripts) + endif() + ssg_build_html_guides(${PRODUCT}) add_custom_target( diff --git a/components/audit.yml b/components/audit.yml index bd1807988a47..018ead72842e 100644 --- a/components/audit.yml +++ b/components/audit.yml @@ -131,6 +131,7 @@ rules: - audit_rules_mac_modification_etc_apparmor_d - audit_rules_mac_modification_etc_selinux - audit_rules_mac_modification_usr_share +- audit_rules_mac_modification_var_lib_selinux - audit_rules_media_export - audit_rules_networkconfig_modification - audit_rules_networkconfig_modification_etc_hosts diff --git a/components/authselect.yml b/components/authselect.yml deleted file mode 100644 index 7c0e4d38cf97..000000000000 --- a/components/authselect.yml +++ /dev/null @@ -1,5 +0,0 @@ -name: authselect -packages: -- authselect -rules: -- package_authselect_installed diff --git a/components/bash.yml b/components/bash.yml index 6187c59427d8..31006f91bddf 100644 --- a/components/bash.yml +++ b/components/bash.yml @@ -3,6 +3,7 @@ packages: - bash rules: - accounts_umask_etc_bashrc +- file_permission_user_bash_history - accounts_umask_etc_csh_cshrc - accounts_umask_etc_profile - accounts_umask_root diff --git a/components/chrony.yml b/components/chrony.yml index cffe68f8cb4e..5ac8a033be9f 100644 --- a/components/chrony.yml +++ b/components/chrony.yml @@ -14,6 +14,7 @@ rules: - service_chronyd_enabled - chrony_set_nts - chronyd_client_only +- chronyd_configure_local_socket - chronyd_no_chronyc_network - chronyd_or_ntpd_specify_multiple_servers - chronyd_sync_clock diff --git a/components/crypto-policies.yml b/components/crypto-policies.yml index a93e67af5505..595c4dbc8db5 100644 --- a/components/crypto-policies.yml +++ b/components/crypto-policies.yml @@ -13,6 +13,7 @@ rules: - configure_openssl_tls_crypto_policy - configure_ssh_crypto_policy - configure_custom_crypto_policy_cis +- crypto_policy_not_legacy - harden_openssl_crypto_policy - harden_ssh_client_crypto_policy - harden_sshd_ciphers_openssh_conf_crypto_policy @@ -24,3 +25,4 @@ rules: - package_crypto-policies_installed - fips_crypto_subpolicy - fips_crypto_policy_symlinks +- crypto_policy_not_overridden diff --git a/components/dnf.yml b/components/dnf.yml index ff1d7d264df3..65a1e2b888d0 100644 --- a/components/dnf.yml +++ b/components/dnf.yml @@ -10,6 +10,7 @@ rules: - enable_gpgcheck_for_all_repositories - ensure_gpgcheck_globally_activated - ensure_gpgcheck_local_packages +- ensure_gpgcheck_never_disabled - ensure_gpgcheck_repo_metadata - package_dnf-automatic_installed - package_dnf-plugin-subscription-manager_installed diff --git a/components/krb5.yml b/components/krb5.yml index 859ce0292d8f..414bd442334e 100644 --- a/components/krb5.yml +++ b/components/krb5.yml @@ -3,9 +3,11 @@ groups: name: krb5 packages: - krb5 +- krb5-libs - krb5-server - krb5-workstation rules: +- configure_kerberos_crypto_policy - kerberos_disable_no_keytab - package_krb5-server_removed - package_krb5-workstation_removed diff --git a/components/nfs-common.yml b/components/nfs-common.yml new file mode 100644 index 000000000000..31b0f2666976 --- /dev/null +++ b/components/nfs-common.yml @@ -0,0 +1,5 @@ +name: nfs-common +packages: +- nfs-common +rules: +- package_nfs-common_removed diff --git a/components/ntp.yml b/components/ntp.yml index 22c94f65fdc9..8ff66b5a133c 100644 --- a/components/ntp.yml +++ b/components/ntp.yml @@ -5,6 +5,7 @@ packages: - ntp rules: - chronyd_client_only +- chronyd_configure_local_socket - chronyd_configure_pool_and_server - chronyd_no_chronyc_network - chronyd_or_ntpd_set_maxpoll diff --git a/components/openssh.yml b/components/openssh.yml index 48d3672b1f29..63c1017aecf8 100644 --- a/components/openssh.yml +++ b/components/openssh.yml @@ -94,6 +94,8 @@ rules: - sshd_use_strong_rng - sshd_x11_use_localhost - sshd_include_crypto_policy +- harden_sshd_ciphers_openssh_conf_crypto_policy - harden_sshd_crypto_policy +- harden_sshd_macs_openssh_conf_crypto_policy templates: - sshd_lineinfile diff --git a/components/openssl.yml b/components/openssl.yml index 57c8a1ae2fbb..914f36e073d5 100644 --- a/components/openssl.yml +++ b/components/openssl.yml @@ -4,5 +4,7 @@ name: openssl packages: - openssl rules: +- configure_openssl_crypto_policy +- configure_openssl_tls_crypto_policy - only_allow_dod_certs - only_allow_specific_certs diff --git a/components/operating-system.yml b/components/operating-system.yml index 45d050bf1724..d8a27adbd67f 100644 --- a/components/operating-system.yml +++ b/components/operating-system.yml @@ -6,6 +6,7 @@ rules: - accounts_user_home_paths_only - accounts_user_interactive_home_directory_defined - accounts_user_interactive_home_directory_exists +- accounts_user_interactive_home_directory_on_separate_partition - bios_assign_password - bios_disable_usb_boot - bios_enable_execution_restrictions diff --git a/components/pam.yml b/components/pam.yml index 8cc1332d5209..fece98a2896b 100644 --- a/components/pam.yml +++ b/components/pam.yml @@ -7,6 +7,7 @@ groups: - password_quality_pamcracklib name: pam packages: +- authselect - pam - pam_apparmor - libnss-sss @@ -64,6 +65,7 @@ rules: - accounts_passwords_pam_faillock_deny - accounts_passwords_pam_faillock_deny_root - accounts_passwords_pam_faillock_dir +- accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time - accounts_passwords_pam_faillock_enforce_local - accounts_passwords_pam_faillock_interval - accounts_passwords_pam_faillock_silent @@ -112,6 +114,7 @@ rules: - ensure_root_password_configured - ensure_shadow_group_empty - ensure_sudo_group_restricted +- file_etc_security_opasswd - file_groupowner_etc_issue - file_groupowner_etc_issue_net - file_groupowner_etc_motd @@ -121,7 +124,6 @@ rules: - file_owner_etc_motd - file_ownership_home_directories - file_ownership_lastlog -- file_permission_user_bash_history - file_permissions_etc_issue - file_permissions_etc_issue_net - file_permissions_etc_motd @@ -149,6 +151,7 @@ rules: - package_nss_sss_installed - package_pam_installed - package_pam_apparmor_installed +- package_authselect_installed - package_pam_modules_installed - package_pam_pwquality_installed - package_pam_runtime_installed diff --git a/components/tcsh.yml b/components/tcsh.yml new file mode 100644 index 000000000000..baf6b99dea9d --- /dev/null +++ b/components/tcsh.yml @@ -0,0 +1,5 @@ +name: tcsh +packages: + - tcsh +rules: + - accounts_umask_etc_csh_cshrc diff --git a/controls/anssi.yml b/controls/anssi.yml index ea88b22c4b38..90b391564ffb 100644 --- a/controls/anssi.yml +++ b/controls/anssi.yml @@ -1479,6 +1479,7 @@ controls: - ensure_logrotate_activated # Based on DAT-PA-012 R26, R27 + - rsyslog_filecreatemode - rsyslog_files_ownership - rsyslog_files_groupownership - rsyslog_files_permissions diff --git a/controls/ccn_ol9.yml b/controls/ccn_ol9.yml index 9c0756c3efa1..ec263c9b4823 100644 --- a/controls/ccn_ol9.yml +++ b/controls/ccn_ol9.yml @@ -321,7 +321,7 @@ controls: - advanced status: automated rules: - - configure_ssh_crypto_policy + - configure_crypto_policy - id: A.5.SEC-OL7 title: Network Session Inactivity is Controlled @@ -623,10 +623,15 @@ controls: - banner_etc_motd - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - sshd_enable_warning_banner_net - login_banner_text=cis_default + - login_banner_contents=cis_default - motd_banner_text=cis_default + - motd_banner_contents=cis_default - remote_login_banner_text=cis_default + - remote_login_banner_contents=cis_default - id: A.11.SEC-OL5 title: Network Acess to the System is Controlled @@ -650,7 +655,7 @@ controls: notes: |- It overlaps the rule in A.5.SEC-OL6 requirement related_rules: - - configure_ssh_crypto_policy + - configure_crypto_policy - id: A.11.SEC-OL7 title: GUI Idle Time is Limited diff --git a/controls/cis_al2023.yml b/controls/cis_al2023.yml index 666a5322499e..ffb74aa0621b 100644 --- a/controls/cis_al2023.yml +++ b/controls/cis_al2023.yml @@ -468,6 +468,7 @@ controls: rules: - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: 1.7.2 title: Ensure local login warning banner is configured properly (Automated) @@ -477,6 +478,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: 1.7.3 title: Ensure remote login warning banner is configured properly (Automated) @@ -486,6 +488,7 @@ controls: rules: - banner_etc_issue_net - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: 1.7.4 title: Ensure permissions on /etc/motd are configured (Automated) diff --git a/controls/cis_almalinux9.yml b/controls/cis_almalinux9.yml index 29fa4bd9b124..9919d5f05a6d 100644 --- a/controls/cis_almalinux9.yml +++ b/controls/cis_almalinux9.yml @@ -547,8 +547,7 @@ controls: - l1_workstation status: automated rules: - - configure_crypto_policy - - var_system_crypto_policy=default_nosha1 + - configure_custom_crypto_policy_cis - id: 1.6.2 title: Ensure system wide crypto policy is not set in sshd configuration (Automated) @@ -568,31 +567,25 @@ controls: notes: |- This requirement is already satisfied by 1.6.1. related_rules: - - configure_crypto_policy + - configure_custom_crypto_policy_cis - id: 1.6.4 title: Ensure system wide crypto policy disables macs less than 128 bits (Automated) levels: - l1_server - l1_workstation - status: pending - notes: |- - It is necessary a new rule to ensure a module disabling weak MACs in - /etc/crypto-policies/policies/modules/ so it can be used by update-crypto-policies command. - related_rules: - - configure_crypto_policy + status: automated + rules: + - configure_custom_crypto_policy_cis - id: 1.6.5 title: Ensure system wide crypto policy disables cbc for ssh (Automated) levels: - l1_server - l1_workstation - status: pending - notes: |- - It is necessary a new rule to ensure a module disabling CBC in - /etc/crypto-policies/policies/modules/ so it can be used by update-crypto-policies command. - related_rules: - - configure_crypto_policy + status: automated + rules: + - configure_custom_crypto_policy_cis - id: 1.6.6 title: Ensure system wide crypto policy disables chacha20-poly1305 for ssh (Automated) @@ -691,7 +684,8 @@ controls: rules: - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_banners + - dconf_login_banner_text=cis_banners + - dconf_login_banner_contents=cis_default - id: 1.8.3 title: Ensure GDM disable-user-list option is enabled (Automated) diff --git a/controls/cis_debian12.yml b/controls/cis_debian12.yml index 8e0208f77309..6ffb09b7dda3 100644 --- a/controls/cis_debian12.yml +++ b/controls/cis_debian12.yml @@ -540,7 +540,8 @@ controls: - l1_server - l1_workstation rules: - - login_banner_text=cis_default + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text status: automated diff --git a/controls/cis_debian13.yml b/controls/cis_debian13.yml new file mode 100644 index 000000000000..f409e5958dfd --- /dev/null +++ b/controls/cis_debian13.yml @@ -0,0 +1,631 @@ +--- +policy: CIS Benchmark for Debian 13 +title: CIS Benchmark for Debian 13 +id: cis_debian13 +version: '1.0.0' +source: https://www.cisecurity.org/cis-benchmarks + +levels: + - id: l1_server + - id: l2_server + inherits_from: + - l1_server + - id: l1_workstation + - id: l2_workstation + inherits_from: + - l1_workstation + +reference_type: cis +product: debian13 + +controls: + - id: 1.1.1.1 + title: Ensure cramfs kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + rules: + - kernel_module_cramfs_disabled + status: automated + + - id: 1.1.1.2 + title: Ensure freevxfs kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + rules: + - kernel_module_freevxfs_disabled + status: automated + + - id: 1.1.1.3 + title: Ensure hfs kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + rules: + - kernel_module_hfs_disabled + status: automated + + - id: 1.1.1.4 + title: Ensure hfsplus kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + rules: + - kernel_module_hfsplus_disabled + status: automated + + - id: 1.1.1.5 + title: Ensure jffs2 kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + rules: + - kernel_module_jffs2_disabled + status: automated + + - id: 1.1.1.6 + title: Ensure overlayfs kernel module is not available (Automated) + levels: + - l2_server + - l2_workstation + rules: + - kernel_module_overlayfs_disabled + status: automated + + - id: 1.1.1.7 + title: Ensure squashfs kernel module is not available (Automated) + levels: + - l2_server + - l2_workstation + related_rules: + - kernel_module_squashfs_disabled + status: automated + + - id: 1.1.1.8 + title: Ensure udf kernel module is not available (Automated) + levels: + - l2_server + - l2_workstation + rules: + - kernel_module_udf_disabled + status: automated + + - id: 1.1.1.9 + title: Ensure firewire-core kernel module is not available (Automated) + levels: + - l1_server + - l2_workstation + rules: + - kernel_module_firewire-core_disabled + status: automated + + - id: 1.1.1.10 + title: Ensure usb-storage kernel module is not available (Automated) + levels: + - l1_server + - l2_workstation + rules: + - kernel_module_usb-storage_disabled + status: automated + + - id: 1.1.1.11 + title: Ensure unused filesystems kernel modules are not available (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 1.1.2.1.1 + title: Ensure /tmp is a separate partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - partition_for_tmp + status: automated + + - id: 1.1.2.1.2 + title: Ensure nodev option set on /tmp partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_tmp_nodev + status: automated + + - id: 1.1.2.1.3 + title: Ensure nosuid option set on /tmp partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_tmp_nosuid + status: automated + + - id: 1.1.2.1.4 + title: Ensure noexec option set on /tmp partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_tmp_noexec + status: automated + + - id: 1.1.2.2.1 + title: Ensure /dev/shm is tmpfs or a separate partition (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - partition_for_dev_shm + + - id: 1.1.2.2.2 + title: Ensure nodev option set on /dev/shm partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_dev_shm_nodev + status: automated + + - id: 1.1.2.2.3 + title: Ensure nosuid option set on /dev/shm partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_dev_shm_nosuid + status: automated + + - id: 1.1.2.2.4 + title: Ensure noexec option set on /dev/shm partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_dev_shm_noexec + status: automated + + - id: 1.1.2.3.1 + title: Ensure separate partition exists for /home (Automated) + levels: + - l2_server + - l2_workstation + rules: + - partition_for_home + status: automated + + - id: 1.1.2.3.2 + title: Ensure nodev option set on /home partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_home_nodev + status: automated + + - id: 1.1.2.3.3 + title: Ensure nosuid option set on /home partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_home_nosuid + status: automated + + - id: 1.1.2.4.1 + title: Ensure separate partition exists for /var (Automated) + levels: + - l2_server + - l2_workstation + rules: + - partition_for_var + status: automated + + - id: 1.1.2.4.2 + title: Ensure nodev option set on /var partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_nodev + status: automated + + - id: 1.1.2.4.3 + title: Ensure nosuid option set on /var partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_nosuid + status: automated + + - id: 1.1.2.5.1 + title: Ensure separate partition exists for /var/tmp (Automated) + levels: + - l2_server + - l2_workstation + rules: + - partition_for_var_tmp + status: automated + + - id: 1.1.2.5.2 + title: Ensure nodev option set on /var/tmp partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_tmp_nodev + status: automated + + - id: 1.1.2.5.3 + title: Ensure nosuid option set on /var/tmp partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_tmp_nosuid + status: automated + + - id: 1.1.2.5.4 + title: Ensure noexec option set on /var/tmp partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_tmp_noexec + status: automated + + - id: 1.1.2.6.1 + title: Ensure separate partition exists for /var/log (Automated) + levels: + - l2_server + - l2_workstation + rules: + - partition_for_var_log + status: automated + + - id: 1.1.2.6.2 + title: Ensure nodev option set on /var/log partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_log_nodev + status: automated + + - id: 1.1.2.6.3 + title: Ensure nosuid option set on /var/log partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_log_nosuid + status: automated + + - id: 1.1.2.6.4 + title: Ensure noexec option set on /var/log partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_log_noexec + status: automated + + - id: 1.1.2.7.1 + title: Ensure separate partition exists for /var/log/audit (Automated) + levels: + - l2_server + - l2_workstation + rules: + - partition_for_var_log_audit + status: automated + + - id: 1.1.2.7.2 + title: Ensure nodev option set on /var/log/audit partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_log_audit_nodev + status: automated + + - id: 1.1.2.7.3 + title: Ensure nosuid option set on /var/log/audit partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_log_audit_nosuid + status: automated + + - id: 1.1.2.7.4 + title: Ensure noexec option set on /var/log/audit partition (Automated) + levels: + - l1_server + - l1_workstation + rules: + - mount_option_var_log_audit_noexec + status: automated + + - id: 1.2.1.1 + title: Ensure the source.list and .source files use the Signed-By option (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 1.2.1.2 + title: Ensure weak dependencies are configured (Automated) + levels: + - l2_server + - l2_workstation + status: pending + notes: |- + Needs a new Debian-specific rule checking weak dependencies + + - id: 1.2.1.3 + title: Ensure access to gpg key files are configured (Automated) + levels: + - l1_server + - l2_server + status: pending + notes: |- + Needs a new Debian-specific rule for GPG key file access checks. + Check if all .gpg key files in /usr/share/keyrings/ and /etc/apt/trusted.gpg.d have permissions 0644 and owned by root:root + Check if .list and .sources in /etc/apt/sources.list.d have permissions 0644 and owned by root:root and include option signed-by + + - id: 1.2.1.4 + title: Ensure access to /etc/apt/trusted.gpg.d directory is configured + levels: + - l1_server + - l2_server + status: pending + notes: |- + Needs a new Debian-specific rule for /etc/apt/trusted.gpg.d directory access checks. + Check if /etc/apt/trusted.gpg.d has permissions 0755 and owned by root:root + + - id: 1.2.1.5 + title: Ensure access to /etc/apt/auth.conf.d directory is configured (Automated) + levels: + - l1_server + - l2_server + status: pending + notes: |- + Check if /etc/apt/auth.conf.d has permissions 0755 and owned by root:root + + - id: 1.2.1.6 + title: Ensure access to files in the /etc/apt/auth.conf.d/ directory is configured (Automated) + levels: + - l1_server + - l1_workstation + status: pending + notes: |- + Check if /etc/apt/auth.conf.d/* has permissions 0755 and owned by root:root + + - id: 1.2.1.7 + title: Ensure access to /usr/share/keyrings directory is configured (Automated) + levels: + - l1_server + - l2_server + status: pending + notes: |- + Check if /usr/share/keyrings has permissions 0755 and owned by root:root + + - id: 1.2.1.8 + title: Ensure access to /etc/apt/sources.list.d directory is configured (Automated) + levels: + - l1_server + - l2_server + status: pending + notes: |- + Check if /etc/apt/sources.list.d has permissions 0755 and owned by root:root + + - id: 1.2.1.9 + title: Ensure access to files in /etc/apt/sources.list.d are configured (Automated) + levels: + - l1_server + - l2_server + status: pending + notes: |- + Check if /etc/apt/sources.list.d/* has permissions 0755 and owned by root:root + + - id: 1.2.2.1 + title: Ensure updates, patches, and additional security software are installed (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 1.3.1.1 + title: Ensure AppArmor is installed (Automated) + levels: + - l1_server + - l1_workstation + rules: + - package_apparmor_installed + - package_apparmor-utils_installed + status: automated + + - id: 1.3.1.2 + title: Ensure AppArmor is enabled in the bootloader configuration (Automated) + levels: + - l1_server + - l1_workstation + rules: + - grub2_enable_apparmor + status: automated + + - id: 1.3.1.3 + title: Ensure all AppArmor Profiles are enforcing (Automated) + levels: + - l2_server + - l2_workstation + rules: + - all_apparmor_profiles_enforced + status: automated + notes: | + CIS recommendation does not adequately address the nuances + of various profiles, including disabled, force-complain, + and unconfined. Currently, the control changes the default apparmor + mode for all profiles in /etc/apparmor.d which can + break certain applications. See https://workbench.cisecurity.org/benchmarks/18959/tickets/23987 + + - id: 1.3.1.4 + title: Ensure apparmor_restrict_unprivileged_unconfined is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: pending + notes: |- + Check if sysctl kernel.apparmor_restrict_unprivileged_unconfined = 1 + + - id: 1.4.1 + title: Ensure bootloader password is set (Automated) + levels: + - l1_server + - l1_workstation + rules: + - grub2_password + - grub2_uefi_password + status: automated + + - id: 1.4.2 + title: Ensure access to bootloader config is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - file_owner_grub2_cfg + - file_permissions_grub2_cfg + status: automated + + - id: 1.5.1 + title: Ensure fs.protected_hardlinks is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_fs_protected_hardlinks + status: automated + + - id: 1.5.2 + title: Ensure fs.protected_symlinks is configured (Automated) + levels: + - l2_server + - l2_workstation + rules: + - sysctl_fs_protected_symlinks + status: automated + + - id: 1.5.3 + title: Ensure kernel.yama.ptrace_scope is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_kernel_yama_ptrace_scope + status: automated + + - id: 1.5.4 + title: Ensure fs.suid_dumpable is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_fs_suid_dumpable + status: automated + + - id: 1.5.5 + title: Ensure kernel.dmesg_restrict is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_kernel_dmesg_restrict + status: automated + + - id: 1.5.6 + title: Ensure prelink is not installed (Automated) + levels: + - l1_server + - l1_workstation + rules: + - disable_prelink + status: automated + + - id: 1.5.7 + title: Ensure Automatic Error Reporting is configured (Automated) + levels: + - l1_server + - l1_workstation + status: pending + notes: |- + Check if systemctl is-active apport.service , fail if it's active + Check if apport is installed , if it's not installed pass + + - id: 1.5.8 + title: Ensure kernel.kptr_restrict is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_kernel_kptr_restrict + status: automated + + - id: 1.5.9 + title: Ensure kernel.randomize_va_space is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_kernel_randomize_va_space + status: automated + + - id: 1.5.10 + title: Ensure kernel.yama.ptrace_scope is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - sysctl_kernel_yama_ptrace_scope + status: automated + + - id: 1.5.11 + title: Ensure core file size is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - disable_users_coredumps + + - id: 1.5.12 + title: Ensure systemd-coredump ProcessSizeMax is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - coredump_disable_backtraces + status: automated + + - id: 1.5.13 + title: Ensure systemd-coredump Storage is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - coredump_disable_storage + status: automated + + - id: 1.6.1 + title: Ensure /etc/motd is configured (Automated) + levels: + - l1_server + - l1_workstation + rules: + - banner_etc_motd_cis + - cis_banner_text=cis + status: automated + diff --git a/controls/cis_fedora.yml b/controls/cis_fedora.yml index 031e276bc3d5..a38191bc616c 100644 --- a/controls/cis_fedora.yml +++ b/controls/cis_fedora.yml @@ -369,9 +369,14 @@ controls: levels: - l1_server - l1_workstation - status: manual - related_rules: + status: partial + rules: - ensure_fedora_gpgkey_installed + notes: > + In CIS Benchmark, the requirement is manual, because of GPG keys for 3rd party repositories. + But, add the rule ensure_fedora_gpgkey_installed to the profile because the requirement 1.2.1.2 + adds ensure_gpgcheck_globally_activated which requires GPG key checking. If the Fedora + GPG key wouldn't be installed, people won't be able to install any RPM package using dnf. - id: 1.2.1.2 title: Ensure gpgcheck is configured (Automated) @@ -710,7 +715,8 @@ controls: rules: - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_banners + - dconf_login_banner_text=cis_banners + - dconf_login_banner_contents=cis_default - id: 1.8.2 title: Ensure GDM disable-user-list is configured (Automated) @@ -2077,7 +2083,8 @@ controls: - l2_workstation status: automated rules: - - accounts_passwords_pam_faillock_deny_root + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - var_accounts_passwords_pam_faillock_root_unlock_time=60 - id: 5.3.3.2.1 title: Ensure password number of changed characters is configured (Automated) @@ -2957,6 +2964,7 @@ controls: rules: - audit_rules_mac_modification_etc_selinux - audit_rules_mac_modification_usr_share + - audit_rules_mac_modification_var_lib_selinux - id: 6.3.3.24 title: Ensure successful and unsuccessful attempts to use the chcon command are collected (Automated) diff --git a/controls/cis_ocp.yml b/controls/cis_ocp.yml index e21fa1663d7d..b655dc376154 100644 --- a/controls/cis_ocp.yml +++ b/controls/cis_ocp.yml @@ -3,6 +3,8 @@ policy: CIS Red Hat OpenShift Container Platform 4 Benchmark title: CIS Red Hat OpenShift Container Platform 4 Benchmark id: cis_ocp source: https://www.cisecurity.org/benchmark/kubernetes +product: ocp4 +version: '1.7.0' levels: - id: level_1 diff --git a/controls/cis_ocp_190.yml b/controls/cis_ocp_190.yml new file mode 100644 index 000000000000..783beeeb65ad --- /dev/null +++ b/controls/cis_ocp_190.yml @@ -0,0 +1,14 @@ +--- +policy: CIS Red Hat OpenShift Container Platform 4 Benchmark +title: CIS Red Hat OpenShift Container Platform 4 Benchmark +id: cis_ocp_190 +source: https://www.cisecurity.org/benchmark/kubernetes +product: ocp4 +version: '1.9.0' +reference_type: cis + +levels: + - id: level_1 + - id: level_2 + inherits_from: + - level_1 diff --git a/controls/cis_ocp_190/section-1.yml b/controls/cis_ocp_190/section-1.yml new file mode 100644 index 000000000000..62fadd96bc76 --- /dev/null +++ b/controls/cis_ocp_190/section-1.yml @@ -0,0 +1,506 @@ +--- +controls: + - id: '1' + title: Control Plane Components + status: pending + rules: [] + controls: + - id: '1.1' + title: Master Node Configuration Files + status: automated + rules: [] + controls: + - id: 1.1.1 + title: Ensure that the API server pod specification file permissions are set to 600 + or more restrictive + status: automated + rules: + - file_permissions_kube_apiserver + levels: + - level_1 + - id: 1.1.2 + title: Ensure that the API server pod specification file ownership is set to root:root + status: automated + rules: + - file_owner_kube_apiserver + - file_groupowner_kube_apiserver + levels: + - level_1 + - id: 1.1.3 + title: Ensure that the controller manager pod specification file permissions are set + to 600 or more restrictive + status: automated + rules: + - file_permissions_kube_controller_manager + levels: + - level_1 + - id: 1.1.4 + title: Ensure that the controller manager pod specification file ownership is set to + root:root + status: automated + rules: + - file_owner_kube_controller_manager + - file_groupowner_kube_controller_manager + levels: + - level_1 + - id: 1.1.5 + title: Ensure that the scheduler pod specification file permissions are set to 600 + or more restrictive + status: automated + rules: + - file_permissions_scheduler + levels: + - level_1 + - id: 1.1.6 + title: Ensure that the scheduler pod specification file ownership is set to root:root + status: automated + rules: + - file_owner_kube_scheduler + - file_groupowner_kube_scheduler + levels: + - level_1 + - id: 1.1.7 + title: Ensure that the etcd pod specification file permissions are set to 600 or more + restrictive + status: automated + rules: + - file_permissions_etcd_member + levels: + - level_1 + - id: 1.1.8 + title: Ensure that the etcd pod specification file ownership is set to root:root + status: automated + rules: + - file_groupowner_etcd_member + - file_owner_etcd_member + levels: + - level_1 + - id: 1.1.9 + title: Ensure that the Container Network Interface file permissions are set to 600 + or more restrictive + status: automated + rules: + - file_permissions_cni_conf + - file_permissions_multus_conf + - file_permissions_ip_allocations + - file_perms_openshift_sdn_cniserver_config + - file_permissions_ovs_pid + - file_permissions_ovs_conf_db + - file_permissions_ovs_sys_id_conf + - file_permissions_ovs_conf_db_lock + - file_permissions_ovs_vswitchd_pid + - file_permissions_ovsdb_server_pid + - file_permissions_ovn_cni_server_sock + - file_permissions_ovn_db_files + levels: + - level_1 + - id: 1.1.10 + title: Ensure that the Container Network Interface file ownership is set to root:root + status: automated + rules: + - file_owner_cni_conf + - file_groupowner_cni_conf + - file_owner_multus_conf + - file_groupowner_multus_conf + - file_owner_ip_allocations + - file_groupowner_ip_allocations + - file_owner_openshift_sdn_cniserver_config + - file_groupowner_openshift_sdn_cniserver_config + - file_owner_ovs_pid + - file_groupowner_ovs_pid + - file_owner_ovs_conf_db + - file_groupowner_ovs_conf_db_openvswitch + - file_groupowner_ovs_conf_db_hugetlbfs + - file_owner_ovs_sys_id_conf + - file_groupowner_ovs_sys_id_conf_openvswitch + - file_groupowner_ovs_sys_id_conf_hugetlbfs + - file_owner_ovs_conf_db_lock + - file_groupowner_ovs_conf_db_lock_openvswitch + - file_groupowner_ovs_conf_db_lock_hugetlbfs + - file_owner_ovs_vswitchd_pid + - file_groupowner_ovs_vswitchd_pid + - file_owner_ovsdb_server_pid + - file_groupowner_ovsdb_server_pid + - file_groupowner_ovn_cni_server_sock + - file_owner_ovn_cni_server_sock + - file_owner_ovn_db_files + - file_groupowner_ovn_db_files + levels: + - level_1 + - id: 1.1.11 + title: Ensure that the etcd data directory permissions are set to 700 or more restrictive + status: automated + rules: + - file_permissions_etcd_data_dir + - file_permissions_etcd_data_files + levels: + - level_1 + - id: 1.1.12 + title: Ensure that the etcd data directory ownership is set to root:root + status: automated + rules: + - file_owner_etcd_data_dir + - file_groupowner_etcd_data_dir + - file_owner_etcd_data_files + - file_groupowner_etcd_data_files + levels: + - level_1 + - id: 1.1.13 + title: Ensure that the kubeconfig file permissions are set to 600 or more restrictive + status: automated + rules: + - file_permissions_master_admin_kubeconfigs + levels: + - level_1 + - id: 1.1.14 + title: Ensure that the kubeconfig file ownership is set to root:root + status: automated + rules: + - file_owner_master_admin_kubeconfigs + - file_groupowner_master_admin_kubeconfigs + levels: + - level_1 + - id: 1.1.15 + title: Ensure that the Scheduler kubeconfig file permissions are set to 600 or more + restrictive + status: automated + rules: + - file_permissions_scheduler_kubeconfig + levels: + - level_1 + - id: 1.1.16 + title: Ensure that the Scheduler kubeconfig file ownership is set to root:root + status: automated + rules: + - file_owner_scheduler_kubeconfig + - file_groupowner_scheduler_kubeconfig + levels: + - level_1 + - id: 1.1.17 + title: Ensure that the Controller Manager kubeconfig file permissions are set to 600 + or more restrictive + status: automated + rules: + - file_permissions_controller_manager_kubeconfig + levels: + - level_1 + - id: 1.1.18 + title: Ensure that the Controller Manager kubeconfig file ownership is set to root:root + status: automated + rules: + - file_owner_controller_manager_kubeconfig + - file_groupowner_controller_manager_kubeconfig + levels: + - level_1 + - id: 1.1.19 + title: Ensure that the OpenShift PKI directory and file ownership is set to root:root + status: automated + rules: + - file_owner_openshift_pki_key_files + - file_groupowner_openshift_pki_key_files + - file_owner_openshift_pki_cert_files + - file_groupowner_openshift_pki_cert_files + - file_owner_etcd_pki_cert_files + - file_groupowner_etcd_pki_cert_files + levels: + - level_1 + - id: 1.1.20 + title: Ensure that the OpenShift PKI certificate file permissions are set to 600 or + more restrictive + status: automated + rules: + - file_permissions_openshift_pki_cert_files + - file_permissions_etcd_pki_cert_files + levels: + - level_1 + - id: 1.1.21 + title: Ensure that the OpenShift PKI key file permissions are set to 600 + status: automated + rules: + - file_permissions_openshift_pki_key_files + levels: + - level_1 + - id: '1.2' + title: API Server + status: pending + rules: [] + controls: + - id: 1.2.1 + title: Ensure that anonymous requests are authorized + status: automated + rules: + - api_server_anonymous_auth + levels: + - level_1 + - id: 1.2.2 + title: Use https for kubelet connections + status: automated + rules: + - api_server_https_for_kubelet_conn + - api_server_openshift_https_serving_cert + - api_server_oauth_https_serving_cert + levels: + - level_1 + - id: 1.2.3 + title: Ensure that the kubelet uses certificates to authenticate + status: automated + rules: + - api_server_kubelet_client_cert + - api_server_kubelet_client_key + levels: + - level_1 + - id: 1.2.4 + title: Verify that the kubelet certificate authority is set as appropriate + status: automated + rules: + - api_server_kubelet_certificate_authority + levels: + - level_1 + - id: 1.2.5 + title: Ensure that the --authorization-mode argument is not set to AlwaysAllow + status: automated + rules: + - api_server_auth_mode_no_aa + levels: + - level_1 + - id: 1.2.6 + title: Verify that RBAC is enabled + status: automated + rules: + - api_server_auth_mode_rbac + levels: + - level_1 + - id: 1.2.7 + title: Ensure that the APIPriorityAndFairness feature gate is enabled + status: inherently met + rules: [] + levels: + - level_1 + - id: 1.2.8 + title: Ensure that the admission control plugin AlwaysAdmit is not set + status: automated + rules: + - api_server_admission_control_plugin_alwaysadmit + levels: + - level_1 + - id: 1.2.9 + title: Ensure that the admission control plugin AlwaysPullImages is not set + status: automated + rules: + - api_server_admission_control_plugin_alwayspullimages + levels: + - level_1 + - id: 1.2.10 + title: Ensure that the admission control plugin ServiceAccount is set + status: automated + rules: + - api_server_admission_control_plugin_service_account + levels: + - level_1 + - id: 1.2.11 + title: Ensure that the admission control plugin NamespaceLifecycle is set + status: automated + rules: + - api_server_admission_control_plugin_namespacelifecycle + levels: + - level_1 + - id: 1.2.12 + title: Ensure that the admission control plugin SecurityContextConstraint is set + status: automated + rules: + - api_server_admission_control_plugin_scc + levels: + - level_1 + - id: 1.2.13 + title: Ensure that the admission control plugin NodeRestriction is set + status: automated + rules: + - api_server_admission_control_plugin_noderestriction + levels: + - level_1 + - id: 1.2.14 + title: Ensure that the --insecure-bind-address argument is not set + status: automated + rules: + - api_server_insecure_bind_address + levels: + - level_1 + - id: 1.2.15 + title: Ensure that the --insecure-port argument is set to 0 + status: inherently met + rules: [] + levels: + - level_1 + - id: 1.2.16 + title: Ensure that the --secure-port argument is not set to 0 + status: automated + rules: + - api_server_bind_address + levels: + - level_1 + - id: 1.2.17 + title: Ensure that the healthz endpoint is protected by RBAC + status: automated + rules: + - api_server_profiling_protected_by_rbac + levels: + - level_1 + - id: 1.2.18 + title: Ensure that the --audit-log-path argument is set + status: automated + rules: + - api_server_audit_log_path + - openshift_api_server_audit_log_path + levels: + - level_1 + - id: 1.2.19 + title: Ensure that the audit logs are forwarded off the cluster for retention + status: automated + rules: + - audit_log_forwarding_enabled + - audit_log_forwarding_webhook + levels: + - level_1 + - id: 1.2.20 + title: Ensure that the maximumRetainedFiles argument is set to 10 or as appropriate + status: automated + rules: + - api_server_audit_log_maxbackup + - ocp_api_server_audit_log_maxbackup + levels: + - level_1 + - id: 1.2.21 + title: Configure Kubernetes API Server Maximum Audit Log Size + status: automated + rules: + - api_server_audit_log_maxsize + - ocp_api_server_audit_log_maxsize + levels: + - level_1 + - id: 1.2.22 + title: Ensure that the --request-timeout argument is set + status: automated + rules: + - api_server_request_timeout + levels: + - level_1 + - id: 1.2.23 + title: Ensure that the --service-account-lookup argument is set to true + status: automated + rules: + - api_server_service_account_lookup + levels: + - level_1 + - id: 1.2.24 + title: Ensure that the --service-account-key-file argument is set as appropriate + status: automated + rules: + - api_server_service_account_public_key + levels: + - level_1 + - id: 1.2.25 + title: Ensure that the --etcd-certfile and --etcd-keyfile arguments are set as appropriate + status: automated + rules: + - api_server_etcd_cert + - api_server_etcd_key + levels: + - level_1 + - id: 1.2.26 + title: Ensure that the --tls-cert-file and --tls-private-key-file arguments are set + as appropriate + status: automated + rules: + - api_server_tls_cert + - api_server_tls_private_key + levels: + - level_1 + - id: 1.2.27 + title: Ensure that the --client-ca-file argument is set as appropriate + status: automated + rules: + - api_server_client_ca + levels: + - level_1 + - id: 1.2.28 + title: Ensure that the --etcd-cafile argument is set as appropriate + status: automated + rules: + - api_server_etcd_ca + levels: + - level_1 + - id: 1.2.29 + title: Ensure that encryption providers are appropriately configured + status: automated + rules: + - api_server_encryption_provider_cipher + levels: + - level_1 + - id: 1.2.30 + title: Ensure that the API Server only makes use of Strong Cryptographic Ciphers + status: automated + rules: + - api_server_tls_security_profile_not_old + - api_server_tls_security_profile_custom_min_tls_version + levels: + - level_1 + - id: 1.2.31 + title: Ensure unsupported configuration overrides are not used + status: pending + rules: + - api_server_no_unsupported_config_overrides + - api_server_kube_no_unsupported_config_overrides + levels: + - level_1 + - id: '1.3' + title: Controller Manager + status: pending + rules: [] + controls: + - id: 1.3.1 + title: Ensure that controller manager healthz endpoints are protected by RBAC + status: automated + rules: + - rbac_debug_role_protects_pprof + levels: + - level_1 + - id: 1.3.2 + title: Ensure that the --use-service-account-credentials argument is set to true + status: automated + rules: + - controller_use_service_account + levels: + - level_1 + - id: 1.3.3 + title: Ensure that the --service-account-private-key-file argument is set as appropriate + status: automated + rules: + - controller_service_account_private_key + levels: + - level_1 + - id: 1.3.4 + title: Ensure that the --root-ca-file argument is set as appropriate + status: automated + rules: + - controller_service_account_ca + levels: + - level_1 + - id: '1.4' + title: Scheduler + status: automated + rules: [] + controls: + - id: 1.4.1 + title: Ensure that the healthz endpoints for the scheduler are protected by RBAC + status: automated + rules: + - scheduler_profiling_protected_by_rbac + levels: + - level_1 + - id: 1.4.2 + title: Verify that the scheduler API service is protected by RBAC + status: automated + rules: + - scheduler_service_protected_by_rbac + levels: + - level_1 diff --git a/controls/cis_ocp_190/section-2.yml b/controls/cis_ocp_190/section-2.yml new file mode 100644 index 000000000000..d42cc9d46111 --- /dev/null +++ b/controls/cis_ocp_190/section-2.yml @@ -0,0 +1,58 @@ +--- +controls: + - id: '2' + title: etcd + status: pending + rules: [] + controls: + - id: '2.1' + title: Ensure that the --cert-file and --key-file arguments are set as appropriate + status: automated + rules: + - etcd_cert_file + - etcd_key_file + levels: + - level_1 + - id: '2.2' + title: Ensure that the --client-cert-auth argument is set to true + status: automated + rules: + - etcd_client_cert_auth + levels: + - level_1 + - id: '2.3' + title: Ensure that the --auto-tls argument is not set to true + status: automated + rules: + - etcd_auto_tls + levels: + - level_1 + - id: '2.4' + title: Ensure that the --peer-cert-file and --peer-key-file arguments are set as appropriate + status: automated + rules: + - etcd_peer_cert_file + - etcd_peer_key_file + levels: + - level_1 + - id: '2.5' + title: Ensure that the --peer-client-cert-auth argument is set to true + status: automated + rules: + - etcd_peer_client_cert_auth + levels: + - level_1 + - id: '2.6' + title: Ensure that the --peer-auto-tls argument is not set to true + status: automated + rules: + - etcd_peer_auto_tls + levels: + - level_1 + - id: '2.7' + title: Ensure that a unique Certificate Authority is used for etcd + status: automated + rules: + - etcd_unique_ca + levels: + - level_2 diff --git a/controls/cis_ocp_190/section-3.yml b/controls/cis_ocp_190/section-3.yml new file mode 100644 index 000000000000..3c5dbdc4c0e5 --- /dev/null +++ b/controls/cis_ocp_190/section-3.yml @@ -0,0 +1,39 @@ +--- +controls: + - id: '3' + title: Control Plane Configuration + status: pending + rules: [] + controls: + - id: '3.1' + title: Authentication and Authorization + status: automated + rules: [] + controls: + - id: 3.1.1 + title: Client certificate authentication should not be used for users + status: automated + rules: + - idp_is_configured + - kubeadmin_removed + levels: + - level_2 + - id: '3.2' + title: Logging + status: automated + rules: [] + controls: + - id: 3.2.1 + title: Ensure that a minimal audit policy is created + status: automated + rules: + - audit_logging_enabled + levels: + - level_1 + - id: 3.2.2 + title: Ensure that the audit policy covers key security concerns + status: automated + rules: + - audit_profile_set + levels: + - level_2 diff --git a/controls/cis_ocp_190/section-4.yml b/controls/cis_ocp_190/section-4.yml new file mode 100644 index 000000000000..4343034dbc67 --- /dev/null +++ b/controls/cis_ocp_190/section-4.yml @@ -0,0 +1,191 @@ +--- +controls: + - id: '4' + title: Worker Nodes + status: pending + rules: [] + controls: + - id: '4.1' + title: Worker Node Configuration Files + status: pending + rules: [] + controls: + - id: 4.1.1 + title: Ensure that the kubelet service file permissions are set to 644 or more restrictive + status: automated + rules: + - file_permissions_worker_service + levels: + - level_1 + - id: 4.1.2 + title: Ensure that the kubelet service file ownership is set to root:root + status: automated + rules: + - file_owner_worker_service + - file_groupowner_worker_service + levels: + - level_1 + - id: 4.1.3 + title: If proxy kube proxy configuration file exists ensure permissions are set to + 644 or more restrictive + status: automated + rules: + - file_permissions_proxy_kubeconfig + levels: + - level_1 + - id: 4.1.4 + title: If proxy kubeconfig file exists ensure ownership is set to root:root + status: automated + rules: + - file_owner_proxy_kubeconfig + - file_groupowner_proxy_kubeconfig + levels: + - level_1 + - id: 4.1.5 + title: Ensure that the --kubeconfig kubelet.conf file permissions are set to 644 or + more restrictive + status: automated + rules: + - file_permissions_kubelet_conf + levels: + - level_1 + - id: 4.1.6 + title: Ensure that the --kubeconfig kubelet.conf file ownership is set to root:root + status: automated + rules: + - file_groupowner_kubelet_conf + - file_owner_kubelet_conf + #- file_groupowner_kubelet + - file_owner_kubelet + levels: + - level_1 + - id: 4.1.7 + title: Ensure that the certificate authorities file permissions are set to 644 or more + restrictive + status: automated + rules: + - file_permissions_worker_ca + levels: + - level_1 + - id: 4.1.8 + title: Ensure that the client certificate authorities file ownership is set to root:root + status: automated + rules: + - file_owner_worker_ca + - file_groupowner_worker_ca + levels: + - level_1 + - id: 4.1.9 + title: Ensure that the kubelet --config configuration file has permissions set to 600 + or more restrictive + status: automated + rules: + - file_permissions_worker_kubeconfig + levels: + - level_1 + - id: 4.1.10 + title: Ensure that the kubelet configuration file ownership is set to root:root + status: automated + rules: + - file_owner_worker_kubeconfig + - file_groupowner_worker_kubeconfig + levels: + - level_1 + - id: '4.2' + title: Kubelet + status: pending + rules: [] + controls: + - id: 4.2.1 + title: Activate Garbage collection in OpenShift Container Platform 4, as appropriate + status: automated + rules: + - kubelet_eviction_thresholds_set_hard_memory_available + - kubelet_eviction_thresholds_set_hard_nodefs_available + - kubelet_eviction_thresholds_set_hard_nodefs_inodesfree + - kubelet_eviction_thresholds_set_hard_imagefs_available + levels: + - level_1 + - id: 4.2.2 + title: Ensure that the --anonymous-auth argument is set to false + status: automated + rules: + - kubelet_anonymous_auth + levels: + - level_1 + - id: 4.2.3 + title: Ensure that the --authorization-mode argument is not set to AlwaysAllow + status: automated + rules: + - kubelet_authorization_mode + levels: + - level_1 + - id: 4.2.4 + title: Ensure that the --client-ca-file argument is set as appropriate + status: automated + rules: + - kubelet_configure_client_ca + levels: + - level_1 + - id: 4.2.5 + title: Verify that the read only port is not used or is set to 0 + status: automated + rules: + - kubelet_disable_readonly_port + levels: + - level_1 + - id: 4.2.6 + title: Ensure that the --streaming-connection-idle-timeout argument is not set to 0 + status: automated + rules: + - kubelet_enable_streaming_connections + levels: + - level_1 + - id: 4.2.7 + title: Ensure that the --make-iptables-util-chains argument is set to true + status: automated + rules: + - kubelet_enable_iptables_util_chains + levels: + - level_1 + - id: 4.2.8 + title: Ensure that the kubeAPIQPS [--event-qps] argument is set to a level which + ensures appropriate event capture + status: automated + rules: + - kubelet_configure_event_creation + - var_event_record_qps=50 + levels: + - level_2 + - id: 4.2.9 + title: Ensure that the --tls-cert-file and --tls-private-key-file arguments are set + as appropriate + status: automated + rules: + - kubelet_configure_tls_cert + - kubelet_configure_tls_key + levels: + - level_1 + - id: 4.2.10 + title: Ensure that the --rotate-certificates argument is not set to false + status: automated + rules: + - kubelet_enable_client_cert_rotation + - kubelet_enable_cert_rotation + levels: + - level_1 + - id: 4.2.11 + title: Verify that the RotateKubeletServerCertificate argument is set to true + status: automated + rules: + - kubelet_enable_server_cert_rotation + levels: + - level_1 + - id: 4.2.12 + title: Ensure that the Kubelet only makes use of Strong Cryptographic Ciphers + status: automated + rules: + - kubelet_configure_tls_cipher_suites + - ingress_controller_tls_cipher_suites + levels: + - level_1 diff --git a/controls/cis_ocp_190/section-5.yml b/controls/cis_ocp_190/section-5.yml new file mode 100644 index 000000000000..2e8312954f91 --- /dev/null +++ b/controls/cis_ocp_190/section-5.yml @@ -0,0 +1,216 @@ +--- +controls: + - id: '5' + title: Policies + status: partial + rules: [] + controls: + - id: '5.1' + title: RBAC and Service Accounts + status: manual + rules: [] + controls: + - id: 5.1.1 + title: Ensure that the cluster-admin role is only used where required + status: manual + rules: + - rbac_limit_cluster_admin + levels: + - level_1 + - id: 5.1.2 + title: Minimize access to secrets + status: manual + rules: + - rbac_limit_secrets_access + levels: + - level_1 + - id: 5.1.3 + title: Minimize wildcard use in Roles and ClusterRoles + status: manual + rules: + - rbac_wildcard_use + levels: + - level_1 + - id: 5.1.4 + title: Minimize access to create pods + status: manual + rules: + - rbac_pod_creation_access + levels: + - level_1 + - id: 5.1.5 + title: Ensure that default service accounts are not actively used. + status: manual + rules: + - accounts_unique_service_account + levels: + - level_1 + - id: 5.1.6 + title: Ensure that Service Account Tokens are only mounted where necessary + status: manual + rules: + - accounts_restrict_service_account_tokens + levels: + - level_1 + - id: '5.2' + title: Security Context Constraints + status: partial + rules: [] + controls: + - id: 5.2.1 + title: Minimize the admission of privileged containers + status: manual + rules: + - scc_limit_privileged_containers + levels: + - level_1 + - id: 5.2.2 + title: Minimize the admission of containers wishing to share the host process ID namespace + status: manual + rules: + - scc_limit_process_id_namespace + levels: + - level_1 + - id: 5.2.3 + title: Minimize the admission of containers wishing to share the host IPC namespace + status: manual + rules: + - scc_limit_ipc_namespace + levels: + - level_1 + - id: 5.2.4 + title: Minimize the admission of containers wishing to share the host network namespace + status: manual + rules: + - scc_limit_network_namespace + levels: + - level_1 + - id: 5.2.5 + title: Minimize the admission of containers with allowPrivilegeEscalation + status: manual + rules: + - scc_limit_privilege_escalation + levels: + - level_1 + - id: 5.2.6 + title: Minimize the admission of root containers + status: manual + rules: + - scc_limit_root_containers + levels: + - level_2 + - id: 5.2.7 + title: Minimize the admission of containers with the NET_RAW capability + status: manual + rules: + - scc_limit_net_raw_capability + levels: + - level_1 + - id: 5.2.8 + title: Minimize the admission of containers with added capabilities + status: automated + rules: + - scc_limit_container_allowed_capabilities + levels: + - level_1 + - id: 5.2.9 + title: Minimize the admission of containers with capabilities assigned + status: manual + rules: + - scc_drop_container_capabilities + levels: + - level_2 + - id: 5.2.10 + title: Minimize access to privileged Security Context Constraints + status: manual + rules: + - rbac_least_privilege + levels: + - level_2 + - id: '5.3' + title: Network Policies and CNI + status: partial + rules: [] + controls: + - id: 5.3.1 + title: Ensure that the CNI in use supports Network Policies + status: automated + rules: + - configure_network_policies + levels: + - level_1 + - id: 5.3.2 + title: Ensure that all Namespaces have Network Policies defined + status: partial + rules: + - configure_network_policies_namespaces + - configure_network_policies_hypershift_hosted + levels: + - level_2 + - id: '5.4' + title: Secrets Management + status: manual + rules: [] + controls: + - id: 5.4.1 + title: Prefer using secrets as files over secrets as environment variables + status: manual + rules: + - secrets_no_environment_variables + levels: + - level_1 + - id: 5.4.2 + title: Consider external secret storage + status: manual + rules: + - secrets_consider_external_storage + levels: + - level_2 + - id: '5.5' + title: Extensible Admission Control + status: automated + rules: [] + controls: + - id: 5.5.1 + title: Configure Image Provenance using image controller configuration parameters + status: automated + rules: + - ocp_allowed_registries + - ocp_allowed_registries_for_import + - ocp_insecure_registries + - ocp_insecure_allowed_registries_for_import + levels: + - level_2 + - id: '5.7' + title: General Policies + status: manual + rules: [] + controls: + - id: 5.7.1 + title: Create administrative boundaries between resources using namespaces + status: manual + rules: + - general_namespaces_in_use + levels: + - level_1 + - id: 5.7.2 + title: Ensure that the seccomp profile is set to docker/default in your pod definitions + status: manual + rules: + - general_default_seccomp_profile + levels: + - level_2 + - id: 5.7.3 + title: Apply Security Context to Your Pods and Containers + status: manual + rules: + - general_apply_scc + levels: + - level_2 + - id: 5.7.4 + title: The default namespace should not be used + status: manual + rules: + - general_default_namespace_use + levels: + - level_2 diff --git a/controls/cis_sle12.yml b/controls/cis_sle12.yml index d842d6e6c3c6..3e4d682ce3e6 100644 --- a/controls/cis_sle12.yml +++ b/controls/cis_sle12.yml @@ -457,6 +457,7 @@ controls: rules: - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: 1.8.1.2 title: Ensure local login warning banner is configured properly (Automated) @@ -467,6 +468,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: 1.8.1.3 title: Ensure remote login warning banner is configured properly (Automated) @@ -477,6 +479,7 @@ controls: rules: - banner_etc_issue_net - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: 1.8.1.4 title: Ensure permissions on /etc/motd are configured (Automated) @@ -535,7 +538,8 @@ controls: - dconf_gnome_disable_user_list - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_default + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - id: 2.1.1 title: Ensure xinetd is not installed (Automated) diff --git a/controls/cis_sle15.yml b/controls/cis_sle15.yml index 97c61f63374e..c96352ef9329 100644 --- a/controls/cis_sle15.yml +++ b/controls/cis_sle15.yml @@ -455,6 +455,7 @@ controls: rules: - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: 1.8.1.2 title: Ensure local login warning banner is configured properly (Automated) @@ -465,6 +466,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: 1.8.1.3 title: Ensure remote login warning banner is configured properly (Automated) @@ -475,6 +477,7 @@ controls: rules: - banner_etc_issue_net - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: 1.8.1.4 title: Ensure permissions on /etc/motd are configured (Automated) @@ -532,7 +535,8 @@ controls: - enable_dconf_user_profile - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_default + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - id: 2.1.1 title: Ensure xinetd is not installed (Automated) @@ -1492,9 +1496,7 @@ controls: levels: - l2_server - l2_workstation - status: automated - rules: - - audit_rules_immutable + status: manual - id: 4.2.1.1 title: Ensure rsyslog is installed (Automated) diff --git a/controls/cis_ubuntu2204.yml b/controls/cis_ubuntu2204.yml index 84f3287f32ee..997016fd1e97 100644 --- a/controls/cis_ubuntu2204.yml +++ b/controls/cis_ubuntu2204.yml @@ -528,7 +528,8 @@ controls: - l1_server - l1_workstation rules: - - login_banner_text=cis_default + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text status: automated diff --git a/controls/cis_ubuntu2404.yml b/controls/cis_ubuntu2404.yml index 58c756c81c9d..d4e1dfde39c3 100644 --- a/controls/cis_ubuntu2404.yml +++ b/controls/cis_ubuntu2404.yml @@ -561,7 +561,8 @@ controls: - l1_server - l1_workstation rules: - - login_banner_text=cis_default + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text status: automated diff --git a/controls/cusp_fedora.yml b/controls/cusp_fedora.yml index 85e23df5a2fe..ad27565aee67 100644 --- a/controls/cusp_fedora.yml +++ b/controls/cusp_fedora.yml @@ -271,6 +271,7 @@ controls: # chrony - chronyd_client_only - chronyd_no_chronyc_network + - chronyd_configure_local_socket - chronyd_or_ntpd_set_maxpoll - chronyd_run_as_chrony_user - chronyd_specify_remote_server diff --git a/controls/e8.yml b/controls/e8.yml index c2613a4b1d48..cb6acca5a523 100644 --- a/controls/e8.yml +++ b/controls/e8.yml @@ -179,4 +179,7 @@ controls: - package_firewalld_installed - service_firewalld_enabled - network_sniffer_disabled + + ### Services + - service_kdump_disabled status: partial # Always will be partial as more could be done diff --git a/controls/general_sle15.yml b/controls/general_sle15.yml index 73dca83f3e70..f637cbbd87d4 100644 --- a/controls/general_sle15.yml +++ b/controls/general_sle15.yml @@ -470,6 +470,7 @@ controls: rules: - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: SLES-15-151050030 title: Modify the System Login Banner @@ -479,6 +480,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: SLES-15-151050045 title: Modify the System Login Banner for Remote Connections @@ -488,6 +490,7 @@ controls: rules: - banner_etc_issue_net - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: SLES-15-151050060 title: Configure access to the Message of the Day Banner @@ -535,7 +538,8 @@ controls: rules: - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_default + - dconf_login_banner_text=cis_default + - dconf_login_banner_contents=cis_default - id: SLES-15-151200135 title: Disable the GDM Login User List diff --git a/controls/general_slmicro5.yml b/controls/general_slmicro5.yml index 8a83a0b428fb..ac887def5ee4 100644 --- a/controls/general_slmicro5.yml +++ b/controls/general_slmicro5.yml @@ -269,6 +269,7 @@ controls: rules: - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: SLEM-5-SET-08010200 title: Modify the System Login Banner @@ -278,6 +279,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: SLEM-5-SET-08010300 title: Modify the System Login Banner for Remote Connections @@ -287,6 +289,7 @@ controls: rules: - banner_etc_issue_net - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: SLEM-5-SET-08010400 title: Verify Ownership and Permissions of/on Message of the Day Banner @@ -1021,6 +1024,7 @@ controls: rules: - banner_etc_issue - login_banner_text=dod_banners + - login_banner_contents=dod_default - sshd_enable_warning_banner status: automated diff --git a/controls/hipaa.yml b/controls/hipaa.yml index ccc5b6244edb..5ad2961b3e17 100644 --- a/controls/hipaa.yml +++ b/controls/hipaa.yml @@ -145,6 +145,8 @@ controls: - auditd_data_retention_flush - coreos_audit_option - grub2_audit_argument + - grub2_audit_backlog_limit_argument + - var_audit_backlog_limit=8192 - package_audit-audispd-plugins_installed - package_audit_installed - service_auditd_enabled @@ -1248,6 +1250,7 @@ controls: - auditd_data_retention_max_log_file_action - auditd_data_retention_max_log_file_action_stig - auditd_data_retention_space_left_action + - package_postfix_installed - package_rsyslog_installed - service_rsyslog_enabled - partition_for_var_log_audit diff --git a/controls/ism_o.yml b/controls/ism_o.yml index 28b1cde5d233..685333538b0c 100644 --- a/controls/ism_o.yml +++ b/controls/ism_o.yml @@ -475,6 +475,7 @@ controls: - package_fapolicyd_installed - package_firewalld_installed - package_rsyslog_installed + - package_rsyslog-gnutls_installed - package_squid_removed - package_telnet_removed - package_telnet-server_removed @@ -507,6 +508,7 @@ controls: - package_ypbind_removed - package_xinetd_removed - service_xinetd_disabled + - service_kdump_disabled - id: '1416' title: 'A software firewall is implemented on workstations and servers to restrict inbound and diff --git a/controls/nist_rhcos4.yml b/controls/nist_rhcos4.yml index 02690cb34dc1..b152c281059e 100644 --- a/controls/nist_rhcos4.yml +++ b/controls/nist_rhcos4.yml @@ -1228,6 +1228,7 @@ controls: rules: - banner_etc_issue - login_banner_text=dod_banners + - login_banner_contents=dod_default description: "The information system:\n a. Displays to users [Assignment: organization-defined\ \ system use notification message or banner] before granting access to the system that provides\ \ privacy and security notices consistent with applicable federal laws, Executive Orders, directives,\ @@ -5221,6 +5222,7 @@ controls: https://issues.redhat.com/browse/CMP-274 rules: - chronyd_no_chronyc_network + - chronyd_configure_local_socket description: |- The organization: (a) Reviews the information system [Assignment: organization-defined frequency] to identify unnecessary and/or nonsecure functions, ports, protocols, and services; and diff --git a/controls/pcidss_3.yml b/controls/pcidss_3.yml index f0899ba73887..fa267acdaa68 100644 --- a/controls/pcidss_3.yml +++ b/controls/pcidss_3.yml @@ -2130,6 +2130,7 @@ controls: - auditd_data_retention_space_left - auditd_data_retention_admin_space_left_action - auditd_data_retention_action_mail_acct + - package_postfix_installed - id: Req-10.8 title: 10.8 Ensure that security policies and operational procedures for monitoring all access diff --git a/controls/pcidss_4.yml b/controls/pcidss_4.yml index 8db6d14144e7..a9b4b5c4aa49 100644 --- a/controls/pcidss_4.yml +++ b/controls/pcidss_4.yml @@ -2967,6 +2967,7 @@ controls: - auditd_data_retention_admin_space_left_action - auditd_data_retention_space_left - auditd_data_retention_space_left_action + - package_postfix_installed - package_logrotate_installed - timer_logrotate_enabled related_rules: diff --git a/controls/srg_gpos.yml b/controls/srg_gpos.yml index 5be978311df7..c44f13af6f94 100644 --- a/controls/srg_gpos.yml +++ b/controls/srg_gpos.yml @@ -26,5 +26,6 @@ controls: - var_accounts_authorized_local_users_regex=rhel9 - var_account_disable_post_pw_expiration=35 - login_banner_text=dod_banners + - login_banner_contents=dod_default - var_authselect_profile=sssd - var_auditd_name_format=stig diff --git a/controls/srg_gpos/SRG-OS-000046-GPOS-00022.yml b/controls/srg_gpos/SRG-OS-000046-GPOS-00022.yml index 43b058638fff..8d8807a384f1 100644 --- a/controls/srg_gpos/SRG-OS-000046-GPOS-00022.yml +++ b/controls/srg_gpos/SRG-OS-000046-GPOS-00022.yml @@ -5,6 +5,7 @@ controls: title: {{{ full_name }}} must alert the ISSO and SA (at a minimum) in the event of an audit processing failure. rules: + - package_postfix_installed - postfix_client_configure_mail_alias - postfix_client_configure_mail_alias_postmaster - var_postfix_root_mail_alias=mil_sysadmin diff --git a/controls/srg_gpos/SRG-OS-000480-GPOS-00227.yml b/controls/srg_gpos/SRG-OS-000480-GPOS-00227.yml index 38c2a7c0a869..175ace621bc0 100644 --- a/controls/srg_gpos/SRG-OS-000480-GPOS-00227.yml +++ b/controls/srg_gpos/SRG-OS-000480-GPOS-00227.yml @@ -245,7 +245,6 @@ controls: - display_login_attempts - installed_OS_is_vendor_supported - selinux_all_devicefiles_labeled - - chrony_set_nts - tftp_uses_secure_mode_systemd - grub2_pti_argument - chronyd_client_only diff --git a/controls/std_kylinserver10.yml b/controls/std_kylinserver10.yml index 8e101a908189..785c64550d9e 100644 --- a/controls/std_kylinserver10.yml +++ b/controls/std_kylinserver10.yml @@ -119,6 +119,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: 1.14 title: ensure-message-of-the-day-is-configured-properly @@ -127,7 +128,8 @@ controls: status: automated rules: - banner_etc_motd - - login_banner_text=cis_banners + - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: 1.15 title: Ensure sshd PermitRootLogin is disabled (Automated) diff --git a/controls/std_tencentos4.yml b/controls/std_tencentos4.yml index 06aa7e4656de..b08775cbce91 100644 --- a/controls/std_tencentos4.yml +++ b/controls/std_tencentos4.yml @@ -114,6 +114,7 @@ controls: rules: - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - id: 1.4.2 title: Ensure local login warning banner is configured properly @@ -123,6 +124,7 @@ controls: rules: - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - id: 1.4.3 title: Ensure remote login warning banner is configured properly @@ -132,6 +134,7 @@ controls: rules: - banner_etc_issue_net - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: 1.4.4 title: Ensure permissions on /etc/motd are configured diff --git a/controls/stig_al2023.yml b/controls/stig_al2023.yml new file mode 100644 index 000000000000..823858ec3599 --- /dev/null +++ b/controls/stig_al2023.yml @@ -0,0 +1,1843 @@ +policy: "Amazon Linux 2023 Security Technical Implementation Guide" +title: "Amazon Linux 2023 Security Technical Implementation Guide" +id: stig_al2023 +source: https://www.cyber.mil/stigs/downloads/ +version: V1R1 +reference_type: stigid +product: al2023 + +levels: + - id: high + - id: medium + - id: low + +controls: + - id: AZLX-23-000100 + levels: + - high + title: Amazon Linux 2023 local disk partitions must implement cryptographic mechanisms to prevent unauthorized disclosure or modification of all information that requires at rest protection. + rules: + - encrypt_partitions + status: automated + + - id: AZLX-23-000110 + levels: + - medium + title: Amazon Linux 2023 must ensure cryptographic verification of vendor + software packages. + rules: [] + status: pending + + - id: AZLX-23-000115 + levels: + - high + title: Amazon Linux 2023 must check the GPG signature of locally installed + software packages before installation. + rules: + - ensure_gpgcheck_local_packages + status: automated + + - id: AZLX-23-000120 + levels: + - high + title: Amazon Linux 2023 must check the GPG signature of software packages + originating from external software repositories before installation. + rules: + - ensure_gpgcheck_globally_activated + status: automated + + - id: AZLX-23-000125 + levels: + - high + title: + Amazon Linux 2023 must have GPG signature verification enabled for all + software repositories. + rules: + - ensure_gpgcheck_never_disabled + status: automated + + - id: AZLX-23-000130 + levels: + - high + title: Amazon Linux 2023 must be a vendor-supported release. + rules: + - installed_OS_is_vendor_supported + status: automated + + - id: AZLX-23-000135 + levels: + - medium + title: Amazon Linux 2023 systemd-journald service must be enabled. + rules: + - service_systemd-journald_enabled + status: automated + + - id: AZLX-23-000200 + levels: + - medium + title: Amazon Linux 2023 must restrict access to the kernel message buffer. + rules: + - sysctl_kernel_dmesg_restrict + status: automated + + - id: AZLX-23-000205 + levels: + - medium + title: Amazon Linux 2023 must prevent kernel profiling by nonprivileged users. + rules: + - sysctl_kernel_perf_event_paranoid + status: automated + + - id: AZLX-23-000210 + levels: + - medium + title: Amazon Linux 2023 must restrict exposed kernel pointer addresses + access. + rules: + - sysctl_kernel_kptr_restrict + status: automated + + - id: AZLX-23-000215 + levels: + - medium + title: Amazon Linux 2023 must disable access to network bpf system call from + nonprivileged processes. + rules: + - sysctl_kernel_unprivileged_bpf_disabled + status: automated + + - id: AZLX-23-000220 + levels: + - medium + title: Amazon Linux 2023 must restrict usage of ptrace to descendant + processes. + rules: + - sysctl_kernel_yama_ptrace_scope + status: automated + + - id: AZLX-23-000225 + levels: + - medium + title: Amazon Linux 2023 must implement address space layout randomization + (ASLR) to protect its memory from unauthorized code execution. + rules: + - sysctl_kernel_randomize_va_space + status: automated + + - id: AZLX-23-000300 + levels: + - high + title: Amazon Linux 2023 must not have the vsftpd package installed. + rules: + - package_vsftpd_removed + status: automated + + - id: AZLX-23-000305 + levels: + - medium + title: Amazon Linux 2023 must not have the sendmail package installed. + rules: + - package_sendmail_removed + status: automated + + - id: AZLX-23-000310 + levels: + - medium + title: Amazon Linux 2023 must not have the nfs-utils package installed. + rules: + - package_nfs-utils_removed + status: automated + + - id: AZLX-23-000315 + levels: + - medium + title: Amazon Linux 2023 must not have the telnet-server package installed. + rules: + - package_telnet-server_removed + status: automated + + - id: AZLX-23-000320 + levels: + - medium + title: Amazon Linux 2023 must not have the gssproxy package installed. + rules: + - package_gssproxy_removed + status: automated + + - id: AZLX-23-001000 + levels: + - medium + title: Amazon Linux 2023 must have the sudo package installed. + rules: + - package_sudo_installed + status: automated + + - id: AZLX-23-001005 + levels: + - medium + title: Amazon Linux 2023 must not be configured to bypass password + requirements for privilege escalation. + rules: + - disallow_bypass_password_sudo + status: automated + + - id: AZLX-23-001010 + levels: + - medium + title: Amazon Linux 2023 must require reauthentication when using the "sudo" + command. + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=always_prompt + status: automated + + - id: AZLX-23-001015 + levels: + - medium + title: Amazon Linux 2023 must require users to reauthenticate for privilege + escalation. + rules: + - sudo_remove_no_authenticate + status: automated + + - id: AZLX-23-001020 + levels: + - medium + title: Amazon Linux 2023 must require users to provide a password for + privilege escalation. + rules: + - sudo_remove_nopasswd + status: automated + + - id: AZLX-23-002610 + levels: + - medium + title: Amazon Linux 2023 must implement nonexecutable data to protect its memory from unauthorized code execution. + rules: + - bios_enable_execution_restrictions + status: automated + + - id: AZLX-23-001025 + levels: + - medium + title: Amazon Linux 2023 must have the audit package installed. + rules: + - package_audit_installed + status: automated + + - id: AZLX-23-001030 + levels: + - medium + title: + Amazon Linux 2023 must produce audit records containing information to + establish what type of events occurred. + rules: + - service_auditd_enabled + status: automated + + - id: AZLX-23-001035 + levels: + - medium + title: Amazon Linux 2023 audispd-plugins package must be installed. + rules: + - package_audispd-plugins_installed + status: automated + + - id: AZLX-23-001040 + levels: + - medium + title: Amazon Linux 2023 must have the rsyslog package installed. + rules: + - package_rsyslog_installed + status: automated + + - id: AZLX-23-001045 + levels: + - medium + title: Amazon Linux 2023 must monitor remote access methods. + rules: + - rsyslog_remote_access_monitoring + status: automated + + - id: AZLX-23-001050 + levels: + - medium + title: Amazon Linux 2023 must have the chrony package installed. + rules: + - package_chrony_installed + status: automated + + - id: AZLX-23-001055 + levels: + - medium + title: Amazon Linux 2023 chronyd service must be enabled. + rules: + - service_chronyd_enabled + status: automated + + - id: AZLX-23-001060 + levels: + - medium + title: Amazon Linux 2023 must have the Advanced Intrusion Detection + Environment (AIDE) package installed. + rules: + - package_aide_installed + - aide_build_database + status: automated + + - id: AZLX-23-001065 + levels: + - medium + title: Amazon Linux 2023 must routinely check the baseline configuration for + unauthorized changes and notify the system administrator when anomalies in + the operation of any security functions are discovered. + rules: + - aide_scan_notification + status: automated + + - id: AZLX-23-001070 + levels: + - medium + title: Amazon Linux 2023 must use cryptographic mechanisms to protect the + integrity of audit tools. + rules: + - aide_check_audit_tools + status: automated + + - id: AZLX-23-001075 + levels: + - medium + title: Amazon Linux 2023 must have the firewalld package installed. + rules: + - package_firewalld_installed + status: automated + + - id: AZLX-23-001080 + levels: + - medium + title: Amazon Linux 2023 must have the firewalld servicew active. + rules: + - service_firewalld_enabled + status: automated + + - id: AZLX-23-001085 + levels: + - medium + title: Amazon Linux 2023 must be configured to disable nonessential + capabilities. + rules: + - firewalld_sshd_port_enabled + status: automated + + - id: AZLX-23-001090 + levels: + - medium + title: Amazon Linux 2023 must manage excess capacity, bandwidth, or other + redundancy to limit the effects of information flooding types of + denial-of-service (DoS) attacks. + rules: + - firewalld-backend + status: automated + + - id: AZLX-23-001095 + levels: + - medium + title: Amazon Linux 2023 must have the s-nail package installed. + rules: + - package_s-nail_installed + status: automated + + - id: AZLX-23-001105 + levels: + - medium + title: Amazon Linux 2023 must have the libreswan package installed. + rules: + - package_libreswan_installed + status: automated + + - id: AZLX-23-001110 + levels: + - medium + title: Amazon Linux 2023 must have the policycoreutils package installed. + rules: + - package_policycoreutils_installed + status: automated + + - id: AZLX-23-001115 + levels: + - medium + title: Amazon Linux 2023 must have the pcsc-lite package installed. + rules: + - package_pcsc-lite_installed + status: automated + + - id: AZLX-23-001120 + levels: + - medium + title: Amazon Linux 2023 must have the packages required for encrypting + off-loaded audit logs installed. + rules: + - package_rsyslog-gnutls_installed + status: automated + + - id: AZLX-23-001125 + levels: + - medium + title: Amazon Linux 2023 must have the opensc package installed. + rules: + - package_opensc_installed + status: automated + + - id: AZLX-23-001130 + levels: + - medium + title: Amazon Linux 2023 must have the openssl-pkcs11 package installed. + rules: + - install_smartcard_packages + status: automated + + - id: AZLX-23-001180 + levels: + - medium + title: Amazon Linux 2023 must have SSH installed. + rules: + - package_openssh-server_installed + status: automated + + - id: AZLX-23-001185 + levels: + - medium + title: + Amazon Linux 2023 must implement SSH to protect the confidentiality and + integrity of transmitted and received information, as well as information + during preparation for transmission. + rules: + - service_sshd_enabled + status: automated + + - id: AZLX-23-001195 + levels: + - medium + title: Amazon Linux 2023 must have the crypto-policies package installed. + rules: + - package_crypto-policies_installed + status: automated + + - id: AZLX-23-001200 + levels: + - medium + title: Amazon Linux 2023 SSH server must be configured to use systemwide + crypto policies. + rules: + - file_sshd_50_redhat_exists + - sshd_include_crypto_policy + status: automated + + - id: AZLX-23-001205 + levels: + - medium + title: Amazon Linux 2023 server must be configured to use only DOD-approved + encryption ciphers employing FIPS 140-2/140-3 validated cryptographic hash + algorithms to protect the confidentiality of SSH server connections. + status: automated + rules: + - harden_sshd_ciphers_opensshserver_conf_crypto_policy + + - id: AZLX-23-001210 + levels: + - medium + title: Amazon Linux 2023 SSH server must be configured to use only Message + Authentication Codes (MACs) employing FIPS 140-2/140-3 validated + cryptographic hash algorithms to protect the confidentiality of SSH server + connections. + rules: + - harden_sshd_ciphers_openssh_conf_crypto_policy + - harden_sshd_macs_openssh_conf_crypto_policy + status: automated + + - id: AZLX-23-001215 + levels: + - medium + title: Amazon Linux 2023 SSH daemon must not allow Generic Security Service + Application Program Interface (GSSAPI) authentication. + rules: + - sshd_disable_gssapi_auth + status: automated + + - id: AZLX-23-001220 + levels: + - medium + title: Amazon Linux 2023 SSH daemon must not allow Kerberos authentication. + rules: + - sshd_disable_kerb_auth + status: automated + + - id: AZLX-23-001225 + levels: + - medium + title: Amazon Linux 2023 must force a frequent session key renegotiation for + SSH connections to the server. + rules: + - sshd_rekey_limit + - var_rekey_limit_size=1G + - var_rekey_limit_time=1hour + status: automated + + - id: AZLX-23-001230 + levels: + - medium + title: Amazon Linux 2023 SSHD must accept public key authentication. + rules: + - sshd_enable_pubkey_auth + status: automated + + - id: AZLX-23-001235 + levels: + - high + title: Amazon Linux 2023 SSHD must not allow blank passwords. + rules: + - sshd_disable_empty_passwords + status: automated + + - id: AZLX-23-001240 + levels: + - medium + title: Amazon Linux 2023 must not permit direct logons to the root account + using remote access via SSH. + rules: + - sshd_disable_root_login + status: automated + + - id: AZLX-23-001245 + levels: + - medium + title: Amazon Linux 2023 must be configured so that all network connections + associated with SSH traffic are terminated after 10 minutes of becoming + unresponsive. + rules: + - sshd_set_idle_timeout + - sshd_idle_timeout_value=10_minutes + status: automated + + - id: AZLX-23-001250 + levels: + - medium + title: Amazon Linux 2023 must be configured so that all network connections + associated with SSH traffic terminate after becoming unresponsive. + rules: + - sshd_set_keepalive + - var_sshd_set_keepalive=1 + status: automated + + - id: AZLX-23-001255 + levels: + - high + title: + Amazon Linux 2023 must enable the Pluggable Authentication Module (PAM) + interface for SSHD. + rules: + - sshd_enable_pam + status: automated + + - id: AZLX-23-001260 + levels: + - medium + title: + Amazon Linux 2023 must implement DOD-approved encryption in the OpenSSL + package. + rules: + - configure_openssl_crypto_policy + status: automated + + - id: AZLX-23-001265 + levels: + - medium + title: Amazon Linux 2023 must implement DOD-approved TLS encryption in the + OpenSSL package. + rules: + - configure_openssl_tls_crypto_policy + status: automated + + - id: AZLX-23-001270 + levels: + - medium + title: Amazon Linux 2023 must implement a FIPS 140-2/140-3 compliant + systemwide cryptographic policy. + rules: + - harden_sshd_ciphers_openssh_conf_crypto_policy + - harden_sshd_macs_openssh_conf_crypto_policy + - enable_fips_mode + - configure_bind_crypto_policy + - configure_crypto_policy + - configure_kerberos_crypto_policy + - configure_libreswan_crypto_policy + - sysctl_crypto_fips_enabled + status: automated + + - id: AZLX-23-001275 + levels: + - medium + title: + Amazon Linux 2023 must implement DOD-approved encryption to protect the + confidentiality of remote access sessions. + rules: + - harden_sshd_ciphers_opensshserver_conf_crypto_policy + - sshd_approved_ciphers=stig_rhel9 + status: automated + + - id: AZLX-23-001280 + levels: + - high + title: Amazon Linux 2023 must enable FIPS mode. + rules: + - enable_fips_mode + - sysctl_crypto_fips_enabled + - var_system_crypto_policy=fips + - enable_dracut_fips_module + status: automated + + - id: AZLX-23-001285 + levels: + - medium + title: Amazon Linux 2023 crypto policy must not be overridden. + rules: + - configure_ssh_crypto_policy + status: automated + + - id: AZLX-23-001290 + levels: + - medium + title: Amazon Linux 2023 must enable certificate-based smart card + authentication. + rules: + - package_sssd_installed + - sssd_enable_smartcards + status: automated + + - id: AZLX-23-001295 + levels: + - medium + title: Amazon Linux 2023 must map the authenticated identity to the user or + group account for PKI-based authentication. + rules: + - sssd_enable_certmap + status: automated + + - id: AZLX-23-001300 + levels: + - medium + title: Amazon Linux 2023 must implement certificate status checking for + multifactor authentication. + rules: + - sssd_certificate_verification + - var_sssd_certificate_verification_digest_function=sha512 + status: automated + + - id: AZLX-23-001305 + levels: + - medium + title: + Amazon Linux 2023 must prohibit the use of cached authenticators after + one day. + rules: + - sssd_offline_cred_expiration + status: automated + + - id: AZLX-23-001310 + levels: + - medium + title: Amazon Linux 2023, for PKI-based authentication, must validate + certificates by constructing a certification path (which includes status + information) to an accepted trust anchor. + rules: + - sssd_has_trust_anchor + status: pending + + - id: AZLX-23-001315 + levels: + - medium + title: Amazon Linux 2023, for PKI-based authentication, must enforce + authorized access to the corresponding private key. + rules: + - ssh_keys_passphrase_protected + status: automated + + - id: AZLX-23-002000 + levels: + - medium + title: Amazon Linux 2023 must display the Standard Mandatory DOD Notice and + Consent Banner before granting local or remote access to the system. + rules: + - banner_etc_issue + - login_banner_text=dod_banners + status: automated + + - id: AZLX-23-002005 + levels: + - medium + title: Amazon Linux 2023 must display the Standard Mandatory DOD Notice and + Consent Banner before granting local or remote access to the system via a + SSH logon. + rules: + - sshd_enable_warning_banner + status: automated + + - id: AZLX-23-002015 + levels: + - medium + title: + Amazon Linux 2023 must allocate audit record storage capacity to store + at least one week's worth of audit records, when audit records are not + immediately sent to a central audit record storage facility. + rules: + - auditd_audispd_configure_sufficiently_large_partition + status: automated + + - id: AZLX-23-002020 + levels: + - low + title: + Amazon Linux 2023 must use a separate file system for the system audit + data path. + rules: + - partition_for_var_log_audit + status: automated + + - id: AZLX-23-002025 + levels: + - medium + title: Amazon Linux 2023 must label all off-loaded audit logs before sending + them to the central log server. + rules: + - auditd_name_format + - var_auditd_name_format=stig + status: automated + + - id: AZLX-23-002030 + levels: + - medium + title: + Amazon Linux 2023 must take appropriate action when the internal event + queue is full. + rules: + - auditd_overflow_action + status: automated + + - id: AZLX-23-002035 + levels: + - medium + title: + Amazon Linux 2023 must take action when allocated audit record storage + volume reaches 75 percent of the repository maximum audit record storage + capacity. + rules: + - auditd_data_retention_space_left_percentage + - var_auditd_space_left_percentage=25pc + status: automated + + - id: AZLX-23-002040 + levels: + - medium + title: Amazon Linux 2023 must notify the system administrator (SA) and + information system security officer (ISSO) (at a minimum) when allocated + audit record storage volume 75 percent utilization. + rules: + - auditd_data_retention_space_left_action + - var_auditd_space_left_action=email + status: automated + + - id: AZLX-23-002045 + levels: + - medium + title: + Amazon Linux 2023 must take action when allocated audit record storage + volume reaches 95 percent of the audit record storage capacity. + rules: + - auditd_data_retention_admin_space_left_percentage + - var_auditd_admin_space_left_percentage=5pc + status: automated + + - id: AZLX-23-002050 + levels: + - medium + title: + Amazon Linux 2023 must take action when allocated audit record storage + volume reaches 95 percent of the repository maximum audit record storage + capacity. + rules: + - auditd_data_retention_admin_space_left_action + - var_auditd_admin_space_left_action=single + status: automated + + - id: AZLX-23-002055 + levels: + - medium + title: + Amazon Linux 2023 must immediately notify the system administrator (SA) + and information system security officer (ISSO), at a minimum, of an audit + processing failure event. + rules: + - auditd_data_retention_action_mail_acct + - var_auditd_action_mail_acct=root + status: automated + + - id: AZLX-23-002060 + levels: + - medium + title: Amazon Linux 2023 must be configured to off-load audit records onto a + different system from the system being audited via syslog. + rules: + - rsyslog_remote_loghost + status: automated + + - id: AZLX-23-002065 + levels: + - medium + title: Amazon Linux 2023 must authenticate the remote logging server for + off-loading audit logs via rsyslog. + rules: + - rsyslog_encrypt_offload_actionsendstreamdriverauthmode + status: automated + + - id: AZLX-23-002070 + levels: + - medium + title: + Amazon Linux 2023 must encrypt the transfer of audit records off-loaded + onto a different system or media from the system being audited via rsyslog. + rules: + - rsyslog_encrypt_offload_actionsendstreamdrivermode + status: automated + + - id: AZLX-23-002075 + levels: + - medium + title: Amazon Linux 2023 must encrypt via the gtls driver the transfer of + audit records off-loaded onto a different system or media from the system + being audited via rsyslog. + rules: + - rsyslog_encrypt_offload_defaultnetstreamdriver + status: automated + + - id: AZLX-23-002080 + levels: + - medium + title: Amazon Linux 2023 must be configured to off-load audit records onto a + different system from the system being audited via syslog. + rules: + - service_systemd-journal-upload_enabled + - systemd_journal_upload_url + status: automated + + - id: AZLX-23-002085 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/sudoers. + rules: + - audit_rules_sudoers + status: automated + + - id: AZLX-23-002090 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/sudoers.d/ directory. + rules: + - audit_rules_sudoers_d + status: automated + + - id: AZLX-23-002095 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/group. + rules: + - audit_rules_usergroup_modification_group + status: automated + + - id: AZLX-23-002100 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/gshadow. + rules: + - audit_rules_usergroup_modification_gshadow + status: automated + + - id: AZLX-23-002105 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/opasswd. + rules: + - audit_rules_usergroup_modification_opasswd + status: automated + + - id: AZLX-23-002110 + levels: + - medium + title: Amazon Linux 2023 must audit uses of the "execve" system call. + rules: + - audit_rules_suid_privilege_function + status: automated + + - id: AZLX-23-002115 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the chmod, fchmod, and + fchmodat system calls. + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + status: automated + + - id: AZLX-23-002120 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the chown, fchown, fchownat, + and lchown system calls. + rules: + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_lchown + status: automated + + - id: AZLX-23-002125 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the setxattr, fsetxattr, + lsetxattr, removexattr, fremovexattr, and lremovexattr system calls. + rules: + - audit_rules_dac_modification_setxattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_lremovexattr + status: automated + + - id: AZLX-23-002130 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the truncate, ftruncate, + creat, open, openat, and open_by_handle_at system calls. + rules: + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_open_by_handle_at + status: automated + + - id: AZLX-23-002135 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the init_module and + finit_module system calls. + rules: + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + status: automated + + - id: AZLX-23-002140 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the create_module system call. + rules: + - audit_rules_kernel_module_loading_create + status: automated + + - id: AZLX-23-002145 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the kmod command. + rules: + - audit_rules_privileged_commands_kmod + status: automated + + - id: AZLX-23-002150 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the rename, unlink, rmdir, + renameat, and unlinkat system calls. + rules: + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_rmdir + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_unlinkat + status: automated + + - id: AZLX-23-002155 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the chcon command. + rules: + - audit_rules_execution_chcon + status: automated + + - id: AZLX-23-002160 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /var/log/faillock. + rules: + - audit_rules_login_events_faillock + status: automated + + - id: AZLX-23-002165 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /var/log/lastlog. + rules: + - audit_rules_login_events_lastlog + status: automated + + - id: AZLX-23-002175 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the init command. + rules: + - audit_privileged_commands_init + status: automated + + - id: AZLX-23-002180 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the reboot command. + rules: + - audit_privileged_commands_reboot + status: automated + + - id: AZLX-23-002185 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the shutdown command. + rules: + - audit_privileged_commands_shutdown + status: automated + + - id: AZLX-23-002190 + levels: + - medium + title: Amazon Linux 2023 audit tools must have a mode of "0755" or less + permissive. + rules: + - file_audit_tools_permissions + status: automated + + - id: AZLX-23-002195 + levels: + - medium + title: Amazon Linux 2023 audit tools must be owned by root. + rules: + - file_audit_tools_ownership + status: automated + + - id: AZLX-23-002200 + levels: + - medium + title: Amazon Linux 2023 audit tools must be group-owned by root. + rules: + - file_audit_tools_group_ownership + status: automated + + - id: AZLX-23-002205 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/passwd. + rules: + - audit_rules_usergroup_modification_shadow + status: automated + + - id: AZLX-23-002210 + levels: + - medium + title: Amazon Linux 2023 must audit all successful/unsuccessful uses of the + chage command. + rules: + - audit_rules_privileged_commands_chage + status: automated + + - id: AZLX-23-002215 + levels: + - medium + title: Amazon Linux 2023 must alert the information system security officer + (ISSO) and system administrator (SA), at a minimum, in the event of an audit + processing failure. + rules: + - auditd_data_retention_action_mail_acct + status: automated + + - id: AZLX-23-002220 + levels: + - medium + title: Amazon Linux 2023 must off-load audit records onto a different system + in the event the audit storage volume is full. + rules: + - auditd_data_disk_full_action_stig + - var_auditd_disk_full_action=halt + status: automated + + - id: AZLX-23-002225 + levels: + - medium + title: Amazon Linux 2023 audit logs must be group-owned by root or by a + restricted logging group to prevent unauthorized read access. + rules: + - file_group_ownership_var_log_audit + status: automated + + - id: AZLX-23-002230 + levels: + - medium + title: + Amazon Linux 2023 audit log directory must be owned by root to prevent + unauthorized read access. + rules: + - file_ownership_var_log_audit_stig + status: automated + + - id: AZLX-23-002235 + levels: + - medium + title: Amazon Linux 2023 audit logs file must have mode "0600" or less + permissive to prevent unauthorized access to the audit log. + rules: + - file_permissions_var_log_audit + status: automated + + - id: AZLX-23-002240 + levels: + - medium + title: Amazon Linux 2023 must allow only the information system security + manager (ISSM) (or individuals or roles appointed by the ISSM) to select + which auditable events are to be audited. + rules: + - file_permissions_audit_configuration + status: automated + + - id: AZLX-23-002245 + levels: + - medium + title: Amazon Linux 2023 must audit all uses of the sudo command. + rules: + - audit_rules_privileged_commands_sudo + status: automated + + - id: AZLX-23-002250 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/passwd. + rules: + - audit_rules_usergroup_modification_passwd + status: automated + + - id: AZLX-23-002255 + levels: + - medium + title: Amazon Linux 2023 must generate audit records for all account + creations, modifications, disabling, and termination events that affect + /etc/shadow. + rules: + - audit_rules_usergroup_modification_shadow + status: automated + + - id: AZLX-23-002260 + levels: + - medium + title: + Amazon Linux 2023 must produce audit records containing information to + establish the identity of any individual or process associated with the + event. + rules: + - auditd_log_format + status: automated + + - id: AZLX-23-002265 + levels: + - medium + title: Amazon Linux 2023 audit logs must be group-owned by root or by a + restricted logging group to prevent unauthorized read access. + rules: + - directory_group_ownership_var_log_audit + status: automated + + - id: AZLX-23-002270 + levels: + - medium + title: + Amazon Linux 2023 must ensure the audit log directory be owned by root + to prevent unauthorized read access. + rules: + - directory_ownership_var_log_audit + status: automated + + - id: AZLX-23-002275 + levels: + - medium + title: Amazon Linux 2023 audit logs file must have mode "0600" or less + permissive to prevent unauthorized access to the audit log. + rules: + - file_permissions_var_log_audit + status: automated + + - id: AZLX-23-002280 + levels: + - medium + title: + Amazon Linux 2023 library directories must be group-owned by root or a + system account. + rules: + - dir_group_ownership_library_dirs + status: automated + + - id: AZLX-23-002285 + levels: + - medium + title: Amazon Linux 2023 library directories must have mode "755" or less + permissive. + rules: + - dir_permissions_library_dirs + status: automated + + - id: AZLX-23-002290 + levels: + - medium + title: Amazon Linux 2023 library files must have mode "755" or less + permissive. + rules: + - file_permissions_library_dirs + status: automated + + - id: AZLX-23-002295 + levels: + - medium + title: Amazon Linux 2023 library files must be owned by root. + rules: + - file_ownership_library_dirs + status: automated + + - id: AZLX-23-002300 + levels: + - medium + title: + Amazon Linux 2023 library files must be group-owned by root or a system + account. + rules: + - root_permissions_syslibrary_files + status: automated + + - id: AZLX-23-002305 + levels: + - medium + title: Amazon Linux 2023 library directories must be owned by root. + rules: + - dir_ownership_library_dirs + status: automated + + - id: AZLX-23-002315 + levels: + - medium + title: Amazon Linux 2023 must ensure the /var/log directory have mode "0755" + or less permissive. + rules: + - file_permissions_var_log + status: automated + + - id: AZLX-23-002320 + levels: + - medium + title: Amazon Linux 2023 must ensure the /var/log directory be owned by root. + rules: + - file_owner_var_log + status: automated + + - id: AZLX-23-002325 + levels: + - medium + title: + Amazon Linux 2023 must ensure the /var/log directory be group-owned by + root. + rules: + - file_groupowner_var_log + status: automated + + - id: AZLX-23-002330 + levels: + - medium + title: Amazon Linux 2023 must ensure the /var/log/messages file have mode + "0640" or less permissive. + rules: + - file_permissions_var_log_messages + status: automated + + - id: AZLX-23-002335 + levels: + - medium + title: + Amazon Linux 2023 must ensure the /var/log/messages file be group-owned + by root. + rules: + - file_groupowner_var_log_messages + status: automated + + - id: AZLX-23-002340 + levels: + - medium + title: Amazon Linux 2023 must ensure the /var/log/messages file be owned by + root. + rules: + - file_owner_var_log_messages + status: automated + + - id: AZLX-23-002345 + levels: + - medium + title: Amazon Linux 2023 system commands must be owned by root. + rules: + - file_ownership_binary_dirs + status: automated + + - id: AZLX-23-002350 + levels: + - medium + title: Amazon Linux 2023 system commands must be group-owned by root or a + system account. + rules: + - file_groupownership_system_commands_dirs + status: automated + + - id: AZLX-23-002355 + levels: + - medium + title: + Amazon Linux 2023 must enforce password complexity by requiring that at + least one uppercase character be used. + rules: + - accounts_password_pam_ucredit + - var_password_pam_ucredit=1 + status: automated + + - id: AZLX-23-002360 + levels: + - medium + title: + Amazon Linux 2023 must enforce password complexity by requiring that at + least one lowercase character be used. + rules: + - accounts_password_pam_lcredit + - var_password_pam_lcredit=1 + status: automated + + - id: AZLX-23-002365 + levels: + - medium + title: + Amazon Linux 2023 must enforce password complexity by requiring that at + least one numeric character be used. + rules: + - accounts_password_pam_dcredit + - var_password_pam_dcredit=1 + status: automated + + - id: AZLX-23-002370 + levels: + - medium + title: + Amazon Linux 2023 must require the change of at least 50 percent of the + total number of characters when passwords are changed. + rules: + - accounts_password_pam_difok + - var_password_pam_difok=8 + status: automated + + - id: AZLX-23-002375 + levels: + - medium + title: Amazon Linux 2023 must enforce a minimum 15-character password length. + rules: + - accounts_password_pam_minlen + - var_password_pam_minlen=15 + status: automated + + - id: AZLX-23-002380 + levels: + - medium + title: + Amazon Linux 2023 must enforce password complexity by requiring that at + least one special character be used. + rules: + - accounts_password_pam_ocredit + - var_password_pam_ocredit=1 + status: automated + + - id: AZLX-23-002385 + levels: + - medium + title: Amazon Linux 2023 must enforce password complexity rules for the root + account. + rules: + - accounts_password_pam_enforce_root + status: automated + + - id: AZLX-23-002390 + levels: + - medium + title: Amazon Linux 2023 must prevent the use of dictionary words for + passwords. + rules: + - accounts_password_pam_dictcheck + - var_password_pam_dictcheck=1 + status: automated + + - id: AZLX-23-002395 + levels: + - low + title: Amazon Linux 2023 must limit the number of concurrent sessions to ten + for all accounts and/or account types. + rules: + - accounts_max_concurrent_login_sessions + - var_accounts_max_concurrent_login_sessions=10 + status: automated + + - id: AZLX-23-002396 + levels: + - medium + title: Amazon Linux 2023 must automatically exit interactive command shell + user sessions after 15 minutes of inactivity. + rules: + - accounts_tmout + - var_accounts_tmout=10_min + status: automated + + - id: AZLX-23-002400 + levels: + - medium + title: Amazon Linux 2023 must enforce 24 hours/1 day as the minimum password + lifetime. + rules: + - accounts_minimum_age_login_defs + status: automated + + - id: AZLX-23-002405 + levels: + - medium + title: + Amazon Linux 2023 must enforce a delay of at least four seconds between + logon prompts following a failed logon attempt. + rules: + - accounts_logon_fail_delay + - var_accounts_fail_delay=4 + status: automated + + - id: AZLX-23-002410 + levels: + - medium + title: + Amazon Linux 2023 must define default permissions for all authenticated + users in such a way that the user can only read and modify their own files. + rules: + - accounts_umask_etc_login_defs + status: automated + + - id: AZLX-23-002415 + levels: + - medium + title: Amazon Linux 2023 must automatically remove or disable temporary user + accounts after 72 hours. + rules: [] + status: pending + + - id: AZLX-23-002420 + levels: + - medium + title: Amazon Linux 2023 must automatically lock an account when three + unsuccessful logon attempts occur. + rules: + - accounts_passwords_pam_faillock_deny + status: automated + + - id: AZLX-23-002425 + levels: + - medium + title: Amazon Linux 2023 must be able to enforce a 60-day maximum password + lifetime restriction. + rules: + - accounts_password_set_max_life_existing + - var_accounts_maximum_age_login_defs=60 + status: automated + + - id: AZLX-23-002430 + levels: + - medium + title: Amazon Linux 2023 must disable account identifiers (individuals, + groups, roles, and devices) after 35 days of inactivity. + rules: + - account_disable_post_pw_expiration + - var_account_disable_post_pw_expiration=35 + status: automated + + - id: AZLX-23-002435 + levels: + - medium + title: Amazon Linux 2023 must automatically expire temporary accounts within + 72 hours. + rules: + - account_temp_expire_date + status: automated + + - id: AZLX-23-002440 + levels: + - medium + title: Amazon Linux 2023 must restrict the use of the "su" command. + rules: + - use_pam_wheel_for_su + status: automated + + - id: AZLX-23-002445 + levels: + - medium + title: Amazon Linux 2023 must enable the SELinux targeted policy. + rules: + - selinux_policytype + - var_selinux_policy_name=targeted + status: automated + + - id: AZLX-23-002450 + levels: + - high + title: Amazon Linux 2023 must use a Linux Security Module configured to + enforce limits on system services. + rules: + - selinux_state + - var_selinux_state=enforcing + status: automated + + - id: AZLX-23-002455 + levels: + - medium + title: Amazon Linux 2023 must automatically lock an account when three + unsuccessful logon attempts occur. + rules: + - accounts_passwords_pam_faillock_deny + - var_accounts_passwords_pam_faillock_deny=3 + status: automated + + - id: AZLX-23-002460 + levels: + - medium + title: Amazon Linux 2023 must automatically lock the root account until the + root account is released by an administrator when three unsuccessful logon + attempts occur during a 15-minute time period. + rules: + - accounts_passwords_pam_faillock_deny_root + status: automated + + - id: AZLX-23-002465 + levels: + - medium + title: Amazon Linux 2023 must automatically lock an account until the locked + account is released by an administrator when three unsuccessful logon + attempts in 15 minutes occur. + rules: + - accounts_passwords_pam_faillock_interval + - var_accounts_passwords_pam_faillock_fail_interval=900 + status: automated + + - id: AZLX-23-002470 + levels: + - medium + title: Amazon Linux 2023 must maintain an account lock until the locked + account is released by an administrator. + rules: + - accounts_passwords_pam_faillock_unlock_time + - var_accounts_passwords_pam_faillock_unlock_time=never + status: automated + + - id: AZLX-23-002475 + levels: + - medium + title: + Amazon Linux 2023 must be configured to prohibit or restrict the use of + functions, ports, protocols, and/or services, as defined in the Ports, + Protocols, and Services Management Category Assurance List (PPSM CAL) and + vulnerability assessments. + rules: + - configured_firewalld_default_deny + status: automated + + - id: AZLX-23-002480 + levels: + - medium + title: Amazon Linux 2023 must insure all interactive users have a primary + group that exists. + rules: + - gid_passwd_group_same + status: automated + + - id: AZLX-23-002485 + levels: + - medium + title: Amazon Linux 2023 must ensure all interactive users have unique User + IDs (UIDs). + rules: + - account_unique_id + status: automated + + - id: AZLX-23-002489 + levels: + - medium + title: + Amazon Linux 2023 must ensure the password complexity module is enabled + in the password-auth file. + rules: + - accounts_password_pam_pwquality_password_auth + status: automated + + - id: AZLX-23-002490 + levels: + - medium + title: + Amazon Linux 2023 password-auth must be configured to use a sufficient + number of hashing rounds. + rules: + - accounts_password_pam_unix_rounds_password_auth + - var_password_pam_unix_rounds=100000 + status: automated + + - id: AZLX-23-002495 + levels: + - medium + title: Amazon Linux 2023 system-auth must be configured to use a sufficient + number of hashing rounds. + rules: + - accounts_password_pam_unix_rounds_system_auth + status: automated + + - id: AZLX-23-002500 + levels: + - medium + title: Amazon Linux 2023 must ensure a sticky bit be set on all public + directories. + rules: + - dir_perms_world_writable_sticky_bits + status: automated + + - id: AZLX-23-002505 + levels: + - medium + title: Amazon Linux 2023 must ensure all world-writable directories be owned + by root, sys, bin, or an application user. + rules: + - dir_perms_world_writable_root_owned + status: automated + + - id: AZLX-23-002510 + levels: + - medium + title: Amazon Linux 2023 must terminate idle user sessions. + rules: + - logind_session_timeout + - var_logind_session_timeout=15_minutes + status: automated + + - id: AZLX-23-002515 + levels: + - low + title: + Amazon Linux 2023 must enable auditing of processes that start prior to + the audit daemon. + rules: + - grub2_audit_argument + status: automated + + - id: AZLX-23-002520 + levels: + - low + title: Amazon Linux 2023 must allocate an audit_backlog_limit of sufficient + size to capture processes that start prior to the audit daemon. + rules: + - grub2_audit_backlog_limit_argument + - var_audit_backlog_limit=8192 + status: automated + + - id: AZLX-23-002535 + levels: + - medium + title: Amazon Linux 2023 must enable discretionary access control on + hardlinks. + rules: + - sysctl_fs_protected_hardlinks + status: automated + + - id: AZLX-23-002540 + levels: + - medium + title: Amazon Linux 2023 must enable kernel parameters to enforce + discretionary access control on symlinks. + rules: + - sysctl_fs_protected_symlinks + status: automated + + - id: AZLX-23-002555 + levels: + - medium + title: Amazon Linux 2023 debug-shell systemd service must be disabled. + status: automated + rules: + - service_debug-shell_disabled + + - id: AZLX-23-002560 + levels: + - medium + title: + Amazon Linux 2023 chrony must be configured with a maximum interval of + 24 hours between requests sent to a USNO server or a time server designated + for the appropriate DOD network. + rules: [] + status: pending + + - id: AZLX-23-002565 + levels: + - medium + title: Amazon Linux 2023 must synchronize internal information system clocks + to the authoritative time source at least every 24 hours. + rules: + - chronyd_or_ntpd_set_maxpoll + - chronyd_server_directive + - chronyd_specify_remote_server + - var_multiple_time_servers=stig + - var_time_service_set_maxpoll=18_hours + status: automated + + - id: AZLX-23-002570 + levels: + - medium + title: Amazon Linux 2023 must routinely check the baseline configuration for + unauthorized changes and notify the system administrator when anomalies in + the operation of any security functions are discovered. + rules: + - aide_periodic_cron_checking + - aide_scan_notification + status: automated + + - id: AZLX-23-002575 + levels: + - medium + title: Amazon Linux 2023 must prevent the loading of a new kernel for later + execution. + rules: + - sysctl_kernel_kexec_load_disabled + status: automated + + - id: AZLX-23-002580 + levels: + - medium + title: + Amazon Linux 2023 must prevent files with the setuid and setgid bit set + from being executed on the /boot/efi directory. + rules: + - mount_option_boot_efi_nosuid + status: automated + + - id: AZLX-23-002585 + levels: + - medium + title: Amazon Linux 2023 must mount /dev/shm with the nodev option. + rules: + - mount_option_dev_shm_nodev + status: automated + + - id: AZLX-23-002590 + levels: + - medium + title: Amazon Linux 2023 must mount /dev/shm with the nosuid option. + rules: + - mount_option_dev_shm_nosuid + status: automated + + - id: AZLX-23-002595 + levels: + - medium + title: Amazon Linux 2023 must ensure the pcscd service is active. + rules: + - service_pcscd_enabled + status: automated + + - id: AZLX-23-002600 + levels: + - medium + title: Amazon Linux 2023 file system automount function must be disabled + unless required. + rules: + - service_autofs_disabled + status: automated + + - id: AZLX-23-002605 + levels: + - medium + title: Amazon Linux 2023 must protect against or limit the effects of + denial-of-service (DoS) attacks by ensuring rate-limiting measures are + configured on impacted network interfaces. + rules: [] + status: pending + + - id: AZLX-23-002615 + levels: + - low + title: Amazon Linux 2023 must remove all software components after updated + versions have been installed. + rules: + - clean_components_post_updating + status: automated + + - id: AZLX-23-002620 + levels: + - medium + title: + Amazon Linux 2023 must configure the use of the pam_faillock.so module + in the /etc/pam.d/system-auth file. + rules: + - account_password_pam_faillock_system_auth + status: automated + + - id: AZLX-23-005000 + levels: + - medium + title: Amazon Linux 2023 audit system must protect logon user identifiers + (UIDs) from unauthorized change. + rules: + - audit_rules_immutable_login_uids + status: automated + + - id: needed_rules + levels: + - medium + rules: + - enable_authselect + - var_authselect_profile=sssd + - enable_fips_mode + - var_system_crypto_policy=fips + - configure_crypto_policy + - configure_bind_crypto_policy + - configure_libreswan_crypto_policy + - configure_kerberos_crypto_policy + - package_authselect_installed + diff --git a/controls/stig_ol9.yml b/controls/stig_ol9.yml index bc1370b1b5a4..7f7303b0949d 100644 --- a/controls/stig_ol9.yml +++ b/controls/stig_ol9.yml @@ -3,7 +3,7 @@ policy: 'Oracle Linux 9 Security Technical Implementation Guide' title: 'Oracle Linux 9 Security Technical Implementation Guide' id: stig_ol9 source: https://www.cyber.mil/stigs/downloads/ -version: V1R1 +version: V1R5 reference_type: stigid product: ol9 @@ -53,6 +53,7 @@ controls: rules: - banner_etc_issue - login_banner_text=dod_default + - login_banner_contents=dod_default status: automated - id: OL09-00-000020 @@ -466,14 +467,6 @@ controls: - package_tftp-server_removed status: automated - - id: OL09-00-000140 - levels: - - medium - title: OL 9 must not have the quagga package installed. - rules: - - package_quagga_removed - status: not applicable # The quagga package is not available in OL 9 - - id: OL09-00-000145 levels: - medium @@ -621,14 +614,6 @@ controls: - mount_option_home_noexec status: automated - - id: OL09-00-002010 - levels: - - medium - title: OL 9 must be configured so that the Network File System (NFS) is configured to use RPCSEC_GSS. - rules: - - mount_option_krb_sec_remote_filesystems - status: automated - - id: OL09-00-002011 levels: - medium @@ -1262,7 +1247,7 @@ controls: - medium title: OL 9 world-writable directories must be owned by root, sys, bin, or an application user. rules: - - dir_perms_world_writable_root_owned + - dir_perms_world_writable_system_owned status: automated - id: OL09-00-002510 @@ -1423,6 +1408,7 @@ controls: title: OL 9 must disable network management of the chrony daemon. rules: - chronyd_no_chronyc_network + - chronyd_configure_local_socket status: automated - id: OL09-00-006003 @@ -1760,7 +1746,7 @@ controls: - id: OL09-00-000261 levels: - - medium + - high title: OL 9 must implement DOD-approved encryption ciphers to protect the confidentiality of SSH client connections. rules: @@ -1768,42 +1754,36 @@ controls: - sshd_approved_ciphers=stig_ol9 status: automated - - id: OL09-00-000252 - levels: - - medium - title: The OL 9 SSH daemon must be configured to use systemwide cryptographic policies. - rules: - - file_sshd_50_redhat_exists - - sshd_include_crypto_policy - status: automated - - id: OL09-00-000254 levels: - - medium + - high title: OL 9 SSH server must be configured to use only ciphers employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections. rules: - harden_sshd_ciphers_opensshserver_conf_crypto_policy + - harden_sshd_ciphers_opensshserver_conf_crypto_policy.severity=high - sshd_approved_ciphers=stig_ol9 status: automated - id: OL09-00-000262 levels: - - medium + - high title: OL 9 SSH client must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms. status: automated rules: - harden_sshd_macs_openssh_conf_crypto_policy + - harden_sshd_macs_openssh_conf_crypto_policy.severity=high - sshd_strong_macs=stig_ol9 - id: OL09-00-000255 levels: - - medium + - high title: OL 9 SSH server must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms. rules: - harden_sshd_macs_opensshserver_conf_crypto_policy + - harden_sshd_macs_opensshserver_conf_crypto_policy.severity=high - sshd_approved_macs=stig_ol9 status: automated @@ -1980,7 +1960,8 @@ controls: or remote access to the system via a graphical user logon. rules: - dconf_gnome_login_banner_text - - login_banner_text=dod_default + - dconf_login_banner_text=dod_default + - dconf_login_banner_contents=dod_default - id: OL09-00-002122 levels: @@ -2063,9 +2044,10 @@ controls: - id: OL09-00-002104 levels: - medium - title: OL 9 must automatically lock graphical user sessions after 15 minutes of inactivity. + title: OL 9 must automatically lock graphical user sessions after 10 minutes of inactivity. rules: - dconf_gnome_screensaver_idle_delay + - inactivity_timeout_value=10_minutes status: automated - id: OL09-00-002124 @@ -2410,14 +2392,6 @@ controls: - sysctl_kernel_exec_shield status: automated - - id: OL09-00-002427 - levels: - - medium - title: Local OL 9 initialization files must not execute world-writable programs. - rules: - - accounts_user_dot_no_world_writable_programs - status: automated - - id: OL09-00-002411 levels: - medium @@ -3789,7 +3763,7 @@ controls: - id: OL09-00-002404 levels: - - medium + - high title: OL 9 IP tunnels must use FIPS 140-2/140-3 approved cryptographic algorithms. rules: - configure_libreswan_crypto_policy @@ -3807,10 +3781,11 @@ controls: - id: OL09-00-000240 levels: - - medium + - high title: OL 9 must have the crypto-policies package installed. rules: - package_crypto-policies_installed + - package_crypto-policies_installed.severity=high status: automated - id: OL09-00-000243 @@ -3821,35 +3796,18 @@ controls: - rpm_verify_hashes status: automated - - id: OL09-00-000244 - levels: - - high - title: OL 9 crypto policy files must match files shipped with the operating system. - rules: - - rpm_verify_crypto_policies - status: automated - - id: OL09-00-000242 levels: - - medium + - high title: OL 9 crypto policy must not be overridden. rules: - fips_crypto_policy_symlinks - status: automated - - - id: OL09-00-002424 - levels: - - medium - title: OL 9 must use mechanisms meeting the requirements of applicable federal laws, executive - orders, directives, policies, regulations, standards, and guidance for authentication to a - cryptographic module. - rules: - - configure_kerberos_crypto_policy + - fips_crypto_policy_symlinks.severity=high status: automated - id: OL09-00-000241 levels: - - medium + - high title: OL 9 must implement a system-wide encryption policy. rules: - configure_crypto_policy @@ -3857,7 +3815,7 @@ controls: - id: OL09-00-002421 levels: - - medium + - high title: OL 9 must implement DOD-approved encryption in the bind package. rules: - configure_bind_crypto_policy diff --git a/controls/stig_slmicro5.yml b/controls/stig_slmicro5.yml index d39b265fff84..32861fe776d3 100644 --- a/controls/stig_slmicro5.yml +++ b/controls/stig_slmicro5.yml @@ -3,1799 +3,1861 @@ policy: SUSE Linux Enterprise Micro (SLEM) 5 Security Technical Implementation G title: SUSE Linux Enterprise Micro (SLEM) 5 Security Technical Implementation Guide id: stig_slmicro5 source: https://www.cyber.mil/stigs/downloads/ -version: V1R2 +version: V1R3 reference_type: stigid product: slmicro5 levels: - - id: high - - id: medium - - id: low + - id: high + - id: medium + - id: low controls: - - id: SLEM-05-211010 - levels: - - high - title: SLEM 5 must be a vendor-supported release. - rules: - - installed_OS_is_vendor_supported - status: automated - - - id: SLEM-05-211015 - levels: - - medium - title: SLEM 5 must implement an endpoint security tool. - rules: [] - status: manual - - - id: SLEM-05-211020 - levels: - - medium - title: SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner before granting - any local or remote connection to the system. - rules: - - banner_etc_issue - - login_banner_text=dod_banners - status: automated - - - id: SLEM-05-211025 - levels: - - high - title: SLEM 5 must disable the x86 Ctrl-Alt-Delete key sequence. - rules: - - disable_ctrlaltdel_reboot - status: automated - - - id: SLEM-05-212010 - levels: - - high - title: SLEM 5 with a basic input/output system (BIOS) must require authentication upon booting - into single-user and maintenance modes. - rules: - - grub2_password - status: automated - - - id: SLEM-05-212015 - levels: - - high - title: SLEM 5 with Unified Extensible Firmware Interface (UEFI) implemented must require authentication - upon booting into single-user mode and maintenance. - rules: - - grub2_uefi_password - status: automated - - - id: SLEM-05-213010 - levels: - - medium - title: SLEM 5 must restrict access to the kernel message buffer. - rules: - - sysctl_kernel_dmesg_restrict - status: automated - - - id: SLEM-05-213015 - levels: - - medium - title: SLEM 5 kernel core dumps must be disabled unless needed. - rules: - - service_kdump_disabled - status: automated - - - id: SLEM-05-213020 - levels: - - medium - title: Address space layout randomization (ASLR) must be implemented by SLEM 5 to protect memory - from unauthorized code execution. - rules: - - sysctl_kernel_randomize_va_space - status: automated - - - id: SLEM-05-213025 - levels: - - medium - title: SLEM 5 must implement kptr-restrict to prevent the leaking of internal kernel addresses. - rules: - - sysctl_kernel_kptr_restrict - status: automated - - - id: SLEM-05-214010 - levels: - - medium - title: Vendor-packaged SLEM 5 security patches and updates must be installed and up to date. - rules: - - security_patches_up_to_date - status: automated - - - id: SLEM-05-214015 - levels: - - high - title: The SLEM 5 tool zypper must have gpgcheck enabled. - rules: - - ensure_gpgcheck_globally_activated - status: automated - - - id: SLEM-05-214020 - levels: - - medium - title: SLEM 5 must remove all outdated software components after updated versions have been installed. - rules: - - clean_components_post_updating - status: automated - - - id: SLEM-05-215010 - levels: - - medium - title: SLEM 5 must use vlock to allow for session locking. - rules: - - vlock_installed - status: automated - - - id: SLEM-05-215015 - levels: - - high - title: SLEM 5 must not have the telnet-server package installed. - rules: - - package_telnet-server_removed - status: automated - - - id: SLEM-05-231010 - levels: - - medium - title: A separate file system must be used for SLEM 5 user home directories (such as /home or an - equivalent). - rules: - - partition_for_home - status: automated - - - id: SLEM-05-231015 - levels: - - medium - title: SLEM 5 must use a separate file system for /var. - rules: - - partition_for_var - status: automated - - - id: SLEM-05-231020 - levels: - - medium - title: SLEM 5 must use a separate file system for the system audit data path. - rules: - - partition_for_var_log_audit - status: automated - - - id: SLEM-05-231025 - levels: - - medium - title: SLEM 5 file systems that are being imported via Network File System (NFS) must be mounted - to prevent files with the setuid and setgid bit set from being executed. - rules: - - mount_option_nosuid_remote_filesystems - status: automated - - - id: SLEM-05-231030 - levels: - - medium - title: SLEM 5 file systems that are being imported via Network File System (NFS) must be mounted - to prevent binary files from being executed. - rules: - - mount_option_noexec_remote_filesystems - status: automated - - - id: SLEM-05-231035 - levels: - - medium - title: SLEM 5 file systems that are used with removable media must be mounted to prevent files - with the setuid and setgid bit set from being executed. - rules: - - mount_option_nosuid_removable_partitions - status: automated - - - id: SLEM-05-231040 - levels: - - high - title: All SLEM 5 persistent disk partitions must implement cryptographic mechanisms to prevent - unauthorized disclosure or modification of all information that requires at-rest protection. - rules: - - encrypt_partitions - status: automated - - - id: SLEM-05-231045 - levels: - - medium - title: SLEM 5 file systems that contain user home directories must be mounted to prevent files - with the setuid and setgid bit set from being executed. - rules: - - mount_option_home_nosuid - status: automated - - - id: SLEM-05-231050 - levels: - - medium - title: SLEM 5 must disable the file system automounter unless required. - rules: - - service_autofs_disabled - status: automated - - - id: SLEM-05-232010 - levels: - - medium - title: SLEM 5 must have directories that contain system commands set to a mode of 755 or less permissive. - rules: - - dir_permissions_binary_dirs - status: automated - - - id: SLEM-05-232015 - levels: - - medium - title: SLEM 5 must have system commands set to a mode of 755 or less permissive. - rules: - - file_permissions_binary_dirs - status: automated - - - id: SLEM-05-232020 - levels: - - medium - title: SLEM 5 library directories must have mode 755 or less permissive. - rules: - - dir_permissions_library_dirs - status: automated - - - id: SLEM-05-232025 - levels: - - medium - title: SLEM 5 library files must have mode 755 or less permissive. - rules: - - file_permissions_library_dirs - status: automated - - - id: SLEM-05-232030 - levels: - - medium - title: All SLEM 5 local interactive user home directories must have mode 750 or less permissive. - rules: - - file_permissions_home_directories - status: automated - - - id: SLEM-05-232035 - levels: - - medium - title: All SLEM 5 local initialization files must have mode 740 or less permissive. - rules: - - file_permission_user_init_files - status: automated - - - id: SLEM-05-232040 - levels: - - medium - title: SLEM 5 SSH daemon public host key files must have mode 644 or less permissive. - rules: - - file_permissions_sshd_pub_key - status: automated - - - id: SLEM-05-232045 - levels: - - medium - title: SLEM 5 SSH daemon private host key files must have mode 640 or less permissive. - rules: - - file_permissions_sshd_private_key - status: automated - - - id: SLEM-05-232050 - levels: - - medium - title: SLEM 5 library files must be owned by root. - rules: - - file_ownership_library_dirs - status: automated - - - id: SLEM-05-232055 - levels: - - medium - title: SLEM 5 library files must be group-owned by root. - rules: - - root_permissions_syslibrary_files - status: automated - - - id: SLEM-05-232060 - levels: - - medium - title: SLEM 5 library directories must be owned by root. - rules: - - dir_ownership_library_dirs - status: automated - - - id: SLEM-05-232065 - levels: - - medium - title: SLEM 5 library directories must be group-owned by root. - rules: - - dir_group_ownership_library_dirs - status: automated - - - id: SLEM-05-232070 - levels: - - medium - title: SLEM 5 must have system commands owned by root. - rules: - - file_ownership_binary_dirs - status: automated - - - id: SLEM-05-232075 - levels: - - medium - title: SLEM 5 must have system commands group-owned by root or a system account. - rules: - - file_groupownership_system_commands_dirs - status: automated - - - id: SLEM-05-232080 - levels: - - medium - title: SLEM 5 must have directories that contain system commands owned by root. - rules: - - dir_system_commands_root_owned - status: automated - - - id: SLEM-05-232085 - levels: - - medium - title: SLEM 5 must have directories that contain system commands group-owned by root. - rules: - - dir_system_commands_group_root_owned - status: automated - - - id: SLEM-05-232090 - levels: - - medium - title: All SLEM 5 files and directories must have a valid owner. - rules: - - no_files_unowned_by_user - status: automated - - - id: SLEM-05-232095 - levels: - - medium - title: All SLEM 5 files and directories must have a valid group owner. - rules: - - file_permissions_ungroupowned - status: automated - - - id: SLEM-05-232100 - levels: - - medium - title: All SLEM 5 local interactive user home directories must be group-owned by the home directory - owner's primary group. - rules: - - file_groupownership_home_directories - status: automated - - - id: SLEM-05-232105 - levels: - - medium - title: All SLEM 5 world-writable directories must be group-owned by root, sys, bin, or an application - group. - rules: - - dir_perms_world_writable_system_owned_group - status: automated - - - id: SLEM-05-232110 - levels: - - medium - title: The sticky bit must be set on all SLEM 5 world-writable directories. - rules: - - dir_perms_world_writable_sticky_bits - status: automated - - - id: SLEM-05-232115 - levels: - - medium - title: SLEM 5 must prevent unauthorized users from accessing system error messages. - rules: - - file_permissions_local_var_log_messages - status: automated - - - id: SLEM-05-232120 - levels: - - medium - title: SLEM 5 must generate error messages that provide information necessary for corrective actions - without revealing information that could be exploited by adversaries. - rules: - - permissions_local_var_log - status: automated - - - id: SLEM-05-251010 - levels: - - medium - title: SLEM 5 must be configured to prohibit or restrict the use of functions, ports, protocols, - and/or services as defined in the Ports, Protocols, and Services Management (PPSM) Category - Assignments List (CAL) and vulnerability assessments. - rules: - - service_firewalld_enabled - status: automated - - - id: SLEM-05-252010 - levels: - - medium - title: SLEM 5 clock must, for networked systems, be synchronized to an authoritative DOD time source - at least every 24 hours. - rules: - - chronyd_or_ntpd_set_maxpoll - - chronyd_specify_remote_server - - var_multiple_time_servers=stig - - var_time_service_set_maxpoll=18_hours - status: automated - - - id: SLEM-05-252015 - levels: - - medium - title: SLEM 5 must not have network interfaces in promiscuous mode unless approved and documented. - rules: - - network_sniffer_disabled - status: automated - - - id: SLEM-05-253010 - levels: - - medium - title: SLEM 5 must not forward Internet Protocol version 4 (IPv4) source-routed packets. - rules: - - sysctl_net_ipv4_conf_all_accept_source_route - status: automated - - - id: SLEM-05-253015 - levels: - - medium - title: SLEM 5 must not forward Internet Protocol version 4 (IPv4) source-routed packets by default. - rules: - - sysctl_net_ipv4_conf_default_accept_source_route - status: automated - - - id: SLEM-05-253020 - levels: - - medium - title: SLEM 5 must prevent Internet Protocol version 4 (IPv4) Internet Control Message Protocol - (ICMP) redirect messages from being accepted. - rules: - - sysctl_net_ipv4_conf_all_accept_redirects - status: automated - - - id: SLEM-05-253025 - levels: - - medium - title: SLEM 5 must not allow interfaces to accept Internet Protocol version 4 (IPv4) Internet Control - Message Protocol (ICMP) redirect messages by default. - rules: - - sysctl_net_ipv4_conf_default_accept_redirects - status: automated - - - id: SLEM-05-253030 - levels: - - medium - title: SLEM 5 must not send Internet Protocol version 4 (IPv4) Internet Control Message Protocol - (ICMP) redirects. - rules: - - sysctl_net_ipv4_conf_all_send_redirects - status: automated - - - id: SLEM-05-253035 - levels: - - medium - title: SLEM 5 must not allow interfaces to send Internet Protocol version 4 (IPv4) Internet Control - Message Protocol (ICMP) redirect messages by default. - rules: - - sysctl_net_ipv4_conf_default_send_redirects - status: automated - - - id: SLEM-05-253040 - levels: - - medium - title: SLEM 5 must not be performing Internet Protocol version 4 (IPv4) packet forwarding unless - the system is a router. - rules: - - sysctl_net_ipv4_ip_forward - status: automated - - - id: SLEM-05-253045 - levels: - - medium - title: SLEM 5 must be configured to use TCP syncookies. - rules: - - sysctl_net_ipv4_tcp_syncookies - status: automated - - - id: SLEM-05-254010 - levels: - - medium - title: SLEM 5 must not forward Internet Protocol version 6 (IPv6) source-routed packets. - rules: - - sysctl_net_ipv6_conf_all_accept_source_route - status: automated - - - id: SLEM-05-254015 - levels: - - medium - title: SLEM 5 must not forward Internet Protocol version 6 (IPv6) source-routed packets by default. - rules: - - sysctl_net_ipv6_conf_default_accept_source_route - status: automated - - - id: SLEM-05-254020 - levels: - - medium - title: SLEM 5 must prevent Internet Protocol version 6 (IPv6) Internet Control Message Protocol - (ICMP) redirect messages from being accepted. - rules: - - sysctl_net_ipv6_conf_all_accept_redirects - status: automated - - - id: SLEM-05-254025 - levels: - - medium - title: SLEM 5 must not allow interfaces to accept Internet Protocol version 6 (IPv6) Internet Control - Message Protocol (ICMP) redirect messages by default. - rules: - - sysctl_net_ipv6_conf_default_accept_redirects - status: automated - - - id: SLEM-05-254030 - levels: - - medium - title: SLEM 5 must not be performing Internet Protocol version 6 (IPv6) packet forwarding unless - the system is a router. - rules: - - sysctl_net_ipv6_conf_all_forwarding - status: automated - - - id: SLEM-05-254035 - levels: - - medium - title: SLEM 5 must not be performing Internet Protocol version 6 (IPv6) packet forwarding by default - unless the system is a router. - rules: - - sysctl_net_ipv6_conf_default_forwarding - status: automated - - - id: SLEM-05-255010 - levels: - - high - title: SLEM 5 must have SSH installed to protect the confidentiality and integrity of transmitted - information. - rules: - - package_openssh-server_installed - status: automated - - - id: SLEM-05-255015 - levels: - - high - title: SLEM 5 must use SSH to protect the confidentiality and integrity of transmitted information. - rules: - - service_sshd_enabled - status: automated - - - id: SLEM-05-255020 - levels: - - medium - title: SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner before granting - access via SSH. - rules: - - sshd_enable_warning_banner - status: automated - - - id: SLEM-05-255025 - levels: - - high - title: SLEM 5 must not allow unattended or automatic logon via SSH. - rules: - - sshd_disable_empty_passwords - - sshd_do_not_permit_user_env - status: automated - - - id: SLEM-05-255030 - levels: - - medium - title: SLEM 5 must be configured so that all network connections associated with SSH traffic terminate - after becoming unresponsive. - rules: - - sshd_set_keepalive - - var_sshd_set_keepalive=1 - status: automated - - - id: SLEM-05-255035 - levels: - - medium - title: SLEM 5 must be configured so that all network connections associated with SSH traffic are - terminated after 10 minutes of becoming unresponsive. - rules: - - sshd_set_idle_timeout - - sshd_idle_timeout_value=10_minutes - status: automated - - - id: SLEM-05-255040 - levels: - - medium - title: SLEM 5 SSH daemon must disable forwarded remote X connections for interactive users, unless - to fulfill documented and validated mission requirements. - rules: - - sshd_disable_x11_forwarding - status: automated - - - id: SLEM-05-255045 - levels: - - high - title: SLEM 5 must implement DOD-approved encryption to protect the confidentiality of SSH remote - connections. - rules: - - sshd_use_approved_ciphers_ordered_stig - - sshd_use_approved_ciphers - status: automated - - - id: SLEM-05-255050 - levels: - - high - title: SLEM 5 SSH daemon must be configured to only use Message Authentication Codes (MACs) employing - FIPS 140-2/140-3 approved cryptographic hash algorithms. - rules: - - sshd_use_approved_macs_ordered_stig - - sshd_use_approved_macs - status: automated - - - id: SLEM-05-255055 - levels: - - high - title: SLEM 5 SSH server must be configured to use only FIPS 140-2/140-3 validated key exchange - algorithms. - rules: - - sshd_use_approved_kex_ordered_stig - status: automated - - - id: SLEM-05-255060 - levels: - - medium - title: SLEM 5 must deny direct logons to the root account using remote access via SSH. - rules: - - sshd_disable_root_login - status: automated - - - id: SLEM-05-255065 - levels: - - medium - title: SLEM 5 must log SSH connection attempts and failures to the server. - rules: - - sshd_set_loglevel_verbose - status: automated - - - id: SLEM-05-255070 - levels: - - medium - title: SLEM 5 must display the date and time of the last successful account logon upon an SSH logon. - rules: - - sshd_print_last_log - status: automated - - - id: SLEM-05-255075 - levels: - - medium - title: SLEM 5 SSH daemon must be configured to not allow authentication using known hosts authentication. - rules: - - sshd_disable_user_known_hosts - status: automated - - - id: SLEM-05-255080 - levels: - - medium - title: SLEM 5 SSH daemon must perform strict mode checking of home directory configuration files. - rules: - - sshd_enable_strictmodes - status: automated - - - id: SLEM-05-255085 - levels: - - medium - title: SLEM 5, for PKI-based authentication, must enforce authorized access to the corresponding - private key. - rules: - - ssh_private_keys_have_passcode - status: manual - - - id: SLEM-05-255090 - levels: - - high - title: There must be no .shosts files on SLEM 5. - rules: - - no_user_host_based_files - status: automated - - - id: SLEM-05-255095 - levels: - - high - title: There must be no shosts.equiv files on SLEM 5. - rules: - - no_host_based_files - status: automated - - - id: SLEM-05-272010 - levels: - - high - title: SLEM 5 must not allow unattended or automatic logon via the graphical user interface (GUI). - rules: - - gnome_gdm_disable_unattended_automatic_login - status: automated - - - id: SLEM-05-291010 - levels: - - medium - title: SLEM 5 wireless network adapters must be disabled unless approved and documented. - rules: - - wireless_disable_interfaces - status: automated - - - id: SLEM-05-291015 - levels: - - medium - title: SLEM 5 must disable the USB mass storage kernel module. - rules: - - kernel_module_usb-storage_disabled - status: automated - - - id: SLEM-05-411010 - levels: - - medium - title: All SLEM 5 local interactive user accounts, upon creation, must be assigned a home directory. - rules: - - accounts_have_homedir_login_defs - status: automated - - - id: SLEM-05-411015 - levels: - - medium - title: SLEM 5 default permissions must be defined in such a way that all authenticated users can - only read and modify their own files. - rules: - - accounts_umask_etc_login_defs - status: automated - - - id: SLEM-05-411020 - levels: - - medium - title: SLEM 5 shadow password suite must be configured to enforce a delay of at least five seconds - between logon prompts following a failed logon attempt. - rules: - - accounts_logon_fail_delay - - var_accounts_fail_delay=5 - status: automated - - - id: SLEM-05-411025 - levels: - - medium - title: All SLEM 5 local interactive users must have a home directory assigned in the /etc/passwd - file. - rules: - - accounts_user_interactive_home_directory_defined - status: automated - - - id: SLEM-05-411030 - levels: - - medium - title: All SLEM 5 local interactive user home directories defined in the /etc/passwd file must - exist. - rules: - - accounts_user_interactive_home_directory_exists - status: automated - - - id: SLEM-05-411035 - levels: - - medium - title: All SLEM 5 local interactive user initialization files executable search paths must contain - only paths that resolve to the users' home directory. - rules: - - accounts_user_home_paths_only - status: automated - - - id: SLEM-05-411040 - levels: - - medium - title: All SLEM 5 local initialization files must not execute world-writable programs. - rules: - - accounts_user_dot_no_world_writable_programs - status: automated - - - id: SLEM-05-411045 - levels: - - medium - title: SLEM 5 must automatically expire temporary accounts within 72 hours. - rules: - - account_temp_expire_date - status: automated - - - id: SLEM-05-411050 - levels: - - medium - title: SLEM 5 must never automatically remove or disable emergency administrator accounts. - rules: - - account_emergency_admin - status: automated - - - id: SLEM-05-411055 - levels: - - medium - title: SLEM 5 must not have unnecessary accounts. - rules: - - accounts_authorized_local_users - - var_accounts_authorized_local_users_regex=slmicro5 - status: automated - - - id: SLEM-05-411060 - levels: - - medium - title: SLEM 5 must not have unnecessary account capabilities. - rules: - - no_shelllogin_for_systemaccounts - status: automated - - - id: SLEM-05-411065 - levels: - - high - title: SLEM 5 root account must be the only account with unrestricted access to the system. - rules: - - accounts_no_uid_except_zero - status: automated - - - id: SLEM-05-411070 - levels: - - medium - title: SLEM 5 must disable account identifiers (individuals, groups, roles, and devices) after - 35 days of inactivity after password expiration. - rules: - - account_disable_post_pw_expiration - status: automated - - - id: SLEM-05-411075 - levels: - - medium - title: SLEM 5 must not have duplicate User IDs (UIDs) for interactive users. - rules: - - account_unique_id - status: automated - - - id: SLEM-05-412010 - levels: - - medium - title: SLEM 5 must display the date and time of the last successful account logon upon logon. - rules: - - display_login_attempts - status: automated - - - id: SLEM-05-412015 - levels: - - medium - title: SLEM 5 must initiate a session lock after a 15-minute period of inactivity. - rules: - - accounts_tmout - - var_accounts_tmout=15_min - status: automated - - - id: SLEM-05-412020 - levels: - - medium - title: SLEM 5 must lock an account after three consecutive invalid access attempts. - rules: - - accounts_passwords_pam_tally2 - - var_password_pam_tally2=3 - status: automated - - - id: SLEM-05-412025 - levels: - - medium - title: SLEM 5 must enforce a delay of at least five seconds between logon prompts following a failed - logon attempt via pluggable authentication modules (PAM). - rules: - - accounts_passwords_pam_faildelay_delay - - var_password_pam_delay=4000000 - status: automated - - - id: SLEM-05-412035 - levels: - - low - title: SLEM 5 must limit the number of concurrent sessions to 10 for all accounts and/or account - types. - rules: - - accounts_max_concurrent_login_sessions - - var_accounts_max_concurrent_login_sessions=10 - status: automated - - - id: SLEM-05-431010 - levels: - - low - title: SLEM 5 must have policycoreutils package installed. - rules: - - package_policycoreutils_installed - status: automated - - - id: SLEM-05-431015 - levels: - - high - title: SLEM 5 must use a Linux Security Module configured to enforce limits on system services. - rules: - - selinux_state - - var_selinux_state=enforcing - status: automated - - - id: SLEM-05-431020 - levels: - - medium - title: SLEM 5 must enable the SELinux targeted policy. - rules: - - selinux_policytype - - var_selinux_policy_name=targeted - status: automated - - - id: SLEM-05-431025 - levels: - - medium - title: SLEM 5 must prevent nonprivileged users from executing privileged functions, including disabling, - circumventing, or altering implemented security safeguards/countermeasures. - rules: - - selinux_user_login_roles - status: manual - - - id: SLEM-05-432010 - levels: - - medium - title: SLEM 5 must use the invoking user's password for privilege escalation when using "sudo". - rules: - - sudoers_validate_passwd - status: automated - - - id: SLEM-05-432015 - levels: - - medium - title: SLEM 5 must reauthenticate users when changing authenticators, roles, or escalating privileges. - rules: - - sudo_require_authentication - - sudo_remove_nopasswd - - sudo_remove_no_authenticate - status: automated - - - id: SLEM-05-432020 - levels: - - medium - title: SLEM 5 must require reauthentication when using the "sudo" command. - rules: - - sudo_require_reauthentication - status: automated - - - id: SLEM-05-432025 - levels: - - medium - title: SLEM 5 must restrict privilege elevation to authorized personnel. - rules: - - sudo_restrict_privilege_elevation_to_authorized - status: automated - - - id: SLEM-05-432030 - levels: - - medium - title: SLEM 5 must specify the default "include" directory for the /etc/sudoers file. - rules: - - sudoers_default_includedir - status: automated - - - id: SLEM-05-611010 - levels: - - medium - title: SLEM 5 must enforce passwords that contain at least one uppercase character. - rules: - - cracklib_accounts_password_pam_ucredit - status: automated - - - id: SLEM-05-611015 - levels: - - medium - title: SLEM 5 must enforce passwords that contain at least one lowercase character. - rules: - - cracklib_accounts_password_pam_lcredit - status: automated - - - id: SLEM-05-611020 - levels: - - medium - title: SLEM 5 must enforce passwords that contain at least one numeric character. - rules: - - cracklib_accounts_password_pam_dcredit - status: automated - - - id: SLEM-05-611025 - levels: - - medium - title: SLEM 5 must enforce passwords that contain at least one special character. - rules: - - cracklib_accounts_password_pam_ocredit - status: automated - - - id: SLEM-05-611030 - levels: - - medium - title: SLEM 5 must prevent the use of dictionary words for passwords. - rules: - - cracklib_accounts_password_pam_retry - - var_password_pam_retry=3 - status: automated - - - id: SLEM-05-611035 - levels: - - medium - title: SLEM 5 must employ passwords with a minimum of 15 characters. - rules: - - cracklib_accounts_password_pam_minlen - status: automated - - - id: SLEM-05-611040 - levels: - - medium - title: SLEM 5 must require the change of at least eight of the total number of characters when - passwords are changed. - rules: - - cracklib_accounts_password_pam_difok - status: automated - - - id: SLEM-05-611045 - levels: - - medium - title: SLEM 5 must not allow passwords to be reused for a minimum of five generations. - rules: - - accounts_password_pam_pwhistory_remember - - var_password_pam_remember_control_flag=requisite - - var_password_pam_remember=5 - status: automated - - - id: SLEM-05-611050 - levels: - - medium - title: SLEM 5 must configure the Linux Pluggable Authentication Modules (PAM) to only store encrypted - representations of passwords. - rules: - - set_password_hashing_algorithm_systemauth - status: automated - - - id: SLEM-05-611055 - levels: - - high - title: SLEM 5 must not be configured to allow blank or null passwords. - rules: - - no_empty_passwords - status: automated - - - id: SLEM-05-611060 - levels: - - high - title: SLEM 5 must not have accounts configured with blank or null passwords. - rules: - - no_empty_passwords_etc_shadow - status: automated - - - id: SLEM-05-611065 - levels: - - medium - title: SLEM 5 must employ user passwords with a minimum lifetime of 24 hours (one day). - rules: - - accounts_password_set_min_life_existing - - var_accounts_minimum_age_login_defs=1 - status: automated - - - id: SLEM-05-611070 - levels: - - medium - title: SLEM 5 must employ user passwords with a maximum lifetime of 60 days. - rules: - - accounts_password_set_max_life_existing - - var_accounts_maximum_age_login_defs=60 - status: automated - - - id: SLEM-05-611075 - levels: - - medium - title: SLEM 5 must employ a password history file. - rules: - - file_etc_security_opasswd - status: automated - - - id: SLEM-05-611080 - levels: - - high - title: SLEM 5 must employ FIPS 140-2/140-3-approved cryptographic hashing algorithms for system - authentication. - rules: - - accounts_password_all_shadowed_sha512 - status: automated - - - id: SLEM-05-611085 - levels: - - high - title: SLEM 5 shadow password suite must be configured to use a sufficient number of hashing rounds. - rules: - - set_password_hashing_min_rounds_logindefs - status: automated - - - id: SLEM-05-611090 - levels: - - medium - title: SLEM 5 must employ FIPS 140-2/140-3 approved cryptographic hashing algorithm for system - authentication (login.defs). - rules: - - set_password_hashing_algorithm_logindefs - - var_password_hashing_algorithm=SHA512 - status: automated - - - id: SLEM-05-611095 - levels: - - medium - title: SLEM 5 must be configured to create or update passwords with a minimum lifetime of 24 hours - (one day). - rules: - - accounts_minimum_age_login_defs - status: automated - - - id: SLEM-05-611100 - levels: - - medium - title: SLEM 5 must be configured to create or update passwords with a maximum lifetime of 60 days. - rules: - - accounts_maximum_age_login_defs - status: automated - - - id: SLEM-05-612010 - levels: - - medium - title: SLEM 5 must have the packages required for multifactor authentication to be installed. - rules: - - install_smartcard_packages - status: automated - - - id: SLEM-05-612015 - levels: - - medium - title: SLEM 5 must implement multifactor authentication for access to privileged accounts via pluggable - authentication modules (PAM). - rules: - - smartcard_pam_enabled - status: automated - - - id: SLEM-05-612020 - levels: - - medium - title: SLEM 5 must implement certificate status checking for multifactor authentication. - rules: - - smartcard_configure_cert_checking - status: automated - - - id: SLEM-05-631010 - levels: - - medium - title: If Network Security Services (NSS) is being used by SLEM 5 it must prohibit the use of cached - authentications after one day. - rules: - - sssd_memcache_timeout - - var_sssd_memcache_timeout=1_day - status: automated - - - id: SLEM-05-631015 - levels: - - medium - title: SLEM 5 must configure the Linux Pluggable Authentication Modules (PAM) to prohibit the use - of cached offline authentications after one day. - rules: - - sssd_offline_cred_expiration - status: automated - - - id: SLEM-05-631020 - levels: - - medium - title: SLEM 5, for PKI-based authentication, must validate certificates by constructing a certification - path (which includes status information) to an accepted trust anchor. - rules: - - smartcard_configure_ca - status: automated - - - id: SLEM-05-631025 - levels: - - medium - title: SLEM 5 must be configured to not overwrite Pluggable Authentication Modules (PAM) configuration - on package changes. - rules: - - pam_disable_automatic_configuration - status: automated - - - id: SLEM-05-651010 - levels: - - medium - title: SLEM 5 must use a file integrity tool to verify correct operation of all security functions. - rules: - - package_aide_installed - - aide_build_database - status: automated - - - id: SLEM-05-651015 - levels: - - medium - title: SLEM 5 file integrity tool must be configured to verify Access Control Lists (ACLs). - rules: - - aide_verify_acls - status: automated - - - id: SLEM-05-651020 - levels: - - medium - title: SLEM 5 file integrity tool must be configured to verify extended attributes. - rules: - - aide_verify_ext_attributes - status: automated - - - id: SLEM-05-651025 - levels: - - medium - title: SLEM 5 file integrity tool must be configured to protect the integrity of the audit tools. - rules: - - aide_check_audit_tools - status: automated - - - id: SLEM-05-651030 - levels: - - medium - title: Advanced Intrusion Detection Environment (AIDE) must verify the baseline SLEM 5 configuration - at least weekly. - rules: - - aide_periodic_checking_systemd_timer - status: automated - - - id: SLEM-05-651035 - levels: - - medium - title: SLEM 5 must notify the system administrator (SA) when Advanced Intrusion Detection Environment - (AIDE) discovers anomalies in the operation of any security functions. - rules: - - aide_scan_notification - status: automated - - - id: SLEM-05-652010 - levels: - - medium - title: SLEM 5 must offload rsyslog messages for networked systems in real time and offload standalone - systems at least weekly. - rules: - - package_systemd-journal-remote_installed - - service_systemd-journal-upload_enabled - - systemd_journal_upload_url - - systemd_journal_upload_server_tls - status: manual # do not assume anything set external variables before use - - - id: SLEM-05-653010 - levels: - - medium - title: SLEM 5 must have the auditing package installed. - rules: - - package_audit_installed - status: automated - - - id: SLEM-05-653015 - levels: - - medium - title: SLEM 5 audit records must contain information to establish what type of events occurred, - the source of events, where events occurred, and the outcome of events. - rules: - - service_auditd_enabled - status: automated - - - id: SLEM-05-653020 - levels: - - medium - title: The audit-audispd-plugins package must be installed on SLEM 5. - rules: - - package_audit-audispd-plugins_installed - status: automated - - - id: SLEM-05-653025 - levels: - - medium - title: SLEM 5 must allocate audit record storage capacity to store at least one week of audit records - when audit records are not immediately sent to a central audit record storage facility. - rules: - - auditd_audispd_configure_sufficiently_large_partition - status: automated - - - id: SLEM-05-653030 - levels: - - medium - title: SLEM 5 auditd service must notify the system administrator (SA) and information system security - officer (ISSO) immediately when audit storage capacity is 75 percent full. - rules: - - auditd_data_retention_space_left_percentage - - var_auditd_space_left_percentage=25pc - - auditd_data_retention_space_left_action - - var_auditd_space_left_action=email - status: automated - - - id: SLEM-05-653035 - levels: - - medium - title: SLEM 5 audit system must take appropriate action when the audit storage volume is full. - rules: - - auditd_data_disk_full_action - status: automated - - - id: SLEM-05-653040 - levels: - - medium - title: SLEM 5 must offload audit records onto a different system or media from the system being - audited. - rules: - - auditd_audispd_network_failure_action - status: automated - - - id: SLEM-05-653045 - levels: - - medium - title: Audispd must take appropriate action when SLEM 5 audit storage is full. - rules: - - auditd_audispd_disk_full_action - status: automated - - - id: SLEM-05-653050 - levels: - - medium - title: SLEM 5 must protect audit rules from unauthorized modification. - rules: - - permissions_local_var_log_audit - status: automated - - - id: SLEM-05-653055 - levels: - - medium - title: SLEM 5 audit tools must have the proper permissions configured to protect against unauthorized - access. - rules: - - permissions_local_audit_binaries - status: automated - - - id: SLEM-05-653060 - levels: - - medium - title: SLEM 5 audit tools must have the proper permissions applied to protect against unauthorized - access. - rules: [] - status: manual - - - id: SLEM-05-653065 - levels: - - low - title: SLEM 5 audit event multiplexor must be configured to use Kerberos. - rules: - - auditd_audispd_encrypt_sent_records - status: automated - - - id: SLEM-05-653070 - levels: - - medium - title: Audispd must offload audit records onto a different system or media from SLEM 5 being audited. - rules: - - auditd_audispd_configure_remote_server - status: automated - - - id: SLEM-05-653075 - levels: - - medium - title: The information system security officer (ISSO) and system administrator (SA), at a minimum, - must have mail aliases to be notified of a SLEM 5 audit processing failure. - rules: - - postfix_client_configure_mail_alias - status: automated - - - id: SLEM-05-653080 - levels: - - medium - title: The information system security officer (ISSO) and system administrator (SA), at a minimum, - must be alerted of a SLEM 5 audit processing failure event. - rules: - - auditd_data_retention_action_mail_acct - status: automated - - - id: SLEM-05-654010 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chacl" command. - rules: - - audit_rules_execution_chacl - status: automated - - - id: SLEM-05-654015 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chage" command. - rules: - - audit_rules_privileged_commands_chage - status: automated - - - id: SLEM-05-654020 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chcon" command. - rules: - - audit_rules_execution_chcon - status: automated - - - id: SLEM-05-654025 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chfn" command. - rules: - - audit_rules_privileged_commands_chfn - status: automated - - - id: SLEM-05-654030 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chmod" command. - rules: - - audit_rules_execution_chmod - status: automated - - - id: SLEM-05-654035 - levels: - - medium - title: SLEM 5 must generate audit records for a uses of the "chsh" command. - rules: - - audit_rules_privileged_commands_chsh - status: automated - - - id: SLEM-05-654040 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "crontab" command. - rules: - - audit_rules_privileged_commands_crontab - status: automated - - - id: SLEM-05-654045 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "gpasswd" command. - rules: - - audit_rules_privileged_commands_gpasswd - status: automated - - - id: SLEM-05-654050 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "insmod" command. - rules: - - audit_rules_privileged_commands_insmod - status: automated - - - id: SLEM-05-654055 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "kmod" command. - rules: - - audit_rules_privileged_commands_kmod - status: automated - - - id: SLEM-05-654060 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "modprobe" command. - rules: - - audit_rules_privileged_commands_modprobe - status: automated - - - id: SLEM-05-654065 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "newgrp" command. - rules: - - audit_rules_privileged_commands_newgrp - status: automated - - - id: SLEM-05-654070 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "pam_timestamp_check" command. - rules: - - audit_rules_privileged_commands_pam_timestamp_check - status: automated - - - id: SLEM-05-654075 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "passwd" command. - rules: - - audit_rules_privileged_commands_passwd - status: automated - - - id: SLEM-05-654080 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "rm" command. - rules: - - audit_rules_execution_rm - status: automated - - - id: SLEM-05-654085 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "rmmod" command. - rules: - - audit_rules_privileged_commands_rmmod - status: automated - - - id: SLEM-05-654090 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "setfacl" command. - rules: - - audit_rules_execution_setfacl - status: automated - - - id: SLEM-05-654095 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "ssh-agent" command. - rules: - - audit_rules_privileged_commands_ssh_agent - status: automated - - - id: SLEM-05-654100 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "ssh-keysign" command. - rules: - - audit_rules_privileged_commands_ssh_keysign - status: automated - - - id: SLEM-05-654105 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "su" command. - rules: - - audit_rules_privileged_commands_su - status: automated - - - id: SLEM-05-654110 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "sudo" command. - rules: - - audit_rules_privileged_commands_sudo - status: automated - - - id: SLEM-05-654115 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "sudoedit" command. - rules: - - audit_rules_privileged_commands_sudoedit - status: automated - - - id: SLEM-05-654120 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "unix_chkpwd" or "unix2_chkpwd" commands. - rules: - - audit_rules_privileged_commands_unix_chkpwd - status: automated - - - id: SLEM-05-654125 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "usermod" command. - rules: - - audit_rules_privileged_commands_usermod - status: automated - - - id: SLEM-05-654130 - levels: - - medium - title: SLEM 5 must generate audit records for all account creations, modifications, disabling, - and termination events that affect /etc/group. - rules: - - audit_rules_usergroup_modification_group - status: automated - - - id: SLEM-05-654135 - levels: - - medium - title: SLEM 5 must generate audit records for all account creations, modifications, disabling, - and termination events that affect /etc/security/opasswd. - rules: - - audit_rules_usergroup_modification_opasswd - status: automated - - - id: SLEM-05-654140 - levels: - - medium - title: SLEM 5 must generate audit records for all account creations, modifications, disabling, - and termination events that affect /etc/passwd. - rules: - - audit_rules_usergroup_modification_passwd - status: automated - - - id: SLEM-05-654145 - levels: - - medium - title: SLEM 5 must generate audit records for all account creations, modifications, disabling, - and termination events that affect /etc/shadow. - rules: - - audit_rules_usergroup_modification_shadow - status: automated - - - id: SLEM-05-654150 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chmod", "fchmod" and "fchmodat" - system calls. - rules: - - audit_rules_dac_modification_fchmod - status: automated - - - id: SLEM-05-654155 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "chown", "fchown", "fchownat", and - "lchown" system calls. - rules: - - audit_rules_dac_modification_lchown - status: automated - - - id: SLEM-05-654160 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "creat", "open", "openat", "open_by_handle_at", - "truncate", and "ftruncate" system calls. - rules: - - audit_rules_unsuccessful_file_modification_open - status: automated - - - id: SLEM-05-654165 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "delete_module" system call. - rules: - - audit_rules_kernel_module_loading_delete - status: automated - - - id: SLEM-05-654170 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "init_module" and "finit_module" - system calls. - rules: - - audit_rules_kernel_module_loading_finit - status: automated - - - id: SLEM-05-654175 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "mount" system call. - rules: - - audit_rules_media_export - status: automated - - - id: SLEM-05-654180 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "setxattr", "fsetxattr", "lsetxattr", - "removexattr", "fremovexattr", and "lremovexattr" system calls. - rules: - - audit_rules_dac_modification_fremovexattr - status: automated - - - id: SLEM-05-654185 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "umount" system call. - rules: - - audit_rules_dac_modification_umount2 - status: automated - - - id: SLEM-05-654190 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of the "unlink", "unlinkat", "rename", "renameat", - and "rmdir" system calls. - rules: - - audit_rules_unsuccessful_file_modification_rename - status: automated - - - id: SLEM-05-654195 - levels: - - medium - title: SLEM 5 must generate audit records for all uses of privileged functions. - rules: - - audit_rules_suid_privilege_function - status: automated - - - id: SLEM-05-654200 - levels: - - medium - title: SLEM 5 must generate audit records for all modifications to the "lastlog" file. - rules: - - audit_rules_login_events_lastlog - status: automated - - - id: SLEM-05-654205 - levels: - - medium - title: SLEM 5 must generate audit records for all modifications to the "tallylog" file must generate - an audit record. - rules: - - audit_rules_login_events_tallylog - status: automated - - - id: SLEM-05-654210 - levels: - - medium - title: SLEM 5 must audit all uses of the sudoers file and all files in the "/etc/sudoers.d/" directory. - rules: - - audit_rules_sysadmin_actions - status: automated - - - id: SLEM-05-654215 - levels: - - medium - title: Successful/unsuccessful uses of "setfiles" in SLEM 5 must generate an audit record. - rules: - - audit_rules_execution_setfiles - status: automated - - - id: SLEM-05-654220 - levels: - - medium - title: Successful/unsuccessful uses of "semanage" in SLEM 5 must generate an audit record. - rules: - - package_policycoreutils-python-utils_installed - - audit_rules_execution_semanage - status: automated - - - id: SLEM-05-654225 - levels: - - medium - title: Successful/unsuccessful uses of "setsebool" in SLEM 5 must generate an audit record. - rules: - - audit_rules_execution_setsebool - status: automated - - - id: SLEM-05-654230 - levels: - - medium - title: SLEM 5 must generate audit records for the "/run/utmp file". - rules: - - audit_rules_session_events_utmp - status: automated - - - id: SLEM-05-654235 - levels: - - medium - title: SLEM 5 must generate audit records for the "/var/log/btmp" file. - rules: - - audit_rules_session_events_btmp - status: automated - - - id: SLEM-05-654240 - levels: - - medium - title: SLEM 5 must generate audit records for the "/var/log/wtmp" file. - rules: - - audit_rules_session_events_wtmp - status: automated - - - id: SLEM-05-654245 - levels: - - medium - title: SLEM 5 must not disable syscall auditing. - rules: - - audit_rules_enable_syscall_auditing - status: automated - - - id: SLEM-05-671010 - levels: - - high - title: FIPS 140-2/140-3 mode must be enabled on SLEM 5. - rules: - - is_fips_mode_enabled - status: automated + - id: SLEM-05-211010 + levels: + - high + title: SLEM 5 must be a vendor-supported release. + rules: + - installed_OS_is_vendor_supported + status: automated + + - id: SLEM-05-211020 + levels: + - medium + title: SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner + before granting any local or remote connection to the system. + rules: + - banner_etc_issue + - login_banner_text=dod_banners + - login_banner_contents=dod_default + status: automated + + - id: SLEM-05-211025 + levels: + - high + title: SLEM 5 must disable the x86 Ctrl-Alt-Delete key sequence. + rules: + - disable_ctrlaltdel_reboot + status: automated + + - id: SLEM-05-212010 + levels: + - high + title: SLEM 5 with a basic input/output system (BIOS) must require + authentication upon booting into single-user and maintenance modes. + rules: + - grub2_password + status: automated + + - id: SLEM-05-212015 + levels: + - high + title: SLEM 5 with Unified Extensible Firmware Interface (UEFI) implemented must + require authentication upon booting into single-user mode and maintenance. + rules: + - grub2_uefi_password + status: automated + + - id: SLEM-05-213010 + levels: + - medium + title: SLEM 5 must restrict access to the kernel message buffer. + rules: + - sysctl_kernel_dmesg_restrict + status: automated + + - id: SLEM-05-213015 + levels: + - medium + title: SLEM 5 kernel core dumps must be disabled unless needed. + rules: + - service_kdump_disabled + status: automated + + - id: SLEM-05-213020 + levels: + - medium + title: Address space layout randomization (ASLR) must be implemented by SLEM 5 + to protect memory from unauthorized code execution. + rules: + - sysctl_kernel_randomize_va_space + status: automated + + - id: SLEM-05-213025 + levels: + - medium + title: SLEM 5 must implement kptr-restrict to prevent the leaking of internal + kernel addresses. + rules: + - sysctl_kernel_kptr_restrict + status: automated + + - id: SLEM-05-214010 + levels: + - medium + title: Vendor-packaged SLEM 5 security patches and updates must be installed and + up to date. + rules: + - security_patches_up_to_date + status: automated + + - id: SLEM-05-214015 + levels: + - high + title: The SLEM 5 tool zypper must have gpgcheck enabled. + rules: + - ensure_gpgcheck_globally_activated + status: automated + + - id: SLEM-05-214020 + levels: + - medium + title: SLEM 5 must remove all outdated software components after updated + versions have been installed. + rules: + - clean_components_post_updating + status: automated + + - id: SLEM-05-215010 + levels: + - medium + title: SLEM 5 must use vlock to allow for session locking. + rules: + - vlock_installed + status: automated + + - id: SLEM-05-215015 + levels: + - high + title: SLEM 5 must not have the telnet-server package installed. + rules: + - package_telnet-server_removed + status: automated + + - id: SLEM-05-231010 + levels: + - medium + title: A separate file system must be used for SLEM 5 user home directories + (such as /home or an equivalent). + rules: + - partition_for_home + status: automated + + - id: SLEM-05-231015 + levels: + - medium + title: SLEM 5 must use a separate file system for /var. + rules: + - partition_for_var + status: automated + + - id: SLEM-05-231020 + levels: + - medium + title: SLEM 5 must use a separate file system for the system audit data path. + rules: + - partition_for_var_log_audit + status: automated + + - id: SLEM-05-231025 + levels: + - medium + title: SLEM 5 file systems that are being imported via Network File System (NFS) + must be mounted to prevent files with the setuid and setgid bit set from + being executed. + rules: + - mount_option_nosuid_remote_filesystems + status: automated + + - id: SLEM-05-231030 + levels: + - medium + title: SLEM 5 file systems that are being imported via Network File System (NFS) + must be mounted to prevent binary files from being executed. + rules: + - mount_option_noexec_remote_filesystems + status: automated + + - id: SLEM-05-231035 + levels: + - medium + title: SLEM 5 file systems that are used with removable media must be mounted to + prevent files with the setuid and setgid bit set from being executed. + rules: + - mount_option_nosuid_removable_partitions + status: automated + + - id: SLEM-05-231040 + levels: + - high + title: All SLEM 5 persistent disk partitions must implement cryptographic + mechanisms to prevent unauthorized disclosure or modification of all + information that requires at-rest protection. + rules: + - encrypt_partitions + status: automated + + - id: SLEM-05-231045 + levels: + - medium + title: SLEM 5 file systems that contain user home directories must be mounted to + prevent files with the setuid and setgid bit set from being executed. + rules: + - mount_option_home_nosuid + status: automated + + - id: SLEM-05-231050 + levels: + - medium + title: SLEM 5 must disable the file system automounter unless required. + rules: + - service_autofs_disabled + status: automated + + - id: SLEM-05-232010 + levels: + - medium + title: SLEM 5 must have directories that contain system commands set to a mode + of 755 or less permissive. + rules: + - dir_permissions_binary_dirs + status: automated + + - id: SLEM-05-232015 + levels: + - medium + title: SLEM 5 must have system commands set to a mode of 755 or less permissive. + rules: + - file_permissions_binary_dirs + status: automated + + - id: SLEM-05-232020 + levels: + - medium + title: SLEM 5 library directories must have mode 755 or less permissive. + rules: + - dir_permissions_library_dirs + status: automated + + - id: SLEM-05-232025 + levels: + - medium + title: SLEM 5 library files must have mode 755 or less permissive. + rules: + - file_permissions_library_dirs + status: automated + + - id: SLEM-05-232030 + levels: + - medium + title: All SLEM 5 local interactive user home directories must have mode 750 or + less permissive. + rules: + - file_permissions_home_directories + status: automated + + - id: SLEM-05-232035 + levels: + - medium + title: All SLEM 5 local initialization files must have mode 740 or less + permissive. + rules: + - file_permission_user_init_files + status: automated + + - id: SLEM-05-232040 + levels: + - medium + title: SLEM 5 SSH daemon public host key files must have mode 644 or less + permissive. + rules: + - file_permissions_sshd_pub_key + status: automated + + - id: SLEM-05-232045 + levels: + - medium + title: SLEM 5 SSH daemon private host key files must have mode 640 or less + permissive. + rules: + - file_permissions_sshd_private_key + status: automated + + - id: SLEM-05-232050 + levels: + - medium + title: SLEM 5 library files must be owned by root. + rules: + - file_ownership_library_dirs + status: automated + + - id: SLEM-05-232055 + levels: + - medium + title: SLEM 5 library files must be group-owned by root. + rules: + - root_permissions_syslibrary_files + status: automated + + - id: SLEM-05-232060 + levels: + - medium + title: SLEM 5 library directories must be owned by root. + rules: + - dir_ownership_library_dirs + status: automated + + - id: SLEM-05-232065 + levels: + - medium + title: SLEM 5 library directories must be group-owned by root. + rules: + - dir_group_ownership_library_dirs + status: automated + + - id: SLEM-05-232070 + levels: + - medium + title: SLEM 5 must have system commands owned by root. + rules: + - file_ownership_binary_dirs + status: automated + + - id: SLEM-05-232075 + levels: + - medium + title: SLEM 5 must have system commands group-owned by root or a system account. + rules: + - file_groupownership_system_commands_dirs + status: automated + + - id: SLEM-05-232080 + levels: + - medium + title: SLEM 5 must have directories that contain system commands owned by root. + rules: + - dir_system_commands_root_owned + status: automated + + - id: SLEM-05-232085 + levels: + - medium + title: SLEM 5 must have directories that contain system commands group-owned by + root. + rules: + - dir_system_commands_group_root_owned + status: automated + + - id: SLEM-05-232090 + levels: + - medium + title: All SLEM 5 files and directories must have a valid owner. + rules: + - no_files_unowned_by_user + status: automated + + - id: SLEM-05-232095 + levels: + - medium + title: All SLEM 5 files and directories must have a valid group owner. + rules: + - file_permissions_ungroupowned + status: automated + + - id: SLEM-05-232100 + levels: + - medium + title: All SLEM 5 local interactive user home directories must be group-owned by + the home directory owner's primary group. + rules: + - file_groupownership_home_directories + status: automated + + - id: SLEM-05-232105 + levels: + - medium + title: All SLEM 5 world-writable directories must be group-owned by root, sys, + bin, or an application group. + rules: + - dir_perms_world_writable_system_owned_group + status: automated + + - id: SLEM-05-232110 + levels: + - medium + title: The sticky bit must be set on all SLEM 5 world-writable directories. + rules: + - dir_perms_world_writable_sticky_bits + status: automated + + - id: SLEM-05-232115 + levels: + - medium + title: SLEM 5 must prevent unauthorized users from accessing system error + messages. + rules: + - file_permissions_local_var_log_messages + status: automated + + - id: SLEM-05-232120 + levels: + - medium + title: SLEM 5 must generate error messages that provide information necessary + for corrective actions without revealing information that could be + exploited by adversaries. + rules: + - permissions_local_var_log + status: automated + + - id: SLEM-05-251010 + levels: + - medium + title: SLEM 5 must be configured to prohibit or restrict the use of functions, + ports, protocols, and/or services as defined in the Ports, Protocols, and + Services Management (PPSM) Category Assignments List (CAL) and + vulnerability assessments. + rules: + - service_firewalld_enabled + status: automated + + - id: SLEM-05-252010 + levels: + - medium + title: SLEM 5 clock must, for networked systems, be synchronized to an + authoritative DOD time source at least every 24 hours. + rules: + - chronyd_or_ntpd_set_maxpoll + - chronyd_specify_remote_server + - var_multiple_time_servers=stig + - var_time_service_set_maxpoll=18_hours + status: automated + + - id: SLEM-05-252015 + levels: + - medium + title: SLEM 5 must not have network interfaces in promiscuous mode unless + approved and documented. + rules: + - network_sniffer_disabled + status: automated + + - id: SLEM-05-253010 + levels: + - medium + title: SLEM 5 must not forward Internet Protocol version 4 (IPv4) source-routed + packets. + rules: + - sysctl_net_ipv4_conf_all_accept_source_route + status: automated + + - id: SLEM-05-253015 + levels: + - medium + title: SLEM 5 must not forward Internet Protocol version 4 (IPv4) source-routed + packets by default. + rules: + - sysctl_net_ipv4_conf_default_accept_source_route + status: automated + + - id: SLEM-05-253020 + levels: + - medium + title: SLEM 5 must prevent Internet Protocol version 4 (IPv4) Internet Control + Message Protocol (ICMP) redirect messages from being accepted. + rules: + - sysctl_net_ipv4_conf_all_accept_redirects + status: automated + + - id: SLEM-05-253025 + levels: + - medium + title: SLEM 5 must not allow interfaces to accept Internet Protocol version 4 + (IPv4) Internet Control Message Protocol (ICMP) redirect messages by + default. + rules: + - sysctl_net_ipv4_conf_default_accept_redirects + status: automated + + - id: SLEM-05-253030 + levels: + - medium + title: SLEM 5 must not send Internet Protocol version 4 (IPv4) Internet Control + Message Protocol (ICMP) redirects. + rules: + - sysctl_net_ipv4_conf_all_send_redirects + status: automated + + - id: SLEM-05-253035 + levels: + - medium + title: SLEM 5 must not allow interfaces to send Internet Protocol version 4 + (IPv4) Internet Control Message Protocol (ICMP) redirect messages by + default. + rules: + - sysctl_net_ipv4_conf_default_send_redirects + status: automated + + - id: SLEM-05-253040 + levels: + - medium + title: SLEM 5 must not be performing Internet Protocol version 4 (IPv4) packet + forwarding unless the system is a router. + rules: + - sysctl_net_ipv4_ip_forward + status: automated + + - id: SLEM-05-253045 + levels: + - medium + title: SLEM 5 must be configured to use TCP syncookies. + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + + - id: SLEM-05-254010 + levels: + - medium + title: SLEM 5 must not forward Internet Protocol version 6 (IPv6) source-routed + packets. + rules: + - sysctl_net_ipv6_conf_all_accept_source_route + status: automated + + - id: SLEM-05-254015 + levels: + - medium + title: SLEM 5 must not forward Internet Protocol version 6 (IPv6) source-routed + packets by default. + rules: + - sysctl_net_ipv6_conf_default_accept_source_route + status: automated + + - id: SLEM-05-254020 + levels: + - medium + title: SLEM 5 must prevent Internet Protocol version 6 (IPv6) Internet Control + Message Protocol (ICMP) redirect messages from being accepted. + rules: + - sysctl_net_ipv6_conf_all_accept_redirects + status: automated + + - id: SLEM-05-254025 + levels: + - medium + title: SLEM 5 must not allow interfaces to accept Internet Protocol version 6 + (IPv6) Internet Control Message Protocol (ICMP) redirect messages by + default. + rules: + - sysctl_net_ipv6_conf_default_accept_redirects + status: automated + + - id: SLEM-05-254030 + levels: + - medium + title: SLEM 5 must not be performing Internet Protocol version 6 (IPv6) packet + forwarding unless the system is a router. + rules: + - sysctl_net_ipv6_conf_all_forwarding + status: automated + + - id: SLEM-05-254035 + levels: + - medium + title: SLEM 5 must not be performing Internet Protocol version 6 (IPv6) packet + forwarding by default unless the system is a router. + rules: + - sysctl_net_ipv6_conf_default_forwarding + status: automated + + - id: SLEM-05-255010 + levels: + - high + title: SLEM 5 must have SSH installed to protect the confidentiality and + integrity of transmitted information. + rules: + - package_openssh-server_installed + status: automated + + - id: SLEM-05-255015 + levels: + - high + title: SLEM 5 must use SSH to protect the confidentiality and integrity of + transmitted information. + rules: + - service_sshd_enabled + status: automated + + - id: SLEM-05-255020 + levels: + - medium + title: SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner + before granting access via SSH. + rules: + - sshd_enable_warning_banner + status: automated + + - id: SLEM-05-255025 + levels: + - high + title: SLEM 5 must not allow unattended or automatic logon via SSH. + rules: + - sshd_disable_empty_passwords + - sshd_do_not_permit_user_env + status: automated + + - id: SLEM-05-255030 + levels: + - medium + title: SLEM 5 must be configured so that all network connections associated with + SSH traffic terminate after becoming unresponsive. + rules: + - sshd_set_keepalive + - var_sshd_set_keepalive=1 + status: automated + + - id: SLEM-05-255035 + levels: + - medium + title: SLEM 5 must be configured so that all network connections associated with + SSH traffic are terminated after 10 minutes of becoming unresponsive. + rules: + - sshd_set_idle_timeout + - sshd_idle_timeout_value=10_minutes + status: automated + + - id: SLEM-05-255040 + levels: + - medium + title: SLEM 5 SSH daemon must disable forwarded remote X connections for + interactive users, unless to fulfill documented and validated mission + requirements. + rules: + - sshd_disable_x11_forwarding + status: automated + + - id: SLEM-05-255045 + levels: + - high + title: SLEM 5 must implement DOD-approved encryption to protect the + confidentiality of SSH remote connections. + rules: + - sshd_use_approved_ciphers_ordered_stig + - sshd_use_approved_ciphers + status: automated + + - id: SLEM-05-255050 + levels: + - high + title: SLEM 5 SSH daemon must be configured to only use Message Authentication + Codes (MACs) employing FIPS 140-2/140-3 approved cryptographic hash + algorithms. + rules: + - sshd_use_approved_macs_ordered_stig + - sshd_use_approved_macs + status: automated + + - id: SLEM-05-255055 + levels: + - high + title: SLEM 5 SSH server must be configured to use only FIPS 140-2/140-3 + validated key exchange algorithms. + rules: + - sshd_use_approved_kex_ordered_stig + status: automated + + - id: SLEM-05-255060 + levels: + - medium + title: SLEM 5 must deny direct logons to the root account using remote access + via SSH. + rules: + - sshd_disable_root_login + status: automated + + - id: SLEM-05-255065 + levels: + - medium + title: SLEM 5 must log SSH connection attempts and failures to the server. + rules: + - sshd_set_loglevel_verbose + status: automated + + - id: SLEM-05-255070 + levels: + - medium + title: SLEM 5 must display the date and time of the last successful account + logon upon an SSH logon. + rules: + - sshd_print_last_log + status: automated + + - id: SLEM-05-255075 + levels: + - medium + title: SLEM 5 SSH daemon must be configured to not allow authentication using + known hosts authentication. + rules: + - sshd_disable_user_known_hosts + status: automated + + - id: SLEM-05-255080 + levels: + - medium + title: SLEM 5 SSH daemon must perform strict mode checking of home directory + configuration files. + rules: + - sshd_enable_strictmodes + status: automated + + - id: SLEM-05-255085 + levels: + - medium + title: SLEM 5, for PKI-based authentication, must enforce authorized access to + the corresponding private key. + rules: + - ssh_private_keys_have_passcode + status: manual + + - id: SLEM-05-255090 + levels: + - high + title: There must be no .shosts files on SLEM 5. + rules: + - no_user_host_based_files + status: automated + + - id: SLEM-05-255095 + levels: + - high + title: There must be no shosts.equiv files on SLEM 5. + rules: + - no_host_based_files + status: automated + + - id: SLEM-05-272010 + levels: + - high + title: SLEM 5 must not allow unattended or automatic logon via the graphical + user interface (GUI). + rules: + - gnome_gdm_disable_unattended_automatic_login + status: automated + + - id: SLEM-05-291010 + levels: + - medium + title: SLEM 5 wireless network adapters must be disabled unless approved and + documented. + rules: + - wireless_disable_interfaces + status: automated + + - id: SLEM-05-291015 + levels: + - medium + title: SLEM 5 must disable the USB mass storage kernel module. + rules: + - kernel_module_usb-storage_disabled + status: automated + + - id: SLEM-05-411010 + levels: + - medium + title: All SLEM 5 local interactive user accounts, upon creation, must be + assigned a home directory. + rules: + - accounts_have_homedir_login_defs + status: automated + + - id: SLEM-05-411015 + levels: + - medium + title: SLEM 5 default permissions must be defined in such a way that all + authenticated users can only read and modify their own files. + rules: + - accounts_umask_etc_login_defs + status: automated + + - id: SLEM-05-411020 + levels: + - medium + title: SLEM 5 shadow password suite must be configured to enforce a delay of at + least five seconds between logon prompts following a failed logon attempt. + rules: + - accounts_logon_fail_delay + - var_accounts_fail_delay=5 + status: automated + + - id: SLEM-05-411025 + levels: + - medium + title: All SLEM 5 local interactive users must have a home directory assigned in + the /etc/passwd file. + rules: + - accounts_user_interactive_home_directory_defined + status: automated + + - id: SLEM-05-411030 + levels: + - medium + title: All SLEM 5 local interactive user home directories defined in the + /etc/passwd file must exist. + rules: + - accounts_user_interactive_home_directory_exists + status: automated + + - id: SLEM-05-411035 + levels: + - medium + title: All SLEM 5 local interactive user initialization files executable search + paths must contain only paths that resolve to the users' home directory. + rules: + - accounts_user_home_paths_only + status: automated + + - id: SLEM-05-411040 + levels: + - medium + title: All SLEM 5 local initialization files must not execute world-writable + programs. + rules: + - accounts_user_dot_no_world_writable_programs + status: automated + + - id: SLEM-05-411045 + levels: + - medium + title: SLEM 5 must automatically expire temporary accounts within 72 hours. + rules: + - account_temp_expire_date + status: automated + + - id: SLEM-05-411050 + levels: + - medium + title: SLEM 5 must never automatically remove or disable emergency administrator + accounts. + rules: + - account_emergency_admin + status: automated + + - id: SLEM-05-411055 + levels: + - medium + title: SLEM 5 must not have unnecessary accounts. + rules: + - accounts_authorized_local_users + - var_accounts_authorized_local_users_regex=slmicro5 + status: automated + + - id: SLEM-05-411060 + levels: + - medium + title: SLEM 5 must not have unnecessary account capabilities. + rules: + - no_shelllogin_for_systemaccounts + status: automated + + - id: SLEM-05-411065 + levels: + - high + title: SLEM 5 root account must be the only account with unrestricted access to + the system. + rules: + - accounts_no_uid_except_zero + status: automated + + - id: SLEM-05-411070 + levels: + - medium + title: SLEM 5 must disable account identifiers (individuals, groups, roles, and + devices) after 35 days of inactivity after password expiration. + rules: + - account_disable_post_pw_expiration + status: automated + + - id: SLEM-05-411075 + levels: + - medium + title: SLEM 5 must not have duplicate User IDs (UIDs) for interactive users. + rules: + - account_unique_id + status: automated + + - id: SLEM-05-412015 + levels: + - medium + title: SLEM 5 must initiate a session lock after a 15-minute period of inactivity. + rules: + - accounts_tmout + - var_accounts_tmout=15_min + status: automated + + - id: SLEM-05-412020 + levels: + - medium + title: SLEM 5 must lock an account after three consecutive invalid access + attempts. + rules: + - accounts_passwords_pam_tally2 + - var_password_pam_tally2=3 + status: automated + + - id: SLEM-05-412025 + levels: + - medium + title: SLEM 5 must enforce a delay of at least five seconds between logon + prompts following a failed logon attempt via pluggable authentication + modules (PAM). + rules: + - accounts_passwords_pam_faildelay_delay + - var_password_pam_delay=4000000 + status: automated + + - id: SLEM-05-412035 + levels: + - low + title: SLEM 5 must limit the number of concurrent sessions to 10 for all + accounts and/or account types. + rules: + - accounts_max_concurrent_login_sessions + - var_accounts_max_concurrent_login_sessions=10 + status: automated + + - id: SLEM-05-431010 + levels: + - low + title: SLEM 5 must have policycoreutils package installed. + rules: + - package_policycoreutils_installed + status: automated + + - id: SLEM-05-431015 + levels: + - high + title: SLEM 5 must use a Linux Security Module configured to enforce limits on + system services. + rules: + - selinux_state + - var_selinux_state=enforcing + status: automated + + - id: SLEM-05-431020 + levels: + - medium + title: SLEM 5 must enable the SELinux targeted policy. + rules: + - selinux_policytype + - var_selinux_policy_name=targeted + status: automated + + - id: SLEM-05-431025 + levels: + - medium + title: SLEM 5 must prevent nonprivileged users from executing privileged + functions, including disabling, circumventing, or altering implemented + security safeguards/countermeasures. + rules: + - selinux_user_login_roles + status: manual + + - id: SLEM-05-432010 + levels: + - medium + title: SLEM 5 must use the invoking user's password for privilege escalation + when using "sudo". + rules: + - sudoers_validate_passwd + status: automated + + - id: SLEM-05-432015 + levels: + - medium + title: SLEM 5 must reauthenticate users when changing authenticators, roles, or + escalating privileges. + rules: + - sudo_require_authentication + - sudo_remove_nopasswd + - sudo_remove_no_authenticate + status: automated + + - id: SLEM-05-432020 + levels: + - medium + title: SLEM 5 must require reauthentication when using the "sudo" command. + rules: + - sudo_require_reauthentication + status: automated + + - id: SLEM-05-432025 + levels: + - medium + title: SLEM 5 must restrict privilege elevation to authorized personnel. + rules: + - sudo_restrict_privilege_elevation_to_authorized + status: automated + + - id: SLEM-05-432030 + levels: + - medium + title: SLEM 5 must specify the default "include" directory for the /etc/sudoers + file. + rules: + - sudoers_default_includedir + status: automated + + - id: SLEM-05-611010 + levels: + - medium + title: SLEM 5 must enforce passwords that contain at least one uppercase + character. + rules: + - cracklib_accounts_password_pam_ucredit + status: automated + + - id: SLEM-05-611015 + levels: + - medium + title: SLEM 5 must enforce passwords that contain at least one lowercase + character. + rules: + - cracklib_accounts_password_pam_lcredit + status: automated + + - id: SLEM-05-611020 + levels: + - medium + title: SLEM 5 must enforce passwords that contain at least one numeric character. + rules: + - cracklib_accounts_password_pam_dcredit + status: automated + + - id: SLEM-05-611025 + levels: + - medium + title: SLEM 5 must enforce passwords that contain at least one special character. + rules: + - cracklib_accounts_password_pam_ocredit + status: automated + + - id: SLEM-05-611030 + levels: + - medium + title: SLEM 5 must prevent the use of dictionary words for passwords. + rules: + - cracklib_accounts_password_pam_retry + - var_password_pam_retry=3 + status: automated + + - id: SLEM-05-611035 + levels: + - medium + title: SLEM 5 must employ passwords with a minimum of 15 characters. + rules: + - cracklib_accounts_password_pam_minlen + status: automated + + - id: SLEM-05-611040 + levels: + - medium + title: SLEM 5 must require the change of at least eight of the total number of + characters when passwords are changed. + rules: + - cracklib_accounts_password_pam_difok + status: automated + + - id: SLEM-05-611045 + levels: + - medium + title: SLEM 5 must not allow passwords to be reused for a minimum of five + generations. + rules: + - accounts_password_pam_pwhistory_remember + - var_password_pam_remember_control_flag=requisite + - var_password_pam_remember=5 + status: automated + + - id: SLEM-05-611050 + levels: + - medium + title: SLEM 5 must configure the Linux Pluggable Authentication Modules (PAM) to + only store encrypted representations of passwords. + rules: + - set_password_hashing_algorithm_systemauth + status: automated + + - id: SLEM-05-611055 + levels: + - high + title: SLEM 5 must not be configured to allow blank or null passwords. + rules: + - no_empty_passwords + status: automated + + - id: SLEM-05-611060 + levels: + - high + title: SLEM 5 must not have accounts configured with blank or null passwords. + rules: + - no_empty_passwords_etc_shadow + status: automated + + - id: SLEM-05-611065 + levels: + - medium + title: SLEM 5 must employ user passwords with a minimum lifetime of 24 hours + (one day). + rules: + - accounts_password_set_min_life_existing + - var_accounts_minimum_age_login_defs=1 + status: automated + + - id: SLEM-05-611070 + levels: + - medium + title: SLEM 5 must employ user passwords with a maximum lifetime of 60 days. + rules: + - accounts_password_set_max_life_existing + - var_accounts_maximum_age_login_defs=60 + status: automated + + - id: SLEM-05-611075 + levels: + - medium + title: SLEM 5 must employ a password history file. + rules: + - file_etc_security_opasswd + status: automated + + - id: SLEM-05-611080 + levels: + - high + title: SLEM 5 must employ FIPS 140-2/140-3-approved cryptographic hashing + algorithms for system authentication. + rules: + - accounts_password_all_shadowed_sha512 + status: automated + + - id: SLEM-05-611085 + levels: + - high + title: SLEM 5 shadow password suite must be configured to use a sufficient + number of hashing rounds. + rules: + - set_password_hashing_min_rounds_logindefs + - var_password_hashing_min_rounds_login_defs=100000 + status: automated + + - id: SLEM-05-611090 + levels: + - medium + title: SLEM 5 must employ FIPS 140-2/140-3 approved cryptographic hashing + algorithm for system authentication (login.defs). + rules: + - set_password_hashing_algorithm_logindefs + - var_password_hashing_algorithm=SHA512 + status: automated + + - id: SLEM-05-611095 + levels: + - medium + title: SLEM 5 must be configured to create or update passwords with a minimum + lifetime of 24 hours (one day). + rules: + - accounts_minimum_age_login_defs + status: automated + + - id: SLEM-05-611100 + levels: + - medium + title: SLEM 5 must be configured to create or update passwords with a maximum + lifetime of 60 days. + rules: + - accounts_maximum_age_login_defs + status: automated + + - id: SLEM-05-612010 + levels: + - medium + title: SLEM 5 must have the packages required for multifactor authentication to + be installed. + rules: + - install_smartcard_packages + status: automated + + - id: SLEM-05-612015 + levels: + - medium + title: SLEM 5 must implement multifactor authentication for access to privileged + accounts via pluggable authentication modules (PAM). + rules: + - smartcard_pam_enabled + status: automated + + - id: SLEM-05-612020 + levels: + - medium + title: SLEM 5 must implement certificate status checking for multifactor + authentication. + rules: + - smartcard_configure_cert_checking + status: automated + + - id: SLEM-05-631010 + levels: + - medium + title: If Network Security Services (NSS) is being used by SLEM 5 it must + prohibit the use of cached authentications after one day. + rules: + - sssd_memcache_timeout + - var_sssd_memcache_timeout=1_day + status: automated + + - id: SLEM-05-631015 + levels: + - medium + title: SLEM 5 must configure the Linux Pluggable Authentication Modules (PAM) to + prohibit the use of cached offline authentications after one day. + rules: + - sssd_offline_cred_expiration + status: automated + + - id: SLEM-05-631020 + levels: + - medium + title: SLEM 5, for PKI-based authentication, must validate certificates by + constructing a certification path (which includes status information) to + an accepted trust anchor. + rules: + - smartcard_configure_ca + status: automated + + - id: SLEM-05-631025 + levels: + - medium + title: SLEM 5 must be configured to not overwrite Pluggable Authentication + Modules (PAM) configuration on package changes. + rules: + - pam_disable_automatic_configuration + status: automated + + - id: SLEM-05-651010 + levels: + - medium + title: SLEM 5 must use a file integrity tool to verify correct operation of all + security functions. + rules: + - package_aide_installed + - aide_build_database + status: automated + + - id: SLEM-05-651015 + levels: + - medium + title: SLEM 5 file integrity tool must be configured to verify Access Control + Lists (ACLs). + rules: + - aide_verify_acls + status: automated + + - id: SLEM-05-651020 + levels: + - medium + title: SLEM 5 file integrity tool must be configured to verify extended + attributes. + rules: + - aide_verify_ext_attributes + status: automated + + - id: SLEM-05-651025 + levels: + - medium + title: SLEM 5 file integrity tool must be configured to protect the integrity of + the audit tools. + rules: + - aide_check_audit_tools + status: automated + + - id: SLEM-05-651030 + levels: + - medium + title: Advanced Intrusion Detection Environment (AIDE) must verify the baseline + SLEM 5 configuration at least weekly. + rules: + - aide_periodic_checking_systemd_timer + status: automated + + - id: SLEM-05-651035 + levels: + - medium + title: SLEM 5 must notify the system administrator (SA) when Advanced Intrusion + Detection Environment (AIDE) discovers anomalies in the operation of any + security functions. + rules: + - aide_scan_notification + status: automated + + - id: SLEM-05-652010 + levels: + - medium + title: SLEM 5 must offload rsyslog messages for networked systems in real time + and offload standalone systems at least weekly. + rules: + - package_systemd-journal-remote_installed + - service_systemd-journal-upload_enabled + - systemd_journal_upload_url + - systemd_journal_upload_server_tls + status: manual # do not assume anything set external variables before use + + - id: SLEM-05-653010 + levels: + - medium + title: SLEM 5 must have the auditing package installed. + rules: + - package_audit_installed + status: automated + + - id: SLEM-05-653015 + levels: + - medium + title: SLEM 5 audit records must contain information to establish what type of + events occurred, the source of events, where events occurred, and the + outcome of events. + rules: + - service_auditd_enabled + status: automated + + - id: SLEM-05-653020 + levels: + - medium + title: The audit-audispd-plugins package must be installed on SLEM 5. + rules: + - package_audit-audispd-plugins_installed + status: automated + + - id: SLEM-05-653025 + levels: + - medium + title: SLEM 5 must allocate audit record storage capacity to store at least one + week of audit records when audit records are not immediately sent to a + central audit record storage facility. + rules: + - auditd_audispd_configure_sufficiently_large_partition + status: automated + + - id: SLEM-05-653030 + levels: + - medium + title: SLEM 5 auditd service must notify the system administrator (SA) and + information system security officer (ISSO) immediately when audit storage + capacity is 75 percent full. + rules: + - auditd_data_retention_space_left_percentage + - var_auditd_space_left_percentage=25pc + - auditd_data_retention_space_left_action + - var_auditd_space_left_action=email + status: automated + + - id: SLEM-05-653035 + levels: + - medium + title: SLEM 5 audit system must take appropriate action when the audit storage + volume is full. + rules: + - auditd_data_disk_full_action + status: automated + + - id: SLEM-05-653040 + levels: + - medium + title: SLEM 5 must offload audit records onto a different system or media from + the system being audited. + rules: + - auditd_audispd_network_failure_action + status: automated + + - id: SLEM-05-653045 + levels: + - medium + title: Audispd must take appropriate action when SLEM 5 audit storage is full. + rules: + - auditd_audispd_disk_full_action + status: automated + + - id: SLEM-05-653050 + levels: + - medium + title: SLEM 5 must protect audit rules from unauthorized modification. + rules: + - permissions_local_var_log_audit + status: automated + + - id: SLEM-05-653055 + levels: + - medium + title: SLEM 5 audit tools must have the proper permissions configured to protect + against unauthorized access. + rules: + - permissions_local_audit_binaries + status: automated + + - id: SLEM-05-653060 + levels: + - medium + title: SLEM 5 audit tools must have the proper permissions applied to protect + against unauthorized access. + rules: [] + status: manual + + - id: SLEM-05-653065 + levels: + - low + title: SLEM 5 audit event multiplexor must be configured to use Kerberos. + rules: + - auditd_audispd_encrypt_sent_records + status: automated + + - id: SLEM-05-653070 + levels: + - medium + title: Audispd must offload audit records onto a different system or media from + SLEM 5 being audited. + rules: + - auditd_audispd_configure_remote_server + status: automated + + - id: SLEM-05-653075 + levels: + - medium + title: The information system security officer (ISSO) and system administrator + (SA), at a minimum, must have mail aliases to be notified of a SLEM 5 + audit processing failure. + rules: + - postfix_client_configure_mail_alias + status: automated + + - id: SLEM-05-653080 + levels: + - medium + title: The information system security officer (ISSO) and system administrator + (SA), at a minimum, must be alerted of a SLEM 5 audit processing failure + event. + rules: + - auditd_data_retention_action_mail_acct + status: automated + + - id: SLEM-05-654010 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chacl" command. + rules: + - audit_rules_execution_chacl + status: automated + + - id: SLEM-05-654015 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chage" command. + rules: + - audit_rules_privileged_commands_chage + status: automated + + - id: SLEM-05-654020 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chcon" command. + rules: + - audit_rules_execution_chcon + status: automated + + - id: SLEM-05-654025 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chfn" command. + rules: + - audit_rules_privileged_commands_chfn + status: automated + + - id: SLEM-05-654030 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chmod" command. + rules: + - audit_rules_execution_chmod + status: automated + + - id: SLEM-05-654035 + levels: + - medium + title: SLEM 5 must generate audit records for a uses of the "chsh" command. + rules: + - audit_rules_privileged_commands_chsh + status: automated + + - id: SLEM-05-654040 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "crontab" command. + rules: + - audit_rules_privileged_commands_crontab + status: automated + + - id: SLEM-05-654045 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "gpasswd" command. + rules: + - audit_rules_privileged_commands_gpasswd + status: automated + + - id: SLEM-05-654050 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "insmod" command. + rules: + - audit_rules_privileged_commands_insmod + status: automated + + - id: SLEM-05-654055 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "kmod" command. + rules: + - audit_rules_privileged_commands_kmod + status: automated + + - id: SLEM-05-654060 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "modprobe" command. + rules: + - audit_rules_privileged_commands_modprobe + status: automated + + - id: SLEM-05-654065 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "newgrp" command. + rules: + - audit_rules_privileged_commands_newgrp + status: automated + + - id: SLEM-05-654070 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the + "pam_timestamp_check" command. + rules: + - audit_rules_privileged_commands_pam_timestamp_check + status: automated + + - id: SLEM-05-654075 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "passwd" command. + rules: + - audit_rules_privileged_commands_passwd + status: automated + + - id: SLEM-05-654080 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "rm" command. + rules: + - audit_rules_execution_rm + status: automated + + - id: SLEM-05-654085 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "rmmod" command. + rules: + - audit_rules_privileged_commands_rmmod + status: automated + + - id: SLEM-05-654090 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "setfacl" command. + rules: + - audit_rules_execution_setfacl + status: automated + + - id: SLEM-05-654095 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "ssh-agent" command. + rules: + - audit_rules_privileged_commands_ssh_agent + status: automated + + - id: SLEM-05-654100 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "ssh-keysign" + command. + rules: + - audit_rules_privileged_commands_ssh_keysign + status: automated + + - id: SLEM-05-654105 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "su" command. + rules: + - audit_rules_privileged_commands_su + status: automated + + - id: SLEM-05-654110 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "sudo" command. + rules: + - audit_rules_privileged_commands_sudo + status: automated + + - id: SLEM-05-654115 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "sudoedit" command. + rules: + - audit_rules_privileged_commands_sudoedit + status: automated + + - id: SLEM-05-654120 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "unix_chkpwd" or + "unix2_chkpwd" commands. + rules: + - audit_rules_privileged_commands_unix_chkpwd + status: automated + + - id: SLEM-05-654125 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "usermod" command. + rules: + - audit_rules_privileged_commands_usermod + status: automated + + - id: SLEM-05-654130 + levels: + - medium + title: SLEM 5 must generate audit records for all account creations, + modifications, disabling, and termination events that affect /etc/group. + rules: + - audit_rules_usergroup_modification_group + status: automated + + - id: SLEM-05-654135 + levels: + - medium + title: SLEM 5 must generate audit records for all account creations, + modifications, disabling, and termination events that affect + /etc/security/opasswd. + rules: + - audit_rules_usergroup_modification_opasswd + status: automated + + - id: SLEM-05-654140 + levels: + - medium + title: SLEM 5 must generate audit records for all account creations, + modifications, disabling, and termination events that affect /etc/passwd. + rules: + - audit_rules_usergroup_modification_passwd + status: automated + + - id: SLEM-05-654145 + levels: + - medium + title: SLEM 5 must generate audit records for all account creations, + modifications, disabling, and termination events that affect /etc/shadow. + rules: + - audit_rules_usergroup_modification_shadow + status: automated + + - id: SLEM-05-654150 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chmod", "fchmod" + and "fchmodat" system calls. + rules: + - audit_rules_dac_modification_fchmod + status: automated + + - id: SLEM-05-654155 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "chown", "fchown", + "fchownat", and "lchown" system calls. + rules: + - audit_rules_dac_modification_lchown + status: automated + + - id: SLEM-05-654160 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "creat", "open", + "openat", "open_by_handle_at", "truncate", and "ftruncate" system calls. + rules: + - audit_rules_unsuccessful_file_modification_open + status: automated + + - id: SLEM-05-654165 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "delete_module" + system call. + rules: + - audit_rules_kernel_module_loading_delete + status: automated + + - id: SLEM-05-654170 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "init_module" and + "finit_module" system calls. + rules: + - audit_rules_kernel_module_loading_finit + status: automated + + - id: SLEM-05-654175 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "mount" system call. + rules: + - audit_rules_media_export + status: automated + + - id: SLEM-05-654180 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "setxattr", + "fsetxattr", "lsetxattr", "removexattr", "fremovexattr", and + "lremovexattr" system calls. + rules: + - audit_rules_dac_modification_fremovexattr + status: automated + + - id: SLEM-05-654185 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "umount" system + call. + rules: + - audit_rules_dac_modification_umount2 + status: automated + + - id: SLEM-05-654190 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of the "unlink", + "unlinkat", "rename", "renameat", and "rmdir" system calls. + rules: + - audit_rules_unsuccessful_file_modification_rename + status: automated + + - id: SLEM-05-654195 + levels: + - medium + title: SLEM 5 must generate audit records for all uses of privileged functions. + rules: + - audit_rules_suid_privilege_function + status: automated + + - id: SLEM-05-654200 + levels: + - medium + title: SLEM 5 must generate audit records for all modifications to the "lastlog" + file. + rules: + - audit_rules_login_events_lastlog + status: automated + + - id: SLEM-05-654205 + levels: + - medium + title: SLEM 5 must generate audit records for all modifications to the + "tallylog" file must generate an audit record. + rules: + - audit_rules_login_events_tallylog + status: automated + + - id: SLEM-05-654210 + levels: + - medium + title: SLEM 5 must audit all uses of the sudoers file and all files in the + "/etc/sudoers.d/" directory. + rules: + - audit_rules_sysadmin_actions + status: automated + + - id: SLEM-05-654215 + levels: + - medium + title: Successful/unsuccessful uses of "setfiles" in SLEM 5 must generate an + audit record. + rules: + - audit_rules_execution_setfiles + status: automated + + - id: SLEM-05-654220 + levels: + - medium + title: Successful/unsuccessful uses of "semanage" in SLEM 5 must generate an + audit record. + rules: + - package_policycoreutils-python-utils_installed + - audit_rules_execution_semanage + status: automated + + - id: SLEM-05-654225 + levels: + - medium + title: Successful/unsuccessful uses of "setsebool" in SLEM 5 must generate an + audit record. + rules: + - audit_rules_execution_setsebool + status: automated + + - id: SLEM-05-654230 + levels: + - medium + title: SLEM 5 must generate audit records for the "/run/utmp file". + rules: + - audit_rules_session_events_utmp + status: automated + + - id: SLEM-05-654235 + levels: + - medium + title: SLEM 5 must generate audit records for the "/var/log/btmp" file. + rules: + - audit_rules_session_events_btmp + status: automated + + - id: SLEM-05-654240 + levels: + - medium + title: SLEM 5 must generate audit records for the "/var/log/wtmp" file. + rules: + - audit_rules_session_events_wtmp + status: automated + + - id: SLEM-05-654245 + levels: + - medium + title: SLEM 5 must not disable syscall auditing. + rules: + - audit_rules_enable_syscall_auditing + status: automated + + - id: SLEM-05-671010 + levels: + - high + title: FIPS 140-2/140-3 mode must be enabled on SLEM 5. + rules: + - is_fips_mode_enabled + status: automated diff --git a/controls/stig_ubuntu2204.yml b/controls/stig_ubuntu2204.yml index db8a53a9bcca..f82e2efc736c 100644 --- a/controls/stig_ubuntu2204.yml +++ b/controls/stig_ubuntu2204.yml @@ -2,7 +2,7 @@ policy: Canonical Ubuntu 22.04 LTS Security Technical Implementation Guide (STIG) title: Canonical Ubuntu 22.04 LTS Security Technical Implementation Guide (STIG) id: stig_ubuntu2204 -version: V2R3 +version: V2R8 source: https://www.cyber.mil/stigs/downloads/ levels: @@ -14,6 +14,14 @@ reference_type: stigid product: ubuntu2204 controls: + - id: UBTU-22-211000 + title: Ubuntu 22.04 LTS must be a vendor-supported release. + levels: + - high + rules: + - installed_OS_is_vendor_supported + status: automated + - id: UBTU-22-211015 title: Ubuntu 22.04 LTS must disable the x86 Ctrl-Alt-Delete key sequence. levels: @@ -108,6 +116,7 @@ controls: levels: - low rules: + - var_timesync_service=chronyd - package_chrony_installed status: automated @@ -143,6 +152,15 @@ controls: - package_telnetd_removed status: automated + - id: UBTU-22-215040 + title: Ubuntu 22.04 LTS must not have the "nfs-kernel-server" package installed. + levels: + - medium + rules: + - package_nfs-common_removed + - package_nfs-kernel-server_removed + status: automated + - id: UBTU-22-231010 title: Ubuntu 22.04 LTS must implement cryptographic mechanisms to prevent unauthorized disclosure and modification of all information that requires protection at rest. @@ -474,6 +492,42 @@ controls: - sysctl_net_ipv4_tcp_syncookies status: automated + - id: UBTU-22-254010 + title: Ubuntu 22.04 LTS must have the "SSSD" package installed. + levels: + - medium + rules: + - package_nss_sss_installed + - package_pam_sss_installed + - package_sssd_installed + status: automated + + - id: UBTU-22-254015 + title: Ubuntu 22.04 LTS must use the "SSSD" package for multifactor authentication services. + levels: + - medium + rules: + - service_sssd_enabled + status: automated + + - id: UBTU-22-254020 + title: Ubuntu 22.04 LTS must ensure SSSD performs certificate path validation, including revocation checking, against a trusted anchor for PKI-based authentication. + levels: + - medium + rules: + - sssd_enable_pam_services + - sssd_enable_smartcards + - sssd_certification_path_trust_anchor + status: automated + + - id: UBTU-22-254030 + title: Ubuntu 22.04 LTS must map the authenticated identity to the user or group account for PKI-based authentication. + levels: + - medium + rules: + - sssd_enable_user_cert + status: automated + - id: UBTU-22-255010 title: Ubuntu 22.04 LTS must have SSH installed. levels: @@ -498,6 +552,7 @@ controls: - medium rules: - remote_login_banner_text=dod_banners + - remote_login_banner_contents=dod_default - sshd_enable_warning_banner_net - banner_etc_issue_net status: automated @@ -600,7 +655,8 @@ controls: levels: - medium rules: - - login_banner_text=dod_banners + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default - dconf_gnome_login_banner_text status: automated @@ -790,7 +846,15 @@ controls: levels: - medium rules: - - sudo_require_authentication + - sudo_remove_no_authenticate + status: automated + + - id: UBTU-22-432011 + title: Ubuntu 22.04 LTS must require users to provide a password for privilege escalation. + levels: + - medium + rules: + - sudo_remove_nopasswd status: automated - id: UBTU-22-432015 @@ -886,7 +950,9 @@ controls: levels: - medium rules: - - set_password_hashing_algorithm_systemauth + - var_password_pam_unix_rounds=100000 + - set_password_hashing_algorithm_auth_stig + - accounts_password_pam_unix_rounds_password_auth status: automated - id: UBTU-22-611060 @@ -1260,6 +1326,15 @@ controls: - audit_rules_privileged_commands_crontab status: automated + - id: UBTU-22-654041 + title: Ubuntu 22.04 LTS must audit any script or executable called by cron as root or by any privileged user. + levels: + - medium + rules: + - audit_rules_etc_cron_d + - audit_rules_var_spool_cron + status: automated + - id: UBTU-22-654045 title: Ubuntu 22.04 LTS must generate audit records for successful/unsuccessful attempts to use the fdisk command. @@ -1600,6 +1675,14 @@ controls: - audit_rules_sudoers status: automated + - id: UBTU-22-654224 + title: The operating system must restrict privilege elevation to authorized personnel. + levels: + - medium + rules: + - sudo_restrict_privilege_elevation_to_authorized + status: automated + - id: UBTU-22-654225 title: Ubuntu 22.04 LTS must generate audit records when successful/unsuccessful attempts to modify the /etc/sudoers.d directory occur. diff --git a/controls/stig_ubuntu2404.yml b/controls/stig_ubuntu2404.yml index cb85dc34866e..68fb3d859c18 100644 --- a/controls/stig_ubuntu2404.yml +++ b/controls/stig_ubuntu2404.yml @@ -46,6 +46,15 @@ controls: - package_rsh-server_removed status: automated + - id: UBTU-24-100050 + title: Ubuntu 24.04 LTS must not have the nfs-kernel-server package installed. + levels: + - high + rules: + - package_nfs-kernel-server_removed + - service_nfs_disabled + status: automated + - id: UBTU-24-100100 title: Ubuntu 24.04 LTS must use a file integrity tool to verify correct operation of all security functions. @@ -317,15 +326,39 @@ controls: - var_screensaver_lock_delay=immediate - dconf_gnome_screensaver_idle_delay - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_lock_enabled status: automated - id: UBTU-24-200040 - title: Ubuntu 24.04 LTS must retain a user's session lock until the user reestablishes access using - established identification and authentication procedures. + title: Ubuntu 24.04 LTS must prevent a user from overriding the disabling of the graphical user interface automount function. levels: - medium rules: - - dconf_gnome_screensaver_lock_enabled + - dconf_gnome_disable_automount_open + status: automated + + - id: UBTU-24-200041 + title: Ubuntu 24.04 LTS must prevent a user from overriding the disabling of the graphical user interface autorun function. + levels: + - medium + rules: + - dconf_gnome_disable_autorun + status: automated + + - id: UBTU-24-200042 + title: Ubuntu 24.04 LTS must prevent a user from overriding the disabling of the graphical user smart card removal action. + levels: + - medium + rules: + - dconf_gnome_lock_screen_on_smartcard_removal + status: automated + + - id: UBTU-24-200043 + title: Ubuntu 24.04 LTS must conceal, via the session lock, information previously visible on the display with a publicly viewable image. + levels: + - medium + rules: + - dconf_gnome_screensaver_mode_blank status: automated - id: UBTU-24-200060 @@ -363,6 +396,15 @@ controls: - account_disable_post_pw_expiration status: automated + - id: UBTU-24-200270 + title: Ubuntu 24.04 LTS must audit any script or executable called by cron as root or by any privileged user. + levels: + - medium + rules: + - audit_rules_etc_cron_d + - audit_rules_var_spool_cron + status: automated + - id: UBTU-24-200280 title: Ubuntu 24.04 LTS must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/passwd. @@ -441,6 +483,7 @@ controls: - medium rules: - remote_login_banner_text=dod_banners + - remote_login_banner_contents=dod_default - sshd_enable_warning_banner_net - banner_etc_issue_net status: automated @@ -461,7 +504,8 @@ controls: levels: - medium rules: - - login_banner_text=dod_banners + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default - dconf_gnome_login_banner_text status: automated @@ -580,6 +624,22 @@ controls: - accounts_passwords_pam_faildelay_delay status: automated + - id: UBTU-24-300019 + title: Ubuntu 24.04 LTS must restrict privilege elevation to authorized personnel. + levels: + - medium + rules: + - sudo_restrict_privilege_elevation_to_authorized + status: automated + + - id: UBTU-24-300020 + title: Ubuntu 24.04 LTS must require users to provide a password for privilege escalation. + levels: + - medium + rules: + - sudo_remove_nopasswd + status: automated + - id: UBTU-24-300021 title: Ubuntu 24.04 LTS must require users to reauthenticate for privilege escalation or when changing roles. diff --git a/docs/manual/developer/02_building_complianceascode.md b/docs/manual/developer/02_building_complianceascode.md index 1032af1d51ef..1931c7519c34 100644 --- a/docs/manual/developer/02_building_complianceascode.md +++ b/docs/manual/developer/02_building_complianceascode.md @@ -313,6 +313,36 @@ The thin Datastream is stored under the normal Datastream name (for example, `ss ./build_product fedora --rule-id enable_fips_mode ``` +### Building CEL Content + +CEL (Common Expression Language) content is available for Kubernetes and OpenShift products. +When building products with `PRODUCT_CEL_ENABLED` set in their CMakeLists.txt, CEL content is generated automatically during a full build. + +```bash + # Build all content including CEL (for products with CEL enabled) + ./build_product ocp4 + + # Build data stream only (excludes CEL content) + ./build_product ocp4 --datastream + # Short form (only builds datastream): + ./build_product ocp4 -d + # Legacy form (still supported): + ./build_product ocp4 --datastream-only + + # Build data stream and CEL content + ./build_product ocp4 --datastream --cel-content=ocp4 + + # Build only CEL content (no data stream) + ./build_product --cel-content=ocp4 + + # Build CEL content for multiple products + ./build_product --cel-content=ocp4,rhel9 +``` + +CEL content files are generated as `build/-cel-content.yaml`. + +For more information about CEL content, see [CEL Content Documentation](13_cel_content.md). + ### Configuring CMake options using GUI Configure options before building using a GUI tool: diff --git a/docs/manual/developer/03_creating_content.md b/docs/manual/developer/03_creating_content.md index d1a1b0b25695..ac32a875f4ec 100644 --- a/docs/manual/developer/03_creating_content.md +++ b/docs/manual/developer/03_creating_content.md @@ -26,7 +26,7 @@ build files/configuration, etc.

applications

-

Contains security content for applications such as OpenShift or OpenStack. Contains rules, OVAL checks, Ansible tasks, Bash remediations, etc.

+

Contains security content for applications such as OpenShift or OpenStack. Contains rules, OVAL checks, CEL checks, Ansible tasks, Bash remediations, etc. For Kubernetes/OpenShift CEL rules, see CEL Content.

shared

diff --git a/docs/manual/developer/04_style_guide.md b/docs/manual/developer/04_style_guide.md index 7ba2c0dec31e..cbb23f9196a8 100644 --- a/docs/manual/developer/04_style_guide.md +++ b/docs/manual/developer/04_style_guide.md @@ -274,6 +274,98 @@ Rules sections must be in the following order, if they are present. * Must be a valid rule id * `template` +#### CEL Rule Sections + +CEL (Common Expression Language) rules are used for Kubernetes/OpenShift compliance checks. +Rules with CEL checks use a split-file structure: + +* **`rule.yml`** - Contains metadata (same as any rule) +* **`cel/shared.yml`** - Contains CEL-specific fields (check_type, failure_reason, inputs, expression) + +This allows rules to support both CEL and OVAL checks during migration. + +##### rule.yml Sections + +Rule sections must be in the following order, if present: + +* `documentation_complete` +* `title` +* `description` (HTML Like) +* `rationale` (HTML Like) +* `severity` +* `identifiers` (Optional) + * Keys must be in alphabetical order +* `references` (Optional) + * Keys must be in alphabetical order +* `ocil_clause` (Optional) +* `ocil` (HTML Like, Optional) + +##### cel/shared.yml Sections + +CEL-specific sections must be in the following order: + +* `check_type` + * Must be `Platform` for Kubernetes/OpenShift checks +* `failure_reason` (Optional) + * Must be a block + * Must describe the condition when the check fails +* `expression` + * Must be a valid CEL expression that evaluates to boolean + * Must use variables defined in `inputs` + * Should use `has()` to check for field existence before accessing + * Should be formatted for readability using multi-line block syntax for complex expressions +* `inputs` + * Must be a list of at least one input + * Each input must have: + * `name` - Variable name used in the CEL expression + * `kubernetes_input_spec` - Kubernetes resource specification + * `api_version` - Kubernetes API version (e.g., `v1`, `apps/v1`) + * `resource` - Resource type in plural form (e.g., `pods`, `deployments`) + * `resource_name` (Optional) - Specific resource name to query + * `resource_namespace` (Optional) - Specific namespace to query + +Example rule with CEL checks: + +**rule.yml:** +```yaml +documentation_complete: true + +title: 'Rule Title in Title Case' + +description: |- + Description of what the rule checks. + +rationale: |- + Why this rule matters for security/compliance. + +severity: medium + +ocil: |- + Run the following command: +
$ oc get configmap my-config -n default
+``` + +**cel/shared.yml:** +```yaml +check_type: Platform + +failure_reason: |- + The resource is not properly configured. + +expression: |- + resource.spec.enabled == true && + has(resource.spec.field) && + resource.spec.field == "expected_value" + +inputs: + - name: resource + kubernetes_input_spec: + api_version: v1 + resource: configmaps + resource_name: my-config + resource_namespace: default +``` + ### Group This section describes the style guide around the `group.yml` files. @@ -354,21 +446,27 @@ Control sections must be in the following order, if they are present. #### Profile Sections -Control sections must be in the following order, all sections are required unless otherwise noted. +Profile sections must be in the following order, all sections are required unless otherwise noted. * `documentation_complete` -* `id` -* `metadata` +* `metadata` (Optional) * `reference` * `version` * `SMEs` * `title` * Shall be short and descriptive * `description` (HTML-Like) +* `platform` (Optional) + * Must be a valid platform identifier (e.g., `ocp4`, `rhel9`) +* `scanner_type` (Optional) + * Must be `CEL` for profiles targeting the CEL checking engine + * Profiles with `scanner_type: CEL` can only select rules that have CEL checks (cel/ directory) + * Profiles with `scanner_type: CEL` are excluded from XCCDF/OVAL generation * `extends` (Optional) * Must be valid id of another profile id * `selections` * Must be valid rule ids + * For profiles with `scanner_type: CEL`, must only contain rule ids with CEL checks (using hyphens, not underscores) ## Remediation diff --git a/docs/manual/developer/05_tools_and_utilities.md b/docs/manual/developer/05_tools_and_utilities.md index 3600665940ea..400147b424ab 100644 --- a/docs/manual/developer/05_tools_and_utilities.md +++ b/docs/manual/developer/05_tools_and_utilities.md @@ -382,7 +382,7 @@ To execute: ### `utils/compare_ds.py` – Compare two data streams (can also compare XCCDFs) This script compares two data streams or two benchmarks and generates a diff output. -It can show what changed in rules, for example in description, references and remediation scripts. +It shows what changed in rules, for example in description, references and remediation scripts. Changes in checks (OVAL and OCIL) are shown too, but the OVAL diff is limited to the `criteria` and `criterion` order and their IDs. @@ -396,16 +396,16 @@ diff for the whole data stream or benchmark. The option `--rule-diffs` can be used to generate a diff file per rule. In this mode the diff files are created in a directory: `./compare_ds-diffs`. To change the output dir use `--output-dir` option. -Compare current DISA's manual benchmark, and generate per file diffs: +Compare two data streams and save the output to a file: ```bash - $ utils/compare_ds.py --disa-content --rule-diffs ./disa-stig-rhel8-v1r6-xccdf-manual.xml shared/references/disa-stig-rhel8-v1r7-xccdf-manual.xml + $ utils/compare_ds.py > content.diff ``` -Compare two data streams: +Compare two DISA's benchmarks, and generate per rule diffs in the `compare_ds-diffs` directory: ```bash - $ utils/compare_ds.py /tmp/ssg-rhel8-ds.xml build/ssg-rhel8-ds.xml > content.diff + $ utils/compare_ds.py --disa-content --rule-diffs ``` #### HTML Diffs @@ -420,11 +420,12 @@ Install `diff2html`: $ sudo npm install -g diff2html-cli ``` -Generate the HTML diffs: +Generate the HTML diffs in the `html` directory. Run the `utils/compare_ds.py` first to generate the diffs in the `compare_ds-diffs` directory. ```bash + $ rm -r html/ $ mkdir -p html - $ for f in $(ls compare_ds-diffs/); do diff2html -i file -t $f -F "html/$f.html" "compare_ds-diffs/$f"; done + $ for f in compare_ds-diffs/*; do name="${f##*/}"; diff2html -i file -t "$name" -F "html/$name.html" -- "$f" & done; wait ``` ### `utils/compare_results.py` – Compare to two ARF result files @@ -703,58 +704,6 @@ $ python3 utils/compare_versions.py compare_tags v0.1.67 v0.1.68 rhel9 It will internally clone the upstream project, checkout these tags, generate ComplianceAsCode JSON manifests, compare them and print the output. -### `utils/oscal/build_cd_from_policy.py` – Build a Component Definition from a Policy - -This script builds an OSCAL Component Definition (cd) (version `1.0.4`) for an existing OSCAL profile from a policy. The script uses the -[compliance-trestle](https://github.com/oscal-compass/compliance-trestle) library to build the component definition. The component definition can be used with the `compliance-trestle` CLI after generation. - -Some assumption made by this script: - -- The script maps control file statuses to valid OSCAL [statuses](https://pages.nist.gov/OSCAL-Reference/models/v1.1.1/system-security-plan/json-reference/#/system-security-plan/control-implementation/implemented-requirements/by-components/implementation-status) as follows: - - * `pending` - `alternative` - - * `not applicable`: `not-applicable` - - * `inherently met`: `implemented` - - * `documentation`: `implemented` - - * `planned`: `planned` - - * `partial`: `partial` - - * `supported`: `implemented` - - * `automated`: `implemented` - - * `manual`: `alternative` - - * `does not meet`: `alternative` - -- The script uses the "Section *letter*:" convention in the control notes to create statements under the implemented requirements. -- The script maps parameter to rules uses the `xccdf_variable` field under `template.vars` -- To determine what responses will mapped to the controls in the OSCAL profile the control id and label property from the resolved catalog is searched. - -It supports the following arguments: - - `-o`, `--output` — Path to write the cd to - - `-r`, `--root` — Root of the SSG project. Defaults to /content. - - `-v`, `--vendor-dir` — Path to the vendor directory with third party OSCAL artifacts - - `-p`, `--profile` — Main profile href, or name of the profile model in the trestle workspace - - `-pr`, `--product` — Product to build cd with - - `-c`, `--control` — Control to use as the source for control responses. To optionally filter by level, use the format :. - - `-j`, `--json` — Path to the rules_dir.json. Defaults to /content/build/rule_dirs.json. - - `-b`, `--build-config-yaml` — YAML file with information about the build configuration - - `-t`, `--component-definition-type` — Type of component definition to create. Defaults to service. Options are service or validation. - -An example of how to execute the script: - -```bash -$ ./build_product ocp4 -$ ./utils/rule_dir_json.py -$ ./utils/oscal/build_cd_from_policy.py -o build/ocp4.json -p fedramp_rev4_high -pr ocp4 -c nist_ocp4:high -``` - ### `utils/ansible_playbook_to_role.py` – Generates Ansible Roles and pushes them to Github This script converts the Ansible playbooks created by the build system and converts them to Ansible roles and can upload them to GitHub. diff --git a/docs/manual/developer/06_contributing_with_content.md b/docs/manual/developer/06_contributing_with_content.md index 3e0427e88f68..6eb1e6f66c47 100644 --- a/docs/manual/developer/06_contributing_with_content.md +++ b/docs/manual/developer/06_contributing_with_content.md @@ -518,6 +518,8 @@ then contain the following subdirectories: - `bootc` - for remediation content used in the `oscap-im` tool internally, ending in `.bo` +- `hummingbird` - for remediation content used during the build of Project Hummingbird container images, ending in `.sh` + In each of these subdirectories, a file named `shared.ext` will apply to all products and be included in all builds, but `{{{ product }}}.ext` will only get included in the build for `{{{ product }}}` (e.g., @@ -668,12 +670,19 @@ Tips: ### Checks -Checks are used to evaluate a Rule. There are two types of check content -supported by ComplianceAsCode: OVAL and SCE. Note that OVAL is standardized -by NIST and has better cross-scanner support than SCE does. However, because -SCE can use any language on the target system (Bash, Python, ...) it is much -more flexible and general-purpose than OVAL. This project generally encourages -OVAL unless it lacks support for certain features. +Checks are used to evaluate a Rule. There are three types of check content +supported by ComplianceAsCode: OVAL, CEL, and SCE. + +* **OVAL** (Open Vulnerability and Assessment Language) - Standardized by NIST with better cross-scanner support. Used for traditional operating system compliance checks (file system, processes, packages). Generally the preferred choice for OS-level checks. + +* **CEL** (Common Expression Language) - Used for Kubernetes and OpenShift platform compliance checks. CEL rules evaluate Kubernetes API resources without requiring shell access to nodes. See [CEL Content](13_cel_content.md) for complete documentation on creating CEL rules. + +* **SCE** (Script Check Engine) - Can use any language on the target system (Bash, Python, ...) making it more flexible and general-purpose than OVAL, but with less cross-scanner support. + +This project generally encourages using: +- OVAL for Linux/OS checks +- CEL for Kubernetes/OpenShift platform checks +- SCE only when OVAL lacks support for certain features #### OVAL Check Content @@ -946,6 +955,95 @@ means: +### CEL Check Content + +[CEL](https://github.com/google/cel-spec) (Common Expression Language) is a mechanism +for evaluating Kubernetes and OpenShift API resources for compliance checking. CEL checks +are used by the [compliance-operator](https://github.com/ComplianceAsCode/compliance-operator) +to perform platform-level compliance checks without requiring shell access to nodes. + +CEL rules use a **split-file structure** to separate metadata from CEL-specific content: + +* **`rule.yml`** - Contains metadata (title, description, rationale, severity, references, etc.) +* **`cel/shared.yml`** - Contains CEL-specific fields (check_type, failure_reason, inputs, expression) + +This allows rules to support **both CEL and OVAL** checks during migration from OVAL to CEL. + +Within a rule's `cel/shared.yml` file, the following fields are used: + +* `check_type: Platform` - Indicates this is a platform-level check (usually Platform for K8s checks) +* `failure_reason` - Optional custom failure message displayed when the check fails +* `expression` - The CEL expression that evaluates to boolean (true=pass, false=fail) +* `inputs` - List of Kubernetes resources to evaluate + +Within a rule's `inputs` section, each input specifies a Kubernetes resource using `kubernetes_input_spec`: + +* `api_version` - Kubernetes API version (e.g., `v1`, `apps/v1`) +* `resource` - Resource type in plural form (e.g., `pods`, `deployments`) +* `resource_name` - Optional: specific resource name to query +* `resource_namespace` - Optional: specific namespace to query + +**Important notes:** + +* CEL rules are **excluded** from XCCDF/OVAL DataStreams +* CEL rules generate a separate `${PRODUCT}-cel-content.yaml` file +* CEL profiles can only select CEL rules +* Rule directory names should use hyphens (Kubernetes naming convention) +* The build system automatically detects rules with CEL checks by the presence of the `cel/` directory + +For complete documentation on creating CEL rules, see [CEL Content](13_cel_content.md). + +Example CEL rule: + +**rule.yml:** +```yaml +documentation_complete: true + +title: 'Ensure Deployments Run as Non-Root' + +description: |- + Deployments should run with non-root security context. + +rationale: |- + Running containers as non-root reduces the attack surface. + +severity: medium +``` + +**cel/shared.yml:** +```yaml +check_type: Platform + +failure_reason: |- + The deployment does not have the required non-root security context. + +expression: |- + resource.spec.replicas >= 3 && + has(resource.spec.template.spec.securityContext) && + resource.spec.template.spec.securityContext.runAsNonRoot == true + +inputs: + - name: resource + kubernetes_input_spec: + api_version: apps/v1 + resource: deployments + resource_name: my-app + resource_namespace: default +``` + +To build CEL content for a product, enable it in the product's `CMakeLists.txt`: + +```cmake +set(PRODUCT "ocp4") +set(PRODUCT_CEL_ENABLED TRUE) +ssg_build_product(${PRODUCT}) +``` + +## Remediations + +The following sections describe remediation content. Note that CEL rules do **not** support +remediation content - they are check-only. + ### Ansible > **Important** diff --git a/docs/manual/developer/07_understanding_build_system.md b/docs/manual/developer/07_understanding_build_system.md index 1b4d638c0286..8ae18c2aa9fd 100644 --- a/docs/manual/developer/07_understanding_build_system.md +++ b/docs/manual/developer/07_understanding_build_system.md @@ -83,6 +83,7 @@ of occurrence: - Load resolved rules, profiles, groups, collected remediations and the unlinked OVAL document and generate XCCDF, OVAL and OCIL documents from this data. - Generate CPE OVAL and CPE dictionary. - Combining the OVAL, OCIL, CPE and XCCDF documents into a single SCAP source data stream. +- Generate CEL content YAML for Kubernetes/OpenShift compliance checks (if enabled for the product). - Generate content for derived products (such as CentOS and Scientific Linux). - Generate HTML tables, Bash scripts, Ansible Playbooks and other secondary artifacts. @@ -93,6 +94,9 @@ refer to their help text for more information and usage: - `build_all_guides.py` -- generates separate HTML guides for every profile in an XCCDF document. +- `build_cel_content.py` -- generates CEL (Common Expression Language) content + YAML for Kubernetes/OpenShift compliance checks. See [CEL Content](13_cel_content.md) + for detailed information about CEL rules and profiles. - `build_rule_playbooks.py` -- generates per-rule per-profile playbooks in Ansible content. - `build_sce.py` -- outputs SCE content and combined metadata. @@ -114,7 +118,7 @@ refer to their help text for more information and usage: framework) to expand Jinja in test scripts. - `generate_guides.py` -- Generate HTML guides and HTML index for every profile in the built SCAP source data stream. - `generate_man_page.py` -- generates the ComplianceAsCode man page. -- `generate_profile_remediations.py` -- Generate profile oriented Bash remediation scripts or profile oriented Ansible Playbooks from the built SCAP source data stream. The output is similar to the output of the `oscap xccdf generate fix` command, but the tool `generate_profile_remediations.py` generates the scripts or Playbooks for all profiles in the given SCAP source data stream at once. +- `generate_profile_remediations.py` -- Generate profile oriented Bash remediations (Bash scripts or Ansible Playbooks or Bash scripts for Hummingbird) from the built SCAP source data stream. The output is similar to the output of the `oscap xccdf generate fix` command, but the tool `generate_profile_remediations.py` generates the output for all profiles in the given SCAP source data stream at once. - `profile_tool.py` -- utility script to generate statistics about profiles in a specific XCCDF/data stream file. - `verify_references.py` -- used by the test system to verify cross-linkage @@ -167,3 +171,98 @@ Steps to link an OVAL document to an XCCDF document: 8. The OVAL Document object is stored as an XML file `build/ssg-${PRODUCT}-oval.xml`. 9. For each XCCDF rule, a minimal OVAL Documents document is generated as an artifact 10. For each reference of OVAL check in XCCDF, a link to the `check-content` and a `check-export` element is added. + +## How CEL Content is Built + +CEL (Common Expression Language) content provides an alternative scanning mechanism to OVAL specifically designed for Kubernetes and OpenShift API resource evaluation. Unlike OVAL which requires shell access and evaluates system state, CEL rules evaluate Kubernetes resources directly through the API server. + +CEL content generation is optional and must be explicitly enabled for each product. + +### Enabling CEL Content + +CEL content generation is enabled by setting `PRODUCT_CEL_ENABLED` in the product's `CMakeLists.txt`: + +```cmake +set(PRODUCT "ocp4") +set(PRODUCT_REMEDIATION_LANGUAGES "ignition;kubernetes") +set(PRODUCT_CEL_ENABLED TRUE) + +ssg_build_product(${PRODUCT}) +``` + +### Build Process + +When CEL content is enabled for a product, the build system performs the following steps: + +1. **Rule and Profile Resolution** - All rules and profiles are compiled to their product-specific resolved form (same as for SCAP content). + +2. **CEL Rule Loading** - The `build_cel_content.py` script loads all rules with CEL checks (identified by having both `expression` and `inputs` fields from `cel/shared.yml`) from the `build/${PRODUCT}/rules/` directory. + +3. **CEL Profile Loading** - The script loads all profiles with `scanner_type: CEL` from the `build/${PRODUCT}/profiles/` directory. + +4. **Validation** - The build system validates CEL content: + - Rules must have `expression` field (non-empty CEL expression) + - Rules must have `inputs` field (non-empty list of Kubernetes resources) + - Profiles must have `selected` field with at least one rule + - No duplicate rule names (after conversion to hyphenated format) + - All profile rule references must exist in the CEL rules + +5. **Content Generation** - The script generates a single CEL content YAML file at `build/${PRODUCT}-cel-content.yaml`. + +### CEL Content Structure + +The generated CEL content YAML has two main sections: + +```yaml +profiles: + - id: cis_vm_extension # Profile ID (with underscores) + name: cis-vm-extension # Profile name (with hyphens) + title: Profile Title + description: Profile description + productType: Platform + rules: # List of rule names (hyphenated) + - rule-name-one + - rule-name-two + +rules: + - id: rule_name_one # Rule ID (with underscores) + name: rule-name-one # Rule name (with hyphens) + title: Rule Title + description: Rule description + rationale: Rule rationale + severity: medium + checkType: Platform + expression: | # CEL expression + resource.spec.enabled == true + inputs: # Kubernetes resource inputs + - name: resource + kubernetesInputSpec: + apiVersion: v1 + resource: pods + instructions: Manual check steps # From ocil field + controls: # From references field + cis@ocp4: + - 1.2.3 + nist: + - CM-6 +``` + +### Differences from SCAP + +CEL content is processed differently from traditional SCAP content: + +| Aspect | SCAP| CEL Content | +|--------|-----------|-------------| +| **Rules Included** | All rules except CEL | Only CEL rules | +| **Profiles Included** | All profiles except CEL | Only CEL profiles | +| **Output Format** | XML (DataStream) | YAML | +| **Output Location** | `build/ssg-${PRODUCT}-ds.xml` | `build/${PRODUCT}-cel-content.yaml` | +| **Scanner** | OpenSCAP | compliance-operator | +| **Evaluation** | Shell commands, file checks | Kubernetes API queries | + +Rules with no check implemented appear **only** in the SCAP content. +Rules with only CEL check implemented are **excluded** from SCAP content generation and **only** appear in the CEL content YAML. +Rules with both OVAL and CEL check implemented are **included** in both SCAP and CEL content. +Profiles with `scanner_type: CEL` are **excluded** from SCAP content and **only** appear in the CEL content YAML. + +For detailed information about creating CEL rules and profiles, see [CEL Content](13_cel_content.md). diff --git a/docs/manual/developer/12_ai_skills.md b/docs/manual/developer/12_ai_skills.md new file mode 100644 index 000000000000..ac44f3447e82 --- /dev/null +++ b/docs/manual/developer/12_ai_skills.md @@ -0,0 +1,31 @@ +# AI-Assisted Development Skills + +This repository includes a set of skills that automate common +development tasks such as building products, creating rules, mapping +control files, reviewing pull requests, and more. Skills are invoked as +slash commands (e.g., `/build-product rhel9`). + +The skills are compatible with any LLM client that supports the +`.claude/skills/` convention, such as +[Claude Code](https://claude.ai/code) and +[Opencode](https://opencode.ai/). + +Some skills can optionally use the +[content-mcp](https://github.com/ComplianceAsCode/content-mcp) MCP +(Model Context Protocol) server for structured, deterministic operations +such as rule lookup, control file parsing, and rendered content search. +When the MCP server is not configured, those skills fall back to +filesystem-based alternatives so that every skill completes successfully +either way. The MCP server is not required. + +## Finding and Using Skills + +Each skill is defined in its own directory under `.claude/skills/`. The +directory name is the skill name (e.g., `.claude/skills/build-product/` +corresponds to `/build-product`). Every skill directory contains a +`SKILL.md` file that fully documents its purpose, usage, arguments, +phases, and behavior. + +Skills are self-documenting. Before using a skill, read its `SKILL.md` +to understand what it does, what arguments it expects, and what side +effects it may have. diff --git a/docs/manual/developer/13_cel_content.md b/docs/manual/developer/13_cel_content.md new file mode 100644 index 000000000000..91cbddf9c15d --- /dev/null +++ b/docs/manual/developer/13_cel_content.md @@ -0,0 +1,453 @@ +# CEL Content + +## Introduction + +CEL (Common Expression Language) is an alternative scanning mechanism to OVAL that provides native Kubernetes resource evaluation. CEL rules are used by the [compliance-operator](https://github.com/ComplianceAsCode/compliance-operator) to perform compliance checks on Kubernetes and OpenShift resources without requiring shell access or OVAL evaluation. + +This document describes how to create CEL rules and profiles, and how the build system generates CEL content. + +## When to Use CEL Rules + +Use CEL rules when: +- Checking Kubernetes or OpenShift API resources (Pods, Deployments, ConfigMaps, etc.) +- Evaluating Custom Resource Definitions (CRDs) +- Performing compliance checks that don't require shell access to nodes +- Building platform-level compliance checks for container orchestration systems + +Continue using OVAL/template-based rules for: +- File system checks +- Process checks +- Package installation verification +- Traditional operating system compliance checks + +## CEL Rule Format + +CEL rules use a **split-file structure** to separate metadata from CEL-specific content: + +- **`rule.yml`** - Contains metadata (title, description, rationale, severity, references, etc.) +- **`cel/shared.yml`** - Contains CEL-specific fields (check_type, failure_reason, inputs, expression) + +This allows rules to support **both CEL and OVAL** checks during migration from OVAL to CEL. + +### rule.yml Fields + +```yaml +documentation_complete: true + +title: 'Short descriptive title' + +description: |- + Full description of what the rule checks. + +rationale: |- + Why this rule matters for security/compliance. + +severity: medium # low, medium, high + +ocil: |- # Optional: Manual verification instructions + Run the following command to verify: +
$ oc get pods
+ +references: # Optional + cis@ocp4: 1.2.3 + nist: CM-6,CM-6(1) + srg: SRG-APP-000516-CTR-001325 +``` + +### cel/shared.yml Fields + +```yaml +check_type: Platform # Type of check (usually Platform for K8s checks) + +failure_reason: |- # Optional: Custom message displayed when the check fails + The resource is not properly configured. + +expression: |- # REQUIRED: CEL expression that evaluates to boolean + resource.spec.enabled == true + +inputs: # REQUIRED: List of Kubernetes resources to evaluate + - name: resource + kubernetes_input_spec: + api_version: v1 + resource: pods + resource_name: my-pod # Optional: specific resource name + resource_namespace: default # Optional: specific namespace +``` + +### CEL Expression + +The `expression` field contains a CEL expression that evaluates to a boolean value: +- `true` means the check passes (compliant) +- `false` means the check fails (non-compliant) + +CEL expressions can reference inputs by name and use standard CEL operators and functions. + +#### Example Expressions + +Simple boolean check: +```yaml +expression: resource.spec.enabled == true +``` + +Checking for absence: +```yaml +expression: !has(hco.spec.storageImport) || hco.spec.storageImport.insecureRegistries.size() == 0 +``` + +Multiple conditions: +```yaml +expression: |- + resource.spec.replicas >= 3 && + has(resource.spec.template.spec.securityContext) && + resource.spec.template.spec.securityContext.runAsNonRoot == true +``` + +### Input Specifications + +The `inputs` field lists Kubernetes resources that the CEL expression can reference. + +#### Kubernetes Input Spec + +```yaml +inputs: + - name: deployment # Name used in the expression + kubernetes_input_spec: + api_version: apps/v1 # Kubernetes API version + resource: deployments # Resource type (plural form) + resource_name: my-app # Optional: specific resource name + resource_namespace: kube-system # Optional: specific namespace +``` + +If `resourceName` is omitted, the check applies to all resources of that type. +If `resourceNamespace` is omitted, the check applies across all namespaces. + +## CEL Profile Format + +CEL profiles use the standard profile format with one additional field: + +```yaml +documentation_complete: true + +title: 'CIS Red Hat OpenShift Virtual Machine Extension Benchmark' + +description: |- + Profile description text. + +scanner_type: CEL # REQUIRED: Marks this as a CEL profile + +selections: + - kubevirt-nonroot-feature-gate-is-enabled + - kubevirt-no-permitted-host-devices + - kubevirt-persistent-reservation-disabled +``` + +**Important:** CEL profiles can only select CEL rules. If a profile includes both CEL and OVAL rules, only the CEL rules will be included in the generated CEL content file. + +## Creating a CEL Rule + +### 1. Choose the Correct Directory + +CEL rules for Kubernetes/OpenShift should go under `applications/openshift/` or `applications/openshift-virtualization/`, organized by component: + +``` +applications/openshift-virtualization/ +├── group.yml +├── kubevirt-nonroot-feature-gate-is-enabled/ +│ └── rule.yml +├── kubevirt-no-permitted-host-devices/ +│ └── rule.yml +└── kubevirt-enforce-trusted-tls-registries/ + └── rule.yml +``` + +**Important:** Directory names should use hyphens (e.g., `kubevirt-nonroot-enabled`), not underscores. This follows Kubernetes naming conventions. + +### 2. Create the group.yml + +Each component directory requires a `group.yml` file: + +```yaml +documentation_complete: true + +title: 'OpenShift Virtualization' + +description: |- + Security recommendations for OpenShift Virtualization (KubeVirt). +``` + +### 3. Create the rule.yml and cel/shared.yml + +Follow the CEL rule format described above. Example: + +**rule.yml:** +```yaml +documentation_complete: true + +title: 'Ensure NonRoot Feature Gate is Enabled' + +description: |- + The NonRoot feature gate restricts containers from running as root, + reducing the attack surface. + +rationale: |- + Running containers as non-root users is a security best practice + that limits the impact of container breakout vulnerabilities. + +severity: medium + +ocil: |- + Run the following command to verify the NonRoot feature gate: +
oc get hyperconverged -n openshift-cnv kubevirt-hyperconverged -o jsonpath='{.spec.featureGates.nonRoot}'
+ The output should be true. + +references: + cis@ocp4: 5.7.1 +``` + +**cel/shared.yml:** +```yaml +check_type: Platform + +failure_reason: |- + The NonRoot feature gate is not enabled in the kubevirt-hyperconverged resource. + +expression: |- + hco.spec.featureGates.nonRoot == true + +inputs: + - name: hco + kubernetes_input_spec: + api_version: hco.kubevirt.io/v1beta1 + resource: hyperconvergeds + resource_name: kubevirt-hyperconverged + resource_namespace: openshift-cnv +``` + +## Build System Integration + +### Enabling CEL Content for a Product + +CEL content generation is enabled per-product in the product's `CMakeLists.txt`: + +```cmake +set(PRODUCT "ocp4") +set(PRODUCT_REMEDIATION_LANGUAGES "ignition;kubernetes") +set(PRODUCT_CEL_ENABLED TRUE) # Enable CEL content generation + +ssg_build_product(${PRODUCT}) +``` + +### Build Process + +When `PRODUCT_CEL_ENABLED` is set to `TRUE`, the build system: + +1. **Compiles all rules** (including CEL rules) using `compile_all.py` +2. **Filters CEL rules** - Rules with CEL checks are identified by the presence of `cel/shared.yml` containing `expression` and `inputs` fields +3. **Filters CEL profiles** - Profiles with `scanner_type: CEL` are identified +4. **Validates CEL content**: + - CEL rules must have `expression` field (non-empty) + - CEL rules must have `inputs` field (non-empty list) + - CEL profiles must have rules in `selected` field + - No duplicate rule names after conversion to hyphens + - Profiles can only reference existing CEL rules +5. **Generates CEL content YAML** at `build/${PRODUCT}-cel-content.yaml` + +### Build Script: build_cel_content.py + +The `build_cel_content.py` script is located in `build-scripts/` and performs the following: + +#### Input +- Resolved rules directory: `build/${PRODUCT}/rules/` +- Resolved profiles directory: `build/${PRODUCT}/profiles/` +- Product YAML: `build/${PRODUCT}/product.yml` + +#### Processing +1. Loads all rules with CEL checks (identified by having both `expression` and `inputs` fields from `cel/shared.yml`) +2. Validates required CEL fields (`expression`, `inputs`) +3. Loads all profiles with `scanner_type: CEL` +4. Validates profile rules are non-empty +5. Converts rule IDs (underscores) to rule names (hyphens) +6. Maps `ocil` field to `instructions` in output +7. Preserves reference keys like `cis@ocp4`, `nist`, etc. as `controls` +8. Validates no duplicate rule names +9. Validates all profile rule references exist + +#### Output +YAML file at `build/${PRODUCT}-cel-content.yaml` with structure: + +```yaml +profiles: + - id: cis_vm_extension + name: cis-vm-extension + title: CIS Red Hat OpenShift Virtual Machine Extension Benchmark + description: Profile description text + productType: Platform + rules: + - kubevirt-nonroot-feature-gate-is-enabled + - kubevirt-no-permitted-host-devices + +rules: + - id: kubevirt_nonroot_feature_gate_is_enabled + name: kubevirt-nonroot-feature-gate-is-enabled + title: Ensure NonRoot Feature Gate is Enabled + description: The NonRoot feature gate restricts containers... + rationale: Running containers as non-root... + severity: medium + checkType: Platform + expression: hco.spec.featureGates.nonRoot == true + inputs: + - name: hco + kubernetesInputSpec: + apiVersion: hco.kubevirt.io/v1beta1 + resource: hyperconvergeds + resourceName: kubevirt-hyperconverged + resourceNamespace: openshift-cnv + instructions: Run the following command... + controls: + cis@ocp4: + - 5.7.1 +``` + +### Build Targets + +```bash +# Build all content including CEL content (for products with PRODUCT_CEL_ENABLED) +./build_product ocp4 + +# Build data stream only (faster, excludes CEL content) +./build_product ocp4 --datastream +# Short form (only builds datastream): +./build_product ocp4 -d +# Legacy form (still supported): +./build_product ocp4 --datastream-only + +# Build data stream and CEL content +./build_product ocp4 --datastream --cel-content=ocp4 + +# Build only CEL content (no data stream) +./build_product --cel-content=ocp4 + +# Build CEL content for multiple products +./build_product --cel-content=ocp4,rhel9 + +# CEL content is generated as build/ocp4-cel-content.yaml +``` + +## Validation + +### Build-Time Validation + +The build system validates CEL content automatically: + +**Rule Validation:** +- `cel/shared.yml` file must exist for CEL rules +- `expression` field must be present and non-empty in `cel/shared.yml` +- `inputs` field must be present and non-empty list in `cel/shared.yml` +- Rule directory names must match rule IDs (with hyphens) + +**Profile Validation:** +- `selected` field must contain at least one rule +- All selected rules must exist in CEL rules +- Profile cannot reference OVAL rules + +**Content Validation:** +- No duplicate rule names (after underscore-to-hyphen conversion) +- All profile rule references must exist + +### Manual Validation + +Test CEL expressions using the CEL evaluator: + +```bash +# Using cel-go +cel-spec '{"resource": {"spec": {"enabled": true}}}' 'resource.spec.enabled == true' +``` + +## CEL vs OVAL Comparison + +| Aspect | CEL | OVAL | +|--------|-----|------| +| **Scope** | Kubernetes API resources | File system, processes, packages | +| **Access Required** | API server access | Node shell access | +| **Syntax** | CEL expressions (C-like) | XML definitions | +| **Performance** | Fast, API-level | Slower, requires node scanning | +| **Use Case** | Platform compliance | OS compliance | +| **Scanner** | compliance-operator | OpenSCAP | +| **Output Format** | YAML (cel-content.yaml) | XML (DataStream) | + +## Best Practices + +### Writing CEL Rules + +1. **Use specific resource names when possible** + ```yaml + inputs: + - name: config + kubernetes_input_spec: + api_version: v1 + resource: configmaps + resource_name: cluster-config # Specific resource + resource_namespace: openshift-config + ``` + +2. **Check for field existence before accessing** + ```yaml + expression: |- + !has(resource.spec.field) || resource.spec.field == "expected" + ``` + +3. **Keep expressions simple and readable** + - Break complex checks into multiple rules + - Use clear variable names in inputs + - Add comments for non-obvious logic + +4. **Test expressions thoroughly** + - Verify both pass and fail cases + - Test with missing fields + - Test with unexpected values + +### Organizing CEL Rules + +1. **Group related rules by component** + - Use meaningful directory names (e.g., `api-server/`, `kubelet/`) + - Create a `group.yml` for each component + +2. **Follow Kubernetes naming conventions** + - Use hyphens in directory names + - Keep names descriptive but concise + +3. **Document OCIL instructions** + - Provide manual verification commands + - Include expected output + - Use proper formatting with `
` and `` tags
+
+## Troubleshooting
+
+### Build Errors
+
+**Error: `CEL rule 'rule-name' has no expression`**
+- Add the `expression` field to your rule.yml
+
+**Error: `CEL rule 'rule-name' has no inputs`**
+- Add the `inputs` field with at least one Kubernetes input
+
+**Error: `CEL profile 'profile-name' has no rules`**
+- Add rules to the `selections` field in the profile
+
+**Error: `profile 'profile-name' references unknown rule 'rule-name'`**
+- Verify the rule exists and has CEL checks (has `cel/shared.yml` with `expression` and `inputs`)
+- Check the rule ID matches the profile selection
+
+### CEL Content Not Generated
+
+1. Verify `PRODUCT_CEL_ENABLED TRUE` is set in `products/${PRODUCT}/CMakeLists.txt`
+2. Check that rules have a `cel/shared.yml` file with `expression` and `inputs` fields
+3. Check that profiles have `scanner_type: CEL`
+4. Review build logs for validation errors
+
+## References
+
+- [CEL Language Specification](https://github.com/google/cel-spec)
+- [CEL Go Implementation](https://github.com/google/cel-go)
+- [Compliance Operator](https://github.com/ComplianceAsCode/compliance-operator)
+- [Kubernetes API Conventions](https://github.com/kubernetes/community/blob/master/contributors/devel/sig-architecture/api-conventions.md)
diff --git a/docs/manual/developer/13_nist_800_53_controls.md b/docs/manual/developer/13_nist_800_53_controls.md
new file mode 100644
index 000000000000..2581674c6e4c
--- /dev/null
+++ b/docs/manual/developer/13_nist_800_53_controls.md
@@ -0,0 +1,248 @@
+# NIST 800-53 Control Files
+
+## Architecture
+```
+products/rhel8/controls/
+├── nist_800_53.yml              # RHEL8-specific metadata
+└── nist_800_53/                 # RHEL8-specific family files (NO guards)
+    ├── ac.yml                   # Only rules available in rhel8
+    ├── au.yml
+    └── ... (21 family files)
+
+products/rhel9/controls/
+├── nist_800_53.yml              # RHEL9-specific metadata
+└── nist_800_53/                 # RHEL9-specific family files (NO guards)
+    ├── ac.yml                   # Only rules available in rhel9
+    ├── au.yml
+    └── ... (21 family files)
+
+products/rhel10/controls/
+├── nist_800_53.yml              # RHEL10-specific metadata
+└── nist_800_53/                 # RHEL10-specific family files (NO guards)
+    ├── ac.yml                   # Only rules available in rhel10
+    ├── au.yml
+    └── ... (21 family files)
+```
+
+## Benefits of Product-Specific Controls
+
+✅ **Cleaner files** - No Jinja2 conditional logic  
+✅ **Better separation** - Each product can evolve independently  
+✅ **Easier to read** - No guards cluttering the rule lists  
+✅ **No build errors** - No NoneType errors from guards evaluating to None  
+✅ **Smaller files** - Only rules that actually apply to the product  
+
+## File Structure
+
+### Product-Specific Control Files
+
+Each product has its own dedicated NIST 800-53 control files:
+
+**Metadata File**: `products/{product}/controls/nist_800_53.yml`
+```yaml
+policy: NIST 800-53 Revision 5
+title: NIST Special Publication 800-53 Revision 5
+id: nist_800_53
+version: Revision 5
+product: rhel9                    # Product-specific
+controls_dir: nist_800_53         # Points to family files
+levels:
+  - id: low
+  - id: moderate
+  - id: high
+```
+
+**Family Files**: `products/{product}/controls/nist_800_53/*.yml` (21 files)
+
+Example: `products/rhel9/controls/nist_800_53/au.yml`
+```yaml
+# NIST 800-53 AU Family: Audit and Accountability
+controls:
+  - id: au-2
+    title: Event Logging
+    levels:
+      - low
+      - moderate
+      - high
+    rules:
+      - aide_build_database
+      - aide_periodic_cron_checking
+      - audit_rules_execution_chacl
+      # ... only rules available in rhel9
+    status: automated
+```
+
+### OSCAL Metadata
+
+OSCAL metadata (description, parameters, guidance, related_controls) is **NOT included** in control files to keep them lean and focused on rule mappings.
+
+**How to retrieve OSCAL metadata**:
+1. **Direct from NIST OSCAL Catalog**: Download from [NIST OSCAL](https://pages.nist.gov/OSCAL/)
+2. **On-demand retrieval**: Web application or API can load the OSCAL JSON catalog and extract metadata by control ID
+3. **Build-time enrichment**: If needed for documentation, retrieve during build process
+
+**Benefits**:
+- Control files stay small (~50-200 lines per family vs. thousands)
+- OSCAL data retrieved from authoritative source (NIST catalog)
+- No duplication across products
+- Updates to OSCAL catalog don't require regenerating control files
+
+## Reference Files (Auto-Generated)
+
+Reference files are auto-generated weekly for comparison:
+
+```
+shared/references/controls/
+├── nist_800_53_cis_reference_rhel8.yml
+├── nist_800_53_cis_reference_rhel8/    # 21 family files
+│   ├── ac.yml
+│   ├── au.yml
+│   └── ...
+├── nist_800_53_cis_reference_rhel9.yml
+├── nist_800_53_cis_reference_rhel9/    # 21 family files
+├── nist_800_53_cis_reference_rhel10.yml
+└── nist_800_53_cis_reference_rhel10/   # 21 family files
+```
+
+- **Purpose**: Generated from CIS benchmark + NIST OSCAL for comparison
+- **Maintained By**: 🤖 **Weekly automation** (DO NOT edit manually)
+- **Usage**: Compare with product control files to detect changes
+
+## Control File Content
+
+Each control entry contains:
+
+```yaml
+- id: au-2                        # NIST control ID
+  title: Event Logging            # Control title
+  levels:                         # Baseline applicability
+    - low
+    - moderate
+    - high
+  rules:                          # Rules that implement this control
+    - var_audit_backlog_limit=8192
+    - aide_build_database
+    - audit_rules_execution_chacl
+  status: automated               # automated | manual | pending
+```
+
+**Field Descriptions**:
+- `id`: NIST 800-53 control identifier (lowercase)
+- `title`: Short descriptive title from NIST catalog
+- `levels`: LOW/MODERATE/HIGH baseline applicability
+- `rules`: Rule IDs and variable assignments that implement the control
+- `status`: 
+  - `automated` - Has rules/checks
+  - `pending` - No rules yet
+  - `manual` - Requires manual verification
+
+## How Profiles Use Control Files
+
+Product profiles reference their own NIST control files:
+
+**Profile**: `products/rhel9/profiles/cis_nist.profile`
+```yaml
+selections:
+  - nist_800_53:all    # References products/rhel9/controls/nist_800_53.yml
+```
+
+The build system automatically:
+1. Loads `products/rhel9/controls/nist_800_53.yml` metadata
+2. Reads `controls_dir: nist_800_53` field
+3. Loads all `.yml` files from `products/rhel9/controls/nist_800_53/`
+4. Merges into single control tree
+5. Expands `nist_800_53:all` to include all rules from all controls
+
+## Generating Control Files
+
+Control files are generated using the NIST sync toolkit:
+
+```bash
+cd utils/nist_sync
+
+# Generate reference files for all products
+./generate_cis_nist_workflow.sh
+
+# Generate for specific product
+python3 sync_nist_split.py --product rhel9
+
+# Copy reference to product directory
+cp shared/references/controls/nist_800_53_cis_reference_rhel9.yml \
+   products/rhel9/controls/nist_800_53.yml
+cp -r shared/references/controls/nist_800_53_cis_reference_rhel9/* \
+   products/rhel9/controls/nist_800_53/
+```
+
+See [utils/nist_sync/README.md](../../../utils/nist_sync/README.md) for details.
+
+## Workflow
+
+### Weekly Automated Sync
+
+Every Sunday at 2 PM UTC, GitHub Actions:
+1. Downloads latest NIST OSCAL catalog
+2. Generates product-specific reference files for rhel8, rhel9, rhel10
+3. Compares with previous version
+4. Creates PR if changes detected
+
+**Reference files updated automatically. Product control files require manual review.**
+
+### Manual Updates
+
+To update product control files:
+
+```bash
+# 1. Generate reference files
+cd utils/nist_sync
+./generate_cis_nist_workflow.sh
+
+# 2. Compare reference vs. product files
+diff -ur shared/references/controls/nist_800_53_cis_reference_rhel9/ \
+         products/rhel9/controls/nist_800_53/
+
+# 3. Review differences and manually update if needed
+vim products/rhel9/controls/nist_800_53/au.yml
+
+# 4. Test build
+./build_product rhel9 --datastream-only
+
+# 5. Commit changes
+git add products/rhel9/controls/nist_800_53/
+git commit -m "Update RHEL9 NIST 800-53 controls"
+```
+
+## Family Breakdown
+
+| Family | Name | Controls | Description |
+|--------|------|----------|-------------|
+| AC | Access Control | 147 | User access, permissions, least privilege |
+| AT | Awareness and Training | 17 | Security awareness, role-based training |
+| AU | Audit and Accountability | 69 | Logging, monitoring, audit records |
+| CA | Assessment, Authorization, Monitoring | 32 | Security assessments, continuous monitoring |
+| CM | Configuration Management | 66 | Baseline configs, change control |
+| CP | Contingency Planning | 56 | Backup, disaster recovery, continuity |
+| IA | Identification and Authentication | 74 | User authentication, MFA, credentials |
+| IR | Incident Response | 42 | Incident handling, response procedures |
+| MA | Maintenance | 30 | System maintenance, tools, personnel |
+| MP | Media Protection | 30 | Removable media, sanitization, disposal |
+| PE | Physical and Environmental Protection | 59 | Physical access, environmental controls |
+| PL | Planning | 17 | Security planning, architecture |
+| PM | Program Management | 37 | Program-level controls, governance |
+| PS | Personnel Security | 18 | Background checks, termination procedures |
+| PT | PII Processing and Transparency | 21 | Privacy, personally identifiable information |
+| RA | Risk Assessment | 26 | Vulnerability scanning, risk analysis |
+| SA | System and Services Acquisition | 147 | SDLC, supply chain, developer controls |
+| SC | System and Communications Protection | 162 | Network security, encryption, boundaries |
+| SI | System and Information Integrity | 119 | Malware protection, security alerts |
+| SR | Supply Chain Risk Management | 27 | Supply chain security, provenance |
+| OTHER | CIS Items Without NIST Mapping | 102 | CIS rules not explicitly mapped to NIST |
+
+**Total**: 1,196 NIST controls + 102 unmapped CIS items = **1,298 total controls**
+
+## References
+
+- **NIST OSCAL**: https://pages.nist.gov/OSCAL/
+- **NIST 800-53 Rev 5**: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final
+- **CIS Benchmarks**: https://www.cisecurity.org/cis-benchmarks
+- **Sync Toolkit**: [utils/nist_sync/README.md](../../../utils/nist_sync/README.md)
+- **GitHub Workflow**: [.github/workflows/cis-nist-sync.yml](../../../.github/workflows/cis-nist-sync.yml)
diff --git a/docs/manual/developer/14_nist_800_53_viewer.md b/docs/manual/developer/14_nist_800_53_viewer.md
new file mode 100644
index 000000000000..8e98646e70e6
--- /dev/null
+++ b/docs/manual/developer/14_nist_800_53_viewer.md
@@ -0,0 +1,326 @@
+# NIST 800-53 Control Viewer & Gap Analysis
+
+Interactive multi-page web-based viewer for NIST 800-53 control files with comprehensive gap analysis and backlog management features.
+
+## Architecture
+
+The viewer is a multi-page web application with the following pages:
+
+- **index.html** - Dashboard with overview statistics and charts
+- **controls.html** - Controls list with advanced filtering
+- **control-detail.html** - Individual control details with OSCAL metadata and TODO management
+- **gaps.html** - Gap analysis showing controls without rules
+- **statistics.html** - Detailed statistics and metrics
+- **family.html** - Control family breakdown and family-specific views
+
+All pages share:
+- Common navigation header for seamless page transitions
+- Shared CSS styling for consistent look and feel
+- Embedded JSON data for offline access (no external API calls)
+- Product selector that persists across pages via localStorage
+
+## Features
+
+### Dashboard (index.html)
+- **Overall Coverage Statistics**: Total controls, automated, manual, and pending counts with percentages
+- **Gap Analysis Summary**: Total controls without rules
+- **Product Comparison Table**: Side-by-side comparison of rhel8, rhel9, and rhel10 coverage
+- **Family Coverage Chart**: Bar chart showing automation coverage by control family
+- **Top Gaps List**: Quick view of controls that need rule implementation (links to detailed gap analysis)
+
+### Controls Browser (controls.html)
+- **Advanced Filtering**:
+  - Filter by control family (AC, AU, CM, IA, SC, SI, etc.)
+  - Filter by baseline level (Low, Moderate, High)
+  - Filter by status (Automated, Manual, Pending)
+  - Filter by gap status (With Rules, Without Rules)
+  - Full-text search across control IDs, titles, and descriptions
+  - Select All / Deselect All checkboxes for each filter category
+
+- **Controls List**:
+  - Clickable control cards showing ID, title, status, and metadata
+  - Visual gap indicators (red dots for controls without rules)
+  - Rule count and baseline level badges
+
+### Control Details (control-detail.html)
+- **OSCAL Metadata**: Full description, supplemental guidance, and parameters (ODPs)
+- **Implementation Status**: Automated, manual, or pending
+- **Rule Listings**: All rules mapped to this control
+- **Related Controls**: Clickable links to related controls
+- **Baseline Level Applicability**: Which baselines (low, moderate, high) include this control
+
+- **Backlog Management**:
+  - Add TODO items per control
+  - Mark items as complete
+  - Delete completed items
+  - Persistent storage in browser localStorage (per-control)
+
+### Gap Analysis (gaps.html)
+- **Gap Summary**: Total gaps broken down by baseline level (high, moderate, low)
+- **Priority Sections**: Gaps organized by baseline priority
+- **Family Breakdown**: Which control families have the most gaps
+- **Quick Navigation**: Click any gap to view control details
+
+### Statistics (statistics.html)
+- **Product Overview**: Comprehensive metrics for current product
+- **Baseline Breakdown**: Coverage statistics for each baseline level (low, moderate, high)
+- **Cross-Product Comparison**: Table comparing all products side-by-side
+- **Family Statistics**: Detailed metrics for each control family
+
+### Control Families (family.html)
+- **Family Grid View**: All control families with coverage stats
+- **Family Detail View**: Click any family to see all controls in that family
+- **Family-Specific Stats**: Automated, manual, pending, and gap counts per family
+- **Quick Control Access**: Jump to any control within a family
+
+## Building the Viewer
+
+### Using CMake (Recommended)
+
+```bash
+# Build everything including the NIST viewer
+cd build
+cmake .. -G Ninja
+ninja nist-viewer
+
+# The viewer will be generated at:
+# build/nist-controls-viewer/
+#   ├── index.html                   (Redirects to rhel9/)
+#   ├── nist-controls-data.json      (Reference data file)
+#   ├── rhel8/
+#   │   ├── index.html               (RHEL8 Dashboard)
+#   │   ├── controls.html            (Controls browser)
+#   │   ├── control-detail.html      (Control details)
+#   │   ├── gaps.html                (Gap analysis)
+#   │   ├── statistics.html          (Statistics)
+#   │   └── family.html              (Families)
+#   ├── rhel9/
+#   │   ├── index.html               (RHEL9 Dashboard)
+#   │   └── ... (same structure)
+#   └── rhel10/
+#       ├── index.html               (RHEL10 Dashboard)
+#       └── ... (same structure)
+```
+
+### Manual Generation
+
+```bash
+cd utils/nist_sync
+
+# Generate the viewer for specific products
+python3 generate_nist_viewer.py \
+  --products rhel8 rhel9 rhel10 \
+  --output-dir ../../build/nist-controls-viewer \
+  --repo-root ../..
+
+# Open the viewer (redirects to rhel9 by default)
+open ../../build/nist-controls-viewer/index.html
+
+# Or open a specific product directly:
+open ../../build/nist-controls-viewer/rhel9/index.html
+```
+
+## Published Version
+
+The viewer is automatically published to GitHub Pages via the `gh-pages` workflow:
+
+**URL**: https://complianceascode.github.io/content-pages/nist-viewer/
+
+The published version updates automatically when changes are pushed to the master branch. Navigate to the dashboard (index.html) to start browsing.
+
+## Data Structure
+
+The viewer generates product-specific pages in separate subdirectories (rhel8/, rhel9/, rhel10/). Each product's pages embed only that product's data (as `EMBEDDED_DATA` JavaScript constant), significantly reducing file sizes and improving performance.
+
+Product-specific data structure:
+- Each product subdirectory contains a complete set of viewer pages
+- Each page embeds only that product's control data (~2.5MB vs ~7.5MB for all products)
+- Pages communicate via URL parameters (e.g., `control-detail.html?id=ac-2`)
+- TODOs are stored in localStorage per-control
+- Product switching is done via links in the header (not localStorage)
+
+A separate `nist-controls-data.json` file is also generated for reference and debugging purposes.
+
+The data structure contains:
+
+```json
+{
+  "products": {
+    "rhel9": {
+      "metadata": { /* Product metadata */ },
+      "controls": [
+        {
+          "id": "ac-1",
+          "title": "Access Control Policy and Procedures",
+          "levels": ["low", "moderate", "high"],
+          "rules": ["rule_id_1", "rule_id_2"],
+          "status": "automated",
+          "description": "OSCAL description...",
+          "guidance": "OSCAL guidance...",
+          "parameters": [ /* ODPs */ ],
+          "related_controls": ["ac-2", "pm-9"],
+          "has_rules": true,
+          "is_automated": true
+        }
+      ]
+    }
+  },
+  "statistics": {
+    "rhel9": {
+      "total": 1196,
+      "automated": 850,
+      "manual": 50,
+      "pending": 296,
+      "with_rules": 900,
+      "without_rules": 296
+    }
+  },
+  "families": [ /* 21 control families */ ]
+}
+```
+
+## Gap Analysis Features
+
+### Gap Identification
+Controls are marked as "gaps" when:
+- `status: pending` - No implementation exists
+- `has_rules: false` - No rules are mapped to the control
+
+### Gap Visualization
+- **Dashboard**: Red indicator showing total gaps with percentage
+- **Controls List**: Red dot indicator on gap controls
+- **Filter**: Dedicated "Without Rules" filter to show only gaps
+- **Gap List**: Top 20 gaps displayed on dashboard
+
+### Addressing Gaps
+1. Navigate to a gap control in the Controls view
+2. Add TODO items describing what needs to be implemented
+3. Create the necessary rules in the repository
+4. Regenerate the viewer to see updated statistics
+
+## TODO/Backlog Management
+
+### Adding TODOs
+1. Select a control
+2. Scroll to the "TODO / Backlog Items" section
+3. Type your TODO item
+4. Click "Add"
+
+### Managing TODOs
+- **Check**: Mark as complete
+- **Uncheck**: Mark as incomplete
+- **Delete**: Remove the item
+
+TODOs are stored in browser localStorage, so they persist across sessions but are local to your browser.
+
+## Customization
+
+### Modifying the Templates
+Edit files in `utils/nist_sync/templates/` to customize:
+- **_shared_styles.html** - Common CSS used across all pages
+- **_shared_header.html** - Navigation header and product selector
+- **index.html** - Dashboard page
+- **controls.html** - Controls browser page
+- **control-detail.html** - Individual control detail page
+- **gaps.html** - Gap analysis page
+- **statistics.html** - Statistics page
+- **family.html** - Control families page
+
+Each template can have its own page-specific styles and JavaScript in addition to the shared components.
+
+### Adding New Statistics
+Modify `generate_nist_viewer.py`:
+1. Update `generate_viewer_data()` to calculate new statistics
+2. Update the template to display them
+
+### Regenerate
+After making changes:
+```bash
+ninja nist-viewer
+```
+
+## Workflow Integration
+
+The viewer is automatically built and published by `.github/workflows/gh-pages.yaml`:
+
+```yaml
+- name: Generate NIST 800-53 Control Viewer
+  run: ninja nist-viewer
+  working-directory: ./build
+```
+
+The generated files are copied to the GitHub Pages site by `utils/generate_html_pages.sh`.
+
+## Browser Compatibility
+
+The viewer uses modern JavaScript features and requires:
+- Chrome 90+
+- Firefox 88+
+- Safari 14+
+- Edge 90+
+
+No external dependencies - all functionality is self-contained in a single HTML file.
+
+## Troubleshooting
+
+### "Error loading data"
+- The data should be embedded in each HTML file - regenerate the viewer with `ninja nist-viewer`
+- If you modified a template, ensure the `/* DATA_PLACEHOLDER */` comment exists in the script section
+- Check browser console for specific error messages
+- Each HTML file should be several MB in size - if much smaller, the data wasn't embedded properly
+
+### Controls not showing
+- Check filter settings on controls.html - try resetting all filters
+- Verify the data is embedded (open browser console and check for `EMBEDDED_DATA`)
+- Try switching products using the product selector
+
+### TODOs not persisting
+- localStorage must be enabled in your browser
+- Check browser privacy settings
+- TODOs are per-browser, per-domain, and per-control
+- Clearing browser data will erase TODOs
+
+### Dashboard not rendering / Page not loading
+- Check browser console for JavaScript errors
+- Ensure the EMBEDDED_DATA constant is defined
+- Try refreshing the page
+- Verify you're using a modern browser (Chrome 90+, Firefox 88+, Safari 14+, Edge 90+)
+
+### Navigation not working
+- Ensure all 6 HTML files are in the same directory
+- Check that file paths are relative (not absolute)
+- If hosting on a web server, verify all files are accessible
+
+### Product selection not persisting
+- Check that localStorage is enabled
+- The product selection is stored in localStorage key `selected-product`
+- Clearing browser data will reset to default (rhel9)
+
+## Development
+
+To develop new features:
+
+1. Edit templates in `utils/nist_sync/templates/`:
+   - For styling changes: edit `_shared_styles.html`
+   - For navigation changes: edit `_shared_header.html`
+   - For page-specific changes: edit the corresponding page template
+2. Test locally by opening the generated HTML files in a browser
+3. Regenerate after changes: `ninja nist-viewer` (from build directory)
+4. Commit template changes
+
+### Adding a New Page
+
+1. Create a new template file in `utils/nist_sync/templates/` (e.g., `new-page.html`)
+2. Include placeholders for shared components:
+   ```html
+   
+   
+   /* DATA_PLACEHOLDER */
+   ```
+3. Add the page to the `pages` list in `generate_nist_viewer.py`
+4. Add navigation link to `_shared_header.html`
+5. Regenerate and test
+
+## License
+
+Same license as the ComplianceAsCode/content project (BSD-3-Clause).
diff --git a/docs/templates/template_reference.md b/docs/templates/template_reference.md
index 90e59824113e..9b9fc1d93c67 100644
--- a/docs/templates/template_reference.md
+++ b/docs/templates/template_reference.md
@@ -455,18 +455,46 @@ they must be of the same length.
 -   Languages: Bash, OVAL
 
 #### grub2_bootloader_argument
--   Ensures that a kernel command line argument is present in GRUB 2 configuration.
+- Ensures that a kernel command line argument is present in GRUB 2 configuration. For example `nousb` or `audit_backlog_limit=8192`.
 
--   Parameters:
-
-    -   **arg_name** - argument name, eg. `audit`
-
-    -   **arg_value** - argument value, eg. `'1'`
-
-    -   **arg_variable** - the variable used as the value for the argument, eg. `'var_slub_debug_options'`
-        This parameter is mutually exclusive with **arg_value**.
+- Parameters:
 
--   Languages: Ansible, Bash, OVAL, Blueprint, Kickstart
+    - **arg_name** (required) - kernel argument name, e.g. `audit`, `audit_backlog_limit`, `nousb`.
+
+    - **arg_value** (optional) value of the kernel argument, e.g. `'1'`, `'on'`.
+        - Mutually exclusive with **arg_variable**.
+        - Single-quote `arg_value` in `rule.yml`. This template expects `arg_value` to
+          stay a string, even when `datatype` is `int`, for example `arg_value: '20'`.
+
+    - **arg_variable** (optional) - XCCDF variable defined in a `.var` file,
+      e.g. `var_audit_backlog_limit`.
+        - Mutually exclusive with **arg_value**.
+        - If used, set **operation** and **datatype** to match the `.var` file's `type` and `operator` variables.
+
+    - **operation** - OVAL comparison operation applied to the extracted value.
+      Default: `equals` if omitted. Supported values:
+        - `equals` — exact match. Works with `string` or `int`.
+          Use for arguments with a single known-good value (e.g. `audit=1`,
+          `pti=on`).
+        - `pattern match` — regex match. Works with `string` only.
+          Use when multiple values are acceptable (e.g. `slub_debug` on OL8
+          where `P` must appear anywhere inside values like `FZP`).
+          Replaces the deprecated `is_substring` parameter.
+        - `greater than or equal` — numeric comparison. Works with `int` only.
+          Use for threshold arguments (e.g. `audit_backlog_limit>=8192`).
+        - Other operations (`not equal`, `greater than`, `less than`,
+          `less than or equal`) are validated but have no test coverage.
+          Adding a rule with these operations requires adding test scenarios and updating `template.py` to support them.
+
+    - **datatype** - OVAL datatype for the comparison. Default: `string`
+      if omitted. Supported values: `string`, `int`.
+        - `string` — lexicographic comparison. Use for non-numeric values
+          (e.g. `on`, `force`, `none`).
+        - `int` — numeric comparison. Use when the value is a number
+          (e.g. `audit_backlog_limit=8192`, `audit=1`). Required for numeric
+          operations like `greater than or equal`.
+
+- Languages: Ansible, Bash, OVAL, Blueprint, Kickstart
 
 #### grub2_bootloader_argument_absent
 -   Ensures that a kernel command line argument is absent in GRUB 2 configuration.
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_dac_actions/audit_rules_dac_modification_umount2/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_dac_actions/audit_rules_dac_modification_umount2/rule.yml
index 8664f8c4bc7d..6d3821a97db7 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_dac_actions/audit_rules_dac_modification_umount2/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_dac_actions/audit_rules_dac_modification_umount2/rule.yml
@@ -32,6 +32,7 @@ identifiers:
     cce@rhel10: CCE-89822-1
     cce@sle12: CCE-83219-6
     cce@sle15: CCE-91250-1
+    cce@sle16: CCE-96470-0
     cce@slmicro5: CCE-93655-9
     cce@slmicro6: CCE-94636-8
 
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_login_events/audit_rules_login_events_faillog/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_login_events/audit_rules_login_events_faillog/rule.yml
index d4672d865a96..1d15559a3503 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_login_events/audit_rules_login_events_faillog/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_login_events/audit_rules_login_events_faillog/rule.yml
@@ -15,6 +15,7 @@ rationale: |-
 severity: medium
 
 identifiers:
+    cce@rhcos4: CCE-90416-9
     cce@sle12: CCE-83192-5
     cce@sle15: CCE-92576-8
     cce@slmicro5: CCE-93841-5
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/bash/shared.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/bash/shared.sh
index 3e3132fa5740..d9d9f68d565b 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/bash/shared.sh
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/bash/shared.sh
@@ -15,7 +15,7 @@ function add_audit_rule()
     local PRIV_CMD="$1"
     local OTHER_FILTERS="-F path=$PRIV_CMD -F perm=x"
     # Perform the remediation for both possible tools: 'auditctl' and 'augenrules'
-{{% if product in ["fedora", "rhel10"] %}}
+{{% if product in ["al2023", "fedora", "rhel10"] %}}
     [ "$(getconf LONG_BIT)" = "32" ] && RULE_ARCHS=("b32") || RULE_ARCHS=("b32" "b64")
     for ARCH in "${RULE_ARCHS[@]}" ; do
         ACTION_ARCH_FILTERS="-a always,exit -F arch=$ARCH"
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/oval/shared.xml b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/oval/shared.xml
index 01d4e202ab2a..8a8af660be4c 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/oval/shared.xml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/oval/shared.xml
@@ -108,7 +108,7 @@
       recurse_file_system="defined" max_depth="-1"/>
     
-    ^\w+
+    /
     state_setuid_or_setgid_set
     state_dracut_tmp_files
   
@@ -117,7 +117,7 @@
     
     /
-    ^\w+
+    /
     state_setuid_or_setgid_set
     state_dracut_tmp_files
     state_audit_rules_privileged_commands_sysroot
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/rule.yml
index 7baee897f2ee..efef98acc465 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/rule.yml
@@ -53,6 +53,7 @@ identifiers:
     cce@rhel10: CCE-88170-6
     cce@sle12: CCE-91611-4
     cce@sle15: CCE-91251-9
+    cce@sle16: CCE-96363-7
 
 references:
     cis-csc: 1,11,12,13,14,15,16,19,2,3,4,5,6,7,8,9
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_extra_rules_configured.pass.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_extra_rules_configured.pass.sh
index 4f991c60a85d..b093b103d42f 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_extra_rules_configured.pass.sh
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_extra_rules_configured.pass.sh
@@ -3,7 +3,7 @@
 # platform = multi_platform_fedora,multi_platform_rhel,Oracle Linux 7,Oracle Linux 8,multi_platform_ubuntu
 
 ./generate_privileged_commands_rule.sh {{{ uid_min }}} privileged /etc/audit/rules.d/privileged.rules
-{{% if product in ["fedora", "rhel10"] %}}
+{{% if product in ["al2023", "fedora", "rhel10"] %}}
     echo "-a always,exit -F arch=b32 -F path=/usr/bin/notrelevant -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/privileged.rules
     echo "-a always,exit -F arch=b64 -F path=/usr/bin/notrelevant -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/privileged.rules
 {{% else %}}
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_one_rule.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_one_rule.fail.sh
index 6e197e75a561..27b589c781fa 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_one_rule.fail.sh
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_one_rule.fail.sh
@@ -1,7 +1,7 @@
 #!/bin/bash
 # packages = audit
 # platform = multi_platform_fedora,multi_platform_rhel,Oracle Linux 7,Oracle Linux 8,multi_platform_ubuntu
-{{% if product in ["fedora", "rhel10"] %}}
+{{% if product in ["al2023", "fedora", "rhel10"] %}}
     echo "-a always,exit -F arch=b32 -F path=/usr/bin/sudo -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/privileged.rules
     echo "-a always,exit -F arch=b64 -F path=/usr/bin/sudo -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/privileged.rules
 {{% else %}}
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_rules_configured_nonutf8.pass.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_rules_configured_nonutf8.pass.sh
new file mode 100644
index 000000000000..d84b3f4a106d
--- /dev/null
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_rules_configured_nonutf8.pass.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+# packages = audit
+# platform = multi_platform_fedora,multi_platform_rhel,Oracle Linux 7,Oracle Linux 8,multi_platform_ubuntu
+
+# This creates a situation from https://redhat.atlassian.net/browse/RHEL-171005
+# OpenSCAP produced an error in previous version of OVAL
+touch /etc/$(printf "evil_filename_\334_non_utf8_character")
+
+./generate_privileged_commands_rule.sh {{{ uid_min }}} privileged /etc/audit/rules.d/privileged.rules
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_two_rules_sep_files.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_two_rules_sep_files.fail.sh
index 6bba4a1c089c..54627a7136e5 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_two_rules_sep_files.fail.sh
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/augenrules_two_rules_sep_files.fail.sh
@@ -2,7 +2,7 @@
 # packages = audit
 # platform = multi_platform_fedora,multi_platform_rhel,Oracle Linux 7,Oracle Linux 8,multi_platform_ubuntu
 
-{{% if product in ["fedora", "rhel10"] %}}
+{{% if product in ["al2023", "fedora", "rhel10"] %}}
 echo "-a always,exit -F arch=b32 -F path=/usr/bin/newgrp -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/priv.rules
 echo "-a always,exit -F arch=b64 -F path=/usr/bin/newgrp -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/priv.rules
 echo "-a always,exit -F arch=b32 -F path=/usr/bin/notrelevant -F perm=x -F auid>={{{ uid_min }}} -F auid!=unset -F key=privileged" >> /etc/audit/rules.d/priv.rules
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/generate_privileged_commands_rule.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/generate_privileged_commands_rule.sh
index 51fe6dc630d4..6de0147b8310 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/generate_privileged_commands_rule.sh
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands/tests/generate_privileged_commands_rule.sh
@@ -4,7 +4,7 @@ AUID=$1
 KEY=$2
 RULEPATH=$3
 for file in $(find / -not \( -fstype afs -o -fstype autofs -o -fstype ceph -o -fstype cifs -o -fstype smb3 -o -fstype smbfs -o -fstype sshfs -o -fstype ncpfs -o -fstype ncp -o -fstype nfs -o -fstype nfs4 -o -fstype gfs -o -fstype gfs2 -o -fstype glusterfs -o -fstype gpfs -o -fstype pvfs2 -o -fstype ocfs2 -o -fstype lustre -o -fstype davfs -o -fstype fuse.sshfs \) -type f \( -perm -4000 -o -perm -2000 \) 2> /dev/null); do
-{{% if product in ["fedora", "rhel10"] %}}
+{{% if product in ["al2023", "fedora", "rhel10"] %}}
     [ "$(getconf LONG_BIT)" = "32" ] && RULE_ARCHS=("b32") || RULE_ARCHS=("b32" "b64")
     for ARCH in "${RULE_ARCHS[@]}" ; do
         echo "-a always,exit -F arch=$ARCH -F path=$file -F perm=x -F auid>=$AUID -F auid!=unset -k $KEY" >> $RULEPATH
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_insmod/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_insmod/rule.yml
index be642d92f573..6b2f502687d1 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_insmod/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_insmod/rule.yml
@@ -30,6 +30,7 @@ identifiers:
     cce@rhel10: CCE-90738-6
     cce@sle12: CCE-92258-3
     cce@sle15: CCE-85744-1
+    cce@sle16: CCE-96174-8
     cce@slmicro5: CCE-93612-0
     cce@slmicro6: CCE-94650-9
 
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_kmod/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_kmod/rule.yml
index c4a37ca44434..4d321ba3a10a 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_kmod/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_kmod/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel10: CCE-86727-5
     cce@sle12: CCE-83207-1
     cce@sle15: CCE-85591-6
+    cce@sle16: CCE-95909-8
     cce@slmicro5: CCE-93615-3
     cce@slmicro6: CCE-94616-0
 
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_modprobe/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_modprobe/rule.yml
index 288f0d033b4b..4ccc58df4968 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_modprobe/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_modprobe/rule.yml
@@ -34,6 +34,7 @@ identifiers:
     cce@rhel10: CCE-89893-2
     cce@sle12: CCE-92257-5
     cce@sle15: CCE-85731-8
+    cce@sle16: CCE-96256-3
     cce@slmicro5: CCE-93614-6
     cce@slmicro6: CCE-94652-5
 
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_rmmod/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_rmmod/rule.yml
index c2c798c0c6e7..40f76e0fcbea 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_rmmod/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_privileged_commands/audit_rules_privileged_commands_rmmod/rule.yml
@@ -30,6 +30,7 @@ identifiers:
     cce@rhel10: CCE-88804-0
     cce@sle12: CCE-92256-7
     cce@sle15: CCE-85732-6
+    cce@sle16: CCE-96358-7
     cce@slmicro5: CCE-93613-8
     cce@slmicro6: CCE-94651-7
 
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_enable_syscall_auditing/ansible/shared.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_enable_syscall_auditing/ansible/shared.yml
index 9210884db9f5..775b8f1d2046 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_enable_syscall_auditing/ansible/shared.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_enable_syscall_auditing/ansible/shared.yml
@@ -57,6 +57,7 @@
     name: auditd.service
     state: restarted
   when:
-    - ansible_facts.services["auditd.service"].state == "running"
+    - ("auditd.service" in ansible_facts.services and
+       ansible_facts.services["auditd.service"].state == "running")
     - (augenrules_syscall_auditing_rule_update_result.changed or
        auditctl_syscall_auditing_rule_update_result.changed)
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_etc_selinux/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_etc_selinux/rule.yml
index 5fd0a94fe92b..eff7c6924655 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_etc_selinux/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_etc_selinux/rule.yml
@@ -13,6 +13,7 @@ rationale: |-
 severity: medium
 
 identifiers:
+    cce@rhcos4: CCE-88995-6
     cce@rhel10: CCE-90737-8
     cce@sle15: CCE-92694-9
     cce@sle16: CCE-96212-6
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_usr_share/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_usr_share/rule.yml
index 7686c3fde492..387f832179c8 100644
--- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_usr_share/rule.yml
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_usr_share/rule.yml
@@ -13,6 +13,7 @@ rationale: |-
 severity: medium
 
 identifiers:
+    cce@rhcos4: CCE-88596-2
     cce@rhel8: CCE-86342-3
     cce@rhel9: CCE-86343-1
     cce@rhel10: CCE-88117-7
diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_var_lib_selinux/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_var_lib_selinux/rule.yml
new file mode 100644
index 000000000000..096b2fa83e8b
--- /dev/null
+++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_mac_modification_var_lib_selinux/rule.yml
@@ -0,0 +1,36 @@
+documentation_complete: true
+
+title: 'Record Events that Modify the System''s Mandatory Access Controls in /var/lib/selinux'
+
+description: |-
+    {{{ describe_audit_rules_watch("/var/lib/selinux/", "MAC-policy") }}}
+    Note that monitoring /var/lib/selinux/ will generate a significant burst of audit events
+    during both selinux-policy* package upgrade and policy rebuild.
+
+rationale: |-
+    The system's mandatory access policy (SELinux) should not be
+    arbitrarily changed by anything other than administrator action. All changes to
+    MAC policy should be audited.
+
+severity: medium
+
+identifiers:
+    cce@rhel8: CCE-86459-5
+    cce@rhel9: CCE-86461-1
+    cce@rhel10: CCE-86465-2
+
+ocil_clause: 'the system is not configured to audit attempts to change the MAC policy'
+
+ocil: |-
+    To determine if the system is configured to audit changes to its SELinux
+    configuration files, run the following command:
+    
$ sudo auditctl -l | grep "dir=/var/lib/selinux"
+ If the system is configured to watch for changes to its SELinux + configuration, a line should be returned (including + perm=wa indicating permissions that are watched). + +template: + name: audit_rules_watch + vars: + path: "/var/lib/selinux/" + key: MAC-policy diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_networkconfig_modification_network_scripts/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_networkconfig_modification_network_scripts/rule.yml index cbed79f2cd37..4db862d08347 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_networkconfig_modification_network_scripts/rule.yml +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_networkconfig_modification_network_scripts/rule.yml @@ -13,6 +13,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-90033-2 cce@rhel8: CCE-86939-6 cce@rhel9: CCE-86940-4 cce@rhel10: CCE-90731-1 diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers/rule.yml index 0dcb511e7002..aa5f534ed6bc 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers/rule.yml +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers/rule.yml @@ -18,6 +18,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88856-0 cce@rhel8: CCE-90175-1 cce@rhel9: CCE-90176-9 cce@rhel10: CCE-88688-7 diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers_d/rule.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers_d/rule.yml index c5a4ca17effb..5a91e876a445 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers_d/rule.yml +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_sudoers_d/rule.yml @@ -18,6 +18,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88024-5 cce@rhel8: CCE-89497-2 cce@rhel9: CCE-89498-0 cce@rhel10: CCE-89020-2 diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_auid_privilege_function/ansible/shared.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_auid_privilege_function/ansible/shared.yml index 9c5b7d2eb947..6ec3963a3007 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_auid_privilege_function/ansible/shared.yml +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_auid_privilege_function/ansible/shared.yml @@ -67,4 +67,5 @@ when: - (augenrules_audit_rules_privilege_function_update_result.changed or auditctl_audit_rules_privilege_function_update_result.changed) - - ansible_facts.services["auditd.service"].state == "running" + - ("auditd.service" in ansible_facts.services and + ansible_facts.services["auditd.service"].state == "running") diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/ansible/shared.yml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/ansible/shared.yml index 623eafd2c929..47440735410d 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/ansible/shared.yml +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/ansible/shared.yml @@ -4,22 +4,15 @@ # complexity = low # disruption = low -{{% if product not in ["ol8"] %}} {{% set egid_arg = " -F egid=0" %}} {{% set euid_arg = " -F euid=0" %}} -{{% endif %}} {{% set rx_beg = "^[\s]*-a[\s]+always,exit[\s]+" %}} {{% set rx_b32 = "-F[\s]+arch=b32[\s]+" %}} {{% set rx_b64 = "-F[\s]+arch=b64[\s]+" %}} -{{% if product in ["ol8"] %}} -{{% set rx_uid = "-S[\s]+execve[\s]+-C[\s]+uid!=euid[\s]+" %}} -{{% set rx_gid = "-S[\s]+execve[\s]+-C[\s]+gid!=egid[\s]+" %}} -{{% else %}} {{% set rx_uid = "-S[\s]+execve[\s]+-C[\s]+uid!=euid[\s]+-F[\s]+euid=0[\s]+" %}} {{% set rx_gid = "-S[\s]+execve[\s]+-C[\s]+gid!=egid[\s]+-F[\s]+egid=0[\s]+" %}} -{{% endif %}} {{% set rx_end = "(?:-k[\s]+|-F[\s]+key=)[\S]+[\s]*$" %}} @@ -75,4 +68,5 @@ when: - (augenrules_audit_rules_privilege_function_update_result.changed or auditctl_audit_rules_privilege_function_update_result.changed) - - ansible_facts.services["auditd.service"].state == "running" + - ("auditd.service" in ansible_facts.services and + ansible_facts.services["auditd.service"].state == "running") diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/bash/shared.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/bash/shared.sh index b452adbc65b1..a3f1129f160c 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/bash/shared.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/bash/shared.sh @@ -7,11 +7,7 @@ for ARCH in "${RULE_ARCHS[@]}" do ACTION_ARCH_FILTERS="-a always,exit -F arch=$ARCH" - {{% if product in ["ol8"] %}} - OTHER_FILTERS="-C uid!=euid" - {{% else %}} OTHER_FILTERS="-C uid!=euid -F euid=0" - {{% endif %}} AUID_FILTERS="" SYSCALL="execve" {{% if product in ["ubuntu2404"] %}} @@ -28,11 +24,7 @@ done for ARCH in "${RULE_ARCHS[@]}" do ACTION_ARCH_FILTERS="-a always,exit -F arch=$ARCH" - {{% if product in ["ol8"] %}} - OTHER_FILTERS="-C gid!=egid" - {{% else %}} OTHER_FILTERS="-C gid!=egid -F egid=0" - {{% endif %}} AUID_FILTERS="" SYSCALL="execve" {{% if product in ["ubuntu2404"] %}} diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/oval/shared.xml b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/oval/shared.xml index 8d56b6df6f8a..41b28f5823dd 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/oval/shared.xml +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/oval/shared.xml @@ -1,13 +1,8 @@ {{% set rx_beg = "^[\s]*-a[\s]+always,exit[\s]+" %}} {{% set rx_b32 = "-F[\s]+arch=b32[\s]+" %}} {{% set rx_b64 = "-F[\s]+arch=b64[\s]+" %}} -{{% if product in ["ol8"] %}} -{{% set rx_uid = "-S[\s]+execve[\s]+-C[\s]+uid!=euid[\s]+" %}} -{{% set rx_gid = "-S[\s]+execve[\s]+-C[\s]+gid!=egid[\s]+" %}} -{{% else %}} {{% set rx_uid = "-S[\s]+execve[\s]+-C[\s]+uid!=euid[\s]+-F[\s]+euid=0[\s]+" %}} {{% set rx_gid = "-S[\s]+execve[\s]+-C[\s]+gid!=egid[\s]+-F[\s]+egid=0[\s]+" %}} -{{% endif %}} {{% set rx_end = "(?:-k[\s]+|-F[\s]+key=)[\S]+[\s]*$" %}} diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/correct_value.pass.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/correct_value.pass.sh index e766ae3325d1..b88b869bbf03 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/correct_value.pass.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/correct_value.pass.sh @@ -1,13 +1,8 @@ #!/bin/bash # packages = audit -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=euid" -OTHER_FILTERS_EGID=" -C gid!=egid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=euid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=egid -F egid=0" -{{% endif %}} echo "-a always,exit -F arch=b32 -S execve${OTHER_FILTERS_EGID} -k setgid" > /etc/audit/rules.d/privileged.rules echo "-a always,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -k setgid" >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_arch.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_arch.fail.sh index 9c2c5255a03e..98ee49c06892 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_arch.fail.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_arch.fail.sh @@ -1,13 +1,8 @@ #!/bin/bash # packages = audit -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=euid" -OTHER_FILTERS_EGID=" -C gid!=egid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=euid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=egid -F egid=0" -{{% endif %}} echo "-a always,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -k setgid" > /etc/audit/rules.d/privileged.rules echo "-a always,exit -F arch=b32 -S execve${OTHER_FILTERS_EUID} -k setuid" >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_c.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_c.fail.sh index 2cec8e81404c..b8d987c0bb93 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_c.fail.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/miss_c.fail.sh @@ -1,11 +1,6 @@ #!/bin/bash # packages = audit -{{% if product not in ["ol8"] %}} -OTHER_FILTERS_EUID=" -F euid=0" -OTHER_FILTERS_EGID=" -F egid=0" -{{% endif %}} - echo "-a always,exit -F arch=b32 -S execve -C gid!=guid${OTHER_FILTERS_EGID} -k setgid" > /etc/audit/rules.d/privileged.rules echo "-a always,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -k setgid" >> /etc/audit/rules.d/privileged.rules echo "-a always,exit -F arch=b32 -S execve${OTHER_FILTERS_EUID} -k setuid" >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/other_key.pass.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/other_key.pass.sh index 09dfcb5076a6..1266ad33742d 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/other_key.pass.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/other_key.pass.sh @@ -3,13 +3,8 @@ # This tests situation where key value is not std. And also situation where there is extra spaces in rules. -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=euid" -OTHER_FILTERS_EGID=" -C gid!=egid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=euid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=egid -F egid=0" -{{% endif %}} echo " -a always,exit -F arch=b32 -S execve ${OTHER_FILTERS_EGID} -F key=my_setgid-audit-rule " > /etc/audit/rules.d/privileged.rules echo " -a always,exit -F arch=b64 -S execve ${OTHER_FILTERS_EGID} -k my_setgid-audit-rule " >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/use_f_key.pass.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/use_f_key.pass.sh index b0ce8f934bb9..4844f44f4e5e 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/use_f_key.pass.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/use_f_key.pass.sh @@ -1,14 +1,8 @@ #!/bin/bash # packages = audit - -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=euid" -OTHER_FILTERS_EGID=" -C gid!=egid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=euid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=egid -F egid=0" -{{% endif %}} echo "-a always,exit -F arch=b32 -S execve${OTHER_FILTERS_EGID} -F key=setgid" > /etc/audit/rules.d/privileged.rules echo "-a always,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -F key=setgid" >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_a.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_a.fail.sh index be0f1b541f00..499dfdb22ee7 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_a.fail.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_a.fail.sh @@ -1,13 +1,8 @@ #!/bin/bash # packages = audit -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=euid" -OTHER_FILTERS_EGID=" -C gid!=egid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=euid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=egid -F egid=0" -{{% endif %}} echo "-a never,exit -F arch=b32 -S execve${OTHER_FILTERS_EGID} -k setgid" > /etc/audit/rules.d/privileged.rules echo "-a never,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -k setgid" >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_egid.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_egid.fail.sh index a7b757311f41..f9078e64672b 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_egid.fail.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_egid.fail.sh @@ -1,13 +1,8 @@ #!/bin/bash # packages = audit -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=egid" -OTHER_FILTERS_EGID=" -C gid!=egid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=egid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=egid -F egid=0" -{{% endif %}} echo '-a always,exit -F arch=b32 -S execve${OTHER_FILTERS_EGID} -k setgid' > /etc/audit/rules.d/privileged.rules echo '-a always,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -k setgid' >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_euid.fail.sh b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_euid.fail.sh index 91c8e3521c0d..3f61e25013ae 100644 --- a/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_euid.fail.sh +++ b/linux_os/guide/auditing/auditd_configure_rules/audit_rules_suid_privilege_function/tests/wrong_c_euid.fail.sh @@ -1,13 +1,8 @@ #!/bin/bash # packages = audit -{{% if product in ["ol8"] %}} -OTHER_FILTERS_EUID=" -C uid!=euid" -OTHER_FILTERS_EGID=" -C gid!=euid" -{{% else %}} OTHER_FILTERS_EUID=" -C uid!=euid -F euid=0" OTHER_FILTERS_EGID=" -C gid!=euid -F egid=0" -{{% endif %}} echo '-a always,exit -F arch=b32 -S execve${OTHER_FILTERS_EGID} -k setgid' > /etc/audit/rules.d/privileged.rules echo '-a always,exit -F arch=b64 -S execve${OTHER_FILTERS_EGID} -k setgid' >> /etc/audit/rules.d/privileged.rules diff --git a/linux_os/guide/auditing/grub2_audit_argument/rule.yml b/linux_os/guide/auditing/grub2_audit_argument/rule.yml index 6da1958af700..097faf3f374a 100644 --- a/linux_os/guide/auditing/grub2_audit_argument/rule.yml +++ b/linux_os/guide/auditing/grub2_audit_argument/rule.yml @@ -57,6 +57,8 @@ template: vars: arg_name: audit arg_value: '1' + datatype: int + operation: equals fixtext: |- {{{ describe_grub2_argument("audit=1") | indent(4) }}} diff --git a/linux_os/guide/auditing/grub2_audit_backlog_limit_argument/rule.yml b/linux_os/guide/auditing/grub2_audit_backlog_limit_argument/rule.yml index 274342124aca..99b50a5c3ef7 100644 --- a/linux_os/guide/auditing/grub2_audit_backlog_limit_argument/rule.yml +++ b/linux_os/guide/auditing/grub2_audit_backlog_limit_argument/rule.yml @@ -29,6 +29,7 @@ identifiers: references: cis@sle12: 4.1.2.4 cis@sle15: 4.1.2.4 + hipaa: 164.308(a)(1)(ii)(D),164.308(a)(5)(ii)(C),164.310(a)(2)(iv),164.310(d)(2)(iii),164.312(b) nist: CM-6(a) ospp: FAU_STG.1,FAU_STG.3 srg: SRG-OS-000037-GPOS-00015,SRG-OS-000042-GPOS-00020,SRG-OS-000062-GPOS-00031,SRG-OS-000254-GPOS-00095,SRG-OS-000341-GPOS-00132,SRG-OS-000392-GPOS-00172,SRG-OS-000462-GPOS-00206,SRG-OS-000471-GPOS-00215 @@ -51,3 +52,5 @@ template: vars: arg_name: audit_backlog_limit arg_variable: var_audit_backlog_limit + datatype: int + operation: greater than or equal diff --git a/linux_os/guide/auditing/package_audispd-plugins_installed/rule.yml b/linux_os/guide/auditing/package_audispd-plugins_installed/rule.yml index f3c77b1eeff0..1e648b605618 100644 --- a/linux_os/guide/auditing/package_audispd-plugins_installed/rule.yml +++ b/linux_os/guide/auditing/package_audispd-plugins_installed/rule.yml @@ -21,9 +21,7 @@ identifiers: references: srg: SRG-OS-000342-GPOS-00133 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="audispd-plugins") }}}' +{{{ complete_ocil_entry_package_installed("audispd-plugins") }}} fixtext: '{{{ fixtext_package_installed("audispd-plugins") }}}' diff --git a/linux_os/guide/auditing/package_audit-libs_installed/rule.yml b/linux_os/guide/auditing/package_audit-libs_installed/rule.yml index cdd150b6925d..3b200b050cac 100644 --- a/linux_os/guide/auditing/package_audit-libs_installed/rule.yml +++ b/linux_os/guide/auditing/package_audit-libs_installed/rule.yml @@ -1,15 +1,15 @@ -{{% if product in ["sle12","sle15"] %}} -{{% set package_name = "libaudit1" %}} +{{% if product in ["sle12", "sle15", "slmicro5"] %}} + {{%- set package = "libaudit1" %}} {{% else %}} -{{% set package_name = "audit-libs" %}} + {{%- set package = "audit-libs" %}} {{% endif %}} documentation_complete: true -title: 'Ensure the {{{ package_name }}} package as a part of audit Subsystem is Installed' +title: 'Ensure the {{{ package }}} package as a part of audit Subsystem is Installed' -description: 'The {{{ package_name }}} package should be installed.' +description: 'The {{{ package }}} package should be installed.' rationale: 'The auditd service is an access monitoring and accounting daemon, watching system calls to audit any access, in comparison with potential local access control policy such as SELinux policy.' @@ -32,25 +32,16 @@ references: pcidss: Req-10.2.1 srg: SRG-OS-000062-GPOS-00031,SRG-OS-000037-GPOS-00015,SRG-OS-000038-GPOS-00016,SRG-OS-000039-GPOS-00017,SRG-OS-000040-GPOS-00018,SRG-OS-000041-GPOS-00019,SRG-OS-000042-GPOS-00021,SRG-OS-000051-GPOS-00024,SRG-OS-000054-GPOS-00025,SRG-OS-000122-GPOS-00063,SRG-OS-000254-GPOS-00095,SRG-OS-000255-GPOS-00096,SRG-OS-000337-GPOS-00129,SRG-OS-000348-GPOS-00136,SRG-OS-000349-GPOS-00137,SRG-OS-000350-GPOS-00138,SRG-OS-000351-GPOS-00139,SRG-OS-000352-GPOS-00140,SRG-OS-000353-GPOS-00141,SRG-OS-000354-GPOS-00142,SRG-OS-000358-GPOS-00145,SRG-OS-000365-GPOS-00152,SRG-OS-000392-GPOS-00172,SRG-OS-000475-GPOS-00220 -ocil_clause: 'the {{{ package_name }}} package is not installed' - -{{% if product in ["sle12","sle15","slmicro5"] %}} -ocil: '{{{ ocil_package("libaudit1") }}}' -{{% else %}} -ocil: '{{{ ocil_package("audit-libs") }}}' -{{% endif %}} +{{{ complete_ocil_entry_package_installed(package=package) }}} fixtext: |- - Install the {{{ package_name }}} package (if {{{ package_name }}} package is not already installed) with the following command: -{{% if product in ["sle12","sle15","slmicro5"] %}} - {{{ package_install("libaudit1") }}} -{{% else %}} - {{{ package_install("audit-libs") }}} -{{% endif %}} + Install the {{{ package }}} package (if {{{ package }}} package is not already installed) with the following command: + {{{ package_install(package=package) }}} template: name: package_installed vars: pkgname: audit-libs + pkgname@sle12: libaudit1 pkgname@sle15: libaudit1 pkgname@slmicro5: libaudit1 diff --git a/linux_os/guide/auditing/package_audit_installed/rule.yml b/linux_os/guide/auditing/package_audit_installed/rule.yml index 1f0043e096d3..47f71637a7a2 100644 --- a/linux_os/guide/auditing/package_audit_installed/rule.yml +++ b/linux_os/guide/auditing/package_audit_installed/rule.yml @@ -33,9 +33,7 @@ references: stigid@sle12: SLES-12-020000 stigid@sle15: SLES-15-030650 -ocil_clause: 'the audit package is not installed' - -ocil: '{{{ ocil_package("audit") }}}' +{{{ complete_ocil_entry_package_installed("audit") }}} fixtext: |- Install the audit service (if the audit service is not already installed) with the following command: diff --git a/linux_os/guide/auditing/var_audit_backlog_limit.var b/linux_os/guide/auditing/var_audit_backlog_limit.var index 6254b02137a1..87f0f12e2119 100644 --- a/linux_os/guide/auditing/var_audit_backlog_limit.var +++ b/linux_os/guide/auditing/var_audit_backlog_limit.var @@ -7,9 +7,9 @@ description: |- The audit_backlog_limit parameter determines how auditd records can be held in the auditd backlog. -type: string +type: number -operator: equals +operator: greater than or equal interactive: true diff --git a/linux_os/guide/services/avahi/disable_avahi_group/package_avahi-autoipd_removed/rule.yml b/linux_os/guide/services/avahi/disable_avahi_group/package_avahi-autoipd_removed/rule.yml index bcce1830dfb5..dec65f241145 100644 --- a/linux_os/guide/services/avahi/disable_avahi_group/package_avahi-autoipd_removed/rule.yml +++ b/linux_os/guide/services/avahi/disable_avahi_group/package_avahi-autoipd_removed/rule.yml @@ -33,7 +33,8 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="avahi-autoipd") }}} +{{{ complete_ocil_entry_package_removed("avahi-autoipd") }}} + fixtext: '{{{ fixtext_package_removed("avahi-autoipd") }}}' template: diff --git a/linux_os/guide/services/avahi/disable_avahi_group/package_avahi_removed/rule.yml b/linux_os/guide/services/avahi/disable_avahi_group/package_avahi_removed/rule.yml index c8f9b7d43b0f..9e62a077de40 100644 --- a/linux_os/guide/services/avahi/disable_avahi_group/package_avahi_removed/rule.yml +++ b/linux_os/guide/services/avahi/disable_avahi_group/package_avahi_removed/rule.yml @@ -34,7 +34,8 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="avahi") }}} +{{{ complete_ocil_entry_package_removed("avahi") }}} + fixtext: '{{{ fixtext_package_removed("avahi") }}}' template: diff --git a/linux_os/guide/services/base/package_abrt_removed/rule.yml b/linux_os/guide/services/base/package_abrt_removed/rule.yml index 5ad756c1d78f..64a7c2677464 100644 --- a/linux_os/guide/services/base/package_abrt_removed/rule.yml +++ b/linux_os/guide/services/base/package_abrt_removed/rule.yml @@ -26,7 +26,7 @@ references: srg: SRG-OS-000095-GPOS-00049 stigid@ol8: OL08-00-040001 -{{{ complete_ocil_entry_package(package="abrt") }}} +{{{ complete_ocil_entry_package_removed("abrt") }}} template: name: package_removed diff --git a/linux_os/guide/services/base/package_psacct_installed/rule.yml b/linux_os/guide/services/base/package_psacct_installed/rule.yml index ebdb655ed5e1..4eedf0d7c62d 100644 --- a/linux_os/guide/services/base/package_psacct_installed/rule.yml +++ b/linux_os/guide/services/base/package_psacct_installed/rule.yml @@ -29,9 +29,7 @@ references: nist: AU-12(a),CM-6(a) nist-csf: DE.CM-1,DE.CM-3,DE.CM-7,ID.SC-4,PR.IP-1,PR.PT-1,PR.PT-3 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="psacct") }}}' +{{{ complete_ocil_entry_package_installed("psacct") }}} template: name: package_installed diff --git a/linux_os/guide/services/cron_and_at/disable_anacron/rule.yml b/linux_os/guide/services/cron_and_at/disable_anacron/rule.yml index 18b12702432c..c539f453688f 100644 --- a/linux_os/guide/services/cron_and_at/disable_anacron/rule.yml +++ b/linux_os/guide/services/cron_and_at/disable_anacron/rule.yml @@ -26,4 +26,4 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="cronie-anacron") }}} +{{{ complete_ocil_entry_package_removed("cronie-anacron") }}} diff --git a/linux_os/guide/services/cron_and_at/package_cron_installed/rule.yml b/linux_os/guide/services/cron_and_at/package_cron_installed/rule.yml index 8ae169f1707d..1ad468bd6cd3 100644 --- a/linux_os/guide/services/cron_and_at/package_cron_installed/rule.yml +++ b/linux_os/guide/services/cron_and_at/package_cron_installed/rule.yml @@ -1,7 +1,7 @@ -{{% if product in [ "ol9", "ol10", "rhel8", "rhel9", "rhel10", "sle12", "sle15", "sle16"] %}} -{{% set package_name = "cronie" %}} +{{% if 'rhel' in product or product in ["ol9", "ol10", "sle12", "sle15", "sle16"] %}} + {{%- set package = "cronie" %}} {{% else %}} -{{% set package_name = "cron" %}} + {{%- set package = "cron" %}} {{% endif %}} documentation_complete: true @@ -35,12 +35,9 @@ references: nist-csf: PR.IP-1,PR.PT-3 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: 'the package is installed' - -ocil: |- - {{{ ocil_package(package_name) }}} +{{{ complete_ocil_entry_package_installed(package=package) }}} template: name: package_installed vars: - pkgname: {{{ package_name }}} + pkgname: {{{ package }}} diff --git a/linux_os/guide/services/cron_and_at/service_atd_disabled/rule.yml b/linux_os/guide/services/cron_and_at/service_atd_disabled/rule.yml index d88ad68377a9..e5286858dcae 100644 --- a/linux_os/guide/services/cron_and_at/service_atd_disabled/rule.yml +++ b/linux_os/guide/services/cron_and_at/service_atd_disabled/rule.yml @@ -20,6 +20,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-90250-2 cce@rhel8: CCE-80871-7 cce@rhel9: CCE-84164-3 diff --git a/linux_os/guide/services/dhcp/disabling_dhcp_client/package_dhcp_client_removed/rule.yml b/linux_os/guide/services/dhcp/disabling_dhcp_client/package_dhcp_client_removed/rule.yml index 8997bfccd035..362e3857b60c 100644 --- a/linux_os/guide/services/dhcp/disabling_dhcp_client/package_dhcp_client_removed/rule.yml +++ b/linux_os/guide/services/dhcp/disabling_dhcp_client/package_dhcp_client_removed/rule.yml @@ -30,7 +30,7 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="dhcp-client") }}} +{{{ complete_ocil_entry_package_removed("dhcp-client") }}} template: name: package_removed diff --git a/linux_os/guide/services/dhcp/disabling_dhcp_server/package_dhcp_removed/rule.yml b/linux_os/guide/services/dhcp/disabling_dhcp_server/package_dhcp_removed/rule.yml index cf13c4a31c11..be5f3397ad78 100644 --- a/linux_os/guide/services/dhcp/disabling_dhcp_server/package_dhcp_removed/rule.yml +++ b/linux_os/guide/services/dhcp/disabling_dhcp_server/package_dhcp_removed/rule.yml @@ -1,17 +1,19 @@ +{{% if 'ubuntu' in product %}} + {{%- set package = "isc-dhcp-server" %}} +{{% elif product in ['ol8', 'ol9', 'rhel8', 'rhel9', 'sle12', 'sle15'] %}} + {{%- set package = "dhcp-server" %}} +{{% else %}} + {{%- set package = "dhcp" %}} +{{% endif %}} + documentation_complete: true title: 'Uninstall DHCP Server Package' description: |- If the system does not need to act as a DHCP server, - the dhcp package can be uninstalled. - {{% if 'ubuntu' in product %}} - {{{ describe_package_remove(package="isc-dhcp-server") }}} - {{% elif product in ['ol8', 'ol9', 'rhel8', 'rhel9', 'sle12', 'sle15'] %}} - {{{ describe_package_remove(package="dhcp-server") }}} - {{% else %}} - {{{ describe_package_remove(package="dhcp") }}} - {{% endif %}} + the {{{ package }}} package can be uninstalled. + {{{ describe_package_remove(package=package) }}} rationale: |- Removing the DHCP server ensures that it cannot be easily or @@ -39,13 +41,8 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{% if 'ubuntu' in product %}} -{{{ complete_ocil_entry_package(package="isc-dhcp-server") }}} -{{% elif product in ['ol8', 'ol9', 'rhel8', 'rhel9', 'sle12', 'sle15'] %}} -{{{ complete_ocil_entry_package(package="dhcp-server") }}} -{{% else %}} -{{{ complete_ocil_entry_package(package="dhcp") }}} -{{% endif %}} + +{{{ complete_ocil_entry_package_removed(package=package) }}} template: name: package_removed diff --git a/linux_os/guide/services/dhcp/disabling_dhcp_server/package_kea_removed/rule.yml b/linux_os/guide/services/dhcp/disabling_dhcp_server/package_kea_removed/rule.yml index 6acdf95eb38f..c85abff6015a 100644 --- a/linux_os/guide/services/dhcp/disabling_dhcp_server/package_kea_removed/rule.yml +++ b/linux_os/guide/services/dhcp/disabling_dhcp_server/package_kea_removed/rule.yml @@ -16,8 +16,9 @@ severity: medium identifiers: cce@rhel8: CCE-87348-9 cce@rhel10: CCE-86596-4 + cce@sle16: CCE-96693-7 -{{{ complete_ocil_entry_package(package="kea") }}} +{{{ complete_ocil_entry_package_removed("kea") }}} template: name: package_removed diff --git a/linux_os/guide/services/dns/disabling_dns_server/package_bind_removed/rule.yml b/linux_os/guide/services/dns/disabling_dns_server/package_bind_removed/rule.yml index 5900a19c10c5..9e9e33fb7aea 100644 --- a/linux_os/guide/services/dns/disabling_dns_server/package_bind_removed/rule.yml +++ b/linux_os/guide/services/dns/disabling_dns_server/package_bind_removed/rule.yml @@ -17,6 +17,7 @@ rationale: |- severity: low identifiers: + cce@rhcos4: CCE-89670-4 cce@rhel8: CCE-82408-6 cce@rhel9: CCE-86505-5 cce@rhel10: CCE-87806-6 @@ -35,7 +36,7 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="bind") }}} +{{{ complete_ocil_entry_package_removed("bind") }}} template: name: package_removed diff --git a/linux_os/guide/services/dns/disabling_dns_server/service_named_disabled/rule.yml b/linux_os/guide/services/dns/disabling_dns_server/service_named_disabled/rule.yml index 102489344108..6fdbc76b7d31 100644 --- a/linux_os/guide/services/dns/disabling_dns_server/service_named_disabled/rule.yml +++ b/linux_os/guide/services/dns/disabling_dns_server/service_named_disabled/rule.yml @@ -12,6 +12,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88516-0 cce@rhel8: CCE-82409-4 cce@rhel9: CCE-84194-0 cce@sle12: CCE-92245-0 diff --git a/linux_os/guide/services/dns/package_dnsmasq_removed/rule.yml b/linux_os/guide/services/dns/package_dnsmasq_removed/rule.yml index 2b53ebdc4ab2..45d124710099 100644 --- a/linux_os/guide/services/dns/package_dnsmasq_removed/rule.yml +++ b/linux_os/guide/services/dns/package_dnsmasq_removed/rule.yml @@ -21,7 +21,7 @@ identifiers: cce@rhel10: CCE-86558-4 cce@sle15: CCE-92596-6 -{{{ complete_ocil_entry_package(package="dnsmasq") }}} +{{{ complete_ocil_entry_package_removed("dnsmasq") }}} template: name: package_removed diff --git a/linux_os/guide/services/dns/service_dnsmasq_disabled/rule.yml b/linux_os/guide/services/dns/service_dnsmasq_disabled/rule.yml index b030a645a893..51fe990a7a8f 100644 --- a/linux_os/guide/services/dns/service_dnsmasq_disabled/rule.yml +++ b/linux_os/guide/services/dns/service_dnsmasq_disabled/rule.yml @@ -13,6 +13,9 @@ rationale: |- severity: medium identifiers: + cce@rhel8: CCE-90720-4 + cce@rhel9: CCE-90721-2 + cce@rhel10: CCE-90722-0 cce@sle15: CCE-92602-2 platform: system_with_kernel diff --git a/linux_os/guide/services/docker/package_docker_installed/rule.yml b/linux_os/guide/services/docker/package_docker_installed/rule.yml index 5d3c27149a1d..fe6c70cf8616 100644 --- a/linux_os/guide/services/docker/package_docker_installed/rule.yml +++ b/linux_os/guide/services/docker/package_docker_installed/rule.yml @@ -14,9 +14,7 @@ rationale: |- severity: medium -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="docker") }}}' +{{{ complete_ocil_entry_package_installed("docker") }}} platform: machine diff --git a/linux_os/guide/services/fapolicyd/fapolicy_default_deny/oval/shared.xml b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/oval/shared.xml index ececdde98a74..302df5a17267 100644 --- a/linux_os/guide/services/fapolicyd/fapolicy_default_deny/oval/shared.xml +++ b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/oval/shared.xml @@ -24,7 +24,7 @@ /etc/fapolicyd/compiled.rules - ^\s*deny\s*perm=any\s*all\s*:\s*all\s*\z + ^\s*deny(_log|_audit)?\s*perm=any\s*all\s*:\s*all\s*\z 1 @@ -37,7 +37,7 @@ /etc/fapolicyd/fapolicyd.rules - ^\s*deny\s*perm=any\s*all\s*:\s*all\s*\z + ^\s*deny(_log|_audit)?\s*perm=any\s*all\s*:\s*all\s*\z 1 diff --git a/linux_os/guide/services/fapolicyd/fapolicy_default_deny/rule.yml b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/rule.yml index 0a2e4606c8d6..e68e0be98f46 100644 --- a/linux_os/guide/services/fapolicyd/fapolicy_default_deny/rule.yml +++ b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/rule.yml @@ -1,18 +1,25 @@ documentation_complete: true -title: 'Configure Fapolicy Module to Employ a Deny-all, Permit-by-exception Policy to Allow the Execution of Authorized Software Programs.' +title: "Configure Fapolicy Module to Employ a Deny-all, Permit-by-exception Policy to Allow the + Execution of Authorized Software Programs." description: |- - The Fapolicy module must be configured to employ a deny-all, permit-by-exception policy to allow the execution of authorized software programs and to prevent unauthorized software from running. + The Fapolicy module must be configured to employ a deny-all, permit-by-exception policy to + allow the execution of authorized software programs and to prevent unauthorized software from + running. rationale: |- - Utilizing a whitelist provides a configuration management method for allowing the execution of only authorized software. - Using only authorized software decreases risk by limiting the number of potential vulnerabilities. Verification of whitelisted software occurs prior to execution or at system startup. + Utilizing a whitelist provides a configuration management method for allowing the execution of + only authorized software. + Using only authorized software decreases risk by limiting the number of potential + vulnerabilities. + Verification of whitelisted software occurs prior to execution or at system startup. Proceed with caution with enforcing the use of this daemon. Improper configuration may render the system non-functional. - The "fapolicyd" API is not namespace aware and can cause issues when launching or running containers. + The "fapolicyd" API is not namespace aware and can cause issues when launching or running + containers. severity: medium @@ -22,11 +29,12 @@ identifiers: cce@rhel10: CCE-90343-5 references: - nist: CM-7 (2),CM-7 (5) (b),CM-6 b - srg: SRG-OS-000368-GPOS-00154,SRG-OS-000370-GPOS-00155,SRG-OS-000480-GPOS-00232 - stigid@ol8: OL08-00-040137 + nist: CM-7 (2),CM-7 (5) (b),CM-6 b + srg: SRG-OS-000368-GPOS-00154,SRG-OS-000370-GPOS-00155,SRG-OS-000480-GPOS-00232 + stigid@ol8: OL08-00-040137 -ocil_clause: 'fapolicyd is not running in enforcement mode with a deny-all, permit-by-exception policy' +ocil_clause: "fapolicyd is not running in enforcement mode with a deny-all, permit-by-exception + policy" ocil: |- Verify the {{{ full_name }}} "fapolicyd" employs a deny-all, permit-by-exception policy. @@ -52,23 +60,33 @@ ocil: |- deny_audit perm=any pattern=ld_so : all deny perm=any all : all + Note: The "deny_log" and "deny_audit" actions also meet the security requirements as they deny + execution while additionally providing logging. + fixtext: |- - Configure {{{ full_name }}} to employ a deny-all, permit-by-exception application whitelisting policy with "fapolicyd". + Configure {{{ full_name }}} to employ a deny-all, permit-by-exception application whitelisting + policy with "fapolicyd". - With the "fapolicyd" installed and enabled, configure the daemon to function in permissive mode until the whitelist is built correctly to avoid system lockout. Do this by editing the "/etc/fapolicyd/fapolicyd.conf" file with the following line: + With the "fapolicyd" installed and enabled, configure the daemon to function in permissive mode + until the whitelist is built correctly to avoid system lockout. + Do this by editing the "/etc/fapolicyd/fapolicyd.conf" file with the following line: permissive = 1 {{%- if product in ["ol8", "rhel8"] %}} For {{{ product_short_name }}} 8.5 systems and older: - Build the whitelist in the "/etc/fapolicyd/fapolicyd.rules" file ensuring the last rule is "deny perm=any all : all". + Build the whitelist in the "/etc/fapolicyd/fapolicyd.rules" file ensuring + the last rule is "deny perm=any all : all". For {{{ product_short_name }}} 8.6 systems and newer: {{%- endif %}} - Build the whitelist in a file within the "/etc/fapolicyd/rules.d" directory ensuring the last rule is "deny perm=any all : all". + Build the whitelist in a file within the "/etc/fapolicyd/rules.d" directory ensuring + the last rule implements a deny-all policy, such as "deny perm=any all : all". - Once it is determined the whitelist is built correctly, set the fapolicyd to enforcing mode by editing the "permissive" line in the /etc/fapolicyd/fapolicyd.conf file. + Once it is determined the whitelist is built correctly, set the fapolicyd to enforcing mode by + editing the "permissive" line in the /etc/fapolicyd/fapolicyd.conf file. permissive = 0 -srg_requirement: 'The {{{ full_name }}} fapolicy module must be configured to employ a deny-all, permit-by-exception policy to allow the execution of authorized software programs.' +srg_requirement: "The {{{ full_name }}} fapolicy module must be configured to employ a deny-all, + permit-by-exception policy to allow the execution of authorized software programs." diff --git a/linux_os/guide/services/fapolicyd/fapolicy_default_deny/tests/deny_audit_policy.pass.sh b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/tests/deny_audit_policy.pass.sh new file mode 100644 index 000000000000..5db205301c7e --- /dev/null +++ b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/tests/deny_audit_policy.pass.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# packages = fapolicyd + +if [ -f /etc/fapolicyd/compiled.rules ]; then + active_rules_file="/etc/fapolicyd/compiled.rules" +else + active_rules_file="/etc/fapolicyd/fapolicyd.rules" +fi + +truncate -s 0 $active_rules_file +echo "allow exe=/usr/bin/python3.7 : ftype=text/x-python" >> $active_rules_file +echo "deny_audit perm=any all : all" >> $active_rules_file + +{{{ set_config_file(path="/etc/fapolicyd/fapolicyd.conf", + parameter="permissive", + value="0", + create=true, + insensitive=true, + separator=" = ", + separator_regex="\s*=\s*", + prefix_regex="^\s*", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/fapolicyd/fapolicy_default_deny/tests/deny_log_policy.pass.sh b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/tests/deny_log_policy.pass.sh new file mode 100644 index 000000000000..15f8a2475402 --- /dev/null +++ b/linux_os/guide/services/fapolicyd/fapolicy_default_deny/tests/deny_log_policy.pass.sh @@ -0,0 +1,21 @@ +#!/bin/bash +# packages = fapolicyd + +if [ -f /etc/fapolicyd/compiled.rules ]; then + active_rules_file="/etc/fapolicyd/compiled.rules" +else + active_rules_file="/etc/fapolicyd/fapolicyd.rules" +fi + +truncate -s 0 $active_rules_file +echo "allow exe=/usr/bin/python3.7 : ftype=text/x-python" >> $active_rules_file +echo "deny_log perm=any all : all" >> $active_rules_file + +{{{ set_config_file(path="/etc/fapolicyd/fapolicyd.conf", + parameter="permissive", + value="0", + create=true, + insensitive=true, + separator=" = ", + separator_regex="\s*=\s*", + prefix_regex="^\s*", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/fapolicyd/package_fapolicyd_installed/rule.yml b/linux_os/guide/services/fapolicyd/package_fapolicyd_installed/rule.yml index e7fad9aefd82..e68b0952998e 100644 --- a/linux_os/guide/services/fapolicyd/package_fapolicyd_installed/rule.yml +++ b/linux_os/guide/services/fapolicyd/package_fapolicyd_installed/rule.yml @@ -24,9 +24,7 @@ references: srg: SRG-OS-000370-GPOS-00155,SRG-OS-000368-GPOS-00154,SRG-OS-000480-GPOS-00230 stigid@ol8: OL08-00-040135 -ocil_clause: 'the fapolicyd package is not installed' - -ocil: '{{{ ocil_package(package="fapolicyd") }}}' +{{{ complete_ocil_entry_package_installed("fapolicyd") }}} fixtext: |- {{{ fixtext_package_installed("fapolicyd") | indent(4) }}} diff --git a/linux_os/guide/services/ftp/disabling_vsftpd/package_vsftpd_removed/rule.yml b/linux_os/guide/services/ftp/disabling_vsftpd/package_vsftpd_removed/rule.yml index 71dba8c3e8ba..783ab5e16d83 100644 --- a/linux_os/guide/services/ftp/disabling_vsftpd/package_vsftpd_removed/rule.yml +++ b/linux_os/guide/services/ftp/disabling_vsftpd/package_vsftpd_removed/rule.yml @@ -12,6 +12,7 @@ rationale: |- severity: high identifiers: + cce@rhcos4: CCE-87843-9 cce@rhel8: CCE-82414-4 cce@rhel9: CCE-84159-3 cce@rhel10: CCE-88674-7 @@ -35,7 +36,7 @@ references: stigid@sle12: SLES-12-030011 stigid@sle15: SLES-15-010030 -{{{ complete_ocil_entry_package(package="vsftpd") }}} +{{{ complete_ocil_entry_package_removed("vsftpd") }}} fixtext: '{{{ fixtext_package_removed(package="vsftpd") }}}' diff --git a/linux_os/guide/services/ftp/disabling_vsftpd/service_vsftpd_disabled/rule.yml b/linux_os/guide/services/ftp/disabling_vsftpd/service_vsftpd_disabled/rule.yml index 94098ec1e013..988bfbcf7f7d 100644 --- a/linux_os/guide/services/ftp/disabling_vsftpd/service_vsftpd_disabled/rule.yml +++ b/linux_os/guide/services/ftp/disabling_vsftpd/service_vsftpd_disabled/rule.yml @@ -15,6 +15,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88298-5 cce@rhel8: CCE-82413-6 cce@rhel9: CCE-84160-1 cce@sle12: CCE-92246-8 diff --git a/linux_os/guide/services/ftp/ftp_configure_vsftpd/ftp_present_banner/ansible/shared.yml b/linux_os/guide/services/ftp/ftp_configure_vsftpd/ftp_present_banner/ansible/shared.yml index efd98396f197..68a79f0c9a31 100644 --- a/linux_os/guide/services/ftp/ftp_configure_vsftpd/ftp_present_banner/ansible/shared.yml +++ b/linux_os/guide/services/ftp/ftp_configure_vsftpd/ftp_present_banner/ansible/shared.yml @@ -20,4 +20,5 @@ ansible.builtin.systemd: name: vsftpd.service state: restarted - when: banner_file_update_result.changed and ansible_facts.services["vsftpd.service"].state == "running" + when: (banner_file_update_result.changed and "vsftpd.service" in ansible_facts.services + and ansible_facts.services["vsftpd.service"].state == "running") diff --git a/linux_os/guide/services/http/disabling_httpd/package_httpd_removed/rule.yml b/linux_os/guide/services/http/disabling_httpd/package_httpd_removed/rule.yml index 0c1605831326..02f281ed5266 100644 --- a/linux_os/guide/services/http/disabling_httpd/package_httpd_removed/rule.yml +++ b/linux_os/guide/services/http/disabling_httpd/package_httpd_removed/rule.yml @@ -1,15 +1,15 @@ documentation_complete: true {{% if 'ubuntu' in product %}} -{{% set package_name = "apache2" %}} + {{%- set package = "apache2" %}} {{% else %}} -{{% set package_name = "httpd" %}} + {{%- set package = "httpd" %}} {{% endif %}} -title: 'Uninstall {{{ package_name }}} Package' +title: 'Uninstall {{{ package }}} Package' description: |- - {{{ describe_package_remove(package=package_name) }}} + {{{ describe_package_remove(package=package) }}} rationale: |- If there is no need to make the web server software available, @@ -36,9 +36,9 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package=package_name) }}} +{{{ complete_ocil_entry_package_removed(package=package) }}} template: name: package_removed vars: - pkgname: {{{ package_name }}} + pkgname: {{{ package }}} diff --git a/linux_os/guide/services/http/disabling_nginx/package_nginx_removed/rule.yml b/linux_os/guide/services/http/disabling_nginx/package_nginx_removed/rule.yml index a08e93d5c988..55004edb92bf 100644 --- a/linux_os/guide/services/http/disabling_nginx/package_nginx_removed/rule.yml +++ b/linux_os/guide/services/http/disabling_nginx/package_nginx_removed/rule.yml @@ -24,7 +24,7 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="nginx") }}} +{{{ complete_ocil_entry_package_removed("nginx") }}} template: name: package_removed diff --git a/linux_os/guide/services/imap/disabling_cyrus-imapd/package_cyrus-imapd_removed/rule.yml b/linux_os/guide/services/imap/disabling_cyrus-imapd/package_cyrus-imapd_removed/rule.yml index 3906c80254f7..04338b8528cd 100644 --- a/linux_os/guide/services/imap/disabling_cyrus-imapd/package_cyrus-imapd_removed/rule.yml +++ b/linux_os/guide/services/imap/disabling_cyrus-imapd/package_cyrus-imapd_removed/rule.yml @@ -17,7 +17,7 @@ identifiers: cce@rhel10: CCE-90156-1 cce@sle15: CCE-92595-8 -{{{ complete_ocil_entry_package(package="cyrus-imapd") }}} +{{{ complete_ocil_entry_package_removed("cyrus-imapd") }}} template: name: package_removed diff --git a/linux_os/guide/services/imap/disabling_dovecot/package_dovecot_removed/rule.yml b/linux_os/guide/services/imap/disabling_dovecot/package_dovecot_removed/rule.yml index 3cfd8548ef7b..0a1f7f5b2a2e 100644 --- a/linux_os/guide/services/imap/disabling_dovecot/package_dovecot_removed/rule.yml +++ b/linux_os/guide/services/imap/disabling_dovecot/package_dovecot_removed/rule.yml @@ -1,13 +1,15 @@ +{{% if 'ubuntu' not in product %}} + {{%- set package = "dovecot" %}} +{{% else %}} + {{%- set package = "dovecot-core" %}} +{{% endif %}} + documentation_complete: true title: 'Uninstall dovecot Package' description: |- - {{% if 'ubuntu' not in product %}} - {{{ describe_package_remove(package="dovecot") }}} - {{% else %}} - {{{ describe_package_remove(package="dovecot-core") }}} - {{% endif %}} + {{{ describe_package_remove(package=package) }}} rationale: |- If there is no need to make the Dovecot software available, @@ -27,11 +29,7 @@ references: cis@sle12: 2.2.12 cis@sle15: 2.2.12 -{{% if 'ubuntu' not in product %}} -{{{ complete_ocil_entry_package(package="dovecot") }}} -{{% else %}} -{{{ complete_ocil_entry_package(package="dovecot-core") }}} -{{% endif %}} +{{{ complete_ocil_entry_package_removed(package=package) }}} template: name: package_removed diff --git a/linux_os/guide/services/kerberos/package_krb5-server_removed/rule.yml b/linux_os/guide/services/kerberos/package_krb5-server_removed/rule.yml index 336f04b987bd..9f180563b3f9 100644 --- a/linux_os/guide/services/kerberos/package_krb5-server_removed/rule.yml +++ b/linux_os/guide/services/kerberos/package_krb5-server_removed/rule.yml @@ -32,9 +32,7 @@ references: platforms: - krb5_server_older_than_1_17-18 -ocil_clause: 'the package is installed' - -ocil: '{{{ ocil_package(package="krb5-server") }}}' +{{{ complete_ocil_entry_package_removed("krb5-server") }}} template: name: package_removed diff --git a/linux_os/guide/services/ldap/openldap_client/enable_ldap_client/rule.yml b/linux_os/guide/services/ldap/openldap_client/enable_ldap_client/rule.yml index b7cbdd7c5b61..5feb392ab915 100644 --- a/linux_os/guide/services/ldap/openldap_client/enable_ldap_client/rule.yml +++ b/linux_os/guide/services/ldap/openldap_client/enable_ldap_client/rule.yml @@ -41,3 +41,5 @@ ocil: |-
$ sudo grep -i useldapauth /etc/sysconfig/authconfig
The output should return:
USELDAPAUTH=yes
+ +platform: system_with_kernel diff --git a/linux_os/guide/services/ldap/openldap_client/package_openldap-clients_removed/rule.yml b/linux_os/guide/services/ldap/openldap_client/package_openldap-clients_removed/rule.yml index d8a0c6ed8a2a..5ff291774a91 100644 --- a/linux_os/guide/services/ldap/openldap_client/package_openldap-clients_removed/rule.yml +++ b/linux_os/guide/services/ldap/openldap_client/package_openldap-clients_removed/rule.yml @@ -1,9 +1,9 @@ -{{% if product in ["sle12", "sle15"] %}} -{{% set package_name = "openldap2-client" %}} +{{% if product in ["sle12", "sle15", "slmicro5"] %}} + {{%- set package = "openldap2-client" %}} {{% elif "ubuntu" in product %}} -{{% set package_name = "ldap-utils" %}} + {{%- set package = "ldap-utils" %}} {{% else %}} -{{% set package_name = "openldap-clients" %}} + {{%- set package = "openldap-clients" %}} {{% endif %}} documentation_complete: true @@ -14,7 +14,7 @@ title: 'Ensure LDAP client is not installed' description: |- The Lightweight Directory Access Protocol (LDAP) is a service that provides a method for looking up information from a central database. - {{{ describe_package_remove( package_name ) }}} + {{{ describe_package_remove(package=package) }}} rationale: @@ -35,10 +35,7 @@ references: cis@sle12: 2.3.5 cis@sle15: 2.3.5 -ocil_clause: 'the package is installed' - -ocil: |- - {{{ ocil_package(package_name) }}} +{{{ complete_ocil_entry_package_removed(package=package) }}} template: name: package_removed diff --git a/linux_os/guide/services/ldap/openldap_server/package_openldap-servers_removed/rule.yml b/linux_os/guide/services/ldap/openldap_server/package_openldap-servers_removed/rule.yml index 5c805fa09975..2c2f7ea7552a 100644 --- a/linux_os/guide/services/ldap/openldap_server/package_openldap-servers_removed/rule.yml +++ b/linux_os/guide/services/ldap/openldap_server/package_openldap-servers_removed/rule.yml @@ -1,20 +1,17 @@ -{{% if product in ["sle12", "sle15"] %}} -{{% set package_name = "openldap2" %}} -{{% set run_cmd = "$ rpm -q openldap2" %}} +{{% if product in ["sle12", "sle15", "slmicro5"] %}} + {{%- set package = "openldap2" %}} {{% elif "ubuntu" in product %}} -{{% set package_name = "slapd" %}} -{{% set run_cmd = "$ dpkg -l slapd" %}} + {{%- set package = "slapd" %}} {{% else %}} -{{% set package_name = "openldap-servers" %}} -{{% set run_cmd = "$ rpm -q openldap-servers" %}} + {{%- set package = "openldap-servers" %}} {{% endif %}} documentation_complete: true -title: 'Uninstall openldap-servers Package' +title: 'Uninstall {{{ package }}} Package' description: |- - The {{{ package_name }}} package is not installed by default on a {{{ full_name }}} + The {{{ package }}} package is not installed by default on a {{{ full_name }}} system. It is needed only by the OpenLDAP server, not by the clients which use LDAP for authentication. If the system is not intended for use as an LDAP Server it should be removed. @@ -43,14 +40,8 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -ocil_clause: "it does not" -ocil: |- - To verify the {{{ package_name }}} package is not installed, run the - following command: -
{{{ run_cmd }}}
- The output should show the following: -
package {{{ package_name }}} is not installed
+{{{ complete_ocil_entry_package_removed(package=package) }}} template: name: package_removed diff --git a/linux_os/guide/services/mail/package_mailx_installed/rule.yml b/linux_os/guide/services/mail/package_mailx_installed/rule.yml index 6e42ca61263d..b61f166bb54b 100644 --- a/linux_os/guide/services/mail/package_mailx_installed/rule.yml +++ b/linux_os/guide/services/mail/package_mailx_installed/rule.yml @@ -26,9 +26,7 @@ references: stigid@sle12: SLES-12-010498 stigid@sle15: SLES-15-010418 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="mailx") }}}' +{{{ complete_ocil_entry_package_installed("mailx") }}} fixtext: '{{{ fixtext_package_installed(package="mailx") }}}' diff --git a/linux_os/guide/services/mail/package_postfix_installed/rule.yml b/linux_os/guide/services/mail/package_postfix_installed/rule.yml index 59373fb084a9..8a076cd1420a 100644 --- a/linux_os/guide/services/mail/package_postfix_installed/rule.yml +++ b/linux_os/guide/services/mail/package_postfix_installed/rule.yml @@ -15,13 +15,13 @@ severity: medium identifiers: cce@rhel8: CCE-85983-5 cce@rhel9: CCE-85984-3 + cce@rhel10: CCE-86466-0 references: + hipaa: 164.312(a)(2)(ii) srg: SRG-OS-000046-GPOS-00022 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="postfix") }}}' +{{{ complete_ocil_entry_package_installed("postfix") }}} fixtext: '{{{ fixtext_package_installed(package="postfix") }}}' diff --git a/linux_os/guide/services/mail/package_s-nail_installed/rule.yml b/linux_os/guide/services/mail/package_s-nail_installed/rule.yml index 7b49a41fd5da..244b65b94499 100644 --- a/linux_os/guide/services/mail/package_s-nail_installed/rule.yml +++ b/linux_os/guide/services/mail/package_s-nail_installed/rule.yml @@ -21,9 +21,7 @@ references: nist: CM-3(5) srg: SRG-OS-000363-GPOS-00150 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="s-nail") }}}' +{{{ complete_ocil_entry_package_installed("s-nail") }}} template: name: package_installed diff --git a/linux_os/guide/services/mail/package_sendmail_removed/rule.yml b/linux_os/guide/services/mail/package_sendmail_removed/rule.yml index 59e0d3880866..6cf8ca96e488 100644 --- a/linux_os/guide/services/mail/package_sendmail_removed/rule.yml +++ b/linux_os/guide/services/mail/package_sendmail_removed/rule.yml @@ -33,7 +33,7 @@ references: srg: SRG-OS-000480-GPOS-00227,SRG-OS-000095-GPOS-00049 stigid@ol8: OL08-00-040002 -{{{ complete_ocil_entry_package(package="sendmail") }}} +{{{ complete_ocil_entry_package_removed("sendmail") }}} fixtext: '{{{ fixtext_package_removed("sendmail") }}}' diff --git a/linux_os/guide/services/mail/postfix_client/postfix_client_configure_mail_alias/rule.yml b/linux_os/guide/services/mail/postfix_client/postfix_client_configure_mail_alias/rule.yml index da2b9e7fd6f6..721e16e03d13 100644 --- a/linux_os/guide/services/mail/postfix_client/postfix_client_configure_mail_alias/rule.yml +++ b/linux_os/guide/services/mail/postfix_client/postfix_client_configure_mail_alias/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-87937-9 cce@sle12: CCE-83031-5 cce@sle15: CCE-85605-4 + cce@sle16: CCE-95842-1 cce@slmicro5: CCE-93678-1 cce@slmicro6: CCE-94656-6 diff --git a/linux_os/guide/services/mail/postfix_client/postfix_network_listening_disabled/ansible/shared.yml b/linux_os/guide/services/mail/postfix_client/postfix_network_listening_disabled/ansible/shared.yml index ca9c793677b4..c824000342ba 100644 --- a/linux_os/guide/services/mail/postfix_client/postfix_network_listening_disabled/ansible/shared.yml +++ b/linux_os/guide/services/mail/postfix_client/postfix_network_listening_disabled/ansible/shared.yml @@ -4,9 +4,4 @@ # complexity = low # disruption = low {{{ ansible_instantiate_variables("var_postfix_inet_interfaces") }}} - -- name: "Gather list of packages" - ansible.builtin.package_facts: - manager: auto - -{{{ ansible_lineinfile(msg='Make changes to Postfix configuration file', path='/etc/postfix/main.cf', regex='^inet_interfaces\s*=\s.*', insensitive='false', new_line='inet_interfaces = {{ var_postfix_inet_interfaces }}', create='no', state='present', insert_after='^inet_interfaces\s*=\s.*', when='"postfix" in ansible_facts.packages', rule_title=rule_title) }}} +{{{ ansible_only_lineinfile(msg='Make changes to Postfix configuration file', path='/etc/postfix/main.cf', line_regex='^inet_interfaces\s*=\s*.*$', new_line='inet_interfaces = {{ var_postfix_inet_interfaces }}', create='no', block=True, rule_title=rule_title) }}} diff --git a/linux_os/guide/services/nfs_and_rpc/disabling_nfs/disabling_nfs_services/package_rpcbind_removed/rule.yml b/linux_os/guide/services/nfs_and_rpc/disabling_nfs/disabling_nfs_services/package_rpcbind_removed/rule.yml index ac9312c2317f..0bd04cbf81f4 100644 --- a/linux_os/guide/services/nfs_and_rpc/disabling_nfs/disabling_nfs_services/package_rpcbind_removed/rule.yml +++ b/linux_os/guide/services/nfs_and_rpc/disabling_nfs/disabling_nfs_services/package_rpcbind_removed/rule.yml @@ -28,7 +28,7 @@ references: cis@sle12: 2.2.8 cis@sle15: 2.2.8 -{{{ complete_ocil_entry_package(package="rpcbind") }}} +{{{ complete_ocil_entry_package_removed("rpcbind") }}} fixtext: '{{{ fixtext_package_removed("rpcbind") }}}' diff --git a/linux_os/guide/services/nfs_and_rpc/package_nfs-common_removed/rule.yml b/linux_os/guide/services/nfs_and_rpc/package_nfs-common_removed/rule.yml new file mode 100644 index 000000000000..e5063ba5e209 --- /dev/null +++ b/linux_os/guide/services/nfs_and_rpc/package_nfs-common_removed/rule.yml @@ -0,0 +1,22 @@ +documentation_complete: true + +title: 'Uninstall nfs-common Package' + +description: |- + {{{ describe_package_remove(package="nfs-common") }}} + +rationale: |- + If the system does not export NFS shares or act as an NFS client, it is + recommended that these services be removed to reduce the remote attack + surface. + +severity: low + +{{{ complete_ocil_entry_package_removed("nfs-common") }}} + +fixtext: '{{{ fixtext_package_removed("nfs-common") }}}' + +template: + name: package_removed + vars: + pkgname: nfs-common diff --git a/linux_os/guide/services/nfs_and_rpc/package_nfs-kernel-server_removed/rule.yml b/linux_os/guide/services/nfs_and_rpc/package_nfs-kernel-server_removed/rule.yml index aec94da56d3b..a620b4492284 100644 --- a/linux_os/guide/services/nfs_and_rpc/package_nfs-kernel-server_removed/rule.yml +++ b/linux_os/guide/services/nfs_and_rpc/package_nfs-kernel-server_removed/rule.yml @@ -12,7 +12,7 @@ rationale: |- severity: low -{{{ complete_ocil_entry_package(package="nfs-kernel-server") }}} +{{{ complete_ocil_entry_package_removed("nfs-kernel-server") }}} fixtext: '{{{ fixtext_package_removed("nfs-kernel-server") }}}' diff --git a/linux_os/guide/services/nfs_and_rpc/package_nfs-utils_removed/rule.yml b/linux_os/guide/services/nfs_and_rpc/package_nfs-utils_removed/rule.yml index 16bace74c76a..d53f4c4838c8 100644 --- a/linux_os/guide/services/nfs_and_rpc/package_nfs-utils_removed/rule.yml +++ b/linux_os/guide/services/nfs_and_rpc/package_nfs-utils_removed/rule.yml @@ -28,7 +28,7 @@ references: cis@sle15: 2.2.7 srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="nfs-utils") }}} +{{{ complete_ocil_entry_package_removed("nfs-utils") }}} fixtext: '{{{ fixtext_package_removed("nfs-utils") }}}' diff --git a/linux_os/guide/services/ntp/chrony_set_nts/rule.yml b/linux_os/guide/services/ntp/chrony_set_nts/rule.yml index 2f81cc7825b8..12e31cd21a52 100644 --- a/linux_os/guide/services/ntp/chrony_set_nts/rule.yml +++ b/linux_os/guide/services/ntp/chrony_set_nts/rule.yml @@ -25,3 +25,10 @@ severity: medium platforms: - package[chrony] + +warnings: + - general: |- + Network Time Security (NTS) is not compatible with systems running in FIPS mode. + Enabling NTS on a system in FIPS mode causes chronyd service to abort with a fatal + error. This is because NTS uses algorithms (specifically SIV cipher) that are not + approved by NIST and are not compliant with FIPS. diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/ansible/rhel8.yml b/linux_os/guide/services/ntp/chronyd_configure_local_socket/ansible/rhel8.yml new file mode 100644 index 000000000000..c2ce355b865a --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/ansible/rhel8.yml @@ -0,0 +1,46 @@ +# platform = Oracle Linux 8,Red Hat Enterprise Linux 8 +# reboot = false +# strategy = restrict +# complexity = low +# disruption = low + +# Fix chrony-wait.service to use Unix socket instead of network socket +# RHEL 8 version without additional hardening (KCS 7064388) +- name: "{{{ rule_title }}} - Check if chrony-wait.service exists" + ansible.builtin.stat: + path: /usr/lib/systemd/system/chrony-wait.service + register: chrony_wait_service + +- name: "{{{ rule_title }}} - Replace chrony-wait.service to use Unix socket (KCS 7064388)" + ansible.builtin.copy: + dest: /etc/systemd/system/chrony-wait.service + content: | + [Unit] + Description=Wait for chrony to synchronize system clock(KCS 7064388) + Documentation=man:chronyc(1) + After=chronyd.service + Requires=chronyd.service + Before=time-sync.target + Wants=time-sync.target + + [Service] + Type=oneshot + # Wait for chronyd to update the clock and the remaining + # correction to be less than 0.1 seconds + ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1 + # Wait for at most 3 minutes + TimeoutStartSec=180 + RemainAfterExit=yes + StandardOutput=null + + [Install] + WantedBy=multi-user.target + mode: '0644' + when: chrony_wait_service.stat.exists + +- name: "{{{ rule_title }}} - Reload systemd daemon and enable chrony-wait.service" + ansible.builtin.systemd: + name: chrony-wait.service + daemon_reload: yes + enabled: yes + when: chrony_wait_service.stat.exists diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/ansible/rhel9.yml b/linux_os/guide/services/ntp/chronyd_configure_local_socket/ansible/rhel9.yml new file mode 100644 index 000000000000..f7b41fc83cb2 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/ansible/rhel9.yml @@ -0,0 +1,76 @@ +# platform = Oracle Linux 9,Red Hat Enterprise Linux 9,Red Hat Enterprise Linux 10,multi_platform_almalinux,multi_platform_fedora +# reboot = false +# strategy = restrict +# complexity = low +# disruption = low + +# Fix chrony-wait.service to use Unix socket instead of network socket +# RHEL 9+ version with hardening directives (KCS 7064388) +- name: "{{{ rule_title }}} - Check if chrony-wait.service exists" + ansible.builtin.stat: + path: /usr/lib/systemd/system/chrony-wait.service + register: chrony_wait_service + +- name: "{{{ rule_title }}} - Replace chrony-wait.service to use Unix socket (KCS 7064388)" + ansible.builtin.copy: + dest: /etc/systemd/system/chrony-wait.service + content: | + [Unit] + Description=Wait for chrony to synchronize system clock(KCS 7064388) + Documentation=man:chronyc(1) + After=chronyd.service + Requires=chronyd.service + Before=time-sync.target + Wants=time-sync.target + + [Service] + Type=oneshot + # Wait for chronyd to update the clock and the remaining + # correction to be less than 0.1 seconds + ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1 + # Wait for at most 3 minutes + TimeoutStartSec=180 + RemainAfterExit=yes + StandardOutput=null + + CapabilityBoundingSet=~CAP_AUDIT_CONTROL CAP_AUDIT_READ CAP_AUDIT_WRITE + CapabilityBoundingSet=~CAP_BLOCK_SUSPEND CAP_KILL CAP_LEASE CAP_LINUX_IMMUTABLE + CapabilityBoundingSet=~CAP_MAC_ADMIN CAP_MAC_OVERRIDE CAP_MKNOD CAP_SYS_ADMIN + CapabilityBoundingSet=~CAP_SYS_BOOT CAP_SYS_CHROOT CAP_SYS_MODULE CAP_SYS_PACCT + CapabilityBoundingSet=~CAP_SYS_PTRACE CAP_SYS_RAWIO CAP_SYS_TTY_CONFIG CAP_WAKE_ALARM + DevicePolicy=closed + #DynamicUser=yes + IPAddressAllow=localhost + IPAddressDeny=any + LockPersonality=yes + MemoryDenyWriteExecute=yes + PrivateDevices=yes + ProcSubset=pid + ProtectClock=yes + ProtectControlGroups=yes + ProtectHome=yes + ProtectHostname=yes + ProtectKernelLogs=yes + ProtectKernelModules=yes + ProtectKernelTunables=yes + ProtectProc=invisible + ProtectSystem=strict + RestrictAddressFamilies=AF_UNIX + RestrictNamespaces=yes + RestrictRealtime=yes + SystemCallArchitectures=native + SystemCallFilter=@system-service + SystemCallFilter=~@privileged @resources + UMask=0777 + + [Install] + WantedBy=multi-user.target + mode: '0644' + when: chrony_wait_service.stat.exists + +- name: "{{{ rule_title }}} - Reload systemd daemon and enable chrony-wait.service" + ansible.builtin.systemd: + name: chrony-wait.service + daemon_reload: yes + enabled: yes + when: chrony_wait_service.stat.exists diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/bash/rhel8.sh b/linux_os/guide/services/ntp/chronyd_configure_local_socket/bash/rhel8.sh new file mode 100644 index 000000000000..da92a724c63b --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/bash/rhel8.sh @@ -0,0 +1,31 @@ +# platform = Oracle Linux 8,Red Hat Enterprise Linux 8 + +# Fix chrony-wait.service to use Unix socket instead of network socket +# The default service uses -h 127.0.0.1,::1 which fails when cmdport is 0 +# RHEL 8 version without additional hardening (KCS 7064388) +if systemctl list-unit-files chrony-wait.service >/dev/null 2>&1; then + cat > /etc/systemd/system/chrony-wait.service << 'EOF' +[Unit] +Description=Wait for chrony to synchronize system clock(KCS 7064388) +Documentation=man:chronyc(1) +After=chronyd.service +Requires=chronyd.service +Before=time-sync.target +Wants=time-sync.target + +[Service] +Type=oneshot +# Wait for chronyd to update the clock and the remaining +# correction to be less than 0.1 seconds +ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1 +# Wait for at most 3 minutes +TimeoutStartSec=180 +RemainAfterExit=yes +StandardOutput=null + +[Install] +WantedBy=multi-user.target +EOF + systemctl daemon-reload + systemctl enable chrony-wait.service +fi diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/bash/rhel9.sh b/linux_os/guide/services/ntp/chronyd_configure_local_socket/bash/rhel9.sh new file mode 100644 index 000000000000..b7fe5fb9dad2 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/bash/rhel9.sh @@ -0,0 +1,61 @@ +# platform = Oracle Linux 9,Red Hat Enterprise Linux 9,Red Hat Enterprise Linux 10,multi_platform_almalinux,multi_platform_fedora + +# Fix chrony-wait.service to use Unix socket instead of network socket +# The default service uses -h 127.0.0.1,::1 which fails when cmdport is 0 +# RHEL 9+ version with hardening directives (KCS 7064388) +if systemctl list-unit-files chrony-wait.service >/dev/null 2>&1; then + cat > /etc/systemd/system/chrony-wait.service << 'EOF' +[Unit] +Description=Wait for chrony to synchronize system clock(KCS 7064388) +Documentation=man:chronyc(1) +After=chronyd.service +Requires=chronyd.service +Before=time-sync.target +Wants=time-sync.target + +[Service] +Type=oneshot +# Wait for chronyd to update the clock and the remaining +# correction to be less than 0.1 seconds +ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1 +# Wait for at most 3 minutes +TimeoutStartSec=180 +RemainAfterExit=yes +StandardOutput=null + +CapabilityBoundingSet=~CAP_AUDIT_CONTROL CAP_AUDIT_READ CAP_AUDIT_WRITE +CapabilityBoundingSet=~CAP_BLOCK_SUSPEND CAP_KILL CAP_LEASE CAP_LINUX_IMMUTABLE +CapabilityBoundingSet=~CAP_MAC_ADMIN CAP_MAC_OVERRIDE CAP_MKNOD CAP_SYS_ADMIN +CapabilityBoundingSet=~CAP_SYS_BOOT CAP_SYS_CHROOT CAP_SYS_MODULE CAP_SYS_PACCT +CapabilityBoundingSet=~CAP_SYS_PTRACE CAP_SYS_RAWIO CAP_SYS_TTY_CONFIG CAP_WAKE_ALARM +DevicePolicy=closed +#DynamicUser=yes +IPAddressAllow=localhost +IPAddressDeny=any +LockPersonality=yes +MemoryDenyWriteExecute=yes +PrivateDevices=yes +ProcSubset=pid +ProtectClock=yes +ProtectControlGroups=yes +ProtectHome=yes +ProtectHostname=yes +ProtectKernelLogs=yes +ProtectKernelModules=yes +ProtectKernelTunables=yes +ProtectProc=invisible +ProtectSystem=strict +RestrictAddressFamilies=AF_UNIX +RestrictNamespaces=yes +RestrictRealtime=yes +SystemCallArchitectures=native +SystemCallFilter=@system-service +SystemCallFilter=~@privileged @resources +UMask=0777 + +[Install] +WantedBy=multi-user.target +EOF + systemctl daemon-reload + systemctl enable chrony-wait.service +fi diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/kubernetes/shared.yml b/linux_os/guide/services/ntp/chronyd_configure_local_socket/kubernetes/shared.yml new file mode 100644 index 000000000000..9229c32ff020 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/kubernetes/shared.yml @@ -0,0 +1,39 @@ +# platform = multi_platform_fedora,multi_platform_rhel,multi_platform_rhcos +# reboot = true +# strategy = restrict +# complexity = low +# disruption = low +--- +apiVersion: machineconfiguration.openshift.io/v1 +kind: MachineConfig +metadata: + annotations: + complianceascode.io/ocp-version: '<4.13.0' +spec: + config: + ignition: + version: 3.1.0 + storage: + files: + - contents: + source: data:,%5BUnit%5D%0ADescription%3DWait%20for%20chrony%20to%20synchronize%20system%20clock%20%28KCS%207064388%29%0ADocumentation%3Dman%3Achronyc%281%29%0AAfter%3Dchronyd.service%0ARequires%3Dchronyd.service%0ABefore%3Dtime-sync.target%0AWants%3Dtime-sync.target%0A%0A%5BService%5D%0AType%3Doneshot%0AExecStart%3D%2Fusr%2Fbin%2Fchronyc%20waitsync%200%200.1%200.0%201%0ATimeoutStartSec%3D180%0ARemainAfterExit%3Dyes%0AStandardOutput%3Dnull%0A%0A%5BInstall%5D%0AWantedBy%3Dmulti-user.target%0A + mode: 420 + overwrite: true + path: /etc/systemd/system/chrony-wait.service +--- +apiVersion: machineconfiguration.openshift.io/v1 +kind: MachineConfig +metadata: + annotations: + complianceascode.io/ocp-version: '>=4.13.0' +spec: + config: + ignition: + version: 3.1.0 + storage: + files: + - contents: + source: data:,%5BUnit%5D%0ADescription%3DWait%20for%20chrony%20to%20synchronize%20system%20clock%20%28KCS%207064388%29%0ADocumentation%3Dman%3Achronyc%281%29%0AAfter%3Dchronyd.service%0ARequires%3Dchronyd.service%0ABefore%3Dtime-sync.target%0AWants%3Dtime-sync.target%0A%0A%5BService%5D%0AType%3Doneshot%0AExecStart%3D%2Fusr%2Fbin%2Fchronyc%20waitsync%200%200.1%200.0%201%0ATimeoutStartSec%3D180%0ARemainAfterExit%3Dyes%0AStandardOutput%3Dnull%0A%0ACapabilityBoundingSet%3D~CAP_AUDIT_CONTROL%20CAP_AUDIT_READ%20CAP_AUDIT_WRITE%0ACapabilityBoundingSet%3D~CAP_BLOCK_SUSPEND%20CAP_KILL%20CAP_LEASE%20CAP_LINUX_IMMUTABLE%0ACapabilityBoundingSet%3D~CAP_MAC_ADMIN%20CAP_MAC_OVERRIDE%20CAP_MKNOD%20CAP_SYS_ADMIN%0ACapabilityBoundingSet%3D~CAP_SYS_BOOT%20CAP_SYS_CHROOT%20CAP_SYS_MODULE%20CAP_SYS_PACCT%0ACapabilityBoundingSet%3D~CAP_SYS_PTRACE%20CAP_SYS_RAWIO%20CAP_SYS_TTY_CONFIG%20CAP_WAKE_ALARM%0ADevicePolicy%3Dclosed%0AIPAddressAllow%3Dlocalhost%0AIPAddressDeny%3Dany%0ALockPersonality%3Dyes%0AMemoryDenyWriteExecute%3Dyes%0APrivateDevices%3Dyes%0AProcSubset%3Dpid%0AProtectClock%3Dyes%0AProtectControlGroups%3Dyes%0AProtectHome%3Dyes%0AProtectHostname%3Dyes%0AProtectKernelLogs%3Dyes%0AProtectKernelModules%3Dyes%0AProtectKernelTunables%3Dyes%0AProtectProc%3Dinvisible%0AProtectSystem%3Dstrict%0ARestrictAddressFamilies%3DAF_UNIX%0ARestrictNamespaces%3Dyes%0ARestrictRealtime%3Dyes%0ASystemCallArchitectures%3Dnative%0ASystemCallFilter%3D%40system-service%0ASystemCallFilter%3D~%40privileged%20%40resources%0AUMask%3D0777%0A%0A%5BInstall%5D%0AWantedBy%3Dmulti-user.target%0A + mode: 420 + overwrite: true + path: /etc/systemd/system/chrony-wait.service diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/oval/shared.xml b/linux_os/guide/services/ntp/chronyd_configure_local_socket/oval/shared.xml new file mode 100644 index 000000000000..d3d8e02c1b08 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/oval/shared.xml @@ -0,0 +1,37 @@ + + + {{{ oval_metadata("Ensure chrony-wait.service is configured to use Unix socket + instead of network addresses.", rule_title=rule_title) }}} + + + + + + + + + + + + /usr/lib/systemd/system/chrony-wait.service + + + + + + + + + /etc/systemd/system/chrony-wait.service + ^ExecStart=(.*)$ + 1 + + + + ^/usr/bin/chronyc\s+waitsync\s+\d+\s+[\d.]+\s+[\d.]+\s+\d+\s*$ + + diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/rule.yml b/linux_os/guide/services/ntp/chronyd_configure_local_socket/rule.yml new file mode 100644 index 000000000000..502cd18e8b3d --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/rule.yml @@ -0,0 +1,44 @@ +documentation_complete: true + + +title: 'Configure chrony-wait.service to use Unix socket' + +description: |- + The default chrony-wait.service attempts to connect via network (127.0.0.1, ::1) + which fails when cmdport is set to 0. The service unit must be replaced + to use chronyc without network address specification, allowing it to use the Unix socket + for local communication with chronyd. + +rationale: |- + When network access to the chrony daemon command port is disabled for security hardening, + the chrony-wait.service must be configured to use the Unix domain socket instead of + network addresses. This ensures the service can still check chrony synchronization status + without requiring network command access. + +severity: low + +platform: package[chrony] + +identifiers: + cce@rhel8: CCE-86482-7 + cce@rhel9: CCE-86468-6 + +references: + nist: CM-7(1) + srg: SRG-OS-000096-GPOS-00050,SRG-OS-000095-GPOS-00049 + +ocil_clause: 'chrony-wait.service uses network addresses' + +ocil: |- + Verify {{{ full_name }}} configures chrony-wait.service to use Unix socket with the following command: +
$ systemctl cat chrony-wait.service | grep ExecStart
+
ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1
+ + The ExecStart line should not contain -h 127.0.0.1,::1 or similar network address specifications. + +fixtext: |- + Configure {{{ full_name }}} chrony-wait.service to use Unix socket by creating /etc/systemd/system/chrony-wait.service + without network address specifications in the ExecStart command. + +srg_requirement: + {{{ full_name }}} chrony-wait.service must use Unix socket for local access when network command access is disabled. diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/cmdport_zero.fail.sh b/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/cmdport_zero.fail.sh new file mode 100644 index 000000000000..7e2f35b8b1b0 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/cmdport_zero.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# packages = chrony +# + +systemctl enable chronyd.service + +echo "cmdport 0" >> /etc/chrony.conf diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/service_fixed_rhel8.pass.sh b/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/service_fixed_rhel8.pass.sh new file mode 100644 index 000000000000..2360509fe08b --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/service_fixed_rhel8.pass.sh @@ -0,0 +1,32 @@ +#!/bin/bash +# platform = Oracle Linux 8,Red Hat Enterprise Linux 8 +# packages = chrony +# + +systemctl enable chronyd.service + +echo "cmdport 0" >> /etc/chrony.conf + +# Create the fixed chrony-wait.service override (RHEL 8 version - no hardening) +cat > /etc/systemd/system/chrony-wait.service << 'EOF' +[Unit] +Description=Wait for chrony to synchronize system clock(KCS 7064388) +Documentation=man:chronyc(1) +After=chronyd.service +Requires=chronyd.service +Before=time-sync.target +Wants=time-sync.target + +[Service] +Type=oneshot +# Wait for chronyd to update the clock and the remaining +# correction to be less than 0.1 seconds +ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1 +# Wait for at most 3 minutes +TimeoutStartSec=180 +RemainAfterExit=yes +StandardOutput=null + +[Install] +WantedBy=multi-user.target +EOF diff --git a/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/service_fixed_rhel9.pass.sh b/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/service_fixed_rhel9.pass.sh new file mode 100644 index 000000000000..7eb3245d96a5 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_configure_local_socket/tests/service_fixed_rhel9.pass.sh @@ -0,0 +1,62 @@ +#!/bin/bash +# platform = Oracle Linux 9,Red Hat Enterprise Linux 9,Red Hat Enterprise Linux 10,multi_platform_almalinux,multi_platform_fedora +# packages = chrony +# + +systemctl enable chronyd.service + +echo "cmdport 0" >> /etc/chrony.conf + +# Create the fixed chrony-wait.service override (RHEL 9+ version - with hardening) +cat > /etc/systemd/system/chrony-wait.service << 'EOF' +[Unit] +Description=Wait for chrony to synchronize system clock(KCS 7064388) +Documentation=man:chronyc(1) +After=chronyd.service +Requires=chronyd.service +Before=time-sync.target +Wants=time-sync.target + +[Service] +Type=oneshot +# Wait for chronyd to update the clock and the remaining +# correction to be less than 0.1 seconds +ExecStart=/usr/bin/chronyc waitsync 0 0.1 0.0 1 +# Wait for at most 3 minutes +TimeoutStartSec=180 +RemainAfterExit=yes +StandardOutput=null + +CapabilityBoundingSet=~CAP_AUDIT_CONTROL CAP_AUDIT_READ CAP_AUDIT_WRITE +CapabilityBoundingSet=~CAP_BLOCK_SUSPEND CAP_KILL CAP_LEASE CAP_LINUX_IMMUTABLE +CapabilityBoundingSet=~CAP_MAC_ADMIN CAP_MAC_OVERRIDE CAP_MKNOD CAP_SYS_ADMIN +CapabilityBoundingSet=~CAP_SYS_BOOT CAP_SYS_CHROOT CAP_SYS_MODULE CAP_SYS_PACCT +CapabilityBoundingSet=~CAP_SYS_PTRACE CAP_SYS_RAWIO CAP_SYS_TTY_CONFIG CAP_WAKE_ALARM +DevicePolicy=closed +#DynamicUser=yes +IPAddressAllow=localhost +IPAddressDeny=any +LockPersonality=yes +MemoryDenyWriteExecute=yes +PrivateDevices=yes +ProcSubset=pid +ProtectClock=yes +ProtectControlGroups=yes +ProtectHome=yes +ProtectHostname=yes +ProtectKernelLogs=yes +ProtectKernelModules=yes +ProtectKernelTunables=yes +ProtectProc=invisible +ProtectSystem=strict +RestrictAddressFamilies=AF_UNIX +RestrictNamespaces=yes +RestrictRealtime=yes +SystemCallArchitectures=native +SystemCallFilter=@system-service +SystemCallFilter=~@privileged @resources +UMask=0777 + +[Install] +WantedBy=multi-user.target +EOF diff --git a/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/bash/shared.sh b/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/bash/shared.sh index b4a1687cde49..144cf95c553a 100644 --- a/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/bash/shared.sh +++ b/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/bash/shared.sh @@ -5,6 +5,8 @@ config_file="{{{ chrony_conf_path }}}" +sed -i -e '$a\' "$config_file" + # Check and configigure servers in {{{ chrony_conf_path }}} IFS="," read -a SERVERS <<< $var_multiple_time_servers for srv in "${SERVERS[@]}" diff --git a/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/rule.yml b/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/rule.yml index 28c845c74a92..c58abf32c154 100644 --- a/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/rule.yml +++ b/linux_os/guide/services/ntp/chronyd_configure_pool_and_server/rule.yml @@ -25,6 +25,7 @@ identifiers: cce@rhel10: CCE-89285-1 cce@sle12: CCE-92394-6 cce@sle15: CCE-92526-3 + cce@sle16: CCE-96189-6 cce@slmicro5: CCE-93908-2 references: diff --git a/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/ansible/shared.yml b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/ansible/shared.yml index 2c58ce0366de..c273fd3fab2d 100644 --- a/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/ansible/shared.yml +++ b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/ansible/shared.yml @@ -48,25 +48,31 @@ replace: '\1 maxpoll {{ var_time_service_set_maxpoll }}\n' when: chrony_conf_exist_result.stat.exists +- name: "{{{ rule_title }}} - Check That {{{ chrony_d_path }}} Exist" + ansible.builtin.stat: + path: "{{{ chrony_d_path }}}" + register: chrony_d_path_exists + - name: "{{{ rule_title }}} - Get Conf Files from {{{ chrony_d_path }}}" ansible.builtin.find: path: "{{{ chrony_d_path }}}" patterns: '*.conf' file_type: file register: chrony_d_conf_files + when: chrony_d_path_exists.stat.exists and chrony_d_path_exists.stat.isdir - name: "{{{ rule_title }}} - Update the maxpoll Values in {{{ chrony_d_path }}}" ansible.builtin.replace: path: "{{ item.path }}" regexp: '^((?:server|pool|peer).*maxpoll)[ ]+[0-9,-]+(.*)$' replace: '\1 {{ var_time_service_set_maxpoll }}\2' - loop: '{{ chrony_d_conf_files.files }}' - when: chrony_d_conf_files.matched + loop: '{{ chrony_d_conf_files.files | default([]) }}' + when: chrony_d_conf_files is defined and chrony_d_conf_files.matched - name: "{{{ rule_title }}} - Set the maxpoll Values in {{{ chrony_d_path }}}" ansible.builtin.replace: path: "{{ item.path }}" regexp: '(^(?:server|pool|peer)\s+((?!maxpoll).)*)$' replace: '\1 maxpoll {{ var_time_service_set_maxpoll }}\n' - loop: '{{ chrony_d_conf_files.files }}' - when: chrony_d_conf_files.matched + loop: '{{ chrony_d_conf_files.files | default([]) }}' + when: chrony_d_conf_files is defined and chrony_d_conf_files.matched diff --git a/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/bash/shared.sh b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/bash/shared.sh index f1a3703adbfa..81bf9717049e 100644 --- a/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/bash/shared.sh +++ b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/bash/shared.sh @@ -12,11 +12,11 @@ pof="/usr/sbin/pidof" CONFIG_FILES="/etc/ntp.conf" $pof ntpd || { CHRONY_D_PATH={{{ chrony_d_path }}} - {{% if 'slmicro' in product %}} - mapfile -t CONFIG_FILES < <(find ${CHRONY_D_PATH} -type f -name '*.conf') - {{% else %}} - mapfile -t CONFIG_FILES < <(find ${CHRONY_D_PATH}.* -type f -name '*.conf') - {{% endif %}} + if [ -d "${CHRONY_D_PATH}" ]; then + mapfile -t CONFIG_FILES < <(find ${CHRONY_D_PATH} -type f -name '*.conf') + else + CONFIG_FILES=() + fi CONFIG_FILES+=({{{ chrony_conf_path }}}) } diff --git a/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/tests/chrony_d_missing_main_conf_configured.pass.sh b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/tests/chrony_d_missing_main_conf_configured.pass.sh new file mode 100644 index 000000000000..54fa61e5f1c7 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/tests/chrony_d_missing_main_conf_configured.pass.sh @@ -0,0 +1,17 @@ +#!/bin/bash +# packages = chrony +# variables = var_time_service_set_maxpoll=16 +# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_sle + +{{{ bash_package_remove("ntp") }}} + +# Remove the /etc/chrony.d directory to simulate systems where it doesn't exist +# (e.g., ppc64le systems with chrony-dhcp in Testing Farm) +rm -rf {{{ chrony_d_path }}} + +# Configure maxpoll correctly in the main chrony.conf file +sed -i "/^\(server\|pool\).*/d" {{{ chrony_conf_path }}} +echo "pool pool.ntp.org iburst maxpoll 16" >> {{{ chrony_conf_path }}} +echo "server time.nist.gov maxpoll 16" >> {{{ chrony_conf_path }}} + +systemctl enable chronyd.service diff --git a/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/tests/chrony_d_missing_main_conf_misconfigured.fail.sh b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/tests/chrony_d_missing_main_conf_misconfigured.fail.sh new file mode 100644 index 000000000000..b6fdcb619b65 --- /dev/null +++ b/linux_os/guide/services/ntp/chronyd_or_ntpd_set_maxpoll/tests/chrony_d_missing_main_conf_misconfigured.fail.sh @@ -0,0 +1,17 @@ +#!/bin/bash +# packages = chrony +# variables = var_time_service_set_maxpoll=16 +# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_sle + +{{{ bash_package_remove("ntp") }}} + +# Remove the /etc/chrony.d directory to simulate systems where it doesn't exist +# (e.g., ppc64le systems with chrony-dhcp in Testing Farm) +rm -rf {{{ chrony_d_path }}} + +# Configure maxpoll incorrectly in the main chrony.conf file +sed -i "/^\(server\|pool\).*/d" {{{ chrony_conf_path }}} +echo "pool pool.ntp.org iburst maxpoll 18" >> {{{ chrony_conf_path }}} +echo "server time.nist.gov maxpoll 20" >> {{{ chrony_conf_path }}} + +systemctl enable chronyd.service diff --git a/linux_os/guide/services/ntp/file_owner_etc_chrony_keys/rule.yml b/linux_os/guide/services/ntp/file_owner_etc_chrony_keys/rule.yml index 683af7223c1f..6fb1a9fea13f 100644 --- a/linux_os/guide/services/ntp/file_owner_etc_chrony_keys/rule.yml +++ b/linux_os/guide/services/ntp/file_owner_etc_chrony_keys/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86379-5 cce@rhel9: CCE-86380-3 cce@rhel10: CCE-88848-7 + cce@sle16: CCE-96618-4 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/chrony.keys", owner="root") }}}' diff --git a/linux_os/guide/services/ntp/file_permissions_etc_chrony_keys/rule.yml b/linux_os/guide/services/ntp/file_permissions_etc_chrony_keys/rule.yml index 94d5ed71807b..01c82c5f51a1 100644 --- a/linux_os/guide/services/ntp/file_permissions_etc_chrony_keys/rule.yml +++ b/linux_os/guide/services/ntp/file_permissions_etc_chrony_keys/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86383-7 cce@rhel9: CCE-86384-5 cce@rhel10: CCE-88155-7 + cce@sle16: CCE-96085-6 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/chrony.keys", perms="0640") }}}' diff --git a/linux_os/guide/services/ntp/package_chrony_installed/rule.yml b/linux_os/guide/services/ntp/package_chrony_installed/rule.yml index 6359e23c76f3..4de2268e8a6c 100644 --- a/linux_os/guide/services/ntp/package_chrony_installed/rule.yml +++ b/linux_os/guide/services/ntp/package_chrony_installed/rule.yml @@ -16,6 +16,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-90536-4 cce@rhel8: CCE-82874-9 cce@rhel9: CCE-84215-3 cce@rhel10: CCE-89591-2 @@ -31,9 +32,7 @@ references: pcidss: Req-10.4 srg: SRG-OS-000355-GPOS-00143 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="chrony") }}}' +{{{ complete_ocil_entry_package_installed("chrony") }}} fixtext: '{{{ describe_package_install(package="chrony") }}}' diff --git a/linux_os/guide/services/ntp/package_ntp_installed/rule.yml b/linux_os/guide/services/ntp/package_ntp_installed/rule.yml index 697bcafe47e0..54a64c9680ae 100644 --- a/linux_os/guide/services/ntp/package_ntp_installed/rule.yml +++ b/linux_os/guide/services/ntp/package_ntp_installed/rule.yml @@ -1,3 +1,8 @@ +{{% if product == "debian13" %}} + {{%- set package = "ntpsec" %}} +{{% else %}} + {{%- set package = "ntp" %}} +{{% endif %}} documentation_complete: true title: 'Install the ntp service' @@ -22,15 +27,8 @@ references: nist-csf: PR.PT-1 pcidss: Req-10.4 -ocil_clause: 'the package is not installed' +{{{ complete_ocil_entry_package_installed(package=package) }}} -ocil: |- - {{% if product == "debian13" %}} - {{{ ocil_package(package="ntpsec") }}} - {{% else %}} - {{{ ocil_package(package="ntp") }}} - {{% endif %}} - template: name: package_installed vars: diff --git a/linux_os/guide/services/ntp/service_chronyd_enabled/rule.yml b/linux_os/guide/services/ntp/service_chronyd_enabled/rule.yml index 754b1bf3d189..af8540441c24 100644 --- a/linux_os/guide/services/ntp/service_chronyd_enabled/rule.yml +++ b/linux_os/guide/services/ntp/service_chronyd_enabled/rule.yml @@ -25,6 +25,7 @@ identifiers: cce@rhel9: CCE-84217-9 cce@rhel10: CCE-90511-7 cce@sle15: CCE-92601-4 + cce@sle16: CCE-96684-6 references: srg: SRG-OS-000355-GPOS-00143 diff --git a/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_installed/rule.yml b/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_installed/rule.yml index dd8afdb34f44..e95155e21f3b 100644 --- a/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_installed/rule.yml +++ b/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_installed/rule.yml @@ -26,9 +26,7 @@ references: nist-csf: PR.IP-1 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="tcp_wrappers") }}}' +{{{ complete_ocil_entry_package_installed("tcp_wrappers") }}} template: name: package_installed diff --git a/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_removed/rule.yml b/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_removed/rule.yml index ee0f1c513e9c..111b88262f64 100644 --- a/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_removed/rule.yml +++ b/linux_os/guide/services/obsolete/inetd_and_xinetd/package_tcp_wrappers_removed/rule.yml @@ -38,7 +38,7 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.AC-3,PR.IP-1,PR.PT-3,PR.PT-4 -{{{ complete_ocil_entry_package(package="tcpd") }}} +{{{ complete_ocil_entry_package_removed("tcpd") }}} fixtext: '{{{ fixtext_package_removed("tcpd") }}}' diff --git a/linux_os/guide/services/obsolete/inetd_and_xinetd/package_xinetd_removed/rule.yml b/linux_os/guide/services/obsolete/inetd_and_xinetd/package_xinetd_removed/rule.yml index c1e0d7193f3e..413af2a83202 100644 --- a/linux_os/guide/services/obsolete/inetd_and_xinetd/package_xinetd_removed/rule.yml +++ b/linux_os/guide/services/obsolete/inetd_and_xinetd/package_xinetd_removed/rule.yml @@ -1,7 +1,7 @@ documentation_complete: true -title: 'Uninstall xinetd Package' +title: 'Uninstall xinetd package if not used by network services' description: |- {{{ describe_package_remove(package="xinetd") }}} @@ -32,18 +32,17 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.AC-3,PR.IP-1,PR.PT-3,PR.PT-4 -ocil: |- - If network services are using the xinetd service, this is not applicable. -

- {{{ complete_ocil_entry_package(package="xinetd") }}} +ocil_clause: "the xinetd package is installed and the network services are not using the xinetd service" -template: - name: package_removed - vars: - pkgname: xinetd +{{{ ocil_package_installed_how_to_check(package="xinetd") }}} {{% if product in ["rhel9"] %}} warnings: - general: The package is not available in {{{ full_name }}}. {{% endif %}} + +template: + name: package_removed + vars: + pkgname: xinetd diff --git a/linux_os/guide/services/obsolete/nis/package_ypserv_removed/rule.yml b/linux_os/guide/services/obsolete/nis/package_ypserv_removed/rule.yml index ab37fab3c561..95515f503b52 100644 --- a/linux_os/guide/services/obsolete/nis/package_ypserv_removed/rule.yml +++ b/linux_os/guide/services/obsolete/nis/package_ypserv_removed/rule.yml @@ -39,7 +39,7 @@ references: srg: SRG-OS-000095-GPOS-00049 stigid@ol7: OL07-00-020010 -{{{ complete_ocil_entry_package(package="ypserv") }}} +{{{ complete_ocil_entry_package_removed("ypserv") }}} template: name: package_removed diff --git a/linux_os/guide/services/obsolete/package_rsync_removed/rule.yml b/linux_os/guide/services/obsolete/package_rsync_removed/rule.yml index d499c08c9f5d..34e6d77272d8 100644 --- a/linux_os/guide/services/obsolete/package_rsync_removed/rule.yml +++ b/linux_os/guide/services/obsolete/package_rsync_removed/rule.yml @@ -1,4 +1,4 @@ -{{% if 'rhel' in product or product in ['ol8','ol9'] -%}} +{{% if 'rhel' in product or product in ['ol8','ol9', 'hummingbird'] -%}} {{% set pkg='rsync-daemon' %}} {{% else %}} {{% set pkg='rsync' %}} @@ -30,7 +30,7 @@ references: cis@sle12: 2.2.17 cis@sle15: 2.2.17 -{{{ complete_ocil_entry_package(package=pkg) }}} +{{{ complete_ocil_entry_package_removed(pkg) }}} fixtext: '{{{ fixtext_package_removed(pkg) }}}' diff --git a/linux_os/guide/services/obsolete/r_services/no_host_based_files/hummingbird/shared.sh b/linux_os/guide/services/obsolete/r_services/no_host_based_files/hummingbird/shared.sh new file mode 100644 index 000000000000..12e3023bd371 --- /dev/null +++ b/linux_os/guide/services/obsolete/r_services/no_host_based_files/hummingbird/shared.sh @@ -0,0 +1,2 @@ +# platform = multi_platform_all +find "$NEWROOT" -type f -name "shosts.equiv" -exec rm -f {} \; diff --git a/linux_os/guide/services/obsolete/r_services/package_rsh-server_removed/rule.yml b/linux_os/guide/services/obsolete/r_services/package_rsh-server_removed/rule.yml index 925223e63275..9300b08dbdab 100644 --- a/linux_os/guide/services/obsolete/r_services/package_rsh-server_removed/rule.yml +++ b/linux_os/guide/services/obsolete/r_services/package_rsh-server_removed/rule.yml @@ -34,9 +34,8 @@ references: nist-csf: PR.AC-3,PR.IP-1,PR.PT-3,PR.PT-4 srg: SRG-OS-000095-GPOS-00049 stigid@ol7: OL07-00-020000 - stigid@ol8: OL08-00-040010 -{{{ complete_ocil_entry_package(package="rsh-server") }}} +{{{ complete_ocil_entry_package_removed("rsh-server") }}} template: name: package_removed diff --git a/linux_os/guide/services/obsolete/service_rsyncd_disabled/rule.yml b/linux_os/guide/services/obsolete/service_rsyncd_disabled/rule.yml index 1db77bb04a7a..d4ed1fb801e0 100644 --- a/linux_os/guide/services/obsolete/service_rsyncd_disabled/rule.yml +++ b/linux_os/guide/services/obsolete/service_rsyncd_disabled/rule.yml @@ -41,6 +41,7 @@ template: packagename@ol7: rsync packagename@sle12: rsync packagename@sle15: rsync + packagename@sle16: rsync packagename@slmicro5: rsync packagename@openeuler2203: rsync servicename@ubuntu2404: rsync diff --git a/linux_os/guide/services/obsolete/talk/package_talk-server_removed/rule.yml b/linux_os/guide/services/obsolete/talk/package_talk-server_removed/rule.yml index a820ba060e8e..2de29f76db34 100644 --- a/linux_os/guide/services/obsolete/talk/package_talk-server_removed/rule.yml +++ b/linux_os/guide/services/obsolete/talk/package_talk-server_removed/rule.yml @@ -22,7 +22,7 @@ identifiers: references: hipaa: 164.308(a)(4)(i),164.308(b)(1),164.308(b)(3),164.310(b),164.312(e)(1),164.312(e)(2)(ii) -{{{ complete_ocil_entry_package(package="talk-server") }}} +{{{ complete_ocil_entry_package_removed("talk-server") }}} template: name: package_removed diff --git a/linux_os/guide/services/obsolete/talk/package_talk_removed/rule.yml b/linux_os/guide/services/obsolete/talk/package_talk_removed/rule.yml index 3004f7fda063..550d0afd9c55 100644 --- a/linux_os/guide/services/obsolete/talk/package_talk_removed/rule.yml +++ b/linux_os/guide/services/obsolete/talk/package_talk_removed/rule.yml @@ -30,7 +30,7 @@ references: cis@sle15: 2.3.3 hipaa: 164.308(a)(4)(i),164.308(b)(1),164.308(b)(3),164.310(b),164.312(e)(1),164.312(e)(2)(ii) -{{{ complete_ocil_entry_package(package="talk") }}} +{{{ complete_ocil_entry_package_removed("talk") }}} template: name: package_removed diff --git a/linux_os/guide/services/obsolete/telnet/package_telnet-server_removed/rule.yml b/linux_os/guide/services/obsolete/telnet/package_telnet-server_removed/rule.yml index e511577a63de..e561d5b0e872 100644 --- a/linux_os/guide/services/obsolete/telnet/package_telnet-server_removed/rule.yml +++ b/linux_os/guide/services/obsolete/telnet/package_telnet-server_removed/rule.yml @@ -51,7 +51,7 @@ references: stigid@sle12: SLES-12-030000 stigid@sle15: SLES-15-010180 -{{{ complete_ocil_entry_package(package="telnet-server") }}} +{{{ complete_ocil_entry_package_removed("telnet-server") }}} srg_requirement: '{{{ srg_requirement_package_removed("telnet-server") }}}' diff --git a/linux_os/guide/services/obsolete/tftp/package_tftp-server_removed/rule.yml b/linux_os/guide/services/obsolete/tftp/package_tftp-server_removed/rule.yml index bba598123a34..1aa283f3983a 100644 --- a/linux_os/guide/services/obsolete/tftp/package_tftp-server_removed/rule.yml +++ b/linux_os/guide/services/obsolete/tftp/package_tftp-server_removed/rule.yml @@ -1,17 +1,19 @@ -documentation_complete: true - {{% if 'ubuntu' in product %}} -{{% set package_name = "tftpd-hpa" %}} + {{%- set package = "tftpd-hpa" %}} +{{% elif 'sle' in product %}} + {{%- set package = "tftp" %}} {{% else %}} -{{% set package_name = "tftp-server" %}} + {{%- set package = "tftp-server" %}} {{% endif %}} -title: 'Uninstall {{{ package_name }}} Package' +documentation_complete: true + +title: 'Uninstall {{{ package }}} Package' -description: '{{{ describe_package_remove(package=package_name) }}}' +description: '{{{ describe_package_remove(package=package) }}}' rationale: |- - Removing the {{{ package_name }}} package decreases the risk of the accidental + Removing the {{{ package }}} package decreases the risk of the accidental (or intentional) activation of tftp services.

If TFTP is required for operational support (such as transmission of router @@ -41,13 +43,13 @@ references: stigid@ol7: OL07-00-040700 stigid@ol8: OL08-00-040190 -{{{ complete_ocil_entry_package(package=package_name) }}} +{{{ complete_ocil_entry_package_removed(package=package) }}} -fixtext: '{{{ fixtext_package_removed(package_name) }}}' +fixtext: '{{{ fixtext_package_removed(package=package) }}}' srg_requirement: 'The Trivial File Transfer Protocol (TFTP) server package must not be installed if not required for {{{ full_name }}} operational support.' template: name: package_removed vars: - pkgname: {{{ package_name }}} + pkgname: {{{ package }}} diff --git a/linux_os/guide/services/obsolete/tftp/service_tftp_disabled/rule.yml b/linux_os/guide/services/obsolete/tftp/service_tftp_disabled/rule.yml index 2a5561109ba9..510779e396e9 100644 --- a/linux_os/guide/services/obsolete/tftp/service_tftp_disabled/rule.yml +++ b/linux_os/guide/services/obsolete/tftp/service_tftp_disabled/rule.yml @@ -1,11 +1,14 @@ documentation_complete: true {{% if 'ubuntu' in product %}} -{{% set service_name = "tftpd-hpa" %}} -{{% set package_name = "tftpd-hpa" %}} + {{%- set service_name = "tftpd-hpa" %}} + {{%- set package = "tftpd-hpa" %}} +{{% elif 'sle' in product or product == "slmicro5" %}} + {{%- set service_name = "tftp" %}} + {{%- set package = "tftp" %}} {{% else %}} -{{% set service_name = "tftp" %}} -{{% set package_name = "tftp-server" %}} + {{%- set service_name = "tftp" %}} + {{%- set package = "tftp-server" %}} {{% endif %}} title: 'Disable {{{ service_name }}} Service' @@ -46,4 +49,4 @@ template: name: service_disabled vars: servicename: {{{ service_name }}} - packagename: {{{ package_name }}} + packagename: {{{ package }}} diff --git a/linux_os/guide/services/printing/package_cups_removed/rule.yml b/linux_os/guide/services/printing/package_cups_removed/rule.yml index 8cfbd3135b55..4dea9847d3c3 100644 --- a/linux_os/guide/services/printing/package_cups_removed/rule.yml +++ b/linux_os/guide/services/printing/package_cups_removed/rule.yml @@ -31,7 +31,7 @@ references: nist: CM-7(a),CM-7(b),CM-6(a) nist-csf: PR.IP-1,PR.PT-3 -{{{ complete_ocil_entry_package(package="cups") }}} +{{{ complete_ocil_entry_package_removed("cups") }}} fixtext: '{{{ fixtext_package_removed("cups") }}}' diff --git a/linux_os/guide/services/printing/service_cups_disabled/rule.yml b/linux_os/guide/services/printing/service_cups_disabled/rule.yml index ee090ae2e682..9cf4f70a3d4a 100644 --- a/linux_os/guide/services/printing/service_cups_disabled/rule.yml +++ b/linux_os/guide/services/printing/service_cups_disabled/rule.yml @@ -11,6 +11,7 @@ rationale: 'Turn off unneeded services to reduce attack surface.' severity: unknown identifiers: + cce@rhcos4: CCE-86928-9 cce@rhel8: CCE-82861-6 cce@rhel9: CCE-90795-6 cce@rhel10: CCE-86174-0 diff --git a/linux_os/guide/services/proxy/disabling_squid/package_squid_removed/rule.yml b/linux_os/guide/services/proxy/disabling_squid/package_squid_removed/rule.yml index 8dd15db0821d..9f586ca6c42b 100644 --- a/linux_os/guide/services/proxy/disabling_squid/package_squid_removed/rule.yml +++ b/linux_os/guide/services/proxy/disabling_squid/package_squid_removed/rule.yml @@ -19,7 +19,7 @@ identifiers: cce@sle15: CCE-91372-3 cce@slmicro5: CCE-93895-1 -{{{ complete_ocil_entry_package(package="squid") }}} +{{{ complete_ocil_entry_package_removed("squid") }}} references: cis@sle12: 2.2.14 diff --git a/linux_os/guide/services/radius/package_freeradius_removed/rule.yml b/linux_os/guide/services/radius/package_freeradius_removed/rule.yml index 9e412ae8ac0a..474f26a809ed 100644 --- a/linux_os/guide/services/radius/package_freeradius_removed/rule.yml +++ b/linux_os/guide/services/radius/package_freeradius_removed/rule.yml @@ -22,9 +22,7 @@ severity: low identifiers: cce@rhel8: CCE-82752-7 -ocil_clause: 'the package is installed' - -ocil: '{{{ ocil_package(package="freeradius") }}}' +{{{ complete_ocil_entry_package_removed("freeradius") }}} template: name: package_removed diff --git a/linux_os/guide/services/routing/disabling_quagga/package_quagga_removed/rule.yml b/linux_os/guide/services/routing/disabling_quagga/package_quagga_removed/rule.yml index 028087f208cc..94b03f0c79d4 100644 --- a/linux_os/guide/services/routing/disabling_quagga/package_quagga_removed/rule.yml +++ b/linux_os/guide/services/routing/disabling_quagga/package_quagga_removed/rule.yml @@ -29,7 +29,7 @@ references: nist-csf: PR.PT-4 srg: SRG-OS-000480-GPOS-00227 -{{{ complete_ocil_entry_package(package="quagga") }}} +{{{ complete_ocil_entry_package_removed("quagga") }}} fixtext: '{{{ fixtext_package_removed("quagga") }}}' diff --git a/linux_os/guide/services/smb/configuring_samba/package_samba-common_installed/rule.yml b/linux_os/guide/services/smb/configuring_samba/package_samba-common_installed/rule.yml index 7a62905135ab..38848e9ac1f7 100644 --- a/linux_os/guide/services/smb/configuring_samba/package_samba-common_installed/rule.yml +++ b/linux_os/guide/services/smb/configuring_samba/package_samba-common_installed/rule.yml @@ -11,9 +11,7 @@ rationale: 'If the samba-common package is not installed, samba cannot be config severity: medium -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="samba-common") }}}' +{{{ complete_ocil_entry_package_installed("samba-common") }}} template: name: package_installed diff --git a/linux_os/guide/services/smb/disabling_samba/package_samba_removed/rule.yml b/linux_os/guide/services/smb/disabling_samba/package_samba_removed/rule.yml index de76ade2bf81..79cd28d84c97 100644 --- a/linux_os/guide/services/smb/disabling_samba/package_samba_removed/rule.yml +++ b/linux_os/guide/services/smb/disabling_samba/package_samba_removed/rule.yml @@ -23,7 +23,7 @@ references: cis@sle12: 2.2.13 cis@sle15: 2.2.13 -{{{ complete_ocil_entry_package(package="samba") }}} +{{{ complete_ocil_entry_package_removed("samba") }}} template: name: package_removed diff --git a/linux_os/guide/services/snmp/disabling_snmp_service/package_net-snmp_removed/rule.yml b/linux_os/guide/services/snmp/disabling_snmp_service/package_net-snmp_removed/rule.yml index d03b49ce0829..3d86a465a82e 100644 --- a/linux_os/guide/services/snmp/disabling_snmp_service/package_net-snmp_removed/rule.yml +++ b/linux_os/guide/services/snmp/disabling_snmp_service/package_net-snmp_removed/rule.yml @@ -33,9 +33,9 @@ references: cis@sle15: 2.2.15 {{% if pkg_manager != "apt_get" %}} -{{{ complete_ocil_entry_package(package="net-snmp") }}} + {{{- complete_ocil_entry_package_removed("net-snmp") }}} {{% else %}} -{{{ complete_ocil_entry_package(package="snmp") }}} + {{{- complete_ocil_entry_package_removed("snmp") }}} {{% endif %}} template: diff --git a/linux_os/guide/services/ssh/directory_groupowner_sshd_config_d/rule.yml b/linux_os/guide/services/ssh/directory_groupowner_sshd_config_d/rule.yml index 9dd2ecc766b5..7c990240df3e 100644 --- a/linux_os/guide/services/ssh/directory_groupowner_sshd_config_d/rule.yml +++ b/linux_os/guide/services/ssh/directory_groupowner_sshd_config_d/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Group Who Owns SSH Server Configuration Files' description: |- - {{{ describe_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}} + {{{ describe_directory_group_owner(directory=sshd_config_dir, group="root") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -28,19 +28,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}}' +ocil_clause: '{{{ ocil_clause_directory_group_owner(directory=sshd_config_dir, group="root") }}}' ocil: |- - {{{ ocil_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}} + {{{ ocil_directory_group_owner(directory=sshd_config_dir, group="root") }}} -fixtext: '{{{ fixtext_directory_group_owner(file="/etc/ssh/sshd_config.d", group="root") }}}' +fixtext: '{{{ fixtext_directory_group_owner(file=sshd_config_dir, group="root") }}}' -srg_requirement: '{{{ srg_requirement_directory_group_owner(file="/etc/ssh/sshd_config.d", group="root") }}}' +srg_requirement: '{{{ srg_requirement_directory_group_owner(file=sshd_config_dir, group="root") }}}' template: name: file_groupowner vars: - filepath: '/etc/ssh/sshd_config.d/' + filepath: '{{{ sshd_config_dir }}}/' gid_or_name: '0' platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/directory_owner_sshd_config_d/rule.yml b/linux_os/guide/services/ssh/directory_owner_sshd_config_d/rule.yml index 73713872c946..0d4dcc611827 100644 --- a/linux_os/guide/services/ssh/directory_owner_sshd_config_d/rule.yml +++ b/linux_os/guide/services/ssh/directory_owner_sshd_config_d/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Owner on SSH Server Configuration Files' description: |- - {{{ describe_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}} + {{{ describe_directory_owner(directory=sshd_config_dir, owner="root") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -28,19 +28,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}}' +ocil_clause: '{{{ ocil_clause_directory_owner(directory=sshd_config_dir, owner="root") }}}' ocil: |- - {{{ ocil_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}} + {{{ ocil_directory_owner(directory=sshd_config_dir, owner="root") }}} -fixtext: '{{{ fixtext_directory_owner(file="/etc/ssh/sshd_config.d", owner="root") }}}' +fixtext: '{{{ fixtext_directory_owner(file=sshd_config_dir, owner="root") }}}' -srg_requirement: '{{{ srg_requirement_directory_owner(file="/etc/ssh/sshd_config.d", owner="root") }}}' +srg_requirement: '{{{ srg_requirement_directory_owner(file=sshd_config_dir, owner="root") }}}' template: name: file_owner vars: - filepath: '/etc/ssh/sshd_config.d/' + filepath: '{{{ sshd_config_dir }}}/' uid_or_name: '0' platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/directory_permissions_sshd_config_d/rule.yml b/linux_os/guide/services/ssh/directory_permissions_sshd_config_d/rule.yml index 6a50abb97e99..9496c6c0efc3 100644 --- a/linux_os/guide/services/ssh/directory_permissions_sshd_config_d/rule.yml +++ b/linux_os/guide/services/ssh/directory_permissions_sshd_config_d/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Permissions on SSH Server Config File' description: |- - {{{ describe_directory_permissions(directory="/etc/ssh/sshd_config.d", perms="0700") }}} + {{{ describe_directory_permissions(directory=sshd_config_dir, perms="0700") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -28,19 +28,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_directory_permissions(directory="/etc/ssh/sshd_config.d", perms="-rwx------") }}}' +ocil_clause: '{{{ ocil_clause_directory_permissions(directory=sshd_config_dir, perms="-rwx------") }}}' ocil: |- - {{{ ocil_directory_permissions(directory="/etc/ssh/sshd_config.d", perms="-rwx------") }}} + {{{ ocil_directory_permissions(directory=sshd_config_dir, perms="-rwx------") }}} -fixtext: '{{{ fixtext_directory_permissions(file="/etc/ssh/sshd_config.d", mode="0700") }}}' +fixtext: '{{{ fixtext_directory_permissions(file=sshd_config_dir, mode="0700") }}}' -srg_requirement: '{{{ srg_requirement_directory_permission(file="/etc/ssh/sshd_config.d", mode="0700") }}}' +srg_requirement: '{{{ srg_requirement_directory_permission(file=sshd_config_dir, mode="0700") }}}' template: name: file_permissions vars: - filepath: /etc/ssh/sshd_config.d/ + filepath: '{{{ sshd_config_dir }}}/' filemode: '0700' platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/file_groupowner_sshd_config/rule.yml b/linux_os/guide/services/ssh/file_groupowner_sshd_config/rule.yml index f0ea9c5cf13d..8d6c5cef73e9 100644 --- a/linux_os/guide/services/ssh/file_groupowner_sshd_config/rule.yml +++ b/linux_os/guide/services/ssh/file_groupowner_sshd_config/rule.yml @@ -4,7 +4,7 @@ documentation_complete: true title: 'Verify Group Who Owns SSH Server config file' description: |- - {{{ describe_file_group_owner(file="/etc/ssh/sshd_config", group="root") }}} + {{{ describe_file_group_owner(file=sshd_main_config_file, group="root") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-86992-5 cce@sle12: CCE-92276-5 cce@sle15: CCE-91392-1 + cce@sle16: CCE-96595-4 cce@slmicro5: CCE-93889-4 references: @@ -35,19 +36,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/ssh/sshd_config", group="root") }}}' +ocil_clause: '{{{ ocil_clause_file_group_owner(file=sshd_main_config_file, group="root") }}}' ocil: |- - {{{ ocil_file_group_owner(file="/etc/ssh/sshd_config", group="root") }}} + {{{ ocil_file_group_owner(file=sshd_main_config_file, group="root") }}} -fixtext: '{{{ fixtext_file_group_owner(file="/etc/ssh/sshd_config", group="root") }}}' +fixtext: '{{{ fixtext_file_group_owner(file=sshd_main_config_file, group="root") }}}' -srg_requirement: '{{{ srg_requirement_file_group_owner(file="/etc/ssh/sshd_config", group="root") }}}' +srg_requirement: '{{{ srg_requirement_file_group_owner(file=sshd_main_config_file, group="root") }}}' template: name: file_groupowner vars: - filepath: /etc/ssh/sshd_config + filepath: '{{{ sshd_main_config_file }}}' gid_or_name: '0' platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/file_groupowner_sshd_drop_in_config/rule.yml b/linux_os/guide/services/ssh/file_groupowner_sshd_drop_in_config/rule.yml index 5f1728ab2a8b..3fd050bca108 100644 --- a/linux_os/guide/services/ssh/file_groupowner_sshd_drop_in_config/rule.yml +++ b/linux_os/guide/services/ssh/file_groupowner_sshd_drop_in_config/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Group Who Owns SSH Server Configuration Files' description: |- - {{{ describe_files_in_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}} + {{{ describe_files_in_directory_group_owner(directory=sshd_config_dir, group="root") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -28,19 +28,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_files_in_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}}' +ocil_clause: '{{{ ocil_clause_files_in_directory_group_owner(directory=sshd_config_dir, group="root") }}}' ocil: |- - {{{ ocil_files_in_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}} + {{{ ocil_files_in_directory_group_owner(directory=sshd_config_dir, group="root") }}} -fixtext: '{{{ fixtext_files_in_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}}' +fixtext: '{{{ fixtext_files_in_directory_group_owner(directory=sshd_config_dir, group="root") }}}' -srg_requirement: '{{{ srg_requirement_files_in_directory_group_owner(directory="/etc/ssh/sshd_config.d", group="root") }}}' +srg_requirement: '{{{ srg_requirement_files_in_directory_group_owner(directory=sshd_config_dir, group="root") }}}' template: name: file_groupowner vars: - filepath: '/etc/ssh/sshd_config.d/' + filepath: '{{{ sshd_config_dir }}}/' file_regex: '^.*$' gid_or_name: '0' diff --git a/linux_os/guide/services/ssh/file_groupownership_sshd_private_key/rule.yml b/linux_os/guide/services/ssh/file_groupownership_sshd_private_key/rule.yml index 755283fde798..fd5b56034bd8 100644 --- a/linux_os/guide/services/ssh/file_groupownership_sshd_private_key/rule.yml +++ b/linux_os/guide/services/ssh/file_groupownership_sshd_private_key/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel8: CCE-86126-0 cce@rhel9: CCE-86127-8 cce@rhel10: CCE-90288-2 + cce@sle16: CCE-96366-0 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/ssh/*_key", group="root") }}}' diff --git a/linux_os/guide/services/ssh/file_groupownership_sshd_pub_key/rule.yml b/linux_os/guide/services/ssh/file_groupownership_sshd_pub_key/rule.yml index d25a28e32dc2..3e235d9d6e8e 100644 --- a/linux_os/guide/services/ssh/file_groupownership_sshd_pub_key/rule.yml +++ b/linux_os/guide/services/ssh/file_groupownership_sshd_pub_key/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86133-6 cce@rhel9: CCE-86136-9 cce@rhel10: CCE-90469-8 + cce@sle16: CCE-96361-1 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/ssh/*.pub", group="root") }}}' diff --git a/linux_os/guide/services/ssh/file_owner_sshd_config/rule.yml b/linux_os/guide/services/ssh/file_owner_sshd_config/rule.yml index 4fefa1a5a591..528ebf4553b9 100644 --- a/linux_os/guide/services/ssh/file_owner_sshd_config/rule.yml +++ b/linux_os/guide/services/ssh/file_owner_sshd_config/rule.yml @@ -4,7 +4,7 @@ documentation_complete: true title: 'Verify Owner on SSH Server config file' description: |- - {{{ describe_file_owner(file="/etc/ssh/sshd_config", owner="root") }}} + {{{ describe_file_owner(file=sshd_main_config_file, owner="root") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-89829-6 cce@sle12: CCE-92277-3 cce@sle15: CCE-91393-9 + cce@sle16: CCE-96194-6 cce@slmicro5: CCE-93888-6 references: @@ -35,19 +36,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/ssh/sshd_config", owner="root") }}}' +ocil_clause: '{{{ ocil_clause_file_owner(file=sshd_main_config_file, owner="root") }}}' ocil: |- - {{{ ocil_file_owner(file="/etc/ssh/sshd_config", owner="root") }}} + {{{ ocil_file_owner(file=sshd_main_config_file, owner="root") }}} -fixtext: '{{{ fixtext_file_owner(file="/etc/ssh/sshd_config", owner="root") }}}' +fixtext: '{{{ fixtext_file_owner(file=sshd_main_config_file, owner="root") }}}' -srg_requirement: '{{{ srg_requirement_file_owner(file="/etc/ssh/sshd_config", owner="root") }}}' +srg_requirement: '{{{ srg_requirement_file_owner(file=sshd_main_config_file, owner="root") }}}' template: name: file_owner vars: - filepath: /etc/ssh/sshd_config + filepath: '{{{ sshd_main_config_file }}}' uid_or_name: '0' platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/file_owner_sshd_drop_in_config/rule.yml b/linux_os/guide/services/ssh/file_owner_sshd_drop_in_config/rule.yml index f0832ad73e6b..bb0cf97aa84a 100644 --- a/linux_os/guide/services/ssh/file_owner_sshd_drop_in_config/rule.yml +++ b/linux_os/guide/services/ssh/file_owner_sshd_drop_in_config/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Owner on SSH Server Configuration Files' description: |- - {{{ describe_files_in_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}} + {{{ describe_files_in_directory_owner(directory=sshd_config_dir, owner="root") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -29,19 +29,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_files_in_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}}' +ocil_clause: '{{{ ocil_clause_files_in_directory_owner(directory=sshd_config_dir, owner="root") }}}' ocil: |- - {{{ ocil_files_in_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}} + {{{ ocil_files_in_directory_owner(directory=sshd_config_dir, owner="root") }}} -fixtext: '{{{ fixtext_files_in_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}}' +fixtext: '{{{ fixtext_files_in_directory_owner(directory=sshd_config_dir, owner="root") }}}' -srg_requirement: '{{{ srg_requirement_files_in_directory_owner(directory="/etc/ssh/sshd_config.d", owner="root") }}}' +srg_requirement: '{{{ srg_requirement_files_in_directory_owner(directory=sshd_config_dir, owner="root") }}}' template: name: file_owner vars: - filepath: '/etc/ssh/sshd_config.d/' + filepath: '{{{ sshd_config_dir }}}/' file_regex: '^.*$' uid_or_name: '0' diff --git a/linux_os/guide/services/ssh/file_ownership_sshd_private_key/rule.yml b/linux_os/guide/services/ssh/file_ownership_sshd_private_key/rule.yml index ccb71fb9ae85..8bae6479baf1 100644 --- a/linux_os/guide/services/ssh/file_ownership_sshd_private_key/rule.yml +++ b/linux_os/guide/services/ssh/file_ownership_sshd_private_key/rule.yml @@ -15,6 +15,7 @@ identifiers: cce@rhel8: CCE-86118-7 cce@rhel9: CCE-86119-5 cce@rhel10: CCE-90624-8 + cce@sle16: CCE-95879-3 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/ssh/*_key", owner="root") }}}' diff --git a/linux_os/guide/services/ssh/file_ownership_sshd_pub_key/rule.yml b/linux_os/guide/services/ssh/file_ownership_sshd_pub_key/rule.yml index 4239d6724a9b..0e77032acb79 100644 --- a/linux_os/guide/services/ssh/file_ownership_sshd_pub_key/rule.yml +++ b/linux_os/guide/services/ssh/file_ownership_sshd_pub_key/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86129-4 cce@rhel9: CCE-86130-2 cce@rhel10: CCE-87297-8 + cce@sle16: CCE-95980-9 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/ssh/*.pub", owner="root") }}}' diff --git a/linux_os/guide/services/ssh/file_permissions_sshd_config/rule.yml b/linux_os/guide/services/ssh/file_permissions_sshd_config/rule.yml index f36678bf6753..d9d311f83a97 100644 --- a/linux_os/guide/services/ssh/file_permissions_sshd_config/rule.yml +++ b/linux_os/guide/services/ssh/file_permissions_sshd_config/rule.yml @@ -4,7 +4,7 @@ documentation_complete: true title: 'Verify Permissions on SSH Server config file' description: |- - {{{ describe_file_permissions(file="/etc/ssh/sshd_config", perms="0600") }}} + {{{ describe_file_permissions(file=sshd_main_config_file, perms="0600") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -36,20 +36,20 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/ssh/sshd_config", perms="-rw-------") }}}' +ocil_clause: '{{{ ocil_clause_file_permissions(file=sshd_main_config_file, perms="-rw-------") }}}' ocil: |- - {{{ ocil_file_permissions(file="/etc/ssh/sshd_config", perms="-rw-------") }}} + {{{ ocil_file_permissions(file=sshd_main_config_file, perms="-rw-------") }}} -fixtext: '{{{ fixtext_file_permissions(file="/etc/ssh/sshd_config", mode="0600") }}}' +fixtext: '{{{ fixtext_file_permissions(file=sshd_main_config_file, mode="0600") }}}' -srg_requirement: '{{{ srg_requirement_file_permission(file="/etc/ssh/sshd_config", mode="0600") }}}' +srg_requirement: '{{{ srg_requirement_file_permission(file=sshd_main_config_file, mode="0600") }}}' template: name: file_permissions vars: filepath: - - /etc/ssh/sshd_config + - '{{{ sshd_main_config_file }}}' filemode: '0600' platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/file_permissions_sshd_drop_in_config/rule.yml b/linux_os/guide/services/ssh/file_permissions_sshd_drop_in_config/rule.yml index 26a1815bce4d..0cfaa9f10f6b 100644 --- a/linux_os/guide/services/ssh/file_permissions_sshd_drop_in_config/rule.yml +++ b/linux_os/guide/services/ssh/file_permissions_sshd_drop_in_config/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Permissions on SSH Server Config File' description: |- - {{{ describe_files_in_directory_permissions(directory="/etc/ssh/sshd_config.d", perms="0600") }}} + {{{ describe_files_in_directory_permissions(directory=sshd_config_dir, perms="0600") }}} rationale: |- Service configuration files enable or disable features of their respective @@ -28,19 +28,19 @@ references: nist-csf: PR.AC-4,PR.DS-5 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: '{{{ ocil_clause_files_in_directory_permissions(directory="/etc/ssh/sshd_config.d", perms="-rw-------") }}}' +ocil_clause: '{{{ ocil_clause_files_in_directory_permissions(directory=sshd_config_dir, perms="-rw-------") }}}' ocil: |- - {{{ ocil_files_in_directory_permissions(directory="/etc/ssh/sshd_config.d", perms="-rw-------") }}} + {{{ ocil_files_in_directory_permissions(directory=sshd_config_dir, perms="-rw-------") }}} -fixtext: '{{{ fixtext_files_in_directory_permissions(directory="/etc/ssh/sshd_config.d", mode="0600") }}}' +fixtext: '{{{ fixtext_files_in_directory_permissions(directory=sshd_config_dir, mode="0600") }}}' -srg_requirement: '{{{ srg_requirement_files_in_directory_permissions(directory="/etc/ssh/sshd_config.d", mode="0600") }}}' +srg_requirement: '{{{ srg_requirement_files_in_directory_permissions(directory=sshd_config_dir, mode="0600") }}}' template: name: file_permissions vars: - filepath: '/etc/ssh/sshd_config.d/' + filepath: '{{{ sshd_config_dir }}}/' file_regex: '^.*$' filemode: '0600' diff --git a/linux_os/guide/services/ssh/file_sshd_50_redhat_exists/rule.yml b/linux_os/guide/services/ssh/file_sshd_50_redhat_exists/rule.yml index ffa34166c034..db813093f611 100644 --- a/linux_os/guide/services/ssh/file_sshd_50_redhat_exists/rule.yml +++ b/linux_os/guide/services/ssh/file_sshd_50_redhat_exists/rule.yml @@ -1,9 +1,10 @@ +{{% set sshd_redhat_drop_in_file = sshd_config_dir ~ "/50-redhat.conf" %}} documentation_complete: true -title: 'The File /etc/ssh/sshd_config.d/50-redhat.conf Must Exist' +title: 'The File {{{ sshd_redhat_drop_in_file }}} Must Exist' description: |- - The /etc/ssh/sshd_config.d/50-redhat.conf file must exist as it contains important + The {{{ sshd_redhat_drop_in_file }}} file must exist as it contains important settings to secure SSH. @@ -29,7 +30,7 @@ warnings: template: name: 'file_existence' vars: - filepath: '/etc/ssh/sshd_config.d/50-redhat.conf' + filepath: '{{{ sshd_redhat_drop_in_file }}}' exists: true backends: ansible: off diff --git a/linux_os/guide/services/ssh/package_openssh-clients_installed/rule.yml b/linux_os/guide/services/ssh/package_openssh-clients_installed/rule.yml index cb2339574bfd..d94efa5d442d 100644 --- a/linux_os/guide/services/ssh/package_openssh-clients_installed/rule.yml +++ b/linux_os/guide/services/ssh/package_openssh-clients_installed/rule.yml @@ -21,9 +21,7 @@ references: ospp: FIA_UAU.5,FTP_ITC_EXT.1,FCS_SSH_EXT.1,FCS_SSHC_EXT.1 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="openssh-clients") }}}' +{{{ complete_ocil_entry_package_installed("openssh-clients") }}} fixtext: '{{{ fixtext_package_removed("openssh-clients") }}}' @@ -33,3 +31,5 @@ template: name: package_installed vars: pkgname: openssh-clients + +platform: system_with_kernel diff --git a/linux_os/guide/services/ssh/package_openssh-server_installed/rule.yml b/linux_os/guide/services/ssh/package_openssh-server_installed/rule.yml index 925eef72f632..89833be81624 100644 --- a/linux_os/guide/services/ssh/package_openssh-server_installed/rule.yml +++ b/linux_os/guide/services/ssh/package_openssh-server_installed/rule.yml @@ -32,9 +32,7 @@ references: stigid@ol7: OL07-00-040300 stigid@ol8: OL08-00-040159 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="openssh-server") }}}' +{{{ complete_ocil_entry_package_installed("openssh-server") }}} template: name: package_installed diff --git a/linux_os/guide/services/ssh/package_openssh-server_removed/rule.yml b/linux_os/guide/services/ssh/package_openssh-server_removed/rule.yml index 15f29deeee6b..17e21fd60866 100644 --- a/linux_os/guide/services/ssh/package_openssh-server_removed/rule.yml +++ b/linux_os/guide/services/ssh/package_openssh-server_removed/rule.yml @@ -13,9 +13,10 @@ rationale: |- severity: medium -ocil_clause: 'the package is installed' +identifiers: + cce@rhcos4: CCE-86709-3 -ocil: '{{{ ocil_package(package="openssh-server") }}}' +{{{ complete_ocil_entry_package_removed("openssh-server") }}} template: name: package_removed diff --git a/linux_os/guide/services/ssh/package_openssh_installed/rule.yml b/linux_os/guide/services/ssh/package_openssh_installed/rule.yml index 5ec44279483d..1d6502a205a6 100644 --- a/linux_os/guide/services/ssh/package_openssh_installed/rule.yml +++ b/linux_os/guide/services/ssh/package_openssh_installed/rule.yml @@ -18,9 +18,7 @@ references: nist: CM-6(a) srg: SRG-OS-000423-GPOS-00187 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="openssh") }}}' +{{{ complete_ocil_entry_package_installed("openssh") }}} template: name: package_installed diff --git a/linux_os/guide/services/ssh/package_openssh_removed/rule.yml b/linux_os/guide/services/ssh/package_openssh_removed/rule.yml index b548e2bcb67d..30f0b696a1d1 100644 --- a/linux_os/guide/services/ssh/package_openssh_removed/rule.yml +++ b/linux_os/guide/services/ssh/package_openssh_removed/rule.yml @@ -14,9 +14,7 @@ rationale: |- severity: medium -ocil_clause: 'the package is installed' - -ocil: '{{{ ocil_package(package="openssh") }}}' +{{{ complete_ocil_entry_package_removed("openssh") }}} template: name: package_removed diff --git a/linux_os/guide/services/ssh/ssh_client/group.yml b/linux_os/guide/services/ssh/ssh_client/group.yml index 62ead28ee19f..785fb28f28bb 100644 --- a/linux_os/guide/services/ssh/ssh_client/group.yml +++ b/linux_os/guide/services/ssh/ssh_client/group.yml @@ -9,3 +9,5 @@ description: |- influence only the default SSH client configuration. Changes in this group can be overridden by the client user by modifying files within the
~/.ssh
directory or by supplying parameters on the command line. + +platform: package[openssh-clients] diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/ansible/shared.yml b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/ansible/shared.yml index 81968afeebea..7b5a91c274e7 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/ansible/shared.yml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/ansible/shared.yml @@ -4,12 +4,15 @@ # complexity = low # disruption = low {{{ ansible_instantiate_variables("var_ssh_client_rekey_limit_size", "var_ssh_client_rekey_limit_time") }}} +{{%- set sshc_main_config = ssh_client_main_config_file -%}} +{{%- set sshc_config_dir = ssh_client_config_dir -%}} +{{%- set sshc_rekey_config = ssh_client_config_dir ~ "/02-rekey-limit.conf" -%}} -{{{ ansible_lineinfile(msg='Ensure RekeyLimit is not configured in /etc/ssh/ssh_config', path='/etc/ssh/ssh_config', regex='^\s*RekeyLimit.*$', insensitive=false, create='no', state='absent', rule_title=rule_title) }}} +{{{ ansible_lineinfile(msg='Ensure RekeyLimit is not configured in ' ~ sshc_main_config, path=sshc_main_config, regex='^\s*RekeyLimit.*$', insensitive=false, create='no', state='absent', rule_title=rule_title) }}} - name: Collect all include config files for ssh client which configure RekeyLimit ansible.builtin.find: - paths: "/etc/ssh/ssh_config.d/" + paths: "{{{ sshc_config_dir }}}" contains: '^[\s]*RekeyLimit.*$' patterns: "*.config" register: ssh_config_include_files @@ -21,4 +24,4 @@ state: "absent" loop: "{{ ssh_config_include_files.files }}" -{{{ ansible_lineinfile(msg='Ensure that rekey limit is set to {{ var_ssh_client_rekey_limit_size }} {{ var_ssh_client_rekey_limit_time }} in /etc/ssh/ssh_config.d/02-rekey-limit.conf', path='/etc/ssh/ssh_config.d/02-rekey-limit.conf', regex='^\s*RekeyLimit.*$', insensitive=false, new_line='RekeyLimit {{ var_ssh_client_rekey_limit_size }} {{ var_ssh_client_rekey_limit_time }}', create='yes', state='present', rule_title=rule_title) }}} +{{{ ansible_lineinfile(msg='Ensure that rekey limit is set to {{ var_ssh_client_rekey_limit_size }} {{ var_ssh_client_rekey_limit_time }} in ' ~ sshc_rekey_config, path=sshc_rekey_config, regex='^\s*RekeyLimit.*$', insensitive=false, new_line='RekeyLimit {{ var_ssh_client_rekey_limit_size }} {{ var_ssh_client_rekey_limit_time }}', create='yes', state='present', rule_title=rule_title) }}} diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/bash/shared.sh b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/bash/shared.sh index 9662e8d55e4c..c50d21ab5242 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/bash/shared.sh @@ -1,9 +1,10 @@ # platform = multi_platform_all {{{ bash_instantiate_variables("var_ssh_client_rekey_limit_size", "var_ssh_client_rekey_limit_time") }}} +{{%- set sshc_rekey_config = ssh_client_config_dir ~ "/02-rekey-limit.conf" -%}} -main_config="/etc/ssh/ssh_config" -include_directory="/etc/ssh/ssh_config.d" +main_config="{{{ ssh_client_main_config_file }}}" +include_directory="{{{ ssh_client_config_dir }}}" if grep -q '^[\s]*RekeyLimit.*$' "$main_config"; then sed -i '/^[\s]*RekeyLimit.*/d' "$main_config" @@ -15,4 +16,4 @@ for file in "$include_directory"/*.conf; do fi done -{{{ set_config_file(path="/etc/ssh/ssh_config.d/02-rekey-limit.conf", parameter="RekeyLimit", value='$var_ssh_client_rekey_limit_size $var_ssh_client_rekey_limit_time', create=true, insert_before="", insert_after="", insensitive=false, separator=" ", separator_regex="\s\+", prefix_regex="^\s*", rule_id=rule_id) }}} +{{{ set_config_file(path=sshc_rekey_config, parameter="RekeyLimit", value='$var_ssh_client_rekey_limit_size $var_ssh_client_rekey_limit_time', create=true, insert_before="", insert_after="", insensitive=false, separator=" ", separator_regex="\s\+", prefix_regex="^\s*", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/oval/shared.xml b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/oval/shared.xml index 83c8433fb153..01f49eb6842f 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/oval/shared.xml @@ -1,10 +1,13 @@ +{{%- set sshc_main_config = ssh_client_main_config_file -%}} +{{%- set sshc_config_dir = ssh_client_config_dir -%}} + - {{{ oval_metadata("Ensure 'RekeyLimit' is configured with the correct value in /etc/ssh/ssh_config and /etc/ssh/ssh_config.d/*.conf", rule_title=rule_title) }}} + {{{ oval_metadata("Ensure 'RekeyLimit' is configured with the correct value in " ~ sshc_main_config ~ " and " ~ sshc_config_dir ~ "/*.conf", rule_title=rule_title) }}} - - + + @@ -22,22 +25,23 @@ - + - /etc/ssh/ssh_config + {{{ sshc_main_config }}} ^[\s]*RekeyLimit.*$ 1 - + - ^/etc/ssh/ssh_config\.d/.*\.conf$ + {{{ sshc_config_dir }}} + .*\.conf$ 1 diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/rule.yml b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/rule.yml index d9b564e17a4d..018a48cca00c 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/rule.yml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_rekey_limit/rule.yml @@ -1,5 +1,8 @@ documentation_complete: true +{{% set sshc_main_config = ssh_client_main_config_file %}} +{{% set sshc_config_dir = ssh_client_config_dir %}} +{{% set sshc_rekey_config = ssh_client_config_dir ~ "/02-rekey-limit.conf" %}} title: 'Configure session renegotiation for SSH client' @@ -8,11 +11,11 @@ description: |- the session key is renegotiated, both in terms of amount of data that may be transmitted and the time elapsed. To decrease the default limits, put line - RekeyLimit {{{ xccdf_value("var_ssh_client_rekey_limit_size") }}} {{{ xccdf_value("var_ssh_client_rekey_limit_time") }}} to file /etc/ssh/ssh_config.d/02-rekey-limit.conf. + RekeyLimit {{{ xccdf_value("var_ssh_client_rekey_limit_size") }}} {{{ xccdf_value("var_ssh_client_rekey_limit_time") }}} to file {{{ sshc_rekey_config }}}. Make sure that there is no other RekeyLimit configuration preceding the include directive in the main config file - /etc/ssh/ssh_config. Check also other files in - /etc/ssh/ssh_config.d directory. Files are processed according to + {{{ sshc_main_config }}}. Check also other files in + {{{ sshc_config_dir }}} directory. Files are processed according to lexicographical order of file names. Make sure that there is no file processed before 02-rekey-limit.conf containing definition of RekeyLimit. @@ -37,12 +40,12 @@ ocil_clause: 'it is commented out or is not set' ocil: |- To check if RekeyLimit is set correctly, run the following command: -
$ sudo grep RekeyLimit /etc/ssh/ssh_config.d/*.conf
+
$ sudo grep RekeyLimit {{{ sshc_config_dir }}}/*.conf
If configured properly, output should be -
/etc/ssh/ssh_config.d/02-rekey-limit.conf:
+    
{{{ sshc_rekey_config }}}:
     RekeyLimit {{{ xccdf_value("var_ssh_client_rekey_limit_size") }}} {{{ xccdf_value("var_ssh_client_rekey_limit_time") }}}
Check also the main configuration file with the following command: -
$ sudo grep RekeyLimit /etc/ssh/ssh_config
+
$ sudo grep RekeyLimit {{{ sshc_main_config }}}
The command should not return any output. fixtext: |- @@ -53,4 +56,3 @@ fixtext: |- Restart the SSH daemon for the settings to take effect. $ sudo systemctl restart sshd.service - diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/bash/shared.sh b/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/bash/shared.sh index c90bd144ef7d..01445b652b99 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/bash/shared.sh @@ -1,14 +1,16 @@ # platform = multi_platform_ubuntu ssh_approved_ciphers="aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr" +{{% set sshc_cipher_list_config = ssh_client_config_dir ~ "/00-cipher-list.conf" %}} -main_config="/etc/ssh/ssh_config" -include_directory="/etc/ssh/ssh_config.d" +main_config="{{{ ssh_client_main_config_file }}}" +include_directory="{{{ ssh_client_config_dir }}}" +cipher_list_config="$include_directory/00-cipher-list.conf" sed -i '/^\s*[Cc]iphers.*/d' "$main_config" "$include_directory"/*.conf || true -if ! grep -qE '^[Hh]ost\s+\*$' /etc/ssh/ssh_config.d/00-cipher-list.conf; then - echo 'Host *' >> /etc/ssh/ssh_config.d/00-cipher-list.conf +if ! grep -qE '^[Hh]ost\s+\*$' "$cipher_list_config"; then + echo 'Host *' >> "$cipher_list_config" fi -{{{ set_config_file(path="/etc/ssh/ssh_config.d/00-cipher-list.conf", parameter="Ciphers", value='$ssh_approved_ciphers', create=true, insert_before="", insert_after="^Host\s+\*$", insensitive=false, separator=" ", separator_regex="\s\+", prefix_regex="^\s*", rule_id=rule_id) }}} +{{{ set_config_file(path=sshc_cipher_list_config, parameter="Ciphers", value='$ssh_approved_ciphers', create=true, insert_before="", insert_after="^Host\s+\*$", insensitive=false, separator=" ", separator_regex="\s\+", prefix_regex="^\s*", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/oval/shared.xml b/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/oval/shared.xml index 3d6471f483cd..6a17966e11de 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/oval/shared.xml @@ -1,40 +1,42 @@ {{%- if product == 'ubuntu2404' %}} {{%- set ssh_approved_ciphers="aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr" %}} {{%- endif %}} +{{%- set sshc_main_config = ssh_client_main_config_file -%}} +{{%- set sshc_config_dir = ssh_client_config_dir -%}} {{{ oval_metadata("Limit the ciphers to those which are FIPS-approved.", rule_title=rule_title) }}} - - - /etc/ssh/ssh_config + {{{ sshc_main_config }}} ^[ \t]*(?i)ciphers(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 - /etc/ssh/ssh_config.d + {{{ sshc_config_dir }}} .*\.conf$ ^[ \t]*(?i)ciphers(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/rule.yml b/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/rule.yml index b390b8e81328..bc8f65cd23a0 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/rule.yml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_client_use_approved_ciphers_ordered_stig/rule.yml @@ -1,13 +1,14 @@ {{%- if product == 'ubuntu2404' %}} {{%- set ssh_approved_ciphers = "aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr" %}} {{%- endif %}} +{{%- set sshc_main_config = ssh_client_main_config_file -%}} documentation_complete: true title: 'Use Only FIPS 140-3 Validated Ciphers in SSH Client Configuration' description: |- Limit the ciphers to those algorithms which are FIPS-approved. - The following line in /etc/ssh/ssh_config + The following line in {{{ sshc_main_config }}} demonstrates use of FIPS-approved ciphers: {{%- if 'ubuntu' in product %}}
Ciphers {{{ ssh_approved_ciphers }}}
diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/bash/shared.sh b/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/bash/shared.sh index 8c4fa3715f4b..c5bef9fd205b 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/bash/shared.sh @@ -1,14 +1,16 @@ # platform = multi_platform_ubuntu {{{ bash_instantiate_variables("ssh_approved_macs") }}} +{{%- set sshc_mac_list_config = ssh_client_config_dir ~ "/00-mac-list.conf" -%}} -main_config="/etc/ssh/ssh_config" -include_directory="/etc/ssh/ssh_config.d" +main_config="{{{ ssh_client_main_config_file }}}" +include_directory="{{{ ssh_client_config_dir }}}" +mac_list_config="$include_directory/00-mac-list.conf" sed -i '/^\s*MACs.*/d' "$main_config" "$include_directory"/*.conf || true -if ! grep -qE '^[Hh]ost\s+\*$' /etc/ssh/ssh_config.d/00-mac-list.conf; then - echo 'Host *' >> /etc/ssh/ssh_config.d/00-mac-list.conf +if ! grep -qE '^[Hh]ost\s+\*$' "$mac_list_config"; then + echo 'Host *' >> "$mac_list_config" fi -{{{ set_config_file(path="/etc/ssh/ssh_config.d/00-mac-list.conf", parameter="MACs", value='$ssh_approved_macs', create=true, insert_before="", insert_after="^Host\s+\*$", insensitive=false, separator=" ", separator_regex="\s\+", prefix_regex="^\s*", rule_id=rule_id) }}} +{{{ set_config_file(path=sshc_mac_list_config, parameter="MACs", value='$ssh_approved_macs', create=true, insert_before="", insert_after="^Host\s+\*$", insensitive=false, separator=" ", separator_regex="\s\+", prefix_regex="^\s*", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/oval/shared.xml b/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/oval/shared.xml index be209a2537b6..a7dbbe5edee9 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/oval/shared.xml @@ -1,11 +1,14 @@ +{{%- set sshc_main_config = ssh_client_main_config_file -%}} +{{%- set sshc_config_dir = ssh_client_config_dir -%}} + {{{ oval_metadata("Limit the Message Authentication Codes (MACs) to those which are FIPS-approved.", rule_title=rule_title) }}} - - @@ -13,27 +16,27 @@ - /etc/ssh/ssh_config + {{{ sshc_main_config }}} ^[ \t]*(?i)MACs(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 - /etc/ssh/ssh_config.d + {{{ sshc_config_dir }}} .*\.conf$ ^[ \t]*(?i)MACs(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/rule.yml b/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/rule.yml index 45de2c107a32..a3b143a1e57f 100644 --- a/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/rule.yml +++ b/linux_os/guide/services/ssh/ssh_client/ssh_use_approved_macs_ordered_stig/rule.yml @@ -1,10 +1,12 @@ documentation_complete: true +{{% set sshc_main_config = ssh_client_main_config_file %}} +{{%- set sshc_config_dir = ssh_client_config_dir -%}} title: 'Use Only FIPS 140-3 Validated MACs' description: |- Limit the MACs to those hash algorithms which are FIPS-approved. - The following line in /etc/ssh/ssh_config + The following line in {{{ sshc_main_config }}} demonstrates use of FIPS-approved MACs:
MACs {{{ ssh_approved_macs }}}
@@ -22,11 +24,10 @@ ocil_clause: 'MACs option is commented out or not using FIPS-approved hash algor ocil: |- Only FIPS-approved MACs should be used. To verify that only FIPS-approved MACs are in use, run the following command: -
$ sudo grep -ir macs /etc/ssh/ssh_config*
+
$ sudo grep -ir macs {{{ sshc_main_config }}} {{{ sshc_config_dir }}}
The output should contain only following MACs:
MACs {{{ xccdf_value("ssh_approved_macs") }}}
warnings: - general: |- The system needs to be rebooted for these changes to take effect. - diff --git a/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/ansible/shared.yml b/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/ansible/shared.yml index 0c91e36308e8..a16687434c6c 100644 --- a/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/ansible/shared.yml +++ b/linux_os/guide/services/ssh/ssh_server/firewalld_sshd_port_enabled/ansible/shared.yml @@ -17,7 +17,8 @@ - name: '{{{ rule_title }}} - Collect facts about system services' ansible.builtin.service_facts: -- name: '{{{ rule_title }}} - Remediation is applicable if firewalld and NetworkManager services are running' +- name: '{{{ rule_title }}} - Remediation is applicable if firewalld and + NetworkManager services are running' block: - name: '{{{ rule_title }}} - Collect NetworkManager connections names' ansible.builtin.shell: @@ -34,7 +35,7 @@ changed_when: false failed_when: false with_items: - - "{{ result_nmcli_cmd_connections_names.stdout_lines | default([]) }}" + - "{{ result_nmcli_cmd_connections_names.stdout_lines | default([]) }}" when: - result_nmcli_cmd_connections_names.stdout_lines is defined - result_nmcli_cmd_connections_names.stdout_lines | length > 0 @@ -59,7 +60,8 @@ when: - result_nmcli_cmd_zone_assignment is defined - result_nmcli_cmd_zone_assignment is changed - - result_nmcli_cmd_zone_assignment.results | selectattr('changed', 'equalto', true) | list | length > 0 + - (result_nmcli_cmd_zone_assignment.results | selectattr('changed', 'equalto', true) | + list | length > 0) - name: '{{{ rule_title }}} - Collect firewalld active zones' ansible.builtin.shell: @@ -82,17 +84,22 @@ - result_firewall_cmd_zones_names.stdout_lines is defined - result_firewall_cmd_zones_names.stdout_lines | length > 0 when: - - ansible_facts.services['firewalld.service'].state == 'running' - - ansible_facts.services['NetworkManager.service'].state == 'running' + - ('firewalld.service' in ansible_facts.services and + ansible_facts.services['firewalld.service'].state == 'running') + - ('NetworkManager.service' in ansible_facts.services and + ansible_facts.services['NetworkManager.service'].state == 'running') - name: '{{{ rule_title }}} - Informative message based on services states' ansible.builtin.assert: that: - - ansible_check_mode or ansible_facts.services['firewalld.service'].state == 'running' - - ansible_check_mode or ansible_facts.services['NetworkManager.service'].state == 'running' + - (ansible_check_mode or ('firewalld.service' in ansible_facts.services and + ansible_facts.services['firewalld.service'].state == 'running')) + - (ansible_check_mode or ('NetworkManager.service' in ansible_facts.services and + ansible_facts.services['NetworkManager.service'].state == 'running')) fail_msg: - firewalld and NetworkManager services are not active. Remediation aborted! - - This remediation could not be applied because it depends on firewalld and NetworkManager services running. + - This remediation could not be applied because it depends on firewalld + - and NetworkManager services running. - The service is not started by this remediation in order to prevent connection issues. success_msg: - {{{ rule_title }}} remediation successfully executed diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/oval/shared.xml index 0370a61865c4..4f652f5c1c22 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/oval/shared.xml @@ -1,3 +1,9 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set sshd_drop_in_include_regex = (sshd_drop_in_dir | replace(".", "\\.")) ~ "/\\*\\.conf" -%}} +{{%- set sshd_main_config_regex = sshd_main_config | replace(".", "\\.") -%}} +{{%- set sshd_drop_in_dir_regex = sshd_drop_in_dir | replace(".", "\\.") -%}} +{{%- set sshd_config_locations_regex = "^(" ~ sshd_main_config_regex ~ "|" ~ sshd_drop_in_dir_regex ~ "/.*\\.conf)$" -%}} {{{ oval_metadata("Ensure SSHD to include the system crypto policy", rule_title=rule_title) }}} @@ -13,8 +19,8 @@ - /etc/ssh/sshd_config - ^[ \t]*(?i)Include(?-i)[ \t]+/etc/ssh/sshd_config\.d/\*.conf$ + {{{ sshd_main_config }}} + ^[ \t]*(?i)Include(?-i)[ \t]+{{{ sshd_drop_in_include_regex }}}$ 1 @@ -25,7 +31,7 @@ - /etc/ssh/(sshd_config|sshd_config\.d/.*\.conf) + {{{ sshd_config_locations_regex }}} ^[ \t]*(?i)Include(?-i)[ \t]+/etc/crypto-policies/back-ends/opensshserver\.config$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/rule.yml b/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/rule.yml index 605707f1e7fb..aa64ffa1f4b7 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/rule.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_include_crypto_policy/rule.yml @@ -6,7 +6,7 @@ description: |- SSHD should follow the system cryptographic policy. In order to accomplish this the SSHD configuration should include the configuration file provided by the system crypto policy. The following line should be present in /etc/ssh/sshd_config or in a file included by this file (a file within the /etc/ssh/sshd_config.d directory): -
Include /etc/crypto-policies/back-ends/opensshserver.config
+
Include {{{ openssh_server_crypto_policy_config_file }}}
rationale: |- @@ -28,8 +28,8 @@ checktext: |-
sudo grep -R "Include /etc/ssh/sshd_config"  /etc/ssh/sshd_config.d/
 
     /etc/ssh/sshd_config:Include /etc/ssh/sshd_config.d/*.conf
-    /etc/ssh/sshd_config.d/50-redhat.conf:Include /etc/crypto-policies/back-ends/opensshserver.config
- If "Include /etc/ssh/sshd_config.d/*.conf" or "Include /etc/crypto-policies/back-ends/opensshserver.config" are not included in the system sshd config or if the file "/etc/ssh/sshd_config.d/50-redhat.conf" is missing, this is a finding. + /etc/ssh/sshd_config.d/50-redhat.conf:Include {{{ openssh_server_crypto_policy_config_file }}}
+ If "Include /etc/ssh/sshd_config.d/*.conf" or "Include {{{ openssh_server_crypto_policy_config_file }}}" are not included in the system sshd config or if the file "/etc/ssh/sshd_config.d/50-redhat.conf" is missing, this is a finding. fixtext: |- Configure the {{{ full_name }}} SSH daemon to use systemwide crypto policies. diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/shared.xml index aff4c3172b75..64801d0bb571 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/shared.xml @@ -1,3 +1,8 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set sshd_main_config_regex = sshd_main_config | replace(".", "\\.") -%}} +{{%- set sshd_drop_in_dir_regex = sshd_drop_in_dir | replace(".", "\\.") -%}} +{{%- set sshd_any_config_regex = "^(" ~ sshd_main_config_regex ~ "|" ~ sshd_drop_in_dir_regex ~ "/.*\\.conf)$" -%}} {{{ oval_metadata("One of the following parameters of the sshd configuration file is set: AllowUsers, DenyUsers, AllowGroups, DenyGroups.", rule_title=rule_title) }}} @@ -27,22 +32,22 @@
- ^\/etc\/ssh\/sshd_config.*$ + {{{ sshd_any_config_regex }}} (?i)^[ ]*AllowUsers[ ]+((?:[^ \n]+[ ]*)+)$ 1 - ^/etc/ssh/sshd_config.*$ + {{{ sshd_any_config_regex }}} (?i)^[ ]*AllowGroups[ ]+((?:[^ \n]+[ ]*)+)$ 1 - ^/etc/ssh/sshd_config.*$ + {{{ sshd_any_config_regex }}} (?i)^[ ]*DenyUsers[ ]+((?:[^ \n]+[ ]*)+)$ 1 - ^/etc/ssh/sshd_config.*$ + {{{ sshd_any_config_regex }}} (?i)^[ ]*DenyGroups[ ]+((?:[^ \n]+[ ]*)+)$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/sle16.xml new file mode 100644 index 000000000000..8dce53384a11 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/oval/sle16.xml @@ -0,0 +1,100 @@ +{{% macro test_sshd_lineinfile(filepath, param, id) %}} +{{%- set object_id = filepath | replace("/", "_") | replace("-", "_") | replace(".", "_") -%}} + + + + + ^{{{ filepath }}} + (?i)^[ ]*{{{ param }}}[ ]+((?:[^ \n]+[ ]*)+)$ + 1 + +{{% endmacro %}} + +{{% macro test_sshd_lineindir(filepath, param, id) %}} +{{%- set object_id = filepath | replace("/", "_") | replace("-", "_") | replace(".", "_") -%}} + + + + + {{{ filepath }}} + .*\.conf$ + (?i)^[ ]*{{{ param }}}[ ]+((?:[^ \n]+[ ]*)+)$ + 1 + +{{% endmacro %}} + + + + {{{ oval_metadata("One of the following parameters of the sshd configuration file is set: AllowUsers, DenyUsers, AllowGroups, DenyGroups.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + {{{ test_sshd_lineinfile("/etc/ssh/sshd_config", "AllowUsers", "test_allow_user_is_configured_etc_ssh_sshdconfig") }}} + {{{ test_sshd_lineinfile("/etc/ssh/sshd_config", "AllowGroups", "test_allow_groups_is_configured_etc_ssh_sshdconfig") }}} + {{{ test_sshd_lineinfile("/etc/ssh/sshd_config", "DenyUsers", "test_deny_users_is_configured_etc_ssh_sshdconfig") }}} + {{{ test_sshd_lineinfile("/etc/ssh/sshd_config", "DenyGroups", "test_deny_groups_is_configured_etc_ssh_sshdconfig") }}} + + {{{ test_sshd_lineinfile("/usr/etc/ssh/sshd_config", "AllowUsers", "test_allow_user_is_configured_usr_etc_ssh_sshdconfig") }}} + {{{ test_sshd_lineinfile("/usr/etc/ssh/sshd_config", "AllowGroups", "test_allow_groups_is_configured_usr_etc_ssh_sshdconfig") }}} + {{{ test_sshd_lineinfile("/usr/etc/ssh/sshd_config", "DenyUsers", "test_deny_users_is_configured_usr_etc_ssh_sshdconfig") }}} + {{{ test_sshd_lineinfile("/usr/etc/ssh/sshd_config", "DenyGroups", "test_deny_groups_is_configured_usr_etc_ssh_sshdconfig") }}} + + {{{ test_sshd_lineindir("/etc/ssh/sshd_config.d", "AllowUsers", "test_allow_user_is_configured_etc_ssh_sshdconfig_dir") }}} + {{{ test_sshd_lineindir("/etc/ssh/sshd_config.d", "AllowGroups", "test_allow_groups_is_configured_etc_ssh_sshdconfig_dir") }}} + {{{ test_sshd_lineindir("/etc/ssh/sshd_config.d", "DenyUsers", "test_deny_users_is_configured_etc_ssh_sshdconfig_dir") }}} + {{{ test_sshd_lineindir("/etc/ssh/sshd_config.d", "DenyGroups", "test_deny_groups_is_configured_etc_ssh_sshdconfig_dir") }}} + + {{{ test_sshd_lineindir("/usr/etc/ssh/sshd_config.d", "AllowUsers", "test_allow_user_is_configured_usr_etc_ssh_sshdconfig_dir") }}} + {{{ test_sshd_lineindir("/usr/etc/ssh/sshd_config.d", "AllowGroups", "test_allow_groups_is_configured_usr_etc_ssh_sshdconfig_dir") }}} + {{{ test_sshd_lineindir("/usr/etc/ssh/sshd_config.d", "DenyUsers", "test_deny_users_is_configured_usr_etc_ssh_sshdconfig_dir") }}} + {{{ test_sshd_lineindir("/usr/etc/ssh/sshd_config.d", "DenyGroups", "test_deny_groups_is_configured_usr_etc_ssh_sshdconfig_dir") }}} + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups.pass.sh index 4a5255dc3c9f..0794a24e80a7 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups.pass.sh @@ -1,4 +1,4 @@ #!/bin/bash -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "AllowGroups testgroup1 testgroup2 testgroup3" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups_etc_ssh_sshd_config_dir.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups_etc_ssh_sshd_config_dir.pass.sh new file mode 100644 index 000000000000..2f5b763698b1 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_groups_etc_ssh_sshd_config_dir.pass.sh @@ -0,0 +1,4 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source common.sh +echo "AllowGroups group" >> /etc/ssh/sshd_config.d/01-complianceascode-reinforce-os-defaults.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users.pass.sh index 9bde6d56cd92..520d0a048faa 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users.pass.sh @@ -1,4 +1,4 @@ #!/bin/bash -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "AllowUsers testuser1 testuser2 testuser3" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_groups.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_groups.pass.sh index 0b35e7039585..6d6bd04f37b6 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_groups.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_groups.pass.sh @@ -1,5 +1,5 @@ #!/bin/bash -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "AllowUsers testuser1 testuser2 testuser3" >> /etc/ssh/sshd_config echo "AllowGroups testgroup1 testgroup2 testgroup3" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_usr_etc_ssh_sshd_config.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_usr_etc_ssh_sshd_config.pass.sh new file mode 100644 index 000000000000..04b090c1a148 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/allow_users_usr_etc_ssh_sshd_config.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source common.sh + +echo "AllowUsers testuser1 testuser2 testuser3" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/common.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/common.sh new file mode 100644 index 000000000000..3c936c2321ce --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/common.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +declare -a SSHD_PATHS=("/etc/ssh/sshd_config") +{{% if product == 'sle16' %}} +SSHD_PATHS+=("/usr/etc/ssh/sshd_config" /usr/etc/ssh/sshd_config.d/* /etc/ssh/sshd_config.d/*) +{{% endif %}} +# clean up configurations +sed -i '/^(Allow|Deny)(Users|Groups).*/d' "${SSHD_PATHS[@]}" + +# restore to defaults for sle16 +{{% if product == 'sle16' %}} +if [ -e "/etc/ssh/sshd_config" ] ; then + rm /etc/ssh/sshd_config +fi +{{% endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_group_in_usr_etc_missing.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_group_in_usr_etc_missing.fail.sh new file mode 100644 index 000000000000..6d23da947c9d --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_group_in_usr_etc_missing.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# remediation = none +# platform = SUSE Linux Enterprise 16 +source common.sh + +touch /etc/ssh/sshd_config +echo "DenyGroups testgroup" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_groups.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_groups.pass.sh index a324d89e397d..16f6e9d3d58f 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_groups.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_groups.pass.sh @@ -1,4 +1,4 @@ #!/bin/bash -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "DenyGroups testgroup1 testgroup2 testgroup3" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users.pass.sh index 35c7f65d7514..adb157baddd2 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users.pass.sh @@ -1,4 +1,4 @@ #!/bin/bash -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "DenyUsers testuser1 testuser2 testuser3" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_groups.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_groups.pass.sh index fc55098614a0..ebe08fb81dea 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_groups.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_groups.pass.sh @@ -1,5 +1,5 @@ #!/bin/bash -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "DenyUsers testuser1 testuser2 testuser3" >> /etc/ssh/sshd_config echo "DenyGroups testgroup1 testgroup2 testgroup3" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_usr_etc_ssh_sshd_config_dir.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_usr_etc_ssh_sshd_config_dir.pass.sh new file mode 100644 index 000000000000..bee5f9991a7c --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/deny_users_usr_etc_ssh_sshd_config_dir.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source common.sh + +echo "DenyUsers user" >> /usr/etc/ssh/sshd_config.d/01-complianceascode-reinforce-os-defaults.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_groups.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_groups.fail.sh index 2f735305d2c5..1f6c11f7a4d1 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_groups.fail.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_groups.fail.sh @@ -1,6 +1,6 @@ #!/bin/bash # remediation = none -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "AllowGroups " >> /etc/ssh/sshd_config echo "DenyGroups " >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_users.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_users.fail.sh index 4affe4b4d598..55ea7d01cde3 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_users.fail.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/empty_users.fail.sh @@ -1,6 +1,6 @@ #!/bin/bash # remediation = none -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh echo "AllowUsers " >> /etc/ssh/sshd_config echo "DenyUsers " >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/no_entry.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/no_entry.fail.sh index bc8a67e7fbad..8ab213a16a18 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/no_entry.fail.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_limit_user_access/tests/no_entry.fail.sh @@ -1,4 +1,4 @@ #!/bin/bash # remediation = none -find /etc/ssh/sshd_config* -type f -print0 | xargs -0 sed -i '/^(Allow|Deny)(Users|Groups).*/d' +source common.sh diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/oval/shared.xml index 918c6c789006..f8056fa2f5fc 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/oval/shared.xml @@ -1,9 +1,9 @@ {{%- set parameter = "RekeyLimit" %}} -{{%- set sshd_config_path = "/etc/ssh/sshd_config" %}} -{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} -{{%- set description = "Ensure " ~ parameter ~ " is configured with the appropriate value in " ~ sshd_config_path %}} +{{%- set sshd_main_config = sshd_main_config_file %}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set description = "Ensure " ~ parameter ~ " is configured with the appropriate value in " ~ sshd_main_config %}} {{%- if sshd_distributed_config == "true" %}} -{{%- set description = description ~ " or in " ~ sshd_config_dir -%}} +{{%- set description = description ~ " or in " ~ sshd_drop_in_dir -%}} {{%- endif %}} @@ -14,15 +14,15 @@ {{{- application_required_or_requirement_unset() }}} {{%- if sshd_distributed_config == "true" %}} - {{{- oval_line_in_directory_criterion(sshd_config_dir, parameter, rule_id=rule_id) | indent(8) }}} + {{{- oval_line_in_directory_criterion(sshd_drop_in_dir, parameter, rule_id=rule_id) | indent(8) }}} - {{{- oval_line_in_file_criterion(sshd_config_path, parameter, rule_id=rule_id) }}} + {{{- oval_line_in_file_criterion(sshd_main_config, parameter, rule_id=rule_id) }}} {{%- else %}} - {{{- oval_line_in_file_criterion(sshd_config_path, parameter, rule_id=rule_id) }}} + {{{- oval_line_in_file_criterion(sshd_main_config, parameter, rule_id=rule_id) }}} {{%- endif %}} @@ -35,7 +35,7 @@
- {{{ sshd_config_path }}} + {{{ sshd_main_config }}} ^[\s]*{{{ parameter }}}[\s]+(.*)$ 1 @@ -54,7 +54,7 @@ - {{{ sshd_config_dir}}} + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[\s]*{{{ parameter }}}[\s]+(.*)$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/rule.yml b/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/rule.yml index d9d64b684db5..70d69a882e6c 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/rule.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_rekey_limit/rule.yml @@ -1,3 +1,5 @@ +{{% set sshd_main_config = sshd_main_config_file %}} +{{% set sshd_drop_in_glob = sshd_config_dir ~ "/*" %}} documentation_complete: true title: 'Force frequent session key renegotiation' @@ -34,24 +36,17 @@ ocil: |- To check if RekeyLimit is set correctly, run the following command: {{% if sshd_distributed_config == "true" %}} -
$ sudo grep RekeyLimit /etc/ssh/sshd_config /etc/ssh/sshd_config.d/*
+
$ sudo grep RekeyLimit {{{ sshd_main_config }}} {{{ sshd_drop_in_glob }}}
{{% else %}} -
$ sudo grep RekeyLimit /etc/ssh/sshd_config
+
$ sudo grep RekeyLimit {{{ sshd_main_config }}}
{{% endif %}} If configured properly, output should be
RekeyLimit {{{ xccdf_value("var_rekey_limit_size") }}} {{{ xccdf_value("var_rekey_limit_time") }}}
fixtext: |- - {{% if sshd_distributed_config == "true" %}} - Configure {{{ full_name }}} to force a frequent session key renegotiation for SSH connections to the server by adding or modifying the following line in the "/etc/ssh/sshd_config.d/00-complianceascode-hardening.conf" file: - {{% else %}} - Configure {{{ full_name }}} to force a frequent session key renegotiation for SSH connections to the server by adding or modifying the following line in the "/etc/ssh/sshd_config" file: - {{% endif %}} - - RekeyLimit {{{ xccdf_value("var_rekey_limit_size") }}} {{{ xccdf_value("var_rekey_limit_time") }}} - - Restart the SSH daemon for the settings to take effect. - - $ sudo systemctl restart sshd.service + {{{ fixtext_sshd_lineinfile( + parameter="RekeyLimit", + value=xccdf_value("var_rekey_limit_size") ~ " " ~ xccdf_value("var_rekey_limit_time"), + config_is_distributed=(sshd_distributed_config == "true")) }}} srg_requirement: '{{{ full_name }}} must force a frequent session key renegotiation for SSH connections to the server.' diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/shared.xml index c4f7f309a530..d5a4b06fe916 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/shared.xml @@ -1,3 +1,6 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set sshd_base_dir = sshd_config_base_dir -%}} {{{ oval_metadata("The SSH idle timeout interval should be set to an @@ -53,7 +56,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)ClientAliveInterval[\s]+(\d+)[\s]*(?:#.*)?$ 1 @@ -67,7 +70,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[\s]*(?i)ClientAliveInterval[\s]+(\d+)[\s]*(?:#.*)?$ 1 @@ -76,7 +79,7 @@ {{%- if product in ["ol8", "ol9"] %}} - /etc/ssh/sshd_config + {{{ sshd_main_config }}} (?i)^\s*Include\s+(.*)$ 1 @@ -84,7 +87,7 @@ - ^(/etc/ssh/(?!/))? + ^({{{ sshd_base_dir }}}/(?!/))? diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/sle16.xml new file mode 100644 index 000000000000..9c2ae2f9a78a --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_idle_timeout/oval/sle16.xml @@ -0,0 +1,153 @@ + + + {{{ oval_metadata("The SSH idle timeout interval should be set to an appropriate value.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + + + + + + + + /etc/ssh/sshd_config + ^[\s]*(?i)ClientAliveInterval[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config + ^[\s]*(?i)ClientAliveInterval[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)ClientAliveInterval[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)ClientAliveInterval[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + 0 + + + + + + + + + + object_sshd_idle_timeout_etc + + + object_sshd_idle_timeout_config_dir + object_sshd_idle_timeout_usr_config_dir + + + + + + + + + + + + object_sshd_idle_timeout_usr + + + object_sshd_idle_timeout_config_dir + object_sshd_idle_timeout_usr_config_dir + + + + + + + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/shared.xml index f1c5911ebcc0..53d51f2abb17 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/shared.xml @@ -1,3 +1,5 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("The SSH number seconds for login grace time should be set to an @@ -44,7 +46,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)LoginGraceTime[\s]+(\d+)[\s]*(?:#.*)?$ 1 @@ -59,7 +61,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[ \t]*(?i)LoginGraceTime(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/sle16.xml new file mode 100644 index 000000000000..23137efd78b8 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/oval/sle16.xml @@ -0,0 +1,153 @@ + + + {{{ oval_metadata("The SSH number seconds for login grace time should be set to an appropriate value.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + + + + + + + + /etc/ssh/sshd_config + ^[\s]*(?i)LoginGraceTime[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config + ^[\s]*(?i)LoginGraceTime[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)LoginGraceTime[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)LoginGraceTime[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + 0 + + + + + + + + + + object_sshd_login_grace_time_etc + + + object_sshd_login_grace_time_config_dir + object_sshd_login_grace_time_usr_config_dir + + + + + + + + + + + + object_sshd_login_grace_time_usr + + + object_sshd_login_grace_time_config_dir + object_sshd_login_grace_time_usr_config_dir + + + + + + + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..a0f68b4a5ccb --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +echo "LoginGraceTime 60" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh new file mode 100644 index 000000000000..b80e3832b591 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +touch /etc/ssh/sshd_config +echo "LoginGraceTime 1" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_usr_etc_sshd_config.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_usr_etc_sshd_config.pass.sh new file mode 100644 index 000000000000..3ed15582de0b --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_usr_etc_sshd_config.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +echo "LoginGraceTime 1" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..1e72b109d85e --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +echo "LoginGraceTime 60" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/include.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/include.sh new file mode 100644 index 000000000000..aee5eb2d0bec --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/include.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +declare -a SSHD_PATHS=("/etc/ssh/sshd_config") +{{% if product == 'sle16' %}} +SSHD_PATHS+=("/usr/etc/ssh/sshd_config" /usr/etc/ssh/sshd_config.d/* /etc/ssh/sshd_config.d/*) +{{% endif %}} +# clean up configurations +sed -i '/^LoginGraceTime.*/d' "${SSHD_PATHS[@]}" + +# restore to defaults for sle16 +{{% if product == 'sle16' %}} +if [ -e "/etc/ssh/sshd_config" ] ; then + rm /etc/ssh/sshd_config +fi +{{% endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/lower_bound.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/lower_bound.pass.sh index f5236501ca01..809d3c1f4659 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/lower_bound.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/lower_bound.pass.sh @@ -1,5 +1,5 @@ #!/bin/bash -# profiles = xccdf_org.ssgproject.content_profile_cis +# profiles = xccdf_org.ssgproject.content_profile_cis,xccdf_org.ssgproject.content_profile_pci-dss-4 # platform = multi_platform_all SSHD_CONFIG="/etc/ssh/sshd_config" diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/no_limit.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/no_limit.fail.sh index 63a0aee97f7d..738969589112 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/no_limit.fail.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/no_limit.fail.sh @@ -1,5 +1,5 @@ #!/bin/bash -# profiles = xccdf_org.ssgproject.content_profile_cis +# profiles = xccdf_org.ssgproject.content_profile_cis,xccdf_org.ssgproject.content_profile_pci-dss-4 # platform = multi_platform_all SSHD_CONFIG="/etc/ssh/sshd_config" diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high.fail.sh index 6d109091b8b9..959f7d699345 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high.fail.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high.fail.sh @@ -1,5 +1,5 @@ #!/bin/bash -# profiles = xccdf_org.ssgproject.content_profile_cis +# profiles = xccdf_org.ssgproject.content_profile_cis,xccdf_org.ssgproject.content_profile_pci-dss-4 # platform = multi_platform_all SSHD_CONFIG="/etc/ssh/sshd_config" diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..35ea7b48f5f4 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +echo "LoginGraceTime 61" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_usr_etc_sshd_config.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_usr_etc_sshd_config.fail.sh new file mode 100644 index 000000000000..7010af0181bd --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_usr_etc_sshd_config.fail.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +echo "LoginGraceTime 61" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_usr_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_usr_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..1cdd63bb777a --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_login_grace_time/tests/too_high_usr_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +source include.sh + +echo "LoginGraceTime 61" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/shared.xml index 117054f7f9eb..ce045e925251 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/shared.xml @@ -1,3 +1,5 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("The SSH MaxAuthTries should be set to an @@ -44,7 +46,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)MaxAuthTries[\s]+(\d+)[\s]*(?:#.*)?$ 1 @@ -59,7 +61,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[ \t]*(?i)MaxAuthTries(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/sle16.xml new file mode 100644 index 000000000000..a9452bfb71aa --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/oval/sle16.xml @@ -0,0 +1,153 @@ + + + {{{ oval_metadata("The SSH MaxAuthTries should be set to an appropriate value.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + + + + + + + + /etc/ssh/sshd_config + ^[\s]*(?i)MaxAuthTries[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config + ^[\s]*(?i)MaxAuthTries[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)MaxAuthTries[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)MaxAuthTries[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + 0 + + + + + + + + + + object_sshd_max_auth_tries_etc + + + object_sshd_max_auth_tries_config_dir + object_sshd_max_auth_tries_usr_config_dir + + + + + + + + + + + + object_sshd_max_auth_tries_usr + + + object_sshd_max_auth_tries_config_dir + object_sshd_max_auth_tries_usr_config_dir + + + + + + + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..4262a6713622 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +echo "MaxAuthTries 4" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh new file mode 100644 index 000000000000..7b327ed220ce --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +touch /etc/ssh/sshd_config +echo "MaxAuthTries 4" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_usr_etc_sshd_config.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_usr_etc_sshd_config.pass.sh new file mode 100644 index 000000000000..d902aa806c16 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_usr_etc_sshd_config.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +echo "MaxAuthTries 4" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..0c0ad79ef4fe --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +echo "MaxAuthTries 4" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/include.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/include.sh new file mode 100644 index 000000000000..9790bbcd68d0 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/include.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +declare -a SSHD_PATHS=("/etc/ssh/sshd_config") +{{% if product == 'sle16' %}} +SSHD_PATHS+=("/usr/etc/ssh/sshd_config" /usr/etc/ssh/sshd_config.d/* /etc/ssh/sshd_config.d/*) +{{% endif %}} +# clean up configurations +sed -i '/^MaxAuthTries.*/d' "${SSHD_PATHS[@]}" + +# restore to defaults for sle16 +{{% if product == 'sle16' %}} +if [ -e "/etc/ssh/sshd_config" ] ; then + rm /etc/ssh/sshd_config +fi +{{% endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..41136d9eb40b --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +echo "MaxAuthTries 20" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_usr_etc_sshd_config.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_usr_etc_sshd_config.fail.sh new file mode 100644 index 000000000000..218e4deb2407 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_usr_etc_sshd_config.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +echo "MaxAuthTries 5" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..753e15c14404 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_auth_tries/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_max_auth_tries_value=4 +source include.sh + +echo "MaxAuthTries 0" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/shared.xml index 0eff641eb037..207e84401ee0 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/shared.xml @@ -1,3 +1,5 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("The SSH number of max sessions should be set to an @@ -44,7 +46,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)MaxSessions[\s]+(\d+)[\s]*(?:#.*)?$ 1 @@ -59,7 +61,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[ \t]*(?i)MaxSessions(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/sle16.xml new file mode 100644 index 000000000000..3acd7b75327d --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/oval/sle16.xml @@ -0,0 +1,153 @@ + + + {{{ oval_metadata("The SSH MaxSessions should be set to an appropriate value.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + + + + + + + + /etc/ssh/sshd_config + ^[\s]*(?i)MaxSessions[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config + ^[\s]*(?i)MaxSessions[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)MaxSessions[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + + + /usr/etc/ssh/sshd_config.d + .*\.conf$ + ^[\s]*(?i)MaxSessions[\s]+(\d+)[\s]*(?:#.*)?$ + 1 + + + + + + + + 0 + + + + + + + + + + object_sshd_max_session_etc + + + object_sshd_max_session_config_dir + object_sshd_max_session_usr_config_dir + + + + + + + + + + + + object_sshd_max_session_usr + + + object_sshd_max_session_config_dir + object_sshd_max_session_usr_config_dir + + + + + + + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..7fdb6123803b --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +echo "MaxSessions 4" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh new file mode 100644 index 000000000000..7f19908dcaea --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +touch /etc/ssh/sshd_config +echo "MaxSessions 4" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_usr_etc_sshd_config.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_usr_etc_sshd_config.pass.sh new file mode 100644 index 000000000000..180bd49bed98 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_usr_etc_sshd_config.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +echo "MaxSessions 4" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..622d36446727 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +echo "MaxSessions 4" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/include.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/include.sh new file mode 100644 index 000000000000..4c8d058295d8 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/include.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +declare -a SSHD_PATHS=("/etc/ssh/sshd_config") +{{% if product == 'sle16' %}} +SSHD_PATHS+=("/usr/etc/ssh/sshd_config" /usr/etc/ssh/sshd_config.d/* /etc/ssh/sshd_config.d/*) +{{% endif %}} +# clean up configurations +sed -i '/^MaxSessions.*/d' "${SSHD_PATHS[@]}" + +# restore to defaults for sle16 +{{% if product == 'sle16' %}} +if [ -e "/etc/ssh/sshd_config" ] ; then + rm /etc/ssh/sshd_config +fi +{{% endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..606d55099420 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +echo "MaxSessions 20" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_usr_etc_sshd_config.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_usr_etc_sshd_config.fail.sh new file mode 100644 index 000000000000..fe6f5a820988 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_usr_etc_sshd_config.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +echo "MaxSessions 5" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..0c07b9608d42 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_max_sessions/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_max_sessions=4 +source include.sh + +echo "MaxSessions 10" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/oval/sle16.xml new file mode 100644 index 000000000000..5ca10680c2a8 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/oval/sle16.xml @@ -0,0 +1,151 @@ + + + {{{ oval_metadata("Ensure 'MaxStartups' is properly configured in SSH configuration files.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + + + + + + + + + + + + + + + ^(/etc/ssh|/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + (sshd_config|.*\.conf)$ + (?i)^\s*MaxStartups\s+(\d+):\d+:\d+\s*$ + 1 + + + ^(/etc/ssh|/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + (sshd_config|.*\.conf)$ + (?i)^\s*MaxStartups\s+\d+:(\d+):\d+\s*$ + 1 + + + ^(/etc/ssh|/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + (sshd_config|.*\.conf)$ + (?i)^\s*MaxStartups\s+\d+:\d+:(\d+)\s*$ + 1 + + + + + + + + + + + + + + + + + ^(/usr/etc/ssh|/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + (sshd_config|.*\.conf)$ + (?i)^\s*MaxStartups\s+(\d+):\d+:\d+\s*$ + 1 + + + ^(/usr/etc/ssh|/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + (sshd_config|.*\.conf)$ + (?i)^\s*MaxStartups\s+\d+:(\d+):\d+\s*$ + 1 + + + ^(/usr/etc/ssh|/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + (sshd_config|.*\.conf)$ + (?i)^\s*MaxStartups\s+\d+:\d+:(\d+)\s*$ + 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..fc6371be73be --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +echo "MaxStartups 10:30:60" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh new file mode 100644 index 000000000000..6905e07c838e --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +touch /etc/ssh/sshd_config +echo "MaxStartups 10:30:60" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_usr_etc_sshd_config.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_usr_etc_sshd_config.pass.sh new file mode 100644 index 000000000000..0a93fe6e32ec --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_usr_etc_sshd_config.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +echo "MaxStartups 10:30:60" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..d2835b507b40 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +echo "MaxStartups 10:30:60" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/include.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/include.sh new file mode 100644 index 000000000000..1f5b69d60b54 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/include.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +declare -a SSHD_PATHS=("/etc/ssh/sshd_config") +{{% if product == 'sle16' %}} +SSHD_PATHS+=("/usr/etc/ssh/sshd_config" /usr/etc/ssh/sshd_config.d/* /etc/ssh/sshd_config.d/*) +{{% endif %}} +# clean up configurations +sed -i '/^MaxStartups.*/d' "${SSHD_PATHS[@]}" + +# restore to defaults for sle16 +{{% if product == 'sle16' %}} +if [ -e "/etc/ssh/sshd_config" ] ; then + rm /etc/ssh/sshd_config +fi +{{% endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..39d6dae3afc2 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +echo "MaxStartups 10:30:61" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_usr_etc_sshd_config.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_usr_etc_sshd_config.fail.sh new file mode 100644 index 000000000000..9bfce7c33062 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_usr_etc_sshd_config.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +echo "MaxStartups 10:29:60" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..a0781811a3a3 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_set_maxstartups/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_sshd_set_maxstartups=10:30:60 +source include.sh + +echo "MaxStartups 11:30:60">> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/bash/shared.sh index 5163c19d87f8..0c9d1b452478 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/bash/shared.sh @@ -2,4 +2,8 @@ {{{ bash_instantiate_variables("sshd_approved_ciphers") }}} -{{{ bash_replace_or_append('/etc/ssh/sshd_config', '^Ciphers', "$sshd_approved_ciphers", '%s %s', cce_identifiers=cce_identifiers) }}} +{{{ bash_sshd_remediation( + parameter="Ciphers", + value="$sshd_approved_ciphers", + config_is_distributed=sshd_distributed_config, + rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/oval/shared.xml index ec798161c368..52ca8097c258 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers/oval/shared.xml @@ -1,3 +1,4 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} {{{ oval_metadata("Limit the ciphers to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -36,7 +37,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)Ciphers(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/ansible/shared.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/ansible/shared.yml index f6dc16cfe0cf..c642d4c55fb4 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/ansible/shared.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/ansible/shared.yml @@ -8,11 +8,5 @@ {{{ ansible_instantiate_variables('sshd_approved_ciphers') }}} {{{ ansible_sshd_set(parameter="Ciphers", value="{{ sshd_approved_ciphers }}", config_is_distributed=sshd_distributed_config, rule_title=rule_title) }}} {{%- else %}} -- name: "Configure sshd to use approved ciphers" - ansible.builtin.lineinfile: - path: /etc/ssh/sshd_config - line: 'Ciphers aes256-ctr,aes192-ctr,aes128-ctr' - state: present - regexp: '^[\s]*[Cc]iphers[\s]+(aes256-ctr(?=[\w,-@]+|$),?)?(aes192-ctr(?=[\w,-@]+|$),?)?(aes128-ctr(?=[\w,-@]+|$),?)?[\s]*(?:#.*)?$' - create: True +{{{ ansible_sshd_set(parameter="Ciphers", value="aes256-ctr,aes192-ctr,aes128-ctr", config_is_distributed=sshd_distributed_config, rule_title=rule_title) }}} {{%- endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/shared.sh index 680c9db7adac..cedc3c42510b 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/shared.sh @@ -1,7 +1,7 @@ # platform = Oracle Linux 7,multi_platform_sle,multi_platform_slmicro -if grep -q -P '^\s*[Cc]iphers\s+' /etc/ssh/sshd_config; then - sed -i 's/^\s*[Cc]iphers.*/Ciphers aes256-ctr,aes192-ctr,aes128-ctr/' /etc/ssh/sshd_config -else - echo "Ciphers aes256-ctr,aes192-ctr,aes128-ctr" >> /etc/ssh/sshd_config -fi +{{{ bash_sshd_remediation( + parameter="Ciphers", + value="aes256-ctr,aes192-ctr,aes128-ctr", + config_is_distributed=sshd_distributed_config, + rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/ubuntu.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/ubuntu.sh index 0c143929b34e..733ffe22da91 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/ubuntu.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/bash/ubuntu.sh @@ -3,7 +3,7 @@ {{%- if product == 'ubuntu2404' %}} sshd_approved_ciphers="aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr" {{%- elif product == 'ubuntu2204' %}} -sshd_approved_ciphers="aes256-ctr,aes256-gcm@openssh.com,aes192-ctr,aes128-ctr,aes128-gcm@openssh.com" +sshd_approved_ciphers="aes256-ctr,aes256-gcm@openssh.com,aes128-ctr,aes128-gcm@openssh.com" {{%- else %}} sshd_approved_ciphers="aes256-ctr,aes192-ctr,aes128-ctr" {{%- endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/shared.xml index b32003ca96ae..452e2c8e1d0f 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/shared.xml @@ -1,3 +1,4 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} {{{ oval_metadata("Limit the ciphers to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -27,7 +28,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)Ciphers(?-i)[\s]+(?=[\w]+)(aes256-ctr(?=[\w,]+|$),?)?(aes192-ctr(?=[\w,]+|$),?)?(aes128-ctr)?[\s]*(?:#.*)?$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/ubuntu.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/ubuntu.xml index 384c5f6589fa..f0dd4e95986a 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/ubuntu.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/oval/ubuntu.xml @@ -1,10 +1,12 @@ {{%- if product == 'ubuntu2404' %}} {{%- set sshd_approved_ciphers = "aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr" %}} {{%- elif product == 'ubuntu2204' %}} -{{%- set sshd_approved_ciphers = "aes256-ctr,aes256-gcm@openssh.com,aes192-ctr,aes128-ctr,aes128-gcm@openssh.com" %}} +{{%- set sshd_approved_ciphers = "aes256-ctr,aes256-gcm@openssh.com,aes128-ctr,aes128-gcm@openssh.com" %}} {{%- else %}} {{%- set sshd_approved_ciphers = "aes256-ctr,aes192-ctr,aes128-ctr" %}} {{%- endif %}} +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("Limit the ciphers to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -43,7 +45,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[ \t]*(?i)ciphers(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 @@ -56,7 +58,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[ \t]*(?i)ciphers(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/rule.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/rule.yml index c04eaa8df1f4..b4be9801bb8c 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/rule.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/rule.yml @@ -1,5 +1,5 @@ {{%- if product == 'ubuntu2204' %}} -{{%- set sshd_approved_ciphers = "aes256-ctr,aes256-gcm@openssh.com,aes192-ctr,aes128-ctr,aes128-gcm@openssh.com" %}} +{{%- set sshd_approved_ciphers = "aes256-ctr,aes256-gcm@openssh.com,aes128-ctr,aes128-gcm@openssh.com" %}} {{%- else %}} {{%- set sshd_approved_ciphers = "aes256-ctr,aes192-ctr,aes128-ctr" %}} {{%- endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/common.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/common.sh index 8e89db1201d7..d819b9d2f29d 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/common.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/common.sh @@ -4,15 +4,15 @@ sshd_approved_ciphers="aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr" sshd_scrambled_ciphers="aes128-gcm@openssh.com,aes256-gcm@openssh.com,aes256-ctr,aes128-ctr" {{%- elif product == "ubuntu2204" %}} -sshd_approved_ciphers="aes256-ctr,aes256-gcm@openssh.com,aes192-ctr,aes128-ctr,aes128-gcm@openssh.com" -sshd_scrambled_ciphers="aes128-gcm@openssh.com,aes256-ctr,aes256-gcm@openssh.com,aes192-ctr,aes128-ctr" +sshd_approved_ciphers="aes256-ctr,aes256-gcm@openssh.com,aes128-ctr,aes128-gcm@openssh.com" +sshd_scrambled_ciphers="aes128-gcm@openssh.com,aes256-ctr,aes256-gcm@openssh.com,aes128-ctr" {{%- else %}} sshd_approved_ciphers="aes256-ctr,aes192-ctr,aes128-ctr" sshd_scrambled_ciphers="aes128-ctr,aes192-ctr,aes256-ctr" {{%- endif %}} for config_file in /etc/ssh/sshd_config /etc/ssh/sshd_config.d/* -do +do [[ -f "$config_file" ]] || continue sed -i "/^Ciphers.*/Id" "$config_file" done diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/correct_reduced_list.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/correct_reduced_list.pass.sh index dec61b6738a7..5e7c65bd472c 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/correct_reduced_list.pass.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_ciphers_ordered_stig/tests/correct_reduced_list.pass.sh @@ -3,4 +3,4 @@ source common.sh -echo "Ciphers aes192-ctr,aes128-ctr" >> /etc/ssh/sshd_config +echo "Ciphers aes128-ctr" >> /etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/ansible/shared.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/ansible/shared.yml index 24f56f81dea1..2ad614753576 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/ansible/shared.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/ansible/shared.yml @@ -4,13 +4,7 @@ # complexity = low # disruption = low -{{% set prefix_conf="^\s*KexAlgorithms\s*" %}} {{% set kex_algos=["ecdh-sha2-nistp256","ecdh-sha2-nistp384","ecdh-sha2-nistp521", "diffie-hellman-group-exchange-sha256"] %}} -- name: "Configure sshd to use FIPS 140-2 approved key exchange algorithms" - ansible.builtin.lineinfile: - path: /etc/ssh/sshd_config - line: 'KexAlgorithms {{{ kex_algos|join(",") }}}' - state: present - regexp: '{{{ prefix_conf }}}' - create: True +{{% set approved_kex_algos = kex_algos|join(",") %}} +{{{ ansible_sshd_set(parameter="KexAlgorithms", value=approved_kex_algos, config_is_distributed=sshd_distributed_config, rule_title=rule_title) }}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/bash/shared.sh index 155d76cd8a52..eda467ef544e 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/bash/shared.sh @@ -9,10 +9,5 @@ KEX_ALGOS="ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellm {{%- if 'ubuntu' in product %}} {{{ bash_sshd_remediation(parameter="KexAlgorithms", value="$KEX_ALGOS", config_is_distributed=sshd_distributed_config, rule_id=rule_id) }}} {{%- else %}} - -if grep -q -P '^\s*KexAlgorithms\s+' /etc/ssh/sshd_config; then - sed -i "s/^\s*KexAlgorithms.*/KexAlgorithms ${KEX_ALGOS}/" /etc/ssh/sshd_config -else - echo "KexAlgorithms ${KEX_ALGOS}" >> /etc/ssh/sshd_config -fi +{{{ bash_sshd_remediation(parameter="KexAlgorithms", value="$KEX_ALGOS", config_is_distributed=sshd_distributed_config, rule_id=rule_id) }}} {{%- endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/shared.xml index 59e39247137d..58ab049c671e 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/shared.xml @@ -1,5 +1,5 @@ {{% if product in ['ol8', 'rhel8'] %}} -{{% set path='/etc/crypto-policies/back-ends/opensshserver.config' %}} +{{% set path=openssh_server_crypto_policy_config_file %}} {{% set prefix_conf="^\s*CRYPTO_POLICY\s*=.*-oKexAlgorithms=" %}} {{% set kex_algos=["ecdh-sha2-nistp256","ecdh-sha2-nistp384", "ecdh-sha2-nistp521","diffie-hellman-group-exchange-sha256", @@ -7,7 +7,7 @@ "diffie-hellman-group18-sha512"] %}} {{% set sufix_conf="(\s.*)?'" %}} {{% elif product in ['ol7', 'sle12', 'sle15', 'slmicro5', 'slmicro6'] %}} -{{% set path='/etc/ssh/sshd_config' %}} +{{% set path=sshd_main_config_file %}} {{% set prefix_conf="^\s*KexAlgorithms\s*" %}} {{% set kex_algos=["ecdh-sha2-nistp256","ecdh-sha2-nistp384","ecdh-sha2-nistp521", "diffie-hellman-group-exchange-sha256"] %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/ubuntu.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/ubuntu.xml index ea32cfadeb56..52fbf0d0bbb3 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/ubuntu.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/oval/ubuntu.xml @@ -3,6 +3,8 @@ {{%- else %}} {{%- set sshd_approved_kexalgorithms = "ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256" %}} {{%- endif %}} +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("Limit the KexAlgorithms to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -41,7 +43,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[ \t]*(?i)KexAlgorithms(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 @@ -54,7 +56,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[ \t]*(?i)KexAlgorithms(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/rule.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/rule.yml index 90e59a76e962..7277f511fce2 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/rule.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_kex_ordered_stig/rule.yml @@ -1,15 +1,15 @@ {{% if product in ['ol8', 'rhel8'] %}} -{{% set path='/etc/crypto-policies/back-ends/opensshserver.config' %}} +{{% set path=openssh_server_crypto_policy_config_file %}} {{% set conf="CRYPTO_POLICY='-oKexAlgorithms=ecdh-sha2-nistp256,ecdh-sha2-nistp384" ~ ",ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256" ~ ",diffie-hellman-group14-sha256,diffie-hellman-group16-sha512" ~ ",diffie-hellman-group18-sha512'" %}} {{% elif product in ['ol7'] %}} -{{% set path='/etc/ssh/sshd_config' %}} +{{% set path=sshd_main_config_file %}} {{% set conf="KexAlgorithms ecdh-sha1-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521" ~ ",diffie-hellman-group-exchange-sha256" %}} {{% elif product in ['sle12', 'sle15', 'slmicro5', 'slmicro6', 'ubuntu2204', 'ubuntu2404'] %}} -{{% set path='/etc/ssh/sshd_config' %}} +{{% set path=sshd_main_config_file %}} {{% set conf="KexAlgorithms ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521" ~ ",diffie-hellman-group-exchange-sha256" %}} {{% endif %}} @@ -46,7 +46,6 @@ references: nist: AC-17(2) srg: SRG-OS-000250-GPOS-00093 stigid@ol7: OL07-00-040712 - stigid@ol8: OL08-00-040342 stigid@sle12: SLES-12-030270 stigid@sle15: SLES-15-040450 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/bash/shared.sh index 34025970a52f..6eee376dbf96 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/bash/shared.sh @@ -2,4 +2,8 @@ {{{ bash_instantiate_variables("sshd_approved_macs") }}} -{{{ bash_replace_or_append('/etc/ssh/sshd_config', '^MACs', "$sshd_approved_macs", '%s %s', cce_identifiers=cce_identifiers) }}} +{{{ bash_sshd_remediation( + parameter="MACs", + value="$sshd_approved_macs", + config_is_distributed=sshd_distributed_config, + rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/oval/shared.xml index c87db511d054..ce8530423105 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs/oval/shared.xml @@ -1,3 +1,4 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} {{{ oval_metadata("Limit the Message Authentication Codes (MACs) to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -46,7 +47,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)MACs(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/ansible/shared.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/ansible/shared.yml index 0acefd7516c1..c3e236f2fcf6 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/ansible/shared.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/ansible/shared.yml @@ -8,11 +8,5 @@ {{{ ansible_instantiate_variables('sshd_approved_macs') }}} {{{ ansible_sshd_set(parameter="Macs", value="{{ sshd_approved_macs }}", config_is_distributed=sshd_distributed_config, rule_title=rule_title) }}} {{%- else %}} -- name: "Configure sshd to use approved MACs" - ansible.builtin.lineinfile: - path: /etc/ssh/sshd_config - line: 'MACs hmac-sha2-512,hmac-sha2-256' - state: present - regexp: '^[\s]*MACs[\s]+(hmac-sha2-512(?=[\w,-@]+|$),?)?(hmac-sha2-256(?=[\w,-@]+|$),?)?[\s]*(?:#.*)?$' - create: True +{{{ ansible_sshd_set(parameter="MACs", value="hmac-sha2-512,hmac-sha2-256", config_is_distributed=sshd_distributed_config, rule_title=rule_title) }}} {{%- endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/bash/shared.sh index 0e0205a98818..83cb8cb6e1c9 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/bash/shared.sh @@ -1,7 +1,7 @@ # platform = Oracle Linux 7,multi_platform_sle,multi_platform_slmicro -if grep -q -P '^\s*MACs\s+' /etc/ssh/sshd_config; then - sed -i 's/^\s*MACs.*/MACs hmac-sha2-512,hmac-sha2-256/' /etc/ssh/sshd_config -else - echo "MACs hmac-sha2-512,hmac-sha2-256" >> /etc/ssh/sshd_config -fi +{{{ bash_sshd_remediation( + parameter="MACs", + value="hmac-sha2-512,hmac-sha2-256", + config_is_distributed=sshd_distributed_config, + rule_id=rule_id) }}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/shared.xml index 1b4781ef43d1..158d94d30e2b 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/shared.xml @@ -1,3 +1,4 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} {{{ oval_metadata("Limit the Message Authentication Codes (MACs) to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -27,7 +28,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)MACs(?-i)[\s]+(?=[\w]+)(hmac-sha2-512(?=[\w,]+|$),?)?(hmac-sha2-256)?[\s]*(?:#.*)?$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/ubuntu.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/ubuntu.xml index cdef6cc539a6..25c618e5ae26 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/ubuntu.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_approved_macs_ordered_stig/oval/ubuntu.xml @@ -5,6 +5,8 @@ {{%- else %}} {{%- set sshd_approved_macs = "hmac-sha2-512,hmac-sha2-256" %}} {{%- endif %}} +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("Limit the Message Authentication Codes (MACs) to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -43,7 +45,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[ \t]*(?i)MACs(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 @@ -56,7 +58,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[ \t]*(?i)MACs(?-i)[ \t]+(.+?)[ \t]*(?:$|#) 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/bash/shared.sh index 9317b23992dc..91548a10db65 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/bash/shared.sh @@ -1,18 +1,21 @@ # platform = multi_platform_all -{{% set target_file = "/etc/ssh/sshd_config.d/sshd_config_original.conf" -%}} -{{% set base_config = "/etc/ssh/sshd_config" -%}} +{{% set base_config = sshd_main_config_file -%}} +{{% set config_dir = sshd_config_dir -%}} +{{% set target_file = config_dir ~ "/sshd_config_original.conf" -%}} +{{% set include_directive = "Include " ~ config_dir ~ "/*.conf" -%}} +{{% set include_regex = "^\\s*Include\\s+" ~ (config_dir | replace(".", "\\.")) ~ "/\\*\\.conf" -%}} if test -f {{{ target_file}}}; then {{{ die("Remediation probably already happened, '" ~ target_file ~ "' already exists, not doing anything.", action="false") }}} -elif grep -Eq '^\s*Include\s+/etc/ssh/sshd_config\.d/\*\.conf' {{{ base_config }}} && ! grep -Eq '^\s*Match\s' {{{ base_config }}}; then +elif grep -Eq '{{{ include_regex }}}' {{{ base_config }}} && ! grep -Eq '^\s*Match\s' {{{ base_config }}}; then {{{ die("Remediation probably already happened, '" ~ base_config ~ "' already contains the include directive.", action="false") }}} else - mkdir -p /etc/ssh/sshd_config.d + mkdir -p {{{ config_dir }}} mv {{{ base_config }}} {{{ target_file }}} cat > {{{ base_config }}} << EOF # To modify the system-wide sshd configuration, create a *.conf file under -# /etc/ssh/sshd_config.d/ which will be automatically included below +# {{{ config_dir }}}/ which will be automatically included below -Include /etc/ssh/sshd_config.d/*.conf +{{{ include_directive }}} EOF fi diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/oval/shared.xml index a0bf190007d0..055f63c20fd2 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_directory_configuration/oval/shared.xml @@ -1,4 +1,4 @@ -{{%- set config_path = "/etc/ssh/sshd_config" %}} +{{%- set config_path = sshd_main_config_file %}} @@ -26,4 +26,3 @@ {{{ oval_line_in_file_test(config_path, "match", missing_parameter_pass=true, rule_id=rule_id) | indent (2) }}} {{{ oval_line_in_file_object(config_path, parameter="match", missing_parameter_pass=true, prefix_regex="^[ \\t]*(?i)", separator_regex="(?-i)\s+\S+", rule_id=rule_id) | indent (2) }}} - diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/ansible/shared.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/ansible/shared.yml index fc2a78f3d79c..82b732e0e66b 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/ansible/shared.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/ansible/shared.yml @@ -6,4 +6,22 @@ {{{ ansible_instantiate_variables("sshd_strong_kex") }}} -{{{ ansible_sshd_set(parameter="KexAlgorithms", value="{{ sshd_strong_kex }}", config_is_distributed=sshd_distributed_config, rule_title=rule_title) }}} +{{%- if product == 'sle16' -%}} + {{{ + ansible_sshd_set_usr( + parameter="KexAlgorithms", + value="{{ sshd_strong_kex }}", + copy_defaults='true', + rule_title=rule_title + ) + }}} +{{%- else -%}} + {{{ + ansible_sshd_set( + parameter="KexAlgorithms", + value="{{ sshd_strong_kex }}", + config_is_distributed=sshd_distributed_config, + rule_title=rule_title + ) + }}} +{{%- endif -%}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/bash/shared.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/bash/shared.sh index e5a56dbfc6ec..de205aedd670 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/bash/shared.sh +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/bash/shared.sh @@ -5,5 +5,22 @@ # disruption = low {{{ bash_instantiate_variables("sshd_strong_kex") }}} -{{{ bash_sshd_remediation(parameter="KexAlgorithms", value="$sshd_strong_kex", config_is_distributed=sshd_distributed_config, rule_id=rule_id) }}} - +{{%- if product == 'sle16' -%}} + {{{ + bash_sshd_remediation_usr( + parameter="KexAlgorithms", + value="$sshd_strong_kex", + copy_defaults=true, + rule_id=rule_id + ) + }}} +{{%- else -%}} + {{{ + bash_sshd_remediation( + parameter="KexAlgorithms", + value="$sshd_strong_kex", + config_is_distributed=sshd_distributed_config, + rule_id=rule_id + ) + }}} +{{%- endif -%}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/shared.xml index 9e097ca403a8..b47bab42117f 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/shared.xml @@ -1,3 +1,5 @@ +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{{ oval_metadata("Limit the Key Exchange Algorithms to those which are FIPS-approved.", rule_title=rule_title) }}} @@ -52,7 +54,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)KexAlgorithms(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ 1 @@ -80,7 +82,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[\s]*(?i)KexAlgorithms(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/sle16.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/sle16.xml new file mode 100644 index 000000000000..d6c8fb2432cf --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/oval/sle16.xml @@ -0,0 +1,171 @@ + + + {{{ oval_metadata("Limit the Key Exchange Algorithms to those which are FIPS-approved.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^/etc/ssh/sshd_config + + + + + + + + + var_sshd_config_kex + + + + + + + + + + + + + + /etc/ssh/sshd_config + ^[\s]*(?i)KexAlgorithms(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ + 1 + + + + + + + + + + var_sshd_config_kex_usr + + + + + + + + + + + + + + /usr/etc/ssh/sshd_config + ^[\s]*(?i)KexAlgorithms(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ + 1 + + + + + + + + + var_sshd_config_kex_config_dir + + + + + + + + ^(/etc/ssh/sshd_config.d|/usr/etc/ssh/sshd_config.d) + .*\.conf$ + ^[\s]*(?i)KexAlgorithms(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ + 1 + + + + + + + + + + + + + + + obj_sshd_config_kex + obj_sshd_config_kex_config_dir + + + + + + + + + + obj_sshd_config_kex_usr + obj_sshd_config_kex_config_dir + + + + + + + + + + + diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..7a794f42a4b1 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 + +source include.sh + +echo "KexAlgorithms curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh new file mode 100644 index 000000000000..9c44448054f2 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_in_usr_etc_sshd_config_present.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 +source include.sh + +touch /etc/ssh/sshd_config +echo "KexAlgorithms curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_usr_etc_sshd_config.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_usr_etc_sshd_config.pass.sh new file mode 100644 index 000000000000..0577aad9bd14 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_usr_etc_sshd_config.pass.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 + +source include.sh + +echo "KexAlgorithms curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh new file mode 100644 index 000000000000..ab24bed01ba1 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/correct_value_usr_etc_sshd_config_drop_in.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 +source include.sh + +echo "KexAlgorithms curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/include.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/include.sh new file mode 100644 index 000000000000..179b7b36e808 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/include.sh @@ -0,0 +1,15 @@ +#!/bin/bash + +declare -a SSHD_PATHS=("/etc/ssh/sshd_config") +{{% if product == 'sle16' %}} +SSHD_PATHS+=("/usr/etc/ssh/sshd_config" /usr/etc/ssh/sshd_config.d/* /etc/ssh/sshd_config.d/*) +{{% endif %}} +# clean up configurations +sed -i '/^KexAlgorithms.*/d' "${SSHD_PATHS[@]}" + +# restore to defaults for sle16 +{{% if product == 'sle16' %}} +if [ -e "/etc/ssh/sshd_config" ] ; then + rm /etc/ssh/sshd_config +fi +{{% endif %}} diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..a1a7b95bafff --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 +source include.sh + +echo "KexAlgorithms diffie-hellman-group-exchange-sha1" >> /etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_usr_etc_sshd_config.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_usr_etc_sshd_config.fail.sh new file mode 100644 index 000000000000..df52b52f680d --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_usr_etc_sshd_config.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 +source include.sh + +echo "KexAlgorithms diffie-hellman-group-exchange-sha1" >> /usr/etc/ssh/sshd_config diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh new file mode 100644 index 000000000000..2a71c2a3bd53 --- /dev/null +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_kex/tests/wrong_value_usr_etc_sshd_config_drop_in.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = sshd_strong_kex=curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256 +source include.sh + +echo "KexAlgorithms diffie-hellman-group-exchange-sha1" >> /usr/etc/ssh/sshd_config.d/01-complianceascode.conf diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_macs/oval/shared.xml b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_macs/oval/shared.xml index cefbd207730f..c50826514438 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_macs/oval/shared.xml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_macs/oval/shared.xml @@ -1,4 +1,5 @@ -{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} {{%- set case_insensitivity_kwargs = dict(prefix_regex="^[ \\t]*(?i)", separator_regex = "(?-i)[ \\t]+") -%}} @@ -56,7 +57,7 @@ - /etc/ssh/sshd_config + {{{ sshd_main_config }}} ^[\s]*(?i)MACs(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ 1 @@ -78,7 +79,7 @@ - /etc/ssh/sshd_config.d + {{{ sshd_drop_in_dir }}} .*\.conf$ ^[\s]*(?i)MACs(?-i)[\s]+([\w,-@]+)+[\s]*(?:#.*)?$ 1 diff --git a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_rng/rule.yml b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_rng/rule.yml index b8240ae667a3..0b43a2b32b1a 100644 --- a/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_rng/rule.yml +++ b/linux_os/guide/services/ssh/ssh_server/sshd_use_strong_rng/rule.yml @@ -1,4 +1,5 @@ documentation_complete: true +{{% set sshd_sysconfig = sshd_sysconfig_file %}} # TODO: The plan is not to need this for RHEL>=8.4 # TODO: Compliant setting is SSH_USE_STRONG_RNG set to 32 or more @@ -6,7 +7,7 @@ documentation_complete: true title: 'SSH server uses strong entropy to seed' description: |- - To set up SSH server to use entropy from a high-quality source, edit the /etc/sysconfig/sshd file. + To set up SSH server to use entropy from a high-quality source, edit the {{{ sshd_sysconfig }}} file. The SSH_USE_STRONG_RNG configuration value determines how many bytes of entropy to use, so make sure that the file contains line
SSH_USE_STRONG_RNG=32
@@ -31,17 +32,17 @@ references: ocil: |- To determine whether the SSH service is configured to use strong entropy seed, - run
$ sudo grep SSH_USE_STRONG_RNG /etc/sysconfig/sshd
+ run
$ sudo grep SSH_USE_STRONG_RNG {{{ sshd_sysconfig }}}
If a line indicating that SSH_USE_STRONG_RNG is set to 32 is returned, then the option is set correctly. ocil_clause: |- - the SSH_USE_STRONG_RNG is not set to 32 in /etc/sysconfig/sshd + the SSH_USE_STRONG_RNG is not set to 32 in {{{ sshd_sysconfig }}} fixtext: |- Configure the {{{ full_name }}} SSH server to use strong entropy. - Add or modify the following line in the "/etc/sysconfig/sshd" file. + Add or modify the following line in the "{{{ sshd_sysconfig }}}" file. SSH_USE_STRONG_RNG=32 @@ -55,7 +56,7 @@ warnings: template: name: shell_lineinfile vars: - path: '/etc/sysconfig/sshd' + path: '{{{ sshd_sysconfig }}}' parameter: 'SSH_USE_STRONG_RNG' value: '32' datatype: int diff --git a/linux_os/guide/services/ssh/sshd_approved_ciphers.var b/linux_os/guide/services/ssh/sshd_approved_ciphers.var index a684560c93d4..6accd5ec24c1 100644 --- a/linux_os/guide/services/ssh/sshd_approved_ciphers.var +++ b/linux_os/guide/services/ssh/sshd_approved_ciphers.var @@ -20,5 +20,6 @@ options: cis_sle12: chacha20-poly1305@openssh.com,aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr cis_sle15: chacha20-poly1305@openssh.com,aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes192-ctr,aes128-ctr cis_ubuntu: chacha20-poly1305@openssh.com,aes128-ctr,aes192-ctr,aes256-ctr,aes128-gcm@openssh.com,aes256-gcm@openssh.com - stig_ubuntu2204: aes256-ctr,aes256-gcm@openssh.com,aes192-ctr,aes128-ctr,aes128-gcm@openssh.com + stig_ubuntu2204: aes256-ctr,aes256-gcm@openssh.com,aes128-ctr,aes128-gcm@openssh.com stig_ol9: aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr + stig_ol8: aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr diff --git a/linux_os/guide/services/ssh/sshd_approved_macs.var b/linux_os/guide/services/ssh/sshd_approved_macs.var index 957ab19dbff8..783f99ee1220 100644 --- a/linux_os/guide/services/ssh/sshd_approved_macs.var +++ b/linux_os/guide/services/ssh/sshd_approved_macs.var @@ -14,6 +14,7 @@ options: stig: hmac-sha2-512,hmac-sha2-256 stig_extended: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 stig_rhel9: hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha2-256,hmac-sha2-512 + stig_al2023: hmac-sha2-512,hmac-sha2-256,hmac-sha1,hmac-sha1-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com default: hmac-sha2-512,hmac-sha2-256,hmac-sha1,hmac-sha1-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com cis_sle12: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 cis_sle15: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 diff --git a/linux_os/guide/services/ssh/sshd_strong_macs.var b/linux_os/guide/services/ssh/sshd_strong_macs.var index 03f8dee10d54..a0a75f544ff8 100644 --- a/linux_os/guide/services/ssh/sshd_strong_macs.var +++ b/linux_os/guide/services/ssh/sshd_strong_macs.var @@ -15,7 +15,7 @@ options: cis_rhel8: -hmac-md5,hmac-md5-96,hmac-ripemd160,hmac-sha1-96,umac-64@openssh.com,hmac-md5-etm@openssh.com,hmac-md5-96-etm@openssh.com,hmac-ripemd160-etm@openssh.com,hmac-sha1-96-etm@openssh.com,umac-64-etm@openssh.com cis_rhel9: -hmac-md5,hmac-md5-96,hmac-ripemd160,hmac-sha1-96,umac-64@openssh.com,hmac-md5-etm@openssh.com,hmac-md5-96-etm@openssh.com,hmac-ripemd160-etm@openssh.com,hmac-sha1-96-etm@openssh.com,umac-64-etm@openssh.com cis_rhel10: -hmac-md5,hmac-md5-96,hmac-ripemd160,hmac-sha1-96,umac-64@openssh.com,hmac-md5-etm@openssh.com,hmac-md5-96-etm@openssh.com,hmac-ripemd160-etm@openssh.com,hmac-sha1-96-etm@openssh.com,umac-64-etm@openssh.com - cis_sle12: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-512,hmac-sha2-256,hmac-ripemd160 + cis_sle12: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 cis_sle15: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,umac-128-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 cis_tencentos4: hmac-sha2-512,hmac-sha2-512-etm@openssh.com,hmac-sha2-256,hmac-sha2-256-etm@openssh.com cis_ubuntu2204: hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 diff --git a/linux_os/guide/services/sssd/package_sssd-ipa_installed/rule.yml b/linux_os/guide/services/sssd/package_sssd-ipa_installed/rule.yml index 039d6d76860e..8b025333bdb2 100644 --- a/linux_os/guide/services/sssd/package_sssd-ipa_installed/rule.yml +++ b/linux_os/guide/services/sssd/package_sssd-ipa_installed/rule.yml @@ -17,10 +17,8 @@ identifiers: references: srg: SRG-OS-000480-GPOS-00227 - -ocil_clause: 'the package is not installed' -ocil: '{{{ ocil_package(package="sssd-ipa") }}}' +{{{ complete_ocil_entry_package_installed("sssd-ipa") }}} template: name: package_installed diff --git a/linux_os/guide/services/sssd/package_sssd_installed/rule.yml b/linux_os/guide/services/sssd/package_sssd_installed/rule.yml index bcb5357c339f..67cf5a89875a 100644 --- a/linux_os/guide/services/sssd/package_sssd_installed/rule.yml +++ b/linux_os/guide/services/sssd/package_sssd_installed/rule.yml @@ -15,6 +15,7 @@ identifiers: cce@rhel8: CCE-82444-1 cce@rhel9: CCE-86083-3 cce@rhel10: CCE-88372-8 + cce@sle16: CCE-96157-3 references: cis-csc: 1,12,15,16,5 @@ -26,10 +27,7 @@ references: nist-csf: PR.AC-1,PR.AC-6,PR.AC-7 srg: SRG-OS-000375-GPOS-00160 - -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="sssd") }}}' +{{{ complete_ocil_entry_package_installed("sssd") }}} template: name: package_installed diff --git a/linux_os/guide/services/sssd/service_sssd_enabled/rule.yml b/linux_os/guide/services/sssd/service_sssd_enabled/rule.yml index e5f043748371..aca8c868e2bd 100644 --- a/linux_os/guide/services/sssd/service_sssd_enabled/rule.yml +++ b/linux_os/guide/services/sssd/service_sssd_enabled/rule.yml @@ -15,6 +15,7 @@ identifiers: cce@rhel8: CCE-82440-9 cce@rhel9: CCE-86088-2 cce@rhel10: CCE-87447-9 + cce@sle16: CCE-95787-8 platform: system_with_kernel and package[sssd] @@ -38,6 +39,7 @@ template: vars: servicename: sssd packagename: sssd-common + packagename@sle16: sssd warnings: - general: diff --git a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/ansible/shared.yml b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/ansible/shared.yml index f8f3cd3e5fff..c7e0de641d6e 100644 --- a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/ansible/shared.yml +++ b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/ansible/shared.yml @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux +# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux,multi_platform_sle # reboot = false # strategy = unknown # complexity = low diff --git a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/bash/shared.sh b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/bash/shared.sh index d228b8cdb0e4..a55a8e9786c9 100644 --- a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/bash/shared.sh +++ b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/bash/shared.sh @@ -1,3 +1,3 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux +# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux,multi_platform_sle {{{ bash_sssd_ldap_config(parameter="ldap_tls_reqcert", value="demand", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/rule.yml b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/rule.yml index f994c2d74b86..aaec9121386b 100644 --- a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/rule.yml +++ b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_configure_tls_reqcert/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel8: CCE-84062-9 cce@rhel9: CCE-86081-7 cce@rhel10: CCE-87985-8 + cce@sle16: CCE-96327-2 references: nist: SC-12(3),CM-6(a) diff --git a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/ansible/shared.yml b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/ansible/shared.yml index 0a1efcabc2aa..1230b6463461 100644 --- a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/ansible/shared.yml +++ b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/ansible/shared.yml @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux +# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux,multi_platform_sle # reboot = false # strategy = unknown # complexity = low diff --git a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/bash/shared.sh b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/bash/shared.sh index 66f05ab54493..4ca2e31d7bc0 100644 --- a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/bash/shared.sh +++ b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/bash/shared.sh @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux +# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux,multi_platform_sle {{{ bash_sssd_ldap_config(parameter="ldap_id_use_start_tls", value="true", rule_id=rule_id) }}} diff --git a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/rule.yml b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/rule.yml index 07df8396e911..5e939e548004 100644 --- a/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/rule.yml +++ b/linux_os/guide/services/sssd/sssd-ldap/sssd_ldap_start_tls/rule.yml @@ -26,6 +26,7 @@ identifiers: cce@rhel8: CCE-82437-5 cce@rhel9: CCE-86082-5 cce@rhel10: CCE-87817-3 + cce@sle16: CCE-96464-3 references: cis-csc: 11,12,14,15,3,8,9 diff --git a/linux_os/guide/services/sssd/sssd_enable_pam_services/rule.yml b/linux_os/guide/services/sssd/sssd_enable_pam_services/rule.yml index adc81468a3ab..2f481f735f4f 100644 --- a/linux_os/guide/services/sssd/sssd_enable_pam_services/rule.yml +++ b/linux_os/guide/services/sssd/sssd_enable_pam_services/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel8: CCE-82446-6 cce@rhel9: CCE-86087-4 cce@rhel10: CCE-90093-6 + cce@sle16: CCE-96039-3 references: cis-csc: 1,12,15,16,5 diff --git a/linux_os/guide/services/usbguard/package_usbguard_installed/rule.yml b/linux_os/guide/services/usbguard/package_usbguard_installed/rule.yml index 891e3b7400ab..c08f6cac97a8 100644 --- a/linux_os/guide/services/usbguard/package_usbguard_installed/rule.yml +++ b/linux_os/guide/services/usbguard/package_usbguard_installed/rule.yml @@ -49,9 +49,7 @@ references: srg: SRG-OS-000378-GPOS-00163,SRG-APP-000141-CTR-000315 stigid@ol8: OL08-00-040139 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="usbguard") }}}' +{{{ complete_ocil_entry_package_installed("usbguard") }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/ansible/shared.yml index 7b15061e7aa4..c1f5e665bf57 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/ansible/shared.yml @@ -1,15 +1,15 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_sle,multi_platform_slmicro,multi_platform_almalinux +# platform = multi_platform_all # reboot = false # strategy = unknown # complexity = low # disruption = medium -{{{ ansible_instantiate_variables("login_banner_text") }}} +{{{ ansible_instantiate_variables("login_banner_contents") }}} {{%- if product not in ['sle15', 'slmicro5', 'slmicro6'] -%}} - name: "{{{ rule_title }}} - Ensure Correct Banner" ansible.builtin.copy: dest: /etc/issue - content: '{{{ ansible_deregexify_banner_etc_issue("login_banner_text") }}}' + content: "{{ login_banner_contents | replace('\\n', '\n') }}\n" {{%- else -%}} - name: {{{ rule_title }}} Ensure issue-generator is Installed ansible.builtin.package: @@ -19,7 +19,7 @@ - name: "{{{ rule_title }}} - Ensure Correct Banner" ansible.builtin.copy: dest: /etc/issue.d/99-oscap-setting - content: '{{{ ansible_deregexify_banner_etc_issue("login_banner_text") }}}' + content: "{{ login_banner_contents | replace('\\n', '\n') }}\n" - name: "{{{ rule_title }}} - Restart issue-generator Service on Issue Configuration Change" ansible.builtin.systemd: diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/bash/shared.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/bash/shared.sh index 177d34e2a3b7..6d0e75f418fa 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/bash/shared.sh @@ -1,31 +1,11 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_rhv,multi_platform_sle,multi_platform_slmicro,multi_platform_ubuntu,multi_platform_almalinux +# platform = multi_platform_all -read -r -d '' login_banner_text <<'EOF' || true -(bash-populate login_banner_text) -EOF - -# Multiple regexes transform the banner regex into a usable banner -# 0 - Remove anchors around the banner text -{{{ bash_deregexify_banner_anchors("login_banner_text") }}} -# 1 - Keep only the first banners if there are multiple -# (dod_banners contains the long and short banner) -{{{ bash_deregexify_multiple_banners("login_banner_text") }}} -# 2 - Add spaces ' '. (Transforms regex for "space or newline" into a " ") -{{{ bash_deregexify_banner_space("login_banner_text") }}} -# 3 - Adds newlines. (Transforms "(?:\[\\n\]+|(?:\\n)+)" into "\n") -{{{ bash_deregexify_banner_newline("login_banner_text", "\\n") }}} -# 4 - Remove any leftover backslash. (From any parenthesis in the banner, for example). -{{{ bash_deregexify_banner_backslash("login_banner_text") }}} -formatted=$(echo "$login_banner_text" | fold -sw 80) +login_banner_contents=$(echo "(bash-populate login_banner_contents)" | sed 's/\\n/\n/g') {{%- if product not in ['sle15', 'slmicro5', 'slmicro6'] %}} -cat </etc/issue -$formatted -EOF +echo "$login_banner_contents" > /etc/issue {{%- else %}} {{{ bash_package_install("issue-generator") }}} -cat </etc/issue.d/99-oscap-setting -$formatted -EOF +echo "$login_banner_contents" > /etc/issue.d/99-oscap-setting {{{ bash_service_command("restart", "issue-generator") }}} {{%- endif -%}} diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_cis_recommended.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_cis_recommended.pass.sh index bc0f5a7a0872..ce541f31864c 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_cis_recommended.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_cis_recommended.pass.sh @@ -2,4 +2,4 @@ # profiles = xccdf_org.ssgproject.content_profile_cis, xccdf_org.ssgproject.content_profile_cis_server_l1, xccdf_org.ssgproject.content_profile_cis_workstation_l1, xccdf_org.ssgproject.content_profile_cis_workstation_l2 # cis_default banner -echo "Authorized uses only. All activity may be monitored and reported." > /etc/issue +echo "Authorized users only. All activity may be monitored and reported." > /etc/issue diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.fail.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.fail.sh index 2b775d15e0eb..0623faba0be8 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.fail.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.fail.sh @@ -1,5 +1,5 @@ #!/bin/bash -# variables = login_banner_text=^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$ +# variables = login_banner_text=^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$,login_banner_contents=I've read & consent to terms in IS user agreem't. # dod_short banner echo "Hello, how are you" > /etc/issue diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.pass.sh index 3b8a52eed5d8..b3ea66d844d9 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/banner_etc_issue_disa_dod_short.pass.sh @@ -1,5 +1,5 @@ #!/bin/bash -# variables = login_banner_text=^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$ +# variables = login_banner_text=^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$,login_banner_contents=I've read & consent to terms in IS user agreem't. # dod_short banner echo "I've read & consent to terms in IS user agreem't." > /etc/issue diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/custom_banner.fail.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/custom_banner.fail.sh new file mode 100644 index 000000000000..59d30c04fdd1 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/custom_banner.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +{{% set ts_custom_banner = "This system is made available by ABCD Inc. exclusively for\nauthorized business use. Use may be monitored for technical or\nregulatory purposes. Do not use this system if you do not consent to\nsuch monitoring.\n\nCe système est mis à disposition par la Société ABCD exclusivement\npour un usage professionnel autorisé. L'utilisation peut faire l'objet\nd'une surveillance pour des raisons techniques ou réglementaires.\nN'utilisez pas ce système si vous n'acceptez pas cette surveillance." %}} +{{% set ts_custom_banner_regex="^This[\s\n]+system[\s\n]+is[\s\n]+made[\s\n]+available[\s\n]+by[\s\n]+ABCD[\s\n]+Inc\.[\s\n]+exclusively[\s\n]+for(?:[\n]+|(?:\\n)+)authorized[\s\n]+business[\s\n]+use\.[\s\n]+Use[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+for[\s\n]+technical[\s\n]+or(?:[\n]+|(?:\\n)+)regulatory[\s\n]+purposes\.[\s\n]+Do[\s\n]+not[\s\n]+use[\s\n]+this[\s\n]+system[\s\n]+if[\s\n]+you[\s\n]+do[\s\n]+not[\s\n]+consent[\s\n]+to(?:[\n]+|(?:\\n)+)such[\s\n]+monitoring\.(?:[\n]+|(?:\\n)+)(?:[\n]+|(?:\\n)+)Ce[\s\n]+système[\s\n]+est[\s\n]+mis[\s\n]+à[\s\n]+disposition[\s\n]+par[\s\n]+la[\s\n]+Société[\s\n]+ABCD[\s\n]+exclusivement(?:[\n]+|(?:\\n)+)pour[\s\n]+un[\s\n]+usage[\s\n]+professionnel[\s\n]+autorisé\.[\s\n]+L'utilisation[\s\n]+peut[\s\n]+faire[\s\n]+l'objet(?:[\n]+|(?:\\n)+)d'une[\s\n]+surveillance[\s\n]+pour[\s\n]+des[\s\n]+raisons[\s\n]+techniques[\s\n]+ou[\s\n]+réglementaires\.(?:[\n]+|(?:\\n)+)N'utilisez[\s\n]+pas[\s\n]+ce[\s\n]+système[\s\n]+si[\s\n]+vous[\s\n]+n'acceptez[\s\n]+pas[\s\n]+cette[\s\n]+surveillance\.$" %}} +# variables = login_banner_contents={{{ ts_custom_banner | replace("\n", "\\n") }}},login_banner_text={{{ ts_custom_banner_regex | replace("\n", "\\n") }}} + +cat > /etc/issue <<'EOF' +This is a test banner. +EOF diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/custom_banner.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/custom_banner.pass.sh new file mode 100644 index 000000000000..4b9bd219e47e --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue/tests/custom_banner.pass.sh @@ -0,0 +1,8 @@ +#!/bin/bash +{{% set ts_custom_banner = "This system is made available by ABCD Inc. exclusively for\nauthorized business use. Use may be monitored for technical or\nregulatory purposes. Do not use this system if you do not consent to\nsuch monitoring.\n\nCe système est mis à disposition par la Société ABCD exclusivement\npour un usage professionnel autorisé. L'utilisation peut faire l'objet\nd'une surveillance pour des raisons techniques ou réglementaires.\nN'utilisez pas ce système si vous n'acceptez pas cette surveillance." %}} +{{% set ts_custom_banner_regex="^This[\s\n]+system[\s\n]+is[\s\n]+made[\s\n]+available[\s\n]+by[\s\n]+ABCD[\s\n]+Inc\.[\s\n]+exclusively[\s\n]+for(?:[\n]+|(?:\\n)+)authorized[\s\n]+business[\s\n]+use\.[\s\n]+Use[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+for[\s\n]+technical[\s\n]+or(?:[\n]+|(?:\\n)+)regulatory[\s\n]+purposes\.[\s\n]+Do[\s\n]+not[\s\n]+use[\s\n]+this[\s\n]+system[\s\n]+if[\s\n]+you[\s\n]+do[\s\n]+not[\s\n]+consent[\s\n]+to(?:[\n]+|(?:\\n)+)such[\s\n]+monitoring\.(?:[\n]+|(?:\\n)+)(?:[\n]+|(?:\\n)+)Ce[\s\n]+système[\s\n]+est[\s\n]+mis[\s\n]+à[\s\n]+disposition[\s\n]+par[\s\n]+la[\s\n]+Société[\s\n]+ABCD[\s\n]+exclusivement(?:[\n]+|(?:\\n)+)pour[\s\n]+un[\s\n]+usage[\s\n]+professionnel[\s\n]+autorisé\.[\s\n]+L'utilisation[\s\n]+peut[\s\n]+faire[\s\n]+l'objet(?:[\n]+|(?:\\n)+)d'une[\s\n]+surveillance[\s\n]+pour[\s\n]+des[\s\n]+raisons[\s\n]+techniques[\s\n]+ou[\s\n]+réglementaires\.(?:[\n]+|(?:\\n)+)N'utilisez[\s\n]+pas[\s\n]+ce[\s\n]+système[\s\n]+si[\s\n]+vous[\s\n]+n'acceptez[\s\n]+pas[\s\n]+cette[\s\n]+surveillance\.$" %}} +# variables = login_banner_contents={{{ ts_custom_banner | replace("\n", "\\n") }}},login_banner_text={{{ ts_custom_banner_regex | replace("\n", "\\n") }}} + +cat > /etc/issue <<'EOF' +{{{ ts_custom_banner }}} +EOF diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/ansible/shared.yml index 828a9a9a0c2d..4a880dccde17 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/ansible/shared.yml @@ -3,9 +3,9 @@ # strategy = unknown # complexity = low # disruption = medium -{{{ ansible_instantiate_variables("remote_login_banner_text") }}} +{{{ ansible_instantiate_variables("remote_login_banner_contents") }}} - name: "{{{ rule_title }}} - ensure correct banner" ansible.builtin.copy: dest: /etc/issue.net - content: '{{{ ansible_deregexify_banner_etc_issue("remote_login_banner_text") }}}' + content: "{{ remote_login_banner_contents | replace('\\n', '\n') }}\n" diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/bash/shared.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/bash/shared.sh index 52eda0b4a9b6..bef6be11259b 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/bash/shared.sh @@ -1,21 +1,4 @@ # platform = multi_platform_all -{{{ bash_instantiate_variables("remote_login_banner_text") }}} - -# Multiple regexes transform the banner regex into a usable banner -# 0 - Remove anchors around the banner text -{{{ bash_deregexify_banner_anchors("remote_login_banner_text") }}} -# 1 - Keep only the first banners if there are multiple -# (dod_banners contains the long and short banner) -{{{ bash_deregexify_multiple_banners("remote_login_banner_text") }}} -# 2 - Add spaces ' '. (Transforms regex for "space or newline" into a " ") -{{{ bash_deregexify_banner_space("remote_login_banner_text") }}} -# 3 - Adds newlines. (Transforms "(?:\[\\n\]+|(?:\\n)+)" into "\n") -{{{ bash_deregexify_banner_newline("remote_login_banner_text", "\\n") }}} -# 4 - Remove any leftover backslash. (From any parenthesis in the banner, for example). -{{{ bash_deregexify_banner_backslash("remote_login_banner_text") }}} -formatted=$(echo "$remote_login_banner_text" | fold -sw 80) - -cat </etc/issue.net -$formatted -EOF +remote_login_banner_contents=$(echo "(bash-populate remote_login_banner_contents)" | sed 's/\\n/\n/g') +echo "$remote_login_banner_contents" > /etc/issue.net diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_cis_recommended.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_cis_recommended.pass.sh index a4d328e76565..5d58cbc2588e 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_cis_recommended.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_cis_recommended.pass.sh @@ -2,4 +2,4 @@ # profiles = xccdf_org.ssgproject.content_profile_cis # cis_default banner -echo "Authorized uses only. All activity may be monitored and reported." > /etc/issue.net +echo "Authorized users only. All activity may be monitored and reported." > /etc/issue.net diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_mingetty.fail.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_mingetty.fail.sh new file mode 100644 index 000000000000..4730f4332b42 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_mingetty.fail.sh @@ -0,0 +1,4 @@ +#!/bin/bash +# variables = remote_login_banner_text=^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$,remote_login_banner_contents=Authorized users only. All activity may be monitored and reported. + +echo "System name \s version \s " > /etc/issue.net diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_osid.fail.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_osid.fail.sh new file mode 100644 index 000000000000..c579e36e5942 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_osid.fail.sh @@ -0,0 +1,4 @@ +#!/bin/bash +# variables = remote_login_banner_text=^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$,remote_login_banner_contents=Authorized users only. All activity may be monitored and reported. + +echo "This system is rhel." > /etc/issue.net diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_recommended.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_recommended.pass.sh new file mode 100644 index 000000000000..a78e272e8d67 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_issue_net/tests/banner_etc_issue_net_recommended.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# variables = remote_login_banner_text=^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$,remote_login_banner_contents=Authorized users only. All activity may be monitored and reported. + +# cis_default banner +echo "Authorized users only. All activity may be monitored and reported." > /etc/issue.net diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/ansible/shared.yml index 252618dedd57..8a3cc3128262 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/ansible/shared.yml @@ -3,9 +3,9 @@ # strategy = unknown # complexity = low # disruption = medium -{{{ ansible_instantiate_variables("motd_banner_text") }}} +{{{ ansible_instantiate_variables("motd_banner_contents") }}} - name: "{{{ rule_title }}} - ensure correct banner" ansible.builtin.copy: dest: /etc/motd - content: '{{{ ansible_deregexify_banner_etc_issue("motd_banner_text") }}}' + content: "{{ motd_banner_contents | replace('\\n', '\n') }}\n" diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/bash/shared.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/bash/shared.sh index f8f5e59a2420..1f8d36fe3ce6 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/bash/shared.sh @@ -1,21 +1,4 @@ -# platform = multi_platform_fedora,multi_platform_ol,multi_platform_rhel,multi_platform_rhv,multi_platform_sle,multi_platform_slmicro,multi_platform_ubuntu,multi_platform_almalinux +# platform = multi_platform_all -{{{ bash_instantiate_variables("motd_banner_text") }}} - -# Multiple regexes transform the banner regex into a usable banner -# 0 - Remove anchors around the banner text -{{{ bash_deregexify_banner_anchors("motd_banner_text") }}} -# 1 - Keep only the first banners if there are multiple -# (dod_banners contains the long and short banner) -{{{ bash_deregexify_multiple_banners("motd_banner_text") }}} -# 2 - Add spaces ' '. (Transforms regex for "space or newline" into a " ") -{{{ bash_deregexify_banner_space("motd_banner_text") }}} -# 3 - Adds newlines. (Transforms "(?:\[\\n\]+|(?:\\n)+)" into "\n") -{{{ bash_deregexify_banner_newline("motd_banner_text", "\\n") }}} -# 4 - Remove any leftover backslash. (From any parenthesis in the banner, for example). -{{{ bash_deregexify_banner_backslash("motd_banner_text") }}} -formatted=$(echo "$motd_banner_text" | fold -sw 80) - -cat </etc/motd -$formatted -EOF +motd_banner_contents=$(echo "(bash-populate motd_banner_contents)" | sed 's/\\n/\n/g') +echo "$motd_banner_contents" > /etc/motd diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/oval/shared.xml b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/oval/shared.xml index be13d1d65419..dbfadc63d9ec 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/oval/shared.xml @@ -15,7 +15,7 @@ /etc/motd - + diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_cis_recommended.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_cis_recommended.pass.sh index 1cacc28d7328..049470d872e4 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_cis_recommended.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_cis_recommended.pass.sh @@ -2,4 +2,4 @@ # profiles = xccdf_org.ssgproject.content_profile_cis, xccdf_org.ssgproject.content_profile_cis_server_l1, xccdf_org.ssgproject.content_profile_cis_workstation_l1, xccdf_org.ssgproject.content_profile_cis_workstation_l2 # cis_default banner -echo "Authorized uses only. All activity may be monitored and reported." > /etc/motd +echo "Authorized users only. All activity may be monitored and reported." > /etc/motd diff --git a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_default.pass.sh b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_default.pass.sh index 8aeedeb1b322..4b7e6447efc9 100644 --- a/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_default.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/banner_etc_motd/tests/banner_etc_motd_default.pass.sh @@ -1,4 +1,4 @@ #!/bin/bash -# default banner from motd_banner_text.var -echo "Authorized uses only. All activity may be monitored and reported." > /etc/motd +# default banner from motd_banner_contents.var +echo "Authorized users only. All activity may be monitored and reported." > /etc/motd diff --git a/linux_os/guide/system/accounts/accounts-banners/dconf_login_banner_contents.var b/linux_os/guide/system/accounts/accounts-banners/dconf_login_banner_contents.var new file mode 100644 index 000000000000..bd366b4da215 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/dconf_login_banner_contents.var @@ -0,0 +1,25 @@ +documentation_complete: true + +title: 'Login Banner Verbiage' + +description: >- + Enter an appropriate login banner text for your organization. + This variable is used only in remediations. + In OVAL checks a regular expression specified in the login_banner_text variable is used instead. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + +type: string + +operator: equals + +interactive: true + +options: + default: 'Authorized users only. All activity may be monitored and reported.' +# CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. +# There is a generic content in case a remediation is necessary. + cis_default: 'Authorized uses only. All activity may be monitored and reported.' + dod_default: 'You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. By using this IS (which includes any device attached to this IS), you consent to the following conditions:\n-The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations.\n-At any time, the USG may inspect and seize data stored on this IS.\n-Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose.\n-This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy.\n-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details.' + dod_short: 'I''ve read & consent to terms in IS user agreem''t.' + dss_odaa_default: 'Use of this or any other DoD interest computer system constitutes consent to monitoring at all times. This is a DoD interest computer system. All DoD interest computer systems and related equipment are intended for the communication, transmission, processing, and storage of official U.S. Government or other authorized information only. All DoD interest computer systems are subject to monitoring at all times to ensure proper functioning of equipment and systems including security devices and systems, to prevent unauthorized use and violations of statutes and security regulations, to deter criminal activity, and for other similar purposes. Any user of a DoD interest computer system should be aware that any information placed in the system is subject to monitoring and is not subject to any expectation of privacy. If monitoring of this or any other DoD interest computer system reveals possible evidence of violation of criminal statutes, this evidence and any other related information, including identification information about the user, may be provided to law enforcement officials. If monitoring of this or any other DoD interest computer systems reveals violations of security regulations or unauthorized use, employees who violate security regulations or make unauthorized use of DoD interest computer systems are subject to appropriate disciplinary action. Use of this or any other DoD interest computer system constitutes consent to monitoring at all times.' + usgcb_default: '-- WARNING -- This system is for the use of authorized users only. Individuals using this computer system without authority or in excess of their authority are subject to having all their activities on this system monitored and recorded by system personnel. Anyone using this system expressly consents to such monitoring and is advised that if such monitoring reveals possible evidence of criminal activity system personal may provide the evidence of such monitoring to law enforcement officials.' diff --git a/linux_os/guide/system/accounts/accounts-banners/dconf_login_banner_text.var b/linux_os/guide/system/accounts/accounts-banners/dconf_login_banner_text.var new file mode 100644 index 000000000000..0f838c065d56 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/dconf_login_banner_text.var @@ -0,0 +1,33 @@ +documentation_complete: true + +title: Dconf GDM Login Banner Verbiage Regular Expression + +description: >- + Enter an appropriate login banner regular expression for your organization. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + This regular expression is used only in OVAL checks. + In remediations the login_banner_contents variable is used instead. + For information about how to generate banner regular expression for your tailoring files, + see: https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions + +type: string + +operator: equals + +interactive: true + +options: +# CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. +# There is a generic content in case a remediation is necessary. +# How to generate banner regex: https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions +# CIS recommends to use "Authorized uses only" for Dconf GDM requirements which is +# different text that in other login banners where CIS recommends "Authorized users only". + cis_banners: ^(Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.|^(?!.*(\\|fedora|rhel|sle|ubuntu)).*)$ + cis_default: ^Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ +# First banner in 'dod_banners' must be the banner for desktop, laptop, and other devices which accommodate banners of 1300 characters + dod_banners: ^(You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U\.S\.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG\-authorized[\s\n]+use[\s\n]+only\.[\s\n]+By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(?:[\n]+|(?:\\n)+)\-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations\.(?:[\n]+|(?:\\n)+)\-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS\.(?:[\n]+|(?:\\n)+)\-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG\-authorized[\s\n]+purpose\.(?:[\n]+|(?:\\n)+)\-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e\.g\.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests\-\-not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy\.(?:[\n]+|(?:\\n)+)\-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants\.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential\.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details\.|I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.)$ + dod_default: ^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U\.S\.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG\-authorized[\s\n]+use[\s\n]+only\.[\s\n]+By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(?:[\n]+|(?:\\n)+)\-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations\.(?:[\n]+|(?:\\n)+)\-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS\.(?:[\n]+|(?:\\n)+)\-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG\-authorized[\s\n]+purpose\.(?:[\n]+|(?:\\n)+)\-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e\.g\.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests\-\-not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy\.(?:[\n]+|(?:\\n)+)\-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants\.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential\.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details\.$ + dod_short: ^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$ + dss_odaa_default: ^Use[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+constitutes[\s\n]+consent[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times\.[\s\n]+This[\s\n]+is[\s\n]+a[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system\.[\s\n]+All[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+and[\s\n]+related[\s\n]+equipment[\s\n]+are[\s\n]+intended[\s\n]+for[\s\n]+the[\s\n]+communication,[\s\n]+transmission,[\s\n]+processing,[\s\n]+and[\s\n]+storage[\s\n]+of[\s\n]+official[\s\n]+U\.S\.[\s\n]+Government[\s\n]+or[\s\n]+other[\s\n]+authorized[\s\n]+information[\s\n]+only\.[\s\n]+All[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times[\s\n]+to[\s\n]+ensure[\s\n]+proper[\s\n]+functioning[\s\n]+of[\s\n]+equipment[\s\n]+and[\s\n]+systems[\s\n]+including[\s\n]+security[\s\n]+devices[\s\n]+and[\s\n]+systems,[\s\n]+to[\s\n]+prevent[\s\n]+unauthorized[\s\n]+use[\s\n]+and[\s\n]+violations[\s\n]+of[\s\n]+statutes[\s\n]+and[\s\n]+security[\s\n]+regulations,[\s\n]+to[\s\n]+deter[\s\n]+criminal[\s\n]+activity,[\s\n]+and[\s\n]+for[\s\n]+other[\s\n]+similar[\s\n]+purposes\.[\s\n]+Any[\s\n]+user[\s\n]+of[\s\n]+a[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+should[\s\n]+be[\s\n]+aware[\s\n]+that[\s\n]+any[\s\n]+information[\s\n]+placed[\s\n]+in[\s\n]+the[\s\n]+system[\s\n]+is[\s\n]+subject[\s\n]+to[\s\n]+monitoring[\s\n]+and[\s\n]+is[\s\n]+not[\s\n]+subject[\s\n]+to[\s\n]+any[\s\n]+expectation[\s\n]+of[\s\n]+privacy\.[\s\n]+If[\s\n]+monitoring[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+reveals[\s\n]+possible[\s\n]+evidence[\s\n]+of[\s\n]+violation[\s\n]+of[\s\n]+criminal[\s\n]+statutes,[\s\n]+this[\s\n]+evidence[\s\n]+and[\s\n]+any[\s\n]+other[\s\n]+related[\s\n]+information,[\s\n]+including[\s\n]+identification[\s\n]+information[\s\n]+about[\s\n]+the[\s\n]+user,[\s\n]+may[\s\n]+be[\s\n]+provided[\s\n]+to[\s\n]+law[\s\n]+enforcement[\s\n]+officials\.[\s\n]+If[\s\n]+monitoring[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+reveals[\s\n]+violations[\s\n]+of[\s\n]+security[\s\n]+regulations[\s\n]+or[\s\n]+unauthorized[\s\n]+use,[\s\n]+employees[\s\n]+who[\s\n]+violate[\s\n]+security[\s\n]+regulations[\s\n]+or[\s\n]+make[\s\n]+unauthorized[\s\n]+use[\s\n]+of[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+appropriate[\s\n]+disciplinary[\s\n]+action\.[\s\n]+Use[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+constitutes[\s\n]+consent[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times\.$ + usgcb_default: ^\-\-[\s\n]+WARNING[\s\n]+\-\-[\s\n]+This[\s\n]+system[\s\n]+is[\s\n]+for[\s\n]+the[\s\n]+use[\s\n]+of[\s\n]+authorized[\s\n]+users[\s\n]+only\.[\s\n]+Individuals[\s\n]+using[\s\n]+this[\s\n]+computer[\s\n]+system[\s\n]+without[\s\n]+authority[\s\n]+or[\s\n]+in[\s\n]+excess[\s\n]+of[\s\n]+their[\s\n]+authority[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+having[\s\n]+all[\s\n]+their[\s\n]+activities[\s\n]+on[\s\n]+this[\s\n]+system[\s\n]+monitored[\s\n]+and[\s\n]+recorded[\s\n]+by[\s\n]+system[\s\n]+personnel\.[\s\n]+Anyone[\s\n]+using[\s\n]+this[\s\n]+system[\s\n]+expressly[\s\n]+consents[\s\n]+to[\s\n]+such[\s\n]+monitoring[\s\n]+and[\s\n]+is[\s\n]+advised[\s\n]+that[\s\n]+if[\s\n]+such[\s\n]+monitoring[\s\n]+reveals[\s\n]+possible[\s\n]+evidence[\s\n]+of[\s\n]+criminal[\s\n]+activity[\s\n]+system[\s\n]+personal[\s\n]+may[\s\n]+provide[\s\n]+the[\s\n]+evidence[\s\n]+of[\s\n]+such[\s\n]+monitoring[\s\n]+to[\s\n]+law[\s\n]+enforcement[\s\n]+officials\.$ + default: ^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/ansible/shared.yml index 33d95980ded9..38bd849f78c4 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/ansible/shared.yml @@ -3,7 +3,7 @@ # strategy = unknown # complexity = low # disruption = medium -{{{ ansible_instantiate_variables("login_banner_text") }}} +{{{ ansible_instantiate_variables("dconf_login_banner_contents") }}} - name: "{{{ rule_title }}}" ansible.builtin.file: @@ -32,7 +32,7 @@ dest: /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings section: org/gnome/login-screen option: banner-message-text - value: '{{{ ansible_deregexify_banner_dconf_gnome("login_banner_text") }}}' + value: '''{{ dconf_login_banner_contents }}''' create: yes no_extra_spaces: yes register: result_ini diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/shared.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/shared.sh index 930d5fe18189..c686cbe1dbf3 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/shared.sh @@ -1,22 +1,5 @@ # platform = multi_platform_all -login_banner_text='(bash-populate login_banner_text)' - -# Multiple regexes transform the banner regex into a usable banner -# 0 - Remove anchors around the banner text -{{{ bash_deregexify_banner_anchors("login_banner_text") }}} -# 1 - Keep only the first banners if there are multiple -# (dod_banners contains the long and short banner) -{{{ bash_deregexify_multiple_banners("login_banner_text") }}} -# 2 - Add spaces ' '. (Transforms regex for "space or newline" into a " ") -{{{ bash_deregexify_banner_space("login_banner_text") }}} -# 3 - Adds newline "tokens". (Transforms "(?:\[\\n\]+|(?:\\n)+)" into "(n)*") -{{{ bash_deregexify_banner_newline("login_banner_text", "(n)*") }}} -# 4 - Remove any leftover backslash. (From any parenthesis in the banner, for example). -{{{ bash_deregexify_banner_backslash("login_banner_text") }}} -# 5 - Removes the newline "token." (Transforms them into newline escape sequences "\n"). -# ( Needs to be done after 4, otherwise the escapce sequence will become just "n". -{{{ bash_deregexify_banner_newline_token("login_banner_text")}}} - -{{{ bash_dconf_settings("org/gnome/login-screen", "banner-message-text", "'${login_banner_text}'", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} +dconf_login_banner_contents=$(echo "(bash-populate dconf_login_banner_contents)" ) +{{{ bash_dconf_settings("org/gnome/login-screen", "banner-message-text", "'${dconf_login_banner_contents}'", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/login-screen", "banner-message-text", dconf_gdm_dir, "00-security-settings-lock") }}} diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/ubuntu.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/ubuntu.sh index 57e577df79b9..4d38311e4e43 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/ubuntu.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/bash/ubuntu.sh @@ -1,28 +1,11 @@ # platform = multi_platform_ubuntu -{{{ bash_instantiate_variables("login_banner_text") }}} - -# Multiple regexes transform the banner regex into a usable banner -# 0 - Remove anchors around the banner text -{{{ bash_deregexify_banner_anchors("login_banner_text") }}} -# 1 - Keep only the first banners if there are multiple -# (dod_banners contains the long and short banner) -{{{ bash_deregexify_multiple_banners("login_banner_text") }}} -# 2 - Add spaces ' '. (Transforms regex for "space or newline" into a " ") -{{{ bash_deregexify_banner_space("login_banner_text") }}} -# 3 - Adds newline "tokens". (Transforms "(?:\[\\n\]+|(?:\\n)+)" into "(n)*") -{{{ bash_deregexify_banner_newline("login_banner_text", "(n)*") }}} -# 4 - Remove any leftover backslash. (From any parenthesis in the banner, for example). -{{{ bash_deregexify_banner_backslash("login_banner_text") }}} -# 5 - Removes the newline "token." (Transforms them into newline escape sequences "\n"). -# ( Needs to be done after 4, otherwise the escapce sequence will become just "n". -{{{ bash_deregexify_banner_newline_token("login_banner_text")}}} - {{{ bash_enable_dconf_user_profile(profile="user", database="local") }}} {{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +dconf_login_banner_contents=$(echo "(bash-populate dconf_login_banner_contents)" ) # Will do both approach, since we plan to migrate to checks over dconf db. That way, future updates of the tool # will pass the check even if we decide to check only for the dconf db path. -{{{ set_config_file("/etc/gdm3/greeter.dconf-defaults", "banner-message-text", value="'${login_banner_text}'", create='no', insert_after="\[org/gnome/login-screen\]", insert_before="", separator="=", separator_regex="", prefix_regex="^\s*", rule_id=rule_id) }}} -{{{ bash_dconf_settings("org/gnome/login-screen", "banner-message-text", "'${login_banner_text}'", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} +{{{ set_config_file("/etc/gdm3/greeter.dconf-defaults", "banner-message-text", value="'${dconf_login_banner_contents}'", create='no', insert_after="\[org/gnome/login-screen\]", insert_before="", separator="=", separator_regex="", prefix_regex="^\s*", rule_id=rule_id) }}} +{{{ bash_dconf_settings("org/gnome/login-screen", "banner-message-text", "'${dconf_login_banner_contents}'", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} # No need to use dconf update, since bash_dconf_settings does that already diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/shared.xml b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/shared.xml index 0a6b6a9c829f..4b957be47881 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/shared.xml @@ -39,9 +39,9 @@
- + - +
diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/ubuntu.xml b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/ubuntu.xml index 3baac57772f3..208572acae53 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/ubuntu.xml +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/oval/ubuntu.xml @@ -37,9 +37,9 @@ - + - +
diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig.pass.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig.pass.sh index 6ff96441acd3..c2caa11732c3 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig.pass.sh @@ -7,11 +7,39 @@ source $SHARED/dconf_test_functions.sh install_dconf_and_gdm_if_needed -login_banner_text="(^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U.S.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG-authorized[\s\n]+use[\s\n]+only.[\s\n]*By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(\\n)*(\n)*-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations.(\\n)*(\n)*-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS.(\\n)*(\n)*-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG-authorized[\s\n]+purpose.(\\n)*(\n)*-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e.g.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests--not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy.(\\n)*(\n)*-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details.$|^I\'ve[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem\'t$)" -expanded=$(echo "$login_banner_text" | sed 's/(\\\\\x27)\*/\\\x27/g;s/(\\\x27)\*//g;s/(\\\\\x27)/tamere/g;s/(\^\(.*\)\$|.*$/\1/g;s/\[\\s\\n\][+*]/ /g;s/\\//g;s/(n)\*/\\n/g;s/\x27/\\\x27/g;') +login_banner_contents=$(cat <<'EOF' +You are accessing a U.S. Government (USG) Information System (IS) that is +provided for USG-authorized use only. By using this IS (which includes any +device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for +purposes including, but not limited to, penetration testing, COMSEC monitoring, +network operations and defense, personnel misconduct (PM), law enforcement +(LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject +to routine monitoring, interception, and search, and may be disclosed or used +for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) +to protect USG interests--not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE +or CI investigative searching or monitoring of the content of privileged +communications, or work product, related to personal representation or services +by attorneys, psychotherapists, or clergy, and their assistants. Such +communications and work product are private and confidential. See User +Agreement for details. +EOF +) + +# replace two subsequent newlines with a \n\n and single newlines with a space +login_banner_text_escaped=$(printf '%s' "$login_banner_contents" | sed ':a;N;$!ba;s/\n\n/\\n\\n/g;s/\n/ /g') clean_dconf_settings -add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'${expanded}'" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'${login_banner_text_escaped}'" "{{{ dconf_gdm_dir }}}" "00-security-settings" add_dconf_lock "org/gnome/login-screen" "banner-message-text" "{{{ dconf_gdm_dir }}}" "00-security-settings-lock" dconf update diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig_wrong_db.fail.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig_wrong_db.fail.sh index 9969fcc6f0d2..c8077d767d35 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig_wrong_db.fail.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/correct_value_stig_wrong_db.fail.sh @@ -7,11 +7,39 @@ source $SHARED/dconf_test_functions.sh install_dconf_and_gdm_if_needed -login_banner_text="(^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U.S.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG-authorized[\s\n]+use[\s\n]+only.[\s\n]*By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(\\n)*(\n)*-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations.(\\n)*(\n)*-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS.(\\n)*(\n)*-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG-authorized[\s\n]+purpose.(\\n)*(\n)*-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e.g.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests--not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy.(\\n)*(\n)*-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details.$|^I\'ve[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem\'t$)" -expanded=$(echo "$login_banner_text" | sed 's/(\\\\\x27)\*/\\\x27/g;s/(\\\x27)\*//g;s/(\\\\\x27)/tamere/g;s/(\^\(.*\)\$|.*$/\1/g;s/\[\\s\\n\][+*]/ /g;s/\\//g;s/(n)\*/\\n/g;s/\x27/\\\x27/g;') +login_banner_contents=$(cat <<'EOF' +You are accessing a U.S. Government (USG) Information System (IS) that is +provided for USG-authorized use only. By using this IS (which includes any +device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for +purposes including, but not limited to, penetration testing, COMSEC monitoring, +network operations and defense, personnel misconduct (PM), law enforcement +(LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject +to routine monitoring, interception, and search, and may be disclosed or used +for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) +to protect USG interests--not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE +or CI investigative searching or monitoring of the content of privileged +communications, or work product, related to personal representation or services +by attorneys, psychotherapists, or clergy, and their assistants. Such +communications and work product are private and confidential. See User +Agreement for details. +EOF +) + +# replace two subsequent newlines with a \n\n and single newlines with a space +login_banner_text_escaped=$(printf '%s' "$login_banner_contents" | sed ':a;N;$!ba;s/\n\n/\\n\\n/g;s/\n/ /g') clean_dconf_settings -add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'${expanded}'" "dummy.d" "00-security-settings" +add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'${login_banner_text_escaped}'" "dummy.d" "00-security-settings" add_dconf_lock "org/gnome/login-screen" "banner-message-text" "dummy.d" "00-security-settings-lock" dconf update diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/missing_value_stig.fail.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/missing_value_stig.fail.sh index c316d7c8f74b..56eb33cd1061 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/missing_value_stig.fail.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/missing_value_stig.fail.sh @@ -7,8 +7,8 @@ source $SHARED/dconf_test_functions.sh install_dconf_and_gdm_if_needed -# login_banner_text="(^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U.S.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG-authorized[\s\n]+use[\s\n]+only.[\s\n]*By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(\\n)*(\n)*-[\s\n]*The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations.(\\n)*(\n)*-[\s\n]*At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS.(\\n)*(\n)*-[\s\n]*Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG-authorized[\s\n]+purpose.(\\n)*(\n)*-[\s\n]*This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e.g.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests--not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy.(\\n)*(\n)*-[\s\n]*Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details.$|^I\'ve[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem\'t$)" -# expanded=$(echo "$login_banner_text" | sed 's/(\\\\\x27)\*/\\\x27/g;s/(\\\x27)\*//g;s/(\\\\\x27)/tamere/g;s/(\^\(.*\)\$|.*$/\1/g;s/\[\\s\\n\][+*]/ /g;s/\\//g;s/(n)\*/\\n/g;s/\x27/\\\x27/g;') +# login_banner_contents="(^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U.S.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG-authorized[\s\n]+use[\s\n]+only.[\s\n]*By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(\\n)*(\n)*-[\s\n]*The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations.(\\n)*(\n)*-[\s\n]*At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS.(\\n)*(\n)*-[\s\n]*Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG-authorized[\s\n]+purpose.(\\n)*(\n)*-[\s\n]*This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e.g.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests--not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy.(\\n)*(\n)*-[\s\n]*Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details.$|^I\'ve[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem\'t$)" +# expanded=$(echo "$login_banner_contents" | sed 's/(\\\\\x27)\*/\\\x27/g;s/(\\\x27)\*//g;s/(\\\\\x27)/tamere/g;s/(\^\(.*\)\$|.*$/\1/g;s/\[\\s\\n\][+*]/ /g;s/\\//g;s/(n)\*/\\n/g;s/\x27/\\\x27/g;') clean_dconf_settings add_dconf_setting "org/gnome/login-screen" "banner-message-enabled" "true" "{{{ dconf_gdm_dir }}}" "00-security-settings" diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value.pass.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value.pass.sh index 9b0d6ebb73f3..55af63e1fc20 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value.pass.sh @@ -1,16 +1,17 @@ #!/bin/bash # platform = multi_platform_ubuntu # packages = gdm3 -# variables = login_banner_text=Authorized users only. All activity may be monitored and reported. +# variables = dconf_login_banner_text=TestBanner,dconf_login_banner_contents=TestBanner source $SHARED/dconf_test_functions.sh clean_dconf_settings add_dconf_profiles -echo > /etc/gdm3/greeter.dconf-defaults +banner="TestBanner" -banner_default="Authorized users only. All activity may be monitored and reported." -add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'$banner_default'" "{{{ dconf_gdm_dir }}}" "00-security-settings" +echo > "/etc/gdm3/greeter.dconf-defaults" + +add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'$banner'" "{{{ dconf_gdm_dir }}}" "00-security-settings" add_dconf_lock "org/gnome/login-screen" "banner-message-text" "{{{ dconf_gdm_dir }}}" "00-security-settings-lock" dconf update diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value_defaults.pass.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value_defaults.pass.sh index 2ffb8ec5fb19..275c403e5496 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value_defaults.pass.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_correct_value_defaults.pass.sh @@ -1,16 +1,17 @@ #!/bin/bash # platform = multi_platform_ubuntu # packages = gdm3 -# variables = login_banner_text=Authorized users only. All activity may be monitored and reported. +# variables = dconf_login_banner_text=TestBanner,dconf_login_banner_contents=TestBanner source $SHARED/dconf_test_functions.sh clean_dconf_settings add_dconf_profiles -conffile="/etc/gdm3/greeter.dconf-defaults" +banner="TestBanner" -banner_default="Authorized users only. All activity may be monitored and reported." -sed -i '/banner-message-enable=/d;/banner-message-text=/d' ${conffile} -sed -i "/^\[org\/gnome\/login-screen\]/a""banner-message-text='$banner_default'" ${conffile} +cat >/etc/gdm3/greeter.dconf-defaults < "/etc/gdm3/greeter.dconf-defaults" dconf update diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value.fail.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value.fail.sh index cf9bb8d31b34..1717797bf50d 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value.fail.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value.fail.sh @@ -1,15 +1,17 @@ #!/bin/bash # platform = multi_platform_ubuntu # packages = gdm3 -# variables = login_banner_text=default +# variables = dconf_login_banner_text=TestBanner,dconf_login_banner_contents=TestBanner source $SHARED/dconf_test_functions.sh clean_dconf_settings add_dconf_profiles +banner="Wrong Banner" + echo > /etc/gdm3/greeter.dconf-defaults -add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'Wrong banner'" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_setting "org/gnome/login-screen" "banner-message-text" "'$banner'" "{{{ dconf_gdm_dir }}}" "00-security-settings" add_dconf_lock "org/gnome/login-screen" "banner-message-text" "{{{ dconf_gdm_dir }}}" "00-security-settings-lock" dconf update diff --git a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value_defaults.fail.sh b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value_defaults.fail.sh index 07e8cacfd78a..0431062c20ca 100644 --- a/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value_defaults.fail.sh +++ b/linux_os/guide/system/accounts/accounts-banners/gui_login_banner/dconf_gnome_login_banner_text/tests/ubuntu_wrong_value_defaults.fail.sh @@ -1,15 +1,17 @@ #!/bin/bash # platform = multi_platform_ubuntu # packages = gdm3 -# variables = login_banner_text=default +# variables = dconf_login_banner_text=TestBanner,dconf_login_banner_contents=TestBanner source $SHARED/dconf_test_functions.sh clean_dconf_settings add_dconf_profiles -conffile="/etc/gdm3/greeter.dconf-defaults" +banner="Wrong Banner" -sed -i '/banner-message-enable=/d;/banner-message-text=/d' ${conffile} -sed -i "/^\[org\/gnome\/login-screen\]/a""banner-message-text='Wrong banner'" ${conffile} +echo >/etc/gdm3/greeter.dconf-defaults <- + Enter an appropriate login banner text for your organization. + This variable is used only in remediations. + In OVAL checks a regular expression specified in the login_banner_text variable is used instead. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + +type: string + +operator: equals + +interactive: true + +options: + default: 'Authorized users only. All activity may be monitored and reported.' +# CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. +# There is a generic content in case a remediation is necessary. + cis_default: 'Authorized users only. All activity may be monitored and reported.' + dod_default: 'You are accessing a U.S. Government (USG) Information System (IS) that is\nprovided for USG-authorized use only. By using this IS (which includes any\ndevice attached to this IS), you consent to the following conditions:\n\n-The USG routinely intercepts and monitors communications on this IS for\npurposes including, but not limited to, penetration testing, COMSEC monitoring,\nnetwork operations and defense, personnel misconduct (PM), law enforcement\n(LE), and counterintelligence (CI) investigations.\n\n-At any time, the USG may inspect and seize data stored on this IS.\n\n-Communications using, or data stored on, this IS are not private, are subject\nto routine monitoring, interception, and search, and may be disclosed or used\nfor any USG-authorized purpose.\n\n-This IS includes security measures (e.g., authentication and access controls)\nto protect USG interests--not for your personal benefit or privacy.\n\n-Notwithstanding the above, using this IS does not constitute consent to PM, LE\nor CI investigative searching or monitoring of the content of privileged\ncommunications, or work product, related to personal representation or services\nby attorneys, psychotherapists, or clergy, and their assistants. Such\ncommunications and work product are private and confidential. See User\nAgreement for details.' + dod_short: 'I''ve read & consent to terms in IS user agreem''t.' + dss_odaa_default: 'Use of this or any other DoD interest computer system constitutes consent to\nmonitoring at all times. This is a DoD interest computer system. All DoD\ninterest computer systems and related equipment are intended for the\ncommunication, transmission, processing, and storage of official U.S.\nGovernment or other authorized information only. All DoD interest computer\nsystems are subject to monitoring at all times to ensure proper functioning of\nequipment and systems including security devices and systems, to prevent\nunauthorized use and violations of statutes and security regulations, to deter\ncriminal activity, and for other similar purposes. Any user of a DoD interest\ncomputer system should be aware that any information placed in the system is\nsubject to monitoring and is not subject to any expectation of privacy. If\nmonitoring of this or any other DoD interest computer system reveals possible\nevidence of violation of criminal statutes, this evidence and any other related\ninformation, including identification information about the user, may be\nprovided to law enforcement officials. If monitoring of this or any other DoD\ninterest computer systems reveals violations of security regulations or\nunauthorized use, employees who violate security regulations or make\nunauthorized use of DoD interest computer systems are subject to appropriate\ndisciplinary action. Use of this or any other DoD interest computer system\nconstitutes consent to monitoring at all times.' + usgcb_default: '-- WARNING -- This system is for the use of authorized users only. Individuals\nusing this computer system without authority or in excess of their authority\nare subject to having all their activities on this system monitored and\nrecorded by system personnel. Anyone using this system expressly consents to\nsuch monitoring and is advised that if such monitoring reveals possible\nevidence of criminal activity system personal may provide the evidence of such\nmonitoring to law enforcement officials.' diff --git a/linux_os/guide/system/accounts/accounts-banners/login_banner_text.var b/linux_os/guide/system/accounts/accounts-banners/login_banner_text.var index a8a9e9337576..6a44de843411 100644 --- a/linux_os/guide/system/accounts/accounts-banners/login_banner_text.var +++ b/linux_os/guide/system/accounts/accounts-banners/login_banner_text.var @@ -1,21 +1,25 @@ documentation_complete: true -title: 'Login Banner Verbiage' +title: Login Banner Verbiage Regular Expression -description: |- - Enter an appropriate login banner for your organization. Please note that new lines must - be expressed by the '\n' character and special characters like parentheses and quotation marks must be escaped with '\\'. +description: >- + Enter an appropriate login banner regular expression for your organization. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + This regular expression is used only in OVAL checks. + In remediations the login_banner_contents variable is used instead. + For information about how to generate banner regular expression for your tailoring files, + see: https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions type: string operator: equals -interactive: false +interactive: true options: # CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. # There is a generic content in case a remediation is necessary. -# How to generate banner, check https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions +# How to generate banner regex: https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions cis_banners: ^(Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.|^(?!.*(\\|fedora|rhel|sle|ubuntu)).*)$ cis_default: ^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ # First banner in 'dod_banners' must be the banner for desktop, laptop, and other devices which accommodate banners of 1300 characters diff --git a/linux_os/guide/system/accounts/accounts-banners/motd_banner_contents.var b/linux_os/guide/system/accounts/accounts-banners/motd_banner_contents.var new file mode 100644 index 000000000000..07fab0040f52 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/motd_banner_contents.var @@ -0,0 +1,25 @@ +documentation_complete: true + +title: 'MotD Banner Verbiage' + +description: >- + Enter an appropriate login banner text for your organization. + This variable is used only in remediations. + In OVAL checks a regular expression specified in the login_banner_text variable is used instead. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + +type: string + +operator: equals + +interactive: true + +options: + default: 'Authorized users only. All activity may be monitored and reported.' +# CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. +# There is a generic content in case a remediation is necessary. + cis_default: 'Authorized users only. All activity may be monitored and reported.' + dod_default: 'You are accessing a U.S. Government (USG) Information System (IS) that is\nprovided for USG-authorized use only. By using this IS (which includes any\ndevice attached to this IS), you consent to the following conditions:\n\n-The USG routinely intercepts and monitors communications on this IS for\npurposes including, but not limited to, penetration testing, COMSEC monitoring,\nnetwork operations and defense, personnel misconduct (PM), law enforcement\n(LE), and counterintelligence (CI) investigations.\n\n-At any time, the USG may inspect and seize data stored on this IS.\n\n-Communications using, or data stored on, this IS are not private, are subject\nto routine monitoring, interception, and search, and may be disclosed or used\nfor any USG-authorized purpose.\n\n-This IS includes security measures (e.g., authentication and access controls)\nto protect USG interests--not for your personal benefit or privacy.\n\n-Notwithstanding the above, using this IS does not constitute consent to PM, LE\nor CI investigative searching or monitoring of the content of privileged\ncommunications, or work product, related to personal representation or services\nby attorneys, psychotherapists, or clergy, and their assistants. Such\ncommunications and work product are private and confidential. See User\nAgreement for details.' + dod_short: 'I''ve read & consent to terms in IS user agreem''t.' + dss_odaa_default: 'Use of this or any other DoD interest computer system constitutes consent to\nmonitoring at all times. This is a DoD interest computer system. All DoD\ninterest computer systems and related equipment are intended for the\ncommunication, transmission, processing, and storage of official U.S.\nGovernment or other authorized information only. All DoD interest computer\nsystems are subject to monitoring at all times to ensure proper functioning of\nequipment and systems including security devices and systems, to prevent\nunauthorized use and violations of statutes and security regulations, to deter\ncriminal activity, and for other similar purposes. Any user of a DoD interest\ncomputer system should be aware that any information placed in the system is\nsubject to monitoring and is not subject to any expectation of privacy. If\nmonitoring of this or any other DoD interest computer system reveals possible\nevidence of violation of criminal statutes, this evidence and any other related\ninformation, including identification information about the user, may be\nprovided to law enforcement officials. If monitoring of this or any other DoD\ninterest computer systems reveals violations of security regulations or\nunauthorized use, employees who violate security regulations or make\nunauthorized use of DoD interest computer systems are subject to appropriate\ndisciplinary action. Use of this or any other DoD interest computer system\nconstitutes consent to monitoring at all times.' + usgcb_default: '-- WARNING -- This system is for the use of authorized users only. Individuals\nusing this computer system without authority or in excess of their authority\nare subject to having all their activities on this system monitored and\nrecorded by system personnel. Anyone using this system expressly consents to\nsuch monitoring and is advised that if such monitoring reveals possible\nevidence of criminal activity system personal may provide the evidence of such\nmonitoring to law enforcement officials.' diff --git a/linux_os/guide/system/accounts/accounts-banners/motd_banner_text.var b/linux_os/guide/system/accounts/accounts-banners/motd_banner_text.var index 6c7fff79ebc7..8b6fdbfc7b2d 100644 --- a/linux_os/guide/system/accounts/accounts-banners/motd_banner_text.var +++ b/linux_os/guide/system/accounts/accounts-banners/motd_banner_text.var @@ -1,27 +1,31 @@ documentation_complete: true -title: 'MotD Banner Verbiage' +title: Motd Banner Verbiage Regular Expression -description: |- - Enter an appropriate login banner for your organization. Please note that new lines must - be expressed by the '\n' character and special characters like parentheses and quotation marks must be escaped with '\\'. +description: >- + Enter an appropriate login banner regular expression for your organization. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + This regular expression is used only in OVAL checks. + In remediations the motd_banner_contents variable is used instead. + For information about how to generate banner regular expression for your tailoring files, + see: https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions type: string operator: equals -interactive: false +interactive: true options: # CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. # There is a generic content in case a remediation is necessary. # How to generate banner, check https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions - cis_banners: ^(Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.|^(?!.*(\\|fedora|rhel|sle|ubuntu)).*)$ - cis_default: ^Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ + cis_banners: ^(Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.|^(?!.*(\\|fedora|rhel|sle|ubuntu)).*)$ + cis_default: ^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ # First banner in 'dod_banners' must be the banner for desktop, laptop, and other devices which accommodate banners of 1300 characters dod_banners: ^(You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U\.S\.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG\-authorized[\s\n]+use[\s\n]+only\.[\s\n]+By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(?:[\n]+|(?:\\n)+)\-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations\.(?:[\n]+|(?:\\n)+)\-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS\.(?:[\n]+|(?:\\n)+)\-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG\-authorized[\s\n]+purpose\.(?:[\n]+|(?:\\n)+)\-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e\.g\.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests\-\-not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy\.(?:[\n]+|(?:\\n)+)\-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants\.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential\.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details\.|I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.)$ dod_default: ^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U\.S\.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG\-authorized[\s\n]+use[\s\n]+only\.[\s\n]+By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(?:[\n]+|(?:\\n)+)\-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations\.(?:[\n]+|(?:\\n)+)\-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS\.(?:[\n]+|(?:\\n)+)\-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG\-authorized[\s\n]+purpose\.(?:[\n]+|(?:\\n)+)\-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e\.g\.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests\-\-not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy\.(?:[\n]+|(?:\\n)+)\-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants\.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential\.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details\.$ dod_short: ^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$ dss_odaa_default: ^Use[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+constitutes[\s\n]+consent[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times\.[\s\n]+This[\s\n]+is[\s\n]+a[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system\.[\s\n]+All[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+and[\s\n]+related[\s\n]+equipment[\s\n]+are[\s\n]+intended[\s\n]+for[\s\n]+the[\s\n]+communication,[\s\n]+transmission,[\s\n]+processing,[\s\n]+and[\s\n]+storage[\s\n]+of[\s\n]+official[\s\n]+U\.S\.[\s\n]+Government[\s\n]+or[\s\n]+other[\s\n]+authorized[\s\n]+information[\s\n]+only\.[\s\n]+All[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times[\s\n]+to[\s\n]+ensure[\s\n]+proper[\s\n]+functioning[\s\n]+of[\s\n]+equipment[\s\n]+and[\s\n]+systems[\s\n]+including[\s\n]+security[\s\n]+devices[\s\n]+and[\s\n]+systems,[\s\n]+to[\s\n]+prevent[\s\n]+unauthorized[\s\n]+use[\s\n]+and[\s\n]+violations[\s\n]+of[\s\n]+statutes[\s\n]+and[\s\n]+security[\s\n]+regulations,[\s\n]+to[\s\n]+deter[\s\n]+criminal[\s\n]+activity,[\s\n]+and[\s\n]+for[\s\n]+other[\s\n]+similar[\s\n]+purposes\.[\s\n]+Any[\s\n]+user[\s\n]+of[\s\n]+a[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+should[\s\n]+be[\s\n]+aware[\s\n]+that[\s\n]+any[\s\n]+information[\s\n]+placed[\s\n]+in[\s\n]+the[\s\n]+system[\s\n]+is[\s\n]+subject[\s\n]+to[\s\n]+monitoring[\s\n]+and[\s\n]+is[\s\n]+not[\s\n]+subject[\s\n]+to[\s\n]+any[\s\n]+expectation[\s\n]+of[\s\n]+privacy\.[\s\n]+If[\s\n]+monitoring[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+reveals[\s\n]+possible[\s\n]+evidence[\s\n]+of[\s\n]+violation[\s\n]+of[\s\n]+criminal[\s\n]+statutes,[\s\n]+this[\s\n]+evidence[\s\n]+and[\s\n]+any[\s\n]+other[\s\n]+related[\s\n]+information,[\s\n]+including[\s\n]+identification[\s\n]+information[\s\n]+about[\s\n]+the[\s\n]+user,[\s\n]+may[\s\n]+be[\s\n]+provided[\s\n]+to[\s\n]+law[\s\n]+enforcement[\s\n]+officials\.[\s\n]+If[\s\n]+monitoring[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+reveals[\s\n]+violations[\s\n]+of[\s\n]+security[\s\n]+regulations[\s\n]+or[\s\n]+unauthorized[\s\n]+use,[\s\n]+employees[\s\n]+who[\s\n]+violate[\s\n]+security[\s\n]+regulations[\s\n]+or[\s\n]+make[\s\n]+unauthorized[\s\n]+use[\s\n]+of[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+appropriate[\s\n]+disciplinary[\s\n]+action\.[\s\n]+Use[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+constitutes[\s\n]+consent[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times\.$ usgcb_default: ^\-\-[\s\n]+WARNING[\s\n]+\-\-[\s\n]+This[\s\n]+system[\s\n]+is[\s\n]+for[\s\n]+the[\s\n]+use[\s\n]+of[\s\n]+authorized[\s\n]+users[\s\n]+only\.[\s\n]+Individuals[\s\n]+using[\s\n]+this[\s\n]+computer[\s\n]+system[\s\n]+without[\s\n]+authority[\s\n]+or[\s\n]+in[\s\n]+excess[\s\n]+of[\s\n]+their[\s\n]+authority[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+having[\s\n]+all[\s\n]+their[\s\n]+activities[\s\n]+on[\s\n]+this[\s\n]+system[\s\n]+monitored[\s\n]+and[\s\n]+recorded[\s\n]+by[\s\n]+system[\s\n]+personnel\.[\s\n]+Anyone[\s\n]+using[\s\n]+this[\s\n]+system[\s\n]+expressly[\s\n]+consents[\s\n]+to[\s\n]+such[\s\n]+monitoring[\s\n]+and[\s\n]+is[\s\n]+advised[\s\n]+that[\s\n]+if[\s\n]+such[\s\n]+monitoring[\s\n]+reveals[\s\n]+possible[\s\n]+evidence[\s\n]+of[\s\n]+criminal[\s\n]+activity[\s\n]+system[\s\n]+personal[\s\n]+may[\s\n]+provide[\s\n]+the[\s\n]+evidence[\s\n]+of[\s\n]+such[\s\n]+monitoring[\s\n]+to[\s\n]+law[\s\n]+enforcement[\s\n]+officials\.$ - default: ^Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ + default: ^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ diff --git a/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_contents.var b/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_contents.var new file mode 100644 index 000000000000..d2b77661b666 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_contents.var @@ -0,0 +1,25 @@ +documentation_complete: true + +title: 'Remote Login Banner Verbiage' + +description: >- + Enter an appropriate login banner text for your organization. + This variable is used only in remediations. + In OVAL checks a regular expression specified in the remote_login_banner_text variable is used instead. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + +type: string + +operator: equals + +interactive: true + +options: + default: 'Authorized users only. All activity may be monitored and reported.' +# CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. +# There is a generic content in case a remediation is necessary. + cis_default: 'Authorized users only. All activity may be monitored and reported.' + dod_default: 'You are accessing a U.S. Government (USG) Information System (IS) that is\nprovided for USG-authorized use only. By using this IS (which includes any\ndevice attached to this IS), you consent to the following conditions:\n\n-The USG routinely intercepts and monitors communications on this IS for\npurposes including, but not limited to, penetration testing, COMSEC monitoring,\nnetwork operations and defense, personnel misconduct (PM), law enforcement\n(LE), and counterintelligence (CI) investigations.\n\n-At any time, the USG may inspect and seize data stored on this IS.\n\n-Communications using, or data stored on, this IS are not private, are subject\nto routine monitoring, interception, and search, and may be disclosed or used\nfor any USG-authorized purpose.\n\n-This IS includes security measures (e.g., authentication and access controls)\nto protect USG interests--not for your personal benefit or privacy.\n\n-Notwithstanding the above, using this IS does not constitute consent to PM, LE\nor CI investigative searching or monitoring of the content of privileged\ncommunications, or work product, related to personal representation or services\nby attorneys, psychotherapists, or clergy, and their assistants. Such\ncommunications and work product are private and confidential. See User\nAgreement for details.' + dod_short: 'I''ve read & consent to terms in IS user agreem''t.' + dss_odaa_default: 'Use of this or any other DoD interest computer system constitutes consent to\nmonitoring at all times. This is a DoD interest computer system. All DoD\ninterest computer systems and related equipment are intended for the\ncommunication, transmission, processing, and storage of official U.S.\nGovernment or other authorized information only. All DoD interest computer\nsystems are subject to monitoring at all times to ensure proper functioning of\nequipment and systems including security devices and systems, to prevent\nunauthorized use and violations of statutes and security regulations, to deter\ncriminal activity, and for other similar purposes. Any user of a DoD interest\ncomputer system should be aware that any information placed in the system is\nsubject to monitoring and is not subject to any expectation of privacy. If\nmonitoring of this or any other DoD interest computer system reveals possible\nevidence of violation of criminal statutes, this evidence and any other related\ninformation, including identification information about the user, may be\nprovided to law enforcement officials. If monitoring of this or any other DoD\ninterest computer systems reveals violations of security regulations or\nunauthorized use, employees who violate security regulations or make\nunauthorized use of DoD interest computer systems are subject to appropriate\ndisciplinary action. Use of this or any other DoD interest computer system\nconstitutes consent to monitoring at all times.' + usgcb_default: '-- WARNING -- This system is for the use of authorized users only. Individuals\nusing this computer system without authority or in excess of their authority\nare subject to having all their activities on this system monitored and\nrecorded by system personnel. Anyone using this system expressly consents to\nsuch monitoring and is advised that if such monitoring reveals possible\nevidence of criminal activity system personal may provide the evidence of such\nmonitoring to law enforcement officials.' diff --git a/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_text.var b/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_text.var index 5f64f4f4af63..a4e24de44962 100644 --- a/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_text.var +++ b/linux_os/guide/system/accounts/accounts-banners/remote_login_banner_text.var @@ -1,28 +1,31 @@ documentation_complete: true -title: 'Remote Login Banner Verbiage' +title: Remote Login Banner Verbiage Regular Expression -description: |- - Enter an appropriate login banner for your organization. Please note that new lines must - be expressed by the '\n' character and special characters like parentheses and quotation marks must be escaped with '\\'. +description: >- + Enter an appropriate login banner regular expression for your organization. + Using a regular expression is needed because some profiles (eg. STIG) allow multiple different banners. + This regular expression is used only in OVAL checks. + In remediations the remote_login_banner_contents variable is used instead. + For information about how to generate banner regular expression for your tailoring files, + see: https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions type: string operator: equals -interactive: false - +interactive: true options: # CIS doesn't enforce any specific content for login banners, but doesn't allow technical information. # There is a generic content in case a remediation is necessary. # How to generate banner, check https://complianceascode.readthedocs.io/en/latest/manual/developer/05_tools_and_utilities.html#generating-login-banner-regular-expressions - cis_banners: ^(Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.|^(?!.*(\\|fedora|rhel|sle|ubuntu)).*)$ - cis_default: ^Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ + cis_banners: ^(Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.|^(?!.*(\\|fedora|rhel|sle|ubuntu)).*)$ + cis_default: ^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ # First banner in 'dod_banners' must be the banner for desktop, laptop, and other devices which accommodate banners of 1300 characters dod_banners: ^(You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U\.S\.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG\-authorized[\s\n]+use[\s\n]+only\.[\s\n]+By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(?:[\n]+|(?:\\n)+)\-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations\.(?:[\n]+|(?:\\n)+)\-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS\.(?:[\n]+|(?:\\n)+)\-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG\-authorized[\s\n]+purpose\.(?:[\n]+|(?:\\n)+)\-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e\.g\.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests\-\-not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy\.(?:[\n]+|(?:\\n)+)\-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants\.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential\.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details\.|I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.)$ dod_default: ^You[\s\n]+are[\s\n]+accessing[\s\n]+a[\s\n]+U\.S\.[\s\n]+Government[\s\n]+\(USG\)[\s\n]+Information[\s\n]+System[\s\n]+\(IS\)[\s\n]+that[\s\n]+is[\s\n]+provided[\s\n]+for[\s\n]+USG\-authorized[\s\n]+use[\s\n]+only\.[\s\n]+By[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+\(which[\s\n]+includes[\s\n]+any[\s\n]+device[\s\n]+attached[\s\n]+to[\s\n]+this[\s\n]+IS\),[\s\n]+you[\s\n]+consent[\s\n]+to[\s\n]+the[\s\n]+following[\s\n]+conditions\:(?:[\n]+|(?:\\n)+)\-The[\s\n]+USG[\s\n]+routinely[\s\n]+intercepts[\s\n]+and[\s\n]+monitors[\s\n]+communications[\s\n]+on[\s\n]+this[\s\n]+IS[\s\n]+for[\s\n]+purposes[\s\n]+including,[\s\n]+but[\s\n]+not[\s\n]+limited[\s\n]+to,[\s\n]+penetration[\s\n]+testing,[\s\n]+COMSEC[\s\n]+monitoring,[\s\n]+network[\s\n]+operations[\s\n]+and[\s\n]+defense,[\s\n]+personnel[\s\n]+misconduct[\s\n]+\(PM\),[\s\n]+law[\s\n]+enforcement[\s\n]+\(LE\),[\s\n]+and[\s\n]+counterintelligence[\s\n]+\(CI\)[\s\n]+investigations\.(?:[\n]+|(?:\\n)+)\-At[\s\n]+any[\s\n]+time,[\s\n]+the[\s\n]+USG[\s\n]+may[\s\n]+inspect[\s\n]+and[\s\n]+seize[\s\n]+data[\s\n]+stored[\s\n]+on[\s\n]+this[\s\n]+IS\.(?:[\n]+|(?:\\n)+)\-Communications[\s\n]+using,[\s\n]+or[\s\n]+data[\s\n]+stored[\s\n]+on,[\s\n]+this[\s\n]+IS[\s\n]+are[\s\n]+not[\s\n]+private,[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+routine[\s\n]+monitoring,[\s\n]+interception,[\s\n]+and[\s\n]+search,[\s\n]+and[\s\n]+may[\s\n]+be[\s\n]+disclosed[\s\n]+or[\s\n]+used[\s\n]+for[\s\n]+any[\s\n]+USG\-authorized[\s\n]+purpose\.(?:[\n]+|(?:\\n)+)\-This[\s\n]+IS[\s\n]+includes[\s\n]+security[\s\n]+measures[\s\n]+\(e\.g\.,[\s\n]+authentication[\s\n]+and[\s\n]+access[\s\n]+controls\)[\s\n]+to[\s\n]+protect[\s\n]+USG[\s\n]+interests\-\-not[\s\n]+for[\s\n]+your[\s\n]+personal[\s\n]+benefit[\s\n]+or[\s\n]+privacy\.(?:[\n]+|(?:\\n)+)\-Notwithstanding[\s\n]+the[\s\n]+above,[\s\n]+using[\s\n]+this[\s\n]+IS[\s\n]+does[\s\n]+not[\s\n]+constitute[\s\n]+consent[\s\n]+to[\s\n]+PM,[\s\n]+LE[\s\n]+or[\s\n]+CI[\s\n]+investigative[\s\n]+searching[\s\n]+or[\s\n]+monitoring[\s\n]+of[\s\n]+the[\s\n]+content[\s\n]+of[\s\n]+privileged[\s\n]+communications,[\s\n]+or[\s\n]+work[\s\n]+product,[\s\n]+related[\s\n]+to[\s\n]+personal[\s\n]+representation[\s\n]+or[\s\n]+services[\s\n]+by[\s\n]+attorneys,[\s\n]+psychotherapists,[\s\n]+or[\s\n]+clergy,[\s\n]+and[\s\n]+their[\s\n]+assistants\.[\s\n]+Such[\s\n]+communications[\s\n]+and[\s\n]+work[\s\n]+product[\s\n]+are[\s\n]+private[\s\n]+and[\s\n]+confidential\.[\s\n]+See[\s\n]+User[\s\n]+Agreement[\s\n]+for[\s\n]+details\.$ dod_short: ^I've[\s\n]+read[\s\n]+\&[\s\n]+consent[\s\n]+to[\s\n]+terms[\s\n]+in[\s\n]+IS[\s\n]+user[\s\n]+agreem't\.$ dss_odaa_default: ^Use[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+constitutes[\s\n]+consent[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times\.[\s\n]+This[\s\n]+is[\s\n]+a[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system\.[\s\n]+All[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+and[\s\n]+related[\s\n]+equipment[\s\n]+are[\s\n]+intended[\s\n]+for[\s\n]+the[\s\n]+communication,[\s\n]+transmission,[\s\n]+processing,[\s\n]+and[\s\n]+storage[\s\n]+of[\s\n]+official[\s\n]+U\.S\.[\s\n]+Government[\s\n]+or[\s\n]+other[\s\n]+authorized[\s\n]+information[\s\n]+only\.[\s\n]+All[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times[\s\n]+to[\s\n]+ensure[\s\n]+proper[\s\n]+functioning[\s\n]+of[\s\n]+equipment[\s\n]+and[\s\n]+systems[\s\n]+including[\s\n]+security[\s\n]+devices[\s\n]+and[\s\n]+systems,[\s\n]+to[\s\n]+prevent[\s\n]+unauthorized[\s\n]+use[\s\n]+and[\s\n]+violations[\s\n]+of[\s\n]+statutes[\s\n]+and[\s\n]+security[\s\n]+regulations,[\s\n]+to[\s\n]+deter[\s\n]+criminal[\s\n]+activity,[\s\n]+and[\s\n]+for[\s\n]+other[\s\n]+similar[\s\n]+purposes\.[\s\n]+Any[\s\n]+user[\s\n]+of[\s\n]+a[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+should[\s\n]+be[\s\n]+aware[\s\n]+that[\s\n]+any[\s\n]+information[\s\n]+placed[\s\n]+in[\s\n]+the[\s\n]+system[\s\n]+is[\s\n]+subject[\s\n]+to[\s\n]+monitoring[\s\n]+and[\s\n]+is[\s\n]+not[\s\n]+subject[\s\n]+to[\s\n]+any[\s\n]+expectation[\s\n]+of[\s\n]+privacy\.[\s\n]+If[\s\n]+monitoring[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+reveals[\s\n]+possible[\s\n]+evidence[\s\n]+of[\s\n]+violation[\s\n]+of[\s\n]+criminal[\s\n]+statutes,[\s\n]+this[\s\n]+evidence[\s\n]+and[\s\n]+any[\s\n]+other[\s\n]+related[\s\n]+information,[\s\n]+including[\s\n]+identification[\s\n]+information[\s\n]+about[\s\n]+the[\s\n]+user,[\s\n]+may[\s\n]+be[\s\n]+provided[\s\n]+to[\s\n]+law[\s\n]+enforcement[\s\n]+officials\.[\s\n]+If[\s\n]+monitoring[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+reveals[\s\n]+violations[\s\n]+of[\s\n]+security[\s\n]+regulations[\s\n]+or[\s\n]+unauthorized[\s\n]+use,[\s\n]+employees[\s\n]+who[\s\n]+violate[\s\n]+security[\s\n]+regulations[\s\n]+or[\s\n]+make[\s\n]+unauthorized[\s\n]+use[\s\n]+of[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+systems[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+appropriate[\s\n]+disciplinary[\s\n]+action\.[\s\n]+Use[\s\n]+of[\s\n]+this[\s\n]+or[\s\n]+any[\s\n]+other[\s\n]+DoD[\s\n]+interest[\s\n]+computer[\s\n]+system[\s\n]+constitutes[\s\n]+consent[\s\n]+to[\s\n]+monitoring[\s\n]+at[\s\n]+all[\s\n]+times\.$ usgcb_default: ^\-\-[\s\n]+WARNING[\s\n]+\-\-[\s\n]+This[\s\n]+system[\s\n]+is[\s\n]+for[\s\n]+the[\s\n]+use[\s\n]+of[\s\n]+authorized[\s\n]+users[\s\n]+only\.[\s\n]+Individuals[\s\n]+using[\s\n]+this[\s\n]+computer[\s\n]+system[\s\n]+without[\s\n]+authority[\s\n]+or[\s\n]+in[\s\n]+excess[\s\n]+of[\s\n]+their[\s\n]+authority[\s\n]+are[\s\n]+subject[\s\n]+to[\s\n]+having[\s\n]+all[\s\n]+their[\s\n]+activities[\s\n]+on[\s\n]+this[\s\n]+system[\s\n]+monitored[\s\n]+and[\s\n]+recorded[\s\n]+by[\s\n]+system[\s\n]+personnel\.[\s\n]+Anyone[\s\n]+using[\s\n]+this[\s\n]+system[\s\n]+expressly[\s\n]+consents[\s\n]+to[\s\n]+such[\s\n]+monitoring[\s\n]+and[\s\n]+is[\s\n]+advised[\s\n]+that[\s\n]+if[\s\n]+such[\s\n]+monitoring[\s\n]+reveals[\s\n]+possible[\s\n]+evidence[\s\n]+of[\s\n]+criminal[\s\n]+activity[\s\n]+system[\s\n]+personal[\s\n]+may[\s\n]+provide[\s\n]+the[\s\n]+evidence[\s\n]+of[\s\n]+such[\s\n]+monitoring[\s\n]+to[\s\n]+law[\s\n]+enforcement[\s\n]+officials\.$ - default: ^Authorized[\s\n]+uses[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ + default: ^Authorized[\s\n]+users[\s\n]+only\.[\s\n]+All[\s\n]+activity[\s\n]+may[\s\n]+be[\s\n]+monitored[\s\n]+and[\s\n]+reported\.$ diff --git a/linux_os/guide/system/accounts/accounts-pam/enable_pam_namespace/rule.yml b/linux_os/guide/system/accounts/accounts-pam/enable_pam_namespace/rule.yml index 2c6f3d6d375c..da5b0d596ce0 100644 --- a/linux_os/guide/system/accounts/accounts-pam/enable_pam_namespace/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/enable_pam_namespace/rule.yml @@ -22,7 +22,7 @@ identifiers: cce@rhel10: CCE-90739-4 cce@sle12: CCE-91505-8 cce@sle15: CCE-91196-6 - + cce@sle16: CCE-96060-9 ocil_clause: |- pam_namespace.so is not required or is commented out diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/correct_value_with_features.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/correct_value_with_features.pass.sh new file mode 100644 index 000000000000..e23b4f3318bb --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/correct_value_with_features.pass.sh @@ -0,0 +1,13 @@ +#!/bin/bash +# packages = authselect,pam +# platform = Oracle Linux 8,Oracle Linux 9,multi_platform_rhel,multi_platform_fedora + +authselect create-profile test_profile -b sssd +authselect select "custom/test_profile" --force + +# Enable multiple features to test the scenario where "authselect current --raw" +# returns a string with spaces (e.g., "custom/test_profile with-faillock with-fingerprint") +authselect enable-feature with-faillock +authselect enable-feature with-fingerprint + +authselect apply-changes diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/no_faillock_with_other_features.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/no_faillock_with_other_features.fail.sh new file mode 100644 index 000000000000..2c2210475003 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/no_faillock_with_other_features.fail.sh @@ -0,0 +1,13 @@ +#!/bin/bash +# packages = authselect,pam +# platform = Oracle Linux 8,Oracle Linux 9,multi_platform_rhel,multi_platform_fedora + +authselect create-profile test_profile -b sssd +authselect select "custom/test_profile" --force + +# Enable other features but not with-faillock to simulate a system +# that has authselect configured with features, but missing the required faillock +authselect enable-feature with-fingerprint +authselect enable-feature with-silent-lastlog + +authselect apply-changes diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/sssd_profile_with_features.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/sssd_profile_with_features.pass.sh new file mode 100644 index 000000000000..37bde473b802 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/sssd_profile_with_features.pass.sh @@ -0,0 +1,13 @@ +#!/bin/bash +# packages = authselect,pam +# platform = Oracle Linux 8,Oracle Linux 9,multi_platform_rhel,multi_platform_fedora + +# Simulate a real RHEL system with sssd profile and multiple features enabled +# This is the scenario reported in issue #14600 where "authselect current --raw" +# returns "sssd with-fingerprint with-silent-lastlog" +authselect select sssd --force +authselect enable-feature with-faillock +authselect enable-feature with-fingerprint +authselect enable-feature with-silent-lastlog + +authselect apply-changes diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/sssd_single_feature_no_faillock.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/sssd_single_feature_no_faillock.fail.sh new file mode 100644 index 000000000000..a5e3b2d93ec4 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/account_password_pam_faillock_password_auth/tests/sssd_single_feature_no_faillock.fail.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# packages = authselect,pam +# platform = Oracle Linux 8,Oracle Linux 9,multi_platform_rhel,multi_platform_fedora + +# Test with sssd profile and one feature (not faillock) enabled +# This simulates a system where "authselect current --raw" returns "sssd with-fingerprint" +authselect select sssd --force +authselect enable-feature with-fingerprint + +authselect apply-changes diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/rule.yml index 6ddeca87203b..c2b84d63960f 100644 --- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/rule.yml @@ -21,6 +21,7 @@ severity: medium identifiers: cce@sle12: CCE-83173-5 cce@sle15: CCE-91398-8 + cce@sle16: CCE-95993-2 cce@slmicro5: CCE-94082-5 cce@slmicro6: CCE-94641-8 diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_authok_missing.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_authok_missing.fail.sh new file mode 100644 index 000000000000..57ba80fda554 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_authok_missing.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = multi_platform_sle +# packages = pam +# variables = var_password_pam_remember=4 + +echo "password requisite pam_pwhistory.so remember=4" > /etc/pam.d/common-password diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_correct_value.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_correct_value.pass.sh new file mode 100644 index 000000000000..8a860dec450c --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_correct_value.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = multi_platform_sle +# packages = pam +# variables = var_password_pam_remember=4 + +echo "password requisite pam_pwhistory.so remember=4 use_authtok" > /etc/pam.d/common-password diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_greater_value.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_greater_value.pass.sh new file mode 100644 index 000000000000..a824cc4f2d12 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_greater_value.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = multi_platform_sle +# packages = pam +# variables = var_password_pam_remember=4 + +echo "password requisite pam_pwhistory.so remember=10 use_authtok" > /etc/pam.d/common-password diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_less_value.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_less_value.fail.sh new file mode 100644 index 000000000000..1a1a85117d86 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_less_value.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = multi_platform_sle +# packages = pam +# variables = var_password_pam_remember=4 + +echo "password requisite pam_pwhistory.so remember=1 use_authtok" > /etc/pam.d/common-password diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_missing.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_missing.fail.sh new file mode 100644 index 000000000000..f599292b836c --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_missing.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = pam + +if [ -e "/etc/pam.d/common-password" ] ; then + rm "/etc/pam.d/common-password" +fi diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_remember_missing.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_remember_missing.fail.sh new file mode 100644 index 000000000000..69464b5db000 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_password_pam_pwhistory_remember/tests/common_password_remember_missing.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = multi_platform_sle +# packages = pam +# variables = var_password_pam_remember=4 + +echo "password requisite pam_pwhistory.so use_authtok" > /etc/pam.d/common-password diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny/rule.yml index 7212a67f9415..6f472912698a 100644 --- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny/rule.yml @@ -30,6 +30,7 @@ identifiers: cce@rhel9: CCE-83587-6 cce@rhel10: CCE-87388-5 cce@sle15: CCE-85842-3 + cce@sle16: CCE-96664-8 references: cis-csc: 1,12,15,16 diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny_root/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny_root/rule.yml index d836a170849b..fd7925a755f1 100644 --- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny_root/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_deny_root/rule.yml @@ -25,6 +25,7 @@ identifiers: cce@rhel10: CCE-87975-9 cce@sle12: CCE-91468-9 cce@sle15: CCE-91171-9 + cce@sle16: CCE-96663-0 references: cis-csc: 1,12,15,16 diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/ansible/shared.yml new file mode 100644 index 000000000000..872add0463f9 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/ansible/shared.yml @@ -0,0 +1,7 @@ +# platform = multi_platform_rhel,multi_platform_fedora +# reboot = false +# strategy = restrict +# complexity = low +# disruption = low +{{{ ansible_pam_faillock_enable(rule_title=rule_title) }}} +{{{ ansible_pam_faillock_parameter_value("even_deny_root", "", rule_title=rule_title) }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/bash/shared.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/bash/shared.sh new file mode 100644 index 000000000000..a5ede08636a5 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/bash/shared.sh @@ -0,0 +1,4 @@ +# platform = multi_platform_rhel,multi_platform_fedora + +{{{ bash_pam_faillock_enable() }}} +{{{ bash_pam_faillock_parameter_value("even_deny_root", "") }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/oval/shared.xml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/oval/shared.xml new file mode 100644 index 000000000000..1873526f7d4d --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/oval/shared.xml @@ -0,0 +1,379 @@ + + + {{{ oval_metadata("The root account should be included in the account lockout policy. + Either the even_deny_root option should be set or root_unlock_time should be set to + the required minimum value or greater.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ^[\s]*auth\N+pam_unix\.so + + + + ^[\s]*auth[\s]+(required|\[(?=.*?\bsuccess=ok\b)(?=.*?\bnew_authtok_reqd=ok\b)(?=.*?\bignore=ignore\b)(?=.*?\bdefault=bad\b).*\])[\s]+pam_faillock\.so[\s\w\d=]+preauth[\s\S]*^[\s]*auth[\s]+(sufficient|\[(?=.*\bsuccess=done\b)(?=.*?\bnew_authtok_reqd=done\b)(?=.*?\bdefault=ignore\b).*\])[\s]+pam_unix\.so[\s\S]*^[\s]*auth[\s]+(required|\[(?=.*?\bsuccess=ok\b)(?=.*?\bnew_authtok_reqd=ok\b)(?=.*?\bignore=ignore\b)(?=.*?\bdefault=bad\b).*\])[\s]+pam_faillock\.so[\s\w\d=]+authfail + + + + ^[\s]*account[\s]+(required|\[(?=.*?\bsuccess=ok\b)(?=.*?\bnew_authtok_reqd=ok\b)(?=.*?\bignore=ignore\b)(?=.*?\bdefault=bad\b).*\])[\s]+pam_faillock\.so[\s\S]*^[\s]*account[\s]+(required|\[(?=.*?\bsuccess=ok\b)(?=.*?\bnew_authtok_reqd=ok\b)(?=.*?\bignore=ignore\b)(?=.*?\bdefault=bad\b).*\])[\s]+pam_unix\.so + + + + ^[\s]*auth[\s]+.+[\s]+pam_faillock.so[\s]+[^\n]*even_deny_root + + + + ^[\s]*even_deny_root + + + + ^[\s]*auth[\s]+.+[\s]+pam_faillock.so[\s]+[^\n]*root_unlock_time=([0-9]+) + + + + ^[\s]*root_unlock_time[\s]*=[\s]*([0-9]+) + + + + + ^/etc/pam.d/system-auth$ + + 1 + + + + + + + + + ^/etc/pam.d/password-auth$ + + 1 + + + + + + + + + ^/etc/pam.d/system-auth$ + + 1 + + + + + + + + + ^/etc/pam.d/system-auth$ + + 1 + + + + + + + + + ^/etc/pam.d/password-auth$ + + 1 + + + + + + + + + ^/etc/pam.d/password-auth$ + + 1 + + + + + + + + + ^/etc/pam.d/system-auth$ + + 1 + + + + + + + + + + + + + ^/etc/pam.d/password-auth$ + + 1 + + + + + + + + + + + + + ^{{{ pam_faillock_conf_path }}}$ + + 1 + + + + + + + + + + + + + ^/etc/pam.d/system-auth$ + + 1 + + + + + + + + + + + + + + ^/etc/pam.d/password-auth$ + + 1 + + + + + + + + + + + + + + ^{{{ pam_faillock_conf_path }}}$ + + 1 + + + + + + + + + + + + + + + + + + + diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/rule.yml new file mode 100644 index 000000000000..c49ac55de782 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/rule.yml @@ -0,0 +1,53 @@ +documentation_complete: true + +title: Ensure Root Account Lockout on Failed Password Attempts + +description: >- + This rule configures the system to include the root account in the + account lockout policy using pam_faillock.so. The system must have + either the even_deny_root option enabled or root_unlock_time + set to {{{xccdf_value("var_accounts_passwords_pam_faillock_root_unlock_time") }}} + seconds or greater in {{{ pam_faillock_conf_path }}}. + + pam_faillock.so module requires multiple entries in pam files. These entries must be carefully + defined to work as expected. In order to avoid errors when manually editing these files, it is + recommended to use the appropriate tools, such as authselect or authconfig, + depending on the OS version. + +rationale: >- + By limiting the number of failed logon attempts, the risk of unauthorized system access via + user password guessing, also known as brute-forcing, is reduced. Limits are imposed by locking + the account. + +severity: medium + +identifiers: + cce@rhel8: CCE-86629-3 + cce@rhel9: CCE-86630-1 + cce@rhel10: CCE-86631-9 + +platform: package[pam] + +ocil_clause: 'neither "even_deny_root" is set nor "root_unlock_time" is set to {{{ xccdf_value("var_accounts_passwords_pam_faillock_root_unlock_time") }}} or greater' + +ocil: >- + Verify {{{ full_name }}} is configured to include the root account in the account lockout + policy with the command: + +
$ grep -E 'even_deny_root|root_unlock_time' {{{ pam_faillock_conf_path }}}
+ + The output should show either: +
even_deny_root
+ or: +
root_unlock_time = <value>
+ where <value> is {{{ xccdf_value("var_accounts_passwords_pam_faillock_root_unlock_time") }}} or greater. + +warnings: + - general: >- + If the system relies on authselect tool to manage PAM settings, the remediation + will also use authselect tool. However, if any manual modification was made in + PAM files, the authselect integrity check will fail and the remediation will be + aborted in order to preserve intentional changes. In this case, an informative message will + be shown in the remediation report. + If the system supports the {{{ pam_faillock_conf_path }}} file, the pam_faillock + parameters should be defined in faillock.conf file. diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/even_deny_root_faillock_conf.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/even_deny_root_faillock_conf.pass.sh new file mode 100644 index 000000000000..c0af070e8db3 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/even_deny_root_faillock_conf.pass.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# packages = authselect +# platform = multi_platform_rhel,multi_platform_fedora +# variables = var_accounts_passwords_pam_faillock_root_unlock_time=60 + +authselect select sssd --force +authselect enable-feature with-faillock +> "{{{ pam_faillock_conf_path }}}" +echo "even_deny_root" >> "{{{ pam_faillock_conf_path }}}" +echo "silent" >> "{{{ pam_faillock_conf_path }}}" diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/neither_set_faillock_conf.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/neither_set_faillock_conf.fail.sh new file mode 100644 index 000000000000..cfa471ed8216 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/neither_set_faillock_conf.fail.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# packages = authselect +# platform = multi_platform_rhel,multi_platform_fedora +# variables = var_accounts_passwords_pam_faillock_root_unlock_time=60 + +authselect select sssd --force +authselect enable-feature with-faillock +> "{{{ pam_faillock_conf_path }}}" +echo "silent" >> "{{{ pam_faillock_conf_path }}}" diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/pam_faillock_disabled.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/pam_faillock_disabled.fail.sh new file mode 100644 index 000000000000..1a83c21d34a2 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/pam_faillock_disabled.fail.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# packages = authselect +# platform = multi_platform_rhel,multi_platform_fedora +# variables = var_accounts_passwords_pam_faillock_root_unlock_time=60 + +authselect select sssd --force +authselect disable-feature with-faillock diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_300_faillock_conf.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_300_faillock_conf.pass.sh new file mode 100644 index 000000000000..6b06b8295c2b --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_300_faillock_conf.pass.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# packages = authselect +# platform = multi_platform_rhel,multi_platform_fedora +# variables = var_accounts_passwords_pam_faillock_root_unlock_time=60 + +authselect select sssd --force +authselect enable-feature with-faillock +> "{{{ pam_faillock_conf_path }}}" +echo "root_unlock_time = 300" >> "{{{ pam_faillock_conf_path }}}" +echo "silent" >> "{{{ pam_faillock_conf_path }}}" diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_30_faillock_conf.fail.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_30_faillock_conf.fail.sh new file mode 100644 index 000000000000..b0892dd5d410 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_30_faillock_conf.fail.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# packages = authselect +# platform = multi_platform_rhel,multi_platform_fedora +# variables = var_accounts_passwords_pam_faillock_root_unlock_time=60 + +authselect select sssd --force +authselect enable-feature with-faillock +> "{{{ pam_faillock_conf_path }}}" +echo "root_unlock_time = 30" >> "{{{ pam_faillock_conf_path }}}" +echo "silent" >> "{{{ pam_faillock_conf_path }}}" diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_60_faillock_conf.pass.sh b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_60_faillock_conf.pass.sh new file mode 100644 index 000000000000..20d52e697ca3 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time/tests/root_unlock_time_60_faillock_conf.pass.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# packages = authselect +# platform = multi_platform_rhel,multi_platform_fedora +# variables = var_accounts_passwords_pam_faillock_root_unlock_time=60 + +authselect select sssd --force +authselect enable-feature with-faillock +> "{{{ pam_faillock_conf_path }}}" +echo "root_unlock_time = 60" >> "{{{ pam_faillock_conf_path }}}" +echo "silent" >> "{{{ pam_faillock_conf_path }}}" diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_interval/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_interval/rule.yml index e012ebd6b3f3..8bad63e27c08 100644 --- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_interval/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_interval/rule.yml @@ -29,6 +29,7 @@ identifiers: cce@rhel9: CCE-83583-5 cce@rhel10: CCE-86672-3 cce@sle15: CCE-91169-3 + cce@sle16: CCE-96665-5 references: cis-csc: 1,12,15,16 diff --git a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_unlock_time/rule.yml b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_unlock_time/rule.yml index bf6799d6f0f4..faa85597accf 100644 --- a/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_unlock_time/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/locking_out_password_attempts/accounts_passwords_pam_faillock_unlock_time/rule.yml @@ -31,6 +31,7 @@ identifiers: cce@rhel9: CCE-83588-4 cce@rhel10: CCE-89250-5 cce@sle15: CCE-85841-5 + cce@sle16: CCE-96666-3 references: cis-csc: 1,12,15,16 diff --git a/linux_os/guide/system/accounts/accounts-pam/package_authselect_installed/rule.yml b/linux_os/guide/system/accounts/accounts-pam/package_authselect_installed/rule.yml index 0435216520b7..44105c3ba1a7 100644 --- a/linux_os/guide/system/accounts/accounts-pam/package_authselect_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/package_authselect_installed/rule.yml @@ -18,9 +18,7 @@ severity: medium identifiers: cce@rhel8: CCE-89186-1 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="authselect") }}}' +{{{ complete_ocil_entry_package_installed("authselect") }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-pam/package_pam_installed/rule.yml b/linux_os/guide/system/accounts/accounts-pam/package_pam_installed/rule.yml index 8a1043ea30c4..ab43dd7253a8 100644 --- a/linux_os/guide/system/accounts/accounts-pam/package_pam_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/package_pam_installed/rule.yml @@ -17,9 +17,7 @@ severity: medium identifiers: cce@rhel8: CCE-89184-6 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="pam") }}}' +{{{ complete_ocil_entry_package_installed("pam") }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-pam/package_pam_pwquality_installed/rule.yml b/linux_os/guide/system/accounts/accounts-pam/package_pam_pwquality_installed/rule.yml index 4681a7f46e0a..c9d08e4bb907 100644 --- a/linux_os/guide/system/accounts/accounts-pam/package_pam_pwquality_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/package_pam_pwquality_installed/rule.yml @@ -1,3 +1,8 @@ +{{% if 'ubuntu' not in product and 'debian' not in product %}} + {{%- set package = "libpwquality" %}} +{{% else %}} + {{%- set package = "libpam-pwquality" %}} +{{% endif %}} documentation_complete: true @@ -27,14 +32,7 @@ identifiers: references: srg: SRG-OS-000480-GPOS-00225 -ocil_clause: 'the package is not installed' - -ocil: |- -{{%- if 'ubuntu' not in product and 'debian' not in product %}} - {{{ ocil_package(package="libpwquality") }}} -{{%- else %}} - {{{ ocil_package(package="libpam-pwquality") }}} -{{%- endif %}} +{{{ complete_ocil_entry_package_installed(package=package) }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ocredit/rule.yml b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ocredit/rule.yml index b8086a960a02..06794ce968d2 100644 --- a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ocredit/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ocredit/rule.yml @@ -21,6 +21,7 @@ severity: medium identifiers: cce@sle12: CCE-83169-3 cce@sle15: CCE-85574-2 + cce@sle16: CCE-96246-4 cce@slmicro5: CCE-93767-2 cce@slmicro6: CCE-94701-0 diff --git a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ucredit/rule.yml b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ucredit/rule.yml index 780f603045c1..f480c5d0113f 100644 --- a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ucredit/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pamcracklib/cracklib_accounts_password_pam_ucredit/rule.yml @@ -21,6 +21,7 @@ severity: medium identifiers: cce@sle12: CCE-83166-9 cce@sle15: CCE-85675-7 + cce@sle16: CCE-96294-4 cce@slmicro5: CCE-93762-3 cce@slmicro6: CCE-94637-6 diff --git a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/ansible/shared.yml index e95e96d9e49f..0ec1a6db3f67 100644 --- a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/ansible/shared.yml @@ -13,6 +13,10 @@ {{{ ansible_instantiate_variables("var_password_pam_retry") }}} +{{% if product == 'sle16' %}} +{{{ ansible_copy_distro_defaults('/usr/lib/security/pwquality.conf', pwquality_path, rule_title=rule_title) }}} +{{% endif %}} + {{% if product in ['rhel8', 'rhel9', 'almalinux', 'sle15', 'sle16'] -%}} - name: Ensure PAM variable retry is set accordingly ansible.builtin.lineinfile: diff --git a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/bash/shared.sh b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/bash/shared.sh index 038b92cbe0d9..246a0a1a4ef9 100644 --- a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/bash/shared.sh @@ -11,6 +11,10 @@ {{{ bash_instantiate_variables("var_password_pam_retry") }}} +{{% if product == 'sle16' %}} +{{{ bash_copy_distro_defaults('/usr/lib/security/pwquality.conf', pwquality_path) }}} +{{% endif %}} + {{% if 'rhel' in product or product in ['sle15', 'sle16'] -%}} {{{ bash_replace_or_append(pwquality_path, '^retry', diff --git a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/tests/pwquality_conf_correct.pass.sh b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/tests/pwquality_conf_correct.pass.sh index dba54f3dc80a..5b8cf70934ff 100644 --- a/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/tests/pwquality_conf_correct.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/password_quality/password_quality_pwquality/accounts_password_pam_retry/tests/pwquality_conf_correct.pass.sh @@ -1,7 +1,11 @@ #!/bin/bash -# packages = authselect -# platform = multi_platform_rhel +# platform = multi_platform_rhel,multi_platform_sle # variables = var_password_pam_retry=3 +{{% if product in ['sle15', 'sle16'] %}} +# packages = libpwquality1 +{{% else %}} +# packages = authselect +{{% endif %}} source common.sh @@ -13,10 +17,11 @@ if grep -q "^.*retry\s*=" "$CONF_FILE"; then else echo "retry = $retry_cnt" >> "$CONF_FILE" fi - +{{% if product not in ['sle15', 'sle16'] %}} for file in ${configuration_files[@]}; do echo "password required pam_pwquality.so" >> \ "/etc/authselect/custom/testingProfile/$file" done authselect apply-changes +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/bash/shared.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/bash/shared.sh deleted file mode 100644 index e6e1362bee8d..000000000000 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/bash/shared.sh +++ /dev/null @@ -1,3 +0,0 @@ -# platform = multi_platform_sle - -{{{ bash_ensure_pam_module_options('/etc/pam.d/common-auth', 'auth', 'required', 'pam_unix.so', 'sha512', '', '') }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/rule.yml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/rule.yml index 34b4754a9757..6ec113bd3fb3 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/rule.yml @@ -56,7 +56,11 @@ template: vars: path: /etc/pam.d/common-auth type: auth + {{% if 'sle' in product %}} + control_flag: sufficient + {{% else %}} control_flag: required + {{% endif %}} module: pam_unix.so arguments: - argument: sha512 diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth-missing.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth-missing.fail.sh new file mode 100644 index 000000000000..d72b296fd04e --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth-missing.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 + +if [ -e "/etc/pam.d/common-auth" ] ; then + rm "/etc/pam.d/common-auth" +fi diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sha512.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sha512.fail.sh index 783e038cef8e..dea2666d2a4d 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sha512.fail.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sha512.fail.sh @@ -1,4 +1,4 @@ #!/bin/bash -# platform = SUSE Linux Enterprise 15 +# platform = SUSE Linux Enterprise 15, SUSE Linux Enterprise 16 -echo "auth required pam_unix.so try_first_pass" > /etc/pam.d/common-auth +echo "auth sufficient pam_unix.so try_first_pass" > /etc/pam.d/common-auth diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_required.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sufficient.fail.sh similarity index 59% rename from linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_required.fail.sh rename to linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sufficient.fail.sh index 3a8ec66a07d8..86d38fbdf108 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_required.fail.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pam_unix_not_sufficient.fail.sh @@ -1,4 +1,4 @@ #!/bin/bash -# platform = SUSE Linux Enterprise 15 +# platform = SUSE Linux Enterprise 15, SUSE Linux Enterprise 16 echo "auth optional pam_unix.so try_first_pass sha512" > /etc/pam.d/common-auth diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pass.sh index 273189d6a9d8..b7eb97585b3b 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_commonauth/tests/common-auth.pass.sh @@ -1,4 +1,4 @@ #!/bin/bash -# platform = SUSE Linux Enterprise 15 +# platform = SUSE Linux Enterprise 15, SUSE Linux Enterprise 16 -echo "auth required pam_unix.so try_first_pass sha512" > /etc/pam.d/common-auth +echo "auth sufficient pam_unix.so try_first_pass sha512" > /etc/pam.d/common-auth diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/ansible/shared.yml index e7d093ace80c..e57f008a17da 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/ansible/shared.yml @@ -6,6 +6,17 @@ {{{ ansible_instantiate_variables("var_password_hashing_algorithm") }}} +{{% if product in [ 'slmicro6', 'sle16' ] %}} +{{% set cce_cce_identifier = cce_identifiers['cce'] %}} +{{{ + ansible_login_defs( + parameter='ENCRYPT_METHOD', + value='{{ var_password_hashing_algorithm.split("|")[0] }}', + rule_title=rule_title, + cce=cce_cce_identifier + ) +}}} +{{% else %}} - name: Set Password Hashing Algorithm in {{{ login_defs_path }}} ansible.builtin.lineinfile: dest: {{{ login_defs_path }}} @@ -13,3 +24,4 @@ line: ENCRYPT_METHOD {{ var_password_hashing_algorithm.split('|')[0] }} state: present create: yes +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/bash/shared.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/bash/shared.sh index 9364d1f9b810..cf504dcf6014 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/bash/shared.sh @@ -6,4 +6,8 @@ # var_password_hashing_algorithm="$(echo $var_password_hashing_algorithm | cut -d \| -f 1)" +{{% if product in [ 'slmicro6', 'sle16' ] %}} +{{{ bash_login_defs("ENCRYPT_METHOD", "$var_password_hashing_algorithm", cce_identifiers=cce_identifiers) }}} +{{% else %}} {{{ bash_replace_or_append(login_defs_path, '^ENCRYPT_METHOD', "$var_password_hashing_algorithm", '%s %s', cce_identifiers=cce_identifiers) }}} +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/oval/shared.xml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/oval/shared.xml index 78972d501099..c66653322faf 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/oval/shared.xml @@ -1,53 +1,64 @@ - {{{ oval_metadata("The password hashing algorithm should be set correctly in /usr/etc/login.defs.", rule_title=rule_title) }}} + {{{ oval_metadata("The password hashing algorithm should be set correctly in " + login_defs_path + ".", rule_title=rule_title) }}} + {{% if product in [ 'slmicro6', 'sle16' ] %}} + + + + + + + + + + {{% else %}} - + + {{% endif %}} - - - - - - - - - {{{ login_defs_path }}} - - .*\n[^#]*(ENCRYPT_METHOD\s+\w+)\s*\n - 1 - - - - - - - - - - - - variable_last_encrypt_method_instance_value - +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_path, + parameter="ENCRYPT_METHOD", + pattern="^[\s]*(?i)(ENCRYPT_METHOD[\s]+\w+)[\s]*(?:#.*)?$", + regex_capture="ENCRYPT_METHOD\s+(\w+)", + operation="pattern match", + type="string", + test_id="test_password_hashing_algorithm_logindefs", + variable="var_password_hashing_algorithm" +) +}}} +{{% set login_defs_drop_in_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) %}} +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_drop_in_config_dir, + filename_regex=".*\.defs$", + parameter="ENCRYPT_METHOD", + pattern="^[\s]*(?i)(ENCRYPT_METHOD[\s]+\w+)[\s]*(?:#.*)?$", + regex_capture="ENCRYPT_METHOD\s+(\w+)", + operation="pattern match", + type="string", + test_id="test_password_hashing_algorithm_logindefs_drop_in_path", + variable="var_password_hashing_algorithm" +) +}}} - - - - - + + + - - - ^ - - $ - - + + {{{ login_defs_drop_in_config_dir }}} + .*\.defs$ + ^\s*ENCRYPT_METHOD\s* + 1 + - diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/correct_value_drop_in_path.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/correct_value_drop_in_path.pass.sh new file mode 100644 index 000000000000..48b58a765f9a --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/correct_value_drop_in_path.pass.sh @@ -0,0 +1,15 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_algorithm=SHA512 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^ENCRYPT_METHOD" {{{ login_defs_path }}} ; then + sed -i "s/ENCRYPT_METHOD.*/ENCRYPT_METHOD MD5/g" {{{ login_defs_path }}} +else + echo "ENCRYPT_METHOD MD5" >> {{{ login_defs_path }}} +fi +echo "ENCRYPT_METHOD SHA512" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/incorrect_value_drop_in_path.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/incorrect_value_drop_in_path.fail.sh new file mode 100644 index 000000000000..a561b03e5fea --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/incorrect_value_drop_in_path.fail.sh @@ -0,0 +1,14 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_algorithm=SHA512 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} +if grep -q "^ENCRYPT_METHOD" {{{ login_defs_path }}} ; then + sed -i "s/ENCRYPT_METHOD.*/ENCRYPT_METHOD SHA512/g" {{{ login_defs_path }}} +else + echo "ENCRYPT_METHOD SHA512" >> {{{ login_defs_path }}} +fi +echo "ENCRYPT_METHOD MD5" >> "/etc/login.defs.d/user.dropin.defs" diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/incorrect_value_dropin.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/incorrect_value_dropin.fail.sh new file mode 100644 index 000000000000..ce86c465fc43 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_algorithm_logindefs/tests/incorrect_value_dropin.fail.sh @@ -0,0 +1,14 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_algorithm=SHA512 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} +if grep -q "^ENCRYPT_METHOD" {{{ login_defs_path }}} ; then + sed -i "s/ENCRYPT_METHOD.*/ENCRYPT_METHOD SHA512/g" {{{ login_defs_path }}} +else + echo "ENCRYPT_METHOD SHA512" >> {{{ login_defs_path }}} +fi +echo "ENCRYPT_METHOD MD5" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/ansible/shared.yml index a149b7614cd4..f245ba0f8407 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/ansible/shared.yml @@ -6,6 +6,25 @@ {{{ ansible_instantiate_variables("var_password_hashing_min_rounds_login_defs") }}} +{{% if product in [ 'sle16', 'slmicro6' ] %}} +{{% set cce_cce_identifier = cce_identifiers['cce'] %}} +{{{ + ansible_login_defs( + parameter='SHA_CRYPT_MIN_ROUNDS', + value='{{ var_password_hashing_min_rounds_login_defs }}', + rule_title=rule_title, + cce=cce_cce_identifier + ) +}}} +{{{ + ansible_login_defs( + parameter='SHA_CRYPT_MAX_ROUNDS', + value='{{ var_password_hashing_min_rounds_login_defs }}', + rule_title=rule_title, + cce=cce_cce_identifier + ) +}}} +{{% else %}} - name: "{{{ rule_title }}} - extract contents of the file {{{ login_defs_path }}}" ansible.builtin.slurp: src: {{{ login_defs_path }}} @@ -48,3 +67,4 @@ path: {{{ login_defs_path }}} state: present when: etc_login_defs_sha_crypt_max_rounds | length == 0 +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/bash/shared.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/bash/shared.sh index 5f576220482e..1fba52ea4ec8 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/bash/shared.sh @@ -2,6 +2,27 @@ {{{ bash_instantiate_variables("var_password_hashing_min_rounds_login_defs") }}} +{{% if product == [ 'sle16', 'slmicro6' ] %}} +{{% set login_defs_d_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) ~ "/*.defs" %}} + +min_rounds_login_defs=$(grep -Po '^\s*SHA_CRYPT_MIN_ROUNDS\s+\K\d+' {{{ login_defs_d_config_dir }}}) +if [[ -z "$min_rounds_login_defs" ]]; then + min_rounds_login_defs=$(grep -Po '^\s*SHA_CRYPT_MIN_ROUNDS\s+\K\d+' {{{ login_defs_path }}}) +fi +if [[ -z "$min_rounds_login_defs" || "$min_rounds_login_defs" -le "$var_password_hashing_min_rounds_login_defs" ]]; then + {{{ bash_login_defs("SHA_CRYPT_MIN_ROUNDS", "$var_password_hashing_min_rounds_login_defs", cce_identifiers=cce_identifiers) }}} +fi + +max_rounds_login_defs=$(grep -Po '^\s*SHA_CRYPT_MAX_ROUNDS\s+\K\d+' {{{ login_defs_d_config_dir }}}) +if [[ -z "$max_rounds_login_defs" ]]; then + max_rounds_login_defs=$(grep -Po '^\s*SHA_CRYPT_MAX_ROUNDS\s+\K\d+' {{{ login_defs_path }}}) +fi +if [[ -z "$max_rounds_login_defs" || "$max_rounds_login_defs" -le "$var_password_hashing_min_rounds_login_defs" ]]; then + {{{ bash_login_defs("SHA_CRYPT_MAX_ROUNDS", "$var_password_hashing_min_rounds_login_defs", cce_identifiers=cce_identifiers) }}} +fi + +{{% else %}} + config_file={{{ login_defs_path }}} current_min_rounds=$(grep -Po '^\s*SHA_CRYPT_MIN_ROUNDS\s+\K\d+' "$config_file") current_max_rounds=$(grep -Po '^\s*SHA_CRYPT_MAX_ROUNDS\s+\K\d+' "$config_file") @@ -21,3 +42,4 @@ if [[ -n "$current_max_rounds" && "$current_max_rounds" -le "$var_password_hashi separator=" ", separator_regex="\s*", rule_id=rule_id) | indent(4) }}} fi +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/oval/sle16.xml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/oval/sle16.xml new file mode 100644 index 000000000000..b46171d1021e --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/oval/sle16.xml @@ -0,0 +1,109 @@ + + + {{{ oval_metadata("The password hashing minimum rounds should be set correctly.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_path, + parameter="SHA_CRYPT_MIN_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MIN_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MIN_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_min_rounds_logindefs" +) +}}} + +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_path, + parameter="SHA_CRYPT_MAX_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MAX_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MAX_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_max_rounds_logindefs" +) +}}} + +{{% set login_defs_drop_in_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) %}} +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_drop_in_config_dir, + filename_regex=".*\.defs$", + parameter="SHA_CRYPT_MIN_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MIN_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MIN_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_min_rounds_logindefs_drop_in_path" +) +}}} + +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_drop_in_config_dir, + filename_regex=".*\.defs$", + parameter="SHA_CRYPT_MAX_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MAX_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MAX_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_max_rounds_logindefs_drop_in_path" +) +}}} + + + + + + + {{{ login_defs_drop_in_config_dir }}} + .*\.defs$ + ^\s*SHA_CRYPT_MIN_ROUNDS\s* + 1 + + + + + + + + {{{ login_defs_drop_in_config_dir }}} + .*\.defs$ + ^\s*SHA_CRYPT_MAX_ROUNDS\s* + 1 + + diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/oval/slmicro6.xml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/oval/slmicro6.xml new file mode 100644 index 000000000000..b46171d1021e --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/oval/slmicro6.xml @@ -0,0 +1,109 @@ + + + {{{ oval_metadata("The password hashing minimum rounds should be set correctly.", rule_title=rule_title) }}} + + + + + + + + + + + + + + + +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_path, + parameter="SHA_CRYPT_MIN_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MIN_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MIN_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_min_rounds_logindefs" +) +}}} + +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_path, + parameter="SHA_CRYPT_MAX_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MAX_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MAX_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_max_rounds_logindefs" +) +}}} + +{{% set login_defs_drop_in_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) %}} +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_drop_in_config_dir, + filename_regex=".*\.defs$", + parameter="SHA_CRYPT_MIN_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MIN_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MIN_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_min_rounds_logindefs_drop_in_path" +) +}}} + +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_drop_in_config_dir, + filename_regex=".*\.defs$", + parameter="SHA_CRYPT_MAX_ROUNDS", + pattern="^[\s]*(?i)(SHA_CRYPT_MAX_ROUNDS[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="SHA_CRYPT_MAX_ROUNDS\s+(\d+)", + operation="greater than or equal", + type="int", + variable="var_password_hashing_min_rounds_login_defs", + test_id="test_sha_crypt_max_rounds_logindefs_drop_in_path" +) +}}} + + + + + + + {{{ login_defs_drop_in_config_dir }}} + .*\.defs$ + ^\s*SHA_CRYPT_MIN_ROUNDS\s* + 1 + + + + + + + + {{{ login_defs_drop_in_config_dir }}} + .*\.defs$ + ^\s*SHA_CRYPT_MAX_ROUNDS\s* + 1 + + diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/rule.yml b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/rule.yml index f1bae24320ee..6c728f535085 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/rule.yml +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/rule.yml @@ -29,6 +29,7 @@ identifiers: cce@rhel10: CCE-90508-3 cce@sle12: CCE-83171-9 cce@sle15: CCE-85567-6 + cce@sle16: CCE-95736-5 cce@slmicro5: CCE-93682-3 cce@slmicro6: CCE-94660-8 diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values.pass.sh index de1337c2f26a..b3614d55df6e 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values.pass.sh @@ -1,5 +1,9 @@ #!/bin/bash # variables = var_password_hashing_min_rounds_login_defs=5000 +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi + echo "SHA_CRYPT_MIN_ROUNDS 5000" > {{{ login_defs_path }}} echo "SHA_CRYPT_MAX_ROUNDS 5000" >> {{{ login_defs_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values_drop_in.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values_drop_in.pass.sh new file mode 100644 index 000000000000..a64c0a6c6c05 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/correct_values_drop_in.pass.sh @@ -0,0 +1,22 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_min_rounds_login_defs=5000 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^SHA_CRYPT_MIN_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MIN_ROUNDS.*/SHA_CRYPT_MIN_ROUNDS 4999/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MIN_ROUNDS 4999" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MIN_ROUNDS 10000" >> {{{ login_defs_drop_in_path }}} + +if grep -q "^SHA_CRYPT_MAX_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MAX_ROUNDS.*/SHA_CRYPT_MAX_ROUNDS 4999/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MAX_ROUNDS 4999" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MAX_ROUNDS 10000" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_max_parameter.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_max_parameter.pass.sh index ecfec522480d..df3a915f9ebd 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_max_parameter.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_max_parameter.pass.sh @@ -1,4 +1,7 @@ #!/bin/bash +{{% if product == "sle16" %}} +# platform = Not Applicable +{{% endif %}} # variables = var_password_hashing_min_rounds_login_defs=5000 # Default values are 5000 if the parameters are not defined. diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_min_parameter.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_min_parameter.pass.sh index a57ccdc11c96..12184f32885b 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_min_parameter.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_min_parameter.pass.sh @@ -1,4 +1,7 @@ #!/bin/bash +{{% if product == "sle16" %}} +# platform = Not Applicable +{{% endif %}} # variables = var_password_hashing_min_rounds_login_defs=5000 # Default values are 5000 if the parameters are not defined. diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_parameters.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_parameters.pass.sh index ada26488c1a2..8040c58df4ed 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_parameters.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/missing_parameters.pass.sh @@ -1,4 +1,7 @@ #!/bin/bash +{{% if product == "sle16" %}} +# platform = Not Applicable +{{% endif %}} # variables = var_password_hashing_min_rounds_login_defs=5000 # Default values are 5000 if the parameters are not defined. diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong.pass.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong.pass.sh index c03dbe93d4c8..bfaea876d725 100644 --- a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong.pass.sh +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong.pass.sh @@ -1,4 +1,7 @@ #!/bin/bash +{{% if product == "sle16" %}} +# platform = Not Applicable +{{% endif %}} # variables = var_password_hashing_min_rounds_login_defs=5000 echo "SHA_CRYPT_MIN_ROUNDS 5000" > {{{ login_defs_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong_drop_in.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong_drop_in.fail.sh new file mode 100644 index 000000000000..859953713530 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_max_value_wrong_drop_in.fail.sh @@ -0,0 +1,22 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_min_rounds_login_defs=5000 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^SHA_CRYPT_MIN_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MIN_ROUNDS.*/SHA_CRYPT_MIN_ROUNDS 1/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MIN_ROUNDS 1" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MIN_ROUNDS 5000" >> {{{ login_defs_drop_in_path }}} + +if grep -q "^SHA_CRYPT_MAX_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MAX_ROUNDS.*/SHA_CRYPT_MAX_ROUNDS 1/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MAX_ROUNDS 1" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MAX_ROUNDS 4999" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_min_value_wrong_drop_in.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_min_value_wrong_drop_in.fail.sh new file mode 100644 index 000000000000..6741a8704839 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/only_min_value_wrong_drop_in.fail.sh @@ -0,0 +1,22 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_min_rounds_login_defs=5000 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^SHA_CRYPT_MIN_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MIN_ROUNDS.*/SHA_CRYPT_MIN_ROUNDS 1/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MIN_ROUNDS 1" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MIN_ROUNDS 4999" >> {{{ login_defs_drop_in_path }}} + +if grep -q "^SHA_CRYPT_MAX_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MAX_ROUNDS.*/SHA_CRYPT_MAX_ROUNDS 1/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MAX_ROUNDS 1" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MAX_ROUNDS 5000" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/wrong_values_drop_in.fail.sh b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/wrong_values_drop_in.fail.sh new file mode 100644 index 000000000000..8e0c52eeeae9 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-pam/set_password_hashing_algorithm/set_password_hashing_min_rounds_logindefs/tests/wrong_values_drop_in.fail.sh @@ -0,0 +1,22 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_password_hashing_min_rounds_login_defs=5000 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^SHA_CRYPT_MIN_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MIN_ROUNDS.*/SHA_CRYPT_MIN_ROUNDS 5000/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MIN_ROUNDS 5000" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MIN_ROUNDS 4999" >> {{{ login_defs_drop_in_path }}} + +if grep -q "^SHA_CRYPT_MAX_ROUNDS" {{{ login_defs_path }}} ; then + sed -i "s/SHA_CRYPT_MAX_ROUNDS.*/SHA_CRYPT_MAX_ROUNDS 5000/g" {{{ login_defs_path }}} +else + echo "SHA_CRYPT_MAX_ROUNDS 5000" >> {{{ login_defs_path }}} +fi +echo "SHA_CRYPT_MAX_ROUNDS 4999" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/ansible/shared.yml index 13dbf9ec612f..bb1894435ae8 100644 --- a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/ansible/shared.yml @@ -6,7 +6,22 @@ {{{ ansible_instantiate_variables("var_logind_session_timeout") }}} -{{% if product in ["sle15", "sle16"] %}} +- name: Remove StopIdleSessionSec from main config + ansible.builtin.lineinfile: + path: /etc/systemd/logind.conf + regexp: '^\s*StopIdleSessionSec\s*=' + state: absent + +{{% if product in ["ol9", "ol10", "rhel9", "rhel10", "sle15", "sle16"] %}} + +- name: Remove StopIdleSessionSec from drop-in files + ansible.builtin.lineinfile: + path: "{{ item }}" + regexp: '^\s*StopIdleSessionSec\s*=' + state: absent + with_fileglob: + - /etc/systemd/logind.conf.d/*.conf + # create drop-in in the /etc/systemd/logind.conf.d/ directory {{% set logind_conf_file = "/etc/systemd/logind.conf.d/oscap-idle-sessions.conf" %}} {{% else %}} diff --git a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/bash/shared.sh b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/bash/shared.sh index 72a2ca90de7e..ea7d0c1caea4 100644 --- a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/bash/shared.sh @@ -2,9 +2,15 @@ {{{ bash_instantiate_variables("var_logind_session_timeout") }}} -{{% if product in ["sle15", "sle16"] %}} +# Remove StopIdleSessionSec from main config +{{{ lineinfile_absent("/etc/systemd/logind.conf", "^\s*StopIdleSessionSec\s*=", insensitive=true, rule_id=rule_id) }}} + +{{% if product in ["ol9", "ol10", "rhel9", "rhel10", "sle15", "sle16"] %}} # create drop-in in the /etc/systemd/logind.conf.d/ directory {{% set logind_conf_file = "/etc/systemd/logind.conf.d/oscap-idle-sessions.conf" %}} +mkdir -p "/etc/systemd/logind.conf.d/" +# remove StopIdleSessionSec from drop-in files +{{{ lineinfile_absent_in_directory("/etc/systemd/logind.conf.d", "^\s*StopIdleSessionSec\s*=", insensitive=true, filename_glob="*.conf") | indent(4) }}} {{% else %}} {{% set logind_conf_file = "/etc/systemd/logind.conf" %}} {{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/oval/shared.xml b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/oval/shared.xml index e4466d9b0c9b..3ea13bc7f07f 100644 --- a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/oval/shared.xml @@ -1,4 +1,4 @@ -{{% if product in ["sle15", "sle16"] %}} +{{% if product in ["ol9", "ol10", "rhel9", "rhel10", "sle15", "sle16"] %}} {{% set logind_conf_file = "/etc/systemd/logind.conf.d/" %}} {{% else %}} {{% set logind_conf_file = "/etc/systemd/logind.conf" %}} @@ -6,7 +6,7 @@ - {{% if product in ["sle15", "sle16"] %}} + {{% if product in ["ol9", "ol10", "rhel9", "rhel10", "sle15", "sle16"] %}} {{{ oval_metadata("Ensure 'StopIdleSessionSec' is configured with desired value in section 'Login' in {{{ logind_conf_file }}}", rule_title=rule_title) }}} diff --git a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/rule.yml b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/rule.yml index 0a3c6db76c18..e9732656fe7a 100644 --- a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/rule.yml @@ -21,6 +21,7 @@ platforms: - os_linux[rhel]>=8.7 and os_linux[rhel]!=9.0 - os_linux[ol]>=8.7 - os_linux[sles]>=15 + - os_linux[amzn]==2023 identifiers: cce@rhel8: CCE-90784-0 diff --git a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/common.sh b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/common.sh index 441b663d9240..ce6a75106687 100644 --- a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/common.sh +++ b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/common.sh @@ -3,7 +3,7 @@ # this file prepares unified test environment used by other scenarios # These should be tuned per product to match defaults -{{% if product in ["sle15", "sle16"] %}} +{{% if product in ["ol9", "ol10", "rhel9", "rhel10", "sle15", "sle16"] %}} LOGIND_CONF_FILE="/etc/systemd/logind.conf.d/oscap-idle-sessions.conf" mkdir -p /etc/systemd/logind.conf.d/ {{% else %}} diff --git a/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/dir_missing.fail.sh b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/dir_missing.fail.sh new file mode 100644 index 000000000000..8f1db2d9320b --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-physical/logind_session_timeout/tests/dir_missing.fail.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +{{% if product in ["rhel9", "rhel10", "sle15", "sle16"] %}} +rm -rf "/etc/systemd/logind.conf.d/" +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/ansible/shared.yml index 0faa359e3937..a8bf7416aa2e 100644 --- a/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/ansible/shared.yml @@ -11,6 +11,7 @@ dest: /etc/systemd/system/emergency.service.d/10-oscap.conf block: | [Service] + ExecStart= ExecStart=-/usr/lib/systemd/systemd-sulogin-shell emergency {{% else %}} - name: Require emergency mode password diff --git a/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/bash/shared.sh b/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/bash/shared.sh index a9995656d996..43dda82dea2f 100644 --- a/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-physical/require_emergency_target_auth/bash/shared.sh @@ -16,6 +16,7 @@ sulogin='/bin/sh -c "/sbin/sulogin; /usr/bin/systemctl --fail --no-block default {{% if 'sle' in product or 'rhel' in product or product == 'fedora' or product == 'slmicro5' or 'ol' in families %}} mkdir -p "${service_dropin_cfg_dir}" echo "[Service]" >> "${service_dropin_file}" +echo "ExecStart=" >> "${service_dropin_file}" echo "ExecStart=-$sulogin" >> "${service_dropin_file}" {{% else %}} if grep "^ExecStart=.*" "$service_file" ; then diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_screen_installed/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_screen_installed/rule.yml index d81d6ad11eb0..5837737c0a3d 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_screen_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_screen_installed/rule.yml @@ -38,9 +38,7 @@ references: srg: SRG-OS-000029-GPOS-00010 stigid@ol7: OL07-00-010090 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="screen") }}}' +{{{ complete_ocil_entry_package_installed("screen") }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_tmux_installed/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_tmux_installed/rule.yml index 472131ead727..b33652090fcb 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_tmux_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/package_tmux_installed/rule.yml @@ -42,9 +42,7 @@ references: ospp: FMT_SMF_EXT.1,FMT_MOF_EXT.1,FTA_SSL.1 srg: SRG-OS-000030-GPOS-00011,SRG-OS-000028-GPOS-00009 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="tmux") }}}' +{{{ complete_ocil_entry_package_installed("tmux") }}} fixtext: '{{{ describe_package_install(package="tmux") }}}' diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/vlock_installed/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/vlock_installed/rule.yml index da1771e5bfff..847d74aedec5 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/vlock_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/console_screen_locking/vlock_installed/rule.yml @@ -1,3 +1,9 @@ +{{% if 'ubuntu' in product %}} + {{%- set package = "vlock" %}} +{{% else %}} + {{%- set package = "kbd" %}} +{{% endif %}} + documentation_complete: true @@ -6,11 +12,7 @@ title: 'Check that vlock is installed to allow session locking' description: |- The {{{ full_name }}} operating system must have vlock installed to allow for session locking. - {{% if 'ubuntu' in product %}} - {{{ describe_package_install(package="vlock") }}} - {{% else %}} - {{{ describe_package_install(package="kbd") }}} - {{% endif %}} + {{{ describe_package_install(package=package) }}} rationale: |- A session lock is a temporary action taken when a user stops work and @@ -41,14 +43,7 @@ references: stigid@sle12: SLES-12-010070 stigid@sle15: SLES-15-010110 -ocil_clause: 'the package is not installed' - -ocil: |- - {{% if 'ubuntu' in product %}} - {{{ ocil_package(package="vlock") }}} - {{% else %}} - {{{ ocil_package(package="kbd") }}} - {{% endif %}} +{{{ complete_ocil_entry_package_installed(package) }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/install_smartcard_packages/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/install_smartcard_packages/rule.yml index 0012f81f5918..cd2393b0c761 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/install_smartcard_packages/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/install_smartcard_packages/rule.yml @@ -61,9 +61,13 @@ ocil_clause: 'smartcard software is not installed' ocil: |- Check that {{{ full_name }}} has the packages for smart card support installed. + {{% if pkg_system is undefined or pkg_system not in ["rpm", "dpkg"] %}} + JINJA MACRO ERROR - Unknown package system '{{{ pkg_system | default("undefined") }}}'. Has to be either 'rpm' or 'dpkg'. + {{% else %}} {{% for pkg in smartcard_packages %}} - {{{ ocil_package(package=pkg) }}} + Run the following command to determine if the {{{ pkg }}} package is installed:
$ {{% if pkg_system == "rpm" %}}rpm -q {{% elif pkg_system == "dpkg" %}}dpkg -l {{% endif %}}{{{ pkg }}}
{{% endfor %}} + {{% endif %}} {{% if product not in ["sle12", "sle15", "slmicro5", "slmicro6"] %}} template: diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_opensc_installed/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_opensc_installed/rule.yml index 3a85ae9df616..b46b481548ea 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_opensc_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_opensc_installed/rule.yml @@ -1,14 +1,15 @@ +{{% if 'ubuntu' not in product %}} + {{%- set package = "opensc" %}} +{{% else %}} + {{%- set package = "opensc-pkcs11" %}} +{{% endif %}} documentation_complete: true -title: 'Install the opensc Package For Multifactor Authentication' +title: 'Install the {{{ package }}} Package For Multifactor Authentication' description: |- - {{% if 'ubuntu' not in product %}} - {{{ describe_package_install(package="opensc") }}} - {{% else %}} - {{{ describe_package_install(package="opensc-pkcs11") }}} - {{% endif %}} + {{{ describe_package_install(package=package) }}} rationale: |- Using an authentication device, such as a CAC or token that is separate from @@ -33,13 +34,7 @@ references: srg: SRG-OS-000375-GPOS-00160,SRG-OS-000376-GPOS-00161 stigid@ol8: OL08-00-010410 -ocil_clause: 'the package is not installed' - -{{% if 'ubuntu' not in product %}} -ocil: '{{{ ocil_package(package="opensc") }}}' -{{% else %}} -ocil: '{{{ ocil_package(package="opensc-pkcs11") }}}' -{{% endif %}} +{{{ complete_ocil_entry_package_installed(package) }}} template: name: package_installed @@ -48,15 +43,7 @@ template: pkgname@ubuntu2204: opensc-pkcs11 fixtext: |- - {{% if 'ubuntu' not in product %}} - {{{ describe_package_install(package="opensc") }}} - {{% else %}} - {{{ describe_package_install(package="opensc-pkcs11") }}} - {{% endif %}} + {{{ describe_package_install(package=package) }}} srg_requirement: |- - {{% if 'ubuntu' not in product %}} - {{{ srg_requirement_package_installed(package="opensc") | indent(4) }}} - {{% else %}} - {{{ srg_requirement_package_installed(package="opensc-pkcs11") | indent(4) }}} - {{% endif %}} + {{{ srg_requirement_package_installed(package=package) | indent(4) }}} diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite-ccid_installed/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite-ccid_installed/rule.yml index 778e50eea75f..1a237c660281 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite-ccid_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite-ccid_installed/rule.yml @@ -20,9 +20,7 @@ references: nist: CM-6(a) srg: SRG-OS-000375-GPOS-00160 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="pcsc-lite-ccid") }}}' +{{{ complete_ocil_entry_package_installed("pcsc-lite-ccid") }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite_installed/rule.yml b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite_installed/rule.yml index 7ac4e6621db6..a1fc81bbdc0e 100644 --- a/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite_installed/rule.yml +++ b/linux_os/guide/system/accounts/accounts-physical/screen_locking/smart_card_login/package_pcsc-lite_installed/rule.yml @@ -21,9 +21,7 @@ references: nist: CM-6(a) srg: SRG-OS-000375-GPOS-00160 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="pcsc-lite") }}}' +{{{ complete_ocil_entry_package_installed("pcsc-lite") }}} template: name: package_installed diff --git a/linux_os/guide/system/accounts/accounts-restrictions/accounts_authorized_local_users/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/accounts_authorized_local_users/rule.yml index 2340d6eedd1f..d5ef8e9d5908 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/accounts_authorized_local_users/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/accounts_authorized_local_users/rule.yml @@ -25,6 +25,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88196-1 cce@rhel8: CCE-85987-6 cce@rhel9: CCE-88048-4 cce@rhel10: CCE-88135-9 @@ -43,7 +44,7 @@ references: ocil_clause: 'there are unauthorized local user accounts on the system' -{{% if 'rhel' in product or 'ol' in families or 'slmicro5' in product %}} +{{% if 'rhel' in product or 'ol' in families or 'slmicro5' in product or 'rhcos' in product %}} warnings: - general: |- Automatic remediation of this control is not available due to the unique diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_minlen_login_defs/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_minlen_login_defs/rule.yml index 03693d6cf2e2..47fb7a0810d9 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_minlen_login_defs/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_minlen_login_defs/rule.yml @@ -29,6 +29,7 @@ identifiers: cce@rhel10: CCE-87452-9 cce@sle12: CCE-83257-6 cce@sle15: CCE-91168-5 + cce@sle16: CCE-95762-1 references: cis-csc: 1,12,15,16,5 @@ -41,7 +42,6 @@ references: nist: IA-5(f),IA-5(1)(a),CM-6(a) nist-csf: PR.AC-1,PR.AC-6,PR.AC-7 srg: SRG-OS-000078-GPOS-00046 - stigid@ol8: OL08-00-020231 ocil_clause: 'it is not set to the required value' diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/ansible/shared.yml index ebcb5ac0430d..66e566378c67 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/ansible/shared.yml @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel +# platform = multi_platform_rhel,multi_platform_sle # reboot = false # strategy = restrict # complexity = low diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/bash/shared.sh index 7bdb759f686f..b0f38d581bc0 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/bash/shared.sh @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel,multi_platform_debian +# platform = multi_platform_debian,multi_platform_rhel,multi_platform_sle # reboot = false # strategy = restrict # complexity = low diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/rule.yml index 97714adfda04..2cfd1a5396f5 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_set_max_life_root/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel8: CCE-87667-2 cce@rhel9: CCE-87668-0 cce@rhel10: CCE-88296-9 + cce@sle16: CCE-96252-2 ocil_clause: 'any results are returned that are not associated with a system account' diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/ansible/shared.yml index fa65688c5031..e9f0c2d4f329 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/ansible/shared.yml @@ -5,6 +5,17 @@ # disruption = low {{{ ansible_instantiate_variables("var_accounts_password_warn_age_login_defs") }}} +{{% if product in [ 'slmicro6', 'sle16' ] %}} +{{% set cce_cce_identifier = cce_identifiers['cce'] %}} +{{{ + ansible_login_defs( + parameter='PASS_WARN_AGE', + value='{{ var_accounts_password_warn_age_login_defs }}', + rule_title=rule_title, + cce=cce_cce_identifier + ) +}}} +{{% else %}} - name: "Set Password Warning Age" ansible.builtin.lineinfile: dest: {{{ login_defs_path }}} @@ -12,3 +23,4 @@ state: present line: "PASS_WARN_AGE {{ var_accounts_password_warn_age_login_defs }}" create: yes +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/bash/shared.sh index 67d735f6e69f..9b02b78a2907 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/bash/shared.sh @@ -1,4 +1,8 @@ # platform = multi_platform_all {{{ bash_instantiate_variables("var_accounts_password_warn_age_login_defs") }}} +{{% if product in [ 'slmicro6', 'sle16' ] %}} +{{{ bash_login_defs("PASS_WARN_AGE", "$var_accounts_password_warn_age_login_defs", cce_identifiers=cce_identifiers) }}} +{{% else %}} {{{ bash_replace_or_append(login_defs_path, '^PASS_WARN_AGE', "$var_accounts_password_warn_age_login_defs", '%s %s', cce_identifiers=cce_identifiers) }}} +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/oval/shared.xml index f1126c6c4b63..8026fe1d3f82 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/oval/shared.xml @@ -1,43 +1,64 @@ {{{ oval_metadata("The password expiration warning age should be set appropriately.", rule_title=rule_title) }}} - - + {{% if product in [ 'slmicro6', 'sle16' ] %}} + + + + + + + + + {{% else %}} + + + + {{% endif %}} - - - - - - - - - {{{ login_defs_path }}} - - .*\n[^#]*(PASS_WARN_AGE\s+\d+)\s*\n - 1 - - - - - - - - - - - - variable_last_pass_warn_age_instance_value - +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_path, + parameter="PASS_WARN_AGE", + pattern="^[\s]*(?i)(PASS_WARN_AGE[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="PASS_WARN_AGE\s+(\d+)", + variable="var_accounts_password_warn_age_login_defs", + operation="greater than or equal", + type="int", + test_id="test_pass_warn_age" +) +}}} +{{% set login_defs_drop_in_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) %}} +{{{ +oval_param_in_file_variable_test( + filepath=login_defs_drop_in_config_dir, + filename_regex=".*\.defs$", + parameter="PASS_WARN_AGE", + pattern="^[\s]*(?i)(PASS_WARN_AGE[\s]+\d+)[\s]*(?:#.*)?$", + regex_capture="PASS_WARN_AGE\s+(\d+)", + variable="var_accounts_password_warn_age_login_defs", + operation="greater than or equal", + type="int", + test_id="test_pass_warn_age_logindefs_drop_in_path" +) +}}} - - - - - + + + - + + {{{ login_defs_drop_in_config_dir }}} + .*\.defs$ + ^\s*PASS_WARN_AGE\s* + 1 + diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/bad_value.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/bad_value.fail.sh index 5c9b5d8a4999..afed1c1e85b3 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/bad_value.fail.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/bad_value.fail.sh @@ -1,5 +1,9 @@ #!/bin/bash +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi + grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} && \ sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE\t0/g" {{{ login_defs_path }}} if ! [ $? -eq 0 ]; then diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/commented.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/commented.fail.sh index 48a33c2e953c..14acce6ac842 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/commented.fail.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/commented.fail.sh @@ -1,5 +1,9 @@ #!/bin/bash +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi + grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} && \ sed -i "s/PASS_WARN_AGE.*/# PASS_WARN_AGE\t7/g" {{{ login_defs_path }}} if ! [ $? -eq 0 ]; then diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/correct.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/correct.pass.sh index 9a7c7fb59055..04480d451725 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/correct.pass.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/correct.pass.sh @@ -1,5 +1,9 @@ #!/bin/bash +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi + grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} && \ sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE\t7/g" {{{ login_defs_path }}} if ! [ $? -eq 0 ]; then diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/disabled.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/disabled.fail.sh index c87c007fcefc..c74cfbc7e78f 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/disabled.fail.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/disabled.fail.sh @@ -1,5 +1,8 @@ #!/bin/bash +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} && \ sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE\t-1/g" {{{ login_defs_path }}} if ! [ $? -eq 0 ]; then diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/exact_value_dropin.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/exact_value_dropin.pass.sh new file mode 100644 index 000000000000..46bca3573c61 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/exact_value_dropin.pass.sh @@ -0,0 +1,15 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_accounts_password_warn_age_login_defs=7 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} ; then + sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE 0/g" {{{ login_defs_path }}} +else + echo "PASS_WARN_AGE 0" >> {{{ login_defs_path }}} +fi +echo "PASS_WARN_AGE 7" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/greater_value_dropin.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/greater_value_dropin.pass.sh new file mode 100644 index 000000000000..7c0c08483476 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/greater_value_dropin.pass.sh @@ -0,0 +1,15 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_accounts_password_warn_age_login_defs=7 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} + +if grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} ; then + sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE 0/g" {{{ login_defs_path }}} +else + echo "PASS_WARN_AGE 0" >> {{{ login_defs_path }}} +fi +echo "PASS_WARN_AGE 8" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/line_missing.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/line_missing.fail.sh index ab6c2b8c2f20..567395a884ea 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/line_missing.fail.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/line_missing.fail.sh @@ -1,3 +1,7 @@ #!/bin/bash +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} sed -i "/PASS_WARN_AGE.*/d" {{{ login_defs_path }}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/user_dropin_incorrect_value.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/user_dropin_incorrect_value.fail.sh new file mode 100644 index 000000000000..a663b9ddadec --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/user_dropin_incorrect_value.fail.sh @@ -0,0 +1,14 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_accounts_password_warn_age_login_defs=7 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} +if grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} ; then + sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE 7/g" {{{ login_defs_path }}} +else + echo "PASS_WARN_AGE 7" >> {{{ login_defs_path }}} +fi +echo "PASS_WARN_AGE 0" >> "/etc/login.defs.d/user.dropin.defs" diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/wrong_value_dropin.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/wrong_value_dropin.fail.sh new file mode 100644 index 000000000000..9e0f746254d5 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_expiration/accounts_password_warn_age_login_defs/tests/wrong_value_dropin.fail.sh @@ -0,0 +1,14 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# variables = var_accounts_password_warn_age_login_defs=7 + +if [ -e {{{ login_defs_drop_in_path }}} ] ; then + rm {{{ login_defs_drop_in_path }}} +fi +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} +if grep -q "^PASS_WARN_AGE" {{{ login_defs_path }}} ; then + sed -i "s/PASS_WARN_AGE.*/PASS_WARN_AGE 7/g" {{{ login_defs_path }}} +else + echo "PASS_WARN_AGE 7" >> {{{ login_defs_path }}} +fi +echo "PASS_WARN_AGE 0" >> {{{ login_defs_drop_in_path }}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/ansible/shared.yml index daf063350cb8..bf8aeb3f469c 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/ansible/shared.yml @@ -6,7 +6,7 @@ {{{ ansible_instantiate_variables("var_password_pam_unix_rounds") }}} -{{% if product in ["sle12", "sle15"] %}} +{{% if product in ["sle12", "sle15", "sle16"] %}} {{{ ansible_ensure_pam_module_configuration('/etc/pam.d/common-password', 'password', 'sufficient', 'pam_unix.so', 'rounds', '{{ var_password_pam_unix_rounds }}', '', rule_id=rule_id, rule_title=rule_title) }}} {{% else %}} {{{ ansible_ensure_pam_module_configuration('/etc/pam.d/password-auth', 'password', 'sufficient', 'pam_unix.so', 'rounds', '{{ var_password_pam_unix_rounds }}', '', rule_id=rule_id, rule_title=rule_title) }}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/bash/shared.sh index 9346f874318b..3bca691a411c 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/bash/shared.sh @@ -2,11 +2,11 @@ {{{ bash_instantiate_variables("var_password_pam_unix_rounds") }}} -{{% if product in ["sle12", "sle15"] %}} +{{% if product in ["sle12", "sle15", "sle16"] %}} {{{ bash_ensure_pam_module_configuration('/etc/pam.d/common-password', 'password', 'sufficient', 'pam_unix.so', 'rounds', "$var_password_pam_unix_rounds", '') }}} {{% elif product in ["debian12", "debian13"] %}} {{{ bash_ensure_pam_module_configuration('/etc/pam.d/common-password', 'password', '\[success=1 default=ignore\]', 'pam_unix.so', 'rounds', "$var_password_pam_unix_rounds", '') }}} -{{% elif product in ["ubuntu2404"] %}} +{{% elif product in ["ubuntu2204", "ubuntu2404"] %}} config_file="/usr/share/pam-configs/cac_unix" {{{ bash_pam_unix_enable() }}} sed -i -E '/^Password:/,/^[^[:space:]]/ { diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/oval/shared.xml index 7e3067f20224..1ebd7c437550 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/oval/shared.xml @@ -1,4 +1,4 @@ -{{% if product in ["sle12", "sle15", "debian12", "debian13", 'ubuntu2404'] %}} +{{% if product in ["debian12", "debian13", "sle12", "sle15", "sle16", "ubuntu2204", "ubuntu2404"] %}} {{% set pam_passwd_file_path = "/etc/pam.d/common-password" %}} {{% else %}} {{% set pam_passwd_file_path = "/etc/pam.d/password-auth" %}} @@ -19,7 +19,7 @@ ^{{{ pam_passwd_file_path }}}$ - {{% if product in ["debian12", "debian13", 'ubuntu2404'] %}} + {{% if product in ["debian12", "debian13", 'ubuntu2204', 'ubuntu2404'] %}} ^\s*password\s+.*\s+pam_unix\.so[^#]*rounds=([0-9]*).*$ {{% else %}} ^\s*password\s+(?:(?:sufficient)|(?:required))\s+pam_unix\.so[^#]*rounds=([0-9]*).*$ diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/rule.yml index 06e867bc9d1e..f00a09c6d160 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/accounts_password_pam_unix_rounds_password_auth/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Set number of Password Hashing Rounds - password-auth' -{{% if product in ["sle12", "sle15", "debian12", "debian13", 'ubuntu2404'] %}} +{{% if product in ["debian12", "debian13", "sle12", "sle15", "sle16", "ubuntu2204", "ubuntu2404"] %}} {{% set pam_passwd_file_path = "/etc/pam.d/common-password" %}} {{% else %}} {{% set pam_passwd_file_path = "/etc/pam.d/password-auth" %}} @@ -15,11 +15,11 @@ description: |-

In file {{{ pam_passwd_file_path }}} append rounds={{{ xccdf_value("var_password_pam_unix_rounds") }}} to the pam_unix.so entry, as shown below: - {{% if product in ["debian12", "debian13", 'ubuntu2404'] %}} + {{% if product in ["debian12", "debian13", 'ubuntu2204', 'ubuntu2404'] %}}
password [success=1 default=ignore] pam_unix.so ...existing_options... rounds={{{ xccdf_value("var_password_pam_unix_rounds") }}}
{{% else %}}
password sufficient pam_unix.so ...existing_options... rounds={{{ xccdf_value("var_password_pam_unix_rounds") }}}
- + The system's default number of rounds is 5000. {{% endif %}} @@ -49,7 +49,7 @@ ocil: |- To verify the number of rounds for the password hashing algorithm is configured, run the following command:
$ sudo grep rounds {{{ pam_passwd_file_path }}}
The output should show the following match: - {{% if product in ["debian12", "debian13", 'ubuntu2404'] %}} + {{% if product in ["debian12", "debian13", 'ubuntu2204', 'ubuntu2404'] %}}
password [success=1 default=ignore] pam_unix.so sha512 rounds={{{ xccdf_value("var_password_pam_unix_rounds") }}}
{{% else %}}
password sufficient pam_unix.so sha512 rounds={{{ xccdf_value("var_password_pam_unix_rounds") }}}
@@ -62,10 +62,10 @@ fixtext: |- Add or modify the following line in "{{{ pam_passwd_file_path }}}" and set "rounds" to {{{ xccdf_value("var_password_pam_unix_rounds") }}}. For example: - {{% if product in ["debian12", "debian13", 'ubuntu2404'] %}} + {{% if product in ["debian12", "debian13", 'ubuntu2204', 'ubuntu2404'] %}} password [success=1 default=ignore] pam_unix.so sha512 rounds=5000 {{% else %}} password sufficient pam_unix.so sha512 rounds=5000 {{% endif %}} - + srg_requirement: '{{{ full_name }}} shadow password suite must be configured to use a sufficient number of hashing rounds in {{{ pam_passwd_file_path }}}.' diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/ansible/shared.yml index 35dffe1f94d3..78a18739de13 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/ansible/shared.yml @@ -4,7 +4,7 @@ # complexity = low # disruption = medium {{% if 'ubuntu' in product %}} -{{%- set pam_config_paths = "['/etc/pam.d/common-password']" %}} +{{%- set pam_config_paths = "['/etc/pam.d/common-auth', '/etc/pam.d/common-password']" %}} {{% else %}} {{%- set pam_config_paths = "['/etc/pam.d/system-auth', '/etc/pam.d/password-auth']" -%}} {{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/bash/shared.sh index e235cdbdd4ab..90a9c6de3992 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/bash/shared.sh @@ -25,6 +25,18 @@ sed -i -E '/^Password-Initial:/,/^[^[:space:]]/ { } }' "$config_file" +sed -i -E '/^Auth:/,/^[^[:space:]]/ { + /pam_unix\.so/ { + s/\s*nullok//g + } +}' "$config_file" + +sed -i -E '/^Auth-Initial:/,/^[^[:space:]]/ { + /pam_unix\.so/ { + s/\s*nullok//g + } +}' "$config_file" + DEBIAN_FRONTEND=noninteractive pam-auth-update {{% else %}} if [ -f /usr/bin/authselect ]; then diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/oval/shared.xml index ddbde376b499..ac2fc52abd05 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/oval/shared.xml @@ -15,7 +15,7 @@ {{% if 'sle' in product or 'slmicro' in product %}} ^/etc/pam.d/.*$ {{% elif 'ubuntu' in product %}} - ^/etc/pam.d/common-password + ^/etc/pam.d/common-(auth|password)$ {{% else %}} ^/etc/pam.d/(system|password)-auth$ {{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/rule.yml index 746e729b1057..b88e482f57ca 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/rule.yml @@ -10,7 +10,7 @@ description: |- {{% if 'sle' in product or 'slmicro' in product%}} password authentication configurations in /etc/pam.d/ {{% elif 'ubuntu' in product %}} - /etc/pam.d/common-password + /etc/pam.d/common-auth and /etc/pam.d/common-password {{% else %}} /etc/pam.d/system-auth and /etc/pam.d/password-auth @@ -63,7 +63,7 @@ ocil: |- {{% if 'sle' in product or 'slmicro' in product %}}
$ grep pam_unix.so /etc/pam.d/* | grep nullok
{{% elif 'ubuntu' in product %}} -
grep nullok /etc/pam.d/common-password
+
grep nullok /etc/pam.d/common-auth /etc/pam.d/common-password
{{% else %}}
$ grep nullok /etc/pam.d/system-auth /etc/pam.d/password-auth
{{% endif %}} @@ -72,10 +72,10 @@ ocil: |- prevent logins with empty passwords. fixtext: |- - Configure {{{ full_name }}} in the {{% if 'ubuntu' in product %}}common-password file {{% else %}}system-auth and password-auth files {{% endif %}} to not allow null + Configure {{{ full_name }}} in the {{% if 'ubuntu' in product %}}common-auth and common-password files {{% else %}}system-auth and password-auth files {{% endif %}} to not allow null passwords. {{% if 'ubuntu' in product %}} - Remove any instances of the "nullok" option in "/etc/pam.d/common-password" + Remove any instances of the "nullok" option in "/etc/pam.d/common-auth" and "/etc/pam.d/common-password" {{% else %}} Remove any instances of the "nullok" option in the "/etc/pam.d/system-auth" and "/etc/pam.d/password-auth" files @@ -85,7 +85,7 @@ fixtext: |- Note: Manual changes to the listed file may be overwritten by the "authselect" program. srg_requirement: |- - '{{{ full_name }}} must not allow blank or null passwords in the {{% if 'ubuntu' in product %}} common-password file.{{% else %}} system-auth file nor + '{{{ full_name }}} must not allow blank or null passwords in the {{% if 'ubuntu' in product %}} common-auth and common-password files.{{% else %}} system-auth file nor password-auth. {{% endif %}}' warnings: diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/no_nullok.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/no_nullok.pass.sh index 6f56a2e0ddae..d1bfb5fc8de3 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/no_nullok.pass.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/no_nullok.pass.sh @@ -12,9 +12,9 @@ Priority: 257 Conflicts: unix Auth-Type: Primary Auth: - [success=end default=ignore] pam_unix.so nullok try_first_pass + [success=end default=ignore] pam_unix.so try_first_pass Auth-Initial: - [success=end default=ignore] pam_unix.so nullok + [success=end default=ignore] pam_unix.so Account-Type: Primary Account: [success=end new_authtok_reqd=done default=ignore] pam_unix.so diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_commented.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_commented.pass.sh index 1c20026e7dd0..9c2ed1c87f26 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_commented.pass.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_commented.pass.sh @@ -12,9 +12,9 @@ Priority: 257 Conflicts: unix Auth-Type: Primary Auth: - [success=end default=ignore] pam_unix.so nullok try_first_pass + [success=end default=ignore] pam_unix.so try_first_pass # nullok Auth-Initial: - [success=end default=ignore] pam_unix.so nullok + [success=end default=ignore] pam_unix.so # nullok Account-Type: Primary Account: [success=end new_authtok_reqd=done default=ignore] pam_unix.so diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_present_auth.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_present_auth.fail.sh new file mode 100644 index 000000000000..4468cb808777 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_present_auth.fail.sh @@ -0,0 +1,35 @@ +#!/bin/bash +# platform = multi_platform_ubuntu +# packages = pam + +config_file=/usr/share/pam-configs/tmp_unix + +cat << EOF > "$config_file" +Name: Unix authentication +Default: yes +Priority: 257 +Conflicts: unix +Auth-Type: Primary +Auth: + [success=end default=ignore] pam_unix.so nullok try_first_pass +Auth-Initial: + [success=end default=ignore] pam_unix.so nullok +Account-Type: Primary +Account: + [success=end new_authtok_reqd=done default=ignore] pam_unix.so +Account-Initial: + [success=end new_authtok_reqd=done default=ignore] pam_unix.so +Session-Type: Additional +Session: + required pam_unix.so +Session-Initial: + required pam_unix.so +Password-Type: Primary +Password: + [success=end default=ignore] pam_unix.so obscure use_authtok try_first_pass yescrypt +Password-Initial: + [success=end default=ignore] pam_unix.so obscure use_authtok try_first_pass yescrypt +EOF + +DEBIAN_FRONTEND=noninteractive pam-auth-update +rm "$config_file" diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_present_password.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_present_password.fail.sh new file mode 100644 index 000000000000..29e3cf57fcb9 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords/tests/nullok_present_password.fail.sh @@ -0,0 +1,35 @@ +#!/bin/bash +# platform = multi_platform_ubuntu +# packages = pam + +config_file=/usr/share/pam-configs/tmp_unix + +cat << EOF > "$config_file" +Name: Unix authentication +Default: yes +Priority: 257 +Conflicts: unix +Auth-Type: Primary +Auth: + [success=end default=ignore] pam_unix.so try_first_pass +Auth-Initial: + [success=end default=ignore] pam_unix.so +Account-Type: Primary +Account: + [success=end new_authtok_reqd=done default=ignore] pam_unix.so +Account-Initial: + [success=end new_authtok_reqd=done default=ignore] pam_unix.so +Session-Type: Additional +Session: + required pam_unix.so +Session-Initial: + required pam_unix.so +Password-Type: Primary +Password: + [success=end default=ignore] pam_unix.so obscure use_authtok try_first_pass yescrypt nullok +Password-Initial: + [success=end default=ignore] pam_unix.so obscure use_authtok try_first_pass yescrypt nullok +EOF + +DEBIAN_FRONTEND=noninteractive pam-auth-update +rm "$config_file" diff --git a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords_etc_shadow/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords_etc_shadow/bash/shared.sh index dd8ad70a8c69..d844d60048b9 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords_etc_shadow/bash/shared.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/password_storage/no_empty_passwords_etc_shadow/bash/shared.sh @@ -1,6 +1,6 @@ # platform = multi_platform_all -readarray -t users_with_empty_pass < <(sudo awk -F: '!$2 {print $1}' /etc/shadow) +readarray -t users_with_empty_pass < <(awk -F: '!$2 {print $1}' /etc/shadow) for user_with_empty_pass in "${users_with_empty_pass[@]}" do diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/ansible/shared.yml index 1fc2e85742bb..ce2102fc53d0 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/ansible/shared.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/ansible/shared.yml @@ -11,5 +11,5 @@ - name: Lock the password of the user accounts other than root with uid 0 ansible.builtin.command: passwd -l {{ item.key }} - loop: "{{ getent_passwd | dict2items | rejectattr('key', 'search', 'root') | list }}" + loop: "{{ getent_passwd | dict2items | rejectattr('key', 'equalto', 'root') | list }}" when: item.value.1 == '0' diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/oval/shared.xml index c1276fa340e1..2fa2d3e58eb4 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/oval/shared.xml @@ -1,16 +1,35 @@ - {{{ oval_metadata("Only the root account should be assigned a user id of 0.", rule_title=rule_title) }}} + {{{ oval_metadata("Only the root account should be assigned a user id of 0, or the account must be locked.", rule_title=rule_title) }}} - + + + + /etc/passwd - ^(?!root:)[^:]*:[^:]*:0 - 1 + ^(?!root:)([^:]+):[^:]+:0:.*$ + 1 + + + /etc/shadow + ^([^:]+):[!*][^:]*:.*$ + 1 + + + + + + + + + diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/rule.yml index 091ca1a70df8..5293b2a6695f 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/rule.yml @@ -4,8 +4,8 @@ title: 'Verify Only Root Has UID 0' description: |- If any account other than root has a UID of 0, this misconfiguration should - be investigated and the accounts other than root should be removed or have - their UID changed. + be investigated and the accounts other than root should be removed, locked + or have their UID changed.
If the account is associated with system commands or applications the UID should be changed to one greater than "0" but less than "{{{ uid_min }}}." @@ -60,12 +60,14 @@ ocil: |- following command:
$ awk -F: '$3 == 0 {print $1}' /etc/passwd
root
+ Also make sure that if non-root account with UID "0" exist, it is locked: +
$ grep -E '^[^:]+:[!*][^:]*:.*$' /etc/shadow
fixtext: |- Change the UID of any account on the system, other than root, that has a UID of "0". If the account is associated with system commands or applications, the UID should be changed to one greater than "0" but less than "{{{ uid_min }}}". Otherwise, - assign a UID of greater than "{{{ uid_min }}}" that has not already been assigned. + assign a UID of greater than "{{{ uid_min }}}" that has not already been assigned or locked. srg_requirement: 'The root account must be the only account having unrestricted access to the {{{ full_name }}} system.' diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/locked_user_uid_0.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/locked_user_uid_0.pass.sh new file mode 100644 index 000000000000..e49712ca010d --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/locked_user_uid_0.pass.sh @@ -0,0 +1,7 @@ +#!/bin/bash +# platform = multi_platform_all + +useradd --non-unique --uid 0 rootlocked +# configure password, otherwise user is locked +echo "rootlocked:password" | chpasswd +passwd -l rootlocked diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/other_user_uid_0.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/other_user_uid_0.fail.sh index aec75bd0ed52..1c3ada03bc0b 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/other_user_uid_0.fail.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/accounts_no_uid_except_zero/tests/other_user_uid_0.fail.sh @@ -1,7 +1,7 @@ #!/bin/bash +# platform = multi_platform_all # -# Remediation doesn't fix the rule, only locks passwords -# of non-root accounts with uid 0. -# remediation = none useradd --non-unique --uid 0 root2 +# configure password, otherwise user is locked +echo "root2:password" | chpasswd diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/oval/shared.xml index f609fc1c0495..a1ceebd779ef 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/oval/shared.xml @@ -44,7 +44,7 @@ ^(?: - ):(?:[^:]*:){5}([^:]+)$ + ):(?:[^:]*:){5}([^\n\r:]+)$
diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/tests/unlocked_valid_shell.pass.sh b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/tests/unlocked_valid_shell.pass.sh new file mode 100644 index 000000000000..3531d75b9ea9 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/no_invalid_shell_accounts_unlocked/tests/unlocked_valid_shell.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +echo "testuser:x:1001:1001::/home/testuser:/bin/bash" >> /etc/passwd +echo 'testuser:$6$exIFis0tobKRcGBk$b.UR.Z8h96FdxJ1bgA/vhdnp0Lsm488swdILNguQX/5qH5hdmClyYb5xk3TpELXWzr4JOiTlHfRkPsXSjMPjv0:20111:0:99999:7:::' >> /etc/shadow +echo "/bin/bash" >> /etc/shells diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/ansible/shared.yml deleted file mode 100644 index b6f60d4bc946..000000000000 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/ansible/shared.yml +++ /dev/null @@ -1,11 +0,0 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_rhv,multi_platform_sle,multi_platform_almalinux -# reboot = false -# strategy = restrict -# complexity = low -# disruption = low - -- name: "Restrict usage of su command only to members of wheel group" - ansible.builtin.replace: - path: "/etc/pam.d/su" - regexp: '^[\s]*#[\s]*auth[\s]+required[\s]+pam_wheel\.so[\s]+use_uid$' - replace: "auth required pam_wheel.so use_uid" diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/bash/shared.sh deleted file mode 100644 index 5bd381d1210f..000000000000 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/bash/shared.sh +++ /dev/null @@ -1,4 +0,0 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_rhv,multi_platform_sle,multi_platform_almalinux - -# uncomment the option if commented -sed '/^[[:space:]]*#[[:space:]]*auth[[:space:]]\+required[[:space:]]\+pam_wheel\.so[[:space:]]\+use_uid$/s/^[[:space:]]*#//' -i /etc/pam.d/su diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/oval/shared.xml deleted file mode 100644 index d7932de398fd..000000000000 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/oval/shared.xml +++ /dev/null @@ -1,21 +0,0 @@ - - - {{{ oval_metadata("Only members of the wheel group should be able to authenticate through the su command.", rule_title=rule_title) }}} - - - - - - - - - - - /etc/pam.d/su - ^[\s]*auth[\s]+required[\s]+pam_wheel\.so[\s]+\buse_uid\b - 1 - - diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/rule.yml index 6c0ca626469e..ad32af129980 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_for_su/rule.yml @@ -61,3 +61,14 @@ vuldiscussion: |- When operating systems provide the capability to escalate a functional capability, it is critical the user re-authenticate. platform: package[pam] + +template: + name: pam_options + vars: + path: /etc/pam.d/su + type: auth + control_flag: required + module: pam_wheel.so + arguments: + - argument: use_uid + new_argument: use_uid diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/ansible/shared.yml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/ansible/shared.yml deleted file mode 100644 index 6d79f4e9d2de..000000000000 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/ansible/shared.yml +++ /dev/null @@ -1,14 +0,0 @@ -# platform = multi_platform_fedora,multi_platform_rhel,multi_platform_sle,multi_platform_slmicro,multi_platform_ubuntu -# reboot = false -# strategy = restrict -# complexity = low -# disruption = low - -{{{ ansible_instantiate_variables("var_pam_wheel_group_for_su") }}} - -- name: {{{ rule_title }}} - Add the group to the /etc/pam.d/su file - ansible.builtin.lineinfile: - path: "/etc/pam.d/su" - state: present - regexp: '^[\s]*#[\s]*auth[\s]+required[\s]+pam_wheel\.so[\s]+use_uid group=$' - line: "auth required pam_wheel.so use_uid group={{ var_pam_wheel_group_for_su }}" diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/bash/shared.sh b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/bash/shared.sh deleted file mode 100644 index 35df572f9f8d..000000000000 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/bash/shared.sh +++ /dev/null @@ -1,15 +0,0 @@ -# platform = multi_platform_fedora,multi_platform_rhel,multi_platform_sle,multi_platform_slmicro,multi_platform_ubuntu,multi_platform_debian -{{{ bash_instantiate_variables("var_pam_wheel_group_for_su") }}} - -PAM_CONF=/etc/pam.d/su - -pamstr=$(grep -P '^auth\s+required\s+pam_wheel\.so\s+(?=[^#]*\buse_uid\b)(?=[^#]*\bgroup=)' ${PAM_CONF}) -if [ -z "$pamstr" ]; then - sed -Ei '/^auth\b.*\brequired\b.*\bpam_wheel\.so/d' ${PAM_CONF} # remove any remaining uncommented pam_wheel.so line - sed -Ei "/^auth\s+sufficient\s+pam_rootok\.so.*$/a auth required pam_wheel.so use_uid group=${var_pam_wheel_group_for_su}" ${PAM_CONF} -else - group_val=$(echo -n "$pamstr" | grep -Eo '\bgroup=[_a-z][-0-9_a-z]*' | cut -d '=' -f 2) - if [ -z "${group_val}" ] || [ ${group_val} != ${var_pam_wheel_group_for_su} ]; then - sed -Ei "s/(^auth\s+required\s+pam_wheel.so\s+[^#]*group=)[_a-z][-0-9_a-z]*/\1${var_pam_wheel_group_for_su}/" ${PAM_CONF} - fi -fi diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/oval/shared.xml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/oval/shared.xml deleted file mode 100644 index b841da12e366..000000000000 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/oval/shared.xml +++ /dev/null @@ -1,31 +0,0 @@ - - - {{{ oval_metadata("Only members of the group set in variable 'var_pam_wheel_group_for_su' should be able to authenticate through the su command.", rule_title=rule_title) }}} - - - - - - - - - - - - /etc/pam.d/su - ^\s*auth\s+required\s+pam_wheel\.so\s+(?=[^#]*\buse_uid\b)[^#]*\bgroup=([_a-z][-0-9_a-z]*) - 1 - - - - - - - - diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/rule.yml b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/rule.yml index 3d00846e44a7..d1cf0a7ad598 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/rule.yml +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/rule.yml @@ -37,9 +37,24 @@ ocil: |- Run the following command to check if the line is present:
grep pam_wheel /etc/pam.d/su
The output should contain the following line: -
auth required pam_wheel.so use_uid group={{{ xccdf_value("var_pam_wheel_group_for_su") }}}
+
auth required pam_wheel.so use_uid group={{{ xccdf_value("var_pam_wheel_group_for_su.var") }}}
warnings: - general: |- Note that ensure_pam_wheel_group_empty rule complements this requirement by ensuring the referenced group exists and has no members. + +template: + name: pam_options + vars: + path: /etc/pam.d/su + type: auth + control_flag: required + module: pam_wheel.so + arguments: + - variable: group + variable_name: var_pam_wheel_group_for_su + operation: equals + datatype: string + - argument: use_uid + new_argument: use_uid diff --git a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/tests/line_not_there.fail.sh b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/tests/line_not_there.fail.sh index 22103e143e61..1334d633e31a 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/tests/line_not_there.fail.sh +++ b/linux_os/guide/system/accounts/accounts-restrictions/root_logins/use_pam_wheel_group_for_su/tests/line_not_there.fail.sh @@ -1,5 +1,9 @@ #!/bin/bash # variables = var_pam_wheel_group_for_su=sugroup +{{% if product in ["sle16", "slmicro6"] %}} +touch /etc/pam.d/su +{{% endif %}} + #clean possible lines sed -Ei '/^auth\b.*\brequired\b.*\bpam_wheel\.so/d' /etc/pam.d/su diff --git a/linux_os/guide/system/accounts/accounts-restrictions/var_accounts_authorized_local_users_regex.var b/linux_os/guide/system/accounts/accounts-restrictions/var_accounts_authorized_local_users_regex.var index 9ef6e6b67a8b..d6342e1436fb 100644 --- a/linux_os/guide/system/accounts/accounts-restrictions/var_accounts_authorized_local_users_regex.var +++ b/linux_os/guide/system/accounts/accounts-restrictions/var_accounts_authorized_local_users_regex.var @@ -32,4 +32,8 @@ options: sle15: "^(root|bin|daemon|adm|lp|sync|shutdown|halt|mail|operator|games|ftp|nobody|pegasus|systemd-bus-proxy|systemd-network|dbus|polkitd|abrt|unbound|tss|libstoragemgmt|rpc|colord|usbmuxd$|pcp|saslauth|geoclue|setroubleshoot|rtkit|chrony|qemu|radvd|rpcuser|nfsnobody|pulse|gdm|gnome-initial-setup|postfix|avahi|ntp|sshd|tcpdump|oprofile|uuidd|systemd-resolve|systemd-coredump|sssd|rngd|man|systemd-timesync|scard|hacluster|statd|at|dockremap|vnc|messagebus|nscd|flatpak|srvGeoClue|tftp|wsdd|dnsmasq|usbmux|brltty)$" slmicro5: "^(root|bin|daemon|adm|lp|sync|shutdown|halt|mail|operator|games|ftp|nobody|pegasus|systemd-bus-proxy|systemd-network|dbus|polkitd|abrt|unbound|tss|libstoragemgmt|rpc|colord|usbmuxd$|pcp|saslauth|geoclue|setroubleshoot|rtkit|chrony|qemu|radvd|rpcuser|nfsnobody|pulse|gdm|gnome-initial-setup|postfix|avahi|ntp|sshd|tcpdump|oprofile|uuidd|systemd-resolve|systemd-coredump|sssd|rngd|man|systemd-timesync|scard|hacluster|statd|at|dockremap|vnc|messagebus|nscd|flatpak|srvGeoClue|tftp|wsdd|dnsmasq|usbmux|brltty|salt|cockpit-ws|cockpit-wsinstance)$" slmicro6: "^(root|bin|daemon|adm|lp|sync|shutdown|halt|mail|operator|games|ftp|nobody|pegasus|systemd-bus-proxy|systemd-network|dbus|polkitd|abrt|unbound|tss|libstoragemgmt|rpc|colord|usbmuxd$|pcp|saslauth|geoclue|setroubleshoot|rtkit|chrony|qemu|radvd|rpcuser|nfsnobody|pulse|gdm|gnome-initial-setup|postfix|avahi|ntp|sshd|tcpdump|oprofile|uuidd|systemd-resolve|systemd-coredump|sssd|rngd|man|systemd-timesync|scard|hacluster|statd|at|dockremap|vnc|messagebus|nscd|flatpak|srvGeoClue|tftp|wsdd|dnsmasq|usbmux|brltty|salt|cockpit-ws|cockpit-wsinstance)$" +{{% if 'rhcos' in product %}} + default: "^(root|core|containers)$" +{{% else %}} default: "^(root|bin|daemon|adm|lp|sync|shutdown|halt|mail|operator|games|ftp|nobody|tss|systemd-coredump|dbus|polkitd|avahi|colord|rtkit|pipewire|clevis|sssd|geoclue|flatpak|setroubleshoot|libstoragemgmt|systemd-oom|gdm|cockpit-ws|cockpit-wsinstance|gnome-initial-setup|sshd|chrony|dnsmasq|tcpdump|admin)$" +{{% endif %}} diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_tmp/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_tmp/rule.yml index 24cfaa9eddcb..7a93cacce005 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_tmp/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_tmp/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-88705-9 cce@sle12: CCE-91506-6 cce@sle15: CCE-91197-4 + cce@sle16: CCE-95788-6 ocil_clause: is not configured diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_var_tmp/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_var_tmp/rule.yml index c58ada6743ce..276e58a84c72 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_var_tmp/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_polyinstantiated_var_tmp/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-88424-7 cce@sle12: CCE-91507-4 cce@sle15: CCE-91198-2 + cce@sle16: CCE-96428-8 ocil_clause: is not configured diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_group_ownership/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_group_ownership/rule.yml index ef74d0ecb3c2..3605f82340c7 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_group_ownership/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_group_ownership/rule.yml @@ -25,6 +25,7 @@ identifiers: cce@rhel10: CCE-89225-7 cce@sle12: CCE-92295-5 cce@sle15: CCE-91408-5 + cce@sle16: CCE-96569-9 references: cis@sle12: 6.2.8 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_user_ownership/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_user_ownership/rule.yml index 203e1e8eabc8..2713d8bc60bc 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_user_ownership/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_dot_user_ownership/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-86981-8 cce@sle12: CCE-92296-3 cce@sle15: CCE-91409-3 + cce@sle16: CCE-96227-4 references: cis@sle12: 6.2.8 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/oval/shared.xml b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/oval/shared.xml new file mode 100644 index 000000000000..02efcd031d5f --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/oval/shared.xml @@ -0,0 +1,71 @@ + + + {{{ oval_metadata("All interactive user home directories must reside on a separate partition from root.", rule_title=rule_title) }}} + + + + + + + + + + + / + + + + + + ^ + + (/|$) + + + + + + + + + + /etc/passwd + ^(?:(?!nobody|nfsnobody)[^:]*):(?:[^:]*:)[1-9]\d{3,}:(?:[^:]*:){2}([^:]+):(?!(?:/usr)?/sbin/nologin$)[^:]*$ + 1 + + + + + + + + + + + + + + + + + + + + + + diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/rule.yml new file mode 100644 index 000000000000..d50d5b5e1112 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/rule.yml @@ -0,0 +1,48 @@ +documentation_complete: true + +title: 'All Interactive User Home Directories Must Reside On a Separate Partition' + +description: |- + All interactive user home directories must be located on a file system + partition separate from the root (/) partition. If any interactive + user's home directory resides directly on the root file system, a failure + of that file system or a user filling it up could impact system operation. + +rationale: |- + Ensuring that interactive user home directories are on a separate + partition from the root file system prevents users from filling the root + partition, which could result in system instability or denial of service. + It also allows administrators to apply more restrictive mount options + such as noexec, nosuid, and nodev to the + partition containing user home directories. + +severity: medium + +identifiers: + cce@rhel8: CCE-90711-3 + +references: + srg: SRG-OS-000480-GPOS-00227 + +ocil_clause: 'any interactive user home directory is on the root partition' + +ocil: |- + Verify that all interactive user home directories are on a separate + file system partition with the following commands: + + List interactive users and their home directories: +
$ awk -F: '($3>={{{ uid_min }}})&&($7 !~ /nologin/){print $1, $6}' /etc/passwd
+ + For each home directory listed, verify it is on a separate partition: +
$ df <home_directory> | tail -1 | awk '{print $6}'
+ + If the command returns / for any interactive user home directory, + this is a finding. + +fixtext: |- + Migrate interactive user home directories that reside on the root + file system to a separate partition. + +srg_requirement: 'All {{{ full_name }}} interactive user home directories must reside on a file system separate from the root partition.' + +platform: machine diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/home_on_root_partition.fail.sh b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/home_on_root_partition.fail.sh new file mode 100644 index 000000000000..4191ed7d46f4 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/home_on_root_partition.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# platform = multi_platform_all +# remediation = none + +{{{ bash_remove_interactive_users_from_passwd_by_uid() }}} + +mkdir -p /root_home +useradd -m -d /root_home/testUser1 testUser1 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/home_on_separate_partition.pass.sh b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/home_on_separate_partition.pass.sh new file mode 100644 index 000000000000..6b6858caa70b --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/home_on_separate_partition.pass.sh @@ -0,0 +1,19 @@ +#!/bin/bash +# platform = multi_platform_all + +. $SHARED/partition.sh + +{{{ bash_remove_interactive_users_from_passwd_by_uid() }}} + +umount /srv || true + +clean_up_partition /srv + +create_partition + +make_fstab_correct_partition_line /srv + +mount_partition /srv + +mkdir -p /srv/home +useradd -m -d /srv/home/testUser1 testUser1 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/mixed_users_one_on_root.fail.sh b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/mixed_users_one_on_root.fail.sh new file mode 100644 index 000000000000..94b1ed0b4054 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/mixed_users_one_on_root.fail.sh @@ -0,0 +1,23 @@ +#!/bin/bash +# platform = multi_platform_all +# remediation = none + +. $SHARED/partition.sh + +{{{ bash_remove_interactive_users_from_passwd_by_uid() }}} + +umount /srv || true + +clean_up_partition /srv + +create_partition + +make_fstab_correct_partition_line /srv + +mount_partition /srv + +mkdir -p /srv/home +useradd -m -d /srv/home/testUser1 testUser1 + +mkdir -p /root_home +useradd -m -d /root_home/testUser2 testUser2 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/no_interactive_users.pass.sh b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/no_interactive_users.pass.sh new file mode 100644 index 000000000000..5f33e91bcd1c --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_user_interactive_home_directory_on_separate_partition/tests/no_interactive_users.pass.sh @@ -0,0 +1,4 @@ +#!/bin/bash +# platform = multi_platform_all + +{{{ bash_remove_interactive_users_from_passwd_by_uid() }}} diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/oval/shared.xml b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/oval/shared.xml index 8a08acd141be..ea0783a8a73c 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/oval/shared.xml @@ -31,7 +31,7 @@ - .* + / diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/rule.yml index 4ddd6fdbecc9..d6a764c59f60 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-87195-4 cce@sle12: CCE-92292-2 cce@sle15: CCE-91405-1 + cce@sle16: CCE-96340-5 references: cis@sle12: 6.2.7 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/tests/expected_groupowner_nonutf.pass.sh b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/tests/expected_groupowner_nonutf.pass.sh new file mode 100644 index 000000000000..c7363b6321c4 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_groupownership/tests/expected_groupowner_nonutf.pass.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +USER="cac_user" +useradd -m $USER +echo "$USER" > /home/$USER/$USER.txt +touch /home/$USER/$(printf "evil_filename_\334_non_utf8_character") +GROUP=$(id $USER -g) +chgrp -f $GROUP /home/$USER/* + diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/oval/shared.xml b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/oval/shared.xml index 2687378bb7d4..2c42ef4133dc 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/oval/shared.xml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/oval/shared.xml @@ -28,7 +28,7 @@ - .* + / diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/rule.yml index 69e726080d45..9c3738271c36 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/rule.yml @@ -26,6 +26,7 @@ identifiers: cce@rhel10: CCE-88043-5 cce@sle12: CCE-92293-0 cce@sle15: CCE-91406-9 + cce@sle16: CCE-96099-7 references: cis@sle12: 6.2.7 diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/tests/expected_owner_nonutf.pass.sh b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/tests/expected_owner_nonutf.pass.sh new file mode 100644 index 000000000000..0d8b630ce14b --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_ownership/tests/expected_owner_nonutf.pass.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +USER="cac_user" +useradd -m $USER +echo "$USER" > /home/$USER/$USER.txt +touch /home/$USER/$(printf "evil_filename_\334_non_utf8_character") +chown $USER /home/$USER/* diff --git a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_permissions/rule.yml b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_permissions/rule.yml index 630e46097f9e..df1cf7b7967a 100644 --- a/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_permissions/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/accounts_users_home_files_permissions/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-87460-2 cce@sle12: CCE-92290-6 cce@sle15: CCE-91403-6 + cce@sle16: CCE-96668-9 cce@slmicro5: CCE-94028-8 references: diff --git a/linux_os/guide/system/accounts/accounts-session/file_permission_user_bash_history/rule.yml b/linux_os/guide/system/accounts/accounts-session/file_permission_user_bash_history/rule.yml index 2f506c1a3364..8b5cce41dc76 100644 --- a/linux_os/guide/system/accounts/accounts-session/file_permission_user_bash_history/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/file_permission_user_bash_history/rule.yml @@ -32,3 +32,5 @@ fixtext: |- Note: The example will be for the smithj user, who has a home directory of "/home/smithj". $ sudo chmod 0600 /home/smithj/.bash_history + +platform: package[bash] diff --git a/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files/rule.yml b/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files/rule.yml index d945e84c2b55..aa4101b1bb1a 100644 --- a/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files/rule.yml @@ -4,9 +4,9 @@ documentation_complete: true title: 'Ensure All User Initialization Files Have Mode 0740 Or Less Permissive' description: |- - Set the mode of the user initialization files to 0740 with the + Set the mode of the user initialization files to 0740 or less permissisive with the following command: -
$ sudo chmod 0740 /home/USER/.INIT_FILE
+
$ sudo chmod u-s,g-wxs,o= /home/USER/.INIT_FILE
rationale: |- Local initialization files are used to configure the user's shell environment @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-87771-2 cce@sle12: CCE-83097-6 cce@sle15: CCE-85630-2 + cce@sle16: CCE-96448-6 cce@slmicro5: CCE-93749-0 cce@slmicro6: CCE-95059-2 @@ -40,10 +41,10 @@ ocil: |- There should be no output. fixtext: |- - Set the mode of the local initialization files to "0740" with the following command: + Set the mode of the local initialization files to "0740" or less permissive with the following command: Note: The example will be for the smithj user, who has a home directory of "/home/smithj". - $ sudo chmod 0740 /home/smithj/. + $ sudo chmod u-s,g-wxs,o= /home/smithj/.INIT_FILE srg_requirement: 'All {{{ full_name }}} local initialization files must have mode 0740 or less permissive.' diff --git a/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files_root/rule.yml b/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files_root/rule.yml index cd0fa53bd48d..d6c50cccaa7b 100644 --- a/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files_root/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/file_permission_user_init_files_root/rule.yml @@ -4,10 +4,10 @@ title: 'Ensure All User Initialization Files Have Mode 0740 Or Less Permissive' description: |- Set the mode of the user initialization files, including the root user, - to 0740 with the following commands: + to 0740 or less permissisive with the following commands:
-    $ sudo chmod 0740 /root/.INIT_FILE
-    $ sudo chmod 0740 /home/USER/.INIT_FILE
+    $ sudo chmod u-s,g-wxs,o= /root/.INIT_FILE
+    $ sudo chmod u-s,g-wxs,o= /home/USER/.INIT_FILE
     
rationale: |- @@ -30,14 +30,14 @@ ocil_clause: 'they are not 0740 or more permissive' ocil: |- To verify that all user initialization files have a mode of 0740 or less permissive, run the following command: -
$ sudo find /home -type f -name '\.*' \( -perm -0002 -o -perm -0020 \)
+
$ sudo find /root /home -type f -name '\.*' \( -perm -0002 -o -perm -0020 \)
There should be no output. fixtext: |- - Set the mode of the local initialization files to "0740" with the following command: + Set the mode of the local initialization files to "0740" or less permissive with the following command: Note: The example will be for the smithj user, who has a home directory of "/home/smithj". - $ sudo chmod 0740 /home/smithj/. + $ sudo chmod u-s,g-wxs,o= /home/smithj/.INIT_FILE srg_requirement: 'All {{{ full_name }}} local initialization files must have mode 0740 or less permissive.' diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/hummingbird/shared.sh b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/hummingbird/shared.sh new file mode 100644 index 000000000000..898cc4a37808 --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/hummingbird/shared.sh @@ -0,0 +1,9 @@ +# platform = multi_platform_all + +{{{ bash_instantiate_variables("var_accounts_user_umask") }}} + +if grep -q "^[^#]*\bumask" "$NEWROOT/etc/bashrc" ; then + sed -i -E -e "s/^([^#]*\bumask)[[:space:]]+[[:digit:]]+/\1 $var_accounts_user_umask/g" "$NEWROOT/etc/bashrc" +else + echo "umask $var_accounts_user_umask" >> "$NEWROOT/etc/bashrc" +fi diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/rule.yml b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/rule.yml index 8d3ae79e0aae..d62e681a65e2 100644 --- a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_bashrc/rule.yml @@ -29,6 +29,7 @@ identifiers: cce@rhel10: CCE-88580-6 cce@sle12: CCE-91530-6 cce@sle15: CCE-91215-4 + cce@sle16: CCE-95724-1 cce@slmicro5: CCE-94023-9 references: diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_csh_cshrc/rule.yml b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_csh_cshrc/rule.yml index 1482707d44a8..95f62d9d9320 100644 --- a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_csh_cshrc/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_csh_cshrc/rule.yml @@ -62,3 +62,5 @@ fixtext: |- umask {{{ xccdf_value("var_accounts_user_umask") }}} srg_requirement: '{{{ full_name }}} must define default permissions for the c shell.' + +platform: package[tcsh] diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_login_defs/rule.yml b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_login_defs/rule.yml index 7e9fd1b6dcf4..d58c68770f4a 100644 --- a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_login_defs/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_login_defs/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-89314-9 cce@sle12: CCE-83052-1 cce@sle15: CCE-85659-1 + cce@sle16: CCE-96038-5 cce@slmicro5: CCE-93753-2 cce@slmicro6: CCE-95089-9 @@ -49,7 +50,7 @@ ocil: |- UMASK {{{ xccdf_value("var_accounts_user_umask") }}}
-platform: package[shadow-utils] +platform: package[shadow-utils] and system_with_kernel checktext: |- Verify {{{ full_name }}} defines default permissions for all authenticated users in such a way that the user can only read and modify their own files with the following command: diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/hummingbird/shared.sh b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/hummingbird/shared.sh new file mode 100644 index 000000000000..195c5ffaa9bc --- /dev/null +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/hummingbird/shared.sh @@ -0,0 +1,17 @@ +# platform = multi_platform_all +# reboot = false +# strategy = restrict +# complexity = low +# disruption = low + +{{{ bash_instantiate_variables("var_accounts_user_umask") }}} + +readarray -t profile_files < <(find $NEWROOT/etc/profile.d/ -type f -name '*.sh' -or -name 'sh.local') + +for file in "${profile_files[@]}" $NEWROOT/etc/profile; do + grep -qE '^[^#]*umask' "$file" && sed -i -E "s/^(\s*umask\s*)[0-7]+/\1$var_accounts_user_umask/g" "$file" +done + +if ! grep -qrE '^[^#]*umask' $NEWROOT/etc/profile*; then + echo "umask $var_accounts_user_umask" >> $NEWROOT/etc/profile +fi diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/rule.yml b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/rule.yml index 09900441660f..93adfed8d28c 100644 --- a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_etc_profile/rule.yml @@ -25,6 +25,7 @@ identifiers: cce@rhel10: CCE-87651-6 cce@sle12: CCE-91531-4 cce@sle15: CCE-91216-2 + cce@sle16: CCE-96140-9 cce@slmicro5: CCE-94024-7 references: diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_interactive_users/rule.yml b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_interactive_users/rule.yml index 23f12c14fb08..d90aba873cdf 100644 --- a/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_interactive_users/rule.yml +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/accounts_umask_interactive_users/rule.yml @@ -47,3 +47,5 @@ fixtext: |- If the account is for an application, the requirement for a umask less restrictive than "077" can be documented with the Information System Security Officer, but the user agreement for access to the account must specify that the local interactive user must log on to their account first and then switch the user to the application account with the correct option to gain the account's environment variables. srg_requirement: '{{{ full_name }}} must set the umask value to 077 for all local interactive user accounts.' + +platform: system_with_kernel diff --git a/linux_os/guide/system/accounts/accounts-session/user_umask/group.yml b/linux_os/guide/system/accounts/accounts-session/user_umask/group.yml index 9dead34f0d89..722696518d33 100644 --- a/linux_os/guide/system/accounts/accounts-session/user_umask/group.yml +++ b/linux_os/guide/system/accounts/accounts-session/user_umask/group.yml @@ -18,5 +18,3 @@ description: |- easy to intentionally share files with groups of which the user is a member.

- -platform: system_with_kernel diff --git a/linux_os/guide/system/apparmor/package_pam_apparmor_installed/rule.yml b/linux_os/guide/system/apparmor/package_pam_apparmor_installed/rule.yml index bf7ab28ebb49..e5bbb94e024c 100644 --- a/linux_os/guide/system/apparmor/package_pam_apparmor_installed/rule.yml +++ b/linux_os/guide/system/apparmor/package_pam_apparmor_installed/rule.yml @@ -25,9 +25,7 @@ references: stigid@sle12: SLES-12-010600 stigid@sle15: SLES-15-010390 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="pam_apparmor") }}}' +{{{ complete_ocil_entry_package_installed("pam_apparmor") }}} template: name: package_installed diff --git a/linux_os/guide/system/bootloader-grub2/grub2_enable_iommu_force/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_enable_iommu_force/rule.yml index 41ee2618721c..e2da2c810ee9 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_enable_iommu_force/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_enable_iommu_force/rule.yml @@ -19,7 +19,7 @@ identifiers: cce@rhel10: CCE-87932-0 cce@sle12: CCE-91532-2 cce@sle15: CCE-91217-0 - + cce@sle16: CCE-96649-9 ocil_clause: 'I/OMMU is not activated' @@ -37,3 +37,5 @@ template: vars: arg_name: iommu arg_value: 'force' + datatype: string + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_init_on_alloc_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_init_on_alloc_argument/rule.yml index 3f61c7dec7d1..b6604045fdcb 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_init_on_alloc_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_init_on_alloc_argument/rule.yml @@ -33,3 +33,5 @@ template: vars: arg_name: init_on_alloc arg_value: '1' + datatype: int + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_init_on_free/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_init_on_free/rule.yml index ef2844e6fd58..51d3ce0d988b 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_init_on_free/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_init_on_free/rule.yml @@ -29,3 +29,5 @@ template: vars: arg_name: init_on_free arg_value: '1' + datatype: int + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_kernel_trust_cpu_rng/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_kernel_trust_cpu_rng/rule.yml index 3d6b750d92f1..daf0a12f5cfc 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_kernel_trust_cpu_rng/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_kernel_trust_cpu_rng/rule.yml @@ -52,5 +52,7 @@ template: vars: arg_name: random.trust_cpu arg_value: 'on' + datatype: string + operation: equals backends: oval: "off" diff --git a/linux_os/guide/system/bootloader-grub2/grub2_l1tf_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_l1tf_argument/rule.yml index 8776d5bf3287..7c408bca491c 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_l1tf_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_l1tf_argument/rule.yml @@ -30,6 +30,7 @@ identifiers: cce@rhel8: CCE-88123-5 cce@rhel9: CCE-89123-4 cce@rhel10: CCE-86521-2 + cce@sle16: CCE-96540-0 ocil_clause: 'l1tf mitigations are not configured appropriately' @@ -42,3 +43,5 @@ template: vars: arg_name: l1tf arg_variable: var_l1tf_options + datatype: string + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_mce_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_mce_argument/rule.yml index b9d0db90b0f8..1c37176567b3 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_mce_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_mce_argument/rule.yml @@ -23,6 +23,7 @@ identifiers: cce@rhel8: CCE-87098-0 cce@rhel9: CCE-88098-9 cce@rhel10: CCE-87067-5 + cce@sle16: CCE-95847-0 ocil_clause: 'MCE tolerance is not set to zero' @@ -35,3 +36,5 @@ template: vars: arg_name: mce arg_value: '0' + datatype: int + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_mds_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_mds_argument/rule.yml index 6e24c5e5e071..a4ce30858d0d 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_mds_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_mds_argument/rule.yml @@ -53,3 +53,5 @@ template: vars: arg_name: mds arg_variable: var_mds_options + datatype: string + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_nosmap_argument_absent/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_nosmap_argument_absent/rule.yml index 5ef143096710..659ce0038ea1 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_nosmap_argument_absent/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_nosmap_argument_absent/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel8: CCE-87345-5 cce@rhel9: CCE-88345-4 cce@rhel10: CCE-89372-7 + cce@sle16: CCE-95742-3 ocil_clause: 'the kernel is configured to disable SMAP' diff --git a/linux_os/guide/system/bootloader-grub2/grub2_page_alloc_shuffle_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_page_alloc_shuffle_argument/rule.yml index 49212c0bc281..ec0b325999af 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_page_alloc_shuffle_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_page_alloc_shuffle_argument/rule.yml @@ -39,3 +39,5 @@ template: vars: arg_name: page_alloc.shuffle arg_value: '1' + datatype: int + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_pti_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_pti_argument/rule.yml index 9ba761cd3af6..e2956d122fe0 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_pti_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_pti_argument/rule.yml @@ -38,6 +38,8 @@ template: vars: arg_name: pti arg_value: 'on' + datatype: string + operation: equals fixtext: |- {{{ describe_grub2_argument("pti=on") | indent(4) }}} diff --git a/linux_os/guide/system/bootloader-grub2/grub2_rng_core_default_quality_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_rng_core_default_quality_argument/rule.yml index ed4f2ce3dfc1..226fef331cff 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_rng_core_default_quality_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_rng_core_default_quality_argument/rule.yml @@ -31,6 +31,7 @@ identifiers: cce@rhel8: CCE-89567-2 cce@rhel9: CCE-90567-9 cce@rhel10: CCE-90519-0 + cce@sle16: CCE-95794-4 ocil_clause: 'trust on hardware random number generator is not configured appropriately' @@ -43,3 +44,5 @@ template: vars: arg_name: rng_core.default_quality arg_variable: var_rng_core_default_quality + datatype: int + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_slab_nomerge_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_slab_nomerge_argument/rule.yml index bc977ab55fac..91d2ebfac7ad 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_slab_nomerge_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_slab_nomerge_argument/rule.yml @@ -29,6 +29,7 @@ identifiers: cce@rhel8: CCE-86777-0 cce@rhel9: CCE-87770-4 cce@rhel10: CCE-89884-1 + cce@sle16: CCE-95733-2 ocil_clause: 'merging of slabs with similar size is enabled' @@ -41,3 +42,5 @@ template: vars: arg_name: slab_nomerge arg_value: 'yes' + datatype: string + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_spec_store_bypass_disable_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_spec_store_bypass_disable_argument/rule.yml index 67870630e885..5c3ca7464b84 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_spec_store_bypass_disable_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_spec_store_bypass_disable_argument/rule.yml @@ -33,6 +33,7 @@ identifiers: cce@rhel8: CCE-89234-9 cce@rhel9: CCE-90234-6 cce@rhel10: CCE-89300-8 + cce@sle16: CCE-95929-6 ocil_clause: 'SSB is not configured appropriately' @@ -45,3 +46,5 @@ template: vars: arg_name: spec_store_bypass_disable arg_variable: var_spec_store_bypass_disable_options + datatype: string + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_spectre_v2_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_spectre_v2_argument/rule.yml index ad3c01692100..53b9c75486ec 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_spectre_v2_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_spectre_v2_argument/rule.yml @@ -38,4 +38,6 @@ template: name: grub2_bootloader_argument vars: arg_name: spectre_v2 - arg_value: on + arg_value: 'on' + datatype: string + operation: equals diff --git a/linux_os/guide/system/bootloader-grub2/grub2_vsyscall_argument/rule.yml b/linux_os/guide/system/bootloader-grub2/grub2_vsyscall_argument/rule.yml index 9fc7c799c829..045f79c93599 100644 --- a/linux_os/guide/system/bootloader-grub2/grub2_vsyscall_argument/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/grub2_vsyscall_argument/rule.yml @@ -37,7 +37,9 @@ template: name: grub2_bootloader_argument vars: arg_name: vsyscall - arg_value: none + arg_value: 'none' + datatype: string + operation: equals fixtext: |- {{{ describe_grub2_argument("vsyscall=none") | indent(4) }}} diff --git a/linux_os/guide/system/bootloader-grub2/non-uefi/grub2_password/rule.yml b/linux_os/guide/system/bootloader-grub2/non-uefi/grub2_password/rule.yml index c605b0770177..c1f8cd5e485f 100644 --- a/linux_os/guide/system/bootloader-grub2/non-uefi/grub2_password/rule.yml +++ b/linux_os/guide/system/bootloader-grub2/non-uefi/grub2_password/rule.yml @@ -9,14 +9,14 @@ description: |-

Since plaintext passwords are a security risk, generate a hash for the password by running the following command: - {{% if product in ["sle12", "sle15", "slmicro5", "slmicro6"] or 'ubuntu' in product %}} + {{% if 'sle' in product or 'slmicro' in product or 'ubuntu' in product %}}
# grub2-mkpasswd-pbkdf2
{{% else %}}
# grub2-setpassword
{{% endif %}} When prompted, enter the password that was selected.

- {{% if product in ["sle12", "sle15", "slmicro5", "slmicro6"] or 'ubuntu' in product %}} + {{% if 'sle' in product or 'slmicro' in product or 'ubuntu' in product %}} Using the hash from the output, modify the /etc/grub.d/40_custom file with the following content:
set superusers="boot"
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_grub2_cfg/rule.yml b/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_grub2_cfg/rule.yml
index f85ec95dda05..1d2d806eff35 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_grub2_cfg/rule.yml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_grub2_cfg/rule.yml
@@ -16,9 +16,11 @@ rationale: |-
 severity: medium
 
 identifiers:
+    cce@rhcos4: CCE-88685-3
     cce@rhel8: CCE-85915-7
     cce@rhel9: CCE-86696-2
     cce@rhel10: CCE-88090-6
+    cce@sle16: CCE-96462-7
 
 references:
     cis-csc: 12,13,14,15,16,18,3,5
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_user_cfg/rule.yml b/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_user_cfg/rule.yml
index b8886be9fb7b..d58624623dbb 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_user_cfg/rule.yml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/file_groupowner_efi_user_cfg/rule.yml
@@ -19,6 +19,7 @@ identifiers:
     cce@rhel8: CCE-86012-2
     cce@rhel9: CCE-86013-0
     cce@rhel10: CCE-87222-6
+    cce@sle16: CCE-96609-3
 
 references:
     cis-csc: 12,13,14,15,16,18,3,5
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_grub2_cfg/rule.yml b/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_grub2_cfg/rule.yml
index 3ee7b3854c55..3a856425d509 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_grub2_cfg/rule.yml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_grub2_cfg/rule.yml
@@ -14,9 +14,11 @@ rationale: 'Only root should be able to modify important boot parameters.'
 severity: medium
 
 identifiers:
+    cce@rhcos4: CCE-89127-5
     cce@rhel8: CCE-85913-2
     cce@rhel9: CCE-86695-4
     cce@rhel10: CCE-89243-0
+    cce@sle16: CCE-96057-5
 
 references:
     cis-csc: 12,13,14,15,16,18,3,5
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_user_cfg/rule.yml b/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_user_cfg/rule.yml
index 89f771cab2b7..9587955025d3 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_user_cfg/rule.yml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/file_owner_efi_user_cfg/rule.yml
@@ -19,6 +19,7 @@ identifiers:
     cce@rhel8: CCE-86021-3
     cce@rhel9: CCE-86022-1
     cce@rhel10: CCE-89217-4
+    cce@sle16: CCE-96438-7
 
 references:
     cis-csc: 12,13,14,15,16,18,3,5
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_grub2_cfg/rule.yml b/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_grub2_cfg/rule.yml
index a4a7abb81ba4..72cbe9db065d 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_grub2_cfg/rule.yml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_grub2_cfg/rule.yml
@@ -15,9 +15,11 @@ rationale: |-
 severity: medium
 
 identifiers:
+    cce@rhcos4: CCE-88839-6
     cce@rhel8: CCE-85912-4
     cce@rhel9: CCE-85925-6
     cce@rhel10: CCE-88815-6
+    cce@sle16: CCE-96129-2
 
 references:
     cis-csc: 12,13,14,15,16,18,3,5
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_user_cfg/rule.yml b/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_user_cfg/rule.yml
index 29b2d1b53306..274b9f55651f 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_user_cfg/rule.yml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/file_permissions_efi_user_cfg/rule.yml
@@ -18,6 +18,7 @@ identifiers:
     cce@rhel8: CCE-86028-8
     cce@rhel9: CCE-86029-6
     cce@rhel10: CCE-90297-3
+    cce@sle16: CCE-96025-2
 
 references:
     cis-csc: 12,13,14,15,16,18,3,5
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/oval/shared.xml b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/oval/shared.xml
index 07f99ff5bba8..170d6e34ab17 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/oval/shared.xml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/oval/shared.xml
@@ -7,6 +7,15 @@
       
+{{% if product in ["rhel8"] %}}
+
+      
+        
+        
+      
+{{% endif %}}
     
   
 
@@ -33,10 +42,36 @@
     
   
 
+{{% set superusers_regex = '^[\\s]*set[\\s]+superusers="(?i)\\b(?!(?:root|admin|administrator)\\b)(\\w+)".*\\n[\\s]*export[\\s]+superusers[\\s]*$' %}}
+
   
     {{{ grub2_uefi_boot_path }}}/grub.cfg
-    ^[\s]*set[\s]+superusers="(?i)\b(?!(?:root|admin|administrator)\b)(\w+)".*\n[\s]*export[\s]+superusers[\s]*$
+    {{{ superusers_regex }}}
+    1
+  
+{{% if product in ["rhel8"] %}}
+  
+    
+  
+  
+    {{{ grub2_uefi_boot_path }}}/grub.cfg
+    ^[\s]*configfile\b.*$
+    1
+  
+
+  
+    
+    
+  
+
+  
+    {{{ grub2_boot_path }}}/grub.cfg
+    {{{ superusers_regex }}}
     1
   
+{{% endif %}}
+
 
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/tests/stub.fail.sh b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/tests/stub.fail.sh
new file mode 100644
index 000000000000..4c077fa1bb1f
--- /dev/null
+++ b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/tests/stub.fail.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+# platform = Red Hat Enterprise Linux 8
+
+. $SHARED/grub2.sh
+
+cat <<'EOF' >/boot/efi/EFI/redhat/grub.cfg
+search --no-floppy --set prefix --file /boot/grub2/grub.cfg
+set prefix=($prefix)/boot/grub2
+configfile $prefix/grub.cfg
+EOF
+
+GRUB_CFG_ROOT="/boot/grub2"
+set_superusers "root"
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/tests/stub.pass.sh b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/tests/stub.pass.sh
new file mode 100644
index 000000000000..45a6bb0c61f2
--- /dev/null
+++ b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_admin_username/tests/stub.pass.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+# platform = Red Hat Enterprise Linux 8
+
+. $SHARED/grub2.sh
+
+cat <<'EOF' >/boot/efi/EFI/redhat/grub.cfg
+search --no-floppy --set prefix --file /boot/grub2/grub.cfg
+set prefix=($prefix)/boot/grub2
+configfile $prefix/grub.cfg
+EOF
+
+GRUB_CFG_ROOT="/boot/grub2"
+set_superusers "koskic"
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/oval/shared.xml b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/oval/shared.xml
index 6323828071e6..c780cf69e5e1 100644
--- a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/oval/shared.xml
+++ b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/oval/shared.xml
@@ -4,9 +4,16 @@
 
     
       
+{{% if product in ["rhel8"] %}}
+
+      
+        
+        
+      
+{{% endif %}}
     
   
-  
+
   
     
   
@@ -16,4 +23,24 @@
     1
   
 
+{{% if product in ["rhel8"] %}}
+  
+    
+  
+  
+    {{{ grub2_uefi_boot_path }}}/grub.cfg
+    ^[\s]*configfile\b.*$
+    1
+  
+
+  
+    
+  
+  
+    {{{ grub2_boot_path }}}/user.cfg
+    ^[\s]*GRUB2_PASSWORD=grub\.pbkdf2\.sha512.*$
+    1
+  
+{{% endif %}}
+
 
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/invalid_username.fail.sh b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/invalid_username.fail.sh
deleted file mode 100644
index c477fd7a9acd..000000000000
--- a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/invalid_username.fail.sh
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/bin/bash
-
-# remediation = none
-
-. $SHARED/grub2.sh
-
-set_grub_uefi_root
-
-make_grub_password
-sed -i '/set superusers/d' /boot/grub/grub.cfg
-sed -i '/export superusers/d' /boot/grub/grub.cfg
-set_superusers "use r"
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/stub.fail.sh b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/stub.fail.sh
new file mode 100644
index 000000000000..0673a07f6c1a
--- /dev/null
+++ b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/stub.fail.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+# platform = Red Hat Enterprise Linux 8
+
+. $SHARED/grub2.sh
+
+cp "/boot/efi/EFI/redhat/user.cfg" "/boot/grub2/user.cfg"
+cat <<'EOF' >/boot/efi/EFI/redhat/grub.cfg
+search --no-floppy --set prefix --file /boot/grub2/grub.cfg
+set prefix=($prefix)/boot/grub2
+configfile $prefix/grub.cfg
+EOF
+rm -rf "/boot/grub2/user.cfg"
diff --git a/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/stub.pass.sh b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/stub.pass.sh
new file mode 100644
index 000000000000..13dd27d8aca1
--- /dev/null
+++ b/linux_os/guide/system/bootloader-grub2/uefi/grub2_uefi_password/tests/stub.pass.sh
@@ -0,0 +1,13 @@
+#!/bin/bash
+# platform = Red Hat Enterprise Linux 8
+
+. $SHARED/grub2.sh
+
+cat <<'EOF' >/boot/efi/EFI/redhat/grub.cfg
+search --no-floppy --set prefix --file /boot/grub2/grub.cfg
+set prefix=($prefix)/boot/grub2
+configfile $prefix/grub.cfg
+EOF
+
+GRUB_CFG_ROOT="/boot/grub2"
+make_grub_password
diff --git a/linux_os/guide/system/bootloader-grub2/var_rng_core_default_quality.var b/linux_os/guide/system/bootloader-grub2/var_rng_core_default_quality.var
index d54caae551d5..77c2d7ca942f 100644
--- a/linux_os/guide/system/bootloader-grub2/var_rng_core_default_quality.var
+++ b/linux_os/guide/system/bootloader-grub2/var_rng_core_default_quality.var
@@ -8,7 +8,7 @@ description: |-
 
 interactive: true
 
-type: string
+type: number
 
 operator: equals
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_acpi_custom_method/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_acpi_custom_method/rule.yml
index 475566370679..e8783af728ce 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_acpi_custom_method/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_acpi_custom_method/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-86778-8
     cce@rhel9: CCE-86779-6
     cce@rhel10: CCE-89223-2
+    cce@sle16: CCE-95814-0
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_binfmt_misc/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_binfmt_misc/rule.yml
index 212d9ef32b80..4788e37e4876 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_binfmt_misc/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_binfmt_misc/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-87766-2
     cce@rhel9: CCE-87767-0
     cce@rhel10: CCE-87210-1
+    cce@sle16: CCE-96265-4
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_bug/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_bug/rule.yml
index a92d750936c0..6c11fa7bba27 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_bug/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_bug/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-86095-7
     cce@rhel9: CCE-86096-5
     cce@rhel10: CCE-89980-7
+    cce@sle16: CCE-96106-0
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_compat_brk/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_compat_brk/rule.yml
index 22af2d7de31d..5d112e988cae 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_compat_brk/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_compat_brk/rule.yml
@@ -23,6 +23,7 @@ identifiers:
     cce@rhel8: CCE-88962-6
     cce@rhel9: CCE-88963-4
     cce@rhel10: CCE-90053-0
+    cce@sle16: CCE-95981-7
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_compat_vdso/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_compat_vdso/rule.yml
index ff138943aedf..259cfa6521a6 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_compat_vdso/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_compat_vdso/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-87256-4
     cce@rhel9: CCE-87257-2
     cce@rhel10: CCE-88353-8
+    cce@sle16: CCE-96692-9
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_debug_credentials/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_debug_credentials/rule.yml
index 9751b1e43b51..7e21594b0534 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_debug_credentials/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_debug_credentials/rule.yml
@@ -24,6 +24,7 @@ identifiers:
     cce@rhel8: CCE-86656-6
     cce@rhel9: CCE-86657-4
     cce@rhel10: CCE-88628-3
+    cce@sle16: CCE-96017-9
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_debug_fs/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_debug_fs/rule.yml
index c325f6265d8f..7170b89ea250 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_debug_fs/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_debug_fs/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-88033-6
     cce@rhel9: CCE-89033-5
     cce@rhel10: CCE-90684-2
+    cce@sle16: CCE-96629-1
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_debug_list/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_debug_list/rule.yml
index 8b43c839bf66..3566c6a9d7af 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_debug_list/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_debug_list/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-86986-7
     cce@rhel9: CCE-86987-5
     cce@rhel10: CCE-86739-0
+    cce@sle16: CCE-96574-9
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_debug_notifiers/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_debug_notifiers/rule.yml
index 17c0e1980733..ee4a6269a263 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_debug_notifiers/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_debug_notifiers/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-86814-1
     cce@rhel9: CCE-86815-8
     cce@rhel10: CCE-89355-2
+    cce@sle16: CCE-96344-7
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_debug_sg/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_debug_sg/rule.yml
index 8d27a5881e70..466899913901 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_debug_sg/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_debug_sg/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-87148-3
     cce@rhel9: CCE-87149-1
     cce@rhel10: CCE-89292-7
+    cce@sle16: CCE-96359-5
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_default_mmap_min_addr/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_default_mmap_min_addr/rule.yml
index e9f2443a603b..fad386a0619d 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_default_mmap_min_addr/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_default_mmap_min_addr/rule.yml
@@ -26,6 +26,7 @@ identifiers:
     cce@rhel8: CCE-88160-7
     cce@rhel9: CCE-88161-5
     cce@rhel10: CCE-90330-2
+    cce@sle16: CCE-96450-2
 
 platform: x86_64_arch or aarch64_arch
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_devkmem/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_devkmem/rule.yml
index 16100ff20e37..57f5fd0804cd 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_devkmem/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_devkmem/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-86947-9
     cce@rhel9: CCE-86948-7
     cce@rhel10: CCE-87428-9
+    cce@sle16: CCE-96408-0
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_hibernation/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_hibernation/rule.yml
index 9e05dd5b022c..ae1341bee709 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_hibernation/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_hibernation/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-87608-6
     cce@rhel9: CCE-87609-4
     cce@rhel10: CCE-87786-0
+    cce@sle16: CCE-95950-2
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_ia32_emulation/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_ia32_emulation/rule.yml
index 60d176410d84..42d615759ab3 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_ia32_emulation/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_ia32_emulation/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-88746-3
     cce@rhel9: CCE-88747-1
     cce@rhel10: CCE-87905-6
+    cce@sle16: CCE-96396-7
 
 platform: x86_64_arch
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_kexec/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_kexec/rule.yml
index c7ba5d36f3cb..25c384c9b817 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_kexec/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_kexec/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-87488-3
     cce@rhel9: CCE-87489-1
     cce@rhel10: CCE-89414-7
+    cce@sle16: CCE-95737-3
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_legacy_ptys/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_legacy_ptys/rule.yml
index 0662aab9b4d3..0c143f0929db 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_legacy_ptys/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_legacy_ptys/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-87925-4
     cce@rhel9: CCE-87926-2
     cce@rhel10: CCE-89570-6
+    cce@sle16: CCE-95831-4
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig/rule.yml
index 4f1bea71d00a..a23af42481e2 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-89378-4
     cce@rhel9: CCE-89379-2
     cce@rhel10: CCE-86836-4
+    cce@sle16: CCE-96615-0
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_all/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_all/rule.yml
index 37e9f12e17db..dfe5a018fb5d 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_all/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_all/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-89615-9
     cce@rhel9: CCE-89616-7
     cce@rhel10: CCE-86520-4
+    cce@sle16: CCE-95955-1
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_force/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_force/rule.yml
index 208327b194e7..f430259f7ef7 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_force/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_force/rule.yml
@@ -19,6 +19,7 @@ identifiers:
     cce@rhel8: CCE-89459-2
     cce@rhel9: CCE-89460-0
     cce@rhel10: CCE-89203-4
+    cce@sle16: CCE-95719-1
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_hash/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_hash/rule.yml
index f05c876e20ce..3786b5bd0ac4 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_hash/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_hash/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-89843-7
     cce@rhel9: CCE-89844-5
     cce@rhel10: CCE-87400-8
+    cce@sle16: CCE-96452-8
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_key/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_key/rule.yml
index cf1c3d8e6f0e..edd1c1b88e8e 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_key/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_key/rule.yml
@@ -26,6 +26,7 @@ identifiers:
     cce@rhel8: CCE-90000-1
     cce@rhel9: CCE-89999-7
     cce@rhel10: CCE-90444-1
+    cce@sle16: CCE-96015-3
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_sha512/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_sha512/rule.yml
index 723b7653d364..3fc61093df5d 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_sha512/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_module_sig_sha512/rule.yml
@@ -19,6 +19,7 @@ identifiers:
     cce@rhel8: CCE-89692-8
     cce@rhel9: CCE-89691-0
     cce@rhel10: CCE-87565-8
+    cce@sle16: CCE-96566-5
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_no_sanity/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_no_sanity/rule.yml
index 89e9f627a722..8b4577861b6f 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_no_sanity/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_no_sanity/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-88574-9
     cce@rhel9: CCE-88575-6
     cce@rhel10: CCE-87844-7
+    cce@sle16: CCE-96130-0
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_zero/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_zero/rule.yml
index adf28b0b2722..4e7465236c53 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_zero/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_page_poisoning_zero/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-88808-1
     cce@rhel9: CCE-88809-9
     cce@rhel10: CCE-90278-3
+    cce@sle16: CCE-96575-6
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_page_table_isolation/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_page_table_isolation/rule.yml
index 08624fe8a169..8d18465fdc86 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_page_table_isolation/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_page_table_isolation/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-88591-3
     cce@rhel9: CCE-88592-1
     cce@rhel10: CCE-88464-3
+    cce@sle16: CCE-96529-3
 
 platform: x86_64_arch
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_panic_on_oops/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_panic_on_oops/rule.yml
index f712157a12ec..a99c8997a2e4 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_panic_on_oops/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_panic_on_oops/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-86176-5
     cce@rhel9: CCE-86177-3
     cce@rhel10: CCE-89985-6
+    cce@sle16: CCE-95726-6
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_panic_timeout/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_panic_timeout/rule.yml
index 32d45b4ca2fa..c7b5e2809366 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_panic_timeout/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_panic_timeout/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-86349-8
     cce@rhel9: CCE-86350-6
     cce@rhel10: CCE-86964-4
+    cce@sle16: CCE-96235-7
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_proc_kcore/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_proc_kcore/rule.yml
index a43931553372..602e57da57fd 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_proc_kcore/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_proc_kcore/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel8: CCE-87105-3
     cce@rhel9: CCE-87106-1
     cce@rhel10: CCE-88511-1
+    cce@sle16: CCE-96083-1
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_randomize_base/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_randomize_base/rule.yml
index 5c1576aa8a46..66f6764d5bf3 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_randomize_base/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_randomize_base/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-88318-1
     cce@rhel9: CCE-88319-9
     cce@rhel10: CCE-87989-0
+    cce@sle16: CCE-96510-3
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_randomize_memory/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_randomize_memory/rule.yml
index 827c666e449e..9990da02bb70 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_randomize_memory/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_randomize_memory/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-88440-3
     cce@rhel9: CCE-88441-1
     cce@rhel10: CCE-88383-5
+    cce@sle16: CCE-95989-0
 
 platform: x86_64_arch
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_retpoline/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_retpoline/rule.yml
index 261cd8a6ce80..059fe0c80fbc 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_retpoline/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_retpoline/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-87494-1
     cce@rhel9: CCE-87495-8
     cce@rhel10: CCE-89562-3
+    cce@sle16: CCE-96519-4
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_seccomp/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_seccomp/rule.yml
index 201464ba05f5..b9d32b907bc0 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_seccomp/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_seccomp/rule.yml
@@ -24,6 +24,7 @@ identifiers:
     cce@rhel9: CCE-86451-2
     cce@rhel10: CCE-87403-2
     cce@sle15: CCE-92567-7
+    cce@sle16: CCE-95777-9
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_seccomp_filter/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_seccomp_filter/rule.yml
index fe3a38d84372..4c8a428075ee 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_seccomp_filter/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_seccomp_filter/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel9: CCE-86491-8
     cce@rhel10: CCE-89407-1
     cce@sle15: CCE-92568-5
+    cce@sle16: CCE-96560-8
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_security/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_security/rule.yml
index f60cbb144a9e..98d382eeffe0 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_security/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_security/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel9: CCE-86573-3
     cce@rhel10: CCE-87679-7
     cce@sle15: CCE-92570-1
+    cce@sle16: CCE-96259-7
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_security_dmesg_restrict/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_security_dmesg_restrict/rule.yml
index 707e3b575b47..4ac0bed31b1c 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_security_dmesg_restrict/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_security_dmesg_restrict/rule.yml
@@ -19,6 +19,7 @@ identifiers:
     cce@rhel8: CCE-87339-8
     cce@rhel9: CCE-87340-6
     cce@rhel10: CCE-89137-4
+    cce@sle16: CCE-96445-2
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_security_writable_hooks/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_security_writable_hooks/rule.yml
index 781acca096a1..ad631811de4a 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_security_writable_hooks/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_security_writable_hooks/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel9: CCE-86885-1
     cce@rhel10: CCE-89825-4
     cce@sle15: CCE-92571-9
+    cce@sle16: CCE-95918-9
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_security_yama/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_security_yama/rule.yml
index 8f0d39a03642..607e85f3da64 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_security_yama/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_security_yama/rule.yml
@@ -23,6 +23,7 @@ identifiers:
     cce@rhel9: CCE-86717-6
     cce@rhel10: CCE-87793-6
     cce@sle15: CCE-92572-7
+    cce@sle16: CCE-96626-7
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_slub_debug/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_slub_debug/rule.yml
index 7a15122c2f8c..e881ea27183f 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_slub_debug/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_slub_debug/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel8: CCE-88275-3
     cce@rhel9: CCE-88276-1
     cce@rhel10: CCE-87071-7
+    cce@sle16: CCE-95987-4
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_syn_cookies/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_syn_cookies/rule.yml
index 6388d834e296..905f36091301 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_syn_cookies/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_syn_cookies/rule.yml
@@ -24,6 +24,7 @@ identifiers:
     cce@rhel8: CCE-87330-7
     cce@rhel9: CCE-87331-5
     cce@rhel10: CCE-89322-2
+    cce@sle16: CCE-95924-7
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_unmap_kernel_at_el0/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_unmap_kernel_at_el0/rule.yml
index 742d5d6a5315..3bde406e4f86 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_unmap_kernel_at_el0/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_unmap_kernel_at_el0/rule.yml
@@ -25,6 +25,7 @@ identifiers:
     cce@rhel8: CCE-89179-6
     cce@rhel9: CCE-89180-4
     cce@rhel10: CCE-90608-1
+    cce@sle16: CCE-95872-8
 
 platform: aarch64_arch
 
diff --git a/linux_os/guide/system/kernel_build_config/kernel_config_x86_vsyscall_emulation/rule.yml b/linux_os/guide/system/kernel_build_config/kernel_config_x86_vsyscall_emulation/rule.yml
index b4519fe5d52e..afb1739706db 100644
--- a/linux_os/guide/system/kernel_build_config/kernel_config_x86_vsyscall_emulation/rule.yml
+++ b/linux_os/guide/system/kernel_build_config/kernel_config_x86_vsyscall_emulation/rule.yml
@@ -22,6 +22,7 @@ identifiers:
     cce@rhel8: CCE-87883-5
     cce@rhel9: CCE-87884-3
     cce@rhel10: CCE-88133-4
+    cce@sle16: CCE-96298-5
 
 ocil_clause: 'the kernel was not built with the required value'
 
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/ansible/shared.yml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/ansible/shared.yml
index 723b269b9fd5..47bf65a2a664 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/ansible/shared.yml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/ansible/shared.yml
@@ -9,6 +9,6 @@
 {{{ ansible_remove_rainerscript_block_entries(rule_title, "action", "StreamDriverAuthMode") }}}
 
 {{{ ansible_set_config_file_dir(msg, "/etc/rsyslog.conf", "/etc/rsyslog.d", "/etc/rsyslog.conf", 
-                                "$ActionSendStreamDriverAuthMode", separator=' ', separator_regex='\s',
+                                "$ActionSendStreamDriverAuthMode", separator=' ',
                                 value="x509/name", create='yes', rule_title=rule_title)
 }}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/bash/shared.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/bash/shared.sh
index 7c01eb6c928d..bf9091f8127b 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/bash/shared.sh
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/bash/shared.sh
@@ -6,5 +6,5 @@
 {{{ setup_rsyslog_encrypt_offload_actionsendstreamdriverauthmode() }}}
 
 {{{ set_config_file(path="$RSYSLOG_D_CONF",
-             parameter="\$ActionSendStreamDriverAuthMode", value="x509/name", create=true, separator=" ", separator_regex=" ", rule_id=rule_id)
+             parameter="\$ActionSendStreamDriverAuthMode", value="x509/name", create=true, separator=" ", rule_id=rule_id)
 }}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/oval/shared.xml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/oval/shared.xml
index e61f97c06af8..12b321ec7102 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/oval/shared.xml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/oval/shared.xml
@@ -15,7 +15,7 @@
         
     
 
-{{% set legacy_regex = "^\\$ActionSendStreamDriverAuthMode x509/name$" %}}
+{{% set legacy_regex = "^\\s*\\$ActionSendStreamDriverAuthMode\\s+x509/name\\s*$" %}}
 {{% set rainer_script_regex = "(?ms)^\\s*action\\(.*(?i)\\btype\\b(?-i)=\"omfwd\".*(?i)\\bStreamDriverAuthMode\\b(?-i)=\"x509/name\".*\\)\\s*$" %}}
 
     > $RSYSLOG_CONF
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/tests/rsyslog_leading_whitespace.pass.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/tests/rsyslog_leading_whitespace.pass.sh
new file mode 100644
index 000000000000..22a58980a1ea
--- /dev/null
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdriverauthmode/tests/rsyslog_leading_whitespace.pass.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+# packages = rsyslog
+{{{ setup_rsyslog_encrypt_offload_actionsendstreamdriverauthmode() }}}
+
+echo "  \$ActionSendStreamDriverAuthMode x509/name" >> $RSYSLOG_CONF
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/ansible/shared.yml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/ansible/shared.yml
index e601fcc42327..2066948f6cef 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/ansible/shared.yml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/ansible/shared.yml
@@ -10,5 +10,5 @@
 
 {{{ ansible_set_config_file_dir(msg, "/etc/rsyslog.conf", "/etc/rsyslog.d", "/etc/rsyslog.conf",
                                   parameter="$ActionSendStreamDriverMode", value="1", create=true, separator=" ",
-                                  separator_regex=" ", rule_title=rule_title)
+                                  rule_title=rule_title)
 }}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/bash/shared.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/bash/shared.sh
index f51f9b548d18..902d4bd99e23 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/bash/shared.sh
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/bash/shared.sh
@@ -2,5 +2,5 @@
 {{{ setup_rsyslog_encrypt_offload_actionsendstreamdrivermode() }}}
 
 {{{ set_config_file(path="$RSYSLOG_D_CONF",
-             parameter="\$ActionSendStreamDriverMode", value="1", create=true, separator=" ", separator_regex=" ", rule_id=rule_id)
+             parameter="\$ActionSendStreamDriverMode", value="1", create=true, separator=" ", rule_id=rule_id)
 }}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/oval/shared.xml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/oval/shared.xml
index 13510c97c1ea..4ef4284bd909 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/oval/shared.xml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/oval/shared.xml
@@ -16,7 +16,7 @@
         
     
 
-{{% set legacy_regex = "^\\$ActionSendStreamDriverMode 1$" %}}
+{{% set legacy_regex = "^\\s*\\$ActionSendStreamDriverMode\\s+1\\s*$" %}}
 {{% set rainer_script_regex = "(?ms)^\\s*action\\(.*(?i)\\btype\\b(?-i)=\"omfwd\".*(?i)\\bStreamDriverMode\\b(?-i)=\"1\".*\\)\\s*$" %}}
 
     > $RSYSLOG_CONF
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/tests/rsyslog_leading_whitespace.pass.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/tests/rsyslog_leading_whitespace.pass.sh
new file mode 100644
index 000000000000..07738507d03e
--- /dev/null
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_actionsendstreamdrivermode/tests/rsyslog_leading_whitespace.pass.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+# packages = rsyslog
+{{{ setup_rsyslog_encrypt_offload_actionsendstreamdrivermode() }}}
+
+echo "  \$ActionSendStreamDriverMode 1" >> $RSYSLOG_CONF
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/ansible/shared.yml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/ansible/shared.yml
index 9c534f5f325b..14595d44550e 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/ansible/shared.yml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/ansible/shared.yml
@@ -10,5 +10,5 @@
 
 {{{ ansible_set_config_file_dir(msg, "/etc/rsyslog.conf", "/etc/rsyslog.d", "/etc/rsyslog.conf",
                                 parameter="$DefaultNetstreamDriver", value="gtls", create=true,
-                                separator=" ", separator_regex=" ", rule_title=rule_title)
+                                separator=" ", rule_title=rule_title)
 }}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/bash/shared.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/bash/shared.sh
index 70e123454bc2..f24f386dace1 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/bash/shared.sh
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/bash/shared.sh
@@ -2,5 +2,5 @@
 {{{ setup_rsyslog_encrypt_offload_defaultnetstreamdriver() }}}
 
 {{{ set_config_file(path="$RSYSLOG_D_CONF",
-                    parameter="\$DefaultNetstreamDriver", value="gtls", create=true, separator=" ", separator_regex=" ", rule_id=rule_id)
+                    parameter="\$DefaultNetstreamDriver", value="gtls", create=true, separator=" ", rule_id=rule_id)
 }}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/oval/shared.xml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/oval/shared.xml
index cb34a148e940..5ac8c94420ec 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/oval/shared.xml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/oval/shared.xml
@@ -16,7 +16,7 @@
         
     
 
-{{% set legacy_regex = "^\\$DefaultNetstreamDriver gtls$" %}}
+{{% set legacy_regex = "^\\s*\\$DefaultNetstreamDriver\\s+gtls\\s*$" %}}
 {{% set rainer_script_regex = "(?ms)^\\s*global\\(.*(?i)\\bDefaultNetStreamDriver\\b(?-i)=\"gtls\".*\\)\\s*$" %}}
 
     > $RSYSLOG_CONF
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/tests/rsyslog_leading_whitespace.pass.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/tests/rsyslog_leading_whitespace.pass.sh
new file mode 100644
index 000000000000..f087b7ca909c
--- /dev/null
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_encrypt_offload_defaultnetstreamdriver/tests/rsyslog_leading_whitespace.pass.sh
@@ -0,0 +1,5 @@
+#!/bin/bash
+# packages = rsyslog
+{{{ setup_rsyslog_encrypt_offload_defaultnetstreamdriver() }}}
+
+echo "  \$DefaultNetstreamDriver gtls" >> $RSYSLOG_CONF
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/oval/shared.xml b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/oval/shared.xml
index 80f5480c379a..928e24fccbdd 100644
--- a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/oval/shared.xml
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/oval/shared.xml
@@ -27,7 +27,7 @@
   {{% macro object_remote_method(method, test_ref) %}}
   
     ^/etc/rsyslog\.(conf|d/.+\.conf)$
-    ^[ \t]*(?:(?:\w+,)*{{{ method }}}(?:,\w+)*\.\*|\S+;{{{ method }}}\.\*|{{{ method }}}\.\*;\S+|\S+;{{{ method }}}\.\*;\S+)[ \t]+(?:(?!action\()\S+|action\([^)]*file\s*=\s*["'][^"']+["'][^)]*\))\s*$
+    ^[ \t]*(?:(?:\w+,)*{{{ method }}}(?:,\w+)*\.\*|\S+;{{{ method }}}\.\*|{{{ method }}}\.\*;\S+|\S+;{{{ method }}}\.\*;\S+)[ \t]+(?:(?!(?i)action(?-i)\()\S+|(?i)action(?-i)\([^)]*(?i)file(?-i)\s*=\s*["'][^"']+["'][^)]*\))\s*$
     1
   
   {{% endmacro %}}
diff --git a/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/tests/rainerscript_action.pass.sh b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/tests/rainerscript_action.pass.sh
new file mode 100644
index 000000000000..2bfe417ad43f
--- /dev/null
+++ b/linux_os/guide/system/logging/ensure_rsyslog_log_file_configuration/rsyslog_remote_access_monitoring/tests/rainerscript_action.pass.sh
@@ -0,0 +1,9 @@
+#!/bin/bash
+# platform = multi_platform_all
+
+rm -rf /etc/rsyslog.d/*
+true > /etc/rsyslog.conf
+
+# Use RainerScript action() syntax with capitalized File property
+echo '*.info;daemon.*;kern.*;auth.*;mail,authpriv,cron.none   action(name="local-messages" type="omfile" File="/var/log/messages")' >> /etc/rsyslog.conf
+echo 'authpriv.*   action(name="local-authpriv" type="omfile" File="/var/log/secure")' >> /etc/rsyslog.conf
diff --git a/linux_os/guide/system/logging/journald/package_systemd-journal-remote_installed/rule.yml b/linux_os/guide/system/logging/journald/package_systemd-journal-remote_installed/rule.yml
index f4a62583346a..f5525d348192 100644
--- a/linux_os/guide/system/logging/journald/package_systemd-journal-remote_installed/rule.yml
+++ b/linux_os/guide/system/logging/journald/package_systemd-journal-remote_installed/rule.yml
@@ -26,9 +26,7 @@ identifiers:
 references:
     srg: SRG-OS-000479-GPOS-00224
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="systemd-journal-remote") }}}'
+{{{ complete_ocil_entry_package_installed("systemd-journal-remote") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/ansible/shared.yml b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/ansible/shared.yml
index f9f947d0bc79..07a61ea4cab9 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/ansible/shared.yml
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/ansible/shared.yml
@@ -4,19 +4,24 @@
 # complexity = low
 # disruption = low
 
-- name: Configure daily log rotation in /etc/logrotate.conf
+{{% set LOGROTATE_CONF_FILE="/etc/logrotate.conf" %}}
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ ansible_copy_distro_defaults('/usr/etc/logrotate.conf', LOGROTATE_CONF_FILE, rule_title) }}}
+{{% endif %}}
+
+- name: "Configure daily log rotation in {{{ LOGROTATE_CONF_FILE }}}"
   ansible.builtin.lineinfile:
     create: yes
-    dest: "/etc/logrotate.conf"
+    dest: {{{ LOGROTATE_CONF_FILE }}}
     regexp: '^\s*(weekly|monthly|yearly)$'
     line: "daily"
     state: present
     insertbefore: BOF
 
-- name: Make sure daily log rotation setting is not overridden in /etc/logrotate.conf
+- name: "Make sure daily log rotation setting is not overridden in {{{ LOGROTATE_CONF_FILE }}}"
   ansible.builtin.lineinfile:
     create: no
-    dest: "/etc/logrotate.conf"
+    dest: {{{ LOGROTATE_CONF_FILE }}}
     regexp: '^[\s]*(weekly|monthly|yearly)$'
     state: absent
 
@@ -39,7 +44,7 @@
     - name: Add logrotate call
       ansible.builtin.lineinfile:
         path: "/etc/cron.daily/logrotate"
-        line: '/usr/sbin/logrotate /etc/logrotate.conf'
-        regexp: '^[\s]*/usr/sbin/logrotate[\s\S]*/etc/logrotate.conf$'
+        line: '/usr/sbin/logrotate {{{ LOGROTATE_CONF_FILE }}}'
+        regexp: '^[\s]*/usr/sbin/logrotate[\s\S]*{{{ LOGROTATE_CONF_FILE }}}$'
         create: yes
 {{% endif %}}
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/bash/shared.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/bash/shared.sh
index c55cd9de94a6..b6ca7b5f2188 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/bash/shared.sh
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/bash/shared.sh
@@ -1,6 +1,11 @@
 # platform = multi_platform_all
 
-LOGROTATE_CONF_FILE="/etc/logrotate.conf"
+LOGROTATE_CONF_FILE='/etc/logrotate.conf'
+
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ bash_copy_distro_defaults('/usr/etc/logrotate.conf', "${LOGROTATE_CONF_FILE}") }}}
+{{% endif %}}
+
 {{% if 'sle' in product or product == 'slmicro5' %}}
 SYSTEMCTL_EXEC='/usr/bin/systemctl'
 {{% else %}}
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/oval/shared.xml b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/oval/shared.xml
index 907b69cc31e3..fc8a7ba8688b 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/oval/shared.xml
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/oval/shared.xml
@@ -11,7 +11,7 @@
       test_ref="test_logrotate_conf_no_other_keyword" />
       
         
-{{% if product in ["ol9", "rhcos4", "rhel9", "rhel10", "sle12", "sle15", "slmicro5"] %}}
+{{% if 'sle' in product or product in ["ol9", "rhcos4", "rhel9", "rhel10", "slmicro5"] %}}
         
 {{% endif %}}
       
@@ -54,7 +54,7 @@
     1
   
 
-  {{% if product in ["ol9", "rhcos4", "rhel9", "rhel10", "sle12", "sle15", "slmicro5"] %}}
+  {{% if 'sle' in product or product in ["ol9", "rhcos4", "rhel9", "rhel10", "slmicro5"] %}}
   
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/rule.yml b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/rule.yml
index 1e1b45b98055..3fbda225bc36 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/rule.yml
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/rule.yml
@@ -26,6 +26,7 @@ identifiers:
     cce@rhel10: CCE-88779-4
     cce@sle12: CCE-91511-6
     cce@sle15: CCE-85850-6
+    cce@sle16: CCE-96682-0
     cce@slmicro5: CCE-94014-8
 
 references:
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_extra_monthly.fail.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_extra_monthly.fail.sh
index e7c626f5b93b..7a011c88bf4e 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_extra_monthly.fail.sh
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_extra_monthly.fail.sh
@@ -1,6 +1,10 @@
 #!/bin/bash
 
 # packages = logrotate,crontabs
+LOGROTATE_CONF_FILE="/etc/logrotate.conf"
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ bash_copy_distro_defaults('/usr/etc/logrotate.conf', "${LOGROTATE_CONF_FILE}") }}}
+{{% endif %}}
 
-sed -i "s/weekly/daily/g" /etc/logrotate.conf
-echo "monthly" >> /etc/logrotate.conf
+sed -i "s/weekly/daily/g" "${LOGROTATE_CONF_FILE}"
+echo "monthly" >> "${LOGROTATE_CONF_FILE}"
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_weekly.fail.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_weekly.fail.sh
index de41c7b2844b..6d1132222642 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_weekly.fail.sh
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_conf_weekly.fail.sh
@@ -1,3 +1,7 @@
 #!/bin/bash
 
-sed -i "s/daily/weekly/" /etc/logrotate.conf
+LOGROTATE_CONF_FILE="/etc/logrotate.conf"
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ bash_copy_distro_defaults('/usr/etc/logrotate.conf', "${LOGROTATE_CONF_FILE}") }}}
+{{% endif %}}
+sed -i "s/daily/weekly/" "${LOGROTATE_CONF_FILE}"
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_configured.pass.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_configured.pass.sh
index 09409e4b3250..82e21f46cadc 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_configured.pass.sh
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_configured.pass.sh
@@ -1,7 +1,10 @@
 #!/bin/bash
 
-# platform = Oracle Linux 7,Oracle Linux 8
+# platform = Oracle Linux 7,Oracle Linux 8,SUSE Linux Enterprise 16
 
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ bash_copy_distro_defaults('/usr/etc/logrotate.conf', '/etc/logrotate.conf') }}}
+{{% endif %}}
 # fix logrotate config
 sed -i "s/\(weekly\|monthly\|yearly\)/daily/" /etc/logrotate.conf
 
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_missing.fail.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_missing.fail.sh
new file mode 100644
index 000000000000..ce29335f65ec
--- /dev/null
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_missing.fail.sh
@@ -0,0 +1,6 @@
+#!/bin/bash
+# platform = SUSE Linux Enterprise 16
+
+if [ -e "/etc/logrotate.conf" ] ; then
+    rm "/etc/logrotate.conf"
+fi
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_config.fail.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_config.fail.sh
index dc8182483935..e17862f9bada 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_config.fail.sh
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_config.fail.sh
@@ -2,5 +2,9 @@
 
 # packages = logrotate,crontabs
 
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ bash_copy_distro_defaults('/usr/etc/logrotate.conf', '/etc/logrotate.conf') }}}
+{{% endif %}}
+
 sed -i "/^\s*(daily|weekly|monthly|yearly)/d" /etc/logrotate.conf
 rm -f /etc/cron.daily/logrotate
diff --git a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_cron_daily_no_timer.fail.sh b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_cron_daily_no_timer.fail.sh
index 86b1ca86090d..f01fb0aea345 100644
--- a/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_cron_daily_no_timer.fail.sh
+++ b/linux_os/guide/system/logging/log_rotation/ensure_logrotate_activated/tests/logrotate_no_cron_daily_no_timer.fail.sh
@@ -2,11 +2,17 @@
 
 # packages = logrotate,crontabs
 
+LOGROTATE_CONF_FILE="/etc/logrotate.conf"
+
+{{% if product in [ 'sle16', 'slmicro6' ] %}}
+{{{ bash_copy_distro_defaults('/usr/etc/logrotate.conf', "${LOGROTATE_CONF_FILE}") }}}
+{{% endif %}}
+
 # disable the timer
 systemctl disable logrotate.timer || true
 
 # fix logrotate config
-sed -i "s/weekly/daily/" /etc/logrotate.conf
+sed -i "s/weekly/daily/" "${LOGROTATE_CONF_FILE}"
 
 # remove default for cron.daily
 rm -f /etc/cron.daily/logrotate
diff --git a/linux_os/guide/system/logging/log_rotation/package_logrotate_installed/rule.yml b/linux_os/guide/system/logging/log_rotation/package_logrotate_installed/rule.yml
index 74ae024ddbad..3ed696891870 100644
--- a/linux_os/guide/system/logging/log_rotation/package_logrotate_installed/rule.yml
+++ b/linux_os/guide/system/logging/log_rotation/package_logrotate_installed/rule.yml
@@ -30,9 +30,7 @@ references:
     nist-csf: PR.PT-1
     pcidss: Req-10.7
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="logrotate") }}}'
+{{{ complete_ocil_entry_package_installed("logrotate") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/logging/package_rsyslog-gnutls_installed/rule.yml b/linux_os/guide/system/logging/package_rsyslog-gnutls_installed/rule.yml
index da05bbd7db9b..2135e974f09f 100644
--- a/linux_os/guide/system/logging/package_rsyslog-gnutls_installed/rule.yml
+++ b/linux_os/guide/system/logging/package_rsyslog-gnutls_installed/rule.yml
@@ -1,18 +1,28 @@
+{{% if 'amzn' in families %}}
+  {{%- set package = "rsyslog-openssl" %}}
+{{% elif 'sle' not in product %}}
+  {{%- set package = "rsyslog-gnutls" %}}
+{{% else %}}
+  {{%- set package = "rsyslog-module-gtls" %}}
+{{% endif %}}
+
 documentation_complete: true
 
-title: 'Ensure rsyslog-gnutls is installed'
+title: 'Ensure {{{ package }}} is installed'
 
 description: |-
     TLS protocol support for rsyslog is installed.
     {{% if 'sle' not in product %}}
     {{{ describe_package_install(package="rsyslog-gnutls") }}}
+    {{% elif 'amzn' in families %}}
+    {{{ describe_package_install(package="rsyslog-openssl") }}}
     {{% else %}}
     {{{ describe_package_install(package="rsyslog-module-gtls") }}}
     {{% endif %}}
 
 
 rationale: |-
-    The rsyslog-gnutls package provides Transport Layer Security (TLS) support
+    The {{{ package }}} package provides Transport Layer Security (TLS) support
     for the rsyslog daemon, which enables secure remote logging.
 
 severity: medium
@@ -23,6 +33,7 @@ identifiers:
     cce@rhel10: CCE-89106-9
     cce@sle12: CCE-91512-4
     cce@sle15: CCE-91199-0
+    cce@sle16: CCE-95816-5
 
 references:
     srg: SRG-OS-000480-GPOS-00227,SRG-OS-000120-GPOS-00061
@@ -31,21 +42,27 @@ references:
 ocil_clause: 'the package is not installed'
 
 {{% if 'sle' not in product %}}
-{{{ complete_ocil_entry_package(package="rsyslog-gnutls") }}}
+{{{ complete_ocil_entry_package_installed(package="rsyslog-gnutls") }}}
+{{% elif 'amzn' in families %}}
+{{{ complete_ocil_entry_package_installed(package="rsyslog-openssl") }}}
 {{% else %}}
-{{{ complete_ocil_entry_package(package="rsyslog-module-gtls") }}}
+{{{ complete_ocil_entry_package_installed(package="rsyslog-module-gtls") }}}
 {{% endif %}}
 
 template:
     name: package_installed
     vars:
         pkgname: rsyslog-gnutls
+        pkgname@al2023: rsyslog-openssl
         pkgname@sle12: rsyslog-module-gtls
         pkgname@sle15: rsyslog-module-gtls
+        pkgname@sle16: rsyslog-module-gtls
 
 fixtext: |-
     {{% if 'sle' not in product %}}
     {{{ describe_package_install(package="rsyslog-gnutls") }}}
+    {{% elif 'amzn' in families %}}
+    {{{ describe_package_install(package="rsyslog-openssl") }}}
     {{% else %}}
     {{{ describe_package_install(package="rsyslog-module-gtls") }}}
     {{% endif %}}
diff --git a/linux_os/guide/system/logging/package_rsyslog_installed/rule.yml b/linux_os/guide/system/logging/package_rsyslog_installed/rule.yml
index 1d2b634233a3..b3292366f9d3 100644
--- a/linux_os/guide/system/logging/package_rsyslog_installed/rule.yml
+++ b/linux_os/guide/system/logging/package_rsyslog_installed/rule.yml
@@ -32,9 +32,7 @@ references:
     srg: SRG-OS-000479-GPOS-00224,SRG-OS-000051-GPOS-00024,SRG-OS-000480-GPOS-00227
     stigid@ol8: OL08-00-030670
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="rsyslog") }}}'
+{{{ complete_ocil_entry_package_installed("rsyslog") }}}
 
 fixtext: |-
     Configure {{{ full_name }}} to offload audit logs by installing the required packages with the following command:
diff --git a/linux_os/guide/system/logging/rsyslog_accepting_remote_messages/package_syslogng_installed/rule.yml b/linux_os/guide/system/logging/rsyslog_accepting_remote_messages/package_syslogng_installed/rule.yml
index 57241eee6686..a1fe9e136ae1 100644
--- a/linux_os/guide/system/logging/rsyslog_accepting_remote_messages/package_syslogng_installed/rule.yml
+++ b/linux_os/guide/system/logging/rsyslog_accepting_remote_messages/package_syslogng_installed/rule.yml
@@ -21,9 +21,7 @@ references:
     nist: CM-6(a)
     nist-csf: PR.PT-1
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="syslog-ng-core") }}}'
+{{{ complete_ocil_entry_package_installed("syslog-ng-core") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/logging/rsyslog_filecreatemode/ansible/shared.yml b/linux_os/guide/system/logging/rsyslog_filecreatemode/ansible/shared.yml
index 6f36c30a1104..9a534d42b607 100644
--- a/linux_os/guide/system/logging/rsyslog_filecreatemode/ansible/shared.yml
+++ b/linux_os/guide/system/logging/rsyslog_filecreatemode/ansible/shared.yml
@@ -39,6 +39,7 @@
     line: '$FileCreateMode 0640'
     mode: 0640
     create: true
+  register: result_rsyslog_filecreatemode_added
   when:
     - rsyslog_filecreatemode_files | length == 0 or result_rsyslog_filecreatemode_removed is not skipped
 
@@ -48,5 +49,15 @@
     regexp: '^\$FileCreateMode'
     line: $FileCreateMode 0640
   loop: "{{ rsyslog_filecreatemode_files }}"
+  register: result_rsyslog_filecreatemode_updated
   when:
     - rsyslog_filecreatemode_files | length == 1
+
+- name: "{{{ rule_title }}} - Restart rsyslog to Apply New $FileCreateMode Setting"
+  ansible.builtin.service:
+    name: rsyslog
+    state: restarted
+  when:
+    - result_rsyslog_filecreatemode_removed is changed
+      or result_rsyslog_filecreatemode_added is changed
+      or result_rsyslog_filecreatemode_updated is changed
diff --git a/linux_os/guide/system/logging/rsyslog_filecreatemode/bash/shared.sh b/linux_os/guide/system/logging/rsyslog_filecreatemode/bash/shared.sh
index 0eeb4896950f..b81ba7d24466 100644
--- a/linux_os/guide/system/logging/rsyslog_filecreatemode/bash/shared.sh
+++ b/linux_os/guide/system/logging/rsyslog_filecreatemode/bash/shared.sh
@@ -4,14 +4,18 @@
 # complexity = low
 # disruption = low
 
-sed -i '/^\s*$FileCreateMode/d' /etc/rsyslog.d/*
+find /etc/rsyslog.d/ -name '*.conf' -exec sed -i '/^\s*\$FileCreateMode/d' {} +
 
+changes_made=false
 if ! grep -qE '^\s*\$FileCreateMode\s+0640' /etc/rsyslog.conf; then
     if grep -qE '^\s*\$FileCreateMode' /etc/rsyslog.conf; then
         sed -i '/^\s*\$FileCreateMode/ s/^/#/' /etc/rsyslog.conf
     fi
     ## Assume there is no filter named as 00-, otherwise those filters might be included before this configuration and create file with different permissions
     echo '$FileCreateMode 0640' > /etc/rsyslog.d/00-rsyslog_filecreatemode.conf
+    changes_made=true
 fi
 
-systemctl restart rsyslog.service
+if [[ "$changes_made" == "true" ]] && [[ $(systemctl is-system-running) != "offline" ]]; then
+    systemctl restart rsyslog.service
+fi
diff --git a/linux_os/guide/system/logging/rsyslog_filecreatemode/rule.yml b/linux_os/guide/system/logging/rsyslog_filecreatemode/rule.yml
index 542b3a3dc7ac..19b38ceced33 100644
--- a/linux_os/guide/system/logging/rsyslog_filecreatemode/rule.yml
+++ b/linux_os/guide/system/logging/rsyslog_filecreatemode/rule.yml
@@ -16,6 +16,7 @@ severity: medium
 identifiers:
     cce@rhel8: CCE-88321-5
     cce@rhel9: CCE-88322-3
+    cce@rhel10: CCE-88819-8
     cce@sle15: CCE-92599-0
 
 ocil_clause: '$FileCreateMode is not set or is more permissive than 0640'
diff --git a/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls/rule.yml b/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls/rule.yml
index 7e245593bc8b..198927dcd228 100644
--- a/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls/rule.yml
+++ b/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls/rule.yml
@@ -25,6 +25,7 @@ identifiers:
     cce@rhel10: CCE-86592-3
     cce@sle12: CCE-91513-2
     cce@sle15: CCE-91200-6
+    cce@sle16: CCE-96405-6
 
 references:
     nist: AU-9(3),CM-6(a)
diff --git a/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls_cacert/rule.yml b/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls_cacert/rule.yml
index c9a7555c5e27..ff8c4ee91c3c 100644
--- a/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls_cacert/rule.yml
+++ b/linux_os/guide/system/logging/rsyslog_sending_messages/rsyslog_remote_tls_cacert/rule.yml
@@ -23,6 +23,7 @@ identifiers:
     cce@rhel10: CCE-88456-9
     cce@sle12: CCE-91514-0
     cce@sle15: CCE-91201-4
+    cce@sle16: CCE-96407-2
 
 references:
     srg: SRG-OS-000480-GPOS-00227
diff --git a/linux_os/guide/system/network/network-firewalld/firewalld_activation/package_firewalld_installed/rule.yml b/linux_os/guide/system/network/network-firewalld/firewalld_activation/package_firewalld_installed/rule.yml
index 0b974a275b36..64e521807275 100644
--- a/linux_os/guide/system/network/network-firewalld/firewalld_activation/package_firewalld_installed/rule.yml
+++ b/linux_os/guide/system/network/network-firewalld/firewalld_activation/package_firewalld_installed/rule.yml
@@ -38,9 +38,7 @@ references:
     stigid@ol8: OL08-00-040100
     stigid@sle15: SLES-15-010220
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="firewalld") }}}'
+{{{ complete_ocil_entry_package_installed("firewalld") }}}
 
 fixtext: |-
     To install the "firewalld" package run the following command:
diff --git a/linux_os/guide/system/network/network-firewalld/firewalld_deactivation/package_firewalld_removed/rule.yml b/linux_os/guide/system/network/network-firewalld/firewalld_deactivation/package_firewalld_removed/rule.yml
index b32d3a54d175..47e3718e8e61 100644
--- a/linux_os/guide/system/network/network-firewalld/firewalld_deactivation/package_firewalld_removed/rule.yml
+++ b/linux_os/guide/system/network/network-firewalld/firewalld_deactivation/package_firewalld_removed/rule.yml
@@ -24,7 +24,7 @@ identifiers:
 references:
     cis@sle15: 3.5.2.2,3.5.3.1.3
 
-{{{ complete_ocil_entry_package(package="firewalld") }}}
+{{{ complete_ocil_entry_package_removed("firewalld") }}}
 
 fixtext: '{{{ fixtext_package_removed("firewalld") }}}'
 
diff --git a/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_restricted/ansible/shared.yml b/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_restricted/ansible/shared.yml
index afd259064df8..13b67cd4b305 100644
--- a/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_restricted/ansible/shared.yml
+++ b/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_restricted/ansible/shared.yml
@@ -19,17 +19,23 @@
   block:
     - name: '{{{ rule_title }}} - Ensure firewalld trusted Zone Restricts IPv4 Loopback Traffic'
       ansible.builtin.command:
-        cmd: firewall-cmd --permanent --zone=trusted --add-rich-rule='rule family=ipv4 source address="127.0.0.1" destination not address="127.0.0.1" drop'
+        cmd: >-
+          firewall-cmd --permanent --zone=trusted
+          --add-rich-rule='rule family=ipv4 source address="127.0.0.1"
+          destination not address="127.0.0.1" drop'
       register: result_trusted_ipv4_restriction
       changed_when:
-          - "'ALREADY_ENABLED' not in result_trusted_ipv4_restriction.stderr"
+        - "'ALREADY_ENABLED' not in result_trusted_ipv4_restriction.stderr"
 
     - name: '{{{ rule_title }}} - Ensure firewalld trusted Zone Restricts IPv6 Loopback Traffic'
       ansible.builtin.command:
-        cmd: firewall-cmd --permanent --zone=trusted --add-rich-rule='rule family=ipv6 source address="::1" destination not address="::1" drop'
+        cmd: >-
+          firewall-cmd --permanent --zone=trusted
+          --add-rich-rule='rule family=ipv6 source address="::1"
+          destination not address="::1" drop'
       register: result_trusted_ipv6_restriction
       changed_when:
-          - "'ALREADY_ENABLED' not in result_trusted_ipv6_restriction.stderr"
+        - "'ALREADY_ENABLED' not in result_trusted_ipv6_restriction.stderr"
 
     - name: '{{{ rule_title }}} - Ensure firewalld Changes are Applied'
       ansible.builtin.service:
@@ -38,12 +44,14 @@
       when:
         - result_trusted_ipv4_restriction is changed or result_trusted_ipv6_restriction is changed
   when:
-    - ansible_facts.services['firewalld.service'].state == 'running'
+    - ('firewalld.service' in ansible_facts.services
+       and ansible_facts.services['firewalld.service'].state == 'running')
 
 - name: '{{{ rule_title }}} - Informative Message Based on Service State'
   ansible.builtin.assert:
     that:
-      - ansible_check_mode or ansible_facts.services['firewalld.service'].state == 'running'
+      - (ansible_check_mode or ('firewalld.service' in ansible_facts.services and
+         ansible_facts.services['firewalld.service'].state == 'running'))
     fail_msg:
       - firewalld service is not active. Remediation aborted!
       - This remediation could not be applied because it depends on firewalld service running.
diff --git a/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_trusted/ansible/shared.yml b/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_trusted/ansible/shared.yml
index 0179c6d9ea22..c7ec703cf727 100644
--- a/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_trusted/ansible/shared.yml
+++ b/linux_os/guide/system/network/network-firewalld/ruleset_modifications/firewalld_loopback_traffic_trusted/ansible/shared.yml
@@ -21,7 +21,7 @@
         cmd: firewall-cmd --permanent --zone=trusted --add-interface=lo
       register: result_lo_interface_assignment
       changed_when:
-          - "'ALREADY_ENABLED' not in result_lo_interface_assignment.stderr"
+        - "'ALREADY_ENABLED' not in result_lo_interface_assignment.stderr"
 
     - name: '{{{ rule_title }}} - Ensure firewalld Changes are Applied'
       ansible.builtin.service:
@@ -30,12 +30,14 @@
       when:
         - result_lo_interface_assignment is changed
   when:
-    - ansible_facts.services['firewalld.service'].state == 'running'
+    - ('firewalld.service' in ansible_facts.services and
+       ansible_facts.services['firewalld.service'].state == 'running')
 
 - name: '{{{ rule_title }}} - Informative Message Based on Service State'
   ansible.builtin.assert:
     that:
-      - ansible_check_mode or ansible_facts.services['firewalld.service'].state == 'running'
+      - (ansible_check_mode or ('firewalld.service' in ansible_facts.services
+         and ansible_facts.services['firewalld.service'].state == 'running'))
     fail_msg:
       - firewalld service is not active. Remediation aborted!
       - This remediation could not be applied because it depends on firewalld service running.
diff --git a/linux_os/guide/system/network/network-ipsec/directory_groupowner_etc_ipsecd/rule.yml b/linux_os/guide/system/network/network-ipsec/directory_groupowner_etc_ipsecd/rule.yml
index 00c3bccff8e8..817074dc64f4 100644
--- a/linux_os/guide/system/network/network-ipsec/directory_groupowner_etc_ipsecd/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/directory_groupowner_etc_ipsecd/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86439-7
     cce@rhel10: CCE-88800-8
     cce@sle15: CCE-92499-3
+    cce@sle16: CCE-96533-5
 
 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/ipsec.d", group="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/directory_owner_etc_ipsecd/rule.yml b/linux_os/guide/system/network/network-ipsec/directory_owner_etc_ipsecd/rule.yml
index ee3fd8aacb67..bbee4ba1f94c 100644
--- a/linux_os/guide/system/network/network-ipsec/directory_owner_etc_ipsecd/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/directory_owner_etc_ipsecd/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86303-5
     cce@rhel10: CCE-87636-7
     cce@sle15: CCE-92508-1
+    cce@sle16: CCE-96161-5
 
 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/ipsec.d", owner="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/directory_permissions_etc_ipsecd/rule.yml b/linux_os/guide/system/network/network-ipsec/directory_permissions_etc_ipsecd/rule.yml
index 3ac5d4a863ad..9caeafde3ecb 100644
--- a/linux_os/guide/system/network/network-ipsec/directory_permissions_etc_ipsecd/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/directory_permissions_etc_ipsecd/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86306-8
     cce@rhel10: CCE-88730-7
     cce@sle15: CCE-92517-2
+    cce@sle16: CCE-96356-1
 
 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/ipsec.d", perms="0700") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_conf/rule.yml b/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_conf/rule.yml
index 6ded8f5d59e0..88e0642ac261 100644
--- a/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_conf/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_conf/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86387-8
     cce@rhel10: CCE-86941-2
     cce@sle15: CCE-92535-4
+    cce@sle16: CCE-96555-8
 
 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/ipsec.conf", group="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_secrets/rule.yml b/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_secrets/rule.yml
index 3335f4d11050..121c920acf70 100644
--- a/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_secrets/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/file_groupowner_etc_ipsec_secrets/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86398-5
     cce@rhel10: CCE-89956-7
     cce@sle15: CCE-92537-0
+    cce@sle16: CCE-96394-2
 
 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/ipsec.secrets", group="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_conf/rule.yml b/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_conf/rule.yml
index d34d45083769..2c3cca80ac6b 100644
--- a/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_conf/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_conf/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86389-4
     cce@rhel9: CCE-86391-0
     cce@rhel10: CCE-87602-9
+    cce@sle16: CCE-96255-5
 
 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/ipsec.conf", owner="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_secrets/rule.yml b/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_secrets/rule.yml
index e852dc2af01e..f16a7747691f 100644
--- a/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_secrets/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/file_owner_etc_ipsec_secrets/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86400-9
     cce@rhel9: CCE-86401-7
     cce@rhel10: CCE-89330-5
+    cce@sle16: CCE-96064-1
 
 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/ipsec.secrets", owner="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_conf/rule.yml b/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_conf/rule.yml
index ad04bc9de2ac..a9112623365e 100644
--- a/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_conf/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_conf/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86393-6
     cce@rhel9: CCE-86395-1
     cce@rhel10: CCE-86443-9
+    cce@sle16: CCE-95807-4
 
 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/ipsec.conf", perms="0644") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_secrets/rule.yml b/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_secrets/rule.yml
index 41e2d7994ad3..cae7c2174d21 100644
--- a/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_secrets/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/file_permissions_etc_ipsec_secrets/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86410-8
     cce@rhel9: CCE-86411-6
     cce@rhel10: CCE-89450-1
+    cce@sle16: CCE-96190-4
 
 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/ipsec.secrets", perms="0644") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/package_libreswan_installed/rule.yml b/linux_os/guide/system/network/network-ipsec/package_libreswan_installed/rule.yml
index d2d3098eab7b..79124282ddbf 100644
--- a/linux_os/guide/system/network/network-ipsec/package_libreswan_installed/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/package_libreswan_installed/rule.yml
@@ -35,9 +35,7 @@ references:
     pcidss: Req-4.1
     srg: SRG-OS-000480-GPOS-00227,SRG-OS-000120-GPOS-00061
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="libreswan") }}}'
+{{{ complete_ocil_entry_package_installed("libreswan") }}}
 
 fixtext: '{{{ fixtext_package_installed("libreswan") }}}'
 
diff --git a/linux_os/guide/system/network/network-ipsec/package_strongswan_installed/rule.yml b/linux_os/guide/system/network/network-ipsec/package_strongswan_installed/rule.yml
index 0f2318334d39..3a6e4de6d971 100644
--- a/linux_os/guide/system/network/network-ipsec/package_strongswan_installed/rule.yml
+++ b/linux_os/guide/system/network/network-ipsec/package_strongswan_installed/rule.yml
@@ -30,9 +30,7 @@ references:
     pcidss: Req-4.1
     srg: SRG-OS-000480-GPOS-00227,SRG-OS-000120-GPOS-00061
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="strongswan") }}}'
+{{{ complete_ocil_entry_package_installed("strongswan") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/network/network-iptables/directory_groupowner_etc_iptables/rule.yml b/linux_os/guide/system/network/network-iptables/directory_groupowner_etc_iptables/rule.yml
index 850de8d57516..fd61baff835a 100644
--- a/linux_os/guide/system/network/network-iptables/directory_groupowner_etc_iptables/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/directory_groupowner_etc_iptables/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86426-4
     cce@rhel9: CCE-86427-2
     cce@rhel10: CCE-86460-3
+    cce@sle16: CCE-95799-3
 
 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/iptables", group="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-iptables/directory_owner_etc_iptables/rule.yml b/linux_os/guide/system/network/network-iptables/directory_owner_etc_iptables/rule.yml
index 73bee5710314..61e65cf453d5 100644
--- a/linux_os/guide/system/network/network-iptables/directory_owner_etc_iptables/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/directory_owner_etc_iptables/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86429-8
     cce@rhel9: CCE-86430-6
     cce@rhel10: CCE-89981-5
+    cce@sle16: CCE-96146-6
 
 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/iptables", owner="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-iptables/directory_permissions_etc_iptables/rule.yml b/linux_os/guide/system/network/network-iptables/directory_permissions_etc_iptables/rule.yml
index fe8bfe7c1de6..9ca60ed074a1 100644
--- a/linux_os/guide/system/network/network-iptables/directory_permissions_etc_iptables/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/directory_permissions_etc_iptables/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-86435-5
     cce@rhel9: CCE-86436-3
     cce@rhel10: CCE-86577-4
+    cce@sle16: CCE-96612-7
 
 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/iptables", perms="0700") }}}'
 
diff --git a/linux_os/guide/system/network/network-iptables/package_iptables-nft_installed/rule.yml b/linux_os/guide/system/network/network-iptables/package_iptables-nft_installed/rule.yml
index 73552ac09ec0..c41950f89215 100644
--- a/linux_os/guide/system/network/network-iptables/package_iptables-nft_installed/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/package_iptables-nft_installed/rule.yml
@@ -21,9 +21,7 @@ identifiers:
 references:
     nist: CM-6(a)
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="iptables-nft") }}}'
+{{{ complete_ocil_entry_package_installed("iptables-nft") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/network/network-iptables/package_iptables-persistent_installed/rule.yml b/linux_os/guide/system/network/network-iptables/package_iptables-persistent_installed/rule.yml
index 4c0aaca58dfb..afdc7d20c795 100644
--- a/linux_os/guide/system/network/network-iptables/package_iptables-persistent_installed/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/package_iptables-persistent_installed/rule.yml
@@ -13,9 +13,7 @@ severity: medium
 
 platform: package[iptables]
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="iptables-persistent") }}}'
+{{{ complete_ocil_entry_package_installed("iptables-persistent") }}}
 
 {{%- if 'ubuntu' in product %}}
 template:
diff --git a/linux_os/guide/system/network/network-iptables/package_iptables-persistent_removed/rule.yml b/linux_os/guide/system/network/network-iptables/package_iptables-persistent_removed/rule.yml
index ef8bdc559fcb..fa519c12cdc9 100644
--- a/linux_os/guide/system/network/network-iptables/package_iptables-persistent_removed/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/package_iptables-persistent_removed/rule.yml
@@ -13,9 +13,7 @@ severity: medium
 
 platform: package[ufw]
 
-ocil_clause: 'the package is installed'
-
-ocil: '{{{ ocil_package(package="iptables-persistent") }}}'
+{{{ complete_ocil_entry_package_removed("iptables-persistent") }}}
 
 template:
     name: package_removed
diff --git a/linux_os/guide/system/network/network-iptables/package_iptables-services_installed/rule.yml b/linux_os/guide/system/network/network-iptables/package_iptables-services_installed/rule.yml
index 7a39d7ec752e..1d686035c231 100644
--- a/linux_os/guide/system/network/network-iptables/package_iptables-services_installed/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/package_iptables-services_installed/rule.yml
@@ -23,9 +23,7 @@ references:
     nist: CM-6(a)
     srg: SRG-OS-000480-GPOS-00227
 
-ocil_clause: 'the iptables-services package is not installed'
-
-ocil: '{{{ ocil_package(package="iptables-services") }}}'
+{{{ complete_ocil_entry_package_installed("iptables-services") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/network/network-iptables/package_iptables-services_removed/rule.yml b/linux_os/guide/system/network/network-iptables/package_iptables-services_removed/rule.yml
index d7defdc05f72..ea96552678e5 100644
--- a/linux_os/guide/system/network/network-iptables/package_iptables-services_removed/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/package_iptables-services_removed/rule.yml
@@ -20,10 +20,7 @@ platform: package[iptables]
 identifiers:
     cce@rhel8: CCE-86679-8
 
-
-ocil_clause: 'the iptables-services package is installed'
-
-ocil: '{{{ ocil_package(package="iptables-services") }}}'
+{{{ complete_ocil_entry_package_removed("iptables-services") }}}
 
 template:
     name: package_removed
diff --git a/linux_os/guide/system/network/network-iptables/package_iptables_installed/rule.yml b/linux_os/guide/system/network/network-iptables/package_iptables_installed/rule.yml
index e2fdaad08ada..c3cc32d49472 100644
--- a/linux_os/guide/system/network/network-iptables/package_iptables_installed/rule.yml
+++ b/linux_os/guide/system/network/network-iptables/package_iptables_installed/rule.yml
@@ -29,9 +29,7 @@ references:
     pcidss: Req-1.4.1
     srg: SRG-OS-000480-GPOS-00227
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="iptables") }}}'
+{{{ complete_ocil_entry_package_installed("iptables") }}}
 
 {{%- if product in [ "sle12", "sle15" ] or 'ubuntu' in product %}}
 template:
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_defrtr/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_defrtr/rule.yml
index 3b7fa656ccf9..d6c3e91138fa 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_defrtr/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_defrtr/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-90653-7
     cce@sle12: CCE-91517-3
     cce@sle15: CCE-91202-2
+    cce@sle16: CCE-96633-3
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.all.accept_ra_defrtr", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_pinfo/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_pinfo/rule.yml
index b1e75aa592d6..449358c21675 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_pinfo/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_pinfo/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-88717-4
     cce@sle12: CCE-91518-1
     cce@sle15: CCE-91203-0
+    cce@sle16: CCE-95919-7
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.all.accept_ra_pinfo", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_rtr_pref/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_rtr_pref/rule.yml
index 82d235cf30bf..7ba89e5d8ff1 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_rtr_pref/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_ra_rtr_pref/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-90302-1
     cce@sle12: CCE-91519-9
     cce@sle15: CCE-91204-8
+    cce@sle16: CCE-96383-5
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.all.accept_ra_rtr_pref", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_redirects/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_redirects/rule.yml
index 551d15a411a9..027e308f53db 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_redirects/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_redirects/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel10: CCE-90083-7
     cce@sle12: CCE-83246-9
     cce@sle15: CCE-85708-6
+    cce@sle16: CCE-96632-5
     cce@slmicro5: CCE-93635-1
     cce@slmicro6: CCE-95079-0 
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_source_route/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_source_route/rule.yml
index d5356b7436e0..a96d1af2a24b 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_source_route/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_accept_source_route/rule.yml
@@ -24,6 +24,7 @@ identifiers:
     cce@rhel10: CCE-90450-8
     cce@sle12: CCE-83078-6
     cce@sle15: CCE-85649-2
+    cce@sle16: CCE-96132-6
     cce@slmicro5: CCE-93630-2
     cce@slmicro6: CCE-95074-1 
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_autoconf/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_autoconf/rule.yml
index 9488675532ca..2b6704e6c378 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_autoconf/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_autoconf/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-88386-8
     cce@sle12: CCE-91520-7
     cce@sle15: CCE-91205-5
+    cce@sle16: CCE-96669-7
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.all.autoconf", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_max_addresses/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_max_addresses/rule.yml
index 66431fe69b3e..413d120c2f30 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_max_addresses/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_max_addresses/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel10: CCE-88552-5
     cce@sle12: CCE-91521-5
     cce@sle15: CCE-91206-3
+    cce@sle16: CCE-96622-6
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.all.max_addresses", value="1") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_router_solicitations/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_router_solicitations/rule.yml
index c58038f96902..b9e6f37fbc6c 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_router_solicitations/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_all_router_solicitations/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-89461-8
     cce@sle12: CCE-91522-3
     cce@sle15: CCE-91207-1
+    cce@sle16: CCE-96065-8
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.all.router_solicitations", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_defrtr/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_defrtr/rule.yml
index 72703a4ddd80..eed209869204 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_defrtr/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_defrtr/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-88613-5
     cce@sle12: CCE-91523-1
     cce@sle15: CCE-91208-9
+    cce@sle16: CCE-96411-4
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.default.accept_ra_defrtr", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_pinfo/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_pinfo/rule.yml
index b44a8ec176c9..f426bfda0309 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_pinfo/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_pinfo/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-88012-0
     cce@sle12: CCE-91524-9
     cce@sle15: CCE-91209-7
+    cce@sle16: CCE-96557-4
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.default.accept_ra_pinfo", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_rtr_pref/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_rtr_pref/rule.yml
index 24855b34558d..8be051de79ce 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_rtr_pref/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_ra_rtr_pref/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-90749-3
     cce@sle12: CCE-91525-6
     cce@sle15: CCE-91210-5
+    cce@sle16: CCE-96589-7
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.default.accept_ra_rtr_pref", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_redirects/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_redirects/rule.yml
index 7db2187f43ec..8f8f0be40d5b 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_redirects/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_accept_redirects/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel10: CCE-89486-5
     cce@sle12: CCE-83223-8
     cce@sle15: CCE-85722-7
+    cce@sle16: CCE-96192-0
     cce@slmicro5: CCE-93636-9
     cce@slmicro6: CCE-95080-8 
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_autoconf/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_autoconf/rule.yml
index 3c5b873a4c98..26697c15d21c 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_autoconf/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_autoconf/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-86607-9
     cce@sle12: CCE-91526-4
     cce@sle15: CCE-91211-3
+    cce@sle16: CCE-96177-1
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.default.autoconf", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_max_addresses/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_max_addresses/rule.yml
index 1ca02e21ab20..60f370531c26 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_max_addresses/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_max_addresses/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel10: CCE-89273-7
     cce@sle12: CCE-91527-2
     cce@sle15: CCE-91212-1
+    cce@sle16: CCE-95727-4
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.default.max_addresses", value="1") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_router_solicitations/rule.yml b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_router_solicitations/rule.yml
index a6fd5ec63f57..5ecba12f7eb4 100644
--- a/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_router_solicitations/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/configuring_ipv6/sysctl_net_ipv6_conf_default_router_solicitations/rule.yml
@@ -15,6 +15,7 @@ identifiers:
     cce@rhel10: CCE-89658-9
     cce@sle12: CCE-91528-0
     cce@sle15: CCE-91213-9
+    cce@sle16: CCE-96390-0
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv6.conf.default.router_solicitations", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-ipv6/disabling_ipv6/grub2_ipv6_disable_argument/rule.yml b/linux_os/guide/system/network/network-ipv6/disabling_ipv6/grub2_ipv6_disable_argument/rule.yml
index 7e2f1dacc65b..65ed5fe5cc13 100644
--- a/linux_os/guide/system/network/network-ipv6/disabling_ipv6/grub2_ipv6_disable_argument/rule.yml
+++ b/linux_os/guide/system/network/network-ipv6/disabling_ipv6/grub2_ipv6_disable_argument/rule.yml
@@ -38,3 +38,5 @@ template:
     vars:
         arg_name: ipv6.disable
         arg_value: '1'
+        datatype: int
+        operation: equals
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_local/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_local/rule.yml
index 5091848972c4..cde2ea069c6a 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_local/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_local/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel8: CCE-88789-3
     cce@rhel9: CCE-89789-2
     cce@rhel10: CCE-86895-0
+    cce@sle16: CCE-96055-9
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.all.accept_local", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_redirects/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_redirects/rule.yml
index fb26eb41907a..654a99a37f0d 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_redirects/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_redirects/rule.yml
@@ -23,6 +23,7 @@ identifiers:
     cce@rhel10: CCE-90409-4
     cce@sle12: CCE-83090-1
     cce@sle15: CCE-85651-8
+    cce@sle16: CCE-96527-7
     cce@slmicro5: CCE-93633-6
     cce@slmicro6: CCE-95077-4 
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_source_route/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_source_route/rule.yml
index 5fd871ab0fea..9bd302a891fb 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_source_route/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_accept_source_route/rule.yml
@@ -24,6 +24,7 @@ identifiers:
     cce@rhel10: CCE-90165-2
     cce@sle12: CCE-83064-6
     cce@sle15: CCE-85648-4
+    cce@sle16: CCE-96355-3
     cce@slmicro5: CCE-93629-4
     cce@slmicro6: CCE-95073-3 
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_filter/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_filter/rule.yml
index fc747f705c48..ac9db557bdcd 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_filter/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_filter/rule.yml
@@ -20,6 +20,7 @@ identifiers:
     cce@rhel9: CCE-89555-7
     cce@rhel10: CCE-89431-1
     cce@sle15: CCE-92609-7
+    cce@sle16: CCE-96549-1
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.all.arp_filter", value=xccdf_value("sysctl_net_ipv4_conf_all_arp_filter_value")) }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_ignore/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_ignore/rule.yml
index 916872b8ffe0..9302d69a4d77 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_ignore/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_arp_ignore/rule.yml
@@ -18,6 +18,7 @@ identifiers:
     cce@rhel9: CCE-89889-0
     cce@rhel10: CCE-87433-9
     cce@sle15: CCE-92610-5
+    cce@sle16: CCE-96367-8
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.all.arp_ignore", value=xccdf_value("sysctl_net_ipv4_conf_all_arp_ignore")) }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_drop_gratuitous_arp/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_drop_gratuitous_arp/rule.yml
index c3a61454b8e4..b3c83e6a668a 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_drop_gratuitous_arp/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_drop_gratuitous_arp/rule.yml
@@ -18,6 +18,7 @@ identifiers:
     cce@rhel8: CCE-88001-3
     cce@rhel9: CCE-89001-2
     cce@rhel10: CCE-89975-7
+    cce@sle16: CCE-96672-1
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.all.drop_gratuitous_arp", value="1") }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_route_localnet/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_route_localnet/rule.yml
index cd544692838a..3c2723ad9125 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_route_localnet/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_route_localnet/rule.yml
@@ -16,6 +16,7 @@ identifiers:
     cce@rhel9: CCE-89023-6
     cce@rhel10: CCE-87566-6
     cce@sle15: CCE-92611-3
+    cce@sle16: CCE-96513-7
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.all.route_localnet", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_shared_media/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_shared_media/rule.yml
index 311db0b56990..8a1d5353ccef 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_shared_media/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_all_shared_media/rule.yml
@@ -14,6 +14,7 @@ identifiers:
     cce@rhel8: CCE-88333-0
     cce@rhel9: CCE-89333-9
     cce@rhel10: CCE-87897-5
+    cce@sle16: CCE-95865-2
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.all.shared_media", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_accept_source_route/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_accept_source_route/rule.yml
index 81acc33e797e..8658fc9a8c75 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_accept_source_route/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_accept_source_route/rule.yml
@@ -24,6 +24,7 @@ identifiers:
     cce@rhel10: CCE-88071-6
     cce@sle12: CCE-83079-4
     cce@sle15: CCE-85650-0
+    cce@sle16: CCE-96076-5
     cce@slmicro5: CCE-93631-0
     cce@slmicro6: CCE-95075-8 
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_rp_filter/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_rp_filter/rule.yml
index b57fd00eea2f..332b397304fe 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_rp_filter/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_rp_filter/rule.yml
@@ -21,6 +21,7 @@ identifiers:
     cce@rhel10: CCE-87424-8
     cce@sle12: CCE-91534-8
     cce@sle15: CCE-91219-6
+    cce@sle16: CCE-96229-0
     cce@slmicro5: CCE-93989-2
 
 references:
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_secure_redirects/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_secure_redirects/rule.yml
index e93e06ac07ab..d0fcab062731 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_secure_redirects/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_secure_redirects/rule.yml
@@ -19,6 +19,7 @@ identifiers:
     cce@rhel10: CCE-87878-5
     cce@sle12: CCE-91536-3
     cce@sle15: CCE-91221-2
+    cce@sle16: CCE-96196-1
     cce@slmicro5: CCE-93988-4
 
 references:
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_shared_media/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_shared_media/rule.yml
index 03b578066423..6b58733b25c2 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_shared_media/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_conf_default_shared_media/rule.yml
@@ -14,6 +14,7 @@ identifiers:
     cce@rhel8: CCE-88444-5
     cce@rhel9: CCE-89444-4
     cce@rhel10: CCE-89010-3
+    cce@sle16: CCE-96642-4
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.conf.default.shared_media", value="0") }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_ip_local_port_range/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_ip_local_port_range/rule.yml
index 942c1351b285..8edb7ace3694 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_ip_local_port_range/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_ip_local_port_range/rule.yml
@@ -18,6 +18,7 @@ identifiers:
     cce@rhel10: CCE-90347-6
     cce@sle12: CCE-91540-5
     cce@sle15: CCE-91225-3
+    cce@sle16: CCE-96447-8
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.ip_local_port_range", value="32768 65535") }}}
 
diff --git a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_tcp_rfc1337/rule.yml b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_tcp_rfc1337/rule.yml
index d6721442dc54..1fe1d752c719 100644
--- a/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_tcp_rfc1337/rule.yml
+++ b/linux_os/guide/system/network/network-kernel/network_host_and_router_parameters/sysctl_net_ipv4_tcp_rfc1337/rule.yml
@@ -18,6 +18,7 @@ identifiers:
     cce@rhel10: CCE-86164-1
     cce@sle12: CCE-91538-9
     cce@sle15: CCE-91223-8
+    cce@sle16: CCE-96069-0
 
 {{{ complete_ocil_entry_sysctl_option_value(sysctl="net.ipv4.tcp_rfc1337", value="1") }}}
 
diff --git a/linux_os/guide/system/network/network-nftables/directory_groupowner_etc_nftables/rule.yml b/linux_os/guide/system/network/network-nftables/directory_groupowner_etc_nftables/rule.yml
index 4838427b8bcb..4b0b04bb39b9 100644
--- a/linux_os/guide/system/network/network-nftables/directory_groupowner_etc_nftables/rule.yml
+++ b/linux_os/guide/system/network/network-nftables/directory_groupowner_etc_nftables/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86309-2
     cce@rhel10: CCE-87879-3
     cce@sle15: CCE-92500-8
+    cce@sle16: CCE-96397-5
 
 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/nftables", group="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-nftables/directory_owner_etc_nftables/rule.yml b/linux_os/guide/system/network/network-nftables/directory_owner_etc_nftables/rule.yml
index 14eb51f4a138..d1e8d31f6366 100644
--- a/linux_os/guide/system/network/network-nftables/directory_owner_etc_nftables/rule.yml
+++ b/linux_os/guide/system/network/network-nftables/directory_owner_etc_nftables/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86313-4
     cce@rhel10: CCE-88672-1
     cce@sle15: CCE-92509-9
+    cce@sle16: CCE-96211-8
 
 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/nftables", owner="root") }}}'
 
diff --git a/linux_os/guide/system/network/network-nftables/directory_permissions_etc_nftables/rule.yml b/linux_os/guide/system/network/network-nftables/directory_permissions_etc_nftables/rule.yml
index a9d01ad9c783..4acab56b2bd9 100644
--- a/linux_os/guide/system/network/network-nftables/directory_permissions_etc_nftables/rule.yml
+++ b/linux_os/guide/system/network/network-nftables/directory_permissions_etc_nftables/rule.yml
@@ -17,6 +17,7 @@ identifiers:
     cce@rhel9: CCE-86320-9
     cce@rhel10: CCE-88802-4
     cce@sle15: CCE-92521-4
+    cce@sle16: CCE-96496-5
 
 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/nftables", perms="0700") }}}'
 
diff --git a/linux_os/guide/system/network/network-nftables/package_nftables_installed/rule.yml b/linux_os/guide/system/network/network-nftables/package_nftables_installed/rule.yml
index 35552c4b3530..e09fe3d9c48d 100644
--- a/linux_os/guide/system/network/network-nftables/package_nftables_installed/rule.yml
+++ b/linux_os/guide/system/network/network-nftables/package_nftables_installed/rule.yml
@@ -27,9 +27,7 @@ identifiers:
 references:
     cis@sle15: 3.5.2.1
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="nftables") }}}'
+{{{ complete_ocil_entry_package_installed("nftables") }}}
 
 platform: system_with_kernel and service_disabled[iptables] and service_disabled[ufw]
 
diff --git a/linux_os/guide/system/network/network-nftables/package_nftables_removed/rule.yml b/linux_os/guide/system/network/network-nftables/package_nftables_removed/rule.yml
index 4d3b3c1618ef..60d5ea59bf2a 100644
--- a/linux_os/guide/system/network/network-nftables/package_nftables_removed/rule.yml
+++ b/linux_os/guide/system/network/network-nftables/package_nftables_removed/rule.yml
@@ -20,7 +20,7 @@ identifiers:
 references:
     cis@sle15: 3.5.1.2,3.5.3.1.2
 
-{{{ complete_ocil_entry_package(package="nftables") }}}
+{{{ complete_ocil_entry_package_removed("nftables") }}}
 
 fixtext: '{{{ fixtext_package_removed("nftables") }}}'
 
diff --git a/linux_os/guide/system/network/network-susefirewall2/package_SuSEfirewall2_installed/rule.yml b/linux_os/guide/system/network/network-susefirewall2/package_SuSEfirewall2_installed/rule.yml
index d0daf70b9e3e..a210c2e85643 100644
--- a/linux_os/guide/system/network/network-susefirewall2/package_SuSEfirewall2_installed/rule.yml
+++ b/linux_os/guide/system/network/network-susefirewall2/package_SuSEfirewall2_installed/rule.yml
@@ -18,9 +18,7 @@ references:
     srg: SRG-OS-000420-GPOS-00186,SRG-OS-000096-GPOS-00050
     stigid@sle12: SLES-12-030030
 
-ocil_clause: 'the package is not installed'
-
-ocil: '{{{ ocil_package(package="SuSEfirewall2") }}}'
+{{{ complete_ocil_entry_package_installed("SuSEfirewall2") }}}
 
 template:
     name: package_installed
diff --git a/linux_os/guide/system/network/network-susefirewall2/susefirewall2_ddos_protection/rule.yml b/linux_os/guide/system/network/network-susefirewall2/susefirewall2_ddos_protection/rule.yml
index 7222131437e3..ee729a542b16 100644
--- a/linux_os/guide/system/network/network-susefirewall2/susefirewall2_ddos_protection/rule.yml
+++ b/linux_os/guide/system/network/network-susefirewall2/susefirewall2_ddos_protection/rule.yml
@@ -45,7 +45,8 @@ references:
 ocil_clause: 'the DoS protection is not active'
 
 ocil: |-
-    {{{ ocil_package(package="SuSEfirewall2") }}}
+    Run the following command to determine if the SuSEfirewall2 package is installed: 
$rpm -q SuSEfirewall2
+ {{{ ocil_service_enabled(service="SuSEfirewall2") }}} Run the following command: diff --git a/linux_os/guide/system/network/network-susefirewall2/susefirewall2_only_required_services/rule.yml b/linux_os/guide/system/network/network-susefirewall2/susefirewall2_only_required_services/rule.yml index 126dd0183a41..ee44169fb944 100644 --- a/linux_os/guide/system/network/network-susefirewall2/susefirewall2_only_required_services/rule.yml +++ b/linux_os/guide/system/network/network-susefirewall2/susefirewall2_only_required_services/rule.yml @@ -50,7 +50,8 @@ references: ocil_clause: 'unauthorized network services can be accessed from the network' ocil: |- - {{{ ocil_package(package="SuSEfirewall2") }}} + Run the following command to determine if the SuSEfirewall2 package is installed:
$rpm -q SuSEfirewall2
+ {{{ ocil_service_enabled(service="SuSEfirewall2") }}} Check the firewall configuration for any unnecessary or prohibited diff --git a/linux_os/guide/system/network/network-ufw/package_ufw_installed/rule.yml b/linux_os/guide/system/network/network-ufw/package_ufw_installed/rule.yml index 53035bc75c34..64341e55dfc9 100644 --- a/linux_os/guide/system/network/network-ufw/package_ufw_installed/rule.yml +++ b/linux_os/guide/system/network/network-ufw/package_ufw_installed/rule.yml @@ -15,9 +15,7 @@ severity: medium references: srg: SRG-OS-000297-GPOS-00115 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="ufw") }}}' +{{{ complete_ocil_entry_package_installed("ufw") }}} {{%- if 'ubuntu' in product %}} template: diff --git a/linux_os/guide/system/network/network-ufw/package_ufw_removed/rule.yml b/linux_os/guide/system/network/network-ufw/package_ufw_removed/rule.yml index 1efcd761d632..d0114bcb6b07 100644 --- a/linux_os/guide/system/network/network-ufw/package_ufw_removed/rule.yml +++ b/linux_os/guide/system/network/network-ufw/package_ufw_removed/rule.yml @@ -11,9 +11,7 @@ rationale: |- severity: medium -ocil_clause: 'the package is installed' - -ocil: '{{{ ocil_package(package="ufw") }}}' +{{{ complete_ocil_entry_package_removed("ufw") }}} platform: system_with_kernel diff --git a/linux_os/guide/system/network/network-wireless/wireless_software/service_bluetooth_disabled/rule.yml b/linux_os/guide/system/network/network-wireless/wireless_software/service_bluetooth_disabled/rule.yml index c4e54a6a838d..58c7ab8cc0ca 100644 --- a/linux_os/guide/system/network/network-wireless/wireless_software/service_bluetooth_disabled/rule.yml +++ b/linux_os/guide/system/network/network-wireless/wireless_software/service_bluetooth_disabled/rule.yml @@ -16,6 +16,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-89516-9 cce@rhel8: CCE-87231-7 cce@rhel9: CCE-86761-4 cce@rhel10: CCE-90381-5 diff --git a/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_in_bios/rule.yml b/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_in_bios/rule.yml index 8514f1be0618..bf988c70fd08 100644 --- a/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_in_bios/rule.yml +++ b/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_in_bios/rule.yml @@ -16,6 +16,16 @@ rationale: |- severity: unknown +ocil_clause: 'wireless devices (WiFi or Bluetooth) are enabled in BIOS' + +ocil: |- + Verify that built-in wireless devices (WiFi and Bluetooth) are disabled in the system + boot firmware (BIOS/UEFI). The process to configure this setting varies by hardware + manufacturer and model. Some systems may not have wireless devices or may not provide + BIOS-level controls for wireless devices. + Consult your hardware manual or vendor documentation for specific instructions on how to + access the firmware setup during boot and disable wireless device support. + identifiers: cce@rhcos4: CCE-82659-4 cce@rhel9: CCE-89909-6 diff --git a/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_interfaces/ansible/shared.yml b/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_interfaces/ansible/shared.yml index efa6874c2b56..843bccf47df6 100644 --- a/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_interfaces/ansible/shared.yml +++ b/linux_os/guide/system/network/network-wireless/wireless_software/wireless_disable_interfaces/ansible/shared.yml @@ -13,7 +13,8 @@ ansible.builtin.command: wicked ifdown {{ item }} loop: '{{ ansible_facts.interfaces }}' when: - - ansible_facts.services['wickedd.service'].state == 'running' + - ('wickedd.service' in ansible_facts.services and + ansible_facts.services['wickedd.service'].state == 'running') - 'item.startswith("wl")' - name: "{{{ rule_title }}} - Wicked Disable Wireless Network Interfaces" @@ -23,7 +24,8 @@ line: STARTMODE=off loop: '{{ ansible_facts.interfaces }}' when: - - ansible_facts.services['wickedd.service'].state == 'running' + - ('wickedd.service' in ansible_facts.services and + ansible_facts.services['wickedd.service'].state == 'running') - 'item.startswith("wl")' {{%- else %}} @@ -40,4 +42,5 @@ ansible.builtin.command: nmcli radio wifi off when: - "'NetworkManager' in ansible_facts.packages" - - ansible_facts.services['NetworkManager.service'].state == 'running' + - ('NetworkManager.service' in ansible_facts.services and + ansible_facts.services['NetworkManager.service'].state == 'running') diff --git a/linux_os/guide/system/permissions/files/dir_perms_world_writable_root_owned/rule.yml b/linux_os/guide/system/permissions/files/dir_perms_world_writable_root_owned/rule.yml index dbaec786e5ec..7e8dfdccc7b4 100644 --- a/linux_os/guide/system/permissions/files/dir_perms_world_writable_root_owned/rule.yml +++ b/linux_os/guide/system/permissions/files/dir_perms_world_writable_root_owned/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-89514-4 cce@sle12: CCE-91597-5 cce@sle15: CCE-91239-4 + cce@sle16: CCE-95897-5 references: srg: SRG-OS-000480-GPOS-00227,SRG-OS-000138-GPOS-00069 diff --git a/linux_os/guide/system/permissions/files/dir_perms_world_writable_system_owned/rule.yml b/linux_os/guide/system/permissions/files/dir_perms_world_writable_system_owned/rule.yml index 3a3bc5278b49..b5fe9798720c 100644 --- a/linux_os/guide/system/permissions/files/dir_perms_world_writable_system_owned/rule.yml +++ b/linux_os/guide/system/permissions/files/dir_perms_world_writable_system_owned/rule.yml @@ -28,6 +28,9 @@ references: stigid@ol7: OL07-00-021031 stigid@ol8: OL08-00-010700 +identifiers: + cce@rhel9: CCE-86469-4 + ocil_clause: 'there is output' ocil: |- diff --git a/linux_os/guide/system/permissions/files/dir_system_commands_group_root_owned/rule.yml b/linux_os/guide/system/permissions/files/dir_system_commands_group_root_owned/rule.yml index 1285c94d87a1..4a300fcd8a49 100644 --- a/linux_os/guide/system/permissions/files/dir_system_commands_group_root_owned/rule.yml +++ b/linux_os/guide/system/permissions/files/dir_system_commands_group_root_owned/rule.yml @@ -40,6 +40,7 @@ identifiers: cce@rhel10: CCE-89520-1 cce@sle12: CCE-83244-4 cce@sle15: CCE-85743-3 + cce@sle16: CCE-95915-5 cce@slmicro5: CCE-93702-9 cce@slmicro6: CCE-94700-2 diff --git a/linux_os/guide/system/permissions/files/dir_system_commands_root_owned/rule.yml b/linux_os/guide/system/permissions/files/dir_system_commands_root_owned/rule.yml index d3b464811bd9..12dc621b7fde 100644 --- a/linux_os/guide/system/permissions/files/dir_system_commands_root_owned/rule.yml +++ b/linux_os/guide/system/permissions/files/dir_system_commands_root_owned/rule.yml @@ -38,6 +38,7 @@ identifiers: cce@rhel10: CCE-88203-5 cce@sle12: CCE-83242-8 cce@sle15: CCE-85741-7 + cce@sle16: CCE-96321-5 cce@slmicro5: CCE-93700-3 cce@slmicro6: CCE-94698-8 diff --git a/linux_os/guide/system/permissions/files/file_groupowner_etc_crypttab/rule.yml b/linux_os/guide/system/permissions/files/file_groupowner_etc_crypttab/rule.yml index f9a6756eca37..bf123935cac6 100644 --- a/linux_os/guide/system/permissions/files/file_groupowner_etc_crypttab/rule.yml +++ b/linux_os/guide/system/permissions/files/file_groupowner_etc_crypttab/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel8: CCE-86362-1 cce@rhel9: CCE-86363-9 cce@rhel10: CCE-88558-2 + cce@sle16: CCE-95756-3 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/crypttab", group="root") }}}' diff --git a/linux_os/guide/system/permissions/files/file_groupowner_etc_sysconfig_sshd/rule.yml b/linux_os/guide/system/permissions/files/file_groupowner_etc_sysconfig_sshd/rule.yml index 6a57207cc9b5..09a5d5beac04 100644 --- a/linux_os/guide/system/permissions/files/file_groupowner_etc_sysconfig_sshd/rule.yml +++ b/linux_os/guide/system/permissions/files/file_groupowner_etc_sysconfig_sshd/rule.yml @@ -2,7 +2,7 @@ documentation_complete: true title: 'Verify Group Who Owns /etc/sysconfig/sshd File' -description: '{{{ describe_file_group_owner(file="/etc/sysconfig/sshd", group="root") }}}' +description: '{{{ describe_file_group_owner(file=sshd_sysconfig_file, group="root") }}}' rationale: |- The /etc/sysconfig/sshd file contains configuration options for the SSH daemon. @@ -14,19 +14,19 @@ severity: medium identifiers: cce@rhel8: CCE-89268-7 -ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/sysconfig/sshd", group="root") }}}' +ocil_clause: '{{{ ocil_clause_file_group_owner(file=sshd_sysconfig_file, group="root") }}}' ocil: |- - {{{ ocil_file_group_owner(file="/etc/sysconfig/sshd", group="root") }}} + {{{ ocil_file_group_owner(file=sshd_sysconfig_file, group="root") }}} -fixtext: '{{{ fixtext_file_group_owner(file="/etc/sysconfig/sshd", group="root") }}}' +fixtext: '{{{ fixtext_file_group_owner(file=sshd_sysconfig_file, group="root") }}}' -srg_requirement: '{{{ srg_requirement_file_group_owner(file="/etc/sysconfig/sshd", group="root") }}}' +srg_requirement: '{{{ srg_requirement_file_group_owner(file=sshd_sysconfig_file, group="root") }}}' template: name: file_groupowner vars: - filepath: /etc/sysconfig/sshd + filepath: '{{{ sshd_sysconfig_file }}}' gid_or_name: '0' platform: system_with_kernel diff --git a/linux_os/guide/system/permissions/files/file_groupowner_systemmap/rule.yml b/linux_os/guide/system/permissions/files/file_groupowner_systemmap/rule.yml index b15ee9a13dd1..c168d31a5c39 100644 --- a/linux_os/guide/system/permissions/files/file_groupowner_systemmap/rule.yml +++ b/linux_os/guide/system/permissions/files/file_groupowner_systemmap/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel8: CCE-86583-2 cce@rhel9: CCE-86584-0 cce@rhel10: CCE-90164-5 + cce@sle16: CCE-95738-1 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/boot/System.map*", group="root") }}}' diff --git a/linux_os/guide/system/permissions/files/file_owner_etc_crypttab/rule.yml b/linux_os/guide/system/permissions/files/file_owner_etc_crypttab/rule.yml index 7e4dc62c9a3c..750234e46588 100644 --- a/linux_os/guide/system/permissions/files/file_owner_etc_crypttab/rule.yml +++ b/linux_os/guide/system/permissions/files/file_owner_etc_crypttab/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel8: CCE-86365-4 cce@rhel9: CCE-86366-2 cce@rhel10: CCE-89519-3 + cce@sle16: CCE-96640-8 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/crypttab", owner="root") }}}' diff --git a/linux_os/guide/system/permissions/files/file_owner_etc_sysconfig_sshd/rule.yml b/linux_os/guide/system/permissions/files/file_owner_etc_sysconfig_sshd/rule.yml index 64785d24ce67..758f6cc3dc7e 100644 --- a/linux_os/guide/system/permissions/files/file_owner_etc_sysconfig_sshd/rule.yml +++ b/linux_os/guide/system/permissions/files/file_owner_etc_sysconfig_sshd/rule.yml @@ -2,7 +2,7 @@ documentation_complete: true title: 'Verify User Who Owns /etc/sysconfig/sshd File' -description: '{{{ describe_file_owner(file="/etc/sysconfig/sshd", owner="root") }}}' +description: '{{{ describe_file_owner(file=sshd_sysconfig_file, owner="root") }}}' rationale: |- The /etc/sysconfig/sshd file contains configuration options for the SSH daemon. @@ -14,19 +14,19 @@ severity: medium identifiers: cce@rhel8: CCE-89269-5 -ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/sysconfig/sshd", owner="root") }}}' +ocil_clause: '{{{ ocil_clause_file_owner(file=sshd_sysconfig_file, owner="root") }}}' ocil: |- - {{{ ocil_file_owner(file="/etc/sysconfig/sshd", owner="root") }}} + {{{ ocil_file_owner(file=sshd_sysconfig_file, owner="root") }}} -fixtext: '{{{ fixtext_file_owner(file="/etc/sysconfig/sshd", owner="root") }}}' +fixtext: '{{{ fixtext_file_owner(file=sshd_sysconfig_file, owner="root") }}}' -srg_requirement: '{{{ srg_requirement_file_owner(file="/etc/sysconfig/sshd", owner="root") }}}' +srg_requirement: '{{{ srg_requirement_file_owner(file=sshd_sysconfig_file, owner="root") }}}' template: name: file_owner vars: - filepath: /etc/sysconfig/sshd + filepath: '{{{ sshd_sysconfig_file }}}' uid_or_name: '0' platform: system_with_kernel diff --git a/linux_os/guide/system/permissions/files/file_owner_systemmap/rule.yml b/linux_os/guide/system/permissions/files/file_owner_systemmap/rule.yml index d10ec7e1ebd4..6a5a019b1605 100644 --- a/linux_os/guide/system/permissions/files/file_owner_systemmap/rule.yml +++ b/linux_os/guide/system/permissions/files/file_owner_systemmap/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel8: CCE-86586-5 cce@rhel9: CCE-86587-3 cce@rhel10: CCE-89808-0 + cce@sle16: CCE-96671-3 ocil_clause: '{{{ ocil_clause_file_owner(file="/boot/System.map*", owner="root") }}}' diff --git a/linux_os/guide/system/permissions/files/file_permissions_etc_crypttab/rule.yml b/linux_os/guide/system/permissions/files/file_permissions_etc_crypttab/rule.yml index f3a6e8920bca..d9af9dca12e1 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_etc_crypttab/rule.yml +++ b/linux_os/guide/system/permissions/files/file_permissions_etc_crypttab/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel8: CCE-86369-6 cce@rhel9: CCE-86370-4 cce@rhel10: CCE-88726-5 + cce@sle16: CCE-95862-9 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/crypttab", perms="0600") }}}' diff --git a/linux_os/guide/system/permissions/files/file_permissions_etc_sysconfig_sshd/rule.yml b/linux_os/guide/system/permissions/files/file_permissions_etc_sysconfig_sshd/rule.yml index 156efad15e09..fab349e834b8 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_etc_sysconfig_sshd/rule.yml +++ b/linux_os/guide/system/permissions/files/file_permissions_etc_sysconfig_sshd/rule.yml @@ -3,7 +3,7 @@ documentation_complete: true title: 'Verify Permissions on /etc/sysconfig/sshd File' description: |- - {{{ describe_file_permissions(file="/etc/sysconfig/sshd", perms="0640") }}} + {{{ describe_file_permissions(file=sshd_sysconfig_file, perms="0640") }}} rationale: |- The /etc/sysconfig/sshd file contains configuration options for the SSH daemon. @@ -15,19 +15,19 @@ severity: medium identifiers: cce@rhel8: CCE-89270-3 -ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/sysconfig/sshd", perms="-rw-r-----") }}}' +ocil_clause: '{{{ ocil_clause_file_permissions(file=sshd_sysconfig_file, perms="-rw-r-----") }}}' ocil: |- - {{{ ocil_file_permissions(file="/etc/sysconfig/sshd", perms="-rw-r-----") }}} + {{{ ocil_file_permissions(file=sshd_sysconfig_file, perms="-rw-r-----") }}} -fixtext: '{{{ fixtext_file_permissions(file="/etc/sysconfig/sshd", mode="0640") }}}' +fixtext: '{{{ fixtext_file_permissions(file=sshd_sysconfig_file, mode="0640") }}}' -srg_requirement: '{{{ srg_requirement_file_permission(file="/etc/sysconfig/sshd", mode="0640") }}}' +srg_requirement: '{{{ srg_requirement_file_permission(file=sshd_sysconfig_file, mode="0640") }}}' template: name: file_permissions vars: - filepath: /etc/sysconfig/sshd + filepath: '{{{ sshd_sysconfig_file }}}' filemode: '0640' allow_stricter_permissions: "true" diff --git a/linux_os/guide/system/permissions/files/file_permissions_systemmap/rule.yml b/linux_os/guide/system/permissions/files/file_permissions_systemmap/rule.yml index 9190b28c74e7..e64a82b43400 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_systemmap/rule.yml +++ b/linux_os/guide/system/permissions/files/file_permissions_systemmap/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel8: CCE-82892-1 cce@rhel9: CCE-86581-6 cce@rhel10: CCE-86786-1 + cce@sle16: CCE-96220-9 ocil_clause: '{{{ ocil_clause_file_permissions(file="/boot/System.map*", perms="-rw-------") }}}' diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/oval/shared.xml b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/oval/shared.xml index cbf3ae449866..9a4aba52ec11 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/oval/shared.xml @@ -31,7 +31,7 @@ recurse_file_system="defined"/> - ^.*$ + / state_file_permissions_unauthorized_sgid_set state_file_permissions_unauthorized_sgid_sysroot diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/rule.yml b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/rule.yml index ae63ad59d9e2..fb19523d62d2 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/rule.yml +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/rule.yml @@ -26,6 +26,7 @@ identifiers: cce@rhel10: CCE-90184-3 cce@sle12: CCE-91472-1 cce@sle15: CCE-91175-0 + cce@sle16: CCE-95910-6 references: cis-csc: 12,13,14,15,16,18,3,5 diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/tests/no_unpackaged_sgid_nonutf.pass.sh b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/tests/no_unpackaged_sgid_nonutf.pass.sh new file mode 100644 index 000000000000..661972c8940c --- /dev/null +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_sgid/tests/no_unpackaged_sgid_nonutf.pass.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +for x in $(find / -perm /g=s) ; do + if ! rpm -qf $x ; then + rm -rf $x + fi +done +touch /usr/bin/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/oval/shared.xml b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/oval/shared.xml index a47fe95478f0..351ef2473566 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/oval/shared.xml @@ -31,7 +31,7 @@ recurse_file_system="defined"/> - ^.*$ + / state_file_permissions_unauthorized_suid_set state_file_permissions_unauthorized_suid_sysroot diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/rule.yml b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/rule.yml index 9ccab80ce39b..341e375c781e 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/rule.yml +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/rule.yml @@ -26,6 +26,7 @@ identifiers: cce@rhel10: CCE-86999-0 cce@sle12: CCE-91473-9 cce@sle15: CCE-91174-3 + cce@sle16: CCE-96423-9 references: cis-csc: 12,13,14,15,16,18,3,5 diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/tests/no_unpackaged_suid_nonutf.pass.sh b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/tests/no_unpackaged_suid_nonutf.pass.sh new file mode 100644 index 000000000000..682a94e66997 --- /dev/null +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_suid/tests/no_unpackaged_suid_nonutf.pass.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +for x in $(find / -perm /u=s) ; do + if ! rpm -qf $x ; then + rm -rf $x + fi +done +touch /usr/bin/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/oval/shared.xml b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/oval/shared.xml index 6cafc77f0a18..2fce2e07bd82 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/oval/shared.xml @@ -38,7 +38,7 @@ recurse_file_system="defined"/> - ^.*$ + / state_file_permissions_unauthorized_world_write state_file_permissions_unauthorized_world_write_special_selinux_files state_file_permissions_unauthorized_world_write_sysroot diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/tests/no_world_writable_nonutf.pass.sh b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/tests/no_world_writable_nonutf.pass.sh new file mode 100644 index 000000000000..48f3dc3f9a7c --- /dev/null +++ b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/tests/no_world_writable_nonutf.pass.sh @@ -0,0 +1,5 @@ +#!/bin/bash +# + +find / -xdev -type f -perm -002 -exec chmod o-w {} \; +touch /etc/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/tests/world_writable_tmp.fail.sh b/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/tests/world_writable_tmp.fail.sh deleted file mode 100644 index c6b866ea6d4b..000000000000 --- a/linux_os/guide/system/permissions/files/file_permissions_unauthorized_world_writable/tests/world_writable_tmp.fail.sh +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/bash -# platform = multi_platform_rhel,multi_platform_ubuntu - -find / -xdev -type f -perm -002 -exec chmod o-w {} \; - -mount tmpfs /tmp -t tmpfs - -touch /tmp/test -chmod o+w /tmp/test diff --git a/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/oval/shared.xml b/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/oval/shared.xml index 4dfbb49104d0..5c608e8c43cb 100644 --- a/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/oval/shared.xml @@ -85,7 +85,7 @@ recurse_file_system="defined" max_depth="-1"/> - .* + / state_file_permissions_ungroupowned_local_group_owner state_file_permissions_ungroupowned_sysroot @@ -96,7 +96,7 @@ recurse_file_system="defined" max_depth="-1"/> - .* + / state_file_permissions_ungroupowned_local_group_owner_with_usrlib state_file_permissions_ungroupowned_sysroot diff --git a/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/tests/all_owned_nonutf.pass.sh b/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/tests/all_owned_nonutf.pass.sh new file mode 100644 index 000000000000..1748aa3f08ea --- /dev/null +++ b/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/tests/all_owned_nonutf.pass.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +UNOWNED_FILES=$(df --local -P | awk {'if (NR!=1) print $6'} | xargs -I '{}' find '{}' -xdev -nogroup) + +IFS=$"\n" +for f in $UNOWNED_FILES; do + rm -f "$f" +done +touch /etc/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/tests/unowned_file_tmp.fail.sh b/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/tests/unowned_file_tmp.fail.sh deleted file mode 100644 index 44f6c84dd6f9..000000000000 --- a/linux_os/guide/system/permissions/files/file_permissions_ungroupowned/tests/unowned_file_tmp.fail.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash -# platform = multi_platform_rhel,multi_platform_ubuntu -# remediation = none - -mount tmpfs /tmp -t tmpfs - -touch /tmp/test -chown 9999:9999 /tmp/test diff --git a/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/oval/shared.xml b/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/oval/shared.xml index 428124a514e5..cc1f85ed2495 100644 --- a/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/oval/shared.xml @@ -90,7 +90,7 @@ recurse_file_system="defined" max_depth="-1"/> - .* + / state_{{{ rule_id }}}_local_group_owner state_{{{ rule_id }}}_sysroot diff --git a/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/tests/all_owned_nonutf.pass.sh b/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/tests/all_owned_nonutf.pass.sh new file mode 100644 index 000000000000..1748aa3f08ea --- /dev/null +++ b/linux_os/guide/system/permissions/files/no_files_or_dirs_ungroupowned/tests/all_owned_nonutf.pass.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +UNOWNED_FILES=$(df --local -P | awk {'if (NR!=1) print $6'} | xargs -I '{}' find '{}' -xdev -nogroup) + +IFS=$"\n" +for f in $UNOWNED_FILES; do + rm -f "$f" +done +touch /etc/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/no_files_or_dirs_unowned_by_user/oval/shared.xml b/linux_os/guide/system/permissions/files/no_files_or_dirs_unowned_by_user/oval/shared.xml index cb9bbe058004..0d8cb3358164 100644 --- a/linux_os/guide/system/permissions/files/no_files_or_dirs_unowned_by_user/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/no_files_or_dirs_unowned_by_user/oval/shared.xml @@ -44,7 +44,7 @@ recurse_file_system="defined" max_depth="-1"/> - .* + / state_{{{ rule_id }}}_uids_list - .* + / state_no_files_unowned_by_user_uids_list diff --git a/linux_os/guide/system/permissions/files/no_files_unowned_by_user/tests/all_owned_nonutf.pass.sh b/linux_os/guide/system/permissions/files/no_files_unowned_by_user/tests/all_owned_nonutf.pass.sh new file mode 100644 index 000000000000..a056c9b2563d --- /dev/null +++ b/linux_os/guide/system/permissions/files/no_files_unowned_by_user/tests/all_owned_nonutf.pass.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +UNOWNED_FILES=$(df --local -P | awk {'if (NR!=1) print $6'} | xargs -I '{}' find '{}' -xdev -nouser) + +IFS=$"\n" +for f in $UNOWNED_FILES; do + rm -f "$f" +done +touch /etc/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/no_files_unowned_by_user/tests/unowned_file_tmp.fail.sh b/linux_os/guide/system/permissions/files/no_files_unowned_by_user/tests/unowned_file_tmp.fail.sh deleted file mode 100644 index c1b6d3e79fc8..000000000000 --- a/linux_os/guide/system/permissions/files/no_files_unowned_by_user/tests/unowned_file_tmp.fail.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash -# platform = multi_platform_fedora,multi_platform_rhel,multi_platform_ubuntu -# remediation = none - -mount tmpfs /tmp -t tmpfs - -touch /tmp/test -chown 9999:9999 /tmp/test diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_etc_security_opasswd/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_etc_security_opasswd/rule.yml index c8ed026ba833..cd283f84e39f 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_etc_security_opasswd/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_etc_security_opasswd/rule.yml @@ -32,3 +32,5 @@ ocil: |- {{{ ocil_file_owner(file="/etc/security/opasswd", owner="root") }}} {{{ ocil_file_group_owner(file="/etc/security/opasswd", group="root") }}} {{{ ocil_file_permissions(file="/etc/security/opasswd", perms="0600") }}} + +platform: package[pam] diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_group/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_group/rule.yml index 576426248976..8b0b96166dcb 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_group/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_group/rule.yml @@ -11,6 +11,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-89605-0 cce@rhel8: CCE-80796-6 cce@rhel9: CCE-83945-6 cce@rhel10: CCE-90261-9 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_gshadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_gshadow/rule.yml index 46e60ad632b0..e255408380c1 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_gshadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_gshadow/rule.yml @@ -17,11 +17,13 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-87871-0 cce@rhel8: CCE-80797-4 cce@rhel9: CCE-83948-0 cce@rhel10: CCE-90043-1 cce@sle12: CCE-92225-2 cce@sle15: CCE-91348-3 + cce@sle16: CCE-95841-3 cce@slmicro5: CCE-93967-8 references: diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_passwd/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_passwd/rule.yml index 726bad1e134e..22018e5efd5a 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_passwd/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_passwd/rule.yml @@ -11,6 +11,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88189-6 cce@rhel8: CCE-80798-2 cce@rhel9: CCE-83950-6 cce@rhel10: CCE-89210-9 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shadow/rule.yml index 5fd150ca6ada..09594a183b65 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shadow/rule.yml @@ -17,6 +17,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-87133-5 cce@rhel8: CCE-80799-0 cce@rhel9: CCE-83930-8 cce@rhel10: CCE-87579-9 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shells/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shells/rule.yml index f518cb5cd15d..114ab8dd6b32 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shells/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_groupowner_etc_shells/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-90434-2 cce@rhel10: CCE-90020-9 cce@sle15: CCE-92541-2 + cce@sle16: CCE-96404-9 references: nist: AC-3,MP-2 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_group/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_group/rule.yml index d40e5d54fabd..61c47e8130cb 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_group/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_group/rule.yml @@ -11,6 +11,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-87800-9 cce@rhel8: CCE-80801-4 cce@rhel9: CCE-83925-8 cce@rhel10: CCE-86870-3 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_gshadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_gshadow/rule.yml index f49d8842b722..c0602df9064f 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_gshadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_gshadow/rule.yml @@ -11,11 +11,13 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-88141-7 cce@rhel8: CCE-80802-2 cce@rhel9: CCE-83924-1 cce@rhel10: CCE-87701-9 cce@sle12: CCE-91557-9 cce@sle15: CCE-91230-3 + cce@sle16: CCE-96275-3 cce@slmicro5: CCE-93959-5 references: diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_passwd/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_passwd/rule.yml index 1e52a940b0f2..05e8b58ff8b6 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_passwd/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_passwd/rule.yml @@ -11,6 +11,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-89312-3 cce@rhel8: CCE-80803-0 cce@rhel9: CCE-83943-1 cce@rhel10: CCE-87827-2 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shadow/rule.yml index ed765a69fc4a..2786050a937d 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shadow/rule.yml @@ -14,6 +14,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-89484-0 cce@rhel8: CCE-80804-8 cce@rhel9: CCE-83926-6 cce@rhel10: CCE-86857-0 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shells/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shells/rule.yml index 0d0c52baae12..89abfb9b8709 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shells/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_owner_etc_shells/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-90435-9 cce@rhel10: CCE-89594-6 cce@sle15: CCE-92547-9 + cce@sle16: CCE-96138-3 references: nist: AC-3,MP-2 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_backup_etc_shadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_backup_etc_shadow/rule.yml index c2080fde3fcd..b3e300599f20 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_backup_etc_shadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_backup_etc_shadow/rule.yml @@ -57,3 +57,4 @@ template: filemode@ubuntu2404: '0640' filemode@sle12: '0640' filemode@sle15: '0640' + filemode@sle16: '0640' diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_group/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_group/rule.yml index 96a2cfc1c1f2..4a98065f41a6 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_group/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_group/rule.yml @@ -12,6 +12,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-90126-4 cce@rhel8: CCE-80810-5 cce@rhel9: CCE-83934-0 cce@rhel10: CCE-88868-5 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_gshadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_gshadow/rule.yml index 49b4c7967b2c..ba2d383c9416 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_gshadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_gshadow/rule.yml @@ -20,11 +20,13 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-86641-8 cce@rhel8: CCE-80811-3 cce@rhel9: CCE-83921-7 cce@rhel10: CCE-86975-0 cce@sle12: CCE-91558-7 cce@sle15: CCE-91231-1 + cce@sle16: CCE-96193-8 cce@slmicro5: CCE-93951-2 references: diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_passwd/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_passwd/rule.yml index d42c430c4c3b..0ab89f80a8c2 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_passwd/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_passwd/rule.yml @@ -14,6 +14,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-87939-5 cce@rhel8: CCE-80812-1 cce@rhel9: CCE-83931-6 cce@rhel10: CCE-90644-6 diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shadow/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shadow/rule.yml index e52241f482f1..4dc4175e98e1 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shadow/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shadow/rule.yml @@ -23,6 +23,7 @@ rationale: |- severity: medium identifiers: + cce@rhcos4: CCE-89361-0 cce@rhel8: CCE-80813-9 cce@rhel9: CCE-83941-5 cce@rhel10: CCE-88433-8 @@ -69,5 +70,6 @@ template: filemode@debian13: '0640' filemode@sle12: '0640' filemode@sle15: '0640' + filemode@sle16: '0640' filemode@ubuntu2204: '0640' filemode@ubuntu2404: '0640' diff --git a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shells/rule.yml b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shells/rule.yml index 83701e95cc30..de73d8f1a6ca 100644 --- a/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shells/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_important_account_files/file_permissions_etc_shells/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-90432-6 cce@rhel10: CCE-89912-0 cce@sle15: CCE-92562-8 + cce@sle16: CCE-96599-6 references: nist: AC-3,MP-2 diff --git a/linux_os/guide/system/permissions/files/permissions_local_var_log/rule.yml b/linux_os/guide/system/permissions/files/permissions_local_var_log/rule.yml index af819ea482cb..1be0bd45ad28 100644 --- a/linux_os/guide/system/permissions/files/permissions_local_var_log/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_local_var_log/rule.yml @@ -63,6 +63,7 @@ template: filepath: /var/log/ recursive@sle12: 'true' recursive@sle15: 'true' + recursive@sle16: 'true' recursive@slmicro5: 'true' recursive@slmicro6: 'true' recursive@ubuntu2204: 'true' diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/bash/shared.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/bash/shared.sh index 6579223bec38..db9e7825fbab 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/bash/shared.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/bash/shared.sh @@ -7,6 +7,18 @@ # see https://workbench.cisecurity.org/benchmarks/18959/tickets/23964 # regarding sssd and gdm exclusions +declare -A valid_shells +while read -r line; do + [[ "$line" == /* ]] && valid_shells["$line"]=1 +done < /etc/shells + +declare -A users_with_valid_shells +while IFS=: read -r user _ _ _ _ _ shell; do + if [[ ${valid_shells["$shell"]} == 1 ]]; then + users_with_valid_shells["$user"]=1 + fi +done < /etc/passwd + find -P /var/log/ -type f -regextype posix-extended \ ! -group root ! -group adm \ ! -name 'gdm' ! -name 'gdm3' \ @@ -26,4 +38,11 @@ find -P /var/log/ -type f -regextype posix-extended \ ! -regex '.*/localmessages(.*)' \ ! -regex '.*/secure(.*)' \ ! -regex '.*/waagent.log(.*)' \ - -regex '.*' -exec chgrp --no-dereference root {} \; + -print0 | while IFS= read -r -d '' log_file + do + # Set to root if owned by a user with a valid shell + user=$(stat -c "%U" "$log_file") + if [[ "${users_with_valid_shells["$user"]}" == "1" ]]; then + chgrp --no-dereference root "$log_file" + fi + done diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/oval/shared.xml b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/oval/shared.xml index bb1b411ae7fe..02f7f4ce5fdb 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/oval/shared.xml @@ -21,8 +21,8 @@ - {{%- if product == "ubuntu2204" %}} - + {{%- if 'ubuntu' in product %}} + {{%- endif %}}
@@ -96,47 +96,43 @@ ^waagent\.log.*$ - {{%- if product == "ubuntu2204" %}} - - + {{%- if 'ubuntu' in product %}} + + - - - - - - /etc/group - + + + /etc/shells + ^(/.*)$ 1 - - - ^[^:]+:[^:]*:( - - ):$ - + + - - + + /etc/passwd - + ^[^:]+:[^:]+:[0-9]+:([0-9]+):.*$ 1 + {{{ rule_id }}}_state_shell_is_valid - + + + + + - ^[^:]*:[^:]*: - - :(\d+):.*$ + ^.*:( + + )$ - - /etc/passwd - ^[^:]+:[^:]*:(\d\d?\d?):.*$ - 1 - + + + {{%- endif %}} diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/excluded_files.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/excluded_files.pass.sh index 1960379c3e08..7dd2a108ed05 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/excluded_files.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/excluded_files.pass.sh @@ -1,6 +1,5 @@ #!/bin/bash # platform = multi_platform_ubuntu -# packages = rsyslog chgrp root -R /var/log/* diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_adm.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_adm.pass.sh index 4afa612eb706..be307cb3eced 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_adm.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_adm.pass.sh @@ -1,6 +1,5 @@ #!/bin/bash # platform = multi_platform_ubuntu -# packages = rsyslog chgrp root -R /var/log/* diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_nobody.fail.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_nobody.fail.sh deleted file mode 100644 index 207dd03b6cd1..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_nobody.fail.sh +++ /dev/null @@ -1,13 +0,0 @@ -#!/bin/bash -# platform = multi_platform_ubuntu -# packages = rsyslog - -chgrp root -R /var/log/* - -touch /var/log/test.log -chgrp nogroup /var/log/test.log -{{%- if product == 'ubuntu2204' %}} -#make sure nogroup has members -usermod -aG nogroup nobody -chown nobody /var/log/test.log -{{%- endif %}} diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_non_sys_acc_grp.fail.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_non_sys_acc_grp.fail.sh deleted file mode 100644 index 53bcf848e1a5..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_non_sys_acc_grp.fail.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -# platform = multi_platform_ubuntu -# packages = rsyslog - -chown root -R /var/log/* - -groupadd testgroup -useradd testUser -usermod -g testgroup testUser - -touch /var/log/test.log -chgrp testgroup /var/log/test.log diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_root.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_root.pass.sh index a9b0b730fe07..a04a0c38499b 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_root.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_root.pass.sh @@ -1,6 +1,5 @@ #!/bin/bash # platform = multi_platform_ubuntu -# packages = rsyslog chgrp root -R /var/log/* diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_sys_acc_grp.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_sys_acc_grp.pass.sh deleted file mode 100644 index 49afdf1ad47b..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_sys_acc_grp.pass.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -# platform = Ubuntu 22.04 -# packages = rsyslog - -chown root -R /var/log/* - -groupadd testgroup -useradd -r testUser -usermod -g testgroup testUser - -touch /var/log/test.log -chgrp testgroup /var/log/test.log diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_user_with_shell.fail.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_user_with_shell.fail.sh new file mode 100644 index 000000000000..3308000d466e --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_user_with_shell.fail.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# platform = multi_platform_ubuntu + +useradd -m -s /bin/bash test_user_with_shell + +chown root:root -R /var/log/* + +touch /var/log/test_log_file +chgrp test_user_with_shell /var/log/test_log_file diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_user_without_shell.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_user_without_shell.pass.sh new file mode 100644 index 000000000000..d985321e5124 --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_groupownerships_var_log/tests/owned_by_user_without_shell.pass.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# platform = multi_platform_ubuntu + +useradd -m -s /usr/sbin/nologin test_user_no_shell + +chown root:root -R /var/log/* + +touch /var/log/test_log_file +chgrp test_user_no_shell /var/log/test_log_file diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/bash/shared.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/bash/shared.sh index ee4cce9fd671..eafb1e165112 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/bash/shared.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/bash/shared.sh @@ -7,6 +7,18 @@ # see https://workbench.cisecurity.org/benchmarks/18959/tickets/23964 # regarding sssd and gdm exclusions +declare -A valid_shells +while read -r line; do + [[ "$line" == /* ]] && valid_shells["$line"]=1 +done < /etc/shells + +declare -A users_with_valid_shells +while IFS=: read -r user _ _ _ _ _ shell; do + if [[ ${valid_shells["$shell"]} == 1 ]]; then + users_with_valid_shells["$user"]=1 + fi +done < /etc/passwd + find -P /var/log/ -type f -regextype posix-extended \ ! -user root ! -user syslog \ ! -name 'gdm' ! -name 'gdm3' \ @@ -26,4 +38,11 @@ find -P /var/log/ -type f -regextype posix-extended \ ! -regex '.*/localmessages(.*)' \ ! -regex '.*/secure(.*)' \ ! -regex '.*/waagent.log(.*)' \ - -regex '.*' -exec chown --no-dereference root {} \; + -print0 | while IFS= read -r -d '' log_file + do + # Set to root if owned by a user with a valid shell + user=$(stat -c "%U" "$log_file") + if [[ "${users_with_valid_shells["$user"]}" == "1" ]]; then + chown --no-dereference root "$log_file" + fi + done diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/oval/shared.xml b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/oval/shared.xml index 95095bbb8837..b97743b02346 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/oval/shared.xml @@ -20,8 +20,8 @@ - {{%- if product == "ubuntu2204" %}} - + {{%- if 'ubuntu' in product %}} + {{%- endif %}} @@ -108,9 +108,43 @@ ^/var/log/exim4/.*$ {{% endif %}} - {{%- if product == "ubuntu2204" %}} - - {{{ uid_min }}} + + + - {{%- endif %}} + + + + /etc/shells + ^(/.*)$ + 1 + + + + + + + + + /etc/passwd + ^[^:]+:[^:]+:([0-9]+):.*$ + 1 + {{{ rule_id }}}_state_shell_is_valid + + + + + + + + + ^.*:( + + )$ + + + + + + diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_nobody.fail.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_nobody.fail.sh deleted file mode 100644 index 1bd7955a7dc2..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_nobody.fail.sh +++ /dev/null @@ -1,8 +0,0 @@ -#!/bin/bash -# platform = multi_platform_ubuntu -# packages = rsyslog - -chown root -R /var/log/* - -touch /var/log/test.log -chown nobody /var/log/test.log diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_root.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_root.pass.sh index 3405d1f42030..c9ea476a15aa 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_root.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_root.pass.sh @@ -1,6 +1,5 @@ #!/bin/bash # platform = multi_platform_ubuntu -# packages = rsyslog chown root -R /var/log/* diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_sysacc.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_sysacc.pass.sh deleted file mode 100644 index 70bb73134866..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_sysacc.pass.sh +++ /dev/null @@ -1,10 +0,0 @@ -#!/bin/bash -# platform = Ubuntu 22.04 -# packages = rsyslog - -chown root -R /var/log/* - -useradd -r testUser - -touch /var/log/test.log -chown testUser /var/log/test.log diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_syslog.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_syslog.pass.sh index 697ac57b5507..b13a50eff8b1 100644 --- a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_syslog.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_syslog.pass.sh @@ -1,6 +1,7 @@ #!/bin/bash # platform = multi_platform_ubuntu -# packages = rsyslog + +useradd -r syslog || true chown root -R /var/log/* diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_user_with_shell.fail.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_user_with_shell.fail.sh new file mode 100644 index 000000000000..6215bee12392 --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_user_with_shell.fail.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# platform = multi_platform_ubuntu + +useradd -m -s /bin/bash test_user_with_shell + +chown root:root -R /var/log/* + +touch /var/log/test_log_file +chown test_user_with_shell /var/log/test_log_file diff --git a/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_user_without_shell.pass.sh b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_user_without_shell.pass.sh new file mode 100644 index 000000000000..b1e5fae1718f --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_var_log_dir/file_ownerships_var_log/tests/owned_by_user_without_shell.pass.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# platform = multi_platform_ubuntu + +useradd -m -s /usr/sbin/nologin test_user_no_shell + +chown root:root -R /var/log/* + +touch /var/log/test_log_file +chown test_user_no_shell /var/log/test_log_file diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_group_ownership_library_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_group_ownership_library_dirs/rule.yml index 3ce312aace9e..e1780a7da884 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_group_ownership_library_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_group_ownership_library_dirs/rule.yml @@ -12,12 +12,16 @@ description: |- /usr/lib /usr/lib64
+ {{% if product != "hummingbird" %}} Kernel modules, which can be added to the kernel during runtime, are also - stored in /lib/modules. All files in these directories should be - group-owned by the root user. If the directories, is found to be owned - by a user other than root correct its - ownership with the following command: + stored in /lib/modules. + {{% endif %}} + All files in these directories should be group-owned by the root group. + {{% if product != "hummingbird" %}} + If the directories are found to be owned by a group other than root correct + its ownership with the following command:
$ sudo chgrp root DIR
+ {{% endif %}} rationale: |- Files from shared library directories are loaded into the address diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_ownership_library_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_ownership_library_dirs/rule.yml index 611558766535..83037dba7333 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_ownership_library_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_ownership_library_dirs/rule.yml @@ -11,12 +11,16 @@ description: |- /usr/lib /usr/lib64 + {{% if product != "hummingbird" %}} Kernel modules, which can be added to the kernel during runtime, are also - stored in /lib/modules. All files in these directories should be - owned by the root user. If the directories, is found to be owned - by a user other than root correct its - ownership with the following command: + stored in /lib/modules. + {{% endif %}} + All files in these directories should be owned by the root user. + {{% if product != "hummingbird" %}} + If the directories are found to be owned by a user other than root correct + its ownership with the following command:
$ sudo chown root DIR
+ {{% endif %}} rationale: |- Files from shared library directories are loaded into the address diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_permissions_library_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_permissions_library_dirs/rule.yml index 88d4068b3297..2236a9f16be3 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_permissions_library_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/dir_permissions_library_dirs/rule.yml @@ -12,12 +12,16 @@ description: |- /usr/lib /usr/lib64 + {{% if product != "hummingbird" %}} Kernel modules, which can be added to the kernel during runtime, are - stored in /lib/modules. All sub-directories in these directories - should not be group-writable or world-writable. If any file in these - directories is found to be group-writable or world-writable, correct + stored in /lib/modules. + {{% endif %}} + All sub-directories in these directories should not be group-writable or world-writable. + {{% if product != "hummingbird" %}} + If any file in these directories is found to be group-writable or world-writable, correct its permission with the following command:
$ sudo chmod go-w DIR
+ {{% endif %}} rationale: |- If the operating system were to allow any user to make changes to software libraries, diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_groupowner_etc_sysctld/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_groupowner_etc_sysctld/rule.yml index fe9ad0c2cb13..4b7a99b4add2 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_groupowner_etc_sysctld/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_groupowner_etc_sysctld/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86325-8 cce@rhel10: CCE-90122-3 cce@sle15: CCE-92506-5 + cce@sle16: CCE-96187-0 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/sysctl.d", group="root") }}}' diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_owner_etc_sysctld/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_owner_etc_sysctld/rule.yml index 4fcf06a18c77..5bd29766509c 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_owner_etc_sysctld/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_owner_etc_sysctld/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86330-8 cce@rhel10: CCE-87242-4 cce@sle15: CCE-92513-1 + cce@sle16: CCE-96370-2 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/sysctl.d", owner="root") }}}' diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_permissions_etc_sysctld/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_permissions_etc_sysctld/rule.yml index 7f93f2ef4dc1..e00b35cee6b9 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_permissions_etc_sysctld/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/directory_permissions_etc_sysctld/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86337-3 cce@rhel10: CCE-89782-7 cce@sle15: CCE-92527-1 + cce@sle16: CCE-95827-2 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/sysctl.d", perms="0755") }}}' diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/ansible/shared.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/ansible/shared.yml index 429962905c3e..78c03e7011b6 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/ansible/shared.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/ansible/shared.yml @@ -11,7 +11,11 @@ follow: no recurse: no register: system_command_files_found + {{% if 'ol9' in product %}} + with_items: ['/bin', '/sbin', '/usr/bin', '/usr/sbin', '/usr/libexec','/usr/local/bin', '/usr/local/sbin'] + {{% else %}} with_items: ['/bin', '/sbin', '/usr/bin', '/usr/sbin', '/usr/local/bin', '/usr/local/sbin'] + {{% endif %}} changed_when: false - name: "{{{ rule_title }}} - Set group ownership to root for system command files" diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/bash/shared.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/bash/shared.sh index 00a12fdfa865..bc803976ee28 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/bash/shared.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/bash/shared.sh @@ -1,3 +1,6 @@ # platform = multi_platform_fedora,multi_platform_ol,multi_platform_rhel,multi_platform_sle,multi_platform_slmicro,multi_platform_almalinux - +{{% if 'ol9' in product %}} +find -P /bin /sbin /usr/bin /usr/sbin /usr/libexec /usr/local/bin /usr/local/sbin \! -group root -type f -exec chgrp root '{}' \; || true +{{% else %}} find -P /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin \! -group root -type f -exec chgrp root '{}' \; || true +{{% endif %}} diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/oval/shared.xml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/oval/shared.xml index 16936790ef09..cf1868fb0f76 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/oval/shared.xml @@ -17,8 +17,12 @@ + {{% if 'ol9' in product %}} + ^\/s?bin|^\/usr\/s?bin|^\/usr\/libexec|^\/usr\/local\/s?bin + {{% else %}} ^\/s?bin|^\/usr\/s?bin|^\/usr\/local\/s?bin - ^.*$ + {{% endif %}} + / state_groupowner_system_commands_dirs_not_root_or_system_account state_groupowner_system_commands_dirs_symlink diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/rule.yml index 37ae549a7174..950ff7cc9d11 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/rule.yml @@ -9,6 +9,9 @@ description: |- /sbin /usr/bin /usr/sbin + {{%- if 'ol9' in product %}} + /usr/libexec + {{%- endif %}} /usr/local/bin /usr/local/sbin @@ -39,6 +42,7 @@ identifiers: cce@rhel10: CCE-89800-7 cce@sle12: CCE-83243-6 cce@sle15: CCE-85742-5 + cce@sle16: CCE-96446-0 cce@slmicro5: CCE-93701-1 cce@slmicro6: CCE-94699-6 @@ -54,7 +58,11 @@ ocil_clause: 'any system commands are returned and is not group-owned by a requi ocil: |- Verify the system commands contained in the following directories are group-owned by "root", or a required system account, with the following command: + {{%- if 'ol9' in product %}} + $ sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/libexec /usr/local/bin /usr/local/sbin ! -group root -exec ls -l {} \; + {{%- else %}} $ sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -group root -exec ls -l {} \; + {{%- endif %}} fixtext: |- Configure the system commands to be protected from unauthorized access. diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner.pass.sh index 48bd0d2c8f5c..9fe7a63d4783 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner.pass.sh @@ -1,3 +1,7 @@ #!/bin/bash +{{% if 'ol9' in product %}} +find -P /bin /sbin /usr/bin /usr/sbin /usr/libexec /usr/local/bin /usr/local/sbin \! -group root -type f -exec chgrp --no-dereference root '{}' \; || true +{{% else %}} find -P /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin \! -group root -type f -exec chgrp --no-dereference root '{}' \; || true +{{% endif %}} diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner_nonutf.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner_nonutf.pass.sh new file mode 100644 index 000000000000..ab943323d2ff --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/correct_groupowner_nonutf.pass.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +{{% if 'ol9' in product %}} +find -P /bin /sbin /usr/bin /usr/sbin /usr/libexec /usr/local/bin /usr/local/sbin \! -group root -type f -exec chgrp --no-dereference root '{}' \; || true +{{% else %}} +find -P /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin \! -group root -type f -exec chgrp --no-dereference root '{}' \; || true +{{% endif %}} +touch /usr/bin/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/incorrect_groupownership.fail.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/incorrect_groupownership.fail.sh index f65c98a225ab..8013aaed79fa 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/incorrect_groupownership.fail.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/incorrect_groupownership.fail.sh @@ -2,13 +2,21 @@ groupadd group_test +{{% if 'ol9' in product %}} +find -P /bin/ /sbin/ /usr/bin/ /usr/sbin/ /usr/libexec/ /usr/local/bin/ /usr/local/sbin/ -type f -exec chgrp --no-dereference root {} \; || true +{{% else %}} find -P /bin/ /sbin/ /usr/bin/ /usr/sbin/ /usr/local/bin/ /usr/local/sbin/ -type f -exec chgrp --no-dereference root {} \; || true +{{% endif %}} {{% if 'ubuntu' in product %}} for TESTFILE in /bin/test_me /sbin/test_me /usr/bin/test_me /usr/sbin/test_me /usr/local/bin/test_me /usr/local/sbin/test_me {{% else %}} +{{% if 'ol9' in product %}} +for TESTFILE in /bin/test_me /sbin/test_me /usr/bin/test_me /usr/libexec/test_me /usr/sbin/test_me /usr/local/bin/test_me +{{% else %}} for TESTFILE in /bin/test_me /sbin/test_me /usr/bin/test_me /usr/sbin/test_me /usr/local/bin/test_me {{% endif %}} +{{% endif %}} do if [[ ! -f $TESTFILE ]] then diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/symlink.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/symlink.pass.sh index 6c9035268936..e27ef5963fc9 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/symlink.pass.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_groupownership_system_commands_dirs/tests/symlink.pass.sh @@ -2,7 +2,11 @@ groupadd group_test +{{% if 'ol9' in product %}} +find -P /bin/ /sbin/ /usr/bin/ /usr/sbin/ /usr/libexec /usr/local/bin/ /usr/local/sbin/ \! -group root -type f -exec chgrp --no-dereference root {} \; || true +{{% else %}} find -P /bin/ /sbin/ /usr/bin/ /usr/sbin/ /usr/local/bin/ /usr/local/sbin/ \! -group root -type f -exec chgrp --no-dereference root {} \; || true +{{% endif %}} ln -s $(mktemp -p /tmp) /usr/bin/test.log.symlink chgrp -h group_test /usr/bin/test.log.symlink diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/oval/shared.xml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/oval/shared.xml index fcc6d03e7e2e..e807a873b544 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/oval/shared.xml @@ -42,7 +42,7 @@ /usr/local/sbin, and /usr/libexec directories belong to user with uid 0 (root) --> ^\/(|s)bin|^\/usr\/(|local\/)(|s)bin|^\/usr\/libexec {{% endif %}} - ^.*$ + / {{% if 'ubuntu' in product %}} state_owner_binaries_not_system_accounts {{% else %}} diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/rule.yml index 1b91da3b6535..fade0c0a085e 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/rule.yml @@ -30,6 +30,7 @@ identifiers: cce@rhel10: CCE-89620-9 cce@sle12: CCE-83241-0 cce@sle15: CCE-85730-0 + cce@sle16: CCE-96514-5 cce@slmicro5: CCE-93699-7 cce@slmicro6: CCE-94697-0 diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/tests/right_owner_nonutf.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/tests/right_owner_nonutf.pass.sh new file mode 100644 index 000000000000..1749f1e8380f --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_binary_dirs/tests/right_owner_nonutf.pass.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +{{% if 'ubuntu' in product %}} +find /bin/ /usr/bin/ /usr/local/bin/ /sbin/ /usr/sbin/ /usr/local/sbin/ \! -uid -{{{ uid_min }}} -execdir chown root {} \; +{{% else %}} +find /bin/ /usr/bin/ /usr/local/bin/ /sbin/ /usr/sbin/ /usr/local/sbin/ /usr/libexec \! -user root -execdir chown root {} \; +{{% endif %}} +touch /usr/bin/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/rule.yml index f894eacfd990..609309761ae5 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/rule.yml @@ -11,12 +11,16 @@ description: |- /usr/lib /usr/lib64 + {{% if product != "hummingbird" %}} Kernel modules, which can be added to the kernel during runtime, are also - stored in /lib/modules. All files in these directories should be - owned by the root user. If the directory, or any file in these - directories, is found to be owned by a user other than root correct its - ownership with the following command: + stored in /lib/modules. + {{% endif %}} + All files in these directories should be owned by the root user. + {{% if product != "hummingbird" %}} + If the directory, or any file in these directories, is found to be owned + by a user other than root correct its ownership with the following command:
$ sudo chown root FILE
+ {{% endif %}} rationale: |- Files from shared library directories are loaded into the address @@ -64,7 +68,7 @@ template: - /usr/lib/ - /usr/lib64/ recursive: 'true' -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} file_regex: ^.*\.so.*$ {{% else %}} file_regex: ^.*$ @@ -74,9 +78,15 @@ template: fixtext: |- Configure the system-wide shared library files (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. +{{%- if 'ubuntu' in product %}} + Run the following command: + +
$ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' ! -user root -exec chown root {} +
+{{%- else %}} Run the following command, replacing "[FILE]" with any library file not owned by "root". $ sudo chown root [FILE] +{{%- endif %}} srg_requirement: {{{ full_name }}} library files must be owned by root. diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner.fail.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner.fail.sh index 07b5f77cc290..c552b5eacd68 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner.fail.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner.fail.sh @@ -2,7 +2,7 @@ # platform = multi_platform_fedora,multi_platform_ol,multi_platform_rhel,multi_platform_sle,multi_platform_ubuntu,multi_platform_almalinux useradd user_test -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} for TESTFILE in /lib/test_me.so /lib64/test_me.so /usr/lib/test_me.so /usr/lib64/test_me.so {{% else %}} for TESTFILE in /lib/test_me /lib64/test_me /usr/lib/test_me /usr/lib64/test_me diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner_within_dir.fail.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner_within_dir.fail.sh index 8dededef2316..a8e577464bfc 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner_within_dir.fail.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_ownership_library_dirs/tests/incorrect_owner_within_dir.fail.sh @@ -6,7 +6,7 @@ useradd user_test TESTDIR="/usr/lib/dir/" mkdir -p "${TESTDIR}" -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} touch "${TESTDIR}"/test_me.so chown user_test "${TESTDIR}"/test_me.so {{% else %}} diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/oval/shared.xml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/oval/shared.xml index 79df61aa5967..ba8b85583f19 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/oval/shared.xml @@ -17,7 +17,7 @@ ^\/(|s)bin|^\/usr\/(|local\/)(|s)bin|^\/usr\/libexec - ^.*$ + / state_perms_binary_files_nogroupwrite_noworldwrite state_perms_binary_files_symlink diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/rule.yml index 4ddad0a17e22..5cd917fc6c08 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/rule.yml @@ -30,6 +30,7 @@ identifiers: cce@rhel10: CCE-86978-4 cce@sle12: CCE-83240-2 cce@sle15: CCE-85729-2 + cce@sle16: CCE-95994-0 cce@slmicro5: CCE-93698-9 cce@slmicro6: CCE-94696-2 diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/tests/correct_permissions_nonutf.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/tests/correct_permissions_nonutf.pass.sh new file mode 100644 index 000000000000..9caf66aa98de --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_binary_dirs/tests/correct_permissions_nonutf.pass.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +DIRS="/bin /usr/bin /usr/local/bin /sbin /usr/sbin /usr/local/sbin /usr/libexec" +for dirPath in $DIRS; do + find "$dirPath" -perm /022 -type f -exec chmod 0755 '{}' \; +done +touch /usr/bin/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/rule.yml index 840e8ab35a16..3361cf819a9f 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/rule.yml @@ -11,12 +11,16 @@ description: |- /usr/lib /usr/lib64 + {{% if product != "hummingbird" %}} Kernel modules, which can be added to the kernel during runtime, are - stored in /lib/modules. All files in these directories - should not be group-writable or world-writable. If any file in these - directories is found to be group-writable or world-writable, correct - its permission with the following command: + stored in /lib/modules. + {{% endif %}} + All files in these directories should not be group-writable or world-writable. + {{% if product != "hummingbird" %}} + If any file in these directories is found to be group-writable + or world-writable, correct its permission with the following command:
$ sudo chmod go-w FILE
+ {{% endif %}} rationale: |- Files from shared library directories are loaded into the address @@ -64,7 +68,7 @@ template: - /usr/lib/ - /usr/lib64/ recursive: 'true' -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} file_regex: ^.*\.so.*$ {{% else %}} file_regex: ^.*$ @@ -72,9 +76,15 @@ template: filemode: '7755' fixtext: |- +{{%- if 'ubuntu' in product %}} + Configure the systemwide shared library files contained in the directories "/lib", "/lib64", "/usr/lib", and "/usr/lib64" to have mode 0755 or less permissive with the following command: + +
$ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' -perm /022 -exec chmod go-w {} +
+{{%- else %}} Configure the library files to be protected from unauthorized access. Run the following command, replacing "[FILE]" with any library file with a mode more permissive than 755. $ sudo chmod 755 [FILE] +{{%- endif %}} srg_requirement: {{{ full_name }}} library directories must have mode 755 or less permissive. diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/tests/lenient_permissions.fail.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/tests/lenient_permissions.fail.sh index f95ab977d6ec..d992d957b68f 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/tests/lenient_permissions.fail.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_library_dirs/tests/lenient_permissions.fail.sh @@ -4,7 +4,7 @@ DIRS="/lib /lib64 /usr/lib /usr/lib64" for dirPath in $DIRS; do # Limit the test changes to a subset of file in the directory # Remediation the whole library dirs is very time consuming -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} find "$dirPath" -type f -regex ".*\.so" -exec chmod go+w '{}' \; {{% else %}} find "$dirPath" -type f -regex ".*\.txt" -exec chmod go+w '{}' \; diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/oval/shared.xml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/oval/shared.xml index bad75171e727..088982ba1080 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/oval/shared.xml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/oval/shared.xml @@ -17,7 +17,7 @@ ^\/(s|)bin|^\/usr\/(s|)bin|^\/usr\/local\/(s|)bin - ^.*$ + / state_perms_system_commands_files_nogroupwrite_noworldwrite state_perms_system_commands_files_symlink diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/tests/correct_permissions_nonutf.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/tests/correct_permissions_nonutf.pass.sh new file mode 100644 index 000000000000..ee294f623b43 --- /dev/null +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/file_permissions_system_commands_dirs/tests/correct_permissions_nonutf.pass.sh @@ -0,0 +1,8 @@ +#!/bin/bash + +for SYSLIBDIRS in /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin +do + find -L $SYSLIBDIRS -perm /022 -type f -exec chmod go-w '{}' \; +done + +touch /usr/bin/$(printf "evil_filename_\334_non_utf8_character") diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/bash/ubuntu.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/bash/ubuntu.sh deleted file mode 100644 index 3f6a097a88d0..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/bash/ubuntu.sh +++ /dev/null @@ -1,2 +0,0 @@ -# platform = multi_platform_ubuntu -find /lib/ /lib64/ /usr/lib/ /usr/lib64/ \! -gid -{{{ gid_min }}} -type f -exec chgrp --no-dereference root '{}' \; diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/oval/ubuntu.xml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/oval/ubuntu.xml deleted file mode 100644 index 37f6972f78d3..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/oval/ubuntu.xml +++ /dev/null @@ -1,29 +0,0 @@ - - - {{{ oval_metadata("Verify the system-wide library files in directories /lib, /lib64, /usr/lib/ and /usr/lib64 are group-owned by root.", rule_title=rule_title) }}} - - - - - - - - - - - - ^/(|usr/)lib(|64)$ - ^.*$ - state_groupowner_binaries_not_system_accounts - state_groupowner_root_path_dirs_symlink - - - - symbolic link - - - - {{{ gid_min }}} - - - diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/rule.yml b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/rule.yml index 6ecf076cd2f5..91ea1c5933f6 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/rule.yml +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/rule.yml @@ -1,12 +1,8 @@ documentation_complete: true -{{% if 'ubuntu' in product -%}} -{{% set gid_description = ' or a required system account' -%}} -{{% endif -%}} - title: |- Verify the system-wide library files in directories - "/lib", "/lib64", "/usr/lib/" and "/usr/lib64" are group-owned by root{{{ gid_description }}}. + "/lib", "/lib64", "/usr/lib/" and "/usr/lib64" are group-owned by root. description: |- System-wide library files are stored in the following directories @@ -17,7 +13,7 @@ description: |- /usr/lib64 All system-wide shared library files should be protected from unauthorised - access. If any of these files is not group-owned by root{{{ gid_description }}}, + access. If any of these files is not group-owned by root, correct its group-owner with the following command:
$ sudo chgrp root FILE
@@ -50,14 +46,13 @@ references: stigid@sle12: SLES-12-010875 stigid@sle15: SLES-15-010355 -ocil_clause: any system wide shared library file is returned and is not group-owned by root{{{ gid_description }}} +ocil_clause: any system wide shared library file is returned and is not group-owned by root ocil: |- - Verify the system-wide shared library files are group-owned by root{{{ gid_description }}} with the following command: + Verify the system-wide shared library files are group-owned by root with the following command: $ sudo find -L /lib /lib64 /usr/lib /usr/lib64 ! -group root -exec ls -l {} \; -{{% if "ubuntu" not in product %}} template: name: file_groupowner vars: @@ -66,21 +61,26 @@ template: - /lib64/ - /usr/lib/ - /usr/lib64/ -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} file_regex: ^.*\.so.*$ {{% else %}} file_regex: ^.*$ {{% endif %}} recursive: 'true' gid_or_name: '0' -{{% endif %}} fixtext: |- Configure the system-wide shared library files (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. - Run the following command, replacing "[FILE]" with any library file not group-owned by root{{{ gid_description }}}. +{{%- if 'ubuntu' in product %}} + Run the following command: + +
$ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' ! -group root -exec chgrp root {} +
+{{%- else %}} + Run the following command, replacing "[FILE]" with any library file not group-owned by root. $ sudo chgrp root [FILE] +{{%- endif %}} srg_requirement: - {{{ full_name }}} library files must be group-owned by root{{{ gid_description }}}. + {{{ full_name }}} library files must be group-owned by root. diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/excluded_groupowner.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/excluded_groupowner.pass.sh deleted file mode 100644 index 575ffe353000..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/excluded_groupowner.pass.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/bash -# platform = multi_platform_ubuntu - -for SYSLIBDIRS in /lib /lib64 /usr/lib /usr/lib64 -do - if [[ -d $SYSLIBDIRS ]] - then - find $SYSLIBDIRS ! -group root -type f -exec chgrp root '{}' \; - fi -done - -groupadd -r cac_sys -touch /lib/test_me - -chgrp cac_sys /lib/test_me diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_groupowner.fail.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_groupowner.fail.sh index c469a2f6e7fa..acb94170fa53 100644 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_groupowner.fail.sh +++ b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_groupowner.fail.sh @@ -2,7 +2,7 @@ # platform = multi_platform_sle,multi_platform_rhel,multi_platform_fedora,multi_platform_ubuntu,multi_platform_ol groupadd group_test -{{% if 'ol' in families or 'rhel' in product %}} +{{% if 'ol' in families or 'rhel' in product or 'ubuntu' in product %}} for TESTFILE in /lib/test_me.so /lib64/test_me.so /usr/lib/test_me.so /usr/lib64/test_me.so {{% else %}} for TESTFILE in /lib/test_me /lib64/test_me /usr/lib/test_me /usr/lib64/test_me diff --git a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_symlink.pass.sh b/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_symlink.pass.sh deleted file mode 100644 index 44616551e68d..000000000000 --- a/linux_os/guide/system/permissions/files/permissions_within_important_dirs/root_permissions_syslibrary_files/tests/incorrect_symlink.pass.sh +++ /dev/null @@ -1,12 +0,0 @@ -#!/bin/bash -# platform = multi_platform_ubuntu - -groupadd group_test - -TESTDIR="/usr/lib64" - -mkdir -p "$TESTDIR" - -# The check ignores this symlink and results in pass -ln -s $TESTDIR/missing_test_file $TESTDIR/faulty_symlink -chgrp -h group_test $TESTDIR/faulty_symlink diff --git a/linux_os/guide/system/permissions/files/sysctl_fs_protected_fifos/rule.yml b/linux_os/guide/system/permissions/files/sysctl_fs_protected_fifos/rule.yml index d21952c3300d..f6325c7cfb07 100644 --- a/linux_os/guide/system/permissions/files/sysctl_fs_protected_fifos/rule.yml +++ b/linux_os/guide/system/permissions/files/sysctl_fs_protected_fifos/rule.yml @@ -15,6 +15,7 @@ severity: medium identifiers: cce@rhel9: CCE-85884-5 cce@rhel10: CCE-87125-1 + cce@sle16: CCE-96680-4 references: nist: CM-6(a),AC-6(1) diff --git a/linux_os/guide/system/permissions/files/sysctl_fs_protected_hardlinks/rule.yml b/linux_os/guide/system/permissions/files/sysctl_fs_protected_hardlinks/rule.yml index e80a9af6cd9a..ce10b4d619a7 100644 --- a/linux_os/guide/system/permissions/files/sysctl_fs_protected_hardlinks/rule.yml +++ b/linux_os/guide/system/permissions/files/sysctl_fs_protected_hardlinks/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel10: CCE-86689-7 cce@sle12: CCE-91559-5 cce@sle15: CCE-91252-7 + cce@sle16: CCE-95822-3 references: nerc-cip: CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2 diff --git a/linux_os/guide/system/permissions/files/sysctl_fs_protected_regular/rule.yml b/linux_os/guide/system/permissions/files/sysctl_fs_protected_regular/rule.yml index bcf733e4ad0a..9a6b3ba2e0f4 100644 --- a/linux_os/guide/system/permissions/files/sysctl_fs_protected_regular/rule.yml +++ b/linux_os/guide/system/permissions/files/sysctl_fs_protected_regular/rule.yml @@ -16,6 +16,7 @@ severity: medium identifiers: cce@rhel9: CCE-85885-2 cce@rhel10: CCE-90354-2 + cce@sle16: CCE-96679-6 references: nist: CM-6(a),AC-6(1) diff --git a/linux_os/guide/system/permissions/files/sysctl_fs_protected_symlinks/rule.yml b/linux_os/guide/system/permissions/files/sysctl_fs_protected_symlinks/rule.yml index 9f068896501b..1a88d1d8b782 100644 --- a/linux_os/guide/system/permissions/files/sysctl_fs_protected_symlinks/rule.yml +++ b/linux_os/guide/system/permissions/files/sysctl_fs_protected_symlinks/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-88796-8 cce@sle12: CCE-91560-3 cce@sle15: CCE-91253-5 + cce@sle16: CCE-96456-9 references: nerc-cip: CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2 diff --git a/linux_os/guide/system/permissions/mounting/bios_disable_usb_boot/rule.yml b/linux_os/guide/system/permissions/mounting/bios_disable_usb_boot/rule.yml index 3af92cfa15c0..38b47b6de468 100644 --- a/linux_os/guide/system/permissions/mounting/bios_disable_usb_boot/rule.yml +++ b/linux_os/guide/system/permissions/mounting/bios_disable_usb_boot/rule.yml @@ -14,6 +14,14 @@ rationale: |- severity: unknown +ocil_clause: 'the system allows booting from USB devices' + +ocil: |- + Verify that booting from USB devices is disabled in the system boot firmware (BIOS/UEFI). + The process to configure this setting varies by hardware manufacturer and model. + Consult your hardware manual or vendor documentation for specific instructions on how to + access the firmware setup during boot and disable USB boot capabilities. + identifiers: cce@rhcos4: CCE-82662-8 cce@rhel9: CCE-87913-0 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/policy/stig/shared.yml b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/policy/stig/shared.yml index b0dee9a10f05..ff21865d7532 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/policy/stig/shared.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/policy/stig/shared.yml @@ -1,15 +1,22 @@ -srg_requirement: |- - {{{ full_name }}} must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory. - -vuldiscussion: |- - The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access. - - - +srg_requirement: >- + {{{ full_name }}} must prevent files with the + setuid and setgid bit set from being executed + on the /boot/efi directory. + +vuldiscussion: >- + The "nosuid" mount option causes the system + not to execute "setuid" and "setgid" files + with owner privileges. This option must be + used for mounting any file system not + containing approved "setuid" and "setguid" + files. Executing files from untrusted file + systems increases the opportunity for + nonprivileged users to attain unauthorized + administrative access. + +# yamllint disable rule:line-length checktext: |- - Note: For systems that use BIOS, this requirement is Not Applicable. - - Note: If the /boot/efi partition is mounted with a vfat filesystem, this requirement is Not Applicable. + Note: For systems that use BIOS, this requirement is not applicable. Verify the /boot/efi directory is mounted with the "nosuid" option with the following command: @@ -19,7 +26,6 @@ checktext: |- If the /boot/efi file system does not have the "nosuid" option set, this is a finding. +# yamllint enable rule:line-length fixtext: |- Modify "/etc/fstab" to use the "nosuid" option on the "/boot/efi" directory. - - diff --git a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/rule.yml index c32ddd70b51a..cdece146f9a3 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/rule.yml @@ -33,7 +33,6 @@ template: vars: mountpoint: /boot/efi mountoption: nosuid - exclude_filesystem_type: vfat backends: anaconda: "off" diff --git a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_with_nosuid.pass.sh b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_with_nosuid.pass.sh index 4f0db84f0be4..4cab01c1366c 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_with_nosuid.pass.sh +++ b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_with_nosuid.pass.sh @@ -1,7 +1,7 @@ #!/bin/bash # This test verifies that the rule passes when /boot/efi is mounted with vfat filesystem -# Even with nosuid set, vfat is excluded from the requirement (nosuid has no effect on vfat) +# with the nosuid option set # packages = dosfstools @@ -14,7 +14,7 @@ VFAT_PARTITION="/root/vfat_partition" dd if=/dev/zero of=$VFAT_PARTITION bs=1M count=50 mkfs.vfat $VFAT_PARTITION -# Add to fstab with nosuid option (should still pass because vfat is excluded) +# Add to fstab with nosuid option mkdir -p /boot/efi echo "$VFAT_PARTITION /boot/efi vfat rw,nosuid,relatime,loop 0 0" >> /etc/fstab diff --git a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_without_nosuid.pass.sh b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_without_nosuid.fail.sh similarity index 61% rename from linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_without_nosuid.pass.sh rename to linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_without_nosuid.fail.sh index 5666d9eb2c57..98acf27624ef 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_without_nosuid.pass.sh +++ b/linux_os/guide/system/permissions/partitions/mount_option_boot_efi_nosuid/tests/vfat_without_nosuid.fail.sh @@ -1,7 +1,7 @@ #!/bin/bash -# This test verifies that the rule passes when /boot/efi is mounted with vfat filesystem -# The nosuid requirement is not applicable to vfat filesystems +# This test verifies that the rule fails when /boot/efi +# is mounted with vfat without the nosuid option # packages = dosfstools @@ -14,7 +14,7 @@ VFAT_PARTITION="/root/vfat_partition" dd if=/dev/zero of=$VFAT_PARTITION bs=1M count=50 mkfs.vfat $VFAT_PARTITION -# Add to fstab without nosuid option (should pass because vfat is excluded) +# Add to fstab without the nosuid option mkdir -p /boot/efi echo "$VFAT_PARTITION /boot/efi vfat rw,relatime,loop 0 0" >> /etc/fstab diff --git a/linux_os/guide/system/permissions/partitions/mount_option_boot_noexec/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_boot_noexec/rule.yml index cbd941664727..773ff170a481 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_boot_noexec/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_boot_noexec/rule.yml @@ -23,7 +23,7 @@ identifiers: cce@rhel10: CCE-90334-4 cce@sle12: CCE-91541-3 cce@sle15: CCE-91234-5 - + cce@sle16: CCE-96582-2 template: name: mount_option diff --git a/linux_os/guide/system/permissions/partitions/mount_option_boot_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_boot_nosuid/rule.yml index b90a2baf6565..6ef99131bf3d 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_boot_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_boot_nosuid/rule.yml @@ -23,6 +23,7 @@ identifiers: cce@rhel10: CCE-88881-8 cce@sle12: CCE-91542-1 cce@sle15: CCE-91235-2 + cce@sle16: CCE-96648-1 references: nerc-cip: CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_home_noexec/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_home_noexec/rule.yml index 097283478533..912d86cc0b97 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_home_noexec/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_home_noexec/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-87810-8 cce@sle12: CCE-91543-9 cce@sle15: CCE-91236-0 + cce@sle16: CCE-96288-6 references: nist: CM-6(b) diff --git a/linux_os/guide/system/permissions/partitions/mount_option_home_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_home_nosuid/rule.yml index 673295341d39..ccb05ba12ef7 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_home_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_home_nosuid/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-88987-3 cce@sle12: CCE-83100-8 cce@sle15: CCE-85633-6 + cce@sle16: CCE-95966-8 cce@slmicro5: CCE-93791-2 cce@slmicro6: CCE-95062-6 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/ansible/shared.yml b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/ansible/shared.yml index c72785a6d38b..b1652d8354aa 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/ansible/shared.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/ansible/shared.yml @@ -41,13 +41,23 @@ fstype: "{{ item.fstype }}" when: - "item.mount is match('/\\w')" + - "item.mount is not match('/(boot|efi)')" - "item.options is not search('nodev')" - "item.fstype not in excluded_fstypes" + # Attempting to change polyinstantiated mounts for /tmp and /var/tmp, if present, will fail + - >- + (not accounts_polyinstantiated_var_tmp | + default(false)) or item.mount != + '/var/tmp/tmp-inst' + - "(not accounts_polyinstantiated_tmp | default(false)) or item.mount != '/tmp/tmp-inst'" with_items: - "{{ ansible_facts.mounts }}" -- name: "{{{ rule_title }}}: Ensure non-root local partitions are present with nodev option in /etc/fstab" +- name: >- + {{{ rule_title }}}: Ensure nodev option in + /etc/fstab for non-root local partitions ansible.builtin.replace: path: /etc/fstab - regexp: '^\s*(?!#)(/dev/\S+|UUID=\S+)\s+(/\w\S*)\s+(\S+)\s+(?!.*\bnodev\b)(\S+)(.*)$' + # yamllint disable-line rule:line-length + regexp: '^\s*(?!#)(/dev/\S+|UUID=\S+)\s+(/(?!boot|efi)\w\S*)\s+(\S+)\s+(?!.*\bnodev\b)(\S+)(.*)$' replace: '\1 \2 \3 \4,nodev \5' diff --git a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/bash/shared.sh b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/bash/shared.sh index 361518e7a35f..ef22a6038ec3 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/bash/shared.sh +++ b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/bash/shared.sh @@ -38,6 +38,11 @@ for partition_record in "${partitions_records[@]}"; do device="$(echo "${partition_record}" | cut -d " " -f2)" device_type="$(echo "${partition_record}" | cut -d " " -f3)" + # Skip /boot and /efi partitions + if [[ "$mount_point" =~ ^/(boot|efi) ]]; then + continue + fi + # Skip polyinstantiated directories if printf '%s\0' "${polyinstantiated_dirs[@]}" | grep -qxzF "$mount_point"; then continue @@ -59,5 +64,5 @@ for partition_record in "${partitions_records[@]}"; do {{{ bash_ensure_partition_is_mounted("$mount_point") | indent(4) }}} done -# Remediate unmounted /etc/fstab entries -sed -i -E '/nodev/! s;^\s*(/dev/\S+|UUID=\S+)\s+(/\w\S*)\s+(\S+)\s+(\S+)(.*)$;\1 \2 \3 \4,nodev \5;' /etc/fstab +# Remediate unmounted /etc/fstab entries, excluding /boot and /efi partitions +sed -i -E '/nodev/! { /^\s*(\/dev\/\S+|UUID=\S+)\s+\/(boot|efi)/! s;^\s*(/dev/\S+|UUID=\S+)\s+(/\w\S*)\s+(\S+)\s+(\S+)(.*)$;\1 \2 \3 \4,nodev \5; }' /etc/fstab diff --git a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/oval/shared.xml b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/oval/shared.xml index 89361099bf93..d467a8bd69f4 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/oval/shared.xml +++ b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/oval/shared.xml @@ -46,7 +46,7 @@ /etc/fstab - ^\s*(?!#)(?:/dev/\S+|UUID=\S+)\s+/\w\S*\s+\S+\s+(\S+) + ^\s*(?!#)(?:/dev/\S+|UUID=\S+)\s+/(?!boot|efi)\w\S*\s+\S+\s+(\S+) 1 nodev
on these filesystems. ocil: | - To verify the nodev option is configured for non-root local partitions, run the following command: + To verify the nodev option is configured for non-root local partitions, + run the following command:
$ sudo mount | grep '^/dev\S* on /\S' | grep --invert-match 'nodev'
- The output shows local non-root partitions mounted without the nodev option, and there should be no output at all. + The output shows local non-root partitions mounted without the nodev option, + and there should be no output at all. ocil_clause: "some mounts appear among output lines" + severity: medium identifiers: @@ -32,14 +35,22 @@ identifiers: cce@rhel10: CCE-88981-6 cce@sle12: CCE-91544-7 cce@sle15: CCE-91237-8 + cce@sle16: CCE-96023-7 references: cis-csc: 11,14,3,9 cobit5: BAI10.01,BAI10.02,BAI10.03,BAI10.05,DSS05.02,DSS05.05,DSS06.06 - isa-62443-2009: 4.3.3.5.1,4.3.3.5.2,4.3.3.5.3,4.3.3.5.4,4.3.3.5.5,4.3.3.5.6,4.3.3.5.7,4.3.3.5.8,4.3.3.6.1,4.3.3.6.2,4.3.3.6.3,4.3.3.6.4,4.3.3.6.5,4.3.3.6.6,4.3.3.6.7,4.3.3.6.8,4.3.3.6.9,4.3.3.7.1,4.3.3.7.2,4.3.3.7.3,4.3.3.7.4,4.3.4.3.2,4.3.4.3.3 - isa-62443-2013: 'SR 1.1,SR 1.10,SR 1.11,SR 1.12,SR 1.13,SR 1.2,SR 1.3,SR 1.4,SR 1.5,SR 1.6,SR 1.7,SR 1.8,SR 1.9,SR 2.1,SR 2.2,SR 2.3,SR 2.4,SR 2.5,SR 2.6,SR 2.7,SR 7.6' + isa-62443-2009: "4.3.3.5.1,4.3.3.5.2,4.3.3.5.3,4.3.3.5.4,4.3.3.5.5,\ + 4.3.3.5.6,4.3.3.5.7,4.3.3.5.8,4.3.3.6.1,4.3.3.6.2,4.3.3.6.3,\ + 4.3.3.6.4,4.3.3.6.5,4.3.3.6.6,4.3.3.6.7,4.3.3.6.8,4.3.3.6.9,\ + 4.3.3.7.1,4.3.3.7.2,4.3.3.7.3,4.3.3.7.4,4.3.4.3.2,4.3.4.3.3" + isa-62443-2013: "SR 1.1,SR 1.10,SR 1.11,SR 1.12,SR 1.13,SR 1.2,\ + SR 1.3,SR 1.4,SR 1.5,SR 1.6,SR 1.7,SR 1.8,SR 1.9,SR 2.1,\ + SR 2.2,SR 2.3,SR 2.4,SR 2.5,SR 2.6,SR 2.7,SR 7.6" iso27001-2013: A.12.1.2,A.12.5.1,A.12.6.2,A.14.2.2,A.14.2.3,A.14.2.4,A.9.1.2 - nerc-cip: CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2 + nerc-cip: "CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,\ + CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,\ + CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2" nist: CM-7(a),CM-7(b),CM-6(a),AC-6,AC-6(1),MP-7 nist-csf: PR.IP-1,PR.PT-3 srg: SRG-OS-000368-GPOS-00154,SRG-OS-000480-GPOS-00227 @@ -50,3 +61,13 @@ fixtext: |- Configure the "/etc/fstab" to use the "nodev" option on all non-root local partitions. srg_requirement: '{{{ full_name }}} must prevent special devices on non-root local partitions.' + +warnings: + - general: |- + This rule checks only local partitions, identified as those backed by + a device node in /dev. Network file systems such as NFS, CIFS, + GlusterFS and others are excluded because they do not expose local + device nodes. The /boot and /efi partitions are + excluded because they are special partitions usually handled by a + systemd mount unit, and enforcing nodev on them during + operating system installation causes issues. diff --git a/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/tests/vfat_without_nodev.fail.sh b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/tests/vfat_without_nodev.fail.sh new file mode 100644 index 000000000000..d395d3842198 --- /dev/null +++ b/linux_os/guide/system/permissions/partitions/mount_option_nodev_nonroot_local_partitions/tests/vfat_without_nodev.fail.sh @@ -0,0 +1,19 @@ +#!/bin/bash + +. $SHARED/partition.sh + +# Add nodev option to all records in fstab to ensure that test will +# run on environment where everything is set correctly for rule check. +cp /etc/fstab /etc/fstab.backup +sed -i -e 's/\bnodev\b/,/g' -e 's/,,//g' -e 's/\s,\s/defaults/g' /etc/fstab.backup +awk '{$4 = $4",nodev"; print}' /etc/fstab.backup > /etc/fstab +# Remount all partitions. (--all option can't be used because it doesn't +# mount e.g. /boot partition +declare -a partitions=( $(awk '{print $2}' /etc/fstab | grep "^/\w") ) +for partition in ${partitions[@]}; do + mount -o remount "$partition" +done + +# A vfat partition without nodev should be flagged by the rule. +PARTITION="/dev/new_partition1"; create_partition +make_fstab_given_partition_line "/tmp/partition1" vfat defaults diff --git a/linux_os/guide/system/permissions/partitions/mount_option_opt_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_opt_nosuid/rule.yml index d5493739a92f..4e9086e97dc2 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_opt_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_opt_nosuid/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-86868-7 cce@sle12: CCE-91584-3 cce@sle15: CCE-91270-9 + cce@sle16: CCE-95940-3 platform: mount[opt] diff --git a/linux_os/guide/system/permissions/partitions/mount_option_srv_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_srv_nosuid/rule.yml index f5f66509d8af..b196cc82a4a5 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_srv_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_srv_nosuid/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-90162-9 cce@sle12: CCE-91585-0 cce@sle15: CCE-91271-7 + cce@sle16: CCE-95863-7 platform: mount[srv] diff --git a/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/ansible/sle16.yml b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/ansible/sle16.yml new file mode 100644 index 000000000000..8dfea23acad8 --- /dev/null +++ b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/ansible/sle16.yml @@ -0,0 +1,28 @@ +# platform = SUSE Linux Enterprise 16 +# reboot = true +# strategy = configure +# complexity = low +# disruption = low + +- name: '{{{ rule_title }}} - Check if noexec options is configured in /usr/lib/systemd/system/tmp.mount' + ansible.builtin.lineinfile: + path: /usr/lib/systemd/system/tmp.mount + regexp: ^[\s]*Options=[\s]*.*noexec.*$ + state: absent + check_mode: true + register: noexec_match + +# if no match, collect current options and add noexec +- name: '{{{ rule_title }}} - Collect previously configured options' + ansible.builtin.shell: + cmd: sed -n 's/^[\s]*Options=[\s]*\(.*\)$/\1/p' /usr/lib/systemd/system/tmp.mount + register: current_options + when: + - noexec_match is defined and noexec_match.found == 0 + + +- name: '{{{ rule_title }}} - Add noexec option to previously configured options' + ansible.builtin.shell: + cmd: sed -i "s/^Options=.*/Options={{ current_options.stdout }},noexec/g" /usr/lib/systemd/system/tmp.mount + when: + - noexec_match.found == 0 and current_options is defined diff --git a/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/bash/sle16.sh b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/bash/sle16.sh new file mode 100644 index 000000000000..9f694b9bb9d3 --- /dev/null +++ b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/bash/sle16.sh @@ -0,0 +1,23 @@ +# platform = SUSE Linux Enterprise 16 +# reboot = true +# strategy = configure +# complexity = low +# disruption = low + +tmp_mount_file="/usr/lib/systemd/system/tmp.mount" + +# if already set, skip +if grep -qE '^[\s]*Options=[\s]*.*noexec.*$' ${tmp_mount_file}; then + echo "noexec option already present, skipping remediation" + exit 0 +fi + +# no options set, add it +if ! grep -qE '^[\s]*Options=[\s]*.*$' ${tmp_mount_file}; then + echo "Options=noexec" >> ${tmp_mount_file} +else + # collect currently set options + current_options=$(sed -n 's/^[\s]*Options=[\s]*\(.*\)$/\1/p' ${tmp_mount_file}) + # add noexec to current options and replace + sed -i "s/^Options=.*/Options=${current_options},noexec/g" ${tmp_mount_file} +fi diff --git a/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/oval/sle16.xml b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/oval/sle16.xml new file mode 100644 index 000000000000..81bec910ddfd --- /dev/null +++ b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/oval/sle16.xml @@ -0,0 +1,18 @@ + + + {{{ oval_metadata("ensure tmp.mount services has noexec option configured.") }}} + + + + + + + + + + /usr/lib/systemd/system/tmp.mount + ^[\s]*Options=.*noexec.*$ + 1 + + + diff --git a/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/rule.yml index 735018892a8c..75fb0ec5f6c6 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_tmp_noexec/rule.yml @@ -23,6 +23,7 @@ identifiers: cce@rhel10: CCE-87095-6 cce@sle12: CCE-91586-8 cce@sle15: CCE-91272-5 + cce@sle16: CCE-96696-0 cce@slmicro5: CCE-94079-1 references: @@ -39,7 +40,7 @@ references: srg: SRG-OS-000368-GPOS-00154 stigid@ol8: OL08-00-040125 -{{% if product == 'slmicro5' %}} +{{% if product in ['slmicro5', 'sle16'] %}} platform: system_with_kernel {{% else %}} platform: mount[tmp] diff --git a/linux_os/guide/system/permissions/partitions/mount_option_tmp_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_tmp_nosuid/rule.yml index 1485f4d8ee99..cf0e126f67e2 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_tmp_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_tmp_nosuid/rule.yml @@ -23,6 +23,7 @@ identifiers: cce@rhel10: CCE-87318-2 cce@sle12: CCE-91587-6 cce@sle15: CCE-91273-3 + cce@sle16: CCE-96573-1 references: cis-csc: 11,13,14,3,8,9 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_var_log_noexec/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_var_log_noexec/rule.yml index 819040553a9d..e2cbb432ed89 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_var_log_noexec/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_var_log_noexec/rule.yml @@ -23,6 +23,7 @@ identifiers: cce@rhel10: CCE-89129-1 cce@sle12: CCE-91588-4 cce@sle15: CCE-91274-1 + cce@sle16: CCE-96444-5 references: nerc-cip: CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_var_log_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_var_log_nosuid/rule.yml index 936812700f4d..5ec43738c51b 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_var_log_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_var_log_nosuid/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-90639-6 cce@sle12: CCE-91589-2 cce@sle15: CCE-91275-8 + cce@sle16: CCE-95774-6 references: nerc-cip: CIP-003-8 R5.1.1,CIP-003-8 R5.3,CIP-004-6 R2.3,CIP-007-3 R2.1,CIP-007-3 R2.2,CIP-007-3 R2.3,CIP-007-3 R5.1,CIP-007-3 R5.1.1,CIP-007-3 R5.1.2 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_var_noexec/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_var_noexec/rule.yml index 1900132c63d8..87808eae8c22 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_var_noexec/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_var_noexec/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-90153-8 cce@sle12: CCE-91590-0 cce@sle15: CCE-91276-6 + cce@sle16: CCE-96551-7 platform: mount[var] diff --git a/linux_os/guide/system/permissions/partitions/mount_option_var_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_var_nosuid/rule.yml index 4ecbb408721f..d1a14d993188 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_var_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_var_nosuid/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel10: CCE-89496-4 cce@sle12: CCE-91591-8 cce@sle15: CCE-91277-4 + cce@sle16: CCE-95884-3 {{{ complete_ocil_entry_mount_option("/var", "nosuid") }}} diff --git a/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_noexec/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_noexec/rule.yml index 5a49a43030a5..cce28561b5c0 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_noexec/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_noexec/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-87347-1 cce@sle12: CCE-91592-6 cce@sle15: CCE-91278-2 + cce@sle16: CCE-95723-3 references: cis@sle12: 1.1.12 diff --git a/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_nosuid/rule.yml b/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_nosuid/rule.yml index dbe30c165901..3b0d2f507d03 100644 --- a/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_nosuid/rule.yml +++ b/linux_os/guide/system/permissions/partitions/mount_option_var_tmp_nosuid/rule.yml @@ -24,6 +24,7 @@ identifiers: cce@rhel10: CCE-87892-6 cce@sle12: CCE-91593-4 cce@sle15: CCE-91279-0 + cce@sle16: CCE-96199-5 references: cis@sle12: 1.1.14 diff --git a/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_backtraces/rule.yml b/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_backtraces/rule.yml index 99fbd8321d5d..5db74d51bd52 100644 --- a/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_backtraces/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_backtraces/rule.yml @@ -66,7 +66,7 @@ warnings: platform: package[systemd] -{{% if product in ["rhel8", "rhel9"] %}} +{{% if product in ["ol8", "ol9", "rhel8", "rhel9"] %}} conflicts: - sysctl_kernel_core_pattern {{% endif %}} diff --git a/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_storage/rule.yml b/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_storage/rule.yml index bd826b199009..793680264655 100644 --- a/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_storage/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/coredumps/coredump_disable_storage/rule.yml @@ -63,7 +63,7 @@ warnings: platform: package[systemd] -{{% if product in ["rhel8", "rhel9"] %}} +{{% if product in ["ol8", "ol9", "rhel8", "rhel9"] %}} conflicts: - sysctl_kernel_core_pattern {{% endif %}} diff --git a/linux_os/guide/system/permissions/restrictions/coredumps/disable_users_coredumps/rule.yml b/linux_os/guide/system/permissions/restrictions/coredumps/disable_users_coredumps/rule.yml index 9f457c1f838b..c7f0e9bc4e9f 100644 --- a/linux_os/guide/system/permissions/restrictions/coredumps/disable_users_coredumps/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/coredumps/disable_users_coredumps/rule.yml @@ -56,7 +56,7 @@ srg_requirement: '{{{ full_name }}} must disable core dumps for all users.' platform: package[pam] -{{% if product in ["rhel8", "rhel9"] %}} +{{% if product in ["ol8", "ol9", "rhel8", "rhel9"] %}} conflicts: - sysctl_kernel_core_pattern {{% endif %}} diff --git a/linux_os/guide/system/permissions/restrictions/coredumps/service_systemd-coredump_disabled/rule.yml b/linux_os/guide/system/permissions/restrictions/coredumps/service_systemd-coredump_disabled/rule.yml index 58b2fe312066..296ea17c8df0 100644 --- a/linux_os/guide/system/permissions/restrictions/coredumps/service_systemd-coredump_disabled/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/coredumps/service_systemd-coredump_disabled/rule.yml @@ -45,7 +45,7 @@ fixtext: '{{{ fixtext_service_disabled("systemd-coredump") }}}' srg_requirement: '{{{ srg_requirement_service_disabled("systemd-coredump") }}}' -{{% if product in ["rhel8", "rhel9"] %}} +{{% if product in ["ol8", "ol9", "rhel8", "rhel9"] %}} conflicts: - sysctl_kernel_core_pattern {{% endif %}} diff --git a/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/rule.yml b/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/rule.yml index c6116f14cf9a..1f235a2e6506 100644 --- a/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-88686-1 cce@sle12: CCE-83125-5 cce@sle15: CCE-83299-8 + cce@sle16: CCE-96503-8 cce@slmicro5: CCE-93627-8 cce@slmicro6: CCE-94727-5 @@ -38,10 +39,12 @@ ocil: |- The runtime status of the kernel.kptr_restrict kernel parameter can be queried by running the following command:
$ sysctl kernel.kptr_restrict
- The output of the command should indicate either: + The output of the command should indicate: kernel.kptr_restrict = 1 + {{% if product != 'rhel8' %}} or: kernel.kptr_restrict = 2 + {{% endif %}} The output of the command should not indicate: kernel.kptr_restrict = 0 @@ -54,12 +57,14 @@ ocil: |-
$ grep -r '^\s*kernel.kptr_restrict\s*=' /etc/sysctl.conf /etc/sysctl.d
The command should not find any assignments other than: kernel.kptr_restrict = 1 + {{% if product != 'rhel8' %}} or: kernel.kptr_restrict = 2 + {{% endif %}} Conflicting assignments are not allowed. -ocil_clause: "the kernel.kptr_restrict is not set to 1 or 2 or is configured to be 0" +ocil_clause: "the kernel.kptr_restrict is not set to 1{{% if product != 'rhel8' %}} or 2{{% endif %}} or is configured to be 0" srg_requirement: '{{{ full_name }}} must restrict exposed kernel pointer addresses access.' @@ -69,7 +74,10 @@ template: name: sysctl vars: sysctlvar: kernel.kptr_restrict - {{% if 'ol' in families or 'rhel' in product %}} + {{% if product == 'rhel8' %}} + sysctlval: '1' + wrong_sysctlval_for_testing: "0" + {{% elif 'ol' in families or 'rhel' in product %}} sysctlval: - '1' - '2' diff --git a/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2.pass.sh b/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2.pass.sh index 23cce30a8853..d9d96bbb3589 100644 --- a/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2.pass.sh +++ b/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2.pass.sh @@ -1,5 +1,9 @@ #!/bin/bash +{{% if product == 'rhel8' %}} +# platform = Not Applicable +{{% else %}} # platform = multi_platform_ol,multi_platform_rhel,multi_platform_almalinux +{{% endif %}} # Clean sysctl config directories rm -rf /usr/lib/sysctl.d/* /run/sysctl.d/* /etc/sysctl.d/* diff --git a/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2_rhel8.fail.sh b/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2_rhel8.fail.sh new file mode 100644 index 000000000000..47200c49b91d --- /dev/null +++ b/linux_os/guide/system/permissions/restrictions/enable_execshield_settings/sysctl_kernel_kptr_restrict/tests/value_2_rhel8.fail.sh @@ -0,0 +1,11 @@ +#!/bin/bash +# platform = Red Hat Enterprise Linux 8 + +# Clean sysctl config directories +rm -rf /usr/lib/sysctl.d/* /run/sysctl.d/* /etc/sysctl.d/* + +sed -i "/kernel.kptr_restrict/d" /etc/sysctl.conf +echo "kernel.kptr_restrict = 2" >> /etc/sysctl.conf + +# set correct runtime value to check if the filesystem configuration is evaluated properly +sysctl -w kernel.kptr_restrict="2" diff --git a/linux_os/guide/system/permissions/restrictions/kernel_module_uvcvideo_disabled/rule.yml b/linux_os/guide/system/permissions/restrictions/kernel_module_uvcvideo_disabled/rule.yml index 2ce9ba6c5b11..825638a8b84f 100644 --- a/linux_os/guide/system/permissions/restrictions/kernel_module_uvcvideo_disabled/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/kernel_module_uvcvideo_disabled/rule.yml @@ -27,7 +27,7 @@ ocil_clause: 'the command does not return any output, or the line is commented o ocil: |- If the device or {{{ full_name }}} does not have a camera installed, this requirement is not applicable. - This requirement is not applicable to mobile devices (smartphones and tablets), where the use of the camera is a local AO decision. + This requirement is not applicable to mobile devices (smartphones and tablets), where the use of the camera is a local Authorizing Official (AO) decision. This requirement is not applicable to dedicated VTC suites located in approved VTC locations that are centrally managed. @@ -35,20 +35,21 @@ ocil: |- For a built-in camera, the camera must be protected by a camera cover (e.g., laptop camera cover slide) when not in use. If the built-in camera is not protected with a camera cover, or is not physically disabled, this is a finding. - If the camera is not disconnected, covered, or physically disabled, determine if it is being disabled via software with the following commands: + If the camera is not disconnected, covered, or physically disabled, determine if it is being disabled via software. - Verify the operating system disables the ability to load the uvcvideo kernel module. + Verify the operating system disables the ability to load the uvcvideo kernel module and ensure that the uvcvideo protocol module is disabled with the following command: - $ sudo grep -r uvcvideo /etc/modprobe.d/* | grep "/bin/true" + $ sudo grep -r uvcvideo /etc/modprobe.d/ - install uvcvideo /bin/true + /etc/modprobe.d/uvcvideo-blacklist.conf:install uvcvideo /bin/false + /etc/modprobe.d/uvcvideo-blacklist.conf:blacklist uvcvideo fixtext: |- Configure {{{ full_name }}} to disable the built-in or attached camera when not in use. - Build or modify the "/etc/modprobe.d/blacklist.conf" file by using the following example: + Add or update the following lines in the "/etc/modprobe.d/uvcvideo-blacklist.conf" file: - install uvcvideo /bin/true + install uvcvideo /bin/false blacklist uvcvideo Reboot the system for the settings to take effect. diff --git a/linux_os/guide/system/permissions/restrictions/poisoning/grub2_page_poison_argument/rule.yml b/linux_os/guide/system/permissions/restrictions/poisoning/grub2_page_poison_argument/rule.yml index 65ee91201ccf..8f82c74cd29b 100644 --- a/linux_os/guide/system/permissions/restrictions/poisoning/grub2_page_poison_argument/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/poisoning/grub2_page_poison_argument/rule.yml @@ -40,6 +40,8 @@ template: vars: arg_name: page_poison arg_value: '1' + datatype: int + operation: equals fixtext: |- {{{ describe_grub2_argument("page_poison=1") | indent(4) }}} diff --git a/linux_os/guide/system/permissions/restrictions/poisoning/grub2_slub_debug_argument/rule.yml b/linux_os/guide/system/permissions/restrictions/poisoning/grub2_slub_debug_argument/rule.yml index ed4efee8c5dd..0c7f99d631db 100644 --- a/linux_os/guide/system/permissions/restrictions/poisoning/grub2_slub_debug_argument/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/poisoning/grub2_slub_debug_argument/rule.yml @@ -40,7 +40,9 @@ template: vars: arg_name: slub_debug arg_variable: var_slub_debug_options - is_substring@ol8: "true" + datatype: string + operation: equals + operation@ol8: "pattern match" fixtext: |- {{{ describe_grub2_argument("slub_debug=" ~ xccdf_value("var_slub_debug_options")) | indent(4) }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/ansible/shared.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/ansible/shared.yml index 8d95be5ac6b1..174866b22b55 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/ansible/shared.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/ansible/shared.yml @@ -4,9 +4,16 @@ # complexity = low # disruption = medium +- name: "{{{ rule_title }}} - Set fact for sysctl paths" + ansible.builtin.set_fact: + sysctl_paths: + - "/etc/sysctl.d/" + - "/run/sysctl.d/" + - "/usr/local/lib/sysctl.d/" + - name: "{{{ rule_title }}} - Find all files that contain kernel.core_pattern" ansible.builtin.shell: - cmd: find -L /etc/sysctl.conf /etc/sysctl.d/ /run/sysctl.d/ -type f -name '*.conf' | xargs grep -HP '^\s*kernel.core_pattern\s*=\s*.*$' + cmd: find -L {{ sysctl_paths | join(" ") }} -type f -name '*.conf' | xargs grep -HP '^\s*kernel.core_pattern\s*=\s*.*$' register: find_all_values check_mode: false changed_when: false @@ -14,7 +21,7 @@ - name: "{{{ rule_title }}} - Find all files that set kernel.core_pattern to correct value" ansible.builtin.shell: - cmd: find -L /etc/sysctl.conf /etc/sysctl.d/ /run/sysctl.d/ -type f -name '*.conf' | xargs grep -HP '^\s*kernel.core_pattern\s*=\s*$' + cmd: find -L {{ sysctl_paths | join(" ") }} -type f -name '*.conf' | xargs grep -HP '^\s*kernel.core_pattern\s*=\s*$' register: find_correct_value check_mode: false changed_when: false @@ -23,15 +30,23 @@ - name: "{{{ rule_title }}} - Comment out any occurrences of kernel.core_pattern from config files" ansible.builtin.replace: path: '{{ item | split(":") | first }}' - regexp: ^[\s]*kernel.core_pattern + regexp: '^[\s]*kernel.core_pattern' replace: '#kernel.core_pattern' loop: '{{ find_all_values.stdout_lines }}' when: find_correct_value.stdout_lines | length == 0 or find_all_values.stdout_lines | length > find_correct_value.stdout_lines | length +- name: "{{{ rule_title }}} - Comment out any occurrences of kernel.core_pattern from /etc/sysctl.conf" + ansible.builtin.replace: + path: "{{ item }}" + regexp: '^[\s]*kernel.core_pattern' + replace: '#kernel.core_pattern' + with_fileglob: + - "/etc/sysctl.conf" + - name: "{{{ rule_title }}} - Ensure sysctl kernel.core_pattern is set to empty" ansible.posix.sysctl: - name: kernel.core_pattern - value: ' ' # ansible sysctl module doesn't allow empty string, a space string is allowed and has the same semantics as sysctl will ignore spaces - sysctl_file: "/etc/sysctl.conf" + name: "kernel.core_pattern" + value: ' ' # ansible sysctl module doesn't allow empty string, a space string is allowed and has the same semantics as sysctl will ignore spaces + sysctl_file: "/etc/sysctl.d/kernel_core_pattern.conf" state: present - reload: true + reload: yes diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/bash/shared.sh b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/bash/shared.sh index 2b2f1cd70b66..301e434e8c03 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/bash/shared.sh +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/bash/shared.sh @@ -5,49 +5,39 @@ # disruption = medium # Comment out any occurrences of kernel.core_pattern from /etc/sysctl.d/*.conf files -for f in /etc/sysctl.d/*.conf /run/sysctl.d/*.conf; do +for f in /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf; do + + # skip systemd-sysctl symlink (/etc/sysctl.d/99-sysctl.conf -> /etc/sysctl.conf) + if [[ "$(readlink -f "$f")" == "/etc/sysctl.conf" ]]; then continue; fi matching_list=$(grep -P '^(?!#).*[\s]*kernel.core_pattern.*$' $f | uniq ) if ! test -z "$matching_list"; then while IFS= read -r entry; do escaped_entry=$(sed -e 's|/|\\/|g' <<< "$entry") # comment out "kernel.core_pattern" matches to preserve user data - sed -i "s/^${escaped_entry}$/# &/g" $f + sed -i --follow-symlinks "s/^${escaped_entry}$/# &/g" $f done <<< "$matching_list" fi done +# +# Set sysctl config file which to save the desired value +# + +SYSCONFIG_FILE='/etc/sysctl.d/kernel_core_pattern.conf' + # # Set runtime for kernel.core_pattern # -/sbin/sysctl -q -n -w kernel.core_pattern="" +if {{{ bash_not_bootc_build() }}} ; then + /sbin/sysctl -q -n -w kernel.core_pattern="" +fi # # If kernel.core_pattern present in /etc/sysctl.conf, change value to empty # else, add "kernel.core_pattern =" to /etc/sysctl.conf # -# 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 "/etc/sysctl.conf"; then - sed_command+=('--follow-symlinks') -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' <<< "^kernel.core_pattern") -# shellcheck disable=SC2059 -printf -v formatted_output "%s=" "$stripped_key" +sed -i --follow-symlinks "/^kernel.core_pattern/d" /etc/sysctl.conf -# 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 \>), -# so if we search for 'setting', 'setting2' won't match. -if LC_ALL=C grep -q -m 1 -i -e "^kernel.core_pattern\\>" "/etc/sysctl.conf"; then - escaped_formatted_output=$(sed -e 's|/|\\/|g' <<< "$formatted_output") - "${sed_command[@]}" "s/^kernel.core_pattern\\>.*/$escaped_formatted_output/gi" "/etc/sysctl.conf" -else - # \n is precaution for case where file ends without trailing newline - - printf '%s\n' "$formatted_output" >> "/etc/sysctl.conf" -fi +{{{ bash_replace_or_append('${SYSCONFIG_FILE}', '^kernel.core_pattern', '', cce_identifiers=cce_identifiers) }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/oval/shared.xml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/oval/shared.xml index 3fba84e44eac..8005c5990f02 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/oval/shared.xml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_core_pattern_empty_string/oval/shared.xml @@ -37,155 +37,68 @@ + {{{ oval_metadata("The kernel 'kernel.core_pattern' parameter should be set to an empty string in the system configuration.", rule_title=rule_title) }}} - - - - - - + + + + + - - + - + - - - - + + + - - + + + - -{{% if target_oval_version >= [5, 11] %}} - - - - - - - local_var_sysctl_kernel_core_pattern_empty_string_counter - - - - 1 - - - - - - - - - - - - - object_sysctl_kernel_core_pattern_empty_string_static_set_sysctls_unfiltered - state_sysctl_kernel_core_pattern_empty_string_filepath_is_symlink - - - - - - - - - - - - - - - - - var_obj_symlink_sysctl_kernel_core_pattern_empty_string - var_obj_blank_sysctl_kernel_core_pattern_empty_string - - - - - local_var_blank_path_sysctl_kernel_core_pattern_empty_string - - - - - - - - local_var_symlinks_sysctl_kernel_core_pattern_empty_string - - - - - - - - - - - - - state_symlink_points_outside_usual_dirs_sysctl_kernel_core_pattern_empty_string - - - - - ^(?!(\/etc\/sysctl\.conf$|(\/etc|\/run|\/usr\/lib)\/sysctl\.d\/)).*$ - -{{% endif %}} - - - - - - + + - object_static_etc_sysctls_sysctl_kernel_core_pattern_empty_string - object_static_run_usr_sysctls_sysctl_kernel_core_pattern_empty_string + object_static_etc_lib_sysctls_sysctl_kernel_core_pattern_empty_string + object_static_run_usr_local_sysctls_sysctl_kernel_core_pattern_empty_string - + object_static_sysctl_sysctl_kernel_core_pattern_empty_string object_static_etc_sysctld_sysctl_kernel_core_pattern_empty_string - + + object_static_usr_local_lib_sysctld_sysctl_kernel_core_pattern_empty_string object_static_run_sysctld_sysctl_kernel_core_pattern_empty_string + /etc/sysctl.conf ^[[:blank:]]*kernel.core_pattern[[:blank:]]*=[[:blank:]]*(.*)$ @@ -205,6 +118,23 @@ ^[[:blank:]]*kernel.core_pattern[[:blank:]]*=[[:blank:]]*(.*)$ 1 + + + /usr/local/lib/sysctl.d + ^.*\.conf$ + ^[[:blank:]]*kernel.core_pattern[[:blank:]]*=[[:blank:]]*(.*)$ + 1 + + + + + /usr/lib/sysctl.d + ^.*\.conf$ + ^[[:blank:]]*kernel.core_pattern[[:blank:]]*=[[:blank:]]*(.*)$ + 1 + + + diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_modules_disabled/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_modules_disabled/rule.yml index ea7ed7dd56c9..7848282d36d4 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_modules_disabled/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_modules_disabled/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-87060-0 cce@sle12: CCE-91566-0 cce@sle15: CCE-91256-8 + cce@sle16: CCE-96441-1 {{{ complete_ocil_entry_sysctl_option_value(sysctl="kernel.modules_disabled", value="1") }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_panic_on_oops/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_panic_on_oops/rule.yml index 4978ee7b55fa..d5e0ff2d7630 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_panic_on_oops/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_panic_on_oops/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel8: CCE-87666-4 cce@rhel9: CCE-88666-3 cce@rhel10: CCE-88293-6 + cce@sle16: CCE-96624-2 {{{ complete_ocil_entry_sysctl_option_value(sysctl="kernel.panic_on_oops", value="1") }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_cpu_time_max_percent/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_cpu_time_max_percent/rule.yml index 4193087a450b..efa5539867f5 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_cpu_time_max_percent/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_cpu_time_max_percent/rule.yml @@ -18,6 +18,7 @@ identifiers: cce@rhel10: CCE-87824-9 cce@sle12: CCE-91567-8 cce@sle15: CCE-91257-6 + cce@sle16: CCE-95810-8 {{{ complete_ocil_entry_sysctl_option_value(sysctl="kernel.perf_cpu_time_max_percent", value="1") }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_max_sample_rate/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_max_sample_rate/rule.yml index a9cd4ecb8b02..311c2a720ae3 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_max_sample_rate/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_max_sample_rate/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel10: CCE-88924-6 cce@sle12: CCE-91569-4 cce@sle15: CCE-91259-2 + cce@sle16: CCE-96293-6 {{{ complete_ocil_entry_sysctl_option_value(sysctl="kernel.perf_event_max_sample_rate", value="1") }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_paranoid/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_paranoid/rule.yml index 0a3b7150118e..15066db66a1a 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_paranoid/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_perf_event_paranoid/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel10: CCE-90142-1 cce@sle12: CCE-91568-6 cce@sle15: CCE-91258-4 + cce@sle16: CCE-96571-5 references: nist: AC-6 diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_pid_max/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_pid_max/rule.yml index d4fdaab86b80..d87e5a513942 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_pid_max/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_pid_max/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel10: CCE-88134-2 cce@sle12: CCE-91570-2 cce@sle15: CCE-91260-0 + cce@sle16: CCE-95760-5 {{{ complete_ocil_entry_sysctl_option_value(sysctl="kernel.pid_max", value="65536") }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_sysrq/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_sysrq/rule.yml index 61cb3a8d4f6c..7a4c299a370b 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_sysrq/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_sysrq/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel10: CCE-90232-0 cce@sle12: CCE-91571-0 cce@sle15: CCE-91261-8 + cce@sle16: CCE-96062-5 {{{ complete_ocil_entry_sysctl_option_value(sysctl="kernel.sysrq", value="0") }}} diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_unprivileged_bpf_disabled/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_unprivileged_bpf_disabled/rule.yml index 53af78ce203b..d2d1e2cf9284 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_unprivileged_bpf_disabled/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_unprivileged_bpf_disabled/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-82974-7 cce@rhel9: CCE-83957-1 cce@rhel10: CCE-89405-5 + cce@sle16: CCE-96676-2 references: nist: AC-6,SC-7(10) diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_yama_ptrace_scope/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_yama_ptrace_scope/rule.yml index 2c6e83019b64..3a56b472e039 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_kernel_yama_ptrace_scope/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_kernel_yama_ptrace_scope/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-88785-1 cce@sle12: CCE-91572-8 cce@sle15: CCE-91262-6 + cce@sle16: CCE-96674-7 references: nist: SC-7(10) diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_net_core_bpf_jit_harden/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_net_core_bpf_jit_harden/rule.yml index e05977fecfbb..49c4d362a87a 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_net_core_bpf_jit_harden/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_net_core_bpf_jit_harden/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel8: CCE-82934-1 cce@rhel9: CCE-83966-2 cce@rhel10: CCE-89631-6 + cce@sle16: CCE-96656-4 references: nist: CM-6,SC-7(10) diff --git a/linux_os/guide/system/permissions/restrictions/sysctl_vm_mmap_min_addr/rule.yml b/linux_os/guide/system/permissions/restrictions/sysctl_vm_mmap_min_addr/rule.yml index 3b247e01b199..581d1200fe48 100644 --- a/linux_os/guide/system/permissions/restrictions/sysctl_vm_mmap_min_addr/rule.yml +++ b/linux_os/guide/system/permissions/restrictions/sysctl_vm_mmap_min_addr/rule.yml @@ -19,6 +19,7 @@ identifiers: cce@rhel10: CCE-87534-4 cce@sle12: CCE-91573-6 cce@sle15: CCE-91263-4 + cce@sle16: CCE-96371-0 {{{ complete_ocil_entry_sysctl_option_value(sysctl="vm.mmap_min_addr", value="65536") }}} diff --git a/linux_os/guide/system/secureboot/group.yml b/linux_os/guide/system/secureboot/group.yml index ef21365aa1da..6b90ec08ed26 100644 --- a/linux_os/guide/system/secureboot/group.yml +++ b/linux_os/guide/system/secureboot/group.yml @@ -10,7 +10,7 @@ description: |- Secure Boot is part of the Unified Extensible Firmware Interface (UEFI). The protocol defines a process that prevents the loading of unsigned drivers, boot loaders, or kernel modules (or those with unacceptable digital signatures). When Secure Boot - is enabled, system boot loaders, the Red Hat Enterprise Linux kernel, and all + is enabled, system boot loaders, the {{{ full_name }}} kernel, and all kernel modules must be cryptographically signed with a private key. This allows them to be authenticated with the corresponding public key. diff --git a/linux_os/guide/system/selinux/directory_groupowner_etc_selinux/rule.yml b/linux_os/guide/system/selinux/directory_groupowner_etc_selinux/rule.yml index 96333381c14e..4cf322bb6f65 100644 --- a/linux_os/guide/system/selinux/directory_groupowner_etc_selinux/rule.yml +++ b/linux_os/guide/system/selinux/directory_groupowner_etc_selinux/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86274-8 cce@rhel10: CCE-87637-5 cce@sle15: CCE-92501-6 + cce@sle16: CCE-96054-2 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/selinux", group="root") }}}' diff --git a/linux_os/guide/system/selinux/directory_owner_etc_selinux/rule.yml b/linux_os/guide/system/selinux/directory_owner_etc_selinux/rule.yml index 5f14cf353776..5273edd45640 100644 --- a/linux_os/guide/system/selinux/directory_owner_etc_selinux/rule.yml +++ b/linux_os/guide/system/selinux/directory_owner_etc_selinux/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86271-4 cce@rhel10: CCE-89309-9 cce@sle15: CCE-92510-7 + cce@sle16: CCE-96414-8 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/selinux", owner="root") }}}' diff --git a/linux_os/guide/system/selinux/directory_permissions_etc_selinux/rule.yml b/linux_os/guide/system/selinux/directory_permissions_etc_selinux/rule.yml index b2bbcef59795..1428e4d9ff4a 100644 --- a/linux_os/guide/system/selinux/directory_permissions_etc_selinux/rule.yml +++ b/linux_os/guide/system/selinux/directory_permissions_etc_selinux/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86279-7 cce@rhel10: CCE-87997-3 cce@sle15: CCE-92524-8 + cce@sle16: CCE-96570-7 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/selinux", perms="0755") }}}' diff --git a/linux_os/guide/system/selinux/file_groupowner_etc_sestatus_conf/rule.yml b/linux_os/guide/system/selinux/file_groupowner_etc_sestatus_conf/rule.yml index 73216cabd0aa..96b0d62306f2 100644 --- a/linux_os/guide/system/selinux/file_groupowner_etc_sestatus_conf/rule.yml +++ b/linux_os/guide/system/selinux/file_groupowner_etc_sestatus_conf/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86288-8 cce@rhel9: CCE-86289-6 cce@rhel10: CCE-89741-3 + cce@sle16: CCE-95848-8 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/sestatus.conf", group="root") }}}' diff --git a/linux_os/guide/system/selinux/file_owner_etc_sestatus_conf/rule.yml b/linux_os/guide/system/selinux/file_owner_etc_sestatus_conf/rule.yml index ba62bf3c001b..923c2deafc18 100644 --- a/linux_os/guide/system/selinux/file_owner_etc_sestatus_conf/rule.yml +++ b/linux_os/guide/system/selinux/file_owner_etc_sestatus_conf/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86285-4 cce@rhel9: CCE-86286-2 cce@rhel10: CCE-86503-0 + cce@sle16: CCE-95806-6 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/sestatus.conf", owner="root") }}}' diff --git a/linux_os/guide/system/selinux/file_permissions_etc_sestatus_conf/rule.yml b/linux_os/guide/system/selinux/file_permissions_etc_sestatus_conf/rule.yml index 0ae5fea5b3bb..23c360f25e80 100644 --- a/linux_os/guide/system/selinux/file_permissions_etc_sestatus_conf/rule.yml +++ b/linux_os/guide/system/selinux/file_permissions_etc_sestatus_conf/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86291-2 cce@rhel9: CCE-86293-8 cce@rhel10: CCE-90692-5 + cce@sle16: CCE-95722-5 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/sestatus.conf", perms="0644") }}}' diff --git a/linux_os/guide/system/selinux/grub2_enable_selinux/ansible/shared.yml b/linux_os/guide/system/selinux/grub2_enable_selinux/ansible/shared.yml index 38c97f2e8870..4ddfa4f42c56 100644 --- a/linux_os/guide/system/selinux/grub2_enable_selinux/ansible/shared.yml +++ b/linux_os/guide/system/selinux/grub2_enable_selinux/ansible/shared.yml @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel,multi_platform_rhv,multi_platform_fedora,multi_platform_ol,SUSE Linux Enterprise 15,multi_platform_almalinux +# platform = SUSE Linux Enterprise 15,SUSE Linux Enterprise 16,multi_platform_almalinux,multi_platform_fedora,multi_platform_ol,multi_platform_rhel,multi_platform_rhv # reboot = false # strategy = restrict # complexity = low diff --git a/linux_os/guide/system/selinux/grub2_enable_selinux/bash/shared.sh b/linux_os/guide/system/selinux/grub2_enable_selinux/bash/shared.sh index 997a564e0c71..b9c10607aa7b 100644 --- a/linux_os/guide/system/selinux/grub2_enable_selinux/bash/shared.sh +++ b/linux_os/guide/system/selinux/grub2_enable_selinux/bash/shared.sh @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel,multi_platform_rhv,multi_platform_fedora,multi_platform_ol,SUSE Linux Enterprise 15,multi_platform_almalinux +# platform = SUSE Linux Enterprise 15,SUSE Linux Enterprise 16,multi_platform_almalinux,multi_platform_fedora,multi_platform_ol,multi_platform_rhel,multi_platform_rhv sed -i --follow-symlinks "s/selinux=0//gI" /etc/default/grub /etc/grub2.cfg /etc/grub.d/* sed -i --follow-symlinks "s/enforcing=0//gI" /etc/default/grub /etc/grub2.cfg /etc/grub.d/* diff --git a/linux_os/guide/system/selinux/package_libselinux_installed/rule.yml b/linux_os/guide/system/selinux/package_libselinux_installed/rule.yml index 81391823b583..b902d67bbd5c 100644 --- a/linux_os/guide/system/selinux/package_libselinux_installed/rule.yml +++ b/linux_os/guide/system/selinux/package_libselinux_installed/rule.yml @@ -15,15 +15,14 @@ rationale: |- severity: high identifiers: + cce@rhcos4: CCE-89156-4 cce@rhel8: CCE-82877-2 cce@rhel9: CCE-84069-4 cce@rhel10: CCE-90410-2 cce@sle15: CCE-92490-2 cce@sle16: CCE-95712-6 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="libselinux") }}}' +{{{ complete_ocil_entry_package_installed("libselinux") }}} template: name: package_installed diff --git a/linux_os/guide/system/selinux/package_policycoreutils-python-utils_installed/rule.yml b/linux_os/guide/system/selinux/package_policycoreutils-python-utils_installed/rule.yml index e345282b5e21..48c7080bfe1b 100644 --- a/linux_os/guide/system/selinux/package_policycoreutils-python-utils_installed/rule.yml +++ b/linux_os/guide/system/selinux/package_policycoreutils-python-utils_installed/rule.yml @@ -22,9 +22,7 @@ identifiers: references: srg: SRG-OS-000480-GPOS-00227 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="policycoreutils-python-utils") }}}' +{{{ complete_ocil_entry_package_installed("policycoreutils-python-utils") }}} fixtext: '{{{ fixtext_package_installed("policycoreutils-python-utils") }}}' diff --git a/linux_os/guide/system/selinux/package_policycoreutils_installed/rule.yml b/linux_os/guide/system/selinux/package_policycoreutils_installed/rule.yml index b489a0fd0fab..ce5df82c7b8d 100644 --- a/linux_os/guide/system/selinux/package_policycoreutils_installed/rule.yml +++ b/linux_os/guide/system/selinux/package_policycoreutils_installed/rule.yml @@ -33,9 +33,7 @@ references: srg: SRG-OS-000480-GPOS-00227,SRG-OS-000134-GPOS-00068 stigid@ol8: OL08-00-010171 -ocil_clause: 'the policycoreutils package is not installed' - -ocil: '{{{ ocil_package(package="policycoreutils") }}}' +{{{ complete_ocil_entry_package_installed("policycoreutils") }}} template: name: package_installed diff --git a/linux_os/guide/system/selinux/package_setroubleshoot-plugins_removed/rule.yml b/linux_os/guide/system/selinux/package_setroubleshoot-plugins_removed/rule.yml index c203843bb30c..354a8060c709 100644 --- a/linux_os/guide/system/selinux/package_setroubleshoot-plugins_removed/rule.yml +++ b/linux_os/guide/system/selinux/package_setroubleshoot-plugins_removed/rule.yml @@ -21,8 +21,9 @@ identifiers: cce@rhel10: CCE-89365-1 cce@sle12: CCE-91582-7 cce@sle15: CCE-91269-1 + cce@sle16: CCE-96431-2 -{{{ complete_ocil_entry_package(package="setroubleshoot-plugins") }}} +{{{ complete_ocil_entry_package_removed("setroubleshoot-plugins") }}} template: name: package_removed diff --git a/linux_os/guide/system/selinux/package_setroubleshoot-server_removed/rule.yml b/linux_os/guide/system/selinux/package_setroubleshoot-server_removed/rule.yml index 2e64ff92ed3e..0fcc6980b0e0 100644 --- a/linux_os/guide/system/selinux/package_setroubleshoot-server_removed/rule.yml +++ b/linux_os/guide/system/selinux/package_setroubleshoot-server_removed/rule.yml @@ -22,8 +22,9 @@ identifiers: cce@rhel10: CCE-89569-8 cce@sle12: CCE-91580-1 cce@sle15: CCE-91267-5 + cce@sle16: CCE-96268-8 -{{{ complete_ocil_entry_package(package="setroubleshoot-server") }}} +{{{ complete_ocil_entry_package_removed("setroubleshoot-server") }}} template: name: package_removed diff --git a/linux_os/guide/system/selinux/package_setroubleshoot_removed/rule.yml b/linux_os/guide/system/selinux/package_setroubleshoot_removed/rule.yml index 5948b2d9202c..8c8fd76fa459 100644 --- a/linux_os/guide/system/selinux/package_setroubleshoot_removed/rule.yml +++ b/linux_os/guide/system/selinux/package_setroubleshoot_removed/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-89902-1 cce@sle12: CCE-91581-9 cce@sle15: CCE-91268-3 + cce@sle16: CCE-96597-0 template: name: package_removed diff --git a/linux_os/guide/system/selinux/selinux-booleans/sebool_deny_execmem/rule.yml b/linux_os/guide/system/selinux/selinux-booleans/sebool_deny_execmem/rule.yml index 54e9870d16ed..1c5b8900ad3a 100644 --- a/linux_os/guide/system/selinux/selinux-booleans/sebool_deny_execmem/rule.yml +++ b/linux_os/guide/system/selinux/selinux-booleans/sebool_deny_execmem/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-87708-4 cce@sle12: CCE-91575-1 cce@sle15: CCE-91265-9 + cce@sle16: CCE-96278-7 {{{ complete_ocil_entry_sebool_var(sebool="deny_execmem") }}} diff --git a/linux_os/guide/system/selinux/selinux-booleans/sebool_polyinstantiation_enabled/rule.yml b/linux_os/guide/system/selinux/selinux-booleans/sebool_polyinstantiation_enabled/rule.yml index 98f8fb788a78..dc41037d27f1 100644 --- a/linux_os/guide/system/selinux/selinux-booleans/sebool_polyinstantiation_enabled/rule.yml +++ b/linux_os/guide/system/selinux/selinux-booleans/sebool_polyinstantiation_enabled/rule.yml @@ -18,6 +18,7 @@ identifiers: cce@rhel10: CCE-88652-3 cce@sle12: CCE-91579-3 cce@sle15: CCE-91238-6 + cce@sle16: CCE-95753-0 {{{ complete_ocil_entry_sebool_var(sebool="polyinstantiation_enabled") }}} diff --git a/linux_os/guide/system/selinux/selinux-booleans/sebool_ssh_sysadm_login/rule.yml b/linux_os/guide/system/selinux/selinux-booleans/sebool_ssh_sysadm_login/rule.yml index 33e7510ffbae..778bfb653bff 100644 --- a/linux_os/guide/system/selinux/selinux-booleans/sebool_ssh_sysadm_login/rule.yml +++ b/linux_os/guide/system/selinux/selinux-booleans/sebool_ssh_sysadm_login/rule.yml @@ -32,6 +32,7 @@ identifiers: cce@rhel10: CCE-90429-2 cce@sle12: CCE-91574-4 cce@sle15: CCE-91264-2 + cce@sle16: CCE-95928-8 {{{ complete_ocil_entry_sebool_disabled(sebool="ssh_sysadm_login") }}} diff --git a/linux_os/guide/system/selinux/selinux_not_disabled/ansible/shared.yml b/linux_os/guide/system/selinux/selinux_not_disabled/ansible/shared.yml index 756897defedf..b3a694a27ed0 100644 --- a/linux_os/guide/system/selinux/selinux_not_disabled/ansible/shared.yml +++ b/linux_os/guide/system/selinux/selinux_not_disabled/ansible/shared.yml @@ -4,19 +4,22 @@ # complexity = low # disruption = low -- name: "{{{ rule_title }}} - Check current SELinux state" +- name: "{{{ rule_title }}} - Check current SELinux configuration" ansible.builtin.command: - cmd: getenforce - register: current_selinux_state + cmd: grep -oP '^\s*SELINUX=\K(enforcing|permissive|disabled)' /etc/selinux/config + register: selinux_config_state check_mode: false changed_when: false + failed_when: false -{{{ ansible_selinux_config_set(parameter="SELINUX", value="permissive", rule_title=rule_title) }}} +- name: "{{{ rule_title }}} - Set SELinux state to permissive if disabled or not configured" + block: + {{{ ansible_selinux_config_set(parameter="SELINUX", value="permissive", rule_title=rule_title) | indent(4) }}} -- name: "{{{ rule_title }}} - Mark system to relabel SELinux on next boot" - ansible.builtin.file: - path: /.autorelabel - state: touch - access_time: preserve - modification_time: preserve - when: current_selinux_state.stdout | lower != "permissive" + - name: "{{{ rule_title }}} - Mark system to relabel SELinux on next boot" + ansible.builtin.file: + path: /.autorelabel + state: touch + access_time: preserve + modification_time: preserve + when: selinux_config_state.stdout not in ['enforcing', 'permissive'] diff --git a/linux_os/guide/system/selinux/selinux_not_disabled/bash/shared.sh b/linux_os/guide/system/selinux/selinux_not_disabled/bash/shared.sh index 95b0795ea481..c5e6dd817545 100644 --- a/linux_os/guide/system/selinux/selinux_not_disabled/bash/shared.sh +++ b/linux_os/guide/system/selinux/selinux_not_disabled/bash/shared.sh @@ -4,6 +4,16 @@ # complexity = low # disruption = low -{{{ bash_selinux_config_set(parameter="SELINUX", value="permissive", rule_id=rule_id) }}} +# Check current SELinux state in config file +selinux_current_state="" +if [ -f "/etc/selinux/config" ]; then + selinux_current_state=$(grep -oP '^\s*SELINUX=\K(enforcing|permissive|disabled)' /etc/selinux/config || true) +fi -fixfiles onboot +# Only remediate if SELinux is disabled or not configured +# If already set to enforcing or permissive, it's compliant - preserve the current state +if [ "$selinux_current_state" != "enforcing" ] && [ "$selinux_current_state" != "permissive" ]; then + # SELinux is disabled or not configured, set to permissive as a conservative approach + {{{ bash_selinux_config_set(parameter="SELINUX", value="permissive", rule_id=rule_id) }}} + fixfiles onboot +fi diff --git a/linux_os/guide/system/selinux/selinux_not_disabled/rule.yml b/linux_os/guide/system/selinux/selinux_not_disabled/rule.yml index e9648d4d2235..73fe9ca6df76 100644 --- a/linux_os/guide/system/selinux/selinux_not_disabled/rule.yml +++ b/linux_os/guide/system/selinux/selinux_not_disabled/rule.yml @@ -9,7 +9,8 @@ description: |-
SELINUX=enforcing
OR
SELINUX=permissive
- Ensure that all files have correct SELinux labels by running: + If SELinux is currently disabled or not configured, ensure that all files have correct SELinux + labels by running:
fixfiles onboot
Then reboot the system. @@ -40,7 +41,11 @@ ocil: |- fixtext: |- Configure {{{ full_name }}} to enable SELinux. - Edit the file /etc/selinux/config and add or modify the following line: + If SELinux is currently set to "enforcing" or "permissive" in /etc/selinux/config, + the system is compliant and no changes are needed. + + If SELinux is disabled or not configured, edit the file /etc/selinux/config + and add or modify the following line:
SELINUX=enforcing
OR
SELINUX=permissive
@@ -49,7 +54,9 @@ fixtext: |- warnings: - general: |- - In case the SELinux is "disabled", the automated remediation will adopt a more - conservative approach and set it to "permissive" in order to avoid any system disruption - and give the administrator the opportunity to assess the impact and necessary efforts - before setting it to "enforcing", which is strongly recommended. + The automated remediation checks the SELinux configuration in /etc/selinux/config. + If SELinux is already set to "enforcing" or "permissive", the current state is preserved + and no changes are made. If SELinux is "disabled" or not configured, the remediation will + adopt a conservative approach and set it to "permissive" in order to avoid any system + disruption and give the administrator the opportunity to assess the impact and necessary + efforts before setting it to "enforcing", which is strongly recommended. diff --git a/linux_os/guide/system/software/disk_partitioning/encrypt_partitions/rule.yml b/linux_os/guide/system/software/disk_partitioning/encrypt_partitions/rule.yml index f2334ef3d080..7d0c8aa188f6 100644 --- a/linux_os/guide/system/software/disk_partitioning/encrypt_partitions/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/encrypt_partitions/rule.yml @@ -36,6 +36,8 @@ description: |- {{{ weblink(link="https://docs.oracle.com/en/operating-systems/oracle-linux/8/install/install-InstallingOracleLinuxManually.html#system-options") }}} {{% elif product == "ol9" %}} {{{ weblink(link="https://docs.oracle.com/en/operating-systems/oracle-linux/9/install/install-InstallingOracleLinuxManually.html#system-options") }}} + {{% elif product == "ol10" %}} + {{{ weblink(link="https://docs.oracle.com/en/operating-systems/oracle-linux/10/install/install-InstallingOracleLinuxManually.html#system-options") }}} {{% elif product == "sle12" %}} {{{ weblink(link="https://documentation.suse.com/sles/12-SP5/html/SLES-all/cha-security-cryptofs.html") }}} {{% elif product == "sle15" %}} @@ -60,6 +62,7 @@ rationale: |- severity: high identifiers: + cce@rhcos4: CCE-89503-7 cce@rhel8: CCE-80789-1 cce@rhel9: CCE-90849-1 cce@rhel10: CCE-89165-5 diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_boot/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_boot/rule.yml index 01c898effa81..11ea801cb32c 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_boot/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_boot/rule.yml @@ -22,7 +22,7 @@ identifiers: cce@rhel10: CCE-90755-0 cce@sle12: CCE-91484-6 cce@sle15: CCE-91176-8 - + cce@sle16: CCE-96430-4 {{{ complete_ocil_entry_separate_partition(part="/boot") }}} diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_home/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_home/rule.yml index f20cf960ae8e..9ea58be5c905 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_home/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_home/rule.yml @@ -23,6 +23,7 @@ identifiers: cce@rhel10: CCE-88231-6 cce@sle12: CCE-83152-9 cce@sle15: CCE-85639-3 + cce@sle16: CCE-95729-0 cce@slmicro5: CCE-93796-1 cce@slmicro6: CCE-95066-7 diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_opt/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_opt/rule.yml index dbb3529e26d0..077f8b781141 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_opt/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_opt/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-90750-1 cce@sle12: CCE-91485-3 cce@sle15: CCE-91177-6 + cce@sle16: CCE-96081-5 {{{ complete_ocil_entry_separate_partition(part="/opt") }}} diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_srv/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_srv/rule.yml index 871ce4fc85ed..773ee54cce20 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_srv/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_srv/rule.yml @@ -25,6 +25,7 @@ identifiers: cce@rhel10: CCE-88936-0 cce@sle12: CCE-91486-1 cce@sle15: CCE-91178-4 + cce@sle16: CCE-95922-1 {{{ complete_ocil_entry_separate_partition(part="/srv") }}} diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_usr/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_usr/rule.yml index a91af9b298db..ec9a94703a6b 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_usr/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_usr/rule.yml @@ -21,7 +21,7 @@ identifiers: cce@rhel10: CCE-90748-5 cce@sle12: CCE-91488-7 cce@sle15: CCE-91180-0 - + cce@sle16: CCE-96274-6 {{{ complete_ocil_entry_separate_partition(part="/usr") }}} diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_var/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_var/rule.yml index 98f4a53535fe..0c9ca10087f2 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_var/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_var/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-89166-3 cce@sle12: CCE-83153-7 cce@sle15: CCE-85640-1 + cce@sle16: CCE-95761-3 cce@slmicro5: CCE-93797-9 cce@slmicro6: CCE-95067-5 diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_var_log/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_var_log/rule.yml index 267652595db1..4afdabd4c279 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_var_log/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_var_log/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-88355-3 cce@sle12: CCE-91489-5 cce@sle15: CCE-91181-8 + cce@sle16: CCE-95945-2 references: cis-csc: 1,12,14,15,16,3,5,6,8 diff --git a/linux_os/guide/system/software/disk_partitioning/partition_for_var_tmp/rule.yml b/linux_os/guide/system/software/disk_partitioning/partition_for_var_tmp/rule.yml index c83b50a9f044..80b218b85f76 100644 --- a/linux_os/guide/system/software/disk_partitioning/partition_for_var_tmp/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/partition_for_var_tmp/rule.yml @@ -22,6 +22,7 @@ identifiers: cce@rhel10: CCE-87694-6 cce@sle12: CCE-91490-3 cce@sle15: CCE-91182-6 + cce@sle16: CCE-96245-6 references: cis@sle12: 1.1.11 diff --git a/linux_os/guide/system/software/disk_partitioning/systemd_tmp_mount_enabled/rule.yml b/linux_os/guide/system/software/disk_partitioning/systemd_tmp_mount_enabled/rule.yml index 6f6532637e10..946e387e60c7 100644 --- a/linux_os/guide/system/software/disk_partitioning/systemd_tmp_mount_enabled/rule.yml +++ b/linux_os/guide/system/software/disk_partitioning/systemd_tmp_mount_enabled/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel8: CCE-86890-1 cce@rhel9: CCE-86891-9 cce@rhel10: CCE-89797-5 + cce@sle16: CCE-96195-3 ocil: |- {{{ ocil_systemd_mount_enabled("tmp") }}} diff --git a/linux_os/guide/system/software/gnome/enable_dconf_user_profile/ansible/shared.yml b/linux_os/guide/system/software/gnome/enable_dconf_user_profile/ansible/shared.yml index c6d042fb3ba3..df0e3739cdc3 100644 --- a/linux_os/guide/system/software/gnome/enable_dconf_user_profile/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/enable_dconf_user_profile/ansible/shared.yml @@ -4,9 +4,4 @@ # complexity = low # disruption = medium -- name: "Configure GNOME3 DConf User Profile" - ansible.builtin.lineinfile: - dest: "/etc/dconf/profile/gdm" - line: "user-db:user\nsystem-db:gdm" - create: yes - state: present +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} diff --git a/linux_os/guide/system/software/gnome/enable_dconf_user_profile/bash/shared.sh b/linux_os/guide/system/software/gnome/enable_dconf_user_profile/bash/shared.sh index 06ba69b527b3..a0f5289b7df6 100644 --- a/linux_os/guide/system/software/gnome/enable_dconf_user_profile/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/enable_dconf_user_profile/bash/shared.sh @@ -1,3 +1,3 @@ # platform = multi_platform_sle -echo -e 'user-db:user\nsystem-db:gdm' > /etc/dconf/profile/gdm +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} diff --git a/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/ansible/shared.yml index d7ef96c9dce7..1d1453d42a41 100644 --- a/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/ansible/shared.yml @@ -21,6 +21,10 @@ create: yes register: result_lineinfile +{{% if product in ['sle15', 'sle16'] %}} +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} + - name: Dconf Update ansible.builtin.command: dconf update when: result_ini is changed or result_lineinfile is changed diff --git a/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/bash/shared.sh index 418467e2393d..4041b82f06fb 100644 --- a/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/bash/shared.sh @@ -5,5 +5,9 @@ {{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} {{% endif %}} +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} + {{{ bash_dconf_settings("org/gnome/login-screen", "disable-user-list", "true", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/login-screen", "disable-user-list", dconf_gdm_dir, "00-security-settings-lock") }}} diff --git a/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/policy/stig/shared.yml b/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/policy/stig/shared.yml index 9d2f897592bb..a30d3e50ba2e 100644 --- a/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/policy/stig/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_login_screen/dconf_gnome_disable_user_list/policy/stig/shared.yml @@ -19,9 +19,9 @@ fixtext: |- Configure {{{ full_name }}} to disable the user list at logon for graphical user interfaces. Create a database to contain the systemwide screensaver settings (if it does not already exist) with the following command: - Note: The example below is using the database "local" for the system. If the system is using another database in "/etc/dconf/profile/user", the file should be created under the appropriate subdirectory. + Note: The example below is using the database "{{{ dconf_gdm_dir }}}" for the system. If the system is using another database in "/etc/dconf/profile/user", the file should be created under the appropriate subdirectory. - $ sudo touch /etc/dconf/db/local.d/02-login-screen + $ sudo touch /etc/dconf/db/{{{ dconf_gdm_dir }}}/02-login-screen [org/gnome/login-screen] disable-user-list=true @@ -29,4 +29,3 @@ fixtext: |- Update the system databases: $ sudo dconf update - diff --git a/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_unattended_automatic_login/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_unattended_automatic_login/bash/shared.sh index 21e8eae8050b..501d4a066b6e 100644 --- a/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_unattended_automatic_login/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_unattended_automatic_login/bash/shared.sh @@ -1,11 +1,9 @@ # platform = multi_platform_sle,multi_platform_slmicro -if ! (sed -n '/^DISPLAYMANAGER_AUTOLOGIN=\"\"/p' /etc/sysconfig/displaymanager) -then +if ! grep -q '^DISPLAYMANAGER_AUTOLOGIN=""' /etc/sysconfig/displaymanager; then sed -i "s/^DISPLAYMANAGER_AUTOLOGIN=.*/DISPLAYMANAGER_AUTOLOGIN=\"\"/g" /etc/sysconfig/displaymanager fi -if ! (sed -n '/^DISPLAYMANAGER_PASSWORD_LESS_LOGIN=\"no\"/p' /etc/sysconfig/displaymanager) -then +if ! grep -q '^DISPLAYMANAGER_PASSWORD_LESS_LOGIN="no"' /etc/sysconfig/displaymanager; then sed -i "s/^DISPLAYMANAGER_PASSWORD_LESS_LOGIN=.*/DISPLAYMANAGER_PASSWORD_LESS_LOGIN=\"no\"/g" /etc/sysconfig/displaymanager fi diff --git a/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_xdmcp/rule.yml b/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_xdmcp/rule.yml index 4f228f0c3a4a..ac8e9953350d 100644 --- a/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_xdmcp/rule.yml +++ b/linux_os/guide/system/software/gnome/gnome_login_screen/gnome_gdm_disable_xdmcp/rule.yml @@ -11,9 +11,7 @@ title: 'Disable XDMCP in GDM' {{% endif %}} description: |- - XDMCP is an unencrypted protocol, and therefore, presents a security risk, see e.g. - {{{ weblink("https://help.gnome.org/admin/gdm/stable/security.html.en_GB#xdmcpsecurity", "XDMCP Gnome docs") }}}. - + XDMCP is an unencrypted protocol, and therefore, presents a security risk. To disable XDMCP support in Gnome, set Enable to false under the [xdmcp] configuration section in {{{ gdm_conf_path }}}. For example:
     [xdmcp]
diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/ansible/shared.yml
index 3a44e002d5c9..7781bf9f6818 100644
--- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/ansible/shared.yml
+++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/ansible/shared.yml
@@ -5,7 +5,11 @@
 # disruption = medium
 - name: "Disable GNOME3 Automounting - automount"
   community.general.ini_file:
+{{% if product in ['sle15', 'sle16'] %}}
+    dest: /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings
+{{% else %}}
     dest: /etc/dconf/db/local.d/00-security-settings
+{{% endif %}}
     section: org/gnome/desktop/media-handling
     option: automount
     value: "false"
@@ -15,20 +19,18 @@
 
 - name: "Prevent user modification of GNOME3 Automounting - automount"
   ansible.builtin.lineinfile:
+{{% if product in ['sle15', 'sle16'] %}}
+    path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock
+{{% else %}}
     path: /etc/dconf/db/local.d/locks/00-security-settings-lock
+{{% endif %}}
     regexp: '^/org/gnome/desktop/media-handling/automount$'
     line: '/org/gnome/desktop/media-handling/automount'
     create: yes
   register: result_lineinfile
 
-# apply fix for enable_dconf_user_profile, OVAL checks it
 {{% if product in ['sle15', 'sle16'] %}}
-- name: "Configure GNOME3 DConf User Profile"
-  ansible.builtin.lineinfile:
-    dest: "/etc/dconf/profile/gdm"
-    line: "user-db:user\nsystem-db:gdm"
-    create: yes
-    state: present
+{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}}
 {{% endif %}}
 
 - name: Dconf Update
diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/bash/shared.sh
index cb549a403266..0fc5cf0727ac 100644
--- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/bash/shared.sh
+++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/bash/shared.sh
@@ -8,7 +8,9 @@
 # apply fix for enable_dconf_user_profile, OVAL checks it
 {{% if product in ['sle15', 'sle16'] %}}
 {{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}}
-{{% endif %}}
-
+{{{ bash_dconf_settings("org/gnome/desktop/media-handling", "automount", "false", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}}
+{{{ bash_dconf_lock("org/gnome/desktop/media-handling", "automount", dconf_gdm_dir, "00-security-settings-lock") }}}
+{{% else %}}
 {{{ bash_dconf_settings("org/gnome/desktop/media-handling", "automount", "false", "local.d", "00-security-settings", rule_id=rule_id) }}}
 {{{ bash_dconf_lock("org/gnome/desktop/media-handling", "automount", "local.d", "00-security-settings-lock") }}}
+{{% endif %}}
diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/oval/shared.xml
index 35d7819f6072..e84d9434d7c6 100644
--- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/oval/shared.xml
+++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/oval/shared.xml
@@ -20,7 +20,11 @@
   
   
+{{% if product in ['sle15', 'sle16'] %}}
+    /etc/dconf/db/{{{ dconf_gdm_dir }}}/
+{{% else %}}
     /etc/dconf/db/local.d/
+{{% endif %}}
     ^.*$
     ^\[org/gnome/desktop/media-handling\]([^\n]*\n+)+?automount=false$
     1
@@ -33,7 +37,11 @@
   
   
+{{% if product in ['sle15', 'sle16'] %}}
+    /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/
+{{% else %}}
     /etc/dconf/db/local.d/locks/
+{{% endif %}}
     ^.*$
     ^/org/gnome/desktop/media-handling/automount$
     1
diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/rule.yml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/rule.yml
index d4c138569ff3..18d34513ebe2 100644
--- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/rule.yml
+++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/rule.yml
@@ -7,12 +7,12 @@ description: |-
     The system's default desktop environment, GNOME3, will mount
     devices and removable media (such as DVDs, CDs and USB flash drives) whenever
     they are inserted into the system. To disable automount within GNOME3, add or set
-    automount to false in /etc/dconf/db/local.d/00-security-settings.
+    automount to false in /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings.
     For example:
     
[org/gnome/desktop/media-handling]
     automount=false
Once the settings have been added, add a lock to - /etc/dconf/db/local.d/locks/00-security-settings-lock to prevent user modification. + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock to prevent user modification. For example:
/org/gnome/desktop/media-handling/automount
After the settings have been set, run dconf update. @@ -51,6 +51,5 @@ ocil: |-
$ gsettings get org.gnome.desktop.media-handling automount
If properly configured, the output for automount should be false. To ensure that users cannot enable automount in GNOME3, run the following: -
$ grep 'automount' /etc/dconf/db/local.d/locks/*
+
$ grep 'automount' /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/*
If properly configured, the output for automount should be /org/gnome/desktop/media-handling/automount - diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/correct_value.pass.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/correct_value.pass.sh index 7d4b240f1bef..5efc7755c127 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/correct_value.pass.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/correct_value.pass.sh @@ -8,6 +8,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings add_dconf_profiles +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "automount" "false" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "automount" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "automount" "false" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "automount" "local.d" "00-security-settings" - +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/missing_profiles.fail.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/missing_profiles.fail.sh index 4f7194e4915b..27ec3eb39bb4 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/missing_profiles.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/missing_profiles.fail.sh @@ -8,5 +8,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "automount" "false" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "automount" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "automount" "false" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "automount" "local.d" "00-security-settings" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/wrong_value.fail.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/wrong_value.fail.sh index af2b99f699e1..a6ad1796e7e2 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/wrong_value.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount/tests/wrong_value.fail.sh @@ -7,5 +7,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings add_dconf_profiles +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "automount-open" "false" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "automount-open" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "automount-open" "false" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "automount-open" "local.d" "00-security-settings" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/ansible/shared.yml index b807cc913da5..ba9b7ef40073 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/ansible/shared.yml @@ -5,7 +5,11 @@ # disruption = medium - name: "Disable GNOME3 Automounting - automount-open" community.general.ini_file: +{{% if product in ['sle15', 'sle16'] %}} + dest: /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings +{{% else %}} dest: /etc/dconf/db/local.d/00-security-settings +{{% endif %}} section: org/gnome/desktop/media-handling option: automount-open value: "false" @@ -15,20 +19,18 @@ - name: "Prevent user modification of GNOME3 Automounting - automount-open" ansible.builtin.lineinfile: +{{% if product in ['sle15', 'sle16'] %}} + path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock +{{% else %}} path: /etc/dconf/db/local.d/locks/00-security-settings-lock +{{% endif %}} regexp: '^/org/gnome/desktop/media-handling/automount-open$' line: '/org/gnome/desktop/media-handling/automount-open' create: yes register: result_lineinfile -# apply fix for enable_dconf_user_profile, OVAL checks it {{% if product in ['sle15', 'sle16'] %}} -- name: "Configure GNOME3 DConf User Profile" - ansible.builtin.lineinfile: - dest: "/etc/dconf/profile/gdm" - line: "user-db:user\nsystem-db:gdm" - create: yes - state: present +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} {{% endif %}} - name: Dconf Update diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/bash/shared.sh index fb7ce9c74e2a..8f3790bd0722 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/bash/shared.sh @@ -8,7 +8,9 @@ # apply fix for enable_dconf_user_profile, OVAL checks it {{% if product in ['sle15', 'sle16'] %}} {{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} -{{% endif %}} - +{{{ bash_dconf_settings("org/gnome/desktop/media-handling", "automount-open", "false", dconf_gdm_dir , "00-security-settings", rule_id=rule_id) }}} +{{{ bash_dconf_lock("org/gnome/desktop/media-handling", "automount-open", dconf_gdm_dir, "00-security-settings-lock") }}} +{{% else %}} {{{ bash_dconf_settings("org/gnome/desktop/media-handling", "automount-open", "false", "local.d", "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/desktop/media-handling", "automount-open", "local.d", "00-security-settings-lock") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/oval/shared.xml index d4000f292d26..be74ea547fa2 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/oval/shared.xml +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/oval/shared.xml @@ -20,7 +20,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/ +{{% else %}} /etc/dconf/db/local.d/ +{{% endif %}} ^.*$ ^\[org/gnome/desktop/media-handling\]([^\n]*\n+)+?automount-open=false$ 1 @@ -33,7 +37,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/ +{{% else %}} /etc/dconf/db/local.d/locks/ +{{% endif %}} ^.*$ ^/org/gnome/desktop/media-handling/automount-open$ 1 diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/rule.yml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/rule.yml index 1e0636944e3a..6757aeabd6d5 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/rule.yml +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/rule.yml @@ -7,12 +7,12 @@ description: |- The system's default desktop environment, GNOME3, will mount devices and removable media (such as DVDs, CDs and USB flash drives) whenever they are inserted into the system. To disable automount-open within GNOME3, add or set - automount-open to false in /etc/dconf/db/local.d/00-security-settings. + automount-open to false in /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings. For example:
[org/gnome/desktop/media-handling]
     automount-open=false
Once the settings have been added, add a lock to - /etc/dconf/db/local.d/locks/00-security-settings-lock to prevent user modification. + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock to prevent user modification. For example:
/org/gnome/desktop/media-handling/automount-open
After the settings have been set, run dconf update. @@ -52,7 +52,7 @@ ocil: |-
$ gsettings get org.gnome.desktop.media-handling automount-open
If properly configured, the output for automount-openshould be false. To ensure that users cannot enable automount opening in GNOME3, run the following: -
$ grep 'automount-open' /etc/dconf/db/local.d/locks/*
+
$ grep 'automount-open' /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/*
If properly configured, the output for automount-open should be /org/gnome/desktop/media-handling/automount-open diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/correct_value.pass.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/correct_value.pass.sh index 4539136d777d..1abf5d412314 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/correct_value.pass.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/correct_value.pass.sh @@ -8,7 +8,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings add_dconf_profiles +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "automount-open" "false" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "automount-open" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "automount-open" "false" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "automount-open" "local.d" "00-security-settings" - - +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/missing_profiles.fail.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/missing_profiles.fail.sh index 21c8d7c2f7a0..73b45031cd11 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/missing_profiles.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_automount_open/tests/missing_profiles.fail.sh @@ -8,5 +8,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "automount-open" "false" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "automount-open" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "automount-open" "false" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "automount-open" "local.d" "00-security-settings" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/ansible/shared.yml index cb6e011ff7ea..f5349391234d 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/ansible/shared.yml @@ -1,11 +1,15 @@ -# platform = multi_platform_rhel,multi_platform_fedora,multi_platform_ol,multi_platform_almalinux +# platform = multi_platform_almalinux,multi_platform_fedora,multi_platform_ol,multi_platform_rhel,multi_platform_sle # reboot = false # strategy = unknown # complexity = low # disruption = medium - name: "Disable GNOME3 Automounting - autorun-never" community.general.ini_file: +{{% if product in ['sle15', 'sle16'] %}} + dest: /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings +{{% else %}} dest: /etc/dconf/db/local.d/00-security-settings +{{% endif %}} section: org/gnome/desktop/media-handling option: autorun-never value: "true" @@ -15,7 +19,11 @@ - name: "Prevent user modification of GNOME3 Automounting - autorun-never" ansible.builtin.lineinfile: +{{% if product in ['sle15', 'sle16'] %}} + path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock +{{% else %}} path: /etc/dconf/db/local.d/locks/00-security-settings-lock +{{% endif %}} regexp: '^/org/gnome/desktop/media-handling/autorun-never$' line: '/org/gnome/desktop/media-handling/autorun-never' create: yes @@ -24,3 +32,7 @@ - name: Dconf Update ansible.builtin.command: dconf update when: result_ini is changed or result_lineinfile is changed + +{{% if product in ['sle15', 'sle16'] %}} +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/bash/shared.sh index a0f809515812..35ce8adc2d9a 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/bash/shared.sh @@ -5,5 +5,11 @@ {{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} {{% endif %}} +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{{ bash_dconf_settings("org/gnome/desktop/media-handling", "autorun-never", "true", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} +{{{ bash_dconf_lock("org/gnome/desktop/media-handling", "autorun-never", dconf_gdm_dir, "00-security-settings-lock") }}} +{{% else %}} {{{ bash_dconf_settings("org/gnome/desktop/media-handling", "autorun-never", "true", "local.d", "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/desktop/media-handling", "autorun-never", "local.d", "00-security-settings-lock") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/oval/shared.xml index 976ac69ae151..e7f55bf5d43f 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/oval/shared.xml +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/oval/shared.xml @@ -20,7 +20,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/ +{{% else %}} /etc/dconf/db/local.d/ +{{% endif %}} ^.*$ ^\[org/gnome/desktop/media-handling\]([^\n]*\n+)+?autorun-never=true$ 1 @@ -33,7 +37,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/ +{{% else %}} /etc/dconf/db/local.d/locks/ +{{% endif %}} ^.*$ ^/org/gnome/desktop/media-handling/autorun-never$ 1 diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/rule.yml b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/rule.yml index 6bd3a7d1c5cf..55fc533a287c 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/rule.yml +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/rule.yml @@ -7,12 +7,12 @@ description: |- The system's default desktop environment, GNOME3, will mount devices and removable media (such as DVDs, CDs and USB flash drives) whenever they are inserted into the system. To disable autorun-never within GNOME3, add or set - autorun-never to true in /etc/dconf/db/local.d/00-security-settings. + autorun-never to true in /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings. For example:
[org/gnome/desktop/media-handling]
     autorun-never=true
Once the settings have been added, add a lock to - /etc/dconf/db/local.d/locks/00-security-settings-lock to prevent user modification. + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock to prevent user modification. For example:
/org/gnome/desktop/media-handling/autorun-never
After the settings have been set, run dconf update. @@ -51,7 +51,7 @@ ocil: |-
$ gsettings get org.gnome.desktop.media-handling autorun-never
If properly configured, the output for autorun-nevershould be true. To ensure that users cannot enable autorun in GNOME3, run the following: -
$ grep 'autorun-never' /etc/dconf/db/local.d/locks/*
+
$ grep 'autorun-never' /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/*
If properly configured, the output for autorun-never should be /org/gnome/desktop/media-handling/autorun-never diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/correct_value.pass.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/correct_value.pass.sh index 4dc8e1444d97..35a93fead2eb 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/correct_value.pass.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/correct_value.pass.sh @@ -8,5 +8,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings add_dconf_profiles +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "autorun-never" "true" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "autorun-never" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "autorun-never" "true" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "autorun-never" "local.d" "00-security-settings" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/missing_profiles.fail.sh b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/missing_profiles.fail.sh index 85dd9a330681..a7991c7f5383 100644 --- a/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/missing_profiles.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_media_settings/dconf_gnome_disable_autorun/tests/missing_profiles.fail.sh @@ -1,5 +1,5 @@ #!/bin/bash -# platform = multi_platform_ubuntu +# platform = multi_platform_sle,multi_platform_ubuntu # packages = gdm,dconf # profiles = xccdf_org.ssgproject.content_profile_stig @@ -8,5 +8,10 @@ install_dconf_and_gdm_if_needed clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/media-handling" "autorun-never" "true" "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/media-handling" "autorun-never" "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/media-handling" "autorun-never" "true" "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/media-handling" "autorun-never" "local.d" "00-security-settings" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/ansible/shared.yml index d11221f62506..708b572f31e7 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/ansible/shared.yml @@ -5,7 +5,11 @@ # disruption = medium - name: "Require Credential Prompting for Remote Access in GNOME3" community.general.ini_file: +{{% if product in ['sle15', 'sle16'] %}} + dest: /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings +{{% else %}} dest: /etc/dconf/db/local.d/00-security-settings +{{% endif %}} section: org/gnome/Vino option: authentication-methods value: "['vnc']" @@ -15,7 +19,11 @@ - name: "Prevent user modification of GNOME3 Credential Prompting for Remote Access" ansible.builtin.lineinfile: +{{% if product in ['sle15', 'sle16'] %}} + path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock +{{% else %}} path: /etc/dconf/db/local.d/locks/00-security-settings-lock +{{% endif %}} regexp: '^/org/gnome/Vino/authentication-methods$' line: '/org/gnome/Vino/authentication-methods' create: yes @@ -24,3 +32,7 @@ - name: Dconf Update ansible.builtin.command: dconf update when: result_ini is changed or result_lineinfile is changed + +{{% if product in ['sle15', 'sle16'] %}} +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/bash/shared.sh index 872cc4bad130..f42aab8bc6a3 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/bash/shared.sh @@ -1,5 +1,10 @@ # platform = multi_platform_all - +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{{ bash_dconf_settings("org/gnome/Vino", "authentication-methods", "['vnc']", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} +{{{ bash_dconf_lock("org/gnome/Vino", "authentication-methods", dconf_gdm_dir, "00-security-settings-lock") }}} +{{% else %}} {{{ bash_dconf_settings("org/gnome/Vino", "authentication-methods", "['vnc']", "local.d", "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/Vino", "authentication-methods", "local.d", "00-security-settings-lock") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/oval/shared.xml index c92bd856aaa2..d62647da25f0 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/oval/shared.xml +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/oval/shared.xml @@ -18,7 +18,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/ +{{% else %}} /etc/dconf/db/local.d/ +{{% endif %}} ^.*$ ^\[org/gnome/Vino\]([^\n]*\n+)+?authentication-methods=\['vnc'\]$ 1 @@ -31,7 +35,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/ +{{% else %}} /etc/dconf/db/local.d/locks/ +{{% endif %}} ^.*$ ^/org/gnome/Vino/authentication-methods$ 1 diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/rule.yml b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/rule.yml index 9cd95350def2..8da990470a3b 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/rule.yml +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_credential_prompt/rule.yml @@ -7,12 +7,12 @@ description: |- By default, GNOME does not require credentials when using Vino for remote access. To configure the system to require remote credentials, add or set authentication-methods to ['vnc'] in - /etc/dconf/db/local.d/00-security-settings. For example: + /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings. For example:
[org/gnome/Vino]
     authentication-methods=['vnc']
     
Once the settings have been added, add a lock to - /etc/dconf/db/local.d/locks/00-security-settings-lock to prevent user modification. + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock to prevent user modification. For example:
/org/gnome/Vino/authentication-methods
After the settings have been set, run dconf update. @@ -41,7 +41,6 @@ ocil: |-
$ gsettings get org.gnome.Vino authentication-methods
If properly configured, the output should be false. To ensure that users cannot disable credentials for remote access, run the following: -
$ grep authentication-methods /etc/dconf/db/local.d/locks/*
+
$ grep authentication-methods /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/*
If properly configured, the output should be /org/gnome/Vino/authentication-methods - diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/ansible/shared.yml index f57ab3f7d511..e7a50cac89f6 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/ansible/shared.yml @@ -5,7 +5,11 @@ # disruption = medium - name: "Require Encryption for Remote Access in GNOME3" community.general.ini_file: +{{% if product in ['sle15', 'sle16'] %}} + dest: /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings +{{% else %}} dest: /etc/dconf/db/local.d/00-security-settings +{{% endif %}} section: org/gnome/Vino option: require-encryption value: "true" @@ -15,7 +19,11 @@ - name: "Prevent user modification of GNOME3 Encryption for Remote Access" ansible.builtin.lineinfile: +{{% if product in ['sle15', 'sle16'] %}} + path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock +{{% else %}} path: /etc/dconf/db/local.d/locks/00-security-settings-lock +{{% endif %}} regexp: '^/org/gnome/Vino/require-encryption$' line: '/org/gnome/Vino/require-encryption' create: yes @@ -24,3 +32,7 @@ - name: Dconf Update ansible.builtin.command: dconf update when: result_ini is changed or result_lineinfile is changed + +{{% if product in ['sle15', 'sle16'] %}} +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/bash/shared.sh index 51d61baf3068..944c461e081b 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/bash/shared.sh @@ -1,5 +1,10 @@ # platform = multi_platform_all - +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{{ bash_dconf_settings("org/gnome/Vino", "require-encryption", "true", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} +{{{ bash_dconf_lock("org/gnome/Vino", "require-encryption", dconf_gdm_dir, "00-security-settings-lock") }}} +{{% else %}} {{{ bash_dconf_settings("org/gnome/Vino", "require-encryption", "true", "local.d", "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/Vino", "require-encryption", "local.d", "00-security-settings-lock") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/oval/shared.xml index 39ba68f4f149..fe360890aa8e 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/oval/shared.xml +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/oval/shared.xml @@ -18,7 +18,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/ +{{% else %}} /etc/dconf/db/local.d/ +{{% endif %}} ^.*$ ^\[org/gnome/Vino\]([^\n]*\n+)+?require-encryption=true$ 1 @@ -31,7 +35,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/ +{{% else %}} /etc/dconf/db/local.d/locks/ +{{% endif %}} ^.*$ ^/org/gnome/Vino/require-encryption$ 1 diff --git a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/rule.yml b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/rule.yml index 12a8f4499433..1e3bb3e00e86 100644 --- a/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/rule.yml +++ b/linux_os/guide/system/software/gnome/gnome_remote_access_settings/dconf_gnome_remote_access_encryption/rule.yml @@ -7,12 +7,12 @@ description: |- By default, GNOME requires encryption when using Vino for remote access. To prevent remote access encryption from being disabled, add or set require-encryption to true in - /etc/dconf/db/local.d/00-security-settings. For example: + /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings. For example:
[org/gnome/Vino]
     require-encryption=true
     
Once the settings have been added, add a lock to - /etc/dconf/db/local.d/locks/00-security-settings-lock to prevent user modification. + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock to prevent user modification. For example:
/org/gnome/Vino/require-encryption
After the settings have been set, run dconf update. @@ -49,7 +49,6 @@ ocil: |-
$ gsettings get org.gnome.Vino require-encrpytion
If properly configured, the output should be true. To ensure that users cannot disable encrypted remote connections, run the following: -
$ grep require-encryption /etc/dconf/db/local.d/locks/*
+
$ grep require-encryption /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/*
If properly configured, the output should be /org/gnome/Vino/require-encryption - diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/ansible/shared.yml index dbccc97c5176..02b8b0430c14 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/ansible/shared.yml @@ -5,7 +5,11 @@ # disruption = medium - name: "Enable GNOME3 Screensaver Idle Activation" community.general.ini_file: +{{% if product in ['sle15', 'sle16'] %}} + dest: "/etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings" +{{% else %}} dest: "/etc/dconf/db/local.d/00-security-settings" +{{% endif %}} section: "org/gnome/desktop/screensaver" option: "idle-activation-enabled" value: "true" @@ -15,7 +19,11 @@ - name: "Prevent user modification of GNOME idle-activation-enabled" ansible.builtin.lineinfile: +{{% if product in ['sle15', 'sle16'] %}} + path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock +{{% else %}} path: /etc/dconf/db/local.d/locks/00-security-settings-lock +{{% endif %}} regexp: '^/org/gnome/desktop/screensaver/idle-activation-enabled$' line: '/org/gnome/desktop/screensaver/idle-activation-enabled' create: yes @@ -24,3 +32,7 @@ - name: Dconf Update ansible.builtin.command: dconf update when: result_ini is changed or result_lineinfile is changed + +{{% if product in ['sle15', 'sle16'] %}} +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/bash/shared.sh index 571567335263..31ee53228b9b 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/bash/shared.sh @@ -1,5 +1,10 @@ # platform = multi_platform_all - +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{{ bash_dconf_settings("org/gnome/desktop/screensaver", "idle-activation-enabled", "true", dconf_gdm_dir , "00-security-settings", rule_id=rule_id) }}} +{{{ bash_dconf_lock("org/gnome/desktop/screensaver", "idle-activation-enabled", dconf_gdm_dir, "00-security-settings-lock") }}} +{{% else %}} {{{ bash_dconf_settings("org/gnome/desktop/screensaver", "idle-activation-enabled", "true", "local.d", "00-security-settings", rule_id=rule_id) }}} {{{ bash_dconf_lock("org/gnome/desktop/screensaver", "idle-activation-enabled", "local.d", "00-security-settings-lock") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/oval/shared.xml index 849b09080d2a..7ed4cdd67f84 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/oval/shared.xml +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/oval/shared.xml @@ -18,7 +18,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/ +{{% else %}} /etc/dconf/db/local.d/ +{{% endif %}} ^.*$ ^\[org/gnome/desktop/screensaver\]([^\n]*\n+)+?idle-activation-enabled=true$ 1 @@ -31,7 +35,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/ +{{% else %}} /etc/dconf/db/local.d/locks/ +{{% endif %}} ^.*$ ^/org/gnome/desktop/screensaver/idle-activation-enabled$ 1 diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/rule.yml b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/rule.yml index c2d48df41ac4..dfc2874675d3 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/rule.yml +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/rule.yml @@ -6,11 +6,11 @@ title: 'Enable GNOME3 Screensaver Idle Activation' description: |- To activate the screensaver in the GNOME3 desktop after a period of inactivity, add or set idle-activation-enabled to true in - /etc/dconf/db/local.d/00-security-settings. For example: + /etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings. For example:
[org/gnome/desktop/screensaver]
     idle-activation-enabled=true
Once the setting has been added, add a lock to - /etc/dconf/db/local.d/locks/00-security-settings-lock to prevent user modification. + /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock to prevent user modification. For example:
/org/gnome/desktop/screensaver/idle-activation-enabled
After the settings have been set, run dconf update. @@ -59,6 +59,5 @@ ocil: |-
$ gsettings get org.gnome.desktop.screensaver idle-activation-enabled
If properly configured, the output should be true. To ensure that users cannot disable the screensaver idle inactivity setting, run the following: -
$ grep idle-activation-enabled /etc/dconf/db/local.d/locks/*
+
$ grep idle-activation-enabled /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/*
If properly configured, the output should be /org/gnome/desktop/screensaver/idle-activation-enabled - diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/comment.fail.sh b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/comment.fail.sh index e8ff2ac2955c..5d205dd8d052 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/comment.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/comment.fail.sh @@ -4,7 +4,14 @@ . $SHARED/dconf_test_functions.sh clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/screensaver" "#idle-activation-enabled" "true" \ + "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/screensaver" "idle-activation-enabled" "{{{ dconf_gdm_dir }}}" \ + "00-security-settings-lock" +{{% else %}} add_dconf_setting "org/gnome/desktop/screensaver" "#idle-activation-enabled" "true" \ "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/screensaver" "idle-activation-enabled" "local.d" \ "00-security-settings-lock" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/correct_value.pass.sh b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/correct_value.pass.sh index 3d7cfa54c6d2..17cd6d979b5c 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/correct_value.pass.sh +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/correct_value.pass.sh @@ -4,7 +4,15 @@ . $SHARED/dconf_test_functions.sh clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_profiles +add_dconf_setting "org/gnome/desktop/screensaver" "idle-activation-enabled" "true" \ + "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/screensaver" "idle-activation-enabled" "{{{ dconf_gdm_dir }}}" \ + "00-security-settings-lock" +{{% else %}} add_dconf_setting "org/gnome/desktop/screensaver" "idle-activation-enabled" "true" \ "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/screensaver" "idle-activation-enabled" "local.d" \ "00-security-settings-lock" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/missing_lock.fail.sh b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/missing_lock.fail.sh index 5cfef8b62db8..831bb770d9b5 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/missing_lock.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/missing_lock.fail.sh @@ -4,5 +4,10 @@ . $SHARED/dconf_test_functions.sh clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/screensaver" "idle-activation-enabled" "true" \ + "{{{ dconf_gdm_dir }}}" "00-security-settings" +{{% else %}} add_dconf_setting "org/gnome/desktop/screensaver" "idle-activation-enabled" "true" \ "local.d" "00-security-settings" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/wrong_value.fail.sh b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/wrong_value.fail.sh index 76b9088c85f5..88027535c535 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/wrong_value.fail.sh +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_activation_enabled/tests/wrong_value.fail.sh @@ -4,7 +4,14 @@ . $SHARED/dconf_test_functions.sh clean_dconf_settings +{{% if product in ['sle15', 'sle16'] %}} +add_dconf_setting "org/gnome/desktop/screensaver" "idle-activation-enabled" "false" \ + "{{{ dconf_gdm_dir }}}" "00-security-settings" +add_dconf_lock "org/gnome/desktop/screensaver" "idle-activation-enabled" "{{{ dconf_gdm_dir }}}" \ + "00-security-settings-lock" +{{% else %}} add_dconf_setting "org/gnome/desktop/screensaver" "idle-activation-enabled" "false" \ "local.d" "00-security-settings" add_dconf_lock "org/gnome/desktop/screensaver" "idle-activation-enabled" "local.d" \ "00-security-settings-lock" +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/ansible/shared.yml b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/ansible/shared.yml index 78360c115b16..a1e43dcd17e6 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/ansible/shared.yml +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/ansible/shared.yml @@ -7,7 +7,11 @@ - name: "Set GNOME3 Screensaver Inactivity Timeout" community.general.ini_file: +{{% if product in ['sle15', 'sle16'] %}} + dest: "/etc/dconf/db/{{{ dconf_gdm_dir }}}/00-security-settings" +{{% else %}} dest: "/etc/dconf/db/local.d/00-security-settings" +{{% endif %}} section: "org/gnome/desktop/session" option: idle-delay value: "uint32 {{ inactivity_timeout_value }}" @@ -15,6 +19,28 @@ no_extra_spaces: yes register: result_ini +{{% if 'ubuntu' in product or product in ["sle15", "sle16"] %}} +- name: "Prevent user modification of GNOME Screensaver Inactivity Timeout" + ansible.builtin.lineinfile: +{{% if product in ['sle15', 'sle16'] %}} + path: /etc/dconf/db/{{{ dconf_gdm_dir }}}/locks/00-security-settings-lock +{{% else %}} + path: /etc/dconf/db/local.d/locks/00-security-settings-lock +{{% endif %}} + regexp: '^/org/gnome/desktop/session/idle-delay$' + line: '/org/gnome/desktop/session/idle-delay' + create: yes + register: result_lineinfile +{{% endif %}} + - name: Dconf Update ansible.builtin.command: dconf update +{{% if 'ubuntu' in product or product in ["sle15", "sle16"] %}} + when: result_ini is changed or result_lineinfile is changed +{{% else %}} when: result_ini is changed +{{% endif %}} + +{{% if product in ['sle15', 'sle16'] %}} +{{{ ansible_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/bash/shared.sh b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/bash/shared.sh index de0854c03f83..48fbd7b92677 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/bash/shared.sh +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/bash/shared.sh @@ -6,6 +6,15 @@ {{{ bash_dconf_lock("org/gnome/desktop/session", "idle-delay", "local.d", "00-security-settings-lock") }}} {{% endif %}} +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_enable_dconf_user_profile(profile="gdm", database="gdm") }}} +{{{ bash_dconf_lock("org/gnome/desktop/session", "idle-delay", dconf_gdm_dir, "00-security-settings-lock") }}} +{{% endif %}} + {{{ bash_instantiate_variables("inactivity_timeout_value") }}} +{{% if product in ['sle15', 'sle16'] %}} +{{{ bash_dconf_settings("org/gnome/desktop/session", "idle-delay", "uint32 ${inactivity_timeout_value}", dconf_gdm_dir, "00-security-settings", rule_id=rule_id) }}} +{{% else %}} {{{ bash_dconf_settings("org/gnome/desktop/session", "idle-delay", "uint32 ${inactivity_timeout_value}", "local.d", "00-security-settings", rule_id=rule_id) }}} +{{% endif %}} diff --git a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/oval/shared.xml b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/oval/shared.xml index a4173903a2c2..5108cdd21a2a 100644 --- a/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/oval/shared.xml +++ b/linux_os/guide/system/software/gnome/gnome_screen_locking/dconf_gnome_screensaver_idle_delay/oval/shared.xml @@ -7,7 +7,7 @@ - {{% if 'ubuntu' in product %}} + {{% if 'ubuntu' in product or product in ["sle15", "sle16"] %}} {{% endif %}} @@ -21,7 +21,11 @@ +{{% if product in ['sle15', 'sle16'] %}} + /etc/dconf/db/{{{ dconf_gdm_dir }}}/ +{{% else %}} /etc/dconf/db/local.d/ +{{% endif %}} ^.*$ diff --git a/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/oval/shared.xml b/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/oval/shared.xml index a028877c12a7..f9d3127a311e 100644 --- a/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/oval/shared.xml @@ -5,9 +5,11 @@ ", rule_title=rule_title) }}} + + @@ -16,6 +18,7 @@ + diff --git a/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/rule.yml b/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/rule.yml index a7a47148ab0d..35e234c7d031 100644 --- a/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/rule.yml +++ b/linux_os/guide/system/software/integrity/certified-vendor/installed_OS_is_vendor_supported/rule.yml @@ -60,7 +60,7 @@ ocil_clause: 'the installed operating system is not supported' ocil: |- To verify that the installed operating system is supported, run the following command: -{{% if product.startswith("rhel") %}} +{{% if product.startswith("rhel") or product == "hummingbird" %}}
$ grep -i "red hat" /etc/redhat-release
{{% elif 'ol' in families %}}
$ grep -i "oracle" /etc/oracle-release
diff --git a/linux_os/guide/system/software/integrity/crypto/configure_bind_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_bind_crypto_policy/rule.yml index 104c9a9ac28f..25d2d0206bba 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_bind_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_bind_crypto_policy/rule.yml @@ -30,7 +30,7 @@ references: nerc-cip: CIP-003-8 R4.2,CIP-007-3 R5.1 nist: SC-13,SC-12(2),SC-12(3) srg: SRG-OS-000423-GPOS-00187,SRG-OS-000426-GPOS-00190 - stigid@ol8: OL08-00-010020 + stigid@ol8: OL08-00-010020,OL08-00-010187 ocil_clause: |- BIND is installed and the BIND config file doesn't contain the diff --git a/linux_os/guide/system/software/integrity/crypto/configure_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_crypto_policy/rule.yml index 2800415a2f58..11bbd91c8b83 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_crypto_policy/rule.yml @@ -4,6 +4,7 @@ documentation_complete: true title: 'Configure System Cryptography Policy' description: |- + {{% if product != "hummingbird" -%}} To configure the system cryptography policy to use ciphers only from the {{{ xccdf_value("var_system_crypto_policy") }}} {{% if product != "rhcos4" -%}} policy, run the following command: @@ -42,6 +43,7 @@ description: |-

{{{ machineconfig_description_footer() | indent(4) }}} {{% endif -%}} + {{% endif -%}} The rule checks if settings for selected crypto policy are configured as expected. Configuration files in the /etc/crypto-policies/back-ends are either symlinks to correct files provided by Crypto-policies package or they are regular files in case crypto policy customizations are applied. Crypto policies may be customized by crypto policy modules, in which case it is delimited from the base policy using a colon. @@ -66,7 +68,7 @@ references: nist: AC-17(a),AC-17(2),CM-6(a),MA-4(6),SC-13,SC-12(2),SC-12(3) ospp: FCS_COP.1(1),FCS_COP.1(2),FCS_COP.1(3),FCS_COP.1(4),FCS_CKM.1,FCS_CKM.2,FCS_TLSC_EXT.1 srg: SRG-OS-000396-GPOS-00176,SRG-OS-000393-GPOS-00173,SRG-OS-000394-GPOS-00174 - stigid@ol8: OL08-00-010020 + stigid@ol8: OL08-00-010020,OL08-00-010183,OL08-00-010181 ocil_clause: 'cryptographic policy is not configured or is configured incorrectly' @@ -86,8 +88,10 @@ ocil: |- Outputs of two previous commands should match. warnings: + {{% if product != "hummingbird" -%}} - general: |- The system needs to be rebooted for these changes to take effect. + {{% endif -%}} - regulatory: |- System Crypto Modules must be provided by a vendor that undergoes FIPS-140 certifications. diff --git a/linux_os/guide/system/software/integrity/crypto/configure_custom_crypto_policy_cis/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_custom_crypto_policy_cis/rule.yml index b80f01777048..434f5e6c227a 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_custom_crypto_policy_cis/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_custom_crypto_policy_cis/rule.yml @@ -52,7 +52,22 @@ title: Implement Custom Crypto Policy Modules for CIS Benchmark { "module_name": "NO-RPMSHA1", "key": "hash@rpm", - "value": "-SHA1" + "value": "-SHA1", + "scope": "rpm-sequoia" + }, +] %}} +{{% elif product == "almalinux9" %}} +{{% set base_policy = "DEFAULT:NO-SHA1" %}} +{{% set sub_policies = [ + { + "module_name": "NO-WEAKMAC", + "key": "mac", + "value": "-*-64*" + }, + { + "module_name": "NO-SSHCBC", + "key": "cipher@SSH", + "value": "-*-CBC" }, ] %}} {{% elif product == "rhel10" or product == "fedora" %}} diff --git a/linux_os/guide/system/software/integrity/crypto/configure_gnutls_tls_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_gnutls_tls_crypto_policy/rule.yml index 2305601e885b..849d62a869ed 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_gnutls_tls_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_gnutls_tls_crypto_policy/rule.yml @@ -29,7 +29,6 @@ identifiers: references: nist: AC-17(2) srg: SRG-OS-000250-GPOS-00093,SRG-OS-000423-GPOS-00187 - stigid@ol8: OL08-00-010295 ocil_clause: 'cryptographic policy for gnutls is not configured or is configured incorrectly' diff --git a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/rule.yml index 12aafb03c75d..78d347a00bd2 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/rule.yml @@ -43,3 +43,5 @@ fixtext: |- $ sudo ln -s /etc/crypto-policies/back-ends/krb5.config /etc/krb5.conf.d/crypto-policies srg_requirement: '{{{ full_name }}} must implement NIST FIPS-validated cryptography for the following: to provision digital signatures, to generate cryptographic hashes, and to protect data requiring data-at-rest protections in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards.' + +platform: package[krb5-libs] diff --git a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_correct_policy.pass.sh b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_correct_policy.pass.sh index 4834387dcdb0..55d78ced431c 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_correct_policy.pass.sh +++ b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_correct_policy.pass.sh @@ -1,5 +1,5 @@ #!/bin/bash -# platform = multi_platform_fedora,Oracle Linux 8,Oracle Linux 9,Red Hat Enterprise Linux 8,Red Hat Enterprise Linux 9 +# platform = multi_platform_fedora,Oracle Linux 8,Oracle Linux 9,multi_platform_rhel rm -f /etc/krb5.conf.d/crypto-policies ln -s /etc/crypto-policies/back-ends/krb5.config /etc/krb5.conf.d/crypto-policies diff --git a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_missing_policy.fail.sh b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_missing_policy.fail.sh index 97ccc05908c9..f84eb9de6f7e 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_missing_policy.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_missing_policy.fail.sh @@ -1,4 +1,4 @@ #!/bin/bash -# platform = multi_platform_fedora,Oracle Linux 8,Oracle Linux 9,Red Hat Enterprise Linux 8,Red Hat Enterprise Linux 9 +# platform = multi_platform_fedora,Oracle Linux 8,Oracle Linux 9,multi_platform_rhel rm -f /etc/krb5.conf.d/crypto-policies diff --git a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_wrong_policy.fail.sh b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_wrong_policy.fail.sh index 4eb5348f28a2..25c649123a57 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_wrong_policy.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/configure_kerberos_crypto_policy/tests/kerberos_wrong_policy.fail.sh @@ -1,5 +1,5 @@ #!/bin/bash -# platform = multi_platform_fedora,Oracle Linux 8,Oracle Linux 9,Red Hat Enterprise Linux 8,Red Hat Enterprise Linux 9 +# platform = multi_platform_fedora,Oracle Linux 8,Oracle Linux 9,multi_platform_rhel rm -f /etc/krb5.conf.d/crypto-policies ln -s /etc/crypto-policies/back-ends/openssh.config /etc/krb5.conf.d/crypto-policies diff --git a/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/policy/stig/shared.yml b/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/policy/stig/shared.yml index 9b006ce61dbf..a93243cfcef1 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/policy/stig/shared.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/policy/stig/shared.yml @@ -7,7 +7,7 @@ vuldiscussion: |- checktext: |- Verify that the IPsec service uses the system crypto policy with the following command: - Note: If the ipsec service is not installed, this requirement is Not Applicable. + Note: If the IPsec service is not installed, this requirement is not applicable. $ sudo grep include /etc/ipsec.conf /etc/ipsec.d/*.conf diff --git a/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/rule.yml index 8a14c3de7d55..6329b0864f0d 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_libreswan_crypto_policy/rule.yml @@ -34,15 +34,15 @@ references: nist: CM-6(a),MA-4(6),SC-13,SC-12(2),SC-12(3) pcidss: Req-2.2 srg: SRG-OS-000033-GPOS-00014 - stigid@ol8: OL08-00-010020 + stigid@ol8: OL08-00-010020,OL08-00-010186 ocil_clause: |- the "IPsec" service is active and the ipsec configuration file does not contain does not contain include /etc/crypto-policies/back-ends/libreswan.config ocil: |- - Verify that the IPSec service uses the system crypto policy. + Verify that the IPsec service uses the system crypto policy. - If the ipsec service is not installed is not applicable. + If the IPsec service is not installed, this requirement is not applicable. Check to see if the "IPsec" service is active with the following command: @@ -67,4 +67,4 @@ fixtext: |- srg_requirement: '{{{ full_name }}} must implement NIST FIPS-validated cryptography for the following: to provision digital signatures, to generate cryptographic hashes, and to protect data requiring data-at-rest protections in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards.' -platform: system_with_kernel +platform: system_with_kernel and package[libreswan] diff --git a/linux_os/guide/system/software/integrity/crypto/configure_openssl_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_openssl_crypto_policy/rule.yml index 6f08e01c1a3d..afb6790bbdfb 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_openssl_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_openssl_crypto_policy/rule.yml @@ -65,3 +65,5 @@ fixtext: |- srg_requirement: |- {{{ full_name }}} must implement approved encryption in the OpenSSL package. + +platform: package[openssl] diff --git a/linux_os/guide/system/software/integrity/crypto/configure_openssl_tls_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_openssl_tls_crypto_policy/rule.yml index f82c35566452..af136814fa7a 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_openssl_tls_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_openssl_tls_crypto_policy/rule.yml @@ -43,7 +43,6 @@ identifiers: references: nist: AC-17(2) srg: SRG-OS-000125-GPOS-00065,SRG-OS-000250-GPOS-00093,SRG-OS-000393-GPOS-00173,SRG-OS-000394-GPOS-00174 - stigid@ol8: OL08-00-010294 ocil_clause: 'cryptographic policy for openssl is not configured or is configured incorrectly' @@ -68,3 +67,5 @@ warnings: srg_requirement: |- {{{ full_name }}} must use at minimum TLSv1.2 for TLS connections. + +platform: package[openssl] diff --git a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/ansible/shared.yml b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/ansible/shared.yml index cfbff70b845c..65dccf57d6e7 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/ansible/shared.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/ansible/shared.yml @@ -6,6 +6,6 @@ - name: "{{{ rule_title }}}" ansible.builtin.lineinfile: - dest: /etc/sysconfig/sshd + dest: '{{{ sshd_sysconfig_file }}}' state: absent regexp: (?i)^\s*CRYPTO_POLICY.*$ diff --git a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/bash/shared.sh index 2a04f5ea6bc0..8066e15c264a 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/bash/shared.sh +++ b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/bash/shared.sh @@ -1,5 +1,5 @@ # platform = multi_platform_all -SSH_CONF="/etc/sysconfig/sshd" +SSH_CONF="{{{ sshd_sysconfig_file }}}" sed -i "/^\s*CRYPTO_POLICY.*$/Id" $SSH_CONF diff --git a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/oval/shared.xml index e51181528eb3..0265d746b9ab 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/oval/shared.xml @@ -1,3 +1,4 @@ +{{%- set sshd_sysconfig = sshd_sysconfig_file -%}} {{{ oval_metadata("SSH should be configured to use the system-wide crypto policy setting.", rule_title=rule_title) }}} @@ -14,7 +15,7 @@ - /etc/sysconfig/sshd + {{{ sshd_sysconfig }}} ^\s*(?i)CRYPTO_POLICY\s*=.*$ 1 diff --git a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/rule.yml index 7e722ab1170f..a9c819fde913 100644 --- a/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/configure_ssh_crypto_policy/rule.yml @@ -1,4 +1,5 @@ documentation_complete: true +{{% set sshd_sysconfig = sshd_sysconfig_file %}} title: 'Configure SSH to use System Crypto Policy' @@ -9,7 +10,7 @@ description: |- set up to ignore it. To check that Crypto Policies settings are configured correctly, ensure that the CRYPTO_POLICY variable is either commented or not set at all - in the /etc/sysconfig/sshd. + in the {{{ sshd_sysconfig }}}. rationale: |- Overriding the system crypto policy makes the behavior of the SSH service violate expectations, @@ -32,25 +33,24 @@ references: ospp: FCS_SSH_EXT.1,FCS_SSHS_EXT.1,FCS_SSHC_EXT.1 pcidss: Req-2.2 srg: SRG-OS-000250-GPOS-00093 - stigid@ol8: OL08-00-010287 -ocil_clause: 'the CRYPTO_POLICY variable is set or is not commented out in the /etc/sysconfig/sshd' +ocil_clause: 'the CRYPTO_POLICY variable is set or is not commented out in {{{ sshd_sysconfig }}}' ocil: |- Verify that sshd isn't configured to ignore the system wide cryptographic policy. Check that the CRYPTO_POLICY variable is not set or is commented out in the - /etc/sysconfig/sshd. + {{{ sshd_sysconfig }}}. Run the following command: - $ sudo grep CRYPTO_POLICY /etc/sysconfig/sshd + $ sudo grep CRYPTO_POLICY {{{ sshd_sysconfig }}} fixtext: |- Configure OpenSSH to not ignore the system wide cryptographic policy. Run the following command: - $ sudo sed -i "/^\s*CRYPTO_POLICY.*$/Id" /etc/sysconfig/sshd + $ sudo sed -i "/^\s*CRYPTO_POLICY.*$/Id" {{{ sshd_sysconfig }}} srg_requirement: |- {{{ full_name }}} must implement approved encryption in the OpenSSH package. diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_legacy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_legacy/oval/shared.xml new file mode 100644 index 000000000000..9ccf7a882d1a --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_legacy/oval/shared.xml @@ -0,0 +1,86 @@ + + + {{{ oval_metadata("Ensure crypto policy is correctly configured in /etc/crypto-policies/config, and the policy is current.", rule_title=rule_title) }}} + + + + + + + + + + /etc/crypto-policies/state/current + + + + /etc/crypto-policies/config + + + + + + + + + + + + + + + + + variable_{{{ rule_id }}}_crypto_policies_config_file_timestamp + + + + + + + + + + + + + /etc/crypto-policies/config + ^(?!#)(\S+)$ + 1 + + + + LEGACY + + + + + + + + + /etc/crypto-policies/state/current + ^(?!#)(\S+)$ + 1 + + + + LEGACY + + + + + + + /etc/crypto-policies/back-ends/nss.config + + + diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_legacy/rule.yml b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_legacy/rule.yml new file mode 100644 index 000000000000..b32eea925b14 --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_legacy/rule.yml @@ -0,0 +1,68 @@ +documentation_complete: true + +title: Ensure system wide crypto policy is not set to legacy + +description: >- + When a system-wide policy is set up, the default behavior of applications will be to + follow the policy. Applications will be unable to use algorithms and protocols that do not + meet the policy, unless you explicitly request the application to do so. + + The system-wide crypto-policies followed by the crypto core components allow + consistently deprecating and disabling algorithms system-wide. + The LEGACY policy ensures maximum compatibility with legacy systems at the cost + of being less secure. It allows the TLS 1.2, and TLS 1.3 protocols, as well as IKEv2 and + SSH2. DSA is not allowed, while RSA and Diffie-Hellman parameters are accepted if no + less than 2048 bits. This policy provides at least 80-bit security. + + The rule checks if settings for selected crypto policy are configured as expected. + Configuration files in the /etc/crypto-policies/back-ends are either symlinks + to correct files provided by crypto-policies package or they are regular files in case + crypto policy customizations are applied. Crypto policies may be customized by crypto + policy modules, in which case it is delimited from the base policy using a colon. + +rationale: >- + Centralized cryptographic policies simplify applying secure ciphers across an operating system and + the applications that run on that operating system. Use of weak or untested encryption algorithms + undermines the purposes of utilizing encryption to protect data. + The LEGACY system-wide crypto policy includes support for outdated and weakened + algorithms to ensure maximum compatibility with Red Hat Enterprise Linux 6 and + earlier; it is less secure due to an increased attack surface. + +severity: high + +ocil_clause: 'cryptographic policy is set to LEGACY' + +ocil: |- + To verify that cryptography policy has been configured correctly, run the + following command: +
$ update-crypto-policies --show
+ The output should not return
LEGACY
. + Run the command to check if the policy is correctly applied: +
$ update-crypto-policies --is-applied
+ The output should be
The configured policy is applied
. + Moreover, check if settings for selected crypto policy are as expected. + List all libraries for which it holds that their crypto policies do not have + symbolic link in
/etc/crypto-policies/back-ends
. +
$ ls -l /etc/crypto-policies/back-ends/ | grep '^[^l]' | tail -n +2 | awk -F' ' '{print $NF}' | awk -F'.' '{print $1}' | sort
+ Subsequently, check if matching libraries have drop in files in the
/etc/crypto-policies/local.d
directory. +
$ ls /etc/crypto-policies/local.d/ | awk -F'-' '{print $1}' | uniq | sort
+ Outputs of two previous commands should match. + +warnings: + - regulatory: |- + System Crypto Modules must be provided by a vendor that undergoes + FIPS-140 certifications. + FIPS-140 is applicable to all Federal agencies that use + cryptographic-based security systems to protect sensitive information + in computer and telecommunication systems (including voice systems) as + defined in Section 5131 of the Information Technology Management Reform + Act of 1996, Public Law 104-106. This standard shall be used in + designing and implementing cryptographic modules that Federal + departments and agencies operate or are operated for them under + contract. See {{{ weblink(link="https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.140-2.pdf") }}} + To meet this, the system has to have cryptographic software provided by + a vendor that has undergone this certification. This means providing + documentation, test results, design information, and independent third + party review by an accredited lab. While open source software is + capable of meeting this, it does not meet FIPS-140 unless the vendor + submits to this process. diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/ansible/shared.yml b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/ansible/shared.yml new file mode 100644 index 000000000000..f40a28b4d825 --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/ansible/shared.yml @@ -0,0 +1,22 @@ +# platform = multi_platform_all +# reboot = false +# strategy = configure +# complexity = low +# disruption = low +{{{ ansible_instantiate_variables("var_system_crypto_policy") }}} + +- name: "{{{ rule_title }}} - Check if crypto policy is overridden" + ansible.builtin.command: /usr/bin/update-crypto-policies --check + register: crypto_policy_check + changed_when: false + failed_when: false + check_mode: false + +- name: "{{{ rule_title }}} - Ensure crypto-policies-scripts package is installed" + ansible.builtin.package: + name: crypto-policies-scripts + state: present + +- name: "{{{ rule_title }}} - Re-apply crypto policy" + ansible.builtin.command: /usr/bin/update-crypto-policies --set {{ var_system_crypto_policy }} + when: crypto_policy_check.rc != 0 diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/bash/shared.sh new file mode 100644 index 000000000000..fef5ce2157d5 --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/bash/shared.sh @@ -0,0 +1,23 @@ +# platform = multi_platform_all +# reboot = false +# strategy = configure +# complexity = low +# disruption = low + +{{{ bash_instantiate_variables("var_system_crypto_policy") }}} + +{{{ bash_package_install("crypto-policies-scripts") }}} + +stderr_of_call=$(update-crypto-policies --set "${var_system_crypto_policy}" 2>&1 > /dev/null) +rc=$? + +if test "$rc" = 127; then + echo "$stderr_of_call" >&2 + echo "Make sure that the script is installed on the remediated system." >&2 + echo "See output of the 'dnf provides update-crypto-policies' command" >&2 + echo "to see what package to (re)install" >&2 + false +elif test "$rc" != 0; then + echo "Error invoking the update-crypto-policies script: $stderr_of_call" >&2 + false +fi diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/rule.yml b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/rule.yml new file mode 100644 index 000000000000..c6b239f06f71 --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/rule.yml @@ -0,0 +1,41 @@ +documentation_complete: true + +title: 'Ensure System Cryptographic Policy Is Not Overridden' + +description: |- + The system-wide cryptographic policy must not be overridden by individual + applications. All files in /etc/crypto-policies/back-ends/ except for + nss.config should be symbolic links generated by the + update-crypto-policies tool. + Verify that the configured cryptographic policy has not been overridden by running: +
$ sudo update-crypto-policies --check
+ The output should confirm the configured policy matches the generated policy. + +rationale: |- + Centralized cryptographic policies simplify applying secure ciphers across an + operating system and the applications that run on that operating system. If + cryptographic policy back-end configurations are overridden, the system may use + weak or unapproved cipher suites, undermining the intended security posture. + +severity: medium + +identifiers: + cce@rhel9: CCE-86483-5 + +references: + srg: SRG-OS-000396-GPOS-00176,SRG-OS-000393-GPOS-00173,SRG-OS-000394-GPOS-00174 + +ocil_clause: 'the configured policy does not match the generated policy' + +ocil: |- + Verify that the cryptographic policy has not been overridden by running: +
$ sudo update-crypto-policies --check
+ If compliant, the output confirms the configured policy matches the generated policy. + +platform: system_with_kernel and not osbuild + +warnings: + - general: |- + This rule only contains SCE (Script Check Engine) content. The package + openscap-engine-sce must be installed on the target system for + the check to work. diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/sce/shared.sh b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/sce/shared.sh new file mode 100644 index 000000000000..edeae200b3da --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/sce/shared.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash +# platform = multi_platform_rhel,multi_platform_fedora,Oracle Linux 8,Oracle Linux 9 +# check-import = stdout + +update-crypto-policies --check +rc=$? + +if [ $rc -eq 0 ]; then + exit "${XCCDF_RESULT_PASS}" +fi + +exit "${XCCDF_RESULT_FAIL}" diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/backend_file_overridden.fail.sh b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/backend_file_overridden.fail.sh new file mode 100644 index 000000000000..ef5cdd8dd7b8 --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/backend_file_overridden.fail.sh @@ -0,0 +1,15 @@ +#!/bin/bash +# platform = multi_platform_rhel,multi_platform_fedora,Oracle Linux 8,Oracle Linux 9 +# packages = crypto-policies-scripts,openscap-engine-sce + +# Start from a clean, fully applied state +update-crypto-policies --set DEFAULT + +# Replace the gnutls backend symlink with a modified regular file to simulate +# a manual per-application override of the system crypto policy. +# update-crypto-policies --check regenerates the policy and byte-compares it +# against the back-ends directory, so any content change causes a failure. +BACKEND_FILE="/etc/crypto-policies/back-ends/gnutls.config" +content=$(cat "${BACKEND_FILE}") +rm -f "${BACKEND_FILE}" +printf '%s\n# manual override\n' "${content}" > "${BACKEND_FILE}" diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/config_changed_not_applied.fail.sh b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/config_changed_not_applied.fail.sh new file mode 100644 index 000000000000..f4166cbddcee --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/config_changed_not_applied.fail.sh @@ -0,0 +1,12 @@ +#!/bin/bash +# platform = multi_platform_rhel,multi_platform_fedora,Oracle Linux 8,Oracle Linux 9 +# packages = crypto-policies-scripts,openscap-engine-sce + +# Start from a clean, fully applied DEFAULT state +update-crypto-policies --set DEFAULT + +# Change the config to a different policy without running update-crypto-policies. +# --check regenerates the policy from /etc/crypto-policies/config (now LEGACY) +# and compares it against the back-ends still generated for DEFAULT, so they +# will not match. +echo "LEGACY" > /etc/crypto-policies/config diff --git a/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/correct_policy_applied.pass.sh b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/correct_policy_applied.pass.sh new file mode 100644 index 000000000000..1c0443bdcd6e --- /dev/null +++ b/linux_os/guide/system/software/integrity/crypto/crypto_policy_not_overridden/tests/correct_policy_applied.pass.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = multi_platform_rhel,multi_platform_fedora,Oracle Linux 8,Oracle Linux 9 +# packages = crypto-policies-scripts,openscap-engine-sce + +# Ensure the crypto policy is set and fully applied so --check passes +update-crypto-policies --set DEFAULT diff --git a/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/bash/shared.sh index 61cd291a5c59..bbc1f53d7c8d 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/bash/shared.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/bash/shared.sh @@ -1,7 +1,8 @@ # platform = multi_platform_all #the file starts with 02 so that it is loaded before the 05-redhat.conf which activates configuration provided by system vide crypto policy -file="/etc/ssh/ssh_config.d/02-ospp.conf" +{{% set sshc_crypto_policy_config = ssh_client_config_dir ~ "/02-ospp.conf" %}} +file="{{{ sshc_crypto_policy_config }}}" echo -e "Match final all\n\ RekeyLimit 512M 1h\n\ GSSAPIAuthentication no\n\ diff --git a/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/oval/shared.xml index f1227c5ef087..8700fda2e8be 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/oval/shared.xml @@ -4,6 +4,7 @@ #}} {{%- set suffix_id_default_not_overriden = "_default_not_overriden" -%}} {{%- set common_prefix_regex = "^Match final all(?:.*\n)*?\s*" -%}} +{{%- set sshc_crypto_policy_config = ssh_client_config_dir ~ "/02-ospp.conf" -%}} @@ -131,43 +132,43 @@ - {{{ oval_metadata("Ensure the ssh client ciphers are configured correctly in /etc/ssh/ssh_config.d/02-ospp.conf", rule_title=rule_title) }}} + {{{ oval_metadata("Ensure the ssh client ciphers are configured correctly in " ~ sshc_crypto_policy_config, rule_title=rule_title) }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='Match') }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='RekeyLimit') }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='GSSAPIAuthentication') }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='Ciphers') }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='PubkeyAcceptedKeyTypes') }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='MACs') }}} - {{{ hsccp_oval_line_in_file_criterion(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='KexAlgorithms') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='Match') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='RekeyLimit') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='GSSAPIAuthentication') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='Ciphers') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='PubkeyAcceptedKeyTypes') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='MACs') }}} + {{{ hsccp_oval_line_in_file_criterion(path=sshc_crypto_policy_config, parameter='KexAlgorithms') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='Match', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='Match', separator_regex='[\s]+', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='Match', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='Match', separator_regex='[\s]+', missing_parameter_pass=false) }}} {{{ hsccp_oval_line_in_file_state(parameter='Match', value='final all') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='RekeyLimit', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='RekeyLimit', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='RekeyLimit', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='RekeyLimit', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} {{{ hsccp_oval_line_in_file_state(parameter='RekeyLimit', value='512M 1h') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='GSSAPIAuthentication', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='GSSAPIAuthentication', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='GSSAPIAuthentication', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='GSSAPIAuthentication', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} {{{ hsccp_oval_line_in_file_state(parameter='GSSAPIAuthentication', value='no') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='Ciphers', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='Ciphers', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='Ciphers', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='Ciphers', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} {{{ hsccp_oval_line_in_file_state(parameter='Ciphers', value='aes256-ctr,aes256-cbc,aes128-ctr,aes128-cbc') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='PubkeyAcceptedKeyTypes', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='PubkeyAcceptedKeyTypes', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='PubkeyAcceptedKeyTypes', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='PubkeyAcceptedKeyTypes', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} {{{ hsccp_oval_line_in_file_state(parameter='PubkeyAcceptedKeyTypes', value='ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='MACs', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='MACs', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='MACs', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='MACs', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} {{{ hsccp_oval_line_in_file_state(parameter='MACs', value='hmac-sha2-512,hmac-sha2-256') }}} - {{{ hsccp_oval_line_in_file_test(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='KexAlgorithms', missing_parameter_pass=false) }}} - {{{ hsccp_oval_line_in_file_object(path='/etc/ssh/ssh_config.d/02-ospp.conf', parameter='KexAlgorithms', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} + {{{ hsccp_oval_line_in_file_test(path=sshc_crypto_policy_config, parameter='KexAlgorithms', missing_parameter_pass=false) }}} + {{{ hsccp_oval_line_in_file_object(path=sshc_crypto_policy_config, parameter='KexAlgorithms', separator_regex='[\s]+', missing_parameter_pass=false, prefix_regex=common_prefix_regex) }}} {{{ hsccp_oval_line_in_file_state(parameter='KexAlgorithms', value='ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group14-sha1') }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/rule.yml index 4d50c3ceca6e..2e7e19c30ae8 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_ssh_client_crypto_policy/rule.yml @@ -1,10 +1,12 @@ documentation_complete: true +{{% set sshc_config_dir = ssh_client_config_dir %}} +{{% set sshc_crypto_policy_config = ssh_client_config_dir ~ "/02-ospp.conf" %}} title: 'Harden SSH client Crypto Policy' description: |- Crypto Policies are means of enforcing certain cryptographic settings for selected applications including OpenSSH client. - To override the system wide crypto policy for Openssh client, place a file in the /etc/ssh/ssh_config.d/ so that it is loaded before the 05-redhat.conf. In this case it is file named 02-ospp.conf containing parameters which need to be changed with respect to the crypto policy. + To override the system wide crypto policy for Openssh client, place a file in the {{{ sshc_config_dir }}} directory so that it is loaded before the 05-redhat.conf. In this case it is the {{{ sshc_crypto_policy_config }}} file containing parameters which need to be changed with respect to the crypto policy. This rule checks if the file exists and if it contains required parameters and values which modify the Crypto Policy. During the parsing process, as soon as Openssh client parses some configuration option and its value, it remembers it and ignores any subsequent overrides. The customization mechanism provided by crypto policies appends eventual customizations at the end of the system wide crypto policy. Therefore, if the crypto policy customization overrides some parameter which is already configured in the system wide crypto policy, the SSH client will not honor that customized parameter. @@ -28,7 +30,7 @@ ocil_clause: 'Crypto Policy for OpenSSH Client is not configured according to CC ocil: |- To verify if the OpenSSH Client uses defined Crypto Policy, run: -
$ cat /etc/ssh/ssh_config.d/02-ospp.conf
+
$ cat {{{ sshc_crypto_policy_config }}}
and verify that the line matches
Match final all
RekeyLimit 512M 1h
diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/ansible/shared.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/ansible/shared.yml index c31e056c6e3c..3c654bc0d0c7 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/ansible/shared.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/ansible/shared.yml @@ -4,10 +4,11 @@ # complexity = low # disruption = low {{{ ansible_instantiate_variables("sshd_approved_ciphers") }}} +{{%- set openssh_client_policy_file = openssh_client_crypto_policy_config_file -%}} {{{ ansible_set_config_file( msg='Configure SSH Daemon to Use FIPS 140-2 Validated Ciphers: openssh.config', - file='/etc/crypto-policies/back-ends/openssh.config', + file=openssh_client_policy_file, parameter='Ciphers', value="{{ sshd_approved_ciphers }}", create='yes', diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/bash/shared.sh index 7f5863452d2b..768954d3161b 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/bash/shared.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/bash/shared.sh @@ -1,9 +1,10 @@ # platform = Oracle Linux 8,Oracle Linux 9,Red Hat Enterprise Linux 8,multi_platform_fedora {{{ bash_instantiate_variables("sshd_approved_ciphers") }}} +{{%- set openssh_client_policy_file = openssh_client_crypto_policy_config_file -%}} {{{ set_config_file( - path="/etc/crypto-policies/back-ends/openssh.config", + path=openssh_client_policy_file, parameter="Ciphers", value="${sshd_approved_ciphers}", create=true, diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/oval/shared.xml index ac74c021e292..603ce24415a3 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/oval/shared.xml @@ -1,4 +1,4 @@ -{{%- set PATH = "/etc/crypto-policies/back-ends/openssh.config" -%}} +{{%- set PATH = openssh_client_crypto_policy_config_file -%}} {{{ oval_metadata("Limit the Ciphers to those which are FIPS-approved.", rule_title=rule_title) }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/rule.yml index dc167e5af486..622f75e3c362 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_openssh_conf_crypto_policy/rule.yml @@ -9,7 +9,7 @@ description: |- set up incorrectly. To check that Crypto Policies settings for ciphers are configured correctly, ensure that - /etc/crypto-policies/back-ends/openssh.config contains the following + {{{ openssh_client_crypto_policy_config_file }}} contains the following line and is not commented out:
Ciphers {{{ xccdf_value("sshd_approved_ciphers") }}}
@@ -35,7 +35,7 @@ ocil_clause: 'Crypto Policy for OpenSSH client is not configured correctly' ocil: |- To verify if the OpenSSH client uses defined Cipher suite in the Crypto Policy, run: -
$ grep -i ciphers /etc/crypto-policies/back-ends/openssh.config
+
$ grep -i ciphers {{{ openssh_client_crypto_policy_config_file }}}
and verify that the line matches:
Ciphers {{{ xccdf_value("sshd_approved_ciphers") }}}
@@ -59,3 +59,5 @@ warnings: party review by an accredited lab. While open source software is capable of meeting this, it does not meet FIPS-140 unless the vendor submits to this process. + +platform: package[openssh] diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/ansible/shared.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/ansible/shared.yml index e13f3c36e772..6d475bb9588d 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/ansible/shared.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/ansible/shared.yml @@ -4,10 +4,11 @@ # complexity = low # disruption = low {{{ ansible_instantiate_variables("sshd_approved_ciphers") }}} +{{%- set openssh_server_policy_file = openssh_server_crypto_policy_config_file -%}} - name: "{{{ rule_title }}}: Set relevant paths and correct value" ansible.builtin.set_fact: - opensshserver_path: /etc/crypto-policies/back-ends/opensshserver.config + opensshserver_path: "{{{ openssh_server_policy_file }}}" local_path: /etc/crypto-policies/local.d/opensshserver-ssg.config correct_value: "-oCiphers={{ sshd_approved_ciphers }}" diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/bash/shared.sh index 43fed0ef36de..e5afb9c11c12 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/bash/shared.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/bash/shared.sh @@ -1,8 +1,9 @@ # platform = Oracle Linux 8,Red Hat Enterprise Linux 8,multi_platform_fedora {{{ bash_instantiate_variables("sshd_approved_ciphers") }}} +{{%- set openssh_server_policy_file = openssh_server_crypto_policy_config_file -%}} -CONF_FILE=/etc/crypto-policies/back-ends/opensshserver.config +CONF_FILE="{{{ openssh_server_policy_file }}}" LOCAL_CONF_DIR=/etc/crypto-policies/local.d LOCAL_CONF_FILE=${LOCAL_CONF_DIR}/opensshserver-ssg.config correct_value="-oCiphers=${sshd_approved_ciphers}" diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/oval/shared.xml index 7f0823a567f2..e71fb7ddea0d 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/oval/shared.xml @@ -1,4 +1,4 @@ -{{%- set PATH = "/etc/crypto-policies/back-ends/opensshserver.config" -%}} +{{%- set PATH = openssh_server_crypto_policy_config_file -%}} {{{ oval_metadata("Limit the Ciphers to those which are FIPS-approved.", rule_title=rule_title) }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/rule.yml index 83bb45dc915a..e44749552311 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_ciphers_opensshserver_conf_crypto_policy/rule.yml @@ -1,4 +1,5 @@ documentation_complete: true +{{% set openssh_server_policy_file = openssh_server_crypto_policy_config_file %}} title: 'Configure SSH Server to Use FIPS 140-2 Validated Ciphers: opensshserver.config' @@ -9,7 +10,7 @@ description: |- set up incorrectly. To check that Crypto Policies settings for ciphers are configured correctly, ensure that - /etc/crypto-policies/back-ends/opensshserver.config contains the following + {{{ openssh_server_policy_file }}} contains the following text and is not commented out:
-oCiphers={{{ xccdf_value("sshd_approved_ciphers") }}}
@@ -36,7 +37,7 @@ ocil_clause: 'Crypto Policy for OpenSSH Server is not configured correctly' ocil: |- To verify if the OpenSSH server uses defined ciphers in the Crypto Policy, run: -
$ grep -Po '(-oCiphers=\S+)' /etc/crypto-policies/back-ends/opensshserver.config
+
$ grep -Po '(-oCiphers=\S+)' {{{ openssh_server_policy_file }}}
and verify that the line matches:
-oCiphers={{{ xccdf_value("sshd_approved_ciphers") }}}
diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/oval/shared.xml index 2db2d450afed..6ac15cdb5cc9 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/oval/shared.xml @@ -1 +1 @@ -{{{ oval_check_config_file(path="/etc/crypto-policies/back-ends/opensshserver.config", prefix_regex="^(?:.*\\n)*\s*", parameter="CRYPTO_POLICY", value="'-oCiphers=aes256-ctr,aes128-ctr,aes256-cbc,aes128-cbc -oMACs=hmac-sha2-512,hmac-sha2-256 -oGSSAPIKeyExchange=no -oKexAlgorithms=ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group14-sha1 -oHostKeyAlgorithms=ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256 -oPubkeyAcceptedKeyTypes=rsa-sha2-512,rsa-sha2-256,ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256'", separator_regex="=", application="sshd", rule_id=rule_id, rule_title=rule_title) }}} +{{{ oval_check_config_file(path=openssh_server_crypto_policy_config_file, prefix_regex="^(?:.*\\n)*\s*", parameter="CRYPTO_POLICY", value="'-oCiphers=aes256-ctr,aes128-ctr,aes256-cbc,aes128-cbc -oMACs=hmac-sha2-512,hmac-sha2-256 -oGSSAPIKeyExchange=no -oKexAlgorithms=ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group14-sha1 -oHostKeyAlgorithms=ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256 -oPubkeyAcceptedKeyTypes=rsa-sha2-512,rsa-sha2-256,ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256'", separator_regex="=", application="sshd", rule_id=rule_id, rule_title=rule_title) }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/rule.yml index 99315ff87e42..7cba7acc6188 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/rule.yml @@ -1,4 +1,5 @@ documentation_complete: true +{{% set openssh_server_policy_file = openssh_server_crypto_policy_config_file %}} title: 'Harden SSHD Crypto Policy' @@ -7,7 +8,7 @@ description: |- Crypto Policies are means of enforcing certain cryptographic settings for selected applications including OpenSSH server. The SSHD service is by default configured to modify its configuration based on currently configured Crypto-Policy. However, in certain cases it might be needed to override the Crypto Policy specific to OpenSSH Server and leave rest of the Crypto Policy intact. This can be done by dropping a file named opensshserver-xxx.config, replacing xxx with arbitrary identifier, into /etc/crypto-policies/local.d. This has to be followed by running update-crypto-policies so that changes are applied. - Changes are propagated into /etc/crypto-policies/back-ends/opensshserver.config. This rule checks if this file contains predefined CRYPTO_POLICY environment variable configured with predefined value. + Changes are propagated into {{{ openssh_server_policy_file }}}. This rule checks if this file contains predefined CRYPTO_POLICY environment variable configured with predefined value. rationale: |- The Common Criteria requirements specify that certain parameters for OpenSSH Server are configured e.g. supported ciphers, accepted host key algorithms, public key types, key exchange algorithms, HMACs and GSSAPI key exchange is disabled. Currently particular requirements specified by CC are stricter compared to any existing Crypto Policy. @@ -28,7 +29,7 @@ ocil_clause: 'Crypto Policy for OpenSSH Server is not configured according to CC ocil: |- To verify if the OpenSSH server uses defined Crypto Policy, run: -
$ grep 'CRYPTO_POLICY' /etc/crypto-policies/back-ends/opensshserver.config | tail -n 1
+
$ grep 'CRYPTO_POLICY' {{{ openssh_server_policy_file }}} | tail -n 1
and verify that the line matches
CRYPTO_POLICY='-oCiphers=aes256-ctr,aes128-ctr,aes256-cbc,aes128-cbc -oMACs=hmac-sha2-512,hmac-sha2-256 -oGSSAPIKeyExchange=no -oKexAlgorithms=ecdh-sha2-nistp521,ecdh-sha2-nistp384,ecdh-sha2-nistp256,diffie-hellman-group14-sha1 -oHostKeyAlgorithms=ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256 -oPubkeyAcceptedKeyTypes=rsa-sha2-512,rsa-sha2-256,ssh-rsa,ecdsa-sha2-nistp384,ecdsa-sha2-nistp256'
diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct.pass.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct.pass.sh index d0541b7ab6ce..b95dad27e1e9 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct.pass.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct.pass.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_commented.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_commented.fail.sh index 44434606deba..dee5b0842374 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_commented.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_commented.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_followed_by_incorrect.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_followed_by_incorrect.fail.sh index a92227669a88..9b15274eb853 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_followed_by_incorrect.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/correct_followed_by_incorrect.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_file.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_file.fail.sh index b1e285f9bb5a..b1161346eda2 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_file.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_file.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_policy.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_policy.fail.sh index 754195e43d45..1e6c053b0e7b 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_policy.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/empty_policy.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_followed_by_correct.pass.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_followed_by_correct.pass.sh index 8bf264dcd5f2..c2b06ed61fbf 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_followed_by_correct.pass.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_followed_by_correct.pass.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_policy.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_policy.fail.sh index a76346699149..4537d60b1a61 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_policy.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/incorrect_policy.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/missing_file.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/missing_file.fail.sh index 1928d2cfe916..84155e65aa8d 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/missing_file.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_crypto_policy/tests/missing_file.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = multi_platform_fedora,Red Hat Enterprise Linux 8 +# packages = crypto-policies-scripts configfile=/etc/crypto-policies/back-ends/opensshserver.config diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/ansible/shared.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/ansible/shared.yml index 9fce65f7e870..9cb8d3e80039 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/ansible/shared.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/ansible/shared.yml @@ -4,12 +4,14 @@ # complexity = low # disruption = low {{{ ansible_instantiate_variables("sshd_approved_macs") }}} +{{%- set openssh_client_policy_file = openssh_client_crypto_policy_config_file -%}} -{{{ ansible_set_config_file( +{{{ ansible_only_lineinfile( msg='Configure SSH Daemon to Use FIPS 140-2 Validated MACs: openssh.config', - file='/etc/crypto-policies/back-ends/openssh.config', - parameter='MACs', - value="{{ sshd_approved_macs }}", + path=openssh_client_policy_file, + line_regex='^.*MACs\\s+', + new_line='MACs {{ sshd_approved_macs }}', create='yes', - prefix_regex='^.*', rule_title=rule_title) + block=True, + rule_title=rule_title) }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/bash/shared.sh index 174ee6719a23..a77d89cdee5c 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/bash/shared.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/bash/shared.sh @@ -1,9 +1,10 @@ # platform = Red Hat Enterprise Linux 8,multi_platform_ol,multi_platform_fedora {{{ bash_instantiate_variables("sshd_approved_macs") }}} +{{%- set openssh_client_policy_file = openssh_client_crypto_policy_config_file -%}} {{{ set_config_file( - path="/etc/crypto-policies/back-ends/openssh.config", + path=openssh_client_policy_file, parameter="MACs", value="${sshd_approved_macs}", create=true, diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/oval/shared.xml index 5b7a360a3dfe..04e029e5614f 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/oval/shared.xml @@ -1,4 +1,4 @@ -{{%- set PATH = "/etc/crypto-policies/back-ends/openssh.config" -%}} +{{%- set PATH = openssh_client_crypto_policy_config_file -%}} {{{ oval_metadata("Limit the Message Authentication Codes (MACs) to those which are FIPS-approved.", rule_title=rule_title) }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/rule.yml index 3a7b33427d01..eead135e343f 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/rule.yml @@ -1,4 +1,5 @@ documentation_complete: true +{{% set openssh_client_policy_file = openssh_client_crypto_policy_config_file %}} title: 'Configure SSH Client to Use FIPS 140-2 Validated MACs: openssh.config' @@ -9,7 +10,7 @@ description: |- set up incorrectly. To check that Crypto Policies settings are configured correctly, ensure that - /etc/crypto-policies/back-ends/openssh.config contains the following + {{{ openssh_client_policy_file }}} contains the following line and is not commented out: MACs {{{ xccdf_value("sshd_approved_macs") }}} @@ -28,12 +29,13 @@ identifiers: references: nist: AC-17(2) srg: SRG-OS-000125-GPOS-00065,SRG-OS-000250-GPOS-00093 + stigid@ol8: OL08-00-010185 ocil_clause: 'Crypto Policy for OpenSSH client is not configured correctly' ocil: |- To verify if the OpenSSH client uses defined MACs in the Crypto Policy, run: -
$ grep -i macs /etc/crypto-policies/back-ends/openssh.config
+
$ grep -i macs {{{ openssh_client_policy_file }}}
and verify that the line matches:
MACs {{{ xccdf_value("sshd_approved_macs") }}}
@@ -57,3 +59,5 @@ warnings: party review by an accredited lab. While open source software is capable of meeting this, it does not meet FIPS-140 unless the vendor submits to this process. + +platform: package[openssh] diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_correct_commented.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_correct_commented.fail.sh index a819b2dd0708..4c8f67261b5e 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_correct_commented.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_correct_commented.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = Red Hat Enterprise Linux 8,multi_platform_ol,multi_platform_fedora +# remediation = bash # variables = sshd_approved_macs=hmac-sha2-512,hmac-sha2-256,hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com sshd_approved_macs=hmac-sha2-512,hmac-sha2-256,hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_incorrect_followed_by_correct_commented.fail.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_incorrect_followed_by_correct_commented.fail.sh index b0fea133a9a9..e096776e7017 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_incorrect_followed_by_correct_commented.fail.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_openssh_conf_crypto_policy/tests/stig_incorrect_followed_by_correct_commented.fail.sh @@ -1,5 +1,6 @@ #!/bin/bash # platform = Red Hat Enterprise Linux 8,multi_platform_ol,multi_platform_fedora +# remediation = bash # variables = sshd_approved_macs=hmac-sha2-512,hmac-sha2-256,hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com sshd_approved_macs=hmac-sha2-512,hmac-sha2-256,hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/ansible/shared.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/ansible/shared.yml index 21ab040b517e..1bc2f71ff295 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/ansible/shared.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/ansible/shared.yml @@ -4,10 +4,11 @@ # complexity = low # disruption = low {{{ ansible_instantiate_variables("sshd_approved_macs") }}} +{{%- set openssh_server_policy_file = openssh_server_crypto_policy_config_file -%}} - name: "{{{ rule_title }}}: Set relevant paths and correct value" ansible.builtin.set_fact: - opensshserver_path: /etc/crypto-policies/back-ends/opensshserver.config + opensshserver_path: "{{{ openssh_server_policy_file }}}" local_path: /etc/crypto-policies/local.d/opensshserver-ssg.config correct_value: "-oMACs={{ sshd_approved_macs }}" diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/bash/shared.sh b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/bash/shared.sh index 0c124e624712..6e14c65e90bf 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/bash/shared.sh +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/bash/shared.sh @@ -1,8 +1,9 @@ # platform = Oracle Linux 8,Red Hat Enterprise Linux 8,multi_platform_fedora {{{ bash_instantiate_variables("sshd_approved_macs") }}} +{{%- set openssh_server_policy_file = openssh_server_crypto_policy_config_file -%}} -CONF_FILE=/etc/crypto-policies/back-ends/opensshserver.config +CONF_FILE="{{{ openssh_server_policy_file }}}" LOCAL_CONF_DIR=/etc/crypto-policies/local.d LOCAL_CONF_FILE=${LOCAL_CONF_DIR}/opensshserver-ssg.config correct_value="-oMACs=${sshd_approved_macs}" diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/oval/shared.xml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/oval/shared.xml index 5f734202f3d5..e1e2b21d5831 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/oval/shared.xml @@ -1,4 +1,4 @@ -{{%- set PATH = "/etc/crypto-policies/back-ends/opensshserver.config" -%}} +{{%- set PATH = openssh_server_crypto_policy_config_file -%}} {{{ oval_metadata("Limit the Message Authentication Codes (MACs) to those which are FIPS-approved.", rule_title=rule_title) }}} diff --git a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/rule.yml b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/rule.yml index 81d127526082..bad242a613aa 100644 --- a/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/harden_sshd_macs_opensshserver_conf_crypto_policy/rule.yml @@ -1,4 +1,5 @@ documentation_complete: true +{{% set openssh_server_policy_file = openssh_server_crypto_policy_config_file %}} title: 'Configure SSH Server to Use FIPS 140-2 Validated MACs: opensshserver.config' @@ -9,7 +10,7 @@ description: |- set up incorrectly. To check that Crypto Policies settings are configured correctly, ensure that - /etc/crypto-policies/back-ends/opensshserver.config contains the following + {{{ openssh_server_policy_file }}} contains the following text and is not commented out: -oMACS={{{ xccdf_value("sshd_approved_macs") }}} @@ -34,7 +35,7 @@ ocil_clause: 'Crypto Policy for OpenSSH Server is not configured correctly' ocil: |- To verify if the OpenSSH server uses defined MACs in the Crypto Policy, run: -
$ grep -Po '(-oMACs=\S+)' /etc/crypto-policies/back-ends/opensshserver.config
+
$ grep -Po '(-oMACs=\S+)' {{{ openssh_server_policy_file }}}
and verify that the line matches:
-oMACS={{{ xccdf_value("sshd_approved_macs") }}}
diff --git a/linux_os/guide/system/software/integrity/crypto/package_crypto-policies_installed/rule.yml b/linux_os/guide/system/software/integrity/crypto/package_crypto-policies_installed/rule.yml index 404e14e5b9d8..90a04202b1ab 100644 --- a/linux_os/guide/system/software/integrity/crypto/package_crypto-policies_installed/rule.yml +++ b/linux_os/guide/system/software/integrity/crypto/package_crypto-policies_installed/rule.yml @@ -21,10 +21,9 @@ identifiers: references: ospp: FCS_COP.1(1),FCS_COP.1(2),FCS_COP.1(3),FCS_COP.1(4),FCS_CKM.1,FCS_CKM.2,FCS_TLSC_EXT.1 srg: SRG-OS-000396-GPOS-00176,SRG-OS-000393-GPOS-00173,SRG-OS-000394-GPOS-00174 + stigid@ol8: OL08-00-010180 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="crypto-policies") }}}' +{{{ complete_ocil_entry_package_installed("crypto-policies") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/integrity/endpoint_security_software/mcafee_security_software/mcafee_endpoint_security_software/package_mcafeetp_installed/rule.yml b/linux_os/guide/system/software/integrity/endpoint_security_software/mcafee_security_software/mcafee_endpoint_security_software/package_mcafeetp_installed/rule.yml index b707c73f1649..19f594a04a0d 100644 --- a/linux_os/guide/system/software/integrity/endpoint_security_software/mcafee_security_software/mcafee_endpoint_security_software/package_mcafeetp_installed/rule.yml +++ b/linux_os/guide/system/software/integrity/endpoint_security_software/mcafee_security_software/mcafee_endpoint_security_software/package_mcafeetp_installed/rule.yml @@ -33,9 +33,7 @@ references: nist: SI-2(2) srg: SRG-OS-000191-GPOS-00080 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package=pkg) }}}' +{{{ complete_ocil_entry_package_installed(pkg) }}} warnings: - general: |- diff --git a/linux_os/guide/system/software/integrity/fips/enable_fips_mode/rule.yml b/linux_os/guide/system/software/integrity/fips/enable_fips_mode/rule.yml index ea08f8e52b0a..8648f0127783 100644 --- a/linux_os/guide/system/software/integrity/fips/enable_fips_mode/rule.yml +++ b/linux_os/guide/system/software/integrity/fips/enable_fips_mode/rule.yml @@ -56,7 +56,7 @@ references: nist: CM-3(6),SC-12(2),SC-12(3),IA-7,SC-13,CM-6(a),SC-12 ospp: FCS_COP.1(1),FCS_COP.1(2),FCS_COP.1(3),FCS_COP.1(4),FCS_CKM.1,FCS_CKM.2,FCS_TLSC_EXT.1,FCS_RBG_EXT.1 srg: SRG-OS-000478-GPOS-00223,SRG-OS-000396-GPOS-00176 - stigid@ol8: OL08-00-010020,OL08-00-010293 + stigid@ol8: OL08-00-010020,OL08-00-010182 ocil_clause: 'FIPS mode is not enabled' diff --git a/linux_os/guide/system/software/integrity/fips/fips_crypto_subpolicy/rule.yml b/linux_os/guide/system/software/integrity/fips/fips_crypto_subpolicy/rule.yml index b6f4415705c6..90ee25c43814 100644 --- a/linux_os/guide/system/software/integrity/fips/fips_crypto_subpolicy/rule.yml +++ b/linux_os/guide/system/software/integrity/fips/fips_crypto_subpolicy/rule.yml @@ -19,6 +19,7 @@ identifiers: references: srg: SRG-OS-000033-GPOS-00014 + stigid@ol8: OL08-00-010184,OL08-00-010182,OL08-00-010181 severity: medium diff --git a/linux_os/guide/system/software/integrity/fips/fips_custom_stig_sub_policy/rule.yml b/linux_os/guide/system/software/integrity/fips/fips_custom_stig_sub_policy/rule.yml index 6e77c605a64b..42583a3260cb 100644 --- a/linux_os/guide/system/software/integrity/fips/fips_custom_stig_sub_policy/rule.yml +++ b/linux_os/guide/system/software/integrity/fips/fips_custom_stig_sub_policy/rule.yml @@ -11,10 +11,12 @@ rationale: |- severity: medium identifiers: + cce@rhel8: CCE-86493-4 cce@rhel9: CCE-86570-9 references: srg: SRG-OS-000396-GPOS-00176,SRG-OS-000393-GPOS-00173,SRG-OS-000394-GPOS-00174 + stigid@ol8: OL08-00-010181 ocil_clause: 'the STIG subpolicy does not exist' diff --git a/linux_os/guide/system/software/integrity/fips/package_dracut-fips-aesni_installed/rule.yml b/linux_os/guide/system/software/integrity/fips/package_dracut-fips-aesni_installed/rule.yml index 9705dda83661..dd201283020b 100644 --- a/linux_os/guide/system/software/integrity/fips/package_dracut-fips-aesni_installed/rule.yml +++ b/linux_os/guide/system/software/integrity/fips/package_dracut-fips-aesni_installed/rule.yml @@ -30,9 +30,7 @@ references: nist-csf: PR.AC-3,PR.PT-4 srg: SRG-OS-000033-GPOS-00014,SRG-OS-000396-GPOS-00176,SRG-OS-000478-GPOS-00223 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="dracut-fips-aesni") }}}' +{{{ complete_ocil_entry_package_installed("dracut-fips-aesni") }}} warnings: - general: |- diff --git a/linux_os/guide/system/software/integrity/fips/package_dracut-fips_installed/rule.yml b/linux_os/guide/system/software/integrity/fips/package_dracut-fips_installed/rule.yml index b903dc76ca1e..7a3485d69bd9 100644 --- a/linux_os/guide/system/software/integrity/fips/package_dracut-fips_installed/rule.yml +++ b/linux_os/guide/system/software/integrity/fips/package_dracut-fips_installed/rule.yml @@ -29,9 +29,7 @@ references: nist-csf: PR.AC-3,PR.PT-4 srg: SRG-OS-000033-GPOS-00014,SRG-OS-000396-GPOS-00176,SRG-OS-000478-GPOS-00223 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="dracut-fips") }}}' +{{{ complete_ocil_entry_package_installed("dracut-fips") }}} warnings: - regulatory: |- diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/oval/shared.xml b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/oval/shared.xml index 4fa825c17e49..5e0cd383f28b 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/oval/shared.xml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/oval/shared.xml @@ -22,7 +22,7 @@ {{% elif product == "rhel9" %}} ^database(?:_in)?=file:(?:@@{DBDIR})?/(?:[a-z.]+/)*([a-z.]+)$ - {{% elif product in ['ol10', 'rhel10', 'fedora' ] %}} + {{% elif product in ['ol10', 'rhel10', 'fedora', 'al2023' ] %}} ^database_in=file:(?:@@{DBDIR})?/(?:[a-z.]+/)*([a-z.]+)$ {{% else %}} ^database=file:(?:@@{DBDIR})?/(?:[a-z.]+/)*([a-z.]+)$ diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/rule.yml b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/rule.yml index 146f543b2a20..cdf4ae2f1477 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/rule.yml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_build_database/rule.yml @@ -35,7 +35,7 @@ rationale: |- warnings: - general: |- - In RHEL Image Mode (bootc) systems, the AIDE database must be regenerated after each system update. + In {{{ full_name }}} Image Mode (bootc) systems, the AIDE database must be regenerated after each system update. Image Mode systems receive updates through new container images that may include modified files. After applying system updates, run the following commands to regenerate the AIDE database:
$ sudo {{{ aide_bin_path }}} --init
diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_periodic_checking_systemd_timer/ansible/shared.yml b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_periodic_checking_systemd_timer/ansible/shared.yml index ba728ad7d042..36a76ba9f388 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_periodic_checking_systemd_timer/ansible/shared.yml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_periodic_checking_systemd_timer/ansible/shared.yml @@ -42,6 +42,7 @@ enabled: true daemon_reload: true masked: false + when: not ansible_check_mode - name: "{{{ rule_title }}} - Ensure AIDE Service Timer is Enabled" ansible.builtin.systemd: @@ -50,3 +51,4 @@ enabled: true daemon_reload: true masked: false + when: not ansible_check_mode diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_scan_notification/rule.yml b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_scan_notification/rule.yml index eb4520986a98..1b959ae04a4a 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_scan_notification/rule.yml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_scan_notification/rule.yml @@ -32,6 +32,7 @@ identifiers: cce@rhel10: CCE-90177-7 cce@sle12: CCE-83048-9 cce@sle15: CCE-91214-7 + cce@sle16: CCE-96460-1 cce@slmicro5: CCE-93722-7 cce@slmicro6: CCE-94730-9 diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_acls/rule.yml b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_acls/rule.yml index 0525db7b3921..6563fe6a637b 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_acls/rule.yml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_acls/rule.yml @@ -32,6 +32,7 @@ identifiers: cce@rhel10: CCE-89640-7 cce@sle12: CCE-83150-3 cce@sle15: CCE-85623-7 + cce@sle16: CCE-96372-8 cce@slmicro5: CCE-93742-5 cce@slmicro6: CCE-95052-7 diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_ext_attributes/rule.yml b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_ext_attributes/rule.yml index 1f681250134a..35ed5b595891 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_ext_attributes/rule.yml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/aide_verify_ext_attributes/rule.yml @@ -32,6 +32,7 @@ identifiers: cce@rhel10: CCE-89625-8 cce@sle12: CCE-83151-1 cce@sle15: CCE-85624-5 + cce@sle16: CCE-96620-0 cce@slmicro5: CCE-93743-3 cce@slmicro6: CCE-95053-5 diff --git a/linux_os/guide/system/software/integrity/software-integrity/aide/package_aide_installed/rule.yml b/linux_os/guide/system/software/integrity/software-integrity/aide/package_aide_installed/rule.yml index 7844c8991ce8..dc497c0c7b9a 100644 --- a/linux_os/guide/system/software/integrity/software-integrity/aide/package_aide_installed/rule.yml +++ b/linux_os/guide/system/software/integrity/software-integrity/aide/package_aide_installed/rule.yml @@ -38,9 +38,7 @@ references: stigid@sle12: SLES-12-010499 stigid@sle15: SLES-15-010419 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="aide") }}}' +{{{ complete_ocil_entry_package_installed("aide") }}} fixtext: |- {{{ describe_package_install("aide") }}} diff --git a/linux_os/guide/system/software/prefer_64bit_os/rule.yml b/linux_os/guide/system/software/prefer_64bit_os/rule.yml index 59cf1d282ec8..ae680e70e632 100644 --- a/linux_os/guide/system/software/prefer_64bit_os/rule.yml +++ b/linux_os/guide/system/software/prefer_64bit_os/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-90578-6 cce@sle12: CCE-91504-1 cce@sle15: CCE-91195-8 + cce@sle16: CCE-96208-4 ocil_clause: the installed operating system is 32-bit but the CPU supports operation in 64-bit diff --git a/linux_os/guide/system/software/sap_host/package_glibc_installed/rule.yml b/linux_os/guide/system/software/sap_host/package_glibc_installed/rule.yml index b7564be44d58..c092789ae83d 100644 --- a/linux_os/guide/system/software/sap_host/package_glibc_installed/rule.yml +++ b/linux_os/guide/system/software/sap_host/package_glibc_installed/rule.yml @@ -1,3 +1,4 @@ +{{%- set minimum_version = "0:2.17-55.0.4.el7_0.3" %}} documentation_complete: true @@ -17,12 +18,12 @@ rationale: |- severity: medium -ocil_clause: 'the minimum required glibc version is not installed' +ocil_clause: 'glibc is missing or installed at a version lower than {{{ minimum_version }}}' -ocil: '{{{ ocil_package(package="glibc") }}}' +{{{ ocil_package_installed_how_to_check(package="glibc") }}} template: name: package_installed vars: pkgname: glibc - evr: 0:2.17-55.0.4.el7_0.3 + evr: {{{ minimum_version }}} diff --git a/linux_os/guide/system/software/sap_host/package_uuidd_installed/rule.yml b/linux_os/guide/system/software/sap_host/package_uuidd_installed/rule.yml index cfeb5beb1337..e0e5d42dd145 100644 --- a/linux_os/guide/system/software/sap_host/package_uuidd_installed/rule.yml +++ b/linux_os/guide/system/software/sap_host/package_uuidd_installed/rule.yml @@ -19,9 +19,7 @@ rationale: |- severity: medium -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="uuidd") }}}' +{{{ complete_ocil_entry_package_installed("uuidd") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/sudo/directory_groupowner_etc_sudoersd/rule.yml b/linux_os/guide/system/software/sudo/directory_groupowner_etc_sudoersd/rule.yml index 7f1dc1ddb307..ca8efcd5e8b9 100644 --- a/linux_os/guide/system/software/sudo/directory_groupowner_etc_sudoersd/rule.yml +++ b/linux_os/guide/system/software/sudo/directory_groupowner_etc_sudoersd/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86351-4 cce@rhel10: CCE-87598-9 cce@sle15: CCE-92503-2 + cce@sle16: CCE-96050-0 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/sudoers.d", group="root") }}}' diff --git a/linux_os/guide/system/software/sudo/directory_owner_etc_sudoersd/rule.yml b/linux_os/guide/system/software/sudo/directory_owner_etc_sudoersd/rule.yml index 3183986c551a..1a87f6ee8fca 100644 --- a/linux_os/guide/system/software/sudo/directory_owner_etc_sudoersd/rule.yml +++ b/linux_os/guide/system/software/sudo/directory_owner_etc_sudoersd/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86357-1 cce@rhel10: CCE-89589-6 cce@sle15: CCE-92512-3 + cce@sle16: CCE-96623-4 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/sudoers.d", owner="root") }}}' diff --git a/linux_os/guide/system/software/sudo/directory_permissions_etc_sudoersd/rule.yml b/linux_os/guide/system/software/sudo/directory_permissions_etc_sudoersd/rule.yml index da1a48a14465..652eef8152eb 100644 --- a/linux_os/guide/system/software/sudo/directory_permissions_etc_sudoersd/rule.yml +++ b/linux_os/guide/system/software/sudo/directory_permissions_etc_sudoersd/rule.yml @@ -17,6 +17,7 @@ identifiers: cce@rhel9: CCE-86360-5 cce@rhel10: CCE-89200-0 cce@sle15: CCE-92525-5 + cce@sle16: CCE-96110-2 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/sudoers.d", perms="0750") }}}' diff --git a/linux_os/guide/system/software/sudo/file_groupowner_etc_sudoers/rule.yml b/linux_os/guide/system/software/sudo/file_groupowner_etc_sudoers/rule.yml index cfe3d033707d..a4f8eced4463 100644 --- a/linux_os/guide/system/software/sudo/file_groupowner_etc_sudoers/rule.yml +++ b/linux_os/guide/system/software/sudo/file_groupowner_etc_sudoers/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86413-2 cce@rhel9: CCE-86414-0 cce@rhel10: CCE-89613-4 + cce@sle16: CCE-96285-2 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/sudoers", group="root") }}}' diff --git a/linux_os/guide/system/software/sudo/file_owner_etc_sudoers/rule.yml b/linux_os/guide/system/software/sudo/file_owner_etc_sudoers/rule.yml index a1e02385222c..913068677c86 100644 --- a/linux_os/guide/system/software/sudo/file_owner_etc_sudoers/rule.yml +++ b/linux_os/guide/system/software/sudo/file_owner_etc_sudoers/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86416-5 cce@rhel9: CCE-86417-3 cce@rhel10: CCE-87065-9 + cce@sle16: CCE-96512-9 ocil_clause: '{{{ ocil_clause_file_owner(file="/etc/sudoers", owner="root") }}}' diff --git a/linux_os/guide/system/software/sudo/file_permissions_etc_sudoers/rule.yml b/linux_os/guide/system/software/sudo/file_permissions_etc_sudoers/rule.yml index d1e594c490d7..c6c7752ce18a 100644 --- a/linux_os/guide/system/software/sudo/file_permissions_etc_sudoers/rule.yml +++ b/linux_os/guide/system/software/sudo/file_permissions_etc_sudoers/rule.yml @@ -16,6 +16,7 @@ identifiers: cce@rhel8: CCE-86419-9 cce@rhel9: CCE-86424-9 cce@rhel10: CCE-90690-9 + cce@sle16: CCE-96318-1 ocil_clause: '{{{ ocil_clause_file_permissions(file="/etc/sudoers", perms="0440") }}}' diff --git a/linux_os/guide/system/software/sudo/package_sudo_installed/rule.yml b/linux_os/guide/system/software/sudo/package_sudo_installed/rule.yml index 9fa248ae5d3f..2c46a602376e 100644 --- a/linux_os/guide/system/software/sudo/package_sudo_installed/rule.yml +++ b/linux_os/guide/system/software/sudo/package_sudo_installed/rule.yml @@ -31,9 +31,7 @@ references: ospp: FMT_MOF_EXT.1 srg: SRG-OS-000324-GPOS-00125 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="sudo") }}}' +{{{ complete_ocil_entry_package_installed("sudo") }}} fixtext: |- {{{ describe_package_install(package="sudo") }}} diff --git a/linux_os/guide/system/software/sudo/sudo_add_env_reset/rule.yml b/linux_os/guide/system/software/sudo/sudo_add_env_reset/rule.yml index ee1af2c63369..6918afa2ea0f 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_env_reset/rule.yml +++ b/linux_os/guide/system/software/sudo/sudo_add_env_reset/rule.yml @@ -24,7 +24,7 @@ identifiers: cce@rhel10: CCE-90747-7 cce@sle12: CCE-91492-9 cce@sle15: CCE-91184-2 - + cce@sle16: CCE-96178-9 ocil_clause: 'env_reset is not enabled in sudo' diff --git a/linux_os/guide/system/software/sudo/sudo_add_ignore_dot/rule.yml b/linux_os/guide/system/software/sudo/sudo_add_ignore_dot/rule.yml index 3202a1efc830..9c4003d3e523 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_ignore_dot/rule.yml +++ b/linux_os/guide/system/software/sudo/sudo_add_ignore_dot/rule.yml @@ -24,7 +24,7 @@ identifiers: cce@rhel10: CCE-90743-6 cce@sle12: CCE-91493-7 cce@sle15: CCE-91185-9 - + cce@sle16: CCE-96048-4 ocil_clause: 'ignore_dot is not enabled in sudo' diff --git a/linux_os/guide/system/software/sudo/sudo_add_noexec/rule.yml b/linux_os/guide/system/software/sudo/sudo_add_noexec/rule.yml index 8c77ea2e3d79..93ee04d74015 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_noexec/rule.yml +++ b/linux_os/guide/system/software/sudo/sudo_add_noexec/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-89119-2 cce@sle12: CCE-91494-5 cce@sle15: CCE-91186-7 + cce@sle16: CCE-96653-1 ocil_clause: 'noexec is not enabled in sudo' diff --git a/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/etc_sudoers.missing.fail.sh b/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/etc_sudoers.missing.fail.sh new file mode 100644 index 000000000000..398d45e1fadb --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/etc_sudoers.missing.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +echo "Defaults noexec" >> /etc/sudoers.d/enable_noexec diff --git a/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_absent.fail.sh b/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_absent.fail.sh index ad54d80ce095..a0dbeee74872 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_absent.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_absent.fail.sh @@ -2,6 +2,9 @@ # platform = multi_platform_all touch /etc/sudoers.d/empty +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Code taken from macro bash_sudo_remove_config() for f in /etc/sudoers /etc/sudoers.d/*; do if [ ! -e "$f" ]; then diff --git a/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_enabled_dir.pass.sh b/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_enabled_dir.pass.sh index 105c1ccffbe2..531ceeec7551 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_enabled_dir.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_add_noexec/tests/noexec_enabled_dir.pass.sh @@ -1,4 +1,7 @@ #!/bin/bash # platform = multi_platform_all +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} echo "Defaults noexec" >> /etc/sudoers.d/enable_noexec diff --git a/linux_os/guide/system/software/sudo/sudo_add_requiretty/rule.yml b/linux_os/guide/system/software/sudo/sudo_add_requiretty/rule.yml index ffce5a30d2c9..ace4a8de296d 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_requiretty/rule.yml +++ b/linux_os/guide/system/software/sudo/sudo_add_requiretty/rule.yml @@ -21,6 +21,7 @@ identifiers: cce@rhel10: CCE-90076-1 cce@sle12: CCE-91496-0 cce@sle15: CCE-91188-3 + cce@sle16: CCE-95927-0 ocil_clause: 'requiretty is not enabled in sudo' diff --git a/linux_os/guide/system/software/sudo/sudo_add_umask/rule.yml b/linux_os/guide/system/software/sudo/sudo_add_umask/rule.yml index 03f2ed524dc6..ea5f13d80676 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_umask/rule.yml +++ b/linux_os/guide/system/software/sudo/sudo_add_umask/rule.yml @@ -24,7 +24,7 @@ identifiers: cce@rhel8: CCE-83860-7 cce@sle12: CCE-91498-6 cce@sle15: CCE-91189-1 - + cce@sle16: CCE-96241-5 ocil_clause: 'umask is not set with the appropriate value for sudo' diff --git a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..b3b172f6a0ec --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/etc_sudoers_missing.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +echo "Defaults use_pty" >> /etc/sudoers.d/enable_use_pty diff --git a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_absent.fail.sh b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_absent.fail.sh index df6bb677d203..7fd1f3e5709f 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_absent.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_absent.fail.sh @@ -3,6 +3,9 @@ # packages = sudo touch /etc/sudoers.d/empty +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Code taken from macro bash_sudo_remove_config() for f in /etc/sudoers /etc/sudoers.d/*; do [ -e "$f" ] || continue diff --git a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_disabled.fail.sh b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_disabled.fail.sh index 774b96c1b840..1b1047b03d9e 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_disabled.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_disabled.fail.sh @@ -2,5 +2,8 @@ # platform = multi_platform_all # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} sed '/Defaults.*use_pty/ s/.*/#&/g' -i /etc/sudoers /etc/sudoers.d/* echo "Defaults !use_pty" >> /etc/sudoers.d/enable_use_pty diff --git a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_enabled_dir.pass.sh b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_enabled_dir.pass.sh index ae0ca71f93d6..0f8a07ca0ba8 100644 --- a/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_enabled_dir.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_add_use_pty/tests/use_pty_enabled_dir.pass.sh @@ -2,4 +2,7 @@ # platform = multi_platform_all # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} echo "Defaults use_pty" >> /etc/sudoers.d/enable_use_pty diff --git a/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..599ed44ff52a --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/etc_sudoers_missing.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +echo "Defaults logfile=/var/log/sudo.log" >> /etc/sudoers.d/enable_logfile diff --git a/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_absent.fail.sh b/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_absent.fail.sh index 4e67eab5cdb3..fff1df2ff96e 100644 --- a/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_absent.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_absent.fail.sh @@ -3,6 +3,9 @@ # packages = sudo touch /etc/sudoers.d/empty +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Code taken from macro bash_sudo_remove_config() for f in /etc/sudoers /etc/sudoers.d/*; do if [ ! -e "$f" ]; then diff --git a/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_enabled_dir.pass.sh b/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_enabled_dir.pass.sh index 644d08eb6a3d..0866ec887ed3 100644 --- a/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_enabled_dir.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_custom_logfile/tests/logfile_enabled_dir.pass.sh @@ -2,4 +2,7 @@ # platform = multi_platform_all # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} echo "Defaults logfile=/var/log/sudo.log" >> /etc/sudoers.d/enable_logfile diff --git a/linux_os/guide/system/software/sudo/sudo_dedicated_group/rule.yml b/linux_os/guide/system/software/sudo/sudo_dedicated_group/rule.yml index f04cfbfe2502..0fd5f740e5e3 100644 --- a/linux_os/guide/system/software/sudo/sudo_dedicated_group/rule.yml +++ b/linux_os/guide/system/software/sudo/sudo_dedicated_group/rule.yml @@ -26,6 +26,7 @@ identifiers: cce@rhel10: CCE-89208-3 cce@sle12: CCE-91500-9 cce@sle15: CCE-91191-7 + cce@sle16: CCE-96236-5 ocil_clause: '{{{ ocil_clause_file_group_owner(file="/usr/bin/sudo", group=xccdf_value("var_sudo_dedicated_group")) }}}' diff --git a/linux_os/guide/system/software/sudo/sudo_require_authentication/ansible/shared.yml b/linux_os/guide/system/software/sudo/sudo_require_authentication/ansible/shared.yml index e5e00c5715e1..d402ee5e09ce 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_authentication/ansible/shared.yml +++ b/linux_os/guide/system/software/sudo/sudo_require_authentication/ansible/shared.yml @@ -4,6 +4,19 @@ # complexity = low # disruption = low +{{% if product in [ 'sle16', 'slmicro6' ] %}} +{{{ ansible_copy_distro_defaults('/usr/etc/sudoers', '/etc/sudoers', rule_title=rule_title) }}} +{{{ + ansible_lineinfile( + rule_title + " - Remove /usr/etc/sudoers.d include directive from /etc/sudoers", + path="/etc/sudoers", + regex='^\s*@includedir\s+/usr/etc/sudoers.d', + state="absent", + when="not ansible_check_mode" + ) +}}} +{{% endif %}} + {{{ ansible_sudo_remove_config("NOPASSWD", "NOPASSWD[\s]*\:") }}} {{{ ansible_sudo_remove_config("!authenticate", "\!authenticate") }}} diff --git a/linux_os/guide/system/software/sudo/sudo_require_authentication/bash/shared.sh b/linux_os/guide/system/software/sudo/sudo_require_authentication/bash/shared.sh index 92883b92f313..fdcbedcd72e0 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_authentication/bash/shared.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_authentication/bash/shared.sh @@ -4,6 +4,10 @@ # complexity = low # disruption = low +{{% if product in [ 'sle16', 'slmicro6' ] %}} +{{{ bash_copy_distro_defaults("/usr/etc/sudoers", "/etc/sudoers") }}} +{{{ lineinfile_absent("/etc/sudoers", "^\s*@includedir\s*/usr/etc/sudoers\.d", sed_path_separator="#", rule_id=rule_id) }}} +{{% endif %}} {{{ bash_sudo_remove_config("NOPASSWD", "NOPASSWD[\s]*\:") }}} {{{ bash_sudo_remove_config("!authenticate", "\!authenticate") }}} diff --git a/linux_os/guide/system/software/sudo/sudo_require_authentication/oval/shared.xml b/linux_os/guide/system/software/sudo/sudo_require_authentication/oval/shared.xml index f30ce938feaa..2aa4cc66782c 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_authentication/oval/shared.xml +++ b/linux_os/guide/system/software/sudo/sudo_require_authentication/oval/shared.xml @@ -4,6 +4,15 @@ + {{% if product in [ 'sle16', 'slmicro6' ] %}} + + {{% endif %}}
+ {{% if product in [ 'sle16', 'slmicro6' ] %}} + {{{ oval_config_file_exists_test('/etc/sudoers', rule_id=rule_id) }}} + {{{ oval_config_file_exists_object('/etc/sudoers', rule_id=rule_id) }}} + {{% endif %}}
diff --git a/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/authenticate_disabled_include_dir.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/authenticate_disabled_include_dir.fail.sh new file mode 100644 index 000000000000..95218b2f07e7 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/authenticate_disabled_include_dir.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +touch /etc/sudoers +echo "Defaults !authenticate" > /etc/sudoers.d/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..640f2c58627e --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/etc_sudoers_missing.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +echo "Defaults authenticate" > /etc/sudoers.d/authenticate diff --git a/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/nopasswd_include_dir.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/nopasswd_include_dir.fail.sh new file mode 100644 index 000000000000..445faf103e11 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_require_authentication/tests/nopasswd_include_dir.fail.sh @@ -0,0 +1,6 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +touch /etc/sudoers +echo "%wheel ALL=(ALL) NOPASSWD: ALL" > /etc/sudoers.d/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/ansible/shared.yml b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/ansible/shared.yml index 7a9b0222c4a9..83941c804e7b 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/ansible/shared.yml +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/ansible/shared.yml @@ -6,6 +6,19 @@ {{{ ansible_instantiate_variables("var_sudo_timestamp_timeout") }}} +{{% if product in [ 'sle16', 'slmicro6' ] %}} +{{{ ansible_copy_distro_defaults('/usr/etc/sudoers', '/etc/sudoers', rule_title=rule_title) }}} +{{{ + ansible_lineinfile( + rule_title + " - Remove /usr/etc/sudoers.d include directive from /etc/sudoers", + path="/etc/sudoers", + regex='^\s*@includedir\s+/usr/etc/sudoers.d', + state="absent", + when="not ansible_check_mode" + ) +}}} +{{% endif %}} + - name: "{{{ rule_title }}} - Find /etc/sudoers.d/* files containing 'Defaults timestamp_timeout'" ansible.builtin.find: path: "/etc/sudoers.d" @@ -28,15 +41,24 @@ validate: /usr/sbin/visudo -cf %s backrefs: yes register: edit_sudoers_timestamp_timeout_option +{{% if product in [ 'sle16', 'slmicro6' ] %}} + when: not ansible_check_mode +{{% endif %}} - name: "{{{ rule_title }}} - Enable timestamp_timeout option with correct value in /etc/sudoers" ansible.builtin.lineinfile: # noqa 503 path: /etc/sudoers line: 'Defaults timestamp_timeout={{ var_sudo_timestamp_timeout }}' validate: /usr/sbin/visudo -cf %s +{{% if product in [ 'sle16', 'slmicro6' ] %}} + when: > + not ansible_check_mode and edit_sudoers_timestamp_timeout_option is defined and + not edit_sudoers_timestamp_timeout_option.changed +{{% else %}} when: > edit_sudoers_timestamp_timeout_option is defined and not edit_sudoers_timestamp_timeout_option.changed +{{% endif %}} - name: "{{{ rule_title }}} - Remove timestamp_timeout wrong values in /etc/sudoers" ansible.builtin.lineinfile: diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/bash/shared.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/bash/shared.sh index 4a5d5cb1f03e..b9292fdf9df7 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/bash/shared.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/bash/shared.sh @@ -7,6 +7,11 @@ {{{ bash_instantiate_variables("var_sudo_timestamp_timeout") }}} +{{% if product in [ 'sle16', 'slmicro6' ] %}} +{{{ bash_copy_distro_defaults("/usr/etc/sudoers", "/etc/sudoers") }}} +{{{ lineinfile_absent("/etc/sudoers", "^\s*@includedir\s*/usr/etc/sudoers\.d", sed_path_separator="#", rule_id=rule_id) }}} +{{% endif %}} + if grep -Px '^[\s]*Defaults.*timestamp_timeout[\s]*=.*' /etc/sudoers.d/*; then find /etc/sudoers.d/ -type f -exec sed -Ei "/^[[:blank:]]*Defaults.*timestamp_timeout[[:blank:]]*=.*/d" {} \; fi @@ -22,7 +27,7 @@ if /usr/sbin/visudo -qcf /etc/sudoers; then sed -Ei "s/(^[[:blank:]]*Defaults.*timestamp_timeout[[:blank:]]*=)[[:blank:]]*[-]?\w+(.*$)/\1${var_sudo_timestamp_timeout}\2/" /etc/sudoers fi fi - + # Check validity of sudoers and cleanup bak if /usr/sbin/visudo -qcf /etc/sudoers; then rm -f /etc/sudoers.bak diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/oval/shared.xml b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/oval/shared.xml index a0654aa47479..f524f270c562 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/oval/shared.xml +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/oval/shared.xml @@ -4,6 +4,11 @@ + {{% if product in [ 'sle16', 'slmicro6' ] %}} + + {{% endif %}}
@@ -18,14 +23,18 @@ - ^\/etc\/(sudoers|sudoers\.d\/.*)$ + ^\/etc\/(sudoers|sudoers\.d\/.*)$ ^[\s]*Defaults[\s]+timestamp_timeout[\s]*=\s*[+]?(\d*\.\d+|\d+\.\d*|\d+)$ 1 - ^\/etc\/(sudoers|sudoers\.d\/.*)$ + ^\/etc\/(sudoers|sudoers\.d\/.*)$ ^[\s]*Defaults[\s]+timestamp_timeout[\s]*=\s*[\-](\d*\.\d+|\d+\.\d*|\d+)$ 1 - +
+ {{% if product in [ 'sle16', 'slmicro6' ] %}} + {{{ oval_config_file_exists_test('/etc/sudoers', rule_id=rule_id) }}} + {{{ oval_config_file_exists_object('/etc/sudoers', rule_id=rule_id) }}} + {{% endif %}} diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_1.pass.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_1.pass.sh index 6f22042299c5..c075a558985b 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_1.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_1.pass.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_4.pass.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_4.pass.sh index b85aa3209452..921f4b73dce6 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_4.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_4.pass.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_7.pass.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_7.pass.sh index ca06721f40bd..a0490063068b 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_7.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_7.pass.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_8.pass.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_8.pass.sh index 813d04fe2f1f..afc6c8e2af02 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_8.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_8.pass.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_with_spaces_2.pass.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_with_spaces_2.pass.sh index 18abae85b0cc..c4a5ee2dd233 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_with_spaces_2.pass.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/correct_value_with_spaces_2.pass.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..d12750f8695a --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/etc_sudoers_missing.fail.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +echo "Defaults timestamp_timeout=3" >> /etc/sudoers.d/00-complianceascode-test.conf diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value.fail.sh index faedbd64ac7b..2b8632b71c2e 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value.fail.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers fi diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value_1.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value_1.fail.sh index 1b5e460ae743..219502541ca9 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value_1.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/missing_value_1.fail.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from /etc/sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/wrong_value_1.fail.sh b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/wrong_value_1.fail.sh index 06ca6cd0cbff..369889970698 100644 --- a/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/wrong_value_1.fail.sh +++ b/linux_os/guide/system/software/sudo/sudo_require_reauthentication/tests/wrong_value_1.fail.sh @@ -1,6 +1,9 @@ #!/bin/bash # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +touch /etc/sudoers +{{% endif %}} # Remove Defaults timestamp_timeout from sudoers if grep -q 'timestamp_timeout' /etc/sudoers; then sed -i '/.*timestamp_timeout.*/d' /etc/sudoers diff --git a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/oval/shared.xml b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/oval/shared.xml index 52fce6623a48..fa0c537942b0 100644 --- a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/oval/shared.xml +++ b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/oval/shared.xml @@ -1,9 +1,27 @@ {{{ oval_metadata("Check that sudoers doesn't contain commands without arguments specified", rule_title=rule_title) }}} + {{% if product in [ 'sle16', 'slmicro6' ] %}} + - + + + + {{% else %}} + + + + {{% endif %}} ^(?!\s*Defaults)(?:\s*[^#=]+)=(?:\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,\s]+(?:[ \t]+[^,\s]+)+[ \t]*,)*(\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,\s]+[ \t]*(?:,|$)) 1
+ + {{% if product in [ 'sle16', 'slmicro6' ] %}} + {{{ oval_config_file_exists_test('/etc/sudoers', rule_id=rule_id) }}} + {{{ oval_config_file_exists_object('/etc/sudoers', rule_id=rule_id) }}} + + + + + + + + ^(/usr)?/etc/sudoers\.d/.*$ + ^(?!\s*Defaults)(?:\s*[^#=]+)=(?:\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,\s]+(?:[ \t]+[^,\s]+)+[ \t]*,)*(\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,\s]+[ \t]*(?:,|$)) + 1 + + + + + + + + + /etc/sudoers + ^(?!\s*Defaults)(?:\s*[^#=]+)=(?:\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,\s]+(?:[ \t]+[^,\s]+)+[ \t]*,)*(\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,\s]+[ \t]*(?:,|$)) + 1 + + + {{% endif %}} diff --git a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/rule.yml b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/rule.yml index 95798eda09f1..ed93aa6d2aef 100644 --- a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/rule.yml +++ b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/rule.yml @@ -27,6 +27,7 @@ identifiers: cce@rhel10: CCE-90002-7 cce@sle12: CCE-91501-7 cce@sle15: CCE-91192-5 + cce@sle16: CCE-95946-0 ocil_clause: '/etc/sudoers file contains user specifications that allow execution of commands with any arguments' diff --git a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/commented.pass.sh b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/commented.pass.sh index 81ea5bacd2ed..2d1fcb6999c0 100644 --- a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/commented.pass.sh +++ b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/commented.pass.sh @@ -2,5 +2,8 @@ # platform = multi_platform_all # packages = sudo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +echo '# somebody ALL=/bin/ls, (!bob,alice) !/bin/cat, /bin/dog' > /usr/etc/sudoers.d/foo +{{% endif %}} echo '#jen,!fred ALL, !SERVERS = !/bin/sh' > /etc/sudoers echo '# somebody ALL=/bin/ls, (!bob,alice) !/bin/cat, /bin/dog' > /etc/sudoers.d/foo diff --git a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/distro_defaults_drop_in_no_arguments.fail.sh b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/distro_defaults_drop_in_no_arguments.fail.sh new file mode 100644 index 000000000000..f96c43c451f0 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/distro_defaults_drop_in_no_arguments.fail.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +if [ ! -e "/etc/sudoers" ] ; then + touch "/etc/sudoers" +fi +echo 'user,!example ALL,SERVERS = /bin/sh ' > /usr/etc/sudoers.d/foo diff --git a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/distro_defaults_drop_in_simple.pass.sh b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/distro_defaults_drop_in_simple.pass.sh new file mode 100644 index 000000000000..4003fce75d82 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/distro_defaults_drop_in_simple.pass.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +if [ ! -e "/etc/sudoers" ] ; then + touch "/etc/sudoers" +fi +echo 'nobody ALL=/bin/ls arg arg, (bob,!alice) /bin/dog arg, /bin/cat arg' > /etc/sudoers.d/foo +echo 'nobody ALL=/bin/ls arg arg, (bob,!alice) /bin/dog arg, /bin/cat arg' > /usr/etc/sudoers.d/foo diff --git a/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/sle16_etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/sle16_etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..d8784c90ec6d --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_explicit_command_args/tests/sle16_etc_sudoers_missing.fail.sh @@ -0,0 +1,11 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +# correct entries in default drop-ins, OVAL should fail if /etc/sudoers is missing +echo 'nobody ALL=/bin/ls arg arg, (bob,!alice) /bin/dog arg, /bin/cat arg' > /etc/sudoers.d/foo +echo 'nobody ALL=/bin/ls arg arg, (bob,!alice) /bin/dog arg, /bin/cat arg' > /usr/etc/sudoers.d/foo diff --git a/linux_os/guide/system/software/sudo/sudoers_no_command_negation/oval/shared.xml b/linux_os/guide/system/software/sudo/sudoers_no_command_negation/oval/shared.xml index 56d10458aa2d..d9dc20314df6 100644 --- a/linux_os/guide/system/software/sudo/sudoers_no_command_negation/oval/shared.xml +++ b/linux_os/guide/system/software/sudo/sudoers_no_command_negation/oval/shared.xml @@ -3,6 +3,11 @@ {{{ oval_metadata("Check that sudoers doesn't contain command negations", rule_title=rule_title) }}} + {{% if product in [ 'sle16', 'slmicro6' ] %}} + + {{% endif %}} @@ -23,4 +28,8 @@ ^(?:\s*[^#=]+)=(?:\s*(?:\([^\)]+\))?\s*(?!\s*\()[^,!\n][^,\n]+,)*\s*(?:\([^\)]+\))?\s*(?!\s*\()(!\S+).* 1
+ {{% if product in [ 'sle16', 'slmicro6' ] %}} + {{{ oval_config_file_exists_test('/etc/sudoers', rule_id=rule_id) }}} + {{{ oval_config_file_exists_object('/etc/sudoers', rule_id=rule_id) }}} + {{% endif %}} diff --git a/linux_os/guide/system/software/sudo/sudoers_no_command_negation/rule.yml b/linux_os/guide/system/software/sudo/sudoers_no_command_negation/rule.yml index f956dbc51fb9..9c15e34b9897 100644 --- a/linux_os/guide/system/software/sudo/sudoers_no_command_negation/rule.yml +++ b/linux_os/guide/system/software/sudo/sudoers_no_command_negation/rule.yml @@ -26,6 +26,7 @@ identifiers: cce@rhel10: CCE-90660-2 cce@sle12: CCE-91502-5 cce@sle15: CCE-91193-3 + cce@sle16: CCE-95859-5 ocil_clause: '/etc/sudoers file contains rules that define the set of allowed commands using negation' diff --git a/linux_os/guide/system/software/sudo/sudoers_no_command_negation/tests/etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudoers_no_command_negation/tests/etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..5f6b8de80982 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_no_command_negation/tests/etc_sudoers_missing.fail.sh @@ -0,0 +1,9 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi +echo 'nobody ALL=/bin/ls, (bob !alice) /bin/dog, /bin/cat !arg' > /etc/sudoers.d/foo diff --git a/linux_os/guide/system/software/sudo/sudoers_no_root_target/oval/shared.xml b/linux_os/guide/system/software/sudo/sudoers_no_root_target/oval/shared.xml index ebd96b772480..f6a7c87e6ac3 100644 --- a/linux_os/guide/system/software/sudo/sudoers_no_root_target/oval/shared.xml +++ b/linux_os/guide/system/software/sudo/sudoers_no_root_target/oval/shared.xml @@ -1,10 +1,34 @@ {{{ oval_metadata("Check that sudoers doesn't allow users to run commands as root", rule_title=rule_title) }}} + {{% if product in [ 'sle16', 'slmicro6' ] %}} + + + + + + + + + {{% else %}} + {{% endif %}} - ^\s*((?!root\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*\([\w\s]*\b(root|ALL)\b[\w\s]*\) + ^\s*((?!(root|Defaults)\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*\([\w\s]*\b(root|ALL)\b[\w\s]*\) 1
@@ -41,7 +65,70 @@ - \2: target hostname or ALL - later: No bracket either right after "hosts =", or no bracket after the "previous command" --> - ^\s*((?!root\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*[^\(\s] + ^\s*((?!(root|Defaults)\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*[^\(\s] + 1 +
+ + {{% if product in [ 'sle16', 'slmicro6' ] %}} + {{{ oval_config_file_exists_test('/etc/sudoers', rule_id=rule_id) }}} + {{{ oval_config_file_exists_object('/etc/sudoers', rule_id=rule_id) }}} + + + + + + + + ^(/usr)?/etc/sudoers\.d/.*$ + ^\s*((?!(root|Defaults)\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*\([\w\s]*\b(root|ALL)\b[\w\s]*\) + 1 + + + + + + + + ^(/usr)?/etc/sudoers\.d/.*$ + ^\s*((?!(root|Defaults)\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*[^\(\s] 1 + + + + + + + + + /etc/sudoers + ^\s*((?!(root|Defaults)\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*\([\w\s]*\b(root|ALL)\b[\w\s]*\) + 1 + + + + + + + + /etc/sudoers + ^\s*((?!(root|Defaults)\b)[\w]+)\s*(\w+)\s*=\s*(.*,)?\s*[^\(\s] + 1 + + + + + + + {{% endif %}} diff --git a/linux_os/guide/system/software/sudo/sudoers_no_root_target/rule.yml b/linux_os/guide/system/software/sudo/sudoers_no_root_target/rule.yml index b48bd38dbd19..ebd11afe383b 100644 --- a/linux_os/guide/system/software/sudo/sudoers_no_root_target/rule.yml +++ b/linux_os/guide/system/software/sudo/sudoers_no_root_target/rule.yml @@ -20,6 +20,7 @@ identifiers: cce@rhel10: CCE-90532-3 cce@sle12: CCE-91503-3 cce@sle15: CCE-91194-1 + cce@sle16: CCE-96440-3 # The second part of the sentence explaining what got wrong. # ... Is it the case that diff --git a/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/simple.pass.sh b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/simple.pass.sh index a0b0bcc6bb76..15a85216be1b 100644 --- a/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/simple.pass.sh +++ b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/simple.pass.sh @@ -4,3 +4,6 @@ echo '%wheel ALL=(admin) ALL' > /etc/sudoers echo 'user ALL=(admin) ALL' > /etc/sudoers.d/foo +{{% if product in [ 'sle16', 'slmicro6' ] %}} +sed -i "/^ALL[[:space:]]*ALL=(ALL)[[:space:]]*ALL/d" /usr/etc/sudoers +{{% endif %}} diff --git a/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/sle16_etc_sudoers_missing.fail.sh b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/sle16_etc_sudoers_missing.fail.sh new file mode 100644 index 000000000000..0155c1fb185f --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/sle16_etc_sudoers_missing.fail.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +# remove /etc/sudoers for SUSE Linux Enterprise 16 +# test should fail, by default no drop-in sudoers configuration is present +if [ -e "/etc/sudoers" ] ; then + rm "/etc/sudoers" +fi diff --git a/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/user_allowed_distro_defaults_include_dir.fail.sh b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/user_allowed_distro_defaults_include_dir.fail.sh new file mode 100644 index 000000000000..68d58ee80f54 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/user_allowed_distro_defaults_include_dir.fail.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +# create /etc/sudoers, otherwise OVAL will fail due to missing file +if [ ! -e "/etc/sudoers" ] ; then + touch "/etc/sudoers" +fi +echo 'user ALL=(ALL) ALL' > /usr/etc/sudoers.d/user diff --git a/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/user_allowed_sudoers_d.fail.sh b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/user_allowed_sudoers_d.fail.sh new file mode 100644 index 000000000000..c4d12ed1a7f7 --- /dev/null +++ b/linux_os/guide/system/software/sudo/sudoers_no_root_target/tests/user_allowed_sudoers_d.fail.sh @@ -0,0 +1,10 @@ +#!/bin/bash +# platform = SUSE Linux Enterprise 16 +# packages = sudo +# remediation = none + +# create /etc/sudoers, otherwise OVAL will fail due to missing file +if [ ! -e "/etc/sudoers" ] ; then + touch "/etc/sudoers" +fi +echo 'user ALL=(ALL) ALL' > /etc/sudoers.d/user diff --git a/linux_os/guide/system/software/system-tools/package_abrt-addon-ccpp_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-addon-ccpp_removed/rule.yml index 848e7ff4c37b..bf0552c9ba75 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-addon-ccpp_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-addon-ccpp_removed/rule.yml @@ -19,7 +19,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-addon-ccpp") }}} +{{{ complete_ocil_entry_package_removed("abrt-addon-ccpp") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-addon-kerneloops_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-addon-kerneloops_removed/rule.yml index 6a4366edb8be..f22e7b294016 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-addon-kerneloops_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-addon-kerneloops_removed/rule.yml @@ -19,7 +19,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-addon-kerneloops") }}} +{{{ complete_ocil_entry_package_removed("abrt-addon-kerneloops") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-addon-python_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-addon-python_removed/rule.yml index d8f0d38f23fc..e1ecc296bc96 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-addon-python_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-addon-python_removed/rule.yml @@ -15,7 +15,7 @@ severity: low references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-addon-python") }}} +{{{ complete_ocil_entry_package_removed("abrt-addon-python") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-cli_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-cli_removed/rule.yml index 389988e539c4..e693756ef912 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-cli_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-cli_removed/rule.yml @@ -19,7 +19,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-cli") }}} +{{{ complete_ocil_entry_package_removed("abrt-cli") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-libs_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-libs_removed/rule.yml index 507a42f72223..451a40cee22c 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-libs_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-libs_removed/rule.yml @@ -15,7 +15,7 @@ references: srg: SRG-OS-000095-GPOS-00049 stigid@ol8: OL08-00-040001 -{{{ complete_ocil_entry_package(package="abrt-libs") }}} +{{{ complete_ocil_entry_package_removed("abrt-libs") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-plugin-logger_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-plugin-logger_removed/rule.yml index 122886e14b9c..57db060dbe25 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-plugin-logger_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-plugin-logger_removed/rule.yml @@ -19,7 +19,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-plugin-logger") }}} +{{{ complete_ocil_entry_package_removed("abrt-plugin-logger") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-plugin-rhtsupport_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-plugin-rhtsupport_removed/rule.yml index 09bb7b5ae42e..1cdafc35c8eb 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-plugin-rhtsupport_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-plugin-rhtsupport_removed/rule.yml @@ -19,7 +19,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-plugin-rhtsupport") }}} +{{{ complete_ocil_entry_package_removed("abrt-plugin-rhtsupport") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-plugin-sosreport_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-plugin-sosreport_removed/rule.yml index 6732e5b1a79d..d6542f276b01 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-plugin-sosreport_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-plugin-sosreport_removed/rule.yml @@ -18,7 +18,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="abrt-plugin-sosreport") }}} +{{{ complete_ocil_entry_package_removed("abrt-plugin-sosreport") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_abrt-server-info-page_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_abrt-server-info-page_removed/rule.yml index 0b108df2e7e7..54dfb557de0a 100644 --- a/linux_os/guide/system/software/system-tools/package_abrt-server-info-page_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_abrt-server-info-page_removed/rule.yml @@ -15,7 +15,7 @@ references: srg: SRG-OS-000095-GPOS-00049 stigid@ol8: OL08-00-040001 -{{{ complete_ocil_entry_package(package="abrt-server-info-page") }}} +{{{ complete_ocil_entry_package_removed("abrt-server-info-page") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_binutils_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_binutils_installed/rule.yml index 75b91a333e64..2b9873059ece 100644 --- a/linux_os/guide/system/software/system-tools/package_binutils_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_binutils_installed/rule.yml @@ -16,9 +16,7 @@ severity: medium identifiers: cce@rhel8: CCE-82989-5 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="binutils") }}}' +{{{ complete_ocil_entry_package_installed("binutils") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/system-tools/package_cryptsetup-luks_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_cryptsetup-luks_installed/rule.yml index d1a75d5bc5a7..d00b4eaf70b6 100644 --- a/linux_os/guide/system/software/system-tools/package_cryptsetup-luks_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_cryptsetup-luks_installed/rule.yml @@ -20,9 +20,7 @@ identifiers: cce@rhel9: CCE-86612-9 cce@rhel10: CCE-87541-9 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="cryptsetup") }}}' +{{{ complete_ocil_entry_package_installed("cryptsetup") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/system-tools/package_dnf-plugin-subscription-manager_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_dnf-plugin-subscription-manager_installed/rule.yml index 8f85f0d165d4..93e5309e0479 100644 --- a/linux_os/guide/system/software/system-tools/package_dnf-plugin-subscription-manager_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_dnf-plugin-subscription-manager_installed/rule.yml @@ -21,9 +21,7 @@ references: ospp: FPT_TUD_EXT.1,FPT_TUD_EXT.2 srg: SRG-OS-000366-GPOS-00153 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="dnf-plugin-subscription-manager") }}}' +{{{ complete_ocil_entry_package_installed("dnf-plugin-subscription-manager") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/system-tools/package_geolite2-city_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_geolite2-city_removed/rule.yml index 12af635a5ec3..838b2f0a88da 100644 --- a/linux_os/guide/system/software/system-tools/package_geolite2-city_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_geolite2-city_removed/rule.yml @@ -14,7 +14,7 @@ severity: low identifiers: cce@rhel8: CCE-82939-0 -{{{ complete_ocil_entry_package(package="geolite2-city") }}} +{{{ complete_ocil_entry_package_removed("geolite2-city") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_geolite2-country_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_geolite2-country_removed/rule.yml index 26cd1d47c24b..b8e533ce3ec5 100644 --- a/linux_os/guide/system/software/system-tools/package_geolite2-country_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_geolite2-country_removed/rule.yml @@ -14,7 +14,7 @@ severity: low identifiers: cce@rhel8: CCE-82936-6 -{{{ complete_ocil_entry_package(package="geolite2-country") }}} +{{{ complete_ocil_entry_package_removed("geolite2-country") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_gnutls-utils_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_gnutls-utils_installed/rule.yml index 18ab75439f94..d72cc37d3614 100644 --- a/linux_os/guide/system/software/system-tools/package_gnutls-utils_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_gnutls-utils_installed/rule.yml @@ -25,9 +25,7 @@ references: ospp: FIA_X509_EXT.1,FIA_X509_EXT.1.1,FIA_X509_EXT.2 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="gnutls-utils") }}}' +{{{ complete_ocil_entry_package_installed("gnutls-utils") }}} fixtext: '{{{ fixtext_package_installed("gnutls-utils") }}}' @@ -37,3 +35,5 @@ template: name: package_installed vars: pkgname: gnutls-utils + +platform: system_with_kernel diff --git a/linux_os/guide/system/software/system-tools/package_gssproxy_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_gssproxy_removed/rule.yml index ab99ff48c20f..a8c251de8d2a 100644 --- a/linux_os/guide/system/software/system-tools/package_gssproxy_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_gssproxy_removed/rule.yml @@ -22,7 +22,7 @@ references: srg: SRG-OS-000095-GPOS-00049,SRG-OS-000480-GPOS-00227 stigid@ol8: OL08-00-040370 -{{{ complete_ocil_entry_package(package="gssproxy") }}} +{{{ complete_ocil_entry_package_removed("gssproxy") }}} srg_requirement: '{{{ srg_requirement_package_removed("gssproxy") }}}' @@ -31,6 +31,10 @@ fixtext: '{{{ fixtext_package_removed("gssproxy") }}}' platforms: {{{ rule_notapplicable_when_ovirt_installed() | indent(4)}}} +{{% if "ol" in families %}} +platform: not nfs_mount_defined +{{% endif %}} + warnings: {{{ warning_ovirt_rule_notapplicable("RHV uses NFS storage, which has dependency on gssproxy") | indent(4) }}} diff --git a/linux_os/guide/system/software/system-tools/package_iprutils_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_iprutils_removed/rule.yml index c337bda264ce..72973e86b50a 100644 --- a/linux_os/guide/system/software/system-tools/package_iprutils_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_iprutils_removed/rule.yml @@ -21,7 +21,7 @@ references: srg: SRG-OS-000095-GPOS-00049,SRG-OS-000480-GPOS-00227 stigid@ol8: OL08-00-040380 -{{{ complete_ocil_entry_package(package="iprutils") }}} +{{{ complete_ocil_entry_package_removed("iprutils") }}} fixtext: '{{{ fixtext_package_removed("iprutils") }}}' diff --git a/linux_os/guide/system/software/system-tools/package_krb5-workstation_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_krb5-workstation_removed/rule.yml index d925c313f957..9787a9e11abc 100644 --- a/linux_os/guide/system/software/system-tools/package_krb5-workstation_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_krb5-workstation_removed/rule.yml @@ -32,7 +32,7 @@ platforms: warnings: {{{ warning_ovirt_rule_notapplicable("RHV hosts require ipa-client package, which has dependency on krb5-workstation") | indent(4) }}} -{{{ complete_ocil_entry_package(package="krb5-workstation") }}} +{{{ complete_ocil_entry_package_removed("krb5-workstation") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_libcap-ng-utils_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_libcap-ng-utils_installed/rule.yml index 96c272175642..2719904b4e97 100644 --- a/linux_os/guide/system/software/system-tools/package_libcap-ng-utils_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_libcap-ng-utils_installed/rule.yml @@ -19,10 +19,8 @@ identifiers: references: srg: SRG-OS-000445-GPOS-00199 - -ocil_clause: 'the package is not installed' -ocil: '{{{ ocil_package(package="libcap-ng-utils") }}}' +{{{ complete_ocil_entry_package_installed("libcap-ng-utils") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/system-tools/package_libdnf-plugin-subscription-manager_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_libdnf-plugin-subscription-manager_installed/rule.yml index 40c593787229..c513d51ad843 100644 --- a/linux_os/guide/system/software/system-tools/package_libdnf-plugin-subscription-manager_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_libdnf-plugin-subscription-manager_installed/rule.yml @@ -21,11 +21,11 @@ references: ospp: FPT_TUD_EXT.1,FPT_TUD_EXT.2 srg: SRG-OS-000366-GPOS-00153 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="libdnf-plugin-subscription-manager") }}}' +{{{ complete_ocil_entry_package_installed("libdnf-plugin-subscription-manager") }}} template: name: package_installed vars: pkgname: libdnf-plugin-subscription-manager + +platform: package[dnf] diff --git a/linux_os/guide/system/software/system-tools/package_libreport-plugin-logger_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_libreport-plugin-logger_removed/rule.yml index bdfed2221079..8e24ebd8945e 100644 --- a/linux_os/guide/system/software/system-tools/package_libreport-plugin-logger_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_libreport-plugin-logger_removed/rule.yml @@ -23,7 +23,7 @@ references: srg: SRG-OS-000095-GPOS-00049 stigid@ol8: OL08-00-040001 -{{{ complete_ocil_entry_package(package="libreport-plugin-logger") }}} +{{{ complete_ocil_entry_package_removed("libreport-plugin-logger") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_libreport-plugin-rhtsupport_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_libreport-plugin-rhtsupport_removed/rule.yml index aa86cedf173f..dd889497c51a 100644 --- a/linux_os/guide/system/software/system-tools/package_libreport-plugin-rhtsupport_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_libreport-plugin-rhtsupport_removed/rule.yml @@ -18,7 +18,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="libreport-plugin-rhtsupport") }}} +{{{ complete_ocil_entry_package_removed("libreport-plugin-rhtsupport") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_nss-tools_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_nss-tools_installed/rule.yml index 4a08ea97b8bf..7fd84173e32f 100644 --- a/linux_os/guide/system/software/system-tools/package_nss-tools_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_nss-tools_installed/rule.yml @@ -23,9 +23,7 @@ references: ospp: FMT_SMF_EXT.1 srg: SRG-OS-000480-GPOS-00227 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="nss-tools") }}}' +{{{ complete_ocil_entry_package_installed("nss-tools") }}} fixtext: '{{{ fixtext_package_installed("nss-tools") }}}' @@ -36,3 +34,5 @@ template: name: package_installed vars: pkgname: nss-tools + +platform: system_with_kernel diff --git a/linux_os/guide/system/software/system-tools/package_openscap-scanner_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_openscap-scanner_installed/rule.yml index 013af5517cfd..110df4185625 100644 --- a/linux_os/guide/system/software/system-tools/package_openscap-scanner_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_openscap-scanner_installed/rule.yml @@ -21,10 +21,8 @@ identifiers: references: ospp: AGD_PRE.1,AGD_OPE.1 srg: SRG-OS-000480-GPOS-00227,SRG-OS-000191-GPOS-00080 - -ocil_clause: 'the package is not installed' -ocil: '{{{ ocil_package(package="openscap-scanner") }}}' +{{{ complete_ocil_entry_package_installed("openscap-scanner") }}} fixtext: '{{{ fixtext_package_installed("openscap-scanner") }}}' @@ -35,3 +33,5 @@ template: name: package_installed vars: pkgname: openscap-scanner + +platform: system_with_kernel diff --git a/linux_os/guide/system/software/system-tools/package_pigz_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_pigz_removed/rule.yml index 953c593ae565..664eff36cda4 100644 --- a/linux_os/guide/system/software/system-tools/package_pigz_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_pigz_removed/rule.yml @@ -20,7 +20,7 @@ identifiers: references: srg: SRG-OS-000433-GPOS-00192 -{{{ complete_ocil_entry_package(package="pigz") }}} +{{{ complete_ocil_entry_package_removed("pigz") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_python3-abrt-addon_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_python3-abrt-addon_removed/rule.yml index b1e896461485..eef0ff8c6b49 100644 --- a/linux_os/guide/system/software/system-tools/package_python3-abrt-addon_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_python3-abrt-addon_removed/rule.yml @@ -18,7 +18,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 -{{{ complete_ocil_entry_package(package="python3-abrt-addon") }}} +{{{ complete_ocil_entry_package_removed("python3-abrt-addon") }}} template: name: package_removed diff --git a/linux_os/guide/system/software/system-tools/package_rear_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_rear_installed/rule.yml index cedb1b39211b..8f5dd735e0a0 100644 --- a/linux_os/guide/system/software/system-tools/package_rear_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_rear_installed/rule.yml @@ -17,10 +17,7 @@ identifiers: cce@rhel9: CCE-83503-3 cce@rhel10: CCE-90643-8 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="rear") }}}' - +{{{ complete_ocil_entry_package_installed("rear") }}} platforms: - not ((s390x_arch and os_linux[rhel]<=8.4) or (os_linux[rhel]>=9.0 and aarch64_arch) or (os_linux[ol]>=9.0 and aarch64_arch)) diff --git a/linux_os/guide/system/software/system-tools/package_rng-tools_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_rng-tools_installed/rule.yml index 8d387db19622..2f6d8d5342d9 100644 --- a/linux_os/guide/system/software/system-tools/package_rng-tools_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_rng-tools_installed/rule.yml @@ -21,15 +21,21 @@ references: srg: SRG-OS-000480-GPOS-00227 stigid@ol8: OL08-00-010472 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="rng-tools") }}}' +{{{ complete_ocil_entry_package_installed("rng-tools") }}} fixtext: '{{{ fixtext_package_installed("rng-tools") }}}' srg_requirement: '{{{ srg_requirement_package_installed("rng-tools") }}}' +{{% if product == "rhel8" %}} +platform: (os_linux[rhel]<=8.3 or (os_linux[rhel]>=8.4 and not runtime_kernel_fips_enabled) and system_with_kernel) +warnings: + - general: |- + For RHEL versions 8.4 and above running with kernel FIPS mode enabled this rule is not applicable. + The in-kernel deterministic random bit generator (DRBG) is used in FIPS mode instead. +{{% else %}} platform: system_with_kernel and not runtime_kernel_fips_enabled +{{% endif %}} template: name: package_installed diff --git a/linux_os/guide/system/software/system-tools/package_scap-security-guide_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_scap-security-guide_installed/rule.yml index 25b128edc6a7..75f64b5f6de0 100644 --- a/linux_os/guide/system/software/system-tools/package_scap-security-guide_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_scap-security-guide_installed/rule.yml @@ -27,10 +27,8 @@ identifiers: references: ospp: AGD_PRE.1,AGD_OPE.1 srg: SRG-OS-000480-GPOS-00227 - -ocil_clause: 'the package is not installed' -ocil: '{{{ ocil_package(package="scap-security-guide") }}}' +{{{ complete_ocil_entry_package_installed("scap-security-guide") }}} fixtext: "{{{ fixtext_package_installed("scap-security-guide") }}}" @@ -40,3 +38,5 @@ template: name: package_installed vars: pkgname: scap-security-guide + +platform: system_with_kernel diff --git a/linux_os/guide/system/software/system-tools/package_sequoia-sq_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_sequoia-sq_installed/rule.yml index 0527c91fd6f6..525ff8220296 100644 --- a/linux_os/guide/system/software/system-tools/package_sequoia-sq_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_sequoia-sq_installed/rule.yml @@ -22,11 +22,11 @@ references: ospp: FPT_TUD_EXT.1,FPT_TUD_EXT.2 srg: SRG-OS-000366-GPOS-00153 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="sequoia-sq") }}}' +{{{ complete_ocil_entry_package_installed("sequoia-sq") }}} template: name: package_installed vars: pkgname: sequoia-sq + +platform: system_with_kernel diff --git a/linux_os/guide/system/software/system-tools/package_subscription-manager_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_subscription-manager_installed/rule.yml index cc5603baa841..dae058993c4d 100644 --- a/linux_os/guide/system/software/system-tools/package_subscription-manager_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_subscription-manager_installed/rule.yml @@ -31,9 +31,7 @@ references: ospp: FPT_TUD_EXT.1,FPT_TUD_EXT.2 srg: SRG-OS-000366-GPOS-00153 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="subscription-manager") }}}' +{{{ complete_ocil_entry_package_installed("subscription-manager") }}} template: name: package_installed @@ -44,3 +42,5 @@ fixtext: |- {{{ describe_package_install(package="subscription-manager") }}} srg_requirement: '{{{ srg_requirement_package_installed("subscription-manager") }}}' + +platform: system_with_kernel diff --git a/linux_os/guide/system/software/system-tools/package_tar_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_tar_installed/rule.yml index c12e9b276883..8c4c74b0e74a 100644 --- a/linux_os/guide/system/software/system-tools/package_tar_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_tar_installed/rule.yml @@ -17,9 +17,7 @@ severity: medium identifiers: cce@rhel8: CCE-82965-5 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="tar") }}}' +{{{ complete_ocil_entry_package_installed("tar") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/system-tools/package_tuned_removed/rule.yml b/linux_os/guide/system/software/system-tools/package_tuned_removed/rule.yml index f0f0bb5cd60c..481da09c1966 100644 --- a/linux_os/guide/system/software/system-tools/package_tuned_removed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_tuned_removed/rule.yml @@ -23,7 +23,7 @@ references: srg: SRG-OS-000095-GPOS-00049,SRG-OS-000480-GPOS-00227 stigid@ol8: OL08-00-040390 -{{{ complete_ocil_entry_package(package="tuned") }}} +{{{ complete_ocil_entry_package_removed("tuned") }}} fixtext: '{{{ fixtext_package_removed("tuned") }}}' diff --git a/linux_os/guide/system/software/system-tools/package_vim_installed/rule.yml b/linux_os/guide/system/software/system-tools/package_vim_installed/rule.yml index 4884067bf734..3107fb374ea5 100644 --- a/linux_os/guide/system/software/system-tools/package_vim_installed/rule.yml +++ b/linux_os/guide/system/software/system-tools/package_vim_installed/rule.yml @@ -14,9 +14,7 @@ severity: low identifiers: cce@rhel8: CCE-82956-4 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="vim-enhanced") }}}' +{{{ complete_ocil_entry_package_installed("vim-enhanced") }}} template: name: package_installed diff --git a/linux_os/guide/system/software/updating/disable_weak_deps/rule.yml b/linux_os/guide/system/software/updating/disable_weak_deps/rule.yml index f8fc38d995b3..65cfaa1a3987 100644 --- a/linux_os/guide/system/software/updating/disable_weak_deps/rule.yml +++ b/linux_os/guide/system/software/updating/disable_weak_deps/rule.yml @@ -23,3 +23,5 @@ ocil: |-
# grep -Pi -- '^\h*install_weak_deps\h*=\h*(0|false|no)\b' /etc/dnf/dnf.conf
The output should return the following:
install_weak_deps = 0
+ +platform: package[dnf] diff --git a/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/ansible/shared.yml b/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/ansible/shared.yml index 015c5b02954b..72542ea67a00 100644 --- a/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/ansible/shared.yml +++ b/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/ansible/shared.yml @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel +# platform = multi_platform_rhel,multi_platform_ol # reboot = false # strategy = enable # complexity = low diff --git a/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/bash/shared.sh b/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/bash/shared.sh index eb390cd1ffcc..96b374c77930 100644 --- a/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/bash/shared.sh +++ b/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/bash/shared.sh @@ -1,4 +1,4 @@ -# platform = multi_platform_rhel +# platform = multi_platform_rhel,multi_platform_ol function replace_all_gpgcheck { sed -i 's/gpgcheck\s*=.*/gpgcheck=1/g' /etc/yum.repos.d/* diff --git a/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/rule.yml b/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/rule.yml index 61d9c7e3a8f4..5ac5994ae367 100644 --- a/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/rule.yml +++ b/linux_os/guide/system/software/updating/enable_gpgcheck_for_all_repositories/rule.yml @@ -23,6 +23,7 @@ identifiers: references: srg: SRG-OS-000366-GPOS-00153 + stigid@ol8: OL08-00-010370 ocil_clause: 'GPG checking is disabled' diff --git a/linux_os/guide/system/software/updating/ensure_epel_repos_disabled/rule.yml b/linux_os/guide/system/software/updating/ensure_epel_repos_disabled/rule.yml index 7c7546836639..128cc2a0a4d4 100644 --- a/linux_os/guide/system/software/updating/ensure_epel_repos_disabled/rule.yml +++ b/linux_os/guide/system/software/updating/ensure_epel_repos_disabled/rule.yml @@ -29,6 +29,7 @@ identifiers: references: srg: SRG-OS-000095-GPOS-00049 + stigid@ol8: OL08-00-040010 ocil_clause: 'EPEL repository is enabled' diff --git a/linux_os/guide/system/software/updating/ensure_gpgcheck_globally_activated/rule.yml b/linux_os/guide/system/software/updating/ensure_gpgcheck_globally_activated/rule.yml index 2aff24876f21..b1d83b25cc89 100644 --- a/linux_os/guide/system/software/updating/ensure_gpgcheck_globally_activated/rule.yml +++ b/linux_os/guide/system/software/updating/ensure_gpgcheck_globally_activated/rule.yml @@ -56,7 +56,6 @@ references: pcidss: Req-6.2 srg: SRG-OS-000366-GPOS-00153 stigid@ol7: OL07-00-020050 - stigid@ol8: OL08-00-010370 stigid@sle12: SLES-12-010550 stigid@sle15: SLES-15-010430 diff --git a/linux_os/guide/system/software/updating/ensure_gpgcheck_never_disabled/rule.yml b/linux_os/guide/system/software/updating/ensure_gpgcheck_never_disabled/rule.yml index 37ac17d51f4e..bcb25fb3fb8f 100644 --- a/linux_os/guide/system/software/updating/ensure_gpgcheck_never_disabled/rule.yml +++ b/linux_os/guide/system/software/updating/ensure_gpgcheck_never_disabled/rule.yml @@ -48,7 +48,6 @@ references: ospp: FPT_TUD_EXT.1,FPT_TUD_EXT.2 pcidss: Req-6.2 srg: SRG-OS-000366-GPOS-00153 - stigid@ol8: OL08-00-010370 ocil_clause: 'GPG checking is disabled' @@ -76,3 +75,7 @@ checktext: |- gpgcheck = 1 If "gpgcheck" is not set to "1" for all returned lines, this is a finding. + +{{% if product == "hummingbird" %}} +platform: package[dnf] +{{% endif %}} diff --git a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/ansible/shared.yml b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/ansible/shared.yml index 8080f0c6ced3..36c10b74836b 100644 --- a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/ansible/shared.yml +++ b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/ansible/shared.yml @@ -18,11 +18,27 @@ changed_when: false failed_when: False check_mode: no - register: gpg_fingerprints + register: sq_fingerprints + when: ansible_distribution_version is version('10.1', '>=') - name: "{{{ rule_title }}}: Set Fact - Installed GPG Fingerprints (sq format)" ansible.builtin.set_fact: - gpg_installed_fingerprints: "{{ gpg_fingerprints.stdout | regex_findall('Fingerprint:\\s*([0-9A-Fa-f]+)', '\\1') | list }}" + gpg_installed_fingerprints: "{{ sq_fingerprints.stdout | regex_findall('Fingerprint:\\s*([0-9A-Fa-f]+)', '\\1') | list }}" + when: ansible_distribution_version is version('10.1', '>=') + +- name: "{{{ rule_title }}}: Read signatures in GPG key" + # According to /usr/share/doc/gnupg2/DETAILS fingerprints are in "fpr" record in field 10 + ansible.builtin.command: gpg --show-keys --with-fingerprint --with-colons "/etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release" + changed_when: False + register: gpg_fingerprints + failed_when: False + check_mode: no + when: ansible_distribution_version is version('10.1', '<') + +- name: "{{{ rule_title }}}: Set Fact - Installed GPG Fingerprints (gpg format)" + ansible.builtin.set_fact: + gpg_installed_fingerprints: "{{ gpg_fingerprints.stdout | regex_findall('^pub.*\\n(?:^fpr[:]*)([0-9A-Fa-f]*)', '\\1') | list }}" + when: ansible_distribution_version is version('10.1', '<') {{% else %}} # RHEL 8, 9 and other versions: Use gpg command @@ -40,19 +56,31 @@ {{% endif %}} -- name: "{{{ rule_title }}}: Set Fact - Valid fingerprints" +{{% if "rhel" in families and major_version_ordinal >= 10 %}} +- name: "{{{ rule_title }}}: Set Fact - Valid fingerprints (without PQC)" + ansible.builtin.set_fact: + gpg_valid_fingerprints: + - "{{{ release_key_fingerprint }}}" + - "{{{ auxiliary_key_fingerprint }}}" + when: ansible_distribution_version is version('10.1', '<') + +- name: "{{{ rule_title }}}: Set Fact - Valid fingerprints (with PQC)" ansible.builtin.set_fact: gpg_valid_fingerprints: - "{{{ release_key_fingerprint }}}" - "{{{ auxiliary_key_fingerprint }}}" -{{% if "rhel" in families and major_version_ordinal >= 10 %}} - "{{{ pqc_key_fingerprint }}}" + when: ansible_distribution_version is version('10.1', '>=') +{{% else %}} +- name: "{{{ rule_title }}}: Set Fact - Valid fingerprints" + ansible.builtin.set_fact: + gpg_valid_fingerprints: + - "{{{ release_key_fingerprint }}}" + - "{{{ auxiliary_key_fingerprint }}}" {{% endif %}} - name: "{{{ rule_title }}}: Import RedHat GPG key" - ansible.builtin.rpm_key: - state: present - key: /etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release + ansible.builtin.command: rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release when: - gpg_key_directory_permission.stat.mode <= '0755' - (gpg_installed_fingerprints | difference(gpg_valid_fingerprints)) | length == 0 diff --git a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/bash/shared.sh b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/bash/shared.sh index 53931cd4009d..0ce5135a6f4a 100644 --- a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/bash/shared.sh +++ b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/bash/shared.sh @@ -17,7 +17,12 @@ then # If they are safe, try to obtain fingerprints from the key file # (to ensure there won't be e.g. CRC error). {{% if "rhel" in families and major_version_ordinal >= 10 %}} - readarray -t GPG_OUT < <(sq inspect "$REDHAT_RELEASE_KEY" | grep Fingerprint: | cut -d ":" -f 2) + if {{{ bash_os_linux_conditional("rhel", expected_ver="10.1", op=">=") | trim }}} + then + readarray -t GPG_OUT < <(sq inspect "$REDHAT_RELEASE_KEY" | grep Fingerprint: | cut -d ":" -f 2) + else + readarray -t GPG_OUT < <(gpg --show-keys --with-fingerprint --with-colons "$REDHAT_RELEASE_KEY" | grep -A1 "^pub" | grep "^fpr" | cut -d ":" -f 10) + fi {{% else %}} readarray -t GPG_OUT < <(gpg --show-keys --with-fingerprint --with-colons "$REDHAT_RELEASE_KEY" | grep -A1 "^pub" | grep "^fpr" | cut -d ":" -f 10) {{% endif %}} @@ -25,13 +30,16 @@ then # No CRC error, safe to proceed if [ "${GPG_RESULT}" -eq "0" ] then + # If $REDHAT_RELEASE_KEY file doesn't contain any keys with unknown fingerprint, import it {{% if "rhel" in families and major_version_ordinal >= 10 %}} - echo "${GPG_OUT[*]}" | grep -vE "${REDHAT_RELEASE_FINGERPRINT}|${REDHAT_AUXILIARY_FINGERPRINT}|${REDHAT_PQC_FINGERPRINT}" || { + if {{{ bash_os_linux_conditional("rhel", expected_ver="10.1", op=">=") | trim }}} + then + echo "${GPG_OUT[*]}" | grep -vE "${REDHAT_RELEASE_FINGERPRINT}|${REDHAT_AUXILIARY_FINGERPRINT}|${REDHAT_PQC_FINGERPRINT}" || rpm --import "${REDHAT_RELEASE_KEY}" + else + echo "${GPG_OUT[*]}" | grep -vE "${REDHAT_RELEASE_FINGERPRINT}|${REDHAT_AUXILIARY_FINGERPRINT}" || rpm --import "${REDHAT_RELEASE_KEY}" + fi {{% else %}} - echo "${GPG_OUT[*]}" | grep -vE "${REDHAT_RELEASE_FINGERPRINT}|${REDHAT_AUXILIARY_FINGERPRINT}" || { + echo "${GPG_OUT[*]}" | grep -vE "${REDHAT_RELEASE_FINGERPRINT}|${REDHAT_AUXILIARY_FINGERPRINT}" || rpm --import "${REDHAT_RELEASE_KEY}" {{% endif %}} - # If $REDHAT_RELEASE_KEY file doesn't contain any keys with unknown fingerprint, import it - rpm --import "${REDHAT_RELEASE_KEY}" - } fi fi diff --git a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/oval/shared.xml b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/oval/shared.xml index 6871feba83b3..52461f678900 100644 --- a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/oval/shared.xml +++ b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/oval/shared.xml @@ -13,8 +13,13 @@ {{% if "rhel" in families and major_version_ordinal >= 10 %}} - + + + + + + + {{% endif %}} {{%- if centos_major_version %}} @@ -88,5 +93,22 @@ {{%- endif %}} +{{% if "rhel" in families and major_version_ordinal >= 10 %}} + + + + + + + /etc/os-release + ^VERSION_ID=["']?([\w.]+)["']?$ + 1 + + + + 10.1 + +{{% endif %}} + {{% endif %}} diff --git a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/rule.yml b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/rule.yml index 1baf1173b992..31b49725a950 100644 --- a/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/rule.yml +++ b/linux_os/guide/system/software/updating/ensure_redhat_gpgkey_installed/rule.yml @@ -6,8 +6,10 @@ title: 'Ensure Red Hat GPG Key Installed' description: |- To ensure the system can cryptographically verify base software packages come from Red Hat (and to connect to the Red Hat Network to receive them), - the Red Hat GPG key must properly be installed. To install the Red Hat GPG - key, run: + the Red Hat GPG key must properly be installed. + + {{% if product != "hummingbird" %}} + To install the Red Hat GPG key, run:
$ sudo subscription-manager register
If the system is not connected to the Internet or an RHN Satellite, then @@ -20,6 +22,7 @@ description: |- Alternatively, the key may be pre-loaded during the RHEL installation. In such cases, the key can be installed by running the following command:
sudo rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY-redhat-release
+ {{% endif %}} rationale: |- diff --git a/linux_os/guide/system/software/updating/group.yml b/linux_os/guide/system/software/updating/group.yml index fbc87761edda..5f9e49707916 100644 --- a/linux_os/guide/system/software/updating/group.yml +++ b/linux_os/guide/system/software/updating/group.yml @@ -3,6 +3,10 @@ documentation_complete: true title: 'Updating Software' description: |- +{{% if product == "hummingbird" %}} + {{{ full_name }}} containers and container images contain an installed software + catalog called the RPM database, which records metadata of installed RPM packages. +{{% else %}} The {{{ pkg_manager }}} command line tool is used to install and update software packages. The system also provides a graphical software update tool in the System menu, in the Administration submenu, @@ -13,3 +17,4 @@ description: |- {{{ pkg_manager }}} or the graphical Software Update for all software installation allows for insight into the current inventory of installed software on the system.

+{{% endif %}} diff --git a/linux_os/guide/system/software/updating/package_dnf-automatic_installed/rule.yml b/linux_os/guide/system/software/updating/package_dnf-automatic_installed/rule.yml index f31123960e9d..0e7e82f0ebdb 100644 --- a/linux_os/guide/system/software/updating/package_dnf-automatic_installed/rule.yml +++ b/linux_os/guide/system/software/updating/package_dnf-automatic_installed/rule.yml @@ -23,9 +23,7 @@ references: ospp: FPT_TUD_EXT.1,FPT_TUD_EXT.2 srg: SRG-OS-000191-GPOS-00080 -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="dnf-automatic") }}}' +{{{ complete_ocil_entry_package_installed("dnf-automatic") }}} platform: not bootc and not container diff --git a/linux_os/guide/system/software/updating/package_gnome_software_installed/rule.yml b/linux_os/guide/system/software/updating/package_gnome_software_installed/rule.yml index 2455146eac67..07234de6d7da 100644 --- a/linux_os/guide/system/software/updating/package_gnome_software_installed/rule.yml +++ b/linux_os/guide/system/software/updating/package_gnome_software_installed/rule.yml @@ -10,9 +10,7 @@ rationale: 'The GNOME software package must be installed so that it can be used severity: medium -ocil_clause: 'the package is not installed' - -ocil: '{{{ ocil_package(package="gnome-software") }}}' +{{{ complete_ocil_entry_package_installed("gnome-software") }}} fixtext: |- {{{ describe_package_install("gnome-software") }}} diff --git a/linux_os/guide/system/software/updating/security_patches_up_to_date/policy/stig/shared.yml b/linux_os/guide/system/software/updating/security_patches_up_to_date/policy/stig/shared.yml index 19be55338ce9..de1883442b3f 100644 --- a/linux_os/guide/system/software/updating/security_patches_up_to_date/policy/stig/shared.yml +++ b/linux_os/guide/system/software/updating/security_patches_up_to_date/policy/stig/shared.yml @@ -12,6 +12,8 @@ vuldiscussion: |- Installing software updates is a fundamental mitigation against the exploitation of publicly known vulnerabilities. If the most recent security patches and updates are not installed, unauthorized users may take advantage of weaknesses in the unpatched software. The lack of prompt attention to patching could result in a system compromise. checktext: |- + Note: If the system is not connected to the internet, this requirement is not applicable. + Verify {{{ full_name }}} security patches and updates are installed and up to date. Updates are required to be applied with a frequency determined by organizational policy. Obtain the list of available package security updates from Red Hat. The URL for updates is https://access.redhat.com/errata-search/. It is important to note that updates provided by Red Hat may not be present on the system if the underlying packages are not installed. diff --git a/ocp-resources/ds-build-remote.yaml b/ocp-resources/ds-build-remote.yaml index cb7d35841319..a2238e5c5cd0 100644 --- a/ocp-resources/ds-build-remote.yaml +++ b/ocp-resources/ds-build-remote.yaml @@ -25,12 +25,13 @@ spec: RUN microdnf -y install cmake make git /usr/bin/python3 python3-pyyaml python3-jinja2 openscap-utils - RUN ./build_product --datastream-only --debug ocp4 rhcos4 + RUN ./build_product --datastream --debug ocp4 rhcos4 --cel-content=ocp4 FROM registry.access.redhat.com/ubi8/ubi-minimal WORKDIR / COPY --from=builder /content/build/ssg-ocp4-ds.xml . COPY --from=builder /content/build/ssg-rhcos4-ds.xml . + COPY --from=builder /content/build/ocp4-cel-content.yaml . strategy: dockerStrategy: noCache: true diff --git a/ocp-resources/ds-from-local-build.yaml b/ocp-resources/ds-from-local-build.yaml index 024e5d12a05e..93857fa3af50 100644 --- a/ocp-resources/ds-from-local-build.yaml +++ b/ocp-resources/ds-from-local-build.yaml @@ -20,6 +20,7 @@ spec: FROM registry.access.redhat.com/ubi8/ubi-minimal WORKDIR / COPY *-ds.xml . + COPY *-cel-content.yaml . strategy: dockerStrategy: noCache: true diff --git a/product_properties/10-aide-audit.yml b/product_properties/10-aide-audit.yml index 5918d9b9c7bf..5297de93f5b2 100644 --- a/product_properties/10-aide-audit.yml +++ b/product_properties/10-aide-audit.yml @@ -21,4 +21,7 @@ overrides: {{% elif "rhel-like" not in families %}} aide_also_checks_rsyslog: "no" aide_also_checks_audispd: "yes" +{{% elif "amzn" in families %}} + aide_also_checks_rsyslog: "yes" + aide_also_checks_audispd: "yes" {{% endif %}} diff --git a/product_properties/10-audit-binaries.yml b/product_properties/10-audit-binaries.yml index 9fa2da7022e7..0c17ebfdbd1a 100644 --- a/product_properties/10-audit-binaries.yml +++ b/product_properties/10-audit-binaries.yml @@ -11,9 +11,13 @@ default: - /sbin/audispd {{% endif %}} - /sbin/augenrules - {{% if 'rhel' in product or product == 'sle16' %}} + {{% if 'rhel' in product or product == 'sle16' or 'ubuntu' in product %}} - /sbin/audisp-syslog {{% endif %}} + {{% if 'ubuntu' in product %}} + - /sbin/audisp-remote + - /sbin/audispd-zos-remote + {{% endif %}} overrides: {{% if product == 'sle15' %}} audit_binaries: @@ -25,3 +29,13 @@ overrides: - /usr/sbin/augenrules - /usr/sbin/audisp-syslog {{% endif %}} +{{% if product == 'al2023' %}} + audit_binaries: + - /sbin/auditctl + - /sbin/aureport + - /sbin/ausearch + - /sbin/autrace + - /sbin/auditd + - /sbin/augenrules + - /sbin/audisp-syslog +{{% endif %}} diff --git a/product_properties/10-grub.yml b/product_properties/10-grub.yml index b2c17c23356b..cefccdc02ba7 100644 --- a/product_properties/10-grub.yml +++ b/product_properties/10-grub.yml @@ -12,6 +12,9 @@ overrides: grub2_uefi_boot_path: "/boot/efi/EFI/redhat" {{% endif %}} {{% endif %}} +{{% if "amzn" in families %}} + grub2_uefi_boot_path: "/boot/efi/EFI/amzn" +{{% endif %}} {{% if "suse" in families %}} grub_helper_executable: "grub2-mkconfig" {{% if major_version_ordinal <= 12 %}} diff --git a/product_properties/10-login-defs.yml b/product_properties/10-login-defs.yml index 0ba95753f766..2b2b4d7db7fd 100644 --- a/product_properties/10-login-defs.yml +++ b/product_properties/10-login-defs.yml @@ -1,7 +1,5 @@ default: login_defs_path: "/etc/login.defs" + login_defs_defaults_path: "/usr/etc/login.defs" + login_defs_drop_in_path: "/etc/login.defs.d/oscap.login.defs" -overrides: -{{% if product in [ 'slmicro6', 'sle16' ] %}} - login_defs_path: "/usr/etc/login.defs" -{{% endif %}} diff --git a/product_properties/10-pam-faillock-conf.yml b/product_properties/10-pam-faillock-conf.yml index 06735cd3e5bf..7d6ee01c1209 100644 --- a/product_properties/10-pam-faillock-conf.yml +++ b/product_properties/10-pam-faillock-conf.yml @@ -1,7 +1,2 @@ default: pam_faillock_conf_path: "/etc/security/faillock.conf" - -overrides: -{{% if product == 'sle16' %}} - pam_faillock_conf_path: "/usr/etc/security/faillock.conf" -{{% endif %}} diff --git a/product_properties/10-pwquality-conf.yml b/product_properties/10-pwquality-conf.yml index 8a991951eb7b..1cda98ab41e9 100644 --- a/product_properties/10-pwquality-conf.yml +++ b/product_properties/10-pwquality-conf.yml @@ -1,7 +1,2 @@ default: pwquality_path: "/etc/security/pwquality.conf" - -overrides: -{{% if product == 'sle16' %}} - pwquality_path: "/usr/lib/security/pwquality.conf" -{{% endif %}} diff --git a/products/al2023/CMakeLists.txt b/products/al2023/CMakeLists.txt index 63f7db32c8c0..185cc8d9ea61 100644 --- a/products/al2023/CMakeLists.txt +++ b/products/al2023/CMakeLists.txt @@ -8,3 +8,13 @@ set(PRODUCT "al2023") ssg_build_product(${PRODUCT}) ssg_build_html_cce_table(${PRODUCT}) + +ssg_build_html_ref_tables("${PRODUCT}" "table-${PRODUCT}-{ref_id}refs" "cis;nist") + +ssg_build_html_profile_table("table-${PRODUCT}-nistrefs-stig" "${PRODUCT}" "stig" "nist") + +ssg_build_html_srgmap_tables(${PRODUCT}) + +ssg_build_html_stig_tables(${PRODUCT}) +ssg_build_html_stig_tables_per_profile(${PRODUCT} "stig") + diff --git a/products/al2023/overlays/srg_support.xml b/products/al2023/overlays/srg_support.xml new file mode 100644 index 000000000000..35a58161f0aa --- /dev/null +++ b/products/al2023/overlays/srg_support.xml @@ -0,0 +1,173 @@ + diff --git a/products/al2023/product.yml b/products/al2023/product.yml index 32cf5501a2e8..9d17263ab854 100644 --- a/products/al2023/product.yml +++ b/products/al2023/product.yml @@ -2,6 +2,9 @@ product: al2023 full_name: Amazon Linux 2023 type: platform +families: + - amzn + benchmark_id: AL-2023 benchmark_root: "../../linux_os/guide" components_root: "../../components" @@ -19,6 +22,7 @@ groups: sshd_distributed_config: "true" faillock_path: "/var/log/faillock" +aide_conf_path: "/etc/aide.conf" release_key_fingerprint: "B21C50FA44A99720EAA72F7FE951904AD832C631" @@ -35,4 +39,4 @@ platform_package_overrides: reference_uris: cis: 'https://www.cisecurity.org/benchmark/amazon_linux/' -journald_conf_dir_path: /etc/systemd/journald.conf.d +journald_conf_dir_path: /etc/systemd/journald.conf diff --git a/products/al2023/profiles/stig.profile b/products/al2023/profiles/stig.profile new file mode 100644 index 000000000000..dace6507e64e --- /dev/null +++ b/products/al2023/profiles/stig.profile @@ -0,0 +1,60 @@ +documentation_complete: true + +metadata: + version: V1R1 + SMEs: + - bordencastle + - Eric-Domeier + +reference: https://www.cyber.mil/stigs/downloads/?_dl_facet_stigs=operating-systems%2Cunix-linux + +title: 'DISA STIG for Amazon Linux 2023' + +description: |- + This profile contains configuration checks that align to the + DISA STIG (Security Technical Implementation Guide) for Amazon Linux 2023. + + DISA STIGs are the configuration standards for DOD IA and IA-enabled + devices/systems. The requirements are derived from the NIST 800-53 + and related documents. + +selections: + - stig_al2023:all + - aide_use_fips_hashes + - aide_build_database + - audit_rules_time_adjtimex + - audit_rules_time_settimeofday + - audit_rules_time_stime + - audit_rules_time_clock_settime + - audit_rules_time_watch_localtime + - audit_rules_usergroup_modification + - audit_rules_networkconfig_modification + - audit_rules_mac_modification + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_unsuccessful_file_modification + - audit_rules_privileged_commands + - audit_rules_media_export + - audit_rules_file_deletion_events + - audit_rules_sysadmin_actions + - audit_rules_kernel_module_loading + - audit_rules_immutable_login_uids + - mount_option_boot_efi_nosuid + - grub2_audit_backlog_limit_argument + - grub2_audit_argument + - file_permissions_var_log_audit + - rsyslog_logging_configured + # Variable refine-values + - sshd_approved_macs=stig_al2023 + diff --git a/products/anolis23/profiles/standard.profile b/products/anolis23/profiles/standard.profile index 2cf3bfda5a31..69e8d39628fc 100644 --- a/products/anolis23/profiles/standard.profile +++ b/products/anolis23/profiles/standard.profile @@ -369,12 +369,14 @@ selections: ## 4.1-ensure-message-of-the-day-is-configured-properly ### Level 1 - banner_etc_motd - - login_banner_text=cis_banners + - motd_banner_text=cis_banners + - motd_banner_contents=cis_default ## 4.2-ensure-local-login-warning-banner-is-configured-properly ### Level 1 - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default ## 4.3-ensure-remote-login-warning-banner-is-configured-properly ### Level 1 diff --git a/products/anolis8/profiles/standard.profile b/products/anolis8/profiles/standard.profile index b60cba9e23d0..91f13490b1ab 100644 --- a/products/anolis8/profiles/standard.profile +++ b/products/anolis8/profiles/standard.profile @@ -369,12 +369,14 @@ selections: ## 4.1-ensure-message-of-the-day-is-configured-properly ### Level 1 - banner_etc_motd - - login_banner_text=cis_banners + - motd_banner_text=cis_banners + - motd_banner_contents=cis_default ## 4.2-ensure-local-login-warning-banner-is-configured-properly ### Level 1 - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default ## 4.3-ensure-remote-login-warning-banner-is-configured-properly ### Level 1 diff --git a/products/debian13/product.yml b/products/debian13/product.yml index 379b4d89eb02..26258a81b9ff 100644 --- a/products/debian13/product.yml +++ b/products/debian13/product.yml @@ -30,6 +30,9 @@ cpes: title: "Debian Linux 13" check_id: installed_OS_is_debian13 +reference_uris: + cis: 'https://www.cisecurity.org/cis-benchmarks/' + # Mapping of CPE platform to package platform_package_overrides: gdm: gdm3 diff --git a/products/debian13/profiles/cis_level1_server.profile b/products/debian13/profiles/cis_level1_server.profile new file mode 100644 index 000000000000..b4e01bcd5cc0 --- /dev/null +++ b/products/debian13/profiles/cis_level1_server.profile @@ -0,0 +1,19 @@ +documentation_complete: true + +metadata: + version: 1.0.0 + +reference: https://www.cisecurity.org/benchmark/debian_linux + +title: 'CIS Debian Benchmark for Level 1 - Server' + +description: |- + This profile defines a baseline that aligns to the "Level 1 - Server" + configuration from the Center for Internet Security® + Debian 13 Benchmark™, v1.0.0, released 2025-12-16. + + This profile includes Center for Internet Security® + Debian 13 Benchmark™ content. + +selections: + - cis_debian13:all:l1_server diff --git a/products/fedora/profiles/ospp.profile b/products/fedora/profiles/ospp.profile index 601f0e2375ec..df6ba225251a 100644 --- a/products/fedora/profiles/ospp.profile +++ b/products/fedora/profiles/ospp.profile @@ -103,11 +103,14 @@ selections: - rsyslog_remote_loghost - auditd_audispd_encrypt_sent_records - login_banner_text=usgcb_default + - login_banner_contents=usgcb_default - sshd_enable_warning_banner - banner_etc_issue - sshd_rekey_limit - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text + - dconf_login_banner_text=usgcb_default + - dconf_login_banner_contents=usgcb_default - audit_rules_login_events_faillock - audit_rules_login_events_lastlog - audit_rules_login_events_tallylog @@ -224,6 +227,7 @@ selections: - configure_bind_crypto_policy - configure_crypto_policy - chronyd_no_chronyc_network + - chronyd_configure_local_socket - chronyd_client_only - kernel_module_atm_disabled - kernel_module_can_disabled diff --git a/products/hummingbird/CMakeLists.txt b/products/hummingbird/CMakeLists.txt new file mode 100644 index 000000000000..edfbcafaa630 --- /dev/null +++ b/products/hummingbird/CMakeLists.txt @@ -0,0 +1,8 @@ +# Sometimes our users will try to do: "cd hummingbird; cmake ." That needs to error in a nice way. +if("${CMAKE_SOURCE_DIR}" STREQUAL "${CMAKE_CURRENT_SOURCE_DIR}") + message(FATAL_ERROR "cmake has to be used on the root CMakeLists.txt, see the Building ComplianceAsCode section in the Developer Guide!") +endif() + +set(PRODUCT_REMEDIATION_LANGUAGES "hummingbird") + +ssg_build_product("hummingbird") diff --git a/products/hummingbird/controls/cis_hummingbird.yml b/products/hummingbird/controls/cis_hummingbird.yml new file mode 100644 index 000000000000..6dcf27287592 --- /dev/null +++ b/products/hummingbird/controls/cis_hummingbird.yml @@ -0,0 +1,2450 @@ +policy: CIS Benchmark for Red Hat Hummingbird +title: CIS Benchmark for Red Hat Hummingbird +id: cis_hummingbird +version: vendor +source: https://www.cisecurity.org/cis-benchmarks/#red_hat_linux + +levels: + - id: l1_server + - id: l2_server + inherits_from: + - l1_server + - id: l1_workstation + - id: l2_workstation + inherits_from: + - l1_workstation + +reference_type: cis +product: hummingbird + +controls: + - id: 1.1.1.1 + title: Ensure cramfs kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.1.2 + title: Ensure freevxfs kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.1.3 + title: Ensure hfs kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.1.4 + title: Ensure hfsplus kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.1.5 + title: Ensure jffs2 kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.1.6 + title: Ensure overlay kernel module is not available (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.1.7 + title: Ensure squashfs kernel module is not available (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.1.8 + title: Ensure udf kernel module is not available (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.1.9 + title: Ensure firewire-core kernel module is not available (Automated) + levels: + - l1_server + - l2_workstation + status: not applicable + + - id: 1.1.1.10 + title: Ensure usb-storage kernel module is not available (Automated) + levels: + - l1_server + - l2_workstation + status: not applicable + + - id: 1.1.1.11 + title: Ensure unused filesystems kernel modules are not available (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.1.1 + title: Ensure /tmp is tmpfs or a separate partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.1.2 + title: Ensure nodev option set on /tmp partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.1.3 + title: Ensure nosuid option set on /tmp partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.1.4 + title: Ensure noexec option set on /tmp partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.2.1 + title: Ensure /dev/shm is tmpfs or a separate partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.2.2 + title: Ensure nodev option set on /dev/shm partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.2.3 + title: Ensure nosuid option set on /dev/shm partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.2.4 + title: Ensure noexec option set on /dev/shm partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.3.1 + title: Ensure separate partition exists for /home (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.2.3.2 + title: Ensure nodev option set on /home partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.3.3 + title: Ensure nosuid option set on /home partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.4.1 + title: Ensure separate partition exists for /var (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.2.4.2 + title: Ensure nodev option set on /var partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.4.3 + title: Ensure nosuid option set on /var partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.5.1 + title: Ensure separate partition exists for /var/tmp (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.2.5.2 + title: Ensure nodev option set on /var/tmp partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.5.3 + title: Ensure nosuid option set on /var/tmp partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.5.4 + title: Ensure noexec option set on /var/tmp partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.6.1 + title: Ensure separate partition exists for /var/log (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.2.6.2 + title: Ensure nodev option set on /var/log partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.6.3 + title: Ensure nosuid option set on /var/log partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.6.4 + title: Ensure noexec option set on /var/log partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.7.1 + title: Ensure separate partition exists for /var/log/audit (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.1.2.7.2 + title: Ensure nodev option set on /var/log/audit partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.7.3 + title: Ensure nosuid option set on /var/log/audit partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.1.2.7.4 + title: Ensure noexec option set on /var/log/audit partition (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.2.1.1 + title: Ensure GPG keys are configured (Manual) + levels: + - l1_server + - l1_workstation + status: partial + rules: + - ensure_redhat_gpgkey_installed + notes: > + In CIS Benchmark, the requirement is manual, because of GPG keys for 3rd party repositories. + However, for official images, we assume that the official images will contain only RPM packages + signed by Red Hat which allows us to check the requirement automatically by adding the rule + ensure_redhat_gpgkey_installed to the profile. + + - id: 1.2.1.2 + title: Ensure gpgcheck is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.2.1.3 + title: Ensure repo_gpgcheck is globally activated (Manual) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.2.1.4 + title: Ensure package manager repositories are configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.2.1.5 + title: Ensure weak dependencies are configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.2.2.1 + title: Ensure updates, patches, and additional security software are installed (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 1.3.1.1 + title: Ensure SELinux is installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.3.1.2 + title: Ensure SELinux is not disabled in bootloader configuration (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.3.1.3 + title: Ensure SELinux policy is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.3.1.4 + title: Ensure the SELinux mode is not disabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.3.1.5 + title: Ensure the SELinux mode is enforcing (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.3.1.6 + title: Ensure no unconfined services exist (Manual) + levels: + - l2_server + - l2_workstation + status: manual + + - id: 1.3.1.7 + title: Ensure the MCS Translation Service (mcstrans) is not installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.3.1.8 + title: Ensure SETroubleshoot is not installed (Automated) + levels: + - l1_server + status: not applicable + + - id: 1.4.1 + title: Ensure bootloader password is set (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.4.2 + title: Ensure access to bootloader config is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.1 + title: Ensure core file size is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.2 + title: Ensure fs.protected_hardlinks is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.3 + title: Ensure fs.protected_symlinks is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 1.5.4 + title: Ensure fs.suid_dumpable is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.5 + title: Ensure kernel.dmesg_restrict is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.6 + title: Ensure kernel.kptr_restrict is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.7 + title: Ensure kernel.yama.ptrace_scope is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.8 + title: Ensure kernel.randomize_va_space is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + notes: |- + Address Space Layout Randomization (ASLR) + + - id: 1.5.9 + title: Ensure systemd-coredump ProcessSizeMax is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.5.10 + title: Ensure systemd-coredump Storage is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.6.1 + title: Ensure system wide crypto policy is not set to legacy (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - crypto_policy_not_legacy + + - id: 1.6.2 + title: Ensure system wide crypto policy disables sha1 hash and signature support (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - crypto_policy_not_legacy + + - id: 1.6.3 + title: Ensure system wide crypto policy macs are configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - crypto_policy_not_legacy + + - id: 1.6.4 + title: Ensure system wide crypto policy disables cbc for ssh (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.7.1 + title: Ensure /etc/motd is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.7.2 + title: Ensure /etc/issue is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.7.3 + title: Ensure /etc/issue.net is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.7.4 + title: Ensure access to /etc/motd is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_motd + - file_owner_etc_motd + - file_permissions_etc_motd + + - id: 1.7.5 + title: Ensure access to /etc/issue is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_issue + - file_owner_etc_issue + - file_permissions_etc_issue + + - id: 1.7.6 + title: Ensure access to /etc/issue.net is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_issue_net + - file_owner_etc_issue_net + - file_permissions_etc_issue_net + + - id: 1.8.1 + title: Ensure GDM login banner is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.8.2 + title: Ensure GDM disable-user-list is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.8.3 + title: Ensure GDM screen lock is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.8.4 + title: Ensure GDM automount is configured (Automated) + levels: + - l1_server + - l2_workstation + status: not applicable + + - id: 1.8.5 + title: Ensure GDM autorun-never is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 1.8.6 + title: Ensure Xwayland is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 2.1.1 + title: Ensure autofs services are not in use (Automated) + levels: + - l1_server + - l2_workstation + status: not applicable + + - id: 2.1.2 + title: Ensure avahi daemon services are not in use (Automated) + levels: + - l1_server + - l2_workstation + status: not applicable + + - id: 2.1.3 + title: Ensure cockpit web services are not in use (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 2.1.4 + title: Ensure dhcp server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_kea_removed + + - id: 2.1.5 + title: Ensure dns server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_bind_removed + + - id: 2.1.6 + title: Ensure dnsmasq services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.1.7 + title: Ensure ftp server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_vsftpd_removed + + - id: 2.1.8 + title: Ensure message access server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_dovecot_removed + - package_cyrus-imapd_removed + + - id: 2.1.9 + title: Ensure network file system services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.1.10 + title: Ensure print server services are not in use (Automated) + levels: + - l1_server + status: not applicable + + - id: 2.1.11 + title: Ensure rpcbind services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.1.12 + title: Ensure rsync services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_rsync_removed + + - id: 2.1.13 + title: Ensure samba file server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_samba_removed + + - id: 2.1.14 + title: Ensure snmp services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_net-snmp_removed + + - id: 2.1.15 + title: Ensure telnet server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_telnet-server_removed + + - id: 2.1.16 + title: Ensure tftp server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_tftp-server_removed + + - id: 2.1.17 + title: Ensure web proxy server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_squid_removed + + - id: 2.1.18 + title: Ensure web server services are not in use (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_httpd_removed + - package_nginx_removed + + - id: 2.1.19 + title: Ensure GNOME Display Manager is removed (Automated) + levels: + - l2_server + status: not applicable + + - id: 2.1.20 + title: Ensure X window server services are not in use (Automated) + levels: + - l2_server + status: automated + rules: + - package_xorg-x11-server-Xwayland_removed + + - id: 2.1.21 + title: Ensure mail transfer agents are configured for local-only mode (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.1.22 + title: Ensure only approved services are listening on a network interface (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 2.2.1 + title: Ensure ftp client is not installed (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_ftp_removed + + - id: 2.2.2 + title: Ensure ldap client is not installed (Automated) + levels: + - l2_server + - l2_workstation + status: automated + rules: + - package_openldap-clients_removed + + - id: 2.2.3 + title: Ensure telnet client is not installed (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_telnet_removed + + - id: 2.2.4 + title: Ensure tftp client is not installed (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - package_tftp_removed + + - id: 2.3.1 + title: Ensure time synchronization is in use (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.3.2 + title: Ensure chrony is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.3.3 + title: Ensure chrony is not run as the root user (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.1 + title: Ensure cron daemon is enabled and active (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.2 + title: Ensure access to /etc/crontab is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.3 + title: Ensure access to /etc/cron.hourly is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.4 + title: Ensure access to /etc/cron.daily is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.5 + title: Ensure access to /etc/cron.weekly is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.6 + title: Ensure access to /etc/cron.monthly is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.7 + title: Ensure access to /etc/cron.yearly is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.8 + title: Ensure access to /etc/cron.d is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.1.9 + title: Ensure access to crontab is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 2.4.2.1 + title: Ensure access to at is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.1.1 + title: Ensure IPv6 status is identified (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 3.1.2 + title: Ensure wireless interfaces are not available (Automated) + levels: + - l1_server + status: not applicable + + - id: 3.1.3 + title: Ensure bluetooth services are not in use (Automated) + levels: + - l1_server + - l2_workstation + status: not applicable + + - id: 3.2.1 + title: Ensure atm kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.2.2 + title: Ensure can kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.2.3 + title: Ensure dccp kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.2.4 + title: Ensure tipc kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.2.5 + title: Ensure rds kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.2.6 + title: Ensure sctp kernel module is not available (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.1 + title: Ensure net.ipv4.ip_forward is configured (Automated) + levels: + - l1_workstation + - l2_server + status: not applicable + + - id: 3.3.1.2 + title: Ensure net.ipv4.conf.all.forwarding is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.3 + title: Ensure net.ipv4.conf.default.forwarding is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.4 + title: Ensure net.ipv4.conf.all.send_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.5 + title: Ensure net.ipv4.conf.default.send_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.6 + title: Ensure net.ipv4.icmp_ignore_bogus_error_responses is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.7 + title: Ensure net.ipv4.icmp_echo_ignore_broadcasts is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.8 + title: Ensure net.ipv4.conf.all.accept_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.9 + title: Ensure net.ipv4.conf.default.accept_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.10 + title: Ensure net.ipv4.conf.all.secure_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.11 + title: Ensure net.ipv4.conf.default.secure_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.12 + title: Ensure net.ipv4.conf.all.rp_filter is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.13 + title: Ensure net.ipv4.conf.default.rp_filter is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.14 + title: Ensure net.ipv4.conf.all.accept_source_route is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.15 + title: Ensure net.ipv4.conf.default.accept_source_route is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.16 + title: Ensure net.ipv4.conf.all.log_martians is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.17 + title: Ensure net.ipv4.conf.default.log_martians is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.1.18 + title: Ensure net.ipv4.tcp_syncookies is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.1 + title: Ensure net.ipv6.conf.all.forwarding is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.2 + title: Ensure net.ipv6.conf.default.forwarding is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.3 + title: Ensure net.ipv6.conf.all.accept_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.4 + title: Ensure net.ipv6.conf.default.accept_redirects is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.5 + title: Ensure net.ipv6.conf.all.accept_source_route is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.6 + title: Ensure net.ipv6.conf.default.accept_source_route is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.7 + title: Ensure net.ipv6.conf.all.accept_ra is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 3.3.2.8 + title: Ensure net.ipv6.conf.default.accept_ra is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.1 + title: Ensure firewalld is installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.2 + title: Ensure firewalld backend is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.3 + title: Ensure firewalld.service is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.4 + title: Ensure firewalld active zone target is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.5 + title: Ensure firewalld loopback traffic is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.6 + title: Ensure firewalld loopback source address traffic is configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 4.1.7 + title: Ensure firewalld services and ports are configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.1 + title: Ensure access to /etc/ssh/sshd_config is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.2 + title: Ensure access to SSH private host key files is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.3 + title: Ensure access to SSH public host key files is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.4 + title: Ensure sshd access is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.5 + title: Ensure sshd Banner is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.6 + title: Ensure sshd Ciphers are configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.7 + title: Ensure sshd ClientAliveInterval and ClientAliveCountMax are configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.8 + title: Ensure sshd DisableForwarding is enabled (Automated) + levels: + - l1_workstation + - l2_server + status: not applicable + + - id: 5.1.9 + title: Ensure sshd GSSAPIAuthentication is disabled (Automated) + levels: + - l1_workstation + - l2_server + status: not applicable + + - id: 5.1.10 + title: Ensure sshd HostbasedAuthentication is disabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.11 + title: Ensure sshd IgnoreRhosts is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.12 + title: Ensure sshd KexAlgorithms is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.13 + title: Ensure sshd LoginGraceTime is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.14 + title: Ensure sshd LogLevel is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.15 + title: Ensure sshd MACs are configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.16 + title: Ensure sshd MaxAuthTries is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.17 + title: Ensure sshd MaxStartups is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.18 + title: Ensure sshd MaxSessions is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.19 + title: Ensure sshd PermitEmptyPasswords is disabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.20 + title: Ensure sshd PermitRootLogin is disabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.21 + title: Ensure sshd PermitUserEnvironment is disabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.1.22 + title: Ensure sshd UsePAM is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.2.1 + title: Ensure sudo is installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.2.2 + title: Ensure sudo commands use pty (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.2.3 + title: Ensure sudo log file exists (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.2.4 + title: Ensure users must provide password for escalation (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 5.2.5 + title: Ensure re-authentication for privilege escalation is not disabled globally (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.2.6 + title: Ensure sudo timestamp_timeout is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.2.7 + title: Ensure access to the su command is restricted (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.1.1 + title: Ensure active authselect profile includes pam modules (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.1.2 + title: Ensure pam_faillock module is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.1.3 + title: Ensure pam_pwquality module is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.1.4 + title: Ensure pam_pwhistory module is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.1.5 + title: Ensure pam_unix module is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.1.1 + title: Ensure password failed attempts lockout is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.1.2 + title: Ensure password unlock time is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.1.3 + title: Ensure password failed attempts lockout includes root account (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 5.3.2.2.1 + title: Ensure password number of changed characters is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.2.2 + title: Ensure password length is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.2.3 + title: Ensure password complexity is configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.2.4 + title: Ensure password same consecutive characters is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.2.5 + title: Ensure password maximum sequential characters is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.2.6 + title: Ensure password dictionary check is enabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.2.7 + title: Ensure password quality is enforced for the root user (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.3.1 + title: Ensure password history remember is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.3.2 + title: Ensure password history is enforced for the root user (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.3.3 + title: Ensure pam_pwhistory includes use_authtok (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.4.1 + title: Ensure pam_unix does not include nullok (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.4.2 + title: Ensure pam_unix does not include remember (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.4.3 + title: Ensure pam_unix includes a strong password hashing algorithm (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.3.2.4.4 + title: Ensure pam_unix includes use_authtok (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.1.1 + title: Ensure password expiration is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.1.2 + title: Ensure minimum password days is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 5.4.1.3 + title: Ensure password expiration warning days is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.1.4 + title: Ensure strong password hashing algorithm is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.1.5 + title: Ensure inactive password lock is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.1.6 + title: Ensure all users last password change date is in the past (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.2.1 + title: Ensure root is the only UID 0 account (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.2.2 + title: Ensure root is the only GID 0 account (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.2.3 + title: Ensure group root is the only GID 0 group (Automated) + levels: + - l1_server + - l1_workstation + status: automated + notes: |- + There is assessment but no automated remediation for this rule and this sounds reasonable. + rules: + - groups_no_zero_gid_except_root + + - id: 5.4.2.4 + title: Ensure root account access is controlled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.2.5 + title: Ensure root path integrity (Automated) + levels: + - l1_server + - l1_workstation + status: manual + notes: >- + The requirement should be applicable for Hummingbird. However, there + is a problem if a container image is scanned. The reason is the OVAL + check reads the $PATH environment variable of the current process + from /proc. When using oscap-podman this OVAL works, because + oscap-podman creates a container first if an image is given and + containers contain /proc. But, when using openscap container, when + a container image is mounted to the openscap container, no /proc is + present in the mounted filesystem. Unfortunately, there is no easy + way how to detect the $PATH from mounted configuration files, so we + will keep the requirement as manual. + related_rules: + - accounts_root_path_dirs_no_write + - root_path_no_dot + + - id: 5.4.2.6 + title: Ensure root user umask is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.2.7 + title: Ensure system accounts do not have a valid login shell (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.2.8 + title: Ensure accounts without a valid login shell are locked (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.3.1 + title: Ensure nologin is not listed in /etc/shells (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 5.4.3.2 + title: Ensure default user shell timeout is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 5.4.3.3 + title: Ensure default user umask is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_profile + - var_accounts_user_umask=027 + + - id: 6.1.1 + title: Ensure AIDE is installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.1.2 + title: Ensure filesystem integrity is regularly checked (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.1.3 + title: Ensure cryptographic mechanisms are used to protect the integrity of audit tools (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.1.1 + title: Ensure journald service is active (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.1.2 + title: Ensure journald log file access is configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.1.3 + title: Ensure journald log file rotation is configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.1.4 + title: Ensure only one logging system is in use (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.2.1.1 + title: Ensure systemd-journal-remote is installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.2.1.2 + title: Ensure systemd-journal-upload authentication is configured (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 6.2.2.1.3 + title: Ensure systemd-journal-upload is enabled and active (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.2.1.4 + title: Ensure systemd-journal-remote service is not in use (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.2.2 + title: Ensure journald ForwardToSyslog is disabled (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.2.3 + title: Ensure journald Compress is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.2.4 + title: Ensure journald Storage is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.1 + title: Ensure rsyslog is installed (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.2 + title: Ensure rsyslog service is enabled and active (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.3 + title: Ensure journald is configured to send logs to rsyslog (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.4 + title: Ensure rsyslog log file creation mode is configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.5 + title: Ensure rsyslog logging is configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.6 + title: Ensure rsyslog is configured to send logs to a remote log host (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.7 + title: Ensure rsyslog is not configured to receive logs from a remote client (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.3.8 + title: Ensure rsyslog logrotate is configured (Manual) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.2.4.1 + title: Ensure access to all logfiles has been configured (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 6.3.1.1 + title: Ensure auditd packages are installed (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.1.2 + title: Ensure auditing for processes that start prior to auditd is enabled (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.1.3 + title: Ensure audit_backlog_limit is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.1.4 + title: Ensure auditd service is enabled and active (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.2.1 + title: Ensure audit log storage size is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.2.2 + title: Ensure audit logs are not automatically deleted (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.2.3 + title: Ensure system is disabled when audit logs are full (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.2.4 + title: Ensure system warns when audit logs are low on space (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.1 + title: Ensure modification of the /etc/sudoers file is collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.2 + title: Ensure actions as another user are always logged (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.3 + title: Ensure events that modify the sudo log file are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.4 + title: Ensure events that modify date and time information are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.5 + title: Ensure events that modify sethostname and setdomainname are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.6 + title: Ensure events that modify /etc/issue and /etc/issue.net are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.7 + title: Ensure events that modify /etc/hosts and /etc/hostname are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.8 + title: Ensure events that modify /etc/sysconfig/network and /etc/NetworkManager/system-connections/ are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.9 + title: Ensure events that modify /etc/NetworkManager directory are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.10 + title: Ensure use of privileged commands are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.11 + title: Ensure unsuccessful file access attempts are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.12 + title: Ensure events that modify /etc/group information are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.13 + title: Ensure events that modify /etc/passwd information are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.14 + title: Ensure events that modify /etc/shadow and /etc/gshadow are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.15 + title: Ensure events that modify /etc/security/opasswd are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.16 + title: Ensure events that modify /etc/nsswitch.conf file are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.17 + title: Ensure events that modify /etc/pam.conf and /etc/pam.d/ information are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.18 + title: Ensure discretionary access control permission modification events chmod,fchmod,fchmodat,fchmodat2 are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.19 + title: Ensure discretionary access control permission modification events chown,fchown,lchown,fchownat are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.20 + title: Ensure discretionary access control permission modification events setxattr,lsetxattr,fsetxattr,removexattr,lremovexattr,fremovexattr collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.21 + title: Ensure successful file system mounts are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.22 + title: Ensure session initiation information is collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.23 + title: Ensure login and logout events are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.24 + title: Ensure unlink file deletion events by users are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.25 + title: Ensure rename file deletion events by users are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.26 + title: Ensure events that modify the system's Mandatory Access Controls are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.27 + title: Ensure successful and unsuccessful attempts to use the chcon command are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.28 + title: Ensure successful and unsuccessful attempts to use the setfacl command are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.29 + title: Ensure successful and unsuccessful attempts to use the chacl command are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.30 + title: Ensure successful and unsuccessful attempts to use the usermod command are collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.31 + title: Ensure kernel module loading unloading and modification is collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.32 + title: Ensure kernel "init_module" and "finit_module" loading unloading and modification is collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.33 + title: Ensure kernel "delete_module" loading unloading and modification is collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.34 + title: Ensure kernel "query_module" loading unloading and modification is collected (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.35 + title: Ensure the audit configuration is loaded regardless of errors (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.36 + title: Ensure the audit configuration is immutable (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.3.37 + title: Ensure the running and on disk configuration is the same (Manual) + levels: + - l2_server + - l2_workstation + status: manual + + - id: 6.3.4.1 + title: Ensure the audit log file directory mode is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.2 + title: Ensure audit log files mode is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.3 + title: Ensure audit log files owner is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.4 + title: Ensure audit log files group owner is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.5 + title: Ensure audit configuration files mode is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.6 + title: Ensure audit configuration files owner is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.7 + title: Ensure audit configuration files group owner is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.8 + title: Ensure audit tools mode is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.9 + title: Ensure audit tools owner is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 6.3.4.10 + title: Ensure audit tools group owner is configured (Automated) + levels: + - l2_server + - l2_workstation + status: not applicable + + - id: 7.1.1 + title: Ensure access to /etc/passwd is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_passwd + - file_owner_etc_passwd + - file_permissions_etc_passwd + + - id: 7.1.2 + title: Ensure access to /etc/passwd- is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_backup_etc_passwd + - file_owner_backup_etc_passwd + - file_permissions_backup_etc_passwd + + - id: 7.1.3 + title: Ensure access to /etc/group is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_group + - file_owner_etc_group + - file_permissions_etc_group + + - id: 7.1.4 + title: Ensure access to /etc/group- is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_backup_etc_group + - file_owner_backup_etc_group + - file_permissions_backup_etc_group + + - id: 7.1.5 + title: Ensure access to /etc/shadow is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_owner_etc_shadow + - file_groupowner_etc_shadow + - file_permissions_etc_shadow + + - id: 7.1.6 + title: Ensure access to /etc/shadow- is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_backup_etc_shadow + - file_owner_backup_etc_shadow + - file_permissions_backup_etc_shadow + + - id: 7.1.7 + title: Ensure access to /etc/gshadow is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_gshadow + - file_owner_etc_gshadow + - file_permissions_etc_gshadow + + - id: 7.1.8 + title: Ensure access to /etc/gshadow- is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_backup_etc_gshadow + - file_owner_backup_etc_gshadow + - file_permissions_backup_etc_gshadow + + - id: 7.1.9 + title: Ensure access to /etc/shells is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_shells + - file_owner_etc_shells + - file_permissions_etc_shells + + - id: 7.1.10 + title: Ensure access to /etc/security/opasswd is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_groupowner_etc_security_opasswd + - file_owner_etc_security_opasswd + - file_permissions_etc_security_opasswd + - file_groupowner_etc_security_opasswd_old + - file_owner_etc_security_opasswd_old + - file_permissions_etc_security_opasswd_old + + - id: 7.1.11 + title: Ensure world writable files and directories are secured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_permissions_unauthorized_world_writable + - dir_perms_world_writable_sticky_bits + + - id: 7.1.12 + title: Ensure no files or directories without an owner and a group exist (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - no_files_or_dirs_ungroupowned + + - id: 7.1.13 + title: Ensure SUID and SGID files are reviewed (Manual) + levels: + - l1_server + - l1_workstation + status: manual + + - id: 7.2.1 + title: Ensure accounts in /etc/passwd use shadowed passwords (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 7.2.2 + title: Ensure /etc/shadow password fields are not empty (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 7.2.3 + title: Ensure all groups in /etc/passwd exist in /etc/group (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - gid_passwd_group_same + + - id: 7.2.4 + title: Ensure no duplicate UIDs exist (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 7.2.5 + title: Ensure no duplicate GIDs exist (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 7.2.6 + title: Ensure no duplicate user names exist (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 7.2.7 + title: Ensure no duplicate group names exist (Automated) + levels: + - l1_server + - l1_workstation + status: not applicable + + - id: 7.2.8 + title: Ensure local interactive user home directories are configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_ownership_home_directories + - file_permissions_home_directories + + - id: 7.2.9 + title: Ensure local interactive user dot files access is configured (Automated) + levels: + - l1_server + - l1_workstation + status: automated + rules: + - file_permission_user_init_files + - var_user_initialization_files_regex=all_dotfiles + - file_permission_user_bash_history diff --git a/products/hummingbird/controls/stig_hummingbird.yml b/products/hummingbird/controls/stig_hummingbird.yml new file mode 100644 index 000000000000..4a86f116a227 --- /dev/null +++ b/products/hummingbird/controls/stig_hummingbird.yml @@ -0,0 +1,1290 @@ +--- +policy: 'Red Hat Hummingbird Security Technical Implementation Guide' +title: 'Red Hat Hummingbird Security Technical Implementation Guide' +id: stig_hummingbird +source: https://www.cyber.mil/stigs/downloads/ +version: vendor +reference_type: stigid +product: hummingbird + +levels: + - id: high + - id: medium + - id: low + +controls: + - id: SRG-OS-000001-GPOS-00001 + levels: + - medium + title: 'Red Hat Hummingbird must provide automated mechanisms for supporting account management functions.' + status: does not meet + + - id: SRG-OS-000002-GPOS-00002 + levels: + - medium + title: 'Red Hat Hummingbird must automatically remove or disable temporary user accounts after 72 hours.' + status: not applicable + + - id: SRG-OS-000004-GPOS-00004 + levels: + - medium + title: 'Red Hat Hummingbird must audit all account creations.' + status: not applicable + + - id: SRG-OS-000021-GPOS-00005 + levels: + - medium + title: 'Red Hat Hummingbird must enforce the limit of three consecutive invalid logon attempts by a user during a 15-minute time period.' + status: not applicable + + - id: SRG-OS-000023-GPOS-00006 + levels: + - medium + title: 'Red Hat Hummingbird must display the Standard Mandatory DoD Notice and Consent Banner before granting local or remote access to the system.' + status: not applicable + + - id: SRG-OS-000024-GPOS-00007 + levels: + - medium + title: 'Red Hat Hummingbird must display the Standard Mandatory DoD Notice and Consent Banner until users acknowledge the usage conditions and take explicit actions to log on for further access.' + status: does not meet + + - id: SRG-OS-000027-GPOS-00008 + levels: + - low + title: 'Red Hat Hummingbird must limit the number of concurrent sessions to ten for all accounts and/or account types.' + status: not applicable + + - id: SRG-OS-000032-GPOS-00013 + levels: + - medium + title: 'Red Hat Hummingbird must monitor remote access methods.' + status: not applicable + + - id: SRG-OS-000033-GPOS-00014 + levels: + - high + title: 'Red Hat Hummingbird must implement DoD-approved encryption to protect the confidentiality of remote access sessions.' + status: not applicable + + - id: SRG-OS-000038-GPOS-00016 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing information to establish when (date and time) the events occurred.' + status: not applicable + + - id: SRG-OS-000039-GPOS-00017 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing information to establish where the events occurred.' + status: not applicable + + - id: SRG-OS-000040-GPOS-00018 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing information to establish the source of the events.' + status: not applicable + + - id: SRG-OS-000041-GPOS-00019 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing information to establish the outcome of the events.' + status: not applicable + + - id: SRG-OS-000042-GPOS-00021 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing the individual identities of group account users.' + status: not applicable + + - id: SRG-OS-000046-GPOS-00022 + levels: + - medium + title: 'Red Hat Hummingbird must alert the ISSO and SA (at a minimum) in the event of an audit processing failure.' + status: not applicable + + - id: SRG-OS-000051-GPOS-00024 + levels: + - medium + title: 'Red Hat Hummingbird must provide the capability to centrally review and analyze audit records from multiple components within the system.' + status: not applicable + + - id: SRG-OS-000054-GPOS-00025 + levels: + - medium + title: 'Red Hat Hummingbird must provide the capability to filter audit records for events of interest based upon all audit fields within audit records.' + status: not applicable + + - id: SRG-OS-000055-GPOS-00026 + levels: + - medium + title: 'Red Hat Hummingbird must use internal system clocks to generate time stamps for audit records.' + status: inherently met + + - id: SRG-OS-000063-GPOS-00032 + levels: + - medium + title: 'Red Hat Hummingbird must allow only the ISSM (or individuals or roles appointed by the ISSM) to select which auditable events are to be audited.' + status: not applicable + + - id: SRG-OS-000066-GPOS-00034 + levels: + - medium + title: 'Red Hat Hummingbird, for PKI-based authentication, must validate certificates by constructing a certification path (which includes status information) to an accepted trust anchor.' + status: manual + + - id: SRG-OS-000067-GPOS-00035 + levels: + - medium + title: 'Red Hat Hummingbird, for PKI-based authentication, must enforce authorized access to the corresponding private key.' + status: manual + + - id: SRG-OS-000068-GPOS-00036 + levels: + - medium + title: 'Red Hat Hummingbird must map the authenticated identity to the user or group account for PKI-based authentication.' + status: not applicable + + - id: SRG-OS-000070-GPOS-00038 + levels: + - medium + title: 'Red Hat Hummingbird must enforce password complexity by requiring that at least one lowercase character be used.' + status: not applicable + + - id: SRG-OS-000071-GPOS-00039 + levels: + - medium + title: 'Red Hat Hummingbird must enforce password complexity by requiring that at least one numeric character be used.' + status: not applicable + + - id: SRG-OS-000072-GPOS-00040 + levels: + - medium + title: 'Red Hat Hummingbird must require the change of at least 50 percent of the total number of characters when passwords are changed.' + status: not applicable + + - id: SRG-OS-000074-GPOS-00042 + levels: + - high + title: 'Red Hat Hummingbird must transmit only encrypted representations of passwords.' + status: automated + rules: + - package_tftp_removed + - package_vsftpd_removed + - package_telnet-server_removed + + - id: SRG-OS-000075-GPOS-00043 + levels: + - medium + title: 'Red Hat Hummingbird must enforce 24 hours/1 day as the minimum password lifetime.' + status: not applicable + + - id: SRG-OS-000078-GPOS-00046 + levels: + - medium + title: 'Red Hat Hummingbird must enforce a minimum 15-character password length.' + status: not applicable + + - id: SRG-OS-000079-GPOS-00047 + levels: + - medium + title: 'Red Hat Hummingbird must obscure feedback of authentication information during the authentication process to protect the information from possible exploitation/use by unauthorized individuals.' + status: inherently met + + - id: SRG-OS-000096-GPOS-00050 + levels: + - medium + title: 'Red Hat Hummingbird must be configured to prohibit or restrict the use of functions, ports, protocols, and/or services, as defined in the PPSM CAL and vulnerability assessments.' + status: not applicable + + - id: SRG-OS-000104-GPOS-00051 + levels: + - medium + title: 'Red Hat Hummingbird must uniquely identify and must authenticate organizational users (or processes acting on behalf of organizational users).' + status: automated + rules: + - gid_passwd_group_same + + - id: SRG-OS-000105-GPOS-00052 + levels: + - medium + title: 'Red Hat Hummingbird must use multifactor authentication for network access to privileged accounts.' + status: not applicable + + - id: SRG-OS-000106-GPOS-00053 + levels: + - medium + title: 'Red Hat Hummingbird must use multifactor authentication for network access to non-privileged accounts.' + status: not applicable + + - id: SRG-OS-000107-GPOS-00054 + levels: + - medium + title: 'Red Hat Hummingbird must use multifactor authentication for local access to privileged accounts.' + status: not applicable + + - id: SRG-OS-000108-GPOS-00055 + levels: + - medium + title: 'Red Hat Hummingbird must use multifactor authentication for local access to nonprivileged accounts.' + status: not applicable + + - id: SRG-OS-000109-GPOS-00056 + levels: + - medium + title: 'Red Hat Hummingbird must require individuals to be authenticated with an individual authenticator prior to using a group authenticator.' + status: not applicable + + - id: SRG-OS-000112-GPOS-00057 + levels: + - medium + title: 'Red Hat Hummingbird must implement replay-resistant authentication mechanisms for network access to privileged accounts.' + status: inherently met + + - id: SRG-OS-000113-GPOS-00058 + levels: + - medium + title: 'Red Hat Hummingbird must implement replay-resistant authentication mechanisms for network access to nonprivileged accounts.' + status: inherently met + + - id: SRG-OS-000114-GPOS-00059 + levels: + - medium + title: 'Red Hat Hummingbird must uniquely identify peripherals before establishing a connection.' + status: not applicable + + - id: SRG-OS-000118-GPOS-00060 + levels: + - medium + title: 'Red Hat Hummingbird must disable account identifiers (individuals, groups, roles, and devices) after 35 days of inactivity.' + status: not applicable + + - id: SRG-OS-000121-GPOS-00062 + levels: + - medium + title: 'Red Hat Hummingbird must uniquely identify and must authenticate non-organizational users (or processes acting on behalf of non-organizational users).' + status: not applicable + + - id: SRG-OS-000122-GPOS-00063 + levels: + - medium + title: 'Red Hat Hummingbird must provide an audit reduction capability that supports on-demand reporting requirements.' + status: not applicable + + - id: SRG-OS-000123-GPOS-00064 + levels: + - medium + title: 'The information system must automatically remove or disable emergency accounts after the crisis is resolved or 72 hours.' + status: not applicable + + - id: SRG-OS-000125-GPOS-00065 + levels: + - high + title: 'Red Hat Hummingbird must employ strong authenticators in the establishment of nonlocal maintenance and diagnostic sessions.' + status: not applicable + + - id: SRG-OS-000132-GPOS-00067 + levels: + - medium + title: 'Red Hat Hummingbird must separate user functionality (including user interface services) from operating system management functionality.' + status: inherently met + + - id: SRG-OS-000138-GPOS-00069 + levels: + - medium + title: 'Operating systems must prevent unauthorized and unintended information transfer via shared system resources.' + status: automated + rules: + - dir_perms_world_writable_root_owned + - dir_perms_world_writable_sticky_bits + + - id: SRG-OS-000142-GPOS-00071 + levels: + - medium + title: 'Red Hat Hummingbird must manage excess capacity, bandwidth, or other redundancy to limit the effects of information flooding types of Denial of Service (DoS) attacks.' + status: not applicable + + - id: SRG-OS-000184-GPOS-00078 + levels: + - medium + title: 'Red Hat Hummingbird must fail to a secure state if system initialization fails, shutdown fails, or aborts fail.' + status: inherently met + + - id: SRG-OS-000185-GPOS-00079 + levels: + - medium + title: 'Red Hat Hummingbird must protect the confidentiality and integrity of all information at rest.' + status: not applicable + + - id: SRG-OS-000205-GPOS-00083 + levels: + - medium + title: 'Red Hat Hummingbird must generate error messages that provide information necessary for corrective actions without revealing information that could be exploited by adversaries.' + status: inherently met + + - id: SRG-OS-000206-GPOS-00084 + levels: + - medium + title: 'Red Hat Hummingbird must reveal error messages only to authorized users.' + status: automated + rules: + - file_permissions_var_log_messages + - file_groupowner_var_log + - file_owner_var_log_messages + - file_groupowner_var_log_messages + - file_owner_var_log + - file_permissions_var_log + + - id: SRG-OS-000239-GPOS-00089 + levels: + - medium + title: 'Red Hat Hummingbird must audit all account modifications.' + status: not applicable + + - id: SRG-OS-000240-GPOS-00090 + levels: + - medium + title: 'Red Hat Hummingbird must audit all account disabling actions.' + status: not applicable + + - id: SRG-OS-000241-GPOS-00091 + levels: + - medium + title: 'Red Hat Hummingbird must audit all account removal actions.' + status: not applicable + + - id: SRG-OS-000255-GPOS-00096 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing information to establish the identity of any individual or process associated with the event.' + status: not applicable + + - id: SRG-OS-000256-GPOS-00097 + levels: + - medium + title: 'Red Hat Hummingbird must protect audit tools from unauthorized access.' + status: not applicable + + - id: SRG-OS-000257-GPOS-00098 + levels: + - medium + title: 'Red Hat Hummingbird must protect audit tools from unauthorized modification.' + status: not applicable + + - id: SRG-OS-000258-GPOS-00099 + levels: + - medium + title: 'Red Hat Hummingbird must protect audit tools from unauthorized deletion.' + status: not applicable + + - id: SRG-OS-000259-GPOS-00100 + levels: + - medium + title: 'Red Hat Hummingbird must limit privileges to change software resident within software libraries.' + status: automated + rules: + - dir_group_ownership_library_dirs + - file_groupownership_system_commands_dirs + - root_permissions_syslibrary_files + - dir_ownership_library_dirs + - dir_permissions_library_dirs + - file_ownership_binary_dirs + - file_permissions_library_dirs + - file_permissions_binary_dirs + - file_ownership_library_dirs + + - id: SRG-OS-000266-GPOS-00101 + levels: + - medium + title: 'Red Hat Hummingbird must enforce password complexity by requiring that at least one special character be used.' + status: not applicable + + - id: SRG-OS-000274-GPOS-00104 + levels: + - medium + title: 'Red Hat Hummingbird must notify system administrators and ISSOs when accounts are created.' + status: does not meet + + - id: SRG-OS-000275-GPOS-00105 + levels: + - medium + title: 'Red Hat Hummingbird must notify system administrators and ISSOs when accounts are modified.' + status: does not meet + + - id: SRG-OS-000276-GPOS-00106 + levels: + - medium + title: 'Red Hat Hummingbird must notify system administrators and ISSOs when accounts are disabled.' + status: does not meet + + - id: SRG-OS-000277-GPOS-00107 + levels: + - medium + title: 'Red Hat Hummingbird must notify system administrators and ISSOs when accounts are removed.' + status: does not meet + + - id: SRG-OS-000278-GPOS-00108 + levels: + - high + title: 'Red Hat Hummingbird must use cryptographic mechanisms to protect the integrity of audit tools.' + status: not applicable + + - id: SRG-OS-000279-GPOS-00109 + levels: + - medium + title: 'Red Hat Hummingbird must automatically terminate a user session after inactivity time-outs have expired or at shutdown.' + status: not applicable + + - id: SRG-OS-000280-GPOS-00110 + levels: + - medium + title: 'Red Hat Hummingbird must provide a logoff capability for user-initiated communications sessions when requiring user access authentication.' + status: inherently met + + - id: SRG-OS-000281-GPOS-00111 + levels: + - medium + title: 'Red Hat Hummingbird must display an explicit logoff message to users indicating the reliable termination of authenticated communications sessions.' + status: inherently met + + - id: SRG-OS-000297-GPOS-00115 + levels: + - medium + title: 'Red Hat Hummingbird must control remote access methods.' + status: not applicable + + - id: SRG-OS-000298-GPOS-00116 + levels: + - medium + title: 'Red Hat Hummingbird must provide the capability to immediately disconnect or disable remote access to the operating system.' + status: inherently met + + - id: SRG-OS-000299-GPOS-00117 + levels: + - medium + title: 'Red Hat Hummingbird must protect wireless access to and from the system using encryption.' + status: not applicable + + - id: SRG-OS-000300-GPOS-00118 + levels: + - medium + title: 'Red Hat Hummingbird must protect wireless access to the system using authentication of users and/or devices.' + status: not applicable + + - id: SRG-OS-000303-GPOS-00120 + levels: + - medium + title: 'Red Hat Hummingbird must audit all account enabling actions.' + status: not applicable + + - id: SRG-OS-000304-GPOS-00121 + levels: + - medium + title: 'Red Hat Hummingbird must notify system administrators (SAs) and information system security officers (ISSOs) of account enabling actions.' + status: not applicable + + - id: SRG-OS-000312-GPOS-00122 + levels: + - medium + title: 'Red Hat Hummingbird must allow operating system admins to pass information to any other operating system admin or user.' + status: inherently met + + - id: SRG-OS-000312-GPOS-00123 + levels: + - medium + title: 'Red Hat Hummingbird must allow operating system admins to grant their privileges to other operating system admins.' + status: not applicable + + - id: SRG-OS-000312-GPOS-00124 + levels: + - medium + title: 'Red Hat Hummingbird must allow operating system admins to change security attributes on users, the operating system, or the operating systems components.' + status: inherently met + + - id: SRG-OS-000326-GPOS-00126 + levels: + - medium + title: 'Red Hat Hummingbird must prevent all software from executing at higher privilege levels than users executing the software.' + status: not applicable + + - id: SRG-OS-000327-GPOS-00127 + levels: + - medium + title: 'Red Hat Hummingbird must audit the execution of privileged functions.' + status: not applicable + + - id: SRG-OS-000329-GPOS-00128 + levels: + - medium + title: 'Red Hat Hummingbird must automatically lock an account until the locked account is released by an administrator when three unsuccessful logon attempts in 15 minutes occur.' + status: not applicable + + - id: SRG-OS-000337-GPOS-00129 + levels: + - medium + title: 'Red Hat Hummingbird must provide the capability for assigned IMOs/ISSOs or designated SAs to change the auditing to be performed on all operating system components, based on all selectable event criteria in near real time.' + status: not applicable + + - id: SRG-OS-000342-GPOS-00133 + levels: + - low + title: 'Red Hat Hummingbird must offload audit records onto a different system or media from the system being audited.' + status: not applicable + + - id: SRG-OS-000343-GPOS-00134 + levels: + - low + title: 'Red Hat Hummingbird must immediately notify the SA and ISSO (at a minimum) when allocated audit record storage volume reaches 75 percent of the repository maximum audit record storage capacity.' + status: not applicable + + - id: SRG-OS-000344-GPOS-00135 + levels: + - medium + title: 'Red Hat Hummingbird must provide an immediate real-time alert to the SA and ISSO, at a minimum, of all audit failure events requiring real-time alerts.' + status: does not meet + + - id: SRG-OS-000348-GPOS-00136 + levels: + - low + title: 'Red Hat Hummingbird must provide an audit reduction capability that supports on-demand audit review and analysis.' + status: not applicable + + - id: SRG-OS-000349-GPOS-00137 + levels: + - low + title: 'Red Hat Hummingbird must provide an audit reduction capability that supports after-the-fact investigations of security incidents.' + status: not applicable + + - id: SRG-OS-000350-GPOS-00138 + levels: + - low + title: 'Red Hat Hummingbird must provide a report generation capability that supports on-demand audit review and analysis.' + status: not applicable + + - id: SRG-OS-000351-GPOS-00139 + levels: + - low + title: 'Red Hat Hummingbird must provide a report generation capability that supports on-demand reporting requirements.' + status: not applicable + + - id: SRG-OS-000352-GPOS-00140 + levels: + - low + title: 'Red Hat Hummingbird must provide a report generation capability that supports after-the-fact investigations of security incidents.' + status: not applicable + + - id: SRG-OS-000353-GPOS-00141 + levels: + - medium + title: 'Red Hat Hummingbird must not alter original content or time ordering of audit records when it provides an audit reduction capability.' + status: not applicable + + - id: SRG-OS-000354-GPOS-00142 + levels: + - medium + title: 'Red Hat Hummingbird must not alter original content or time ordering of audit records when it provides a report generation capability.' + status: not applicable + + - id: SRG-OS-000356-GPOS-00144 + levels: + - medium + title: 'Red Hat Hummingbird must synchronize internal information system clocks to the authoritative time source when the time difference is greater than one second.' + status: not applicable + + - id: SRG-OS-000358-GPOS-00145 + levels: + - medium + title: 'Red Hat Hummingbird must record time stamps for audit records that meet a minimum granularity of one second for a minimum degree of precision.' + status: inherently met + + - id: SRG-OS-000359-GPOS-00146 + levels: + - low + title: 'Red Hat Hummingbird must record time stamps for audit records that can be mapped to Coordinated Universal Time (UTC) or Greenwich Mean Time (GMT).' + status: not applicable + + - id: SRG-OS-000360-GPOS-00147 + levels: + - medium + title: 'Red Hat Hummingbird must enforce dual authorization for movement and/or deletion of all audit information, when such movement or deletion is not part of an authorized automatic process.' + status: does not meet + + - id: SRG-OS-000362-GPOS-00149 + levels: + - medium + title: 'Red Hat Hummingbird must prohibit user installation of system software without explicit privileged status.' + status: inherently met + + - id: SRG-OS-000363-GPOS-00150 + levels: + - medium + title: 'Red Hat Hummingbird must notify designated personnel if baseline configurations are changed in an unauthorized manner.' + status: not applicable + + - id: SRG-OS-000364-GPOS-00151 + levels: + - medium + title: 'Red Hat Hummingbird must enforce access restrictions.' + status: inherently met + + - id: SRG-OS-000365-GPOS-00152 + levels: + - medium + title: 'Red Hat Hummingbird must audit the enforcement actions used to restrict access associated with changes to the system.' + status: not applicable + + - id: SRG-OS-000370-GPOS-00155 + levels: + - medium + title: 'Red Hat Hummingbird must employ a deny-all, permit-by-exception policy to allow the execution of authorized software programs.' + status: not applicable + + - id: SRG-OS-000376-GPOS-00161 + levels: + - medium + title: 'Red Hat Hummingbird must accept Personal Identity Verification (PIV) credentials.' + status: not applicable + + - id: SRG-OS-000377-GPOS-00162 + levels: + - medium + title: 'Red Hat Hummingbird must electronically verify Personal Identity Verification (PIV) credentials.' + status: not applicable + + - id: SRG-OS-000378-GPOS-00163 + levels: + - medium + title: 'Red Hat Hummingbird must authenticate peripherals before establishing a connection.' + status: not applicable + + - id: SRG-OS-000379-GPOS-00164 + levels: + - medium + title: 'Red Hat Hummingbird must authenticate all endpoint devices before establishing a local, remote, and/or network connection using bidirectional authentication that is cryptographically based.' + status: not applicable + + - id: SRG-OS-000383-GPOS-00166 + levels: + - medium + title: 'Red Hat Hummingbird must prohibit the use of cached authenticators after one day.' + status: not applicable + + - id: SRG-OS-000393-GPOS-00173 + levels: + - high + title: 'Red Hat Hummingbird must implement cryptographic mechanisms to protect the integrity of nonlocal maintenance and diagnostic communications, when used for nonlocal maintenance sessions.' + status: automated + rules: + - configure_crypto_policy + - package_crypto-policies_installed + - var_system_crypto_policy=fips + + - id: SRG-OS-000394-GPOS-00174 + levels: + - high + title: 'Red Hat Hummingbird must implement cryptographic mechanisms to protect the confidentiality of nonlocal maintenance and diagnostic communications, when used for nonlocal maintenance sessions.' + status: automated + rules: + - configure_crypto_policy + - package_crypto-policies_installed + - var_system_crypto_policy=fips + + - id: SRG-OS-000395-GPOS-00175 + levels: + - medium + title: 'Red Hat Hummingbird must verify remote disconnection at the termination of nonlocal maintenance and diagnostic sessions, when used for nonlocal maintenance sessions.' + status: inherently met + + - id: SRG-OS-000403-GPOS-00182 + levels: + - medium + title: 'Red Hat Hummingbird must only allow the use of DoD PKI-established certificate authorities for authentication in the establishment of protected sessions to the operating system.' + status: does not meet + + - id: SRG-OS-000404-GPOS-00183 + levels: + - high + title: 'Red Hat Hummingbird must implement cryptographic mechanisms to prevent unauthorized modification of all information at rest on all operating system components.' + status: not applicable + + - id: SRG-OS-000405-GPOS-00184 + levels: + - high + title: 'Red Hat Hummingbird must implement cryptographic mechanisms to prevent unauthorized disclosure of all information at rest on all operating system components.' + status: not applicable + + - id: SRG-OS-000424-GPOS-00188 + levels: + - high + title: 'Red Hat Hummingbird must implement cryptographic mechanisms to prevent unauthorized disclosure of information and/or detect changes to information during transmission unless otherwise protected by alternative physical safeguards, such as, at a minimum, a Protected Distribution System (PDS).' + status: not applicable + + - id: SRG-OS-000425-GPOS-00189 + levels: + - medium + title: 'Red Hat Hummingbird must maintain the confidentiality and integrity of information during preparation for transmission.' + status: not applicable + + - id: SRG-OS-000426-GPOS-00190 + levels: + - medium + title: 'Red Hat Hummingbird must maintain the confidentiality and integrity of information during reception.' + status: not applicable + + - id: SRG-OS-000432-GPOS-00191 + levels: + - medium + title: 'Red Hat Hummingbird must behave in a predictable and documented manner that reflects organizational and system objectives when invalid inputs are received.' + status: inherently met + + - id: SRG-OS-000433-GPOS-00193 + levels: + - medium + title: 'Red Hat Hummingbird must implement address space layout randomization to protect its memory from unauthorized code execution.' + status: not applicable + + - id: SRG-OS-000437-GPOS-00194 + levels: + - medium + title: 'Red Hat Hummingbird must remove all software components after updated versions have been installed.' + status: not applicable + + - id: SRG-OS-000446-GPOS-00200 + levels: + - medium + title: 'Red Hat Hummingbird must perform verification of the correct operation of security functions: upon system start-up and/or restart; upon command by a user with privileged access; and/or every 30 days.' + status: not applicable + + - id: SRG-OS-000447-GPOS-00201 + levels: + - medium + title: 'Red Hat Hummingbird must shut down the information system, restart the information system, and/or notify the system administrator when anomalies in the operation of any security functions are discovered.' + status: not applicable + + - id: SRG-OS-000458-GPOS-00203 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to access security objects occur.' + status: not applicable + + - id: SRG-OS-000461-GPOS-00205 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to access categories of information (e.g., classification levels) occur.' + status: not applicable + + - id: SRG-OS-000463-GPOS-00207 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to modify security objects occur.' + status: not applicable + + - id: SRG-OS-000465-GPOS-00209 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to modify categories of information (e.g., classification levels) occur.' + status: not applicable + + - id: SRG-OS-000470-GPOS-00214 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful logon attempts occur.' + status: not applicable + + - id: SRG-OS-000471-GPOS-00216 + levels: + - medium + title: 'The audit system must be configured to audit the loading and unloading of dynamic kernel modules.' + status: not applicable + + - id: SRG-OS-000472-GPOS-00217 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records showing starting and ending time for user access to the system.' + status: inherently met + + - id: SRG-OS-000473-GPOS-00218 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when concurrent logons to the same account occur from different sources.' + status: not applicable + + - id: SRG-OS-000474-GPOS-00219 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful accesses to objects occur.' + status: not applicable + + - id: SRG-OS-000475-GPOS-00220 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records for all direct access to the information system.' + status: not applicable + + - id: SRG-OS-000476-GPOS-00221 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records for all account creations, modifications, disabling, and termination events.' + status: not applicable + + - id: SRG-OS-000477-GPOS-00222 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records for all kernel module load, unload, and restart actions, and also for all program initiations.' + status: not applicable + + - id: SRG-OS-000479-GPOS-00224 + levels: + - medium + title: 'Red Hat Hummingbird must, at a minimum, off-load audit data from interconnected systems in real time and off-load audit data from standalone systems weekly.' + status: not applicable + + - id: SRG-OS-000480-GPOS-00225 + levels: + - medium + title: 'Red Hat Hummingbird must prevent the use of dictionary words for passwords.' + status: not applicable + + - id: SRG-OS-000480-GPOS-00226 + levels: + - medium + title: 'Red Hat Hummingbird must enforce a delay of at least 4 seconds between logon prompts following a failed logon attempt.' + status: not applicable + + - id: SRG-OS-000480-GPOS-00228 + levels: + - medium + title: 'Red Hat Hummingbird must define default permissions for all authenticated users in such a way that the user can only read and modify their own files.' + status: not applicable + + - id: SRG-OS-000480-GPOS-00229 + levels: + - high + title: 'Red Hat Hummingbird must not allow an unattended or automatic logon to the system.' + status: not applicable + + - id: SRG-OS-000480-GPOS-00232 + levels: + - medium + title: 'Red Hat Hummingbird must enable an application firewall, if available.' + status: not applicable + + - id: SRG-OS-000481-GPOS-00481 + levels: + - high + title: 'Red Hat Hummingbird must protect the confidentiality and integrity of communications with wireless peripherals.' + status: not applicable + + - id: SRG-OS-000755-GPOS-00220 + levels: + - medium + title: 'Red Hat Hummingbird must monitor the use of maintenance tools that execute with increased privilege.' + status: not applicable + + - id: SRG-OS-000057-GPOS-00027 + levels: + - medium + title: 'Red Hat Hummingbird must protect audit information from unauthorized read access.' + status: not applicable + + - id: SRG-OS-000058-GPOS-00028 + levels: + - medium + title: 'Red Hat Hummingbird must protect audit information from unauthorized modification.' + status: not applicable + + - id: SRG-OS-000059-GPOS-00029 + levels: + - medium + title: 'Red Hat Hummingbird must protect audit information from unauthorized deletion.' + status: not applicable + + - id: SRG-OS-000069-GPOS-00037 + levels: + - medium + title: 'Red Hat Hummingbird must enforce password complexity by requiring that at least one uppercase character be used.' + status: not applicable + + - id: SRG-OS-000076-GPOS-00044 + levels: + - medium + title: 'Red Hat Hummingbird must enforce a 60-day maximum password lifetime restriction.' + status: not applicable + + - id: SRG-OS-000120-GPOS-00061 + levels: + - medium + title: 'Red Hat Hummingbird must use mechanisms meeting the requirements of applicable federal laws, Executive orders, directives, policies, regulations, standards, and guidance for authentication to a cryptographic module.' + status: not applicable + + - id: SRG-OS-000355-GPOS-00143 + levels: + - medium + title: 'Red Hat Hummingbird must, for networked systems, compare internal information system clocks at least every 24 hours with an authoritative time source.' + status: not applicable + + - id: SRG-OS-000375-GPOS-00160 + levels: + - medium + title: 'Red Hat Hummingbird must implement multifactor authentication for remote access to privileged accounts in such a way that one of the factors is provided by a device separate from the system gaining access.' + status: not applicable + + - id: SRG-OS-000478-GPOS-00223 + levels: + - high + title: 'Red Hat Hummingbird must implement NIST FIPS-validated cryptography for the following: to provision digital signatures, to generate cryptographic hashes, and to protect unclassified information requiring confidentiality and cryptographic protection in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards.' + status: automated + rules: + - configure_crypto_policy + - package_crypto-policies_installed + - var_system_crypto_policy=fips + + - id: SRG-OS-000028-GPOS-00009 + levels: + - high + title: 'Red Hat Hummingbird must retain a users session lock until that user reestablishes access using established identification and authentication procedures.' + status: not applicable + + - id: SRG-OS-000029-GPOS-00010 + levels: + - medium + title: 'Red Hat Hummingbird must initiate a session lock after a 15-minute period of inactivity for all connection types.' + status: not applicable + + - id: SRG-OS-000030-GPOS-00011 + levels: + - medium + title: 'Red Hat Hummingbird must provide the capability for users to directly initiate a session lock for all connection types.' + status: not applicable + + - id: SRG-OS-000031-GPOS-00012 + levels: + - medium + title: 'Red Hat Hummingbird must conceal, via the session lock, information previously visible on the display with a publicly viewable image.' + status: not applicable + + - id: SRG-OS-000037-GPOS-00015 + levels: + - medium + title: 'Red Hat Hummingbird must produce audit records containing information to establish what type of events occurred.' + status: not applicable + + - id: SRG-OS-000042-GPOS-00020 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records containing the full-text recording of privileged commands.' + status: not applicable + + - id: SRG-OS-000062-GPOS-00031 + levels: + - medium + title: 'Red Hat Hummingbird must provide audit record generation capability for DoD-defined auditable events for all operating system components.' + status: not applicable + + - id: SRG-OS-000064-GPOS-00033 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to access privileges occur.' + status: not applicable + + - id: SRG-OS-000073-GPOS-00041 + levels: + - high + title: 'Red Hat Hummingbird must store only encrypted representations of passwords.' + status: not applicable + + - id: SRG-OS-000080-GPOS-00048 + levels: + - medium + title: 'Red Hat Hummingbird must enforce approved authorizations for logical access to information and system resources in accordance with applicable access control policies.' + status: not applicable + + - id: SRG-OS-000095-GPOS-00049 + levels: + - medium + title: 'Red Hat Hummingbird must be configured to disable non-essential capabilities.' + status: not applicable + + - id: SRG-OS-000134-GPOS-00068 + levels: + - medium + title: 'Red Hat Hummingbird must isolate security functions from nonsecurity functions.' + status: not applicable + + - id: SRG-OS-000163-GPOS-00072 + levels: + - medium + title: 'Red Hat Hummingbird must terminate all network connections associated with a communications session at the end of the session, or as follows: for in-band management sessions (privileged sessions), the session must be terminated after 10 minutes of inactivity; and for user sessions (non-privileged session), the session must be terminated after 15 minutes of inactivity, except to fulfill documented and validated mission requirements.' + status: not applicable + + - id: SRG-OS-000228-GPOS-00088 + levels: + - medium + title: 'Any publically accessible connection to Red Hat Hummingbird must display the Standard Mandatory DoD Notice and Consent Banner before granting access to the system.' + status: not applicable + + - id: SRG-OS-000250-GPOS-00093 + levels: + - high + title: 'Red Hat Hummingbird must implement cryptography to protect the integrity of remote access sessions.' + status: not applicable + + - id: SRG-OS-000254-GPOS-00095 + levels: + - medium + title: 'Red Hat Hummingbird must initiate session audits at system start-up.' + status: not applicable + + - id: SRG-OS-000269-GPOS-00103 + levels: + - medium + title: 'In the event of a system failure, Red Hat Hummingbird must preserve any information necessary to determine cause of failure and any information necessary to return to operations with least disruption to mission processes.' + status: not applicable + + - id: SRG-OS-000324-GPOS-00125 + levels: + - high + title: 'Red Hat Hummingbird must prevent nonprivileged users from executing privileged functions to include disabling, circumventing, or altering implemented security safeguards/countermeasures.' + status: not applicable + + - id: SRG-OS-000341-GPOS-00132 + levels: + - low + title: "Red Hat Hummingbird must allocate audit record storage capacity to store at least one week's worth of audit records, when audit records are not immediately sent to a central audit record storage facility." + status: not applicable + + - id: SRG-OS-000368-GPOS-00154 + levels: + - medium + title: 'Red Hat Hummingbird must prevent program execution in accordance with local policies regarding software program usage and restrictions and/or rules authorizing the terms and conditions of software program usage.' + status: not applicable + + - id: SRG-OS-000373-GPOS-00156 + levels: + - medium + title: 'Red Hat Hummingbird must require users to reauthenticate for privilege escalation.' + status: not applicable + + - id: SRG-OS-000373-GPOS-00157 + levels: + - medium + title: 'Red Hat Hummingbird must require users to reauthenticate when changing roles.' + status: not applicable + + - id: SRG-OS-000373-GPOS-00158 + levels: + - medium + title: 'Red Hat Hummingbird must require users to reauthenticate when changing authenticators.' + status: not applicable + + - id: SRG-OS-000384-GPOS-00167 + levels: + - medium + title: 'Red Hat Hummingbird, for PKI-based authentication, must implement a local cache of revocation data to support path discovery and validation in case of the inability to access revocation information via the network.' + status: manual + + - id: SRG-OS-000392-GPOS-00172 + levels: + - medium + title: 'Red Hat Hummingbird must audit all activities performed during nonlocal maintenance and diagnostic sessions.' + status: not applicable + + - id: SRG-OS-000396-GPOS-00176 + levels: + - high + title: 'Red Hat Hummingbird must implement NSA-approved cryptography to protect classified information in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards.' + status: automated + rules: + - configure_crypto_policy + - package_crypto-policies_installed + + - id: SRG-OS-000420-GPOS-00186 + levels: + - medium + title: 'Red Hat Hummingbird must protect against or limit the effects of Denial of Service (DoS) attacks by ensuring the operating system is implementing rate-limiting measures on impacted network interfaces.' + status: not applicable + + - id: SRG-OS-000423-GPOS-00187 + levels: + - high + title: 'Red Hat Hummingbird must protect the confidentiality and integrity of transmitted information.' + status: not applicable + + - id: SRG-OS-000433-GPOS-00192 + levels: + - medium + title: 'Red Hat Hummingbird must implement non-executable data to protect its memory from unauthorized code execution.' + status: not applicable + + - id: SRG-OS-000439-GPOS-00195 + levels: + - medium + title: 'Red Hat Hummingbird must install security-relevant software updates within the time period directed by an authoritative source (e.g., IAVM, CTOs, DTMs, and STIGs).' + status: not applicable + + - id: SRG-OS-000445-GPOS-00199 + levels: + - medium + title: 'Red Hat Hummingbird must verify correct operation of all security functions.' + status: not applicable + + - id: SRG-OS-000462-GPOS-00206 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to modify privileges occur.' + status: not applicable + + - id: SRG-OS-000466-GPOS-00210 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to delete privileges occur.' + status: not applicable + + - id: SRG-OS-000467-GPOS-00211 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to delete security levels occur.' + status: not applicable + + - id: SRG-OS-000468-GPOS-00212 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records when successful/unsuccessful attempts to delete security objects occur.' + status: not applicable + + - id: SRG-OS-000471-GPOS-00215 + levels: + - medium + title: 'Red Hat Hummingbird must generate audit records for privileged activities or other system-level access.' + status: not applicable + + - id: SRG-OS-000480-GPOS-00227 + levels: + - medium + title: 'Red Hat Hummingbird must be configured in accordance with the security configuration settings based on DoD security configuration or implementation guidance, including STIGs, NSA configuration guides, CTOs, and DTMs.' + status: automated + rules: + - file_owner_etc_gshadow + - file_groupowner_backup_etc_group + - dir_perms_world_writable_root_owned + - file_permissions_etc_group + - file_owner_etc_shadow + - installed_OS_is_vendor_supported + - package_unbound_removed + - file_permissions_etc_passwd + - no_host_based_files + - file_groupowner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_permissions_backup_etc_gshadow + - file_permissions_ungroupowned + - file_groupowner_etc_passwd + - file_groupowner_etc_shadow + - file_permissions_home_directories + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_shadow + - file_permission_user_init_files + - package_tftp-server_removed + - package_vsftpd_removed + - file_owner_etc_passwd + - file_groupownership_home_directories + - file_permissions_etc_gshadow + - file_permissions_backup_etc_shadow + - package_tuned_removed + - file_permissions_etc_shadow + - file_groupowner_etc_group + - file_owner_backup_etc_group + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_group + - file_owner_etc_group + - no_user_host_based_files + - package_gssproxy_removed + - file_permission_user_init_files_root + - file_groupowner_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - package_nfs-utils_removed + - var_user_initialization_files_regex=all_dotfiles + + - id: SRG-OS-000480-GPOS-00230 + levels: + - medium + title: 'Red Hat Hummingbird must limit the ability of non-privileged users to grant other users direct access to the contents of their home directories/folders.' + status: automated + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_profile + - var_accounts_user_umask=027 + + - id: SRG-OS-000590-GPOS-00110 + levels: + - medium + title: 'Red Hat Hummingbird must disable accounts when the accounts are no longer associated to a user.' + status: not applicable + + - id: SRG-OS-000690-GPOS-00140 + levels: + - medium + title: 'Red Hat Hummingbird must prohibit the use or connection of unauthorized hardware components.' + status: not applicable + + - id: SRG-OS-000705-GPOS-00150 + levels: + - medium + title: 'Red Hat Hummingbird must implement multifactor authentication for local, network, and/or remote access to privileged accounts and/or nonprivileged accounts such that the device meets organization-defined strength of mechanism requirements.' + status: not applicable + + - id: SRG-OS-000710-GPOS-00160 + levels: + - medium + title: 'Red Hat Hummingbird must, for password-based authentication, verify when users create or update passwords the passwords are not found on the list of commonly-used, expected, or compromised passwords in IA-5 (1) (a).' + status: does not meet + + - id: SRG-OS-000720-GPOS-00170 + levels: + - medium + title: 'Red Hat Hummingbird must for password-based authentication, require immediate selection of a new password upon account recovery.' + status: does not meet + + - id: SRG-OS-000725-GPOS-00180 + levels: + - medium + title: 'Red Hat Hummingbird must for password-based authentication, allow user selection of long passwords and passphrases, including spaces and all printable characters.' + status: inherently met + + - id: SRG-OS-000730-GPOS-00190 + levels: + - medium + title: 'Red Hat Hummingbird must, for password-based authentication, employ automated tools to assist the user in selecting strong password authenticators.' + status: not applicable + + - id: SRG-OS-000745-GPOS-00210 + levels: + - medium + title: 'Red Hat Hummingbird must accept only external credentials that are NIST-compliant.' + status: does not meet + + - id: SRG-OS-000775-GPOS-00230 + levels: + - medium + title: 'Red Hat Hummingbird must include only approved trust anchors in trust stores or certificate stores managed by the organization.' + status: manual + + - id: SRG-OS-000780-GPOS-00240 + levels: + - medium + title: 'Red Hat Hummingbird must provide protected storage for cryptographic keys with organization-defined safeguards and/or hardware protected key store.' + status: not applicable + + - id: SRG-OS-000785-GPOS-00250 + levels: + - medium + title: 'Red Hat Hummingbird must synchronize system clocks within and between systems or system components.' + status: not applicable + + - id: SRG-OS-000366-GPOS-00153 + levels: + - high + title: 'Red Hat Hummingbird must prevent the installation of patches, service packs, device drivers, or operating system components without verification they have been digitally signed using a certificate that is recognized and approved by the organization.' + status: automated + rules: + - ensure_redhat_gpgkey_installed diff --git a/products/hummingbird/product.yml b/products/hummingbird/product.yml new file mode 100644 index 000000000000..70ae90fe910a --- /dev/null +++ b/products/hummingbird/product.yml @@ -0,0 +1,23 @@ +product: hummingbird +full_name: Hummingbird +type: platform + +benchmark_id: HUMMINGBIRD +benchmark_root: "../../linux_os/guide" +components_root: "../../components" + +profiles_root: "./profiles" + +pkg_manager: "dnf" + +init_system: "systemd" + +cpes_root: "../../shared/applicability" +cpes: + - hummingbird: + name: "cpe:/a:redhat:hummingbird" + title: "Hummingbird" + check_id: installed_OS_is_hummingbird + +reference_uris: + cis: 'https://www.cisecurity.org/benchmark/red_hat_linux/' diff --git a/products/hummingbird/profiles/cis.profile b/products/hummingbird/profiles/cis.profile new file mode 100644 index 000000000000..9b1f5661aa7d --- /dev/null +++ b/products/hummingbird/profiles/cis.profile @@ -0,0 +1,24 @@ +--- +documentation_complete: true + +metadata: + version: vendor + SMEs: + - mab879 + - ggbecker + +reference: https://www.cisecurity.org/benchmark/red_hat_linux/ + +title: 'CIS Red Hat Hummingbird Benchmark for Level 2 - Server' + +description: |- + This profile defines a baseline inspired by the "Level 2 - Server" + configuration from the Center for Internet Security® Red Hat Enterprise + Linux 10 Benchmark™, v1.0.1, released 2025-09-30, modified and tailored + to Hummingbird container images. + + This profile includes Center for Internet Security® + Red Hat Enterprise Linux 10 CIS Benchmarks™ content. + +selections: + - cis_hummingbird:all:l2_server diff --git a/products/hummingbird/profiles/stig.profile b/products/hummingbird/profiles/stig.profile new file mode 100644 index 000000000000..e2f585834d9f --- /dev/null +++ b/products/hummingbird/profiles/stig.profile @@ -0,0 +1,23 @@ +--- +documentation_complete: true + +metadata: + version: vendor + SMEs: + - jcerny + +reference: https://www.cyber.mil/stigs/downloads/?_dl_facet_stigs=operating-systems%2Cunix-linux + +title: 'Red Hat STIG for Red Hat Hummingbird' + +description: |- + This is a profile based on what is expected in the Hummingbird STIG. + It is not based on the DISA STIG for Hummingbird, because it was not available at time of + the release. + + In addition to being applicable to Red Hat Hummingbird, this + configuration baseline is applicable to the operating system tier of + Red Hat technologies that are based on Red Hat Hummingbird. + +selections: + - stig_hummingbird:all diff --git a/products/ocp4/CMakeLists.txt b/products/ocp4/CMakeLists.txt index 31e9657b99ff..a0eaf870fea1 100644 --- a/products/ocp4/CMakeLists.txt +++ b/products/ocp4/CMakeLists.txt @@ -5,5 +5,6 @@ endif() set(PRODUCT "ocp4") set(PRODUCT_REMEDIATION_LANGUAGES "ignition;kubernetes") +set(PRODUCT_CEL_ENABLED TRUE) ssg_build_product(${PRODUCT}) diff --git a/products/ocp4/profiles/cis-1-7.profile b/products/ocp4/profiles/cis-1-7.profile index 9ca64c32198a..f26be121c46d 100644 --- a/products/ocp4/profiles/cis-1-7.profile +++ b/products/ocp4/profiles/cis-1-7.profile @@ -5,6 +5,8 @@ title: 'CIS Red Hat OpenShift Container Platform 4 Benchmark' platform: ocp4 +status: deprecated + metadata: SMEs: - rhmdnd diff --git a/products/ocp4/profiles/cis-1-9.profile b/products/ocp4/profiles/cis-1-9.profile new file mode 100644 index 000000000000..21109f3e7a1a --- /dev/null +++ b/products/ocp4/profiles/cis-1-9.profile @@ -0,0 +1,37 @@ +--- +documentation_complete: true + +title: 'CIS Red Hat OpenShift Container Platform 4 Benchmark' + +platform: ocp4 + +metadata: + SMEs: + - rhmdnd + - Vincent056 + - yuumasato + version: 1.9.0 + +description: |- + This profile defines a baseline that aligns to the Center for Internet Security® + Red Hat OpenShift Container Platform 4 Benchmark™, V1.9.0. + + This profile includes Center for Internet Security® + Red Hat OpenShift Container Platform 4 CIS Benchmarks™ content. + + Note that this part of the profile is meant to run on the Platform that + Red Hat OpenShift Container Platform 4 runs on top of. + + This profile is applicable to OpenShift versions 4.12 and greater. + +filter_rules: '"ocp4-node" not in platform and "ocp4-master-node" not in platform and "ocp4-node-on-sdn" + not in platform and "ocp4-node-on-ovn" not in platform' + +selections: + - cis_ocp_190:all + ### Variables + - var_openshift_audit_profile=WriteRequestBodies + ### Helper Rules + ### This is a helper rule to fetch the required api resource for detecting OCP version + - version_detect_in_ocp + - version_detect_in_hypershift diff --git a/products/ocp4/profiles/cis-node-1-7.profile b/products/ocp4/profiles/cis-node-1-7.profile index bba8260fec3b..3e7a89d6bae4 100644 --- a/products/ocp4/profiles/cis-node-1-7.profile +++ b/products/ocp4/profiles/cis-node-1-7.profile @@ -5,6 +5,8 @@ title: 'CIS Red Hat OpenShift Container Platform 4 Benchmark' platform: ocp4-node +status: deprecated + metadata: SMEs: - rhmdnd diff --git a/products/ocp4/profiles/cis-node-1-9.profile b/products/ocp4/profiles/cis-node-1-9.profile new file mode 100644 index 000000000000..27ded73fe163 --- /dev/null +++ b/products/ocp4/profiles/cis-node-1-9.profile @@ -0,0 +1,31 @@ +--- +documentation_complete: true + +title: 'CIS Red Hat OpenShift Container Platform 4 Benchmark' + +platform: ocp4-node + +metadata: + SMEs: + - rhmdnd + - Vincent056 + - yuumasato + version: 1.9.0 + +description: |- + This profile defines a baseline that aligns to the Center for Internet Security® + Red Hat OpenShift Container Platform 4 Benchmark™, V1.9.0. + + This profile includes Center for Internet Security® + Red Hat OpenShift Container Platform 4 CIS Benchmarks™ content. + + Note that this part of the profile is meant to run on the Operating System that + Red Hat OpenShift Container Platform 4 runs on top of. + + This profile is applicable to OpenShift versions 4.12 and greater. + +filter_rules: '"ocp4-node" in platform or "ocp4-master-node" in platform or "ocp4-node-on-sdn" in platform + or "ocp4-node-on-ovn" in platform' + +selections: + - cis_ocp_190:all diff --git a/products/ocp4/profiles/cis-node.profile b/products/ocp4/profiles/cis-node.profile index bd1ce3bfce8a..90d8cf879591 100644 --- a/products/ocp4/profiles/cis-node.profile +++ b/products/ocp4/profiles/cis-node.profile @@ -10,11 +10,11 @@ metadata: - rhmdnd - Vincent056 - yuumasato - version: 1.7.0 + version: 1.9.0 description: |- This profile defines a baseline that aligns to the Center for Internet Security® - Red Hat OpenShift Container Platform 4 Benchmark™, V1.7. + Red Hat OpenShift Container Platform 4 Benchmark™, V1.9.0. This profile includes Center for Internet Security® Red Hat OpenShift Container Platform 4 CIS Benchmarks™ content. @@ -24,4 +24,4 @@ description: |- This profile is applicable to OpenShift versions 4.12 and greater. -extends: cis-node-1-7 +extends: cis-node-1-9 diff --git a/products/ocp4/profiles/cis-vm-extension.profile b/products/ocp4/profiles/cis-vm-extension.profile new file mode 100644 index 000000000000..a835ac42f886 --- /dev/null +++ b/products/ocp4/profiles/cis-vm-extension.profile @@ -0,0 +1,30 @@ +--- +documentation_complete: true + +metadata: + version: 1.0.0 + SMEs: + - rhmdnd + - Vincent056 + - yuumasato + +title: 'CIS Red Hat Openshift Virtual Machine Extension Benchmark' + +description: |- + This profile defines a baseline that aligns to the Center for Internet Security® + Red Hat OpenShift Virtual Machine Extension Benchmark™, V1.0.0. + + This profile includes Center for Internet Security® + Red Hat OpenShift Virtual Machine Extension Benchmarks™ content. + + Note that this part of the profile is meant to run on the Platform that + Red Hat OpenShift Container Platform runs on top of. + +scanner_type: CEL + +selections: + - kubevirt-nonroot-feature-gate-is-enabled + - kubevirt-no-permitted-host-devices + - kubevirt-persistent-reservation-disabled + - kubevirt-no-vms-overcommitting-guest-memory + - kubevirt-enforce-trusted-tls-registries diff --git a/products/ocp4/profiles/cis.profile b/products/ocp4/profiles/cis.profile index e46d12ad28c1..f63649d5437f 100644 --- a/products/ocp4/profiles/cis.profile +++ b/products/ocp4/profiles/cis.profile @@ -10,11 +10,11 @@ metadata: - rhmdnd - Vincent056 - yuumasato - version: 1.7.0 + version: 1.9.0 description: |- This profile defines a baseline that aligns to the Center for Internet Security® - Red Hat OpenShift Container Platform 4 Benchmark™, V1.7. + Red Hat OpenShift Container Platform 4 Benchmark™, V1.9.0. This profile includes Center for Internet Security® Red Hat OpenShift Container Platform 4 CIS Benchmarks™ content. @@ -24,4 +24,4 @@ description: |- This profile is applicable to OpenShift versions 4.12 and greater. -extends: cis-1-7 +extends: cis-1-9 diff --git a/products/ol10/profiles/e8.profile b/products/ol10/profiles/e8.profile index 92ef5b8b0541..cb6b3cb6ecdf 100644 --- a/products/ol10/profiles/e8.profile +++ b/products/ol10/profiles/e8.profile @@ -33,3 +33,4 @@ selections: # authselect is enabled by default - '!enable_authselect' - var_authselect_profile=local + - '!configure_ssh_crypto_policy' diff --git a/products/ol10/profiles/hipaa.profile b/products/ol10/profiles/hipaa.profile index 900b942a72a8..6c9bea239ae0 100644 --- a/products/ol10/profiles/hipaa.profile +++ b/products/ol10/profiles/hipaa.profile @@ -61,6 +61,7 @@ selections: - '!sshd_disable_kerb_auth' - '!sshd_disable_gssapi_auth' - '!service_rlogin_disabled' + - '!configure_ssh_crypto_policy' # authselect is enabled by default - '!enable_authselect' diff --git a/products/ol10/profiles/ism_o.profile b/products/ol10/profiles/ism_o.profile index 346e4cc4a62e..db42368179c0 100644 --- a/products/ol10/profiles/ism_o.profile +++ b/products/ol10/profiles/ism_o.profile @@ -75,6 +75,7 @@ selections: - '!accounts_password_all_shadowed' - '!usbguard_allow_hid_and_hub' - '!sshd_allow_only_protocol2' + - '!configure_ssh_crypto_policy' # Older rules, no longer needed - '!security_patches_up_to_date' diff --git a/products/ol10/profiles/ism_o_secret.profile b/products/ol10/profiles/ism_o_secret.profile index d4784c6a6dc4..a16c1f8e1ce4 100644 --- a/products/ol10/profiles/ism_o_secret.profile +++ b/products/ol10/profiles/ism_o_secret.profile @@ -76,6 +76,7 @@ selections: - "!usbguard_allow_hid_and_hub" - "!sshd_allow_only_protocol2" - var_authselect_profile=local + - "!configure_ssh_crypto_policy" # Needed for references in other products - '!security_patches_up_to_date' diff --git a/products/ol10/profiles/ism_o_top_secret.profile b/products/ol10/profiles/ism_o_top_secret.profile index b298e2dc194a..86488417d6c0 100644 --- a/products/ol10/profiles/ism_o_top_secret.profile +++ b/products/ol10/profiles/ism_o_top_secret.profile @@ -76,6 +76,7 @@ selections: - "!usbguard_allow_hid_and_hub" - "!sshd_allow_only_protocol2" - var_authselect_profile=local + - "!configure_ssh_crypto_policy" # Needed for references in other products - '!security_patches_up_to_date' diff --git a/products/ol10/profiles/ospp.profile b/products/ol10/profiles/ospp.profile index 6344b2d9d587..56d272d9f25d 100644 --- a/products/ol10/profiles/ospp.profile +++ b/products/ol10/profiles/ospp.profile @@ -65,3 +65,4 @@ selections: - '!zipl_page_alloc_shuffle_argument' - '!zipl_systemd_debug-shell_argument_absent' - var_authselect_profile=local + - '!configure_ssh_crypto_policy' diff --git a/products/ol10/profiles/pci-dss.profile b/products/ol10/profiles/pci-dss.profile index 55bb210d97d1..6fd45dbccbd5 100644 --- a/products/ol10/profiles/pci-dss.profile +++ b/products/ol10/profiles/pci-dss.profile @@ -77,3 +77,4 @@ selections: # Irrelevant for ol10 - '!enable_dconf_user_profile' - var_authselect_profile=local + - '!configure_ssh_crypto_policy' diff --git a/products/ol7/profiles/ncp.profile b/products/ol7/profiles/ncp.profile index 2acb9c798f04..426901de8641 100644 --- a/products/ol7/profiles/ncp.profile +++ b/products/ol7/profiles/ncp.profile @@ -36,6 +36,7 @@ extends: ospp selections: - installed_OS_is_vendor_supported - login_banner_text=usgcb_default + - login_banner_contents=usgcb_default - inactivity_timeout_value=15_minutes - var_password_pam_minlen=15 - accounts_password_all_shadowed @@ -323,6 +324,8 @@ selections: - dconf_gnome_disable_wifi_notification - dconf_gnome_enable_smartcard_auth - dconf_gnome_login_banner_text + - dconf_login_banner_text=usgcb_default + - dconf_login_banner_contents=usgcb_default - dconf_gnome_login_retries - dconf_gnome_remote_access_credential_prompt - dconf_gnome_remote_access_encryption diff --git a/products/ol7/profiles/stig.profile b/products/ol7/profiles/stig.profile index 133832c72af2..27085939d81a 100644 --- a/products/ol7/profiles/stig.profile +++ b/products/ol7/profiles/stig.profile @@ -8,6 +8,7 @@ description: |- selections: - login_banner_text=dod_banners + - login_banner_contents=dod_default - inactivity_timeout_value=15_minutes - var_screensaver_lock_delay=5_seconds - sshd_idle_timeout_value=10_minutes @@ -54,6 +55,8 @@ selections: - dconf_db_up_to_date - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text + - dconf_login_banner_text=dod_default + - dconf_login_banner_contents=dod_default - banner_etc_issue - dconf_gnome_screensaver_lock_enabled - dconf_gnome_screensaver_lock_locked diff --git a/products/ol8/profiles/ospp.profile b/products/ol8/profiles/ospp.profile index 3dc090fe3a4e..2778f477c9bc 100644 --- a/products/ol8/profiles/ospp.profile +++ b/products/ol8/profiles/ospp.profile @@ -142,6 +142,7 @@ selections: - package_abrt-addon-kerneloops_removed - ssh_client_use_strong_rng_csh - chronyd_no_chronyc_network + - chronyd_configure_local_socket - mount_option_var_log_noexec - sysctl_kernel_core_pattern - mount_option_dev_shm_nodev diff --git a/products/ol8/profiles/stig.profile b/products/ol8/profiles/stig.profile index fba0400ef38b..7280c563534b 100644 --- a/products/ol8/profiles/stig.profile +++ b/products/ol8/profiles/stig.profile @@ -1,7 +1,7 @@ documentation_complete: true metadata: - version: V2R6 + version: V2R8 reference: https://www.cyber.mil/stigs/downloads/?_dl_facet_stigs=operating-systems%2Cunix-linux @@ -9,7 +9,7 @@ title: 'DISA STIG for Oracle Linux 8' description: |- This profile contains configuration checks that align to the - DISA STIG for Oracle Linux 8 V2R6. + DISA STIG for Oracle Linux 8 V2R8. selections: ### Variables @@ -28,7 +28,6 @@ selections: - var_password_pam_remember_control_flag=ol8 - var_selinux_state=enforcing - var_selinux_policy_name=targeted - - var_accounts_password_minlen_login_defs=15 - var_password_pam_unix_rounds=5000 - var_password_pam_minlen=15 - var_password_pam_ocredit=1 @@ -39,7 +38,7 @@ selections: - var_password_pam_retry=3 - var_password_pam_minlen=15 - sshd_approved_macs=stig_extended - - sshd_approved_ciphers=stig_extended + - sshd_approved_ciphers=stig_ol8 - sshd_idle_timeout_value=10_minutes - var_accounts_authorized_local_users_regex=ol8 - var_accounts_passwords_pam_faillock_deny=3 @@ -61,15 +60,29 @@ selections: - var_auditd_disk_full_action=ol8 - var_sssd_certificate_verification_digest_function=sha1 - login_banner_text=dod_banners + - login_banner_contents=dod_default + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default - var_authselect_profile=sssd - var_multiple_time_servers=stig ### Enable / Configure FIPS - # OL08-00-010293, OL08-00-010020 + # OL08-00-010020, OL08-00-010182 - enable_fips_mode - - var_system_crypto_policy=fips + - var_system_crypto_policy=fips_stig + # OL08-00-010180 + - package_crypto-policies_installed + - package_crypto-policies_installed.severity=high + # OL08-00-010183 - configure_crypto_policy + # OL08-00-010181, OL08-00-010184, OL08-00-010182 + - fips_crypto_subpolicy + - fips_crypto_subpolicy.severity=high + - fips_custom_stig_sub_policy + - fips_custom_stig_sub_policy.severity=high + # OL08-00-010187 - configure_bind_crypto_policy + # OL08-00-010186 - configure_libreswan_crypto_policy - configure_kerberos_crypto_policy - enable_dracut_fips_module @@ -162,6 +175,10 @@ selections: # OL08-00-010171 - package_policycoreutils_installed + # OL08-00-010185 + - harden_sshd_macs_openssh_conf_crypto_policy + - harden_sshd_macs_openssh_conf_crypto_policy.severity=high + # OL08-00-010190 - dir_perms_world_writable_sticky_bits @@ -190,24 +207,17 @@ selections: # OL08-00-010260 - file_groupowner_var_log - # OL08-00-010287 - - configure_ssh_crypto_policy - # OL08-00-010290 - harden_sshd_macs_opensshserver_conf_crypto_policy + - harden_sshd_macs_opensshserver_conf_crypto_policy.severity=high # OL08-00-010291 - harden_sshd_ciphers_opensshserver_conf_crypto_policy + - harden_sshd_ciphers_opensshserver_conf_crypto_policy.severity=high # OL08-00-010292 - sshd_use_strong_rng - # OL08-00-010294 - - configure_openssl_tls_crypto_policy - - # OL08-00-010295 - - configure_gnutls_tls_crypto_policy - # OL08-00-010300 - file_permissions_binary_dirs @@ -246,8 +256,7 @@ selections: - aide_scan_notification # OL08-00-010370 - - ensure_gpgcheck_globally_activated - - ensure_gpgcheck_never_disabled + - enable_gpgcheck_for_all_repositories # OL08-00-010371 - ensure_gpgcheck_local_packages @@ -408,9 +417,6 @@ selections: # OL08-00-010650 - mount_option_nosuid_remote_filesystems - # OL08-00-010660 - - accounts_user_dot_no_world_writable_programs - # OL08-00-010670 - service_kdump_disabled @@ -532,7 +538,11 @@ selections: # OL08-00-020035 - logind_session_timeout - - var_logind_session_timeout=15_minutes + - var_logind_session_timeout=10_minutes + + # OL08-00-020040 + - accounts_tmout + - var_accounts_tmout=10_min # OL08-00-020043 - vlock_installed @@ -542,6 +552,7 @@ selections: # OL08-00-020060 - dconf_gnome_screensaver_idle_delay + - inactivity_timeout_value=10_minutes # OL08-00-020080 - dconf_gnome_screensaver_user_locks @@ -604,9 +615,6 @@ selections: # OL08-00-020230 - accounts_password_pam_minlen - # OL08-00-020231 - - accounts_password_minlen_login_defs - # OL08-00-020240 - account_unique_id @@ -651,9 +659,6 @@ selections: # OL08-00-020331, OL08-00-020332 - no_empty_passwords - # OL08-00-020340 - - display_login_attempts - # OL08-00-020350 - sshd_print_last_log @@ -945,6 +950,7 @@ selections: # OL08-00-030742 - chronyd_no_chronyc_network + - chronyd_configure_local_socket # OL08-00-040000 - package_telnet-server_removed @@ -963,6 +969,7 @@ selections: # OL08-00-040010 - ensure_epel_repos_disabled + - ensure_epel_repos_disabled.severity=high # OL08-00-040020 - kernel_module_uvcvideo_disabled @@ -1191,9 +1198,6 @@ selections: # OL08-00-040341 - sshd_x11_use_localhost - # OL08-00-040342 - - sshd_use_approved_kex_ordered_stig - # OL08-00-040350 - tftp_uses_secure_mode_systemd diff --git a/products/ol8/profiles/stig_gui.profile b/products/ol8/profiles/stig_gui.profile index 8d26c7dd0d98..1c53fa35fdd0 100644 --- a/products/ol8/profiles/stig_gui.profile +++ b/products/ol8/profiles/stig_gui.profile @@ -1,13 +1,13 @@ documentation_complete: true metadata: - version: V2R6 + version: V2R8 title: 'DISA STIG with GUI for Oracle Linux 8' description: |- This profile contains configuration checks that align to the - DISA STIG with GUI for Oracle Linux V2R6. + DISA STIG with GUI for Oracle Linux V2R8. Warning: The installation and use of a Graphical User Interface (GUI) increases your attack vector and decreases your overall security posture. If diff --git a/products/ol9/profiles/e8.profile b/products/ol9/profiles/e8.profile index 3d47fe491c0f..18fbc4757f7d 100644 --- a/products/ol9/profiles/e8.profile +++ b/products/ol9/profiles/e8.profile @@ -27,3 +27,4 @@ selections: - '!package_talk_removed' - '!package_talk-server_removed' - '!ensure_redhat_gpgkey_installed' + - '!configure_ssh_crypto_policy' diff --git a/products/ol9/profiles/hipaa.profile b/products/ol9/profiles/hipaa.profile index 23e64e8c5d0b..3e3456216c10 100644 --- a/products/ol9/profiles/hipaa.profile +++ b/products/ol9/profiles/hipaa.profile @@ -89,3 +89,4 @@ selections: - "!sshd_use_approved_ciphers" - "!sshd_use_approved_macs" - "!sshd_use_priv_separation" + - "!configure_ssh_crypto_policy" diff --git a/products/ol9/profiles/ism_o.profile b/products/ol9/profiles/ism_o.profile index 54ccc9bf9e7b..19b45ed888c8 100644 --- a/products/ol9/profiles/ism_o.profile +++ b/products/ol9/profiles/ism_o.profile @@ -21,10 +21,6 @@ extends: e8 selections: - ism_o:all:top_secret - # Setting any nondefault, so a specific driver is expected - # using the same as in STIG - - var_smartcard_drivers=cac - # ISM 0418,1055,1402 # Rule is for authconfig not used in - "!enable_ldap_client" @@ -71,20 +67,41 @@ selections: - '!usbguard_allow_hid_and_hub' - '!sshd_allow_only_protocol2' - '!package_ypbind_removed' - - '!package_ypbind_removed' - '!package_xinetd_removed' - '!ensure_redhat_gpgkey_installed' - '!package_sequoia-sq_installed' - - '!audit_rules_usergroup_modification_opasswd' - - '!audit_rules_usergroup_modification_gshadow' - - '!audit_rules_usergroup_modification_passwd' - - '!audit_rules_usergroup_modification_group' - - '!audit_rules_usergroup_modification_shadow' - '!service_xinetd_disabled' - '!package_talk_removed' - '!package_talk-server_removed' - '!package_rsh-server_removed' - '!package_rsh_removed' - - - "var_password_hashing_algorithm_pam=sha512" - - "enable_dracut_fips_module" + - '!accounts_password_pam_ocredit' + - '!audit_rules_unsuccessful_file_modification_truncate' + - '!set_password_hashing_algorithm_systemauth' + - '!audit_rules_unsuccessful_file_modification_ftruncate' + - '!audit_rules_unsuccessful_file_modification_creat' + - '!sebool_kerberos_enabled' + - '!accounts_password_pam_minclass' + - '!dnf-automatic_apply_updates' + - '!set_password_hashing_algorithm_passwordauth' + - '!chronyd_or_ntpd_specify_multiple_servers' + - '!sebool_authlogin_radius' + - '!configure_kerberos_crypto_policy' + - '!set_password_hashing_algorithm_libuserconf' + - '!audit_rules_unsuccessful_file_modification_openat' + - '!sssd_enable_smartcards' + - '!accounts_password_pam_ucredit' + - '!package_opensc_installed' + - '!accounts_password_pam_lcredit' + - '!sebool_authlogin_nsswitch_use_ldap' + - '!chronyd_configure_pool_and_server' + - '!set_password_hashing_algorithm_logindefs' + - '!service_pcscd_enabled' + - '!package_pcsc-lite_installed' + - '!audit_rules_unsuccessful_file_modification_open' + - '!configure_opensc_card_drivers' + - '!accounts_password_pam_dcredit' + - '!secure_boot_enabled' + - '!audit_rules_unsuccessful_file_modification_open_by_handle_at' + - '!accounts_password_minlen_login_defs' + - '!configure_ssh_crypto_policy' diff --git a/products/ol9/profiles/ospp.profile b/products/ol9/profiles/ospp.profile index 0acf6672a569..84370f9a3622 100644 --- a/products/ol9/profiles/ospp.profile +++ b/products/ol9/profiles/ospp.profile @@ -135,7 +135,6 @@ selections: - enable_fips_mode - var_system_crypto_policy=fips_ospp - configure_crypto_policy - - configure_ssh_crypto_policy - configure_openssl_crypto_policy - enable_dracut_fips_module diff --git a/products/ol9/profiles/pci-dss.profile b/products/ol9/profiles/pci-dss.profile index 835e32687f46..935d6700cc4b 100644 --- a/products/ol9/profiles/pci-dss.profile +++ b/products/ol9/profiles/pci-dss.profile @@ -62,6 +62,7 @@ selections: - '!service_timesyncd_enabled' - '!audit_rules_file_deletion_events_renameat2' - '!audit_rules_dac_modification_fchmodat2' + - '!configure_ssh_crypto_policy' # Not applicable to OL9, packages not available in OL9 - '!package_cryptsetup-luks_installed' - '!service_rpcbind_disabled' diff --git a/products/ol9/profiles/stig.profile b/products/ol9/profiles/stig.profile index 883b970b43a8..e1501f1ababa 100644 --- a/products/ol9/profiles/stig.profile +++ b/products/ol9/profiles/stig.profile @@ -2,7 +2,7 @@ documentation_complete: true metadata: - version: V1R3 + version: V1R5 reference: https://www.cyber.mil/stigs/downloads/?_dl_facet_stigs=operating-systems%2Cunix-linux @@ -10,7 +10,7 @@ title: 'DISA STIG for Oracle Linux 9' description: |- This profile contains configuration checks that align to the - DISA STIG for Oracle Linux 9 V1R3. + DISA STIG for Oracle Linux 9 V1R5. selections: - stig_ol9:all diff --git a/products/ol9/profiles/stig_gui.profile b/products/ol9/profiles/stig_gui.profile index 178e85a21e57..3949f1087602 100644 --- a/products/ol9/profiles/stig_gui.profile +++ b/products/ol9/profiles/stig_gui.profile @@ -1,7 +1,7 @@ documentation_complete: true metadata: - version: V1R3 + version: V1R5 reference: https://www.cyber.mil/stigs/downloads/?_dl_facet_stigs=operating-systems%2Cunix-linux @@ -9,7 +9,7 @@ title: 'DISA STIG with GUI for Oracle Linux 9' description: |- This profile contains configuration checks that align to the - DISA STIG for Oracle Linux 9 V1R3. + DISA STIG for Oracle Linux 9 V1R5. Warning: The installation and use of a Graphical User Interface (GUI) increases your attack vector and decreases your overall security posture. If diff --git a/products/openembedded/profiles/expanded.profile b/products/openembedded/profiles/expanded.profile index 13db15a9530b..a43e6745f40c 100644 --- a/products/openembedded/profiles/expanded.profile +++ b/products/openembedded/profiles/expanded.profile @@ -112,8 +112,10 @@ selections: - service_dovecot_disabled - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - file_groupowner_etc_motd - file_owner_etc_motd - file_permissions_etc_motd diff --git a/products/openembedded/profiles/standard.profile b/products/openembedded/profiles/standard.profile index 37547a454e83..d183617a264b 100644 --- a/products/openembedded/profiles/standard.profile +++ b/products/openembedded/profiles/standard.profile @@ -107,8 +107,10 @@ selections: - service_dovecot_disabled - banner_etc_motd - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - banner_etc_issue - login_banner_text=cis_banners + - login_banner_contents=cis_default - file_groupowner_etc_motd - file_owner_etc_motd - file_permissions_etc_motd diff --git a/products/rhcos4/profiles/default.profile b/products/rhcos4/profiles/default.profile index fda198cccf44..eb7e2a6898e7 100644 --- a/products/rhcos4/profiles/default.profile +++ b/products/rhcos4/profiles/default.profile @@ -281,3 +281,12 @@ selections: - enable_dracut_fips_module - audit_delete_success - mount_option_var_log_nodev + - accounts_authorized_local_users + - service_vsftpd_disabled + - package_vsftpd_removed + - service_named_disabled + - service_atd_disabled + - service_cups_disabled + - audit_rules_networkconfig_modification_network_scripts + - audit_rules_mac_modification_etc_selinux + - audit_rules_login_events_faillog diff --git a/products/rhel10/controls/cis_rhel10.yml b/products/rhel10/controls/cis_rhel10.yml index 8269196f2993..7934783772be 100644 --- a/products/rhel10/controls/cis_rhel10.yml +++ b/products/rhel10/controls/cis_rhel10.yml @@ -366,9 +366,15 @@ controls: levels: - l1_server - l1_workstation - status: manual - related_rules: + status: partial + rules: - ensure_redhat_gpgkey_installed + - package_sequoia-sq_installed + notes: > + In CIS Benchmark, the requirement is manual, because of GPG keys for 3rd party repositories. + But, add the rule ensure_redhat_gpgkey_installed to the profile because the requirement 1.2.1.2 + adds ensure_gpgcheck_never_disabled which requires GPG key checking. If the Red Hat + GPG key wouldn't be installed, people won't be able to install any RPM package using dnf. - id: 1.2.1.2 title: Ensure gpgcheck is configured (Automated) @@ -706,7 +712,8 @@ controls: rules: - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_banners + - dconf_login_banner_text=cis_banners + - dconf_login_banner_contents=cis_default - id: 1.8.2 title: Ensure GDM disable-user-list is configured (Automated) @@ -817,6 +824,8 @@ controls: - l1_workstation status: automated rules: + - service_dnsmasq_disabled + related_rules: - package_dnsmasq_removed - id: 2.1.7 @@ -1981,7 +1990,8 @@ controls: - l2_workstation status: automated rules: - - accounts_passwords_pam_faillock_deny_root + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - var_accounts_passwords_pam_faillock_root_unlock_time=60 - id: 5.3.2.2.1 title: Ensure password number of changed characters is configured (Automated) @@ -2484,8 +2494,8 @@ controls: levels: - l1_server - l1_workstation - status: supported - related_rules: + status: automated + rules: - rsyslog_filecreatemode - id: 6.2.3.5 @@ -2613,8 +2623,11 @@ controls: - l2_workstation status: automated rules: + - auditd_data_retention_action_mail_acct - auditd_data_retention_admin_space_left_action - auditd_data_retention_space_left_action + - package_postfix_installed + - var_auditd_action_mail_acct=root - var_auditd_admin_space_left_action=cis_rhel10 - var_auditd_space_left_action=cis_rhel10 diff --git a/products/rhel10/controls/nist_800_53.yml b/products/rhel10/controls/nist_800_53.yml new file mode 100644 index 000000000000..78f26dcbc284 --- /dev/null +++ b/products/rhel10/controls/nist_800_53.yml @@ -0,0 +1,15 @@ +policy: NIST 800-53 Revision 5 (RHEL10) +title: NIST Special Publication 800-53 Revision 5 for RHEL10 +id: nist_800_53 +version: Revision 5 +source: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +product: rhel10 +controls_dir: nist_800_53 +levels: + - id: low + - id: moderate + inherits_from: + - low + - id: high + inherits_from: + - moderate diff --git a/products/rhel10/controls/nist_800_53/ac.yml b/products/rhel10/controls/nist_800_53/ac.yml new file mode 100644 index 000000000000..e052dceaf7a4 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ac.yml @@ -0,0 +1,842 @@ +# NIST 800-53 AC Family: Access Control +controls: + - id: ac-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ac-2 + title: Account Management + levels: + - low + rules: [] + status: pending + - id: ac-2.1 + title: Automated System Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.2 + title: Automated Temporary and Emergency Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.3 + title: Disable Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-2.4 + title: Automated Audit Actions + levels: + - moderate + rules: [] + status: pending + - id: ac-2.5 + title: Inactivity Logout + levels: + - moderate + rules: + - accounts_tmout + - no_invalid_shell_accounts_unlocked + - no_password_auth_for_systemaccounts + - no_shelllogin_for_systemaccounts + - inactivity_timeout_value=15_minutes + - var_accounts_tmout=15_min + status: automated + - id: ac-2.6 + title: Dynamic Privilege Management + rules: [] + status: pending + - id: ac-2.7 + title: Privileged User Accounts + rules: [] + status: pending + - id: ac-2.8 + title: Dynamic Account Management + rules: [] + status: pending + - id: ac-2.9 + title: Restrictions on Use of Shared and Group Accounts + rules: [] + status: pending + - id: ac-2.10 + title: Shared and Group Account Credential Change + rules: [] + status: pending + - id: ac-2.11 + title: Usage Conditions + levels: + - high + rules: [] + status: pending + - id: ac-2.12 + title: Account Monitoring for Atypical Usage + levels: + - high + rules: [] + status: pending + - id: ac-2.13 + title: Disable Accounts for High-risk Individuals + levels: + - moderate + rules: [] + status: pending + - id: ac-3 + title: Access Enforcement + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_umask_root + - audit_rules_immutable + - dir_perms_world_writable_sticky_bits + - directory_groupowner_sshd_config_d + - directory_owner_sshd_config_d + - directory_permissions_sshd_config_d + - ensure_pam_wheel_group_empty + - file_at_allow_exists + - file_at_deny_not_exist + - file_cron_allow_exists + - file_cron_deny_not_exist + - file_groupowner_at_allow + - file_groupowner_backup_etc_group + - file_groupowner_backup_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - file_groupowner_cron_allow + - file_groupowner_cron_d + - file_groupowner_cron_daily + - file_groupowner_cron_hourly + - file_groupowner_cron_monthly + - file_groupowner_cron_weekly + - file_groupowner_cron_yearly + - file_groupowner_crontab + - file_groupowner_etc_group + - file_groupowner_etc_gshadow + - file_groupowner_etc_issue + - file_groupowner_etc_issue_net + - file_groupowner_etc_motd + - file_groupowner_etc_passwd + - file_groupowner_etc_security_opasswd + - file_groupowner_etc_security_opasswd_old + - file_groupowner_etc_shadow + - file_groupowner_etc_shells + - file_groupowner_sshd_config + - file_groupowner_sshd_drop_in_config + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_at_allow + - file_owner_backup_etc_group + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_owner_backup_etc_shadow + - file_owner_cron_allow + - file_owner_cron_d + - file_owner_cron_daily + - file_owner_cron_hourly + - file_owner_cron_monthly + - file_owner_cron_weekly + - file_owner_cron_yearly + - file_owner_crontab + - file_owner_etc_group + - file_owner_etc_gshadow + - file_owner_etc_issue + - file_owner_etc_issue_net + - file_owner_etc_motd + - file_owner_etc_passwd + - file_owner_etc_security_opasswd + - file_owner_etc_security_opasswd_old + - file_owner_etc_shadow + - file_owner_etc_shells + - file_owner_sshd_config + - file_owner_sshd_drop_in_config + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_at_allow + - file_permissions_backup_etc_group + - file_permissions_backup_etc_gshadow + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_shadow + - file_permissions_cron_allow + - file_permissions_cron_d + - file_permissions_cron_daily + - file_permissions_cron_hourly + - file_permissions_cron_monthly + - file_permissions_cron_weekly + - file_permissions_cron_yearly + - file_permissions_crontab + - file_permissions_etc_group + - file_permissions_etc_gshadow + - file_permissions_etc_issue + - file_permissions_etc_issue_net + - file_permissions_etc_motd + - file_permissions_etc_passwd + - file_permissions_etc_security_opasswd + - file_permissions_etc_security_opasswd_old + - file_permissions_etc_shadow + - file_permissions_etc_shells + - file_permissions_sshd_config + - file_permissions_sshd_drop_in_config + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_unauthorized_world_writable + - grub2_enable_selinux + - grub2_password + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_home_nodev + - mount_option_home_nosuid + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - mount_option_var_log_audit_nodev + - mount_option_var_log_audit_noexec + - mount_option_var_log_audit_nosuid + - mount_option_var_log_nodev + - mount_option_var_log_noexec + - mount_option_var_log_nosuid + - mount_option_var_nodev + - mount_option_var_nosuid + - mount_option_var_tmp_nodev + - mount_option_var_tmp_noexec + - mount_option_var_tmp_nosuid + - package_libselinux_installed + - package_mcstrans_removed + - package_setroubleshoot_removed + - rsyslog_files_groupownership + - rsyslog_files_ownership + - rsyslog_files_permissions + - selinux_not_disabled + - selinux_policytype + - sshd_limit_user_access + - sysctl_fs_protected_hardlinks + - sysctl_fs_protected_symlinks + - use_pam_wheel_group_for_su + - var_accounts_user_umask=027 + - var_pam_wheel_group_for_su=cis + - var_selinux_policy_name=targeted + status: automated + - id: ac-3.1 + title: Restricted Access to Privileged Functions + rules: [] + status: pending + - id: ac-3.2 + title: Dual Authorization + rules: [] + status: pending + - id: ac-3.3 + title: Mandatory Access Control + rules: [] + status: pending + - id: ac-3.4 + title: Discretionary Access Control + rules: [] + status: pending + - id: ac-3.5 + title: Security-relevant Information + rules: [] + status: pending + - id: ac-3.6 + title: Protection of User and System Information + rules: [] + status: pending + - id: ac-3.7 + title: Role-based Access Control + rules: [] + status: pending + - id: ac-3.8 + title: Revocation of Access Authorizations + rules: [] + status: pending + - id: ac-3.9 + title: Controlled Release + rules: [] + status: pending + - id: ac-3.10 + title: Audited Override of Access Control Mechanisms + rules: [] + status: pending + - id: ac-3.11 + title: Restrict Access to Specific Information Types + rules: [] + status: pending + - id: ac-3.12 + title: Assert and Enforce Application Access + rules: [] + status: pending + - id: ac-3.13 + title: Attribute-based Access Control + rules: [] + status: pending + - id: ac-3.14 + title: Individual Access + rules: [] + status: pending + - id: ac-3.15 + title: Discretionary and Mandatory Access Control + rules: [] + status: pending + - id: ac-4 + title: Information Flow Enforcement + levels: + - moderate + rules: [] + status: pending + - id: ac-4.1 + title: Object Security and Privacy Attributes + rules: [] + status: pending + - id: ac-4.2 + title: Processing Domains + rules: [] + status: pending + - id: ac-4.3 + title: Dynamic Information Flow Control + rules: [] + status: pending + - id: ac-4.4 + title: Flow Control of Encrypted Information + levels: + - high + rules: [] + status: pending + - id: ac-4.5 + title: Embedded Data Types + rules: [] + status: pending + - id: ac-4.6 + title: Metadata + rules: [] + status: pending + - id: ac-4.7 + title: One-way Flow Mechanisms + rules: [] + status: pending + - id: ac-4.8 + title: Security and Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.9 + title: Human Reviews + rules: [] + status: pending + - id: ac-4.10 + title: Enable and Disable Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.11 + title: Configuration of Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.12 + title: Data Type Identifiers + rules: [] + status: pending + - id: ac-4.13 + title: Decomposition into Policy-relevant Subcomponents + rules: [] + status: pending + - id: ac-4.14 + title: Security or Privacy Policy Filter Constraints + rules: [] + status: pending + - id: ac-4.15 + title: Detection of Unsanctioned Information + rules: [] + status: pending + - id: ac-4.16 + title: Information Transfers on Interconnected Systems + rules: [] + status: pending + - id: ac-4.17 + title: Domain Authentication + rules: [] + status: pending + - id: ac-4.18 + title: Security Attribute Binding + rules: [] + status: pending + - id: ac-4.19 + title: Validation of Metadata + rules: [] + status: pending + - id: ac-4.20 + title: Approved Solutions + rules: [] + status: pending + - id: ac-4.21 + title: Physical or Logical Separation of Information Flows + rules: [] + status: pending + - id: ac-4.22 + title: Access Only + rules: [] + status: pending + - id: ac-4.23 + title: Modify Non-releasable Information + rules: [] + status: pending + - id: ac-4.24 + title: Internal Normalized Format + rules: [] + status: pending + - id: ac-4.25 + title: Data Sanitization + rules: [] + status: pending + - id: ac-4.26 + title: Audit Filtering Actions + rules: [] + status: pending + - id: ac-4.27 + title: Redundant/Independent Filtering Mechanisms + rules: [] + status: pending + - id: ac-4.28 + title: Linear Filter Pipelines + rules: [] + status: pending + - id: ac-4.29 + title: Filter Orchestration Engines + rules: [] + status: pending + - id: ac-4.30 + title: Filter Mechanisms Using Multiple Processes + rules: [] + status: pending + - id: ac-4.31 + title: Failed Content Transfer Prevention + rules: [] + status: pending + - id: ac-4.32 + title: Process Requirements for Information Transfer + rules: [] + status: pending + - id: ac-5 + title: Separation of Duties + levels: + - moderate + rules: [] + status: pending + - id: ac-6 + title: Least Privilege + levels: + - moderate + rules: + - sshd_disable_root_login + - sudo_add_use_pty + - sudo_remove_no_authenticate + - sudo_remove_nopasswd + status: automated + - id: ac-6.1 + title: Authorize Access to Security Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.2 + title: Non-privileged Access for Nonsecurity Functions + levels: + - moderate + rules: + - package_sudo_installed + status: automated + - id: ac-6.3 + title: Network Access to Privileged Commands + levels: + - high + rules: [] + status: pending + - id: ac-6.4 + title: Separate Processing Domains + rules: [] + status: pending + - id: ac-6.5 + title: Privileged Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-6.6 + title: Privileged Access by Non-organizational Users + rules: [] + status: pending + - id: ac-6.7 + title: Review of User Privileges + levels: + - moderate + rules: [] + status: pending + - id: ac-6.8 + title: Privilege Levels for Code Execution + rules: [] + status: pending + - id: ac-6.9 + title: Log Use of Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.10 + title: Prohibit Non-privileged Users from Executing Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-7 + title: Unsuccessful Logon Attempts + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - accounts_passwords_pam_faillock_deny + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - accounts_passwords_pam_faillock_unlock_time_with_zero + - var_accounts_passwords_pam_faillock_deny=5 + - var_accounts_passwords_pam_faillock_dir=run + - var_accounts_passwords_pam_faillock_root_unlock_time=60 + - var_accounts_passwords_pam_faillock_unlock_time=900 + status: automated + - id: ac-7.1 + title: Automatic Account Lock + rules: [] + status: pending + - id: ac-7.2 + title: Purge or Wipe Mobile Device + rules: [] + status: pending + - id: ac-7.3 + title: Biometric Attempt Limiting + rules: [] + status: pending + - id: ac-7.4 + title: Use of Alternate Authentication Factor + rules: [] + status: pending + - id: ac-8 + title: System Use Notification + levels: + - low + rules: + - dconf_gnome_banner_enabled + - dconf_gnome_login_banner_text + status: automated + - id: ac-9 + title: Previous Logon Notification + rules: [] + status: pending + - id: ac-9.1 + title: Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.2 + title: Successful and Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.3 + title: Notification of Account Changes + rules: [] + status: pending + - id: ac-9.4 + title: Additional Logon Information + rules: [] + status: pending + - id: ac-10 + title: Concurrent Session Control + levels: + - high + rules: [] + status: pending + - id: ac-11 + title: Device Lock + levels: + - moderate + rules: + - dconf_gnome_screensaver_idle_delay + - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_user_locks + - dconf_gnome_session_idle_user_locks + - var_screensaver_lock_delay=5_seconds + status: automated + - id: ac-11.1 + title: Pattern-hiding Displays + levels: + - moderate + rules: [] + status: pending + - id: ac-12 + title: Session Termination + levels: + - moderate + rules: [] + status: pending + - id: ac-12.1 + title: User-initiated Logouts + rules: [] + status: pending + - id: ac-12.2 + title: Termination Message + rules: [] + status: pending + - id: ac-12.3 + title: Timeout Warning Message + rules: [] + status: pending + - id: ac-13 + title: Supervision and Review — Access Control + rules: [] + status: pending + - id: ac-14 + title: Permitted Actions Without Identification or Authentication + levels: + - low + rules: [] + status: pending + - id: ac-14.1 + title: Necessary Uses + rules: [] + status: pending + - id: ac-15 + title: Automated Marking + rules: [] + status: pending + - id: ac-16 + title: Security and Privacy Attributes + rules: [] + status: pending + - id: ac-16.1 + title: Dynamic Attribute Association + rules: [] + status: pending + - id: ac-16.2 + title: Attribute Value Changes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.3 + title: Maintenance of Attribute Associations by System + rules: [] + status: pending + - id: ac-16.4 + title: Association of Attributes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.5 + title: Attribute Displays on Objects to Be Output + rules: [] + status: pending + - id: ac-16.6 + title: Maintenance of Attribute Association + rules: [] + status: pending + - id: ac-16.7 + title: Consistent Attribute Interpretation + rules: [] + status: pending + - id: ac-16.8 + title: Association Techniques and Technologies + rules: [] + status: pending + - id: ac-16.9 + title: Attribute Reassignment — Regrading Mechanisms + rules: [] + status: pending + - id: ac-16.10 + title: Attribute Configuration by Authorized Individuals + rules: [] + status: pending + - id: ac-17 + title: Remote Access + levels: + - low + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: ac-17.1 + title: Monitoring and Control + levels: + - moderate + rules: [] + status: pending + - id: ac-17.2 + title: Protection of Confidentiality and Integrity Using Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-17.3 + title: Managed Access Control Points + levels: + - moderate + rules: [] + status: pending + - id: ac-17.4 + title: Privileged Commands and Access + levels: + - moderate + rules: [] + status: pending + - id: ac-17.5 + title: Monitoring for Unauthorized Connections + rules: [] + status: pending + - id: ac-17.6 + title: Protection of Mechanism Information + rules: [] + status: pending + - id: ac-17.7 + title: Additional Protection for Security Function Access + rules: [] + status: pending + - id: ac-17.8 + title: Disable Nonsecure Network Protocols + rules: [] + status: pending + - id: ac-17.9 + title: Disconnect or Disable Access + rules: [] + status: pending + - id: ac-17.10 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: ac-18 + title: Wireless Access + levels: + - low + rules: + - wireless_disable_interfaces + status: automated + - id: ac-18.1 + title: Authentication and Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-18.2 + title: Monitoring Unauthorized Connections + rules: [] + status: pending + - id: ac-18.3 + title: Disable Wireless Networking + levels: + - moderate + rules: [] + status: pending + - id: ac-18.4 + title: Restrict Configurations by Users + levels: + - high + rules: [] + status: pending + - id: ac-18.5 + title: Antennas and Transmission Power Levels + levels: + - high + rules: [] + status: pending + - id: ac-19 + title: Access Control for Mobile Devices + levels: + - low + rules: [] + status: pending + - id: ac-19.1 + title: Use of Writable and Portable Storage Devices + rules: [] + status: pending + - id: ac-19.2 + title: Use of Personally Owned Portable Storage Devices + rules: [] + status: pending + - id: ac-19.3 + title: Use of Portable Storage Devices with No Identifiable Owner + rules: [] + status: pending + - id: ac-19.4 + title: Restrictions for Classified Information + rules: [] + status: pending + - id: ac-19.5 + title: Full Device or Container-based Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-20 + title: Use of External Systems + levels: + - low + rules: [] + status: pending + - id: ac-20.1 + title: Limits on Authorized Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.2 + title: Portable Storage Devices — Restricted Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.3 + title: Non-organizationally Owned Systems — Restricted Use + rules: [] + status: pending + - id: ac-20.4 + title: Network Accessible Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-20.5 + title: Portable Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-21 + title: Information Sharing + levels: + - moderate + rules: [] + status: pending + - id: ac-21.1 + title: Automated Decision Support + rules: [] + status: pending + - id: ac-21.2 + title: Information Search and Retrieval + rules: [] + status: pending + - id: ac-22 + title: Publicly Accessible Content + levels: + - low + rules: [] + status: pending + - id: ac-23 + title: Data Mining Protection + rules: [] + status: pending + - id: ac-24 + title: Access Control Decisions + rules: [] + status: pending + - id: ac-24.1 + title: Transmit Access Authorization Information + rules: [] + status: pending + - id: ac-24.2 + title: No User or Process Identity + rules: [] + status: pending + - id: ac-25 + title: Reference Monitor + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/at.yml b/products/rhel10/controls/nist_800_53/at.yml new file mode 100644 index 000000000000..80211cdb5591 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/at.yml @@ -0,0 +1,82 @@ +# NIST 800-53 AT Family: Awareness and Training +controls: + - id: at-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: at-2 + title: Literacy Training and Awareness + levels: + - low + rules: [] + status: pending + - id: at-2.1 + title: Practical Exercises + rules: [] + status: pending + - id: at-2.2 + title: Insider Threat + levels: + - low + rules: [] + status: pending + - id: at-2.3 + title: Social Engineering and Mining + levels: + - moderate + rules: [] + status: pending + - id: at-2.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-2.5 + title: Advanced Persistent Threat + rules: [] + status: pending + - id: at-2.6 + title: Cyber Threat Environment + rules: [] + status: pending + - id: at-3 + title: Role-based Training + levels: + - low + rules: [] + status: pending + - id: at-3.1 + title: Environmental Controls + rules: [] + status: pending + - id: at-3.2 + title: Physical Security Controls + rules: [] + status: pending + - id: at-3.3 + title: Practical Exercises + rules: [] + status: pending + - id: at-3.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-3.5 + title: Processing Personally Identifiable Information + rules: [] + status: pending + - id: at-4 + title: Training Records + levels: + - low + rules: [] + status: pending + - id: at-5 + title: Contacts with Security Groups and Associations + rules: [] + status: pending + - id: at-6 + title: Training Feedback + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/au.yml b/products/rhel10/controls/nist_800_53/au.yml new file mode 100644 index 000000000000..51ffe7e55e3e --- /dev/null +++ b/products/rhel10/controls/nist_800_53/au.yml @@ -0,0 +1,486 @@ +# NIST 800-53 AU Family: Audit and Accountability +controls: + - id: au-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: au-2 + title: Event Logging + levels: + - low + rules: + - aide_build_database + - aide_periodic_cron_checking + - audit_rules_execution_chacl + - audit_rules_execution_chcon + - audit_rules_execution_setfacl + - audit_rules_privileged_commands_usermod + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - auditd_data_retention_action_mail_acct + - auditd_data_retention_admin_space_left_action + - auditd_data_retention_space_left_action + - grub2_audit_backlog_limit_argument + - journald_disable_forward_to_syslog + - package_aide_installed + - package_audit-libs_installed + - package_audit_installed + - package_systemd-journal-remote_installed + - service_auditd_enabled + - service_systemd-journal-upload_enabled + - service_systemd-journald_enabled + - socket_systemd-journal-remote_disabled + - ensure_journald_and_rsyslog_not_active_together + - var_audit_backlog_limit=8192 + - var_auditd_action_mail_acct=root + - var_auditd_admin_space_left_action=cis_rhel10 + - var_auditd_space_left_action=cis_rhel10 + status: automated + - id: au-2.1 + title: Compilation of Audit Records from Multiple Sources + rules: [] + status: pending + - id: au-2.2 + title: Selection of Audit Events by Component + rules: [] + status: pending + - id: au-2.3 + title: Reviews and Updates + rules: [] + status: pending + - id: au-2.4 + title: Privileged Functions + rules: [] + status: pending + - id: au-3 + title: Content of Audit Records + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_mac_modification_etc_selinux + - audit_rules_mac_modification_usr_share + - audit_rules_networkconfig_modification_etc_hosts + - audit_rules_networkconfig_modification_etc_issue + - audit_rules_networkconfig_modification_etc_issue_net + - audit_rules_networkconfig_modification_etc_networkmanager_system_connections + - audit_rules_networkconfig_modification_etc_sysconfig_network + - audit_rules_networkconfig_modification_hostname_file + - audit_rules_networkconfig_modification_networkmanager + - audit_rules_networkconfig_modification_setdomainname + - audit_rules_networkconfig_modification_sethostname + - audit_rules_privileged_commands + - audit_rules_privileged_commands_kmod + - audit_rules_session_events_btmp + - audit_rules_session_events_utmp + - audit_rules_session_events_wtmp + - audit_rules_suid_auid_privilege_function + - audit_rules_sysadmin_actions + - audit_rules_time_adjtimex + - audit_rules_time_clock_settime + - audit_rules_time_settimeofday + - audit_rules_time_watch_localtime + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - chronyd_specify_remote_server + - directory_permissions_var_log_audit + - file_groupownership_audit_binaries + - file_ownership_var_log_audit_stig + - file_permissions_audit_binaries + - journald_storage + - sshd_set_loglevel_verbose + - sshd_set_max_auth_tries + - sudo_custom_logfile + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_default_log_martians + - chronyd_run_as_chrony_user + - sshd_max_auth_tries_value=4 + - var_multiple_time_servers=rhel + status: automated + - id: au-3.1 + title: Additional Audit Information + levels: + - moderate + rules: [] + status: pending + - id: au-3.2 + title: Centralized Management of Planned Audit Record Content + rules: [] + status: pending + - id: au-3.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: au-4 + title: Audit Log Storage Capacity + levels: + - low + rules: + - journald_compress + status: automated + - id: au-4.1 + title: Transfer to Alternate Storage + rules: [] + status: pending + - id: au-5 + title: Response to Audit Logging Process Failures + levels: + - low + rules: + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - var_auditd_disk_error_action=cis_rhel10 + - var_auditd_disk_full_action=cis_rhel10 + status: automated + - id: au-5.1 + title: Storage Capacity Warning + levels: + - high + rules: [] + status: pending + - id: au-5.2 + title: Real-time Alerts + levels: + - high + rules: [] + status: pending + - id: au-5.3 + title: Configurable Traffic Volume Thresholds + rules: [] + status: pending + - id: au-5.4 + title: Shutdown on Failure + rules: [] + status: pending + - id: au-5.5 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-6 + title: Audit Record Review, Analysis, and Reporting + levels: + - low + rules: [] + status: pending + - id: au-6.1 + title: Automated Process Integration + levels: + - moderate + rules: [] + status: pending + - id: au-6.2 + title: Automated Security Alerts + rules: [] + status: pending + - id: au-6.3 + title: Correlate Audit Record Repositories + levels: + - moderate + rules: [] + status: pending + - id: au-6.4 + title: Central Review and Analysis + rules: [] + status: pending + - id: au-6.5 + title: Integrated Analysis of Audit Records + levels: + - high + rules: [] + status: pending + - id: au-6.6 + title: Correlation with Physical Monitoring + levels: + - high + rules: [] + status: pending + - id: au-6.7 + title: Permitted Actions + rules: [] + status: pending + - id: au-6.8 + title: Full Text Analysis of Privileged Commands + rules: [] + status: pending + - id: au-6.9 + title: Correlation with Information from Nontechnical Sources + rules: [] + status: pending + - id: au-6.10 + title: Audit Level Adjustment + rules: [] + status: pending + - id: au-7 + title: Audit Record Reduction and Report Generation + levels: + - moderate + rules: [] + status: pending + - id: au-7.1 + title: Automatic Processing + levels: + - moderate + rules: [] + status: pending + - id: au-7.2 + title: Automatic Sort and Search + rules: [] + status: pending + - id: au-8 + title: Time Stamps + levels: + - low + rules: + - auditd_data_retention_max_log_file + - auditd_data_retention_max_log_file_action + - var_auditd_max_log_file=8 + - var_auditd_max_log_file_action=keep_logs + status: automated + - id: au-8.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: au-8.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: au-9 + title: Protection of Audit Information + levels: + - low + rules: + - audit_rules_immutable + - file_groupownership_audit_configuration + - file_ownership_audit_binaries + - file_ownership_audit_configuration + status: automated + - id: au-9.1 + title: Hardware Write-once Media + rules: [] + status: pending + - id: au-9.2 + title: Store on Separate Physical Systems or Components + levels: + - high + rules: [] + status: pending + - id: au-9.3 + title: Cryptographic Protection + levels: + - high + rules: + - aide_check_audit_tools + status: automated + - id: au-9.4 + title: Access by Subset of Privileged Users + levels: + - moderate + rules: + - file_group_ownership_var_log_audit + - file_permissions_var_log_audit + status: automated + - id: au-9.5 + title: Dual Authorization + rules: [] + status: pending + - id: au-9.6 + title: Read-only Access + rules: [] + status: pending + - id: au-9.7 + title: Store on Component with Different Operating System + rules: [] + status: pending + - id: au-10 + title: Non-repudiation + levels: + - high + rules: [] + status: pending + - id: au-10.1 + title: Association of Identities + rules: [] + status: pending + - id: au-10.2 + title: Validate Binding of Information Producer Identity + rules: [] + status: pending + - id: au-10.3 + title: Chain of Custody + rules: [] + status: pending + - id: au-10.4 + title: Validate Binding of Information Reviewer Identity + rules: [] + status: pending + - id: au-10.5 + title: Digital Signatures + rules: [] + status: pending + - id: au-11 + title: Audit Record Retention + levels: + - low + rules: [] + status: pending + - id: au-11.1 + title: Long-term Retrieval Capability + rules: [] + status: pending + - id: au-12 + title: Audit Record Generation + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchmodat2 + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_continue_loading + - audit_rules_execution_chcon + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_renameat2 + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_unlinkat + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_media_export + - audit_rules_privileged_commands_kmod + - audit_rules_privileged_commands_usermod + - audit_rules_sysadmin_actions + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - audit_sudo_log_events + - file_permissions_audit_configuration + - grub2_audit_argument + - service_auditd_enabled + status: automated + - id: au-12.1 + title: System-wide and Time-correlated Audit Trail + levels: + - high + rules: [] + status: pending + - id: au-12.2 + title: Standardized Formats + rules: [] + status: pending + - id: au-12.3 + title: Changes by Authorized Individuals + levels: + - high + rules: [] + status: pending + - id: au-12.4 + title: Query Parameter Audits of Personally Identifiable Information + rules: [] + status: pending + - id: au-13 + title: Monitoring for Information Disclosure + rules: [] + status: pending + - id: au-13.1 + title: Use of Automated Tools + rules: [] + status: pending + - id: au-13.2 + title: Review of Monitored Sites + rules: [] + status: pending + - id: au-13.3 + title: Unauthorized Replication of Information + rules: [] + status: pending + - id: au-14 + title: Session Audit + rules: [] + status: pending + - id: au-14.1 + title: System Start-up + rules: [] + status: pending + - id: au-14.2 + title: Capture and Record Content + rules: [] + status: pending + - id: au-14.3 + title: Remote Viewing and Listening + rules: [] + status: pending + - id: au-15 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-16 + title: Cross-organizational Audit Logging + rules: [] + status: pending + - id: au-16.1 + title: Identity Preservation + rules: [] + status: pending + - id: au-16.2 + title: Sharing of Audit Information + rules: [] + status: pending + - id: au-16.3 + title: Disassociability + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/ca.yml b/products/rhel10/controls/nist_800_53/ca.yml new file mode 100644 index 000000000000..35a07ac6ba5f --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ca.yml @@ -0,0 +1,161 @@ +# NIST 800-53 CA Family: Assessment, Authorization, and Monitoring +controls: + - id: ca-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ca-2 + title: Control Assessments + levels: + - low + rules: [] + status: pending + - id: ca-2.1 + title: Independent Assessors + levels: + - moderate + rules: [] + status: pending + - id: ca-2.2 + title: Specialized Assessments + levels: + - high + rules: [] + status: pending + - id: ca-2.3 + title: Leveraging Results from External Organizations + rules: [] + status: pending + - id: ca-3 + title: Information Exchange + levels: + - low + rules: [] + status: pending + - id: ca-3.1 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: ca-3.2 + title: Classified National Security System Connections + rules: [] + status: pending + - id: ca-3.3 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: ca-3.4 + title: Connections to Public Networks + rules: [] + status: pending + - id: ca-3.5 + title: Restrictions on External System Connections + rules: [] + status: pending + - id: ca-3.6 + title: Transfer Authorizations + levels: + - high + rules: [] + status: pending + - id: ca-3.7 + title: Transitive Information Exchanges + rules: [] + status: pending + - id: ca-4 + title: Security Certification + rules: [] + status: pending + - id: ca-5 + title: Plan of Action and Milestones + levels: + - low + rules: [] + status: pending + - id: ca-5.1 + title: Automation Support for Accuracy and Currency + rules: [] + status: pending + - id: ca-6 + title: Authorization + levels: + - low + rules: [] + status: pending + - id: ca-6.1 + title: Joint Authorization — Intra-organization + rules: [] + status: pending + - id: ca-6.2 + title: Joint Authorization — Inter-organization + rules: [] + status: pending + - id: ca-7 + title: Continuous Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.1 + title: Independent Assessment + levels: + - moderate + rules: [] + status: pending + - id: ca-7.2 + title: Types of Assessments + rules: [] + status: pending + - id: ca-7.3 + title: Trend Analyses + rules: [] + status: pending + - id: ca-7.4 + title: Risk Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.5 + title: Consistency Analysis + rules: [] + status: pending + - id: ca-7.6 + title: Automation Support for Monitoring + rules: [] + status: pending + - id: ca-8 + title: Penetration Testing + levels: + - high + rules: [] + status: pending + - id: ca-8.1 + title: Independent Penetration Testing Agent or Team + levels: + - high + rules: [] + status: pending + - id: ca-8.2 + title: Red Team Exercises + rules: [] + status: pending + - id: ca-8.3 + title: Facility Penetration Testing + rules: [] + status: pending + - id: ca-9 + title: Internal System Connections + levels: + - low + rules: + - firewalld-backend + - firewalld_loopback_traffic_trusted + - package_firewalld_installed + status: automated + - id: ca-9.1 + title: Compliance Checks + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/cm.yml b/products/rhel10/controls/nist_800_53/cm.yml new file mode 100644 index 000000000000..d43e634aaa4b --- /dev/null +++ b/products/rhel10/controls/nist_800_53/cm.yml @@ -0,0 +1,549 @@ +# NIST 800-53 CM Family: Configuration Management +controls: + - id: cm-1 + title: Policy and Procedures + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - account_unique_id + - account_unique_name + - accounts_maximum_age_login_defs + - accounts_no_uid_except_zero + - accounts_password_set_max_life_existing + - accounts_root_gid_zero + - accounts_root_path_dirs_no_write + - accounts_user_dot_group_ownership + - accounts_user_dot_user_ownership + - configure_custom_crypto_policy_cis + - disable_host_auth + - file_permission_user_bash_history + - file_permission_user_init_files + - gid_passwd_group_same + - group_unique_id + - group_unique_name + - groups_no_zero_gid_except_root + - no_forward_files + - no_netrc_files + - no_nologin_in_shells + - no_rhost_files + - package_cron_installed + - root_path_no_dot + - service_crond_enabled + - sshd_disable_empty_passwords + - sshd_disable_gssapi_auth + - sshd_disable_rhosts + - sshd_do_not_permit_user_env + - sshd_enable_pam + - sshd_enable_warning_banner_net + - sshd_set_idle_timeout + - sshd_set_keepalive + - sshd_set_max_sessions + - sshd_set_maxstartups + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv4_tcp_syncookies + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sshd_idle_timeout_value=5_minutes + - sysctl_net_ipv4_tcp_syncookies_value=enabled + - var_accounts_maximum_age_login_defs=365 + - var_sshd_max_sessions=10 + - var_sshd_set_keepalive=1 + - var_sshd_set_maxstartups=10:30:60 + - var_user_initialization_files_regex=all_dotfiles + status: automated + - id: cm-2 + title: Baseline Configuration + levels: + - low + rules: [] + status: pending + - id: cm-2.1 + title: Reviews and Updates + rules: [] + status: pending + - id: cm-2.2 + title: Automation Support for Accuracy and Currency + levels: + - moderate + rules: [] + status: pending + - id: cm-2.3 + title: Retention of Previous Configurations + levels: + - moderate + rules: [] + status: pending + - id: cm-2.4 + title: Unauthorized Software + rules: [] + status: pending + - id: cm-2.5 + title: Authorized Software + rules: [] + status: pending + - id: cm-2.6 + title: Development and Test Environments + rules: [] + status: pending + - id: cm-2.7 + title: Configure Systems and Components for High-risk Areas + levels: + - moderate + rules: [] + status: pending + - id: cm-3 + title: Configuration Change Control + levels: + - moderate + rules: [] + status: pending + - id: cm-3.1 + title: Automated Documentation, Notification, and Prohibition of Changes + levels: + - high + rules: [] + status: pending + - id: cm-3.2 + title: Testing, Validation, and Documentation of Changes + levels: + - moderate + rules: [] + status: pending + - id: cm-3.3 + title: Automated Change Implementation + rules: [] + status: pending + - id: cm-3.4 + title: Security and Privacy Representatives + levels: + - moderate + rules: [] + status: pending + - id: cm-3.5 + title: Automated Security Response + rules: [] + status: pending + - id: cm-3.6 + title: Cryptography Management + levels: + - high + rules: [] + status: pending + - id: cm-3.7 + title: Review System Changes + rules: [] + status: pending + - id: cm-3.8 + title: Prevent or Restrict Configuration Changes + rules: [] + status: pending + - id: cm-4 + title: Impact Analyses + levels: + - low + rules: [] + status: pending + - id: cm-4.1 + title: Separate Test Environments + levels: + - high + rules: [] + status: pending + - id: cm-4.2 + title: Verification of Controls + levels: + - moderate + rules: [] + status: pending + - id: cm-5 + title: Access Restrictions for Change + levels: + - low + rules: [] + status: pending + - id: cm-5.1 + title: Automated Access Enforcement and Audit Records + levels: + - high + rules: [] + status: pending + - id: cm-5.2 + title: Review System Changes + rules: [] + status: pending + - id: cm-5.3 + title: Signed Components + rules: [] + status: pending + - id: cm-5.4 + title: Dual Authorization + rules: [] + status: pending + - id: cm-5.5 + title: Privilege Limitation for Production and Operation + rules: [] + status: pending + - id: cm-5.6 + title: Limit Library Privileges + rules: [] + status: pending + - id: cm-5.7 + title: Automatic Implementation of Security Safeguards + rules: [] + status: pending + - id: cm-6 + title: Configuration Settings + levels: + - low + rules: + - accounts_password_pam_pwquality_password_auth + - accounts_password_pam_pwquality_system_auth + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_user_interactive_home_directory_exists + - audit_rules_media_export + - banner_etc_issue_cis + - banner_etc_issue_net_cis + - banner_etc_motd_cis + - coredump_disable_backtraces + - coredump_disable_storage + - dconf_db_up_to_date + - dconf_gnome_disable_user_list + - disable_host_auth + - disable_users_coredumps + - file_groupowner_boot_grub2 + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_boot_grub2 + - file_ownership_home_directories + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_boot_grub2 + - file_permissions_home_directories + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - no_empty_passwords + - no_empty_passwords_etc_shadow + - no_files_or_dirs_ungroupowned + - no_files_or_dirs_unowned_by_user + - package_pam_pwquality_installed + - package_rsync_removed + - package_samba_removed + - package_squid_removed + - partition_for_tmp + - partition_for_var_log + - service_nfs_disabled + - service_rpcbind_disabled + - sshd_disable_gssapi_auth + - sshd_set_login_grace_time + - sysctl_fs_suid_dumpable + - sysctl_kernel_kptr_restrict + - sysctl_kernel_randomize_va_space + - sysctl_kernel_yama_ptrace_scope + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_forwarding + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_forwarding + - sysctl_net_ipv4_conf_default_log_martians + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sysctl_net_ipv6_conf_default_forwarding + - cis_banner_text=cis + - dconf_login_banner_contents=cis_default + - dconf_login_banner_text=cis_banners + - sysctl_net_ipv4_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_all_log_martians_value=enabled + - sysctl_net_ipv4_conf_all_rp_filter_value=enabled + - sysctl_net_ipv4_conf_all_secure_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_default_forwarding_value=disabled + - sysctl_net_ipv4_conf_default_log_martians_value=enabled + - sysctl_net_ipv4_conf_default_rp_filter_value=enabled + - sysctl_net_ipv4_conf_default_secure_redirects_value=disabled + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled + - sysctl_net_ipv6_conf_all_accept_ra_value=disabled + - sysctl_net_ipv6_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_all_forwarding_value=disabled + - sysctl_net_ipv6_conf_default_accept_ra_value=disabled + - sysctl_net_ipv6_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_default_forwarding_value=disabled + - var_accounts_user_umask=027 + - var_sshd_set_login_grace_time=60 + status: automated + - id: cm-6.1 + title: Automated Management, Application, and Verification + levels: + - high + rules: [] + status: pending + - id: cm-6.2 + title: Respond to Unauthorized Changes + levels: + - high + rules: [] + status: pending + - id: cm-6.3 + title: Unauthorized Change Detection + rules: [] + status: pending + - id: cm-6.4 + title: Conformance Demonstration + rules: [] + status: pending + - id: cm-7 + title: Least Functionality + levels: + - low + rules: + - dconf_gnome_disable_autorun + - disable_weak_deps + - file_ownership_var_log_audit_stig + - has_nonlocal_mta + - kernel_module_atm_disabled + - kernel_module_can_disabled + - kernel_module_cramfs_disabled + - kernel_module_dccp_disabled + - kernel_module_firewire-core_disabled + - kernel_module_freevxfs_disabled + - kernel_module_hfs_disabled + - kernel_module_hfsplus_disabled + - kernel_module_jffs2_disabled + - kernel_module_overlayfs_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_squashfs_disabled + - kernel_module_tipc_disabled + - kernel_module_udf_disabled + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_tmp_nodev + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - package_bind_removed + - package_cyrus-imapd_removed + - package_dovecot_removed + - package_ftp_removed + - package_gdm_removed + - package_httpd_removed + - package_kea_removed + - package_net-snmp_removed + - package_nginx_removed + - package_openldap-clients_removed + - package_postfix_installed + - package_sequoia-sq_installed + - package_telnet-server_removed + - package_telnet_removed + - package_tftp-server_removed + - package_tftp_removed + - package_vsftpd_removed + - partition_for_dev_shm + - partition_for_home + - partition_for_tmp + - partition_for_var + - partition_for_var_log + - partition_for_var_log_audit + - partition_for_var_tmp + - postfix_network_listening_disabled + - service_bluetooth_disabled + - service_cockpit_disabled + - service_cups_disabled + - service_dnsmasq_disabled + - sshd_disable_forwarding + - wireless_disable_interfaces + - xwayland_disabled + - var_postfix_inet_interfaces=loopback-only + status: automated + - id: cm-7.1 + title: Periodic Review + levels: + - moderate + rules: [] + status: pending + - id: cm-7.2 + title: Prevent Program Execution + levels: + - moderate + rules: [] + status: pending + - id: cm-7.3 + title: Registration Compliance + rules: [] + status: pending + - id: cm-7.4 + title: Unauthorized Software — Deny-by-exception + rules: [] + status: pending + - id: cm-7.5 + title: Authorized Software — Allow-by-exception + levels: + - moderate + rules: [] + status: pending + - id: cm-7.6 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: cm-7.7 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: cm-7.8 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: cm-7.9 + title: Prohibiting The Use of Unauthorized Hardware + rules: [] + status: pending + - id: cm-8 + title: System Component Inventory + levels: + - low + rules: [] + status: pending + - id: cm-8.1 + title: Updates During Installation and Removal + levels: + - moderate + rules: [] + status: pending + - id: cm-8.2 + title: Automated Maintenance + levels: + - high + rules: [] + status: pending + - id: cm-8.3 + title: Automated Unauthorized Component Detection + levels: + - moderate + rules: [] + status: pending + - id: cm-8.4 + title: Accountability Information + levels: + - high + rules: [] + status: pending + - id: cm-8.5 + title: No Duplicate Accounting of Components + rules: [] + status: pending + - id: cm-8.6 + title: Assessed Configurations and Approved Deviations + rules: [] + status: pending + - id: cm-8.7 + title: Centralized Repository + rules: [] + status: pending + - id: cm-8.8 + title: Automated Location Tracking + rules: [] + status: pending + - id: cm-8.9 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: cm-9 + title: Configuration Management Plan + levels: + - moderate + rules: [] + status: pending + - id: cm-9.1 + title: Assignment of Responsibility + rules: [] + status: pending + - id: cm-10 + title: Software Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: cm-10.1 + title: Open-source Software + rules: [] + status: pending + - id: cm-11 + title: User-installed Software + levels: + - low + rules: + - package_xorg-x11-server-Xwayland_removed + status: automated + - id: cm-11.1 + title: Alerts for Unauthorized Installations + rules: [] + status: pending + - id: cm-11.2 + title: Software Installation with Privileged Status + rules: [] + status: pending + - id: cm-11.3 + title: Automated Enforcement and Monitoring + rules: [] + status: pending + - id: cm-12 + title: Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-12.1 + title: Automated Tools to Support Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-13 + title: Data Action Mapping + rules: [] + status: pending + - id: cm-14 + title: Signed Components + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/cp.yml b/products/rhel10/controls/nist_800_53/cp.yml new file mode 100644 index 000000000000..53d97fb34990 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/cp.yml @@ -0,0 +1,296 @@ +# NIST 800-53 CP Family: Contingency Planning +controls: + - id: cp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: cp-2 + title: Contingency Plan + levels: + - low + rules: [] + status: pending + - id: cp-2.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-2.2 + title: Capacity Planning + levels: + - high + rules: [] + status: pending + - id: cp-2.3 + title: Resume Mission and Business Functions + levels: + - moderate + rules: [] + status: pending + - id: cp-2.4 + title: Resume All Mission and Business Functions + rules: [] + status: pending + - id: cp-2.5 + title: Continue Mission and Business Functions + levels: + - high + rules: [] + status: pending + - id: cp-2.6 + title: Alternate Processing and Storage Sites + rules: [] + status: pending + - id: cp-2.7 + title: Coordinate with External Service Providers + rules: [] + status: pending + - id: cp-2.8 + title: Identify Critical Assets + levels: + - moderate + rules: [] + status: pending + - id: cp-3 + title: Contingency Training + levels: + - low + rules: [] + status: pending + - id: cp-3.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: cp-3.2 + title: Mechanisms Used in Training Environments + rules: [] + status: pending + - id: cp-4 + title: Contingency Plan Testing + levels: + - low + rules: [] + status: pending + - id: cp-4.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-4.2 + title: Alternate Processing Site + levels: + - high + rules: [] + status: pending + - id: cp-4.3 + title: Automated Testing + rules: [] + status: pending + - id: cp-4.4 + title: Full Recovery and Reconstitution + rules: [] + status: pending + - id: cp-4.5 + title: Self-challenge + rules: [] + status: pending + - id: cp-5 + title: Contingency Plan Update + rules: [] + status: pending + - id: cp-6 + title: Alternate Storage Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.2 + title: Recovery Time and Recovery Point Objectives + levels: + - high + rules: [] + status: pending + - id: cp-6.3 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7 + title: Alternate Processing Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.2 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7.3 + title: Priority of Service + levels: + - moderate + rules: [] + status: pending + - id: cp-7.4 + title: Preparation for Use + levels: + - high + rules: [] + status: pending + - id: cp-7.5 + title: Equivalent Information Security Safeguards + rules: [] + status: pending + - id: cp-7.6 + title: Inability to Return to Primary Site + rules: [] + status: pending + - id: cp-8 + title: Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: cp-8.1 + title: Priority of Service Provisions + levels: + - moderate + rules: [] + status: pending + - id: cp-8.2 + title: Single Points of Failure + levels: + - moderate + rules: [] + status: pending + - id: cp-8.3 + title: Separation of Primary and Alternate Providers + levels: + - high + rules: [] + status: pending + - id: cp-8.4 + title: Provider Contingency Plan + levels: + - high + rules: [] + status: pending + - id: cp-8.5 + title: Alternate Telecommunication Service Testing + rules: [] + status: pending + - id: cp-9 + title: System Backup + levels: + - low + rules: [] + status: pending + - id: cp-9.1 + title: Testing for Reliability and Integrity + levels: + - moderate + rules: [] + status: pending + - id: cp-9.2 + title: Test Restoration Using Sampling + levels: + - high + rules: [] + status: pending + - id: cp-9.3 + title: Separate Storage for Critical Information + levels: + - high + rules: [] + status: pending + - id: cp-9.4 + title: Protection from Unauthorized Modification + rules: [] + status: pending + - id: cp-9.5 + title: Transfer to Alternate Storage Site + levels: + - high + rules: [] + status: pending + - id: cp-9.6 + title: Redundant Secondary System + rules: [] + status: pending + - id: cp-9.7 + title: Dual Authorization for Deletion or Destruction + rules: [] + status: pending + - id: cp-9.8 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: cp-10 + title: System Recovery and Reconstitution + levels: + - low + rules: [] + status: pending + - id: cp-10.1 + title: Contingency Plan Testing + rules: [] + status: pending + - id: cp-10.2 + title: Transaction Recovery + levels: + - moderate + rules: [] + status: pending + - id: cp-10.3 + title: Compensating Security Controls + rules: [] + status: pending + - id: cp-10.4 + title: Restore Within Time Period + levels: + - high + rules: [] + status: pending + - id: cp-10.5 + title: Failover Capability + rules: [] + status: pending + - id: cp-10.6 + title: Component Protection + rules: [] + status: pending + - id: cp-11 + title: Alternate Communications Protocols + rules: [] + status: pending + - id: cp-12 + title: Safe Mode + rules: [] + status: pending + - id: cp-13 + title: Alternative Security Mechanisms + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/ia.yml b/products/rhel10/controls/nist_800_53/ia.yml new file mode 100644 index 000000000000..25435cbd93b5 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ia.yml @@ -0,0 +1,397 @@ +# NIST 800-53 IA Family: Identification and Authentication +controls: + - id: ia-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ia-2 + title: Identification and Authentication (Organizational Users) + levels: + - low + rules: + - account_unique_id + status: automated + - id: ia-2.1 + title: Multi-factor Authentication to Privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.2 + title: Multi-factor Authentication to Non-privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.3 + title: Local Access to Privileged Accounts + rules: [] + status: pending + - id: ia-2.4 + title: Local Access to Non-privileged Accounts + rules: [] + status: pending + - id: ia-2.5 + title: Individual Authentication with Group Authentication + levels: + - high + rules: [] + status: pending + - id: ia-2.6 + title: Access to Accounts —separate Device + rules: [] + status: pending + - id: ia-2.7 + title: Network Access to Non-privileged Accounts — Separate Device + rules: [] + status: pending + - id: ia-2.8 + title: Access to Accounts — Replay Resistant + levels: + - low + rules: [] + status: pending + - id: ia-2.9 + title: Network Access to Non-privileged Accounts — Replay Resistant + rules: [] + status: pending + - id: ia-2.10 + title: Single Sign-on + rules: [] + status: pending + - id: ia-2.11 + title: Remote Access — Separate Device + rules: [] + status: pending + - id: ia-2.12 + title: Acceptance of PIV Credentials + levels: + - low + rules: [] + status: pending + - id: ia-2.13 + title: Out-of-band Authentication + rules: [] + status: pending + - id: ia-3 + title: Device Identification and Authentication + levels: + - moderate + rules: + - dconf_gnome_disable_automount + - dconf_gnome_disable_automount_open + - kernel_module_usb-storage_disabled + status: automated + - id: ia-3.1 + title: Cryptographic Bidirectional Authentication + rules: [] + status: pending + - id: ia-3.2 + title: Cryptographic Bidirectional Network Authentication + rules: [] + status: pending + - id: ia-3.3 + title: Dynamic Address Allocation + rules: [] + status: pending + - id: ia-3.4 + title: Device Attestation + rules: [] + status: pending + - id: ia-4 + title: Identifier Management + levels: + - low + rules: + - account_disable_post_pw_expiration + - accounts_set_post_pw_existing + - var_account_disable_post_pw_expiration=45 + status: automated + - id: ia-4.1 + title: Prohibit Account Identifiers as Public Identifiers + rules: [] + status: pending + - id: ia-4.2 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-4.3 + title: Multiple Forms of Certification + rules: [] + status: pending + - id: ia-4.4 + title: Identify User Status + levels: + - moderate + rules: [] + status: pending + - id: ia-4.5 + title: Dynamic Management + rules: [] + status: pending + - id: ia-4.6 + title: Cross-organization Management + rules: [] + status: pending + - id: ia-4.7 + title: In-person Registration + rules: [] + status: pending + - id: ia-4.8 + title: Pairwise Pseudonymous Identifiers + rules: [] + status: pending + - id: ia-4.9 + title: Attribute Maintenance and Protection + rules: [] + status: pending + - id: ia-5 + title: Authenticator Management + levels: + - low + rules: + - accounts_minimum_age_login_defs + - accounts_password_all_shadowed + - accounts_password_last_change_is_in_past + - accounts_password_pam_dictcheck + - accounts_password_pam_difok + - accounts_password_pam_enforce_root + - accounts_password_pam_maxrepeat + - accounts_password_pam_maxsequence + - accounts_password_pam_minclass + - accounts_password_pam_minlen + - accounts_password_pam_modules_in_authselect_profile + - accounts_password_pam_pwhistory_enforce_for_root + - accounts_password_pam_pwhistory_use_authtok + - accounts_password_pam_unix_authtok + - accounts_password_set_min_life_existing + - accounts_password_set_warn_age_existing + - accounts_password_warn_age_login_defs + - ensure_root_password_configured + - no_empty_passwords_etc_shadow + - set_password_hashing_algorithm_logindefs + - set_password_hashing_algorithm_passwordauth + - set_password_hashing_algorithm_systemauth + - var_accounts_minimum_age_login_defs=1 + - var_accounts_password_warn_age_login_defs=7 + - var_password_hashing_algorithm=cis_rhel10 + - var_password_hashing_algorithm_pam=cis_rhel10 + - var_password_pam_dictcheck=1 + - var_password_pam_difok=2 + - var_password_pam_maxrepeat=3 + - var_password_pam_maxsequence=3 + - var_password_pam_minclass=4 + - var_password_pam_minlen=14 + status: automated + - id: ia-5.1 + title: Password-based Authentication + levels: + - low + rules: + - accounts_password_pam_pwhistory_remember_password_auth + - accounts_password_pam_pwhistory_remember_system_auth + - accounts_password_pam_unix_enabled + - accounts_password_pam_unix_no_remember + - var_password_pam_remember=24 + - var_password_pam_remember_control_flag=requisite_or_required + status: automated + - id: ia-5.2 + title: Public Key-based Authentication + levels: + - moderate + rules: [] + status: pending + - id: ia-5.3 + title: In-person or Trusted External Party Registration + rules: [] + status: pending + - id: ia-5.4 + title: Automated Support for Password Strength Determination + rules: [] + status: pending + - id: ia-5.5 + title: Change Authenticators Prior to Delivery + rules: [] + status: pending + - id: ia-5.6 + title: Protection of Authenticators + levels: + - moderate + rules: [] + status: pending + - id: ia-5.7 + title: No Embedded Unencrypted Static Authenticators + rules: [] + status: pending + - id: ia-5.8 + title: Multiple System Accounts + rules: [] + status: pending + - id: ia-5.9 + title: Federated Credential Management + rules: [] + status: pending + - id: ia-5.10 + title: Dynamic Credential Binding + rules: [] + status: pending + - id: ia-5.11 + title: Hardware Token-based Authentication + rules: [] + status: pending + - id: ia-5.12 + title: Biometric Authentication Performance + rules: [] + status: pending + - id: ia-5.13 + title: Expiration of Cached Authenticators + rules: [] + status: pending + - id: ia-5.14 + title: Managing Content of PKI Trust Stores + rules: [] + status: pending + - id: ia-5.15 + title: GSA-approved Products and Services + rules: [] + status: pending + - id: ia-5.16 + title: In-person or Trusted External Party Authenticator Issuance + rules: [] + status: pending + - id: ia-5.17 + title: Presentation Attack Detection for Biometric Authenticators + rules: [] + status: pending + - id: ia-5.18 + title: Password Managers + rules: [] + status: pending + - id: ia-6 + title: Authentication Feedback + levels: + - low + rules: [] + status: pending + - id: ia-7 + title: Cryptographic Module Authentication + levels: + - low + rules: [] + status: pending + - id: ia-8 + title: Identification and Authentication (Non-organizational Users) + levels: + - low + rules: [] + status: pending + - id: ia-8.1 + title: Acceptance of PIV Credentials from Other Agencies + levels: + - low + rules: [] + status: pending + - id: ia-8.2 + title: Acceptance of External Authenticators + levels: + - low + rules: [] + status: pending + - id: ia-8.3 + title: Use of FICAM-approved Products + rules: [] + status: pending + - id: ia-8.4 + title: Use of Defined Profiles + levels: + - low + rules: [] + status: pending + - id: ia-8.5 + title: Acceptance of PIV-I Credentials + rules: [] + status: pending + - id: ia-8.6 + title: Disassociability + rules: [] + status: pending + - id: ia-9 + title: Service Identification and Authentication + rules: [] + status: pending + - id: ia-9.1 + title: Information Exchange + rules: [] + status: pending + - id: ia-9.2 + title: Transmission of Decisions + rules: [] + status: pending + - id: ia-10 + title: Adaptive Authentication + rules: [] + status: pending + - id: ia-11 + title: Re-authentication + levels: + - low + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=15_minutes + status: automated + - id: ia-12 + title: Identity Proofing + levels: + - moderate + rules: [] + status: pending + - id: ia-12.1 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-12.2 + title: Identity Evidence + levels: + - moderate + rules: [] + status: pending + - id: ia-12.3 + title: Identity Evidence Validation and Verification + levels: + - moderate + rules: [] + status: pending + - id: ia-12.4 + title: In-person Validation and Verification + levels: + - high + rules: [] + status: pending + - id: ia-12.5 + title: Address Confirmation + levels: + - moderate + rules: [] + status: pending + - id: ia-12.6 + title: Accept Externally-proofed Identities + rules: [] + status: pending + - id: ia-13 + title: Identity Providers and Authorization Servers + rules: [] + status: pending + - id: ia-13.1 + title: Protection of Cryptographic Keys + rules: [] + status: pending + - id: ia-13.2 + title: Verification of Identity Assertions and Access Tokens + rules: [] + status: pending + - id: ia-13.3 + title: Token Management + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/ir.yml b/products/rhel10/controls/nist_800_53/ir.yml new file mode 100644 index 000000000000..2d443099c957 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ir.yml @@ -0,0 +1,206 @@ +# NIST 800-53 IR Family: Incident Response +controls: + - id: ir-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ir-2 + title: Incident Response Training + levels: + - low + rules: [] + status: pending + - id: ir-2.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: ir-2.2 + title: Automated Training Environments + levels: + - high + rules: [] + status: pending + - id: ir-2.3 + title: Breach + rules: [] + status: pending + - id: ir-3 + title: Incident Response Testing + levels: + - moderate + rules: [] + status: pending + - id: ir-3.1 + title: Automated Testing + rules: [] + status: pending + - id: ir-3.2 + title: Coordination with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: ir-3.3 + title: Continuous Improvement + rules: [] + status: pending + - id: ir-4 + title: Incident Handling + levels: + - low + rules: [] + status: pending + - id: ir-4.1 + title: Automated Incident Handling Processes + levels: + - moderate + rules: [] + status: pending + - id: ir-4.2 + title: Dynamic Reconfiguration + rules: [] + status: pending + - id: ir-4.3 + title: Continuity of Operations + rules: [] + status: pending + - id: ir-4.4 + title: Information Correlation + levels: + - high + rules: [] + status: pending + - id: ir-4.5 + title: Automatic Disabling of System + rules: [] + status: pending + - id: ir-4.6 + title: Insider Threats + rules: [] + status: pending + - id: ir-4.7 + title: Insider Threats — Intra-organization Coordination + rules: [] + status: pending + - id: ir-4.8 + title: Correlation with External Organizations + rules: [] + status: pending + - id: ir-4.9 + title: Dynamic Response Capability + rules: [] + status: pending + - id: ir-4.10 + title: Supply Chain Coordination + rules: [] + status: pending + - id: ir-4.11 + title: Integrated Incident Response Team + levels: + - high + rules: [] + status: pending + - id: ir-4.12 + title: Malicious Code and Forensic Analysis + rules: [] + status: pending + - id: ir-4.13 + title: Behavior Analysis + rules: [] + status: pending + - id: ir-4.14 + title: Security Operations Center + rules: [] + status: pending + - id: ir-4.15 + title: Public Relations and Reputation Repair + rules: [] + status: pending + - id: ir-5 + title: Incident Monitoring + levels: + - low + rules: [] + status: pending + - id: ir-5.1 + title: Automated Tracking, Data Collection, and Analysis + levels: + - high + rules: [] + status: pending + - id: ir-6 + title: Incident Reporting + levels: + - low + rules: [] + status: pending + - id: ir-6.1 + title: Automated Reporting + levels: + - moderate + rules: [] + status: pending + - id: ir-6.2 + title: Vulnerabilities Related to Incidents + rules: [] + status: pending + - id: ir-6.3 + title: Supply Chain Coordination + levels: + - moderate + rules: [] + status: pending + - id: ir-7 + title: Incident Response Assistance + levels: + - low + rules: [] + status: pending + - id: ir-7.1 + title: Automation Support for Availability of Information and Support + levels: + - moderate + rules: [] + status: pending + - id: ir-7.2 + title: Coordination with External Providers + rules: [] + status: pending + - id: ir-8 + title: Incident Response Plan + levels: + - low + rules: [] + status: pending + - id: ir-8.1 + title: Breaches + rules: [] + status: pending + - id: ir-9 + title: Information Spillage Response + rules: [] + status: pending + - id: ir-9.1 + title: Responsible Personnel + rules: [] + status: pending + - id: ir-9.2 + title: Training + rules: [] + status: pending + - id: ir-9.3 + title: Post-spill Operations + rules: [] + status: pending + - id: ir-9.4 + title: Exposure to Unauthorized Personnel + rules: [] + status: pending + - id: ir-10 + title: Integrated Information Security Analysis Team + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/ma.yml b/products/rhel10/controls/nist_800_53/ma.yml new file mode 100644 index 000000000000..77bd02932613 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ma.yml @@ -0,0 +1,146 @@ +# NIST 800-53 MA Family: Maintenance +controls: + - id: ma-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ma-2 + title: Controlled Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-2.1 + title: Record Content + rules: [] + status: pending + - id: ma-2.2 + title: Automated Maintenance Activities + levels: + - high + rules: [] + status: pending + - id: ma-3 + title: Maintenance Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.1 + title: Inspect Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.2 + title: Inspect Media + levels: + - moderate + rules: [] + status: pending + - id: ma-3.3 + title: Prevent Unauthorized Removal + levels: + - moderate + rules: [] + status: pending + - id: ma-3.4 + title: Restricted Tool Use + rules: [] + status: pending + - id: ma-3.5 + title: Execution with Privilege + rules: [] + status: pending + - id: ma-3.6 + title: Software Updates and Patches + rules: [] + status: pending + - id: ma-4 + title: Nonlocal Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-4.1 + title: Logging and Review + rules: [] + status: pending + - id: ma-4.2 + title: Document Nonlocal Maintenance + rules: [] + status: pending + - id: ma-4.3 + title: Comparable Security and Sanitization + levels: + - high + rules: [] + status: pending + - id: ma-4.4 + title: Authentication and Separation of Maintenance Sessions + rules: [] + status: pending + - id: ma-4.5 + title: Approvals and Notifications + rules: [] + status: pending + - id: ma-4.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: ma-4.7 + title: Disconnect Verification + rules: [] + status: pending + - id: ma-5 + title: Maintenance Personnel + levels: + - low + rules: [] + status: pending + - id: ma-5.1 + title: Individuals Without Appropriate Access + levels: + - high + rules: [] + status: pending + - id: ma-5.2 + title: Security Clearances for Classified Systems + rules: [] + status: pending + - id: ma-5.3 + title: Citizenship Requirements for Classified Systems + rules: [] + status: pending + - id: ma-5.4 + title: Foreign Nationals + rules: [] + status: pending + - id: ma-5.5 + title: Non-system Maintenance + rules: [] + status: pending + - id: ma-6 + title: Timely Maintenance + levels: + - moderate + rules: [] + status: pending + - id: ma-6.1 + title: Preventive Maintenance + rules: [] + status: pending + - id: ma-6.2 + title: Predictive Maintenance + rules: [] + status: pending + - id: ma-6.3 + title: Automated Support for Predictive Maintenance + rules: [] + status: pending + - id: ma-7 + title: Field Maintenance + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/mp.yml b/products/rhel10/controls/nist_800_53/mp.yml new file mode 100644 index 000000000000..6c8e8f46e4e4 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/mp.yml @@ -0,0 +1,142 @@ +# NIST 800-53 MP Family: Media Protection +controls: + - id: mp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: mp-2 + title: Media Access + levels: + - low + rules: [] + status: pending + - id: mp-2.1 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-2.2 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-3 + title: Media Marking + levels: + - moderate + rules: [] + status: pending + - id: mp-4 + title: Media Storage + levels: + - moderate + rules: [] + status: pending + - id: mp-4.1 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-4.2 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-5 + title: Media Transport + levels: + - moderate + rules: [] + status: pending + - id: mp-5.1 + title: Protection Outside of Controlled Areas + rules: [] + status: pending + - id: mp-5.2 + title: Documentation of Activities + rules: [] + status: pending + - id: mp-5.3 + title: Custodians + rules: [] + status: pending + - id: mp-5.4 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-6 + title: Media Sanitization + levels: + - low + rules: [] + status: pending + - id: mp-6.1 + title: Review, Approve, Track, Document, and Verify + levels: + - high + rules: [] + status: pending + - id: mp-6.2 + title: Equipment Testing + levels: + - high + rules: [] + status: pending + - id: mp-6.3 + title: Nondestructive Techniques + levels: + - high + rules: [] + status: pending + - id: mp-6.4 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-6.5 + title: Classified Information + rules: [] + status: pending + - id: mp-6.6 + title: Media Destruction + rules: [] + status: pending + - id: mp-6.7 + title: Dual Authorization + rules: [] + status: pending + - id: mp-6.8 + title: Remote Purging or Wiping of Information + rules: [] + status: pending + - id: mp-7 + title: Media Use + levels: + - low + rules: [] + status: pending + - id: mp-7.1 + title: Prohibit Use Without Owner + rules: [] + status: pending + - id: mp-7.2 + title: Prohibit Use of Sanitization-resistant Media + rules: [] + status: pending + - id: mp-8 + title: Media Downgrading + rules: [] + status: pending + - id: mp-8.1 + title: Documentation of Process + rules: [] + status: pending + - id: mp-8.2 + title: Equipment Testing + rules: [] + status: pending + - id: mp-8.3 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-8.4 + title: Classified Information + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/pe.yml b/products/rhel10/controls/nist_800_53/pe.yml new file mode 100644 index 000000000000..b6728c7d49d5 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/pe.yml @@ -0,0 +1,288 @@ +# NIST 800-53 PE Family: Physical and Environmental Protection +controls: + - id: pe-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pe-2 + title: Physical Access Authorizations + levels: + - low + rules: [] + status: pending + - id: pe-2.1 + title: Access by Position or Role + rules: [] + status: pending + - id: pe-2.2 + title: Two Forms of Identification + rules: [] + status: pending + - id: pe-2.3 + title: Restrict Unescorted Access + rules: [] + status: pending + - id: pe-3 + title: Physical Access Control + levels: + - low + rules: [] + status: pending + - id: pe-3.1 + title: System Access + levels: + - high + rules: [] + status: pending + - id: pe-3.2 + title: Facility and Systems + rules: [] + status: pending + - id: pe-3.3 + title: Continuous Guards + rules: [] + status: pending + - id: pe-3.4 + title: Lockable Casings + rules: [] + status: pending + - id: pe-3.5 + title: Tamper Protection + rules: [] + status: pending + - id: pe-3.6 + title: Facility Penetration Testing + rules: [] + status: pending + - id: pe-3.7 + title: Physical Barriers + rules: [] + status: pending + - id: pe-3.8 + title: Access Control Vestibules + rules: [] + status: pending + - id: pe-4 + title: Access Control for Transmission + levels: + - moderate + rules: [] + status: pending + - id: pe-5 + title: Access Control for Output Devices + levels: + - moderate + rules: [] + status: pending + - id: pe-5.1 + title: Access to Output by Authorized Individuals + rules: [] + status: pending + - id: pe-5.2 + title: Link to Individual Identity + rules: [] + status: pending + - id: pe-5.3 + title: Marking Output Devices + rules: [] + status: pending + - id: pe-6 + title: Monitoring Physical Access + levels: + - low + rules: [] + status: pending + - id: pe-6.1 + title: Intrusion Alarms and Surveillance Equipment + levels: + - moderate + rules: [] + status: pending + - id: pe-6.2 + title: Automated Intrusion Recognition and Responses + rules: [] + status: pending + - id: pe-6.3 + title: Video Surveillance + rules: [] + status: pending + - id: pe-6.4 + title: Monitoring Physical Access to Systems + levels: + - high + rules: [] + status: pending + - id: pe-7 + title: Visitor Control + rules: [] + status: pending + - id: pe-8 + title: Visitor Access Records + levels: + - low + rules: [] + status: pending + - id: pe-8.1 + title: Automated Records Maintenance and Review + levels: + - high + rules: [] + status: pending + - id: pe-8.2 + title: Physical Access Records + rules: [] + status: pending + - id: pe-8.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: pe-9 + title: Power Equipment and Cabling + levels: + - moderate + rules: [] + status: pending + - id: pe-9.1 + title: Redundant Cabling + rules: [] + status: pending + - id: pe-9.2 + title: Automatic Voltage Controls + rules: [] + status: pending + - id: pe-10 + title: Emergency Shutoff + levels: + - moderate + rules: [] + status: pending + - id: pe-10.1 + title: Accidental and Unauthorized Activation + rules: [] + status: pending + - id: pe-11 + title: Emergency Power + levels: + - moderate + rules: [] + status: pending + - id: pe-11.1 + title: Alternate Power Supply — Minimal Operational Capability + levels: + - high + rules: [] + status: pending + - id: pe-11.2 + title: Alternate Power Supply — Self-contained + rules: [] + status: pending + - id: pe-12 + title: Emergency Lighting + levels: + - low + rules: [] + status: pending + - id: pe-12.1 + title: Essential Mission and Business Functions + rules: [] + status: pending + - id: pe-13 + title: Fire Protection + levels: + - low + rules: [] + status: pending + - id: pe-13.1 + title: Detection Systems — Automatic Activation and Notification + levels: + - moderate + rules: [] + status: pending + - id: pe-13.2 + title: Suppression Systems — Automatic Activation and Notification + levels: + - high + rules: [] + status: pending + - id: pe-13.3 + title: Automatic Fire Suppression + rules: [] + status: pending + - id: pe-13.4 + title: Inspections + rules: [] + status: pending + - id: pe-14 + title: Environmental Controls + levels: + - low + rules: [] + status: pending + - id: pe-14.1 + title: Automatic Controls + rules: [] + status: pending + - id: pe-14.2 + title: Monitoring with Alarms and Notifications + rules: [] + status: pending + - id: pe-15 + title: Water Damage Protection + levels: + - low + rules: [] + status: pending + - id: pe-15.1 + title: Automation Support + levels: + - high + rules: [] + status: pending + - id: pe-16 + title: Delivery and Removal + levels: + - low + rules: [] + status: pending + - id: pe-17 + title: Alternate Work Site + levels: + - moderate + rules: [] + status: pending + - id: pe-18 + title: Location of System Components + levels: + - high + rules: [] + status: pending + - id: pe-18.1 + title: Facility Site + rules: [] + status: pending + - id: pe-19 + title: Information Leakage + rules: [] + status: pending + - id: pe-19.1 + title: National Emissions Policies and Procedures + rules: [] + status: pending + - id: pe-20 + title: Asset Monitoring and Tracking + rules: [] + status: pending + - id: pe-21 + title: Electromagnetic Pulse Protection + rules: [] + status: pending + - id: pe-22 + title: Component Marking + rules: [] + status: pending + - id: pe-23 + title: Facility Location + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/pl.yml b/products/rhel10/controls/nist_800_53/pl.yml new file mode 100644 index 000000000000..d670e154e380 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/pl.yml @@ -0,0 +1,84 @@ +# NIST 800-53 PL Family: Planning +controls: + - id: pl-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pl-2 + title: System Security and Privacy Plans + levels: + - low + rules: [] + status: pending + - id: pl-2.1 + title: Concept of Operations + rules: [] + status: pending + - id: pl-2.2 + title: Functional Architecture + rules: [] + status: pending + - id: pl-2.3 + title: Plan and Coordinate with Other Organizational Entities + rules: [] + status: pending + - id: pl-3 + title: System Security Plan Update + rules: [] + status: pending + - id: pl-4 + title: Rules of Behavior + levels: + - low + rules: [] + status: pending + - id: pl-4.1 + title: Social Media and External Site/Application Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: pl-5 + title: Privacy Impact Assessment + rules: [] + status: pending + - id: pl-6 + title: Security-related Activity Planning + rules: [] + status: pending + - id: pl-7 + title: Concept of Operations + rules: [] + status: pending + - id: pl-8 + title: Security and Privacy Architectures + levels: + - moderate + rules: [] + status: pending + - id: pl-8.1 + title: Defense in Depth + rules: [] + status: pending + - id: pl-8.2 + title: Supplier Diversity + rules: [] + status: pending + - id: pl-9 + title: Central Management + rules: [] + status: pending + - id: pl-10 + title: Baseline Selection + levels: + - low + rules: [] + status: pending + - id: pl-11 + title: Baseline Tailoring + levels: + - low + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/pm.yml b/products/rhel10/controls/nist_800_53/pm.yml new file mode 100644 index 000000000000..97a32be05deb --- /dev/null +++ b/products/rhel10/controls/nist_800_53/pm.yml @@ -0,0 +1,151 @@ +# NIST 800-53 PM Family: Program Management +controls: + - id: pm-1 + title: Information Security Program Plan + rules: [] + status: pending + - id: pm-2 + title: Information Security Program Leadership Role + rules: [] + status: pending + - id: pm-3 + title: Information Security and Privacy Resources + rules: [] + status: pending + - id: pm-4 + title: Plan of Action and Milestones Process + rules: [] + status: pending + - id: pm-5 + title: System Inventory + rules: [] + status: pending + - id: pm-5.1 + title: Inventory of Personally Identifiable Information + rules: [] + status: pending + - id: pm-6 + title: Measures of Performance + rules: [] + status: pending + - id: pm-7 + title: Enterprise Architecture + rules: [] + status: pending + - id: pm-7.1 + title: Offloading + rules: [] + status: pending + - id: pm-8 + title: Critical Infrastructure Plan + rules: [] + status: pending + - id: pm-9 + title: Risk Management Strategy + rules: [] + status: pending + - id: pm-10 + title: Authorization Process + rules: [] + status: pending + - id: pm-11 + title: Mission and Business Process Definition + rules: [] + status: pending + - id: pm-12 + title: Insider Threat Program + rules: [] + status: pending + - id: pm-13 + title: Security and Privacy Workforce + rules: [] + status: pending + - id: pm-14 + title: Testing, Training, and Monitoring + rules: [] + status: pending + - id: pm-15 + title: Security and Privacy Groups and Associations + rules: [] + status: pending + - id: pm-16 + title: Threat Awareness Program + rules: [] + status: pending + - id: pm-16.1 + title: Automated Means for Sharing Threat Intelligence + rules: [] + status: pending + - id: pm-17 + title: Protecting Controlled Unclassified Information on External Systems + rules: [] + status: pending + - id: pm-18 + title: Privacy Program Plan + rules: [] + status: pending + - id: pm-19 + title: Privacy Program Leadership Role + rules: [] + status: pending + - id: pm-20 + title: Dissemination of Privacy Program Information + rules: [] + status: pending + - id: pm-20.1 + title: Privacy Policies on Websites, Applications, and Digital Services + rules: [] + status: pending + - id: pm-21 + title: Accounting of Disclosures + rules: [] + status: pending + - id: pm-22 + title: Personally Identifiable Information Quality Management + rules: [] + status: pending + - id: pm-23 + title: Data Governance Body + rules: [] + status: pending + - id: pm-24 + title: Data Integrity Board + rules: [] + status: pending + - id: pm-25 + title: Minimization of Personally Identifiable Information Used in Testing, Training, and + Research + rules: [] + status: pending + - id: pm-26 + title: Complaint Management + rules: [] + status: pending + - id: pm-27 + title: Privacy Reporting + rules: [] + status: pending + - id: pm-28 + title: Risk Framing + rules: [] + status: pending + - id: pm-29 + title: Risk Management Program Leadership Roles + rules: [] + status: pending + - id: pm-30 + title: Supply Chain Risk Management Strategy + rules: [] + status: pending + - id: pm-30.1 + title: Suppliers of Critical or Mission-essential Items + rules: [] + status: pending + - id: pm-31 + title: Continuous Monitoring Strategy + rules: [] + status: pending + - id: pm-32 + title: Purposing + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/ps.yml b/products/rhel10/controls/nist_800_53/ps.yml new file mode 100644 index 000000000000..ad7d70333c17 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ps.yml @@ -0,0 +1,94 @@ +# NIST 800-53 PS Family: Personnel Security +controls: + - id: ps-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ps-2 + title: Position Risk Designation + levels: + - low + rules: [] + status: pending + - id: ps-3 + title: Personnel Screening + levels: + - low + rules: [] + status: pending + - id: ps-3.1 + title: Classified Information + rules: [] + status: pending + - id: ps-3.2 + title: Formal Indoctrination + rules: [] + status: pending + - id: ps-3.3 + title: Information Requiring Special Protective Measures + rules: [] + status: pending + - id: ps-3.4 + title: Citizenship Requirements + rules: [] + status: pending + - id: ps-4 + title: Personnel Termination + levels: + - low + rules: [] + status: pending + - id: ps-4.1 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-4.2 + title: Automated Actions + levels: + - high + rules: [] + status: pending + - id: ps-5 + title: Personnel Transfer + levels: + - low + rules: [] + status: pending + - id: ps-6 + title: Access Agreements + levels: + - low + rules: [] + status: pending + - id: ps-6.1 + title: Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.2 + title: Classified Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.3 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-7 + title: External Personnel Security + levels: + - low + rules: [] + status: pending + - id: ps-8 + title: Personnel Sanctions + levels: + - low + rules: [] + status: pending + - id: ps-9 + title: Position Descriptions + levels: + - low + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/pt.yml b/products/rhel10/controls/nist_800_53/pt.yml new file mode 100644 index 000000000000..fe3d1ee54437 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/pt.yml @@ -0,0 +1,86 @@ +# NIST 800-53 PT Family: PII Processing and Transparency +controls: + - id: pt-1 + title: Policy and Procedures + rules: [] + status: pending + - id: pt-2 + title: Authority to Process Personally Identifiable Information + rules: [] + status: pending + - id: pt-2.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-2.2 + title: Automation + rules: [] + status: pending + - id: pt-3 + title: Personally Identifiable Information Processing Purposes + rules: [] + status: pending + - id: pt-3.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-3.2 + title: Automation + rules: [] + status: pending + - id: pt-4 + title: Consent + rules: [] + status: pending + - id: pt-4.1 + title: Tailored Consent + rules: [] + status: pending + - id: pt-4.2 + title: Just-in-time Consent + rules: [] + status: pending + - id: pt-4.3 + title: Revocation + rules: [] + status: pending + - id: pt-5 + title: Privacy Notice + rules: [] + status: pending + - id: pt-5.1 + title: Just-in-time Notice + rules: [] + status: pending + - id: pt-5.2 + title: Privacy Act Statements + rules: [] + status: pending + - id: pt-6 + title: System of Records Notice + rules: [] + status: pending + - id: pt-6.1 + title: Routine Uses + rules: [] + status: pending + - id: pt-6.2 + title: Exemption Rules + rules: [] + status: pending + - id: pt-7 + title: Specific Categories of Personally Identifiable Information + rules: [] + status: pending + - id: pt-7.1 + title: Social Security Numbers + rules: [] + status: pending + - id: pt-7.2 + title: First Amendment Information + rules: [] + status: pending + - id: pt-8 + title: Computer Matching Requirements + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/ra.yml b/products/rhel10/controls/nist_800_53/ra.yml new file mode 100644 index 000000000000..ca44e21f4e67 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/ra.yml @@ -0,0 +1,128 @@ +# NIST 800-53 RA Family: Risk Assessment +controls: + - id: ra-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ra-2 + title: Security Categorization + levels: + - low + rules: [] + status: pending + - id: ra-2.1 + title: Impact-level Prioritization + rules: [] + status: pending + - id: ra-3 + title: Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.1 + title: Supply Chain Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.2 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: ra-3.3 + title: Dynamic Threat Awareness + rules: [] + status: pending + - id: ra-3.4 + title: Predictive Cyber Analytics + rules: [] + status: pending + - id: ra-4 + title: Risk Assessment Update + rules: [] + status: pending + - id: ra-5 + title: Vulnerability Monitoring and Scanning + levels: + - low + rules: [] + status: pending + - id: ra-5.1 + title: Update Tool Capability + rules: [] + status: pending + - id: ra-5.2 + title: Update Vulnerabilities to Be Scanned + levels: + - low + rules: [] + status: pending + - id: ra-5.3 + title: Breadth and Depth of Coverage + rules: [] + status: pending + - id: ra-5.4 + title: Discoverable Information + levels: + - high + rules: [] + status: pending + - id: ra-5.5 + title: Privileged Access + levels: + - moderate + rules: [] + status: pending + - id: ra-5.6 + title: Automated Trend Analyses + rules: [] + status: pending + - id: ra-5.7 + title: Automated Detection and Notification of Unauthorized Components + rules: [] + status: pending + - id: ra-5.8 + title: Review Historic Audit Logs + rules: [] + status: pending + - id: ra-5.9 + title: Penetration Testing and Analyses + rules: [] + status: pending + - id: ra-5.10 + title: Correlate Scanning Information + rules: [] + status: pending + - id: ra-5.11 + title: Public Disclosure Program + levels: + - low + rules: [] + status: pending + - id: ra-6 + title: Technical Surveillance Countermeasures Survey + rules: [] + status: pending + - id: ra-7 + title: Risk Response + levels: + - low + rules: [] + status: pending + - id: ra-8 + title: Privacy Impact Assessments + rules: [] + status: pending + - id: ra-9 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: ra-10 + title: Threat Hunting + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/sa.yml b/products/rhel10/controls/nist_800_53/sa.yml new file mode 100644 index 000000000000..89a619dd4589 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/sa.yml @@ -0,0 +1,632 @@ +# NIST 800-53 SA Family: System and Services Acquisition +controls: + - id: sa-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sa-2 + title: Allocation of Resources + levels: + - low + rules: [] + status: pending + - id: sa-3 + title: System Development Life Cycle + levels: + - low + rules: [] + status: pending + - id: sa-3.1 + title: Manage Preproduction Environment + rules: [] + status: pending + - id: sa-3.2 + title: Use of Live or Operational Data + rules: [] + status: pending + - id: sa-3.3 + title: Technology Refresh + rules: [] + status: pending + - id: sa-4 + title: Acquisition Process + levels: + - low + rules: [] + status: pending + - id: sa-4.1 + title: Functional Properties of Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.2 + title: Design and Implementation Information for Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.3 + title: Development Methods, Techniques, and Practices + rules: [] + status: pending + - id: sa-4.4 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: sa-4.5 + title: System, Component, and Service Configurations + levels: + - high + rules: [] + status: pending + - id: sa-4.6 + title: Use of Information Assurance Products + rules: [] + status: pending + - id: sa-4.7 + title: 'NIAP-approved Protection Profiles ' + rules: [] + status: pending + - id: sa-4.8 + title: Continuous Monitoring Plan for Controls + rules: [] + status: pending + - id: sa-4.9 + title: Functions, Ports, Protocols, and Services in Use + levels: + - moderate + rules: [] + status: pending + - id: sa-4.10 + title: Use of Approved PIV Products + levels: + - low + rules: [] + status: pending + - id: sa-4.11 + title: System of Records + rules: [] + status: pending + - id: sa-4.12 + title: Data Ownership + rules: [] + status: pending + - id: sa-5 + title: System Documentation + levels: + - low + rules: [] + status: pending + - id: sa-5.1 + title: Functional Properties of Security Controls + rules: [] + status: pending + - id: sa-5.2 + title: Security-relevant External System Interfaces + rules: [] + status: pending + - id: sa-5.3 + title: High-level Design + rules: [] + status: pending + - id: sa-5.4 + title: Low-level Design + rules: [] + status: pending + - id: sa-5.5 + title: Source Code + rules: [] + status: pending + - id: sa-6 + title: Software Usage Restrictions + rules: [] + status: pending + - id: sa-7 + title: User-installed Software + rules: [] + status: pending + - id: sa-8 + title: Security and Privacy Engineering Principles + levels: + - low + rules: [] + status: pending + - id: sa-8.1 + title: Clear Abstractions + rules: [] + status: pending + - id: sa-8.2 + title: Least Common Mechanism + rules: [] + status: pending + - id: sa-8.3 + title: Modularity and Layering + rules: [] + status: pending + - id: sa-8.4 + title: Partially Ordered Dependencies + rules: [] + status: pending + - id: sa-8.5 + title: Efficiently Mediated Access + rules: [] + status: pending + - id: sa-8.6 + title: Minimized Sharing + rules: [] + status: pending + - id: sa-8.7 + title: Reduced Complexity + rules: [] + status: pending + - id: sa-8.8 + title: Secure Evolvability + rules: [] + status: pending + - id: sa-8.9 + title: Trusted Components + rules: [] + status: pending + - id: sa-8.10 + title: Hierarchical Trust + rules: [] + status: pending + - id: sa-8.11 + title: Inverse Modification Threshold + rules: [] + status: pending + - id: sa-8.12 + title: Hierarchical Protection + rules: [] + status: pending + - id: sa-8.13 + title: Minimized Security Elements + rules: [] + status: pending + - id: sa-8.14 + title: Least Privilege + rules: [] + status: pending + - id: sa-8.15 + title: Predicate Permission + rules: [] + status: pending + - id: sa-8.16 + title: Self-reliant Trustworthiness + rules: [] + status: pending + - id: sa-8.17 + title: Secure Distributed Composition + rules: [] + status: pending + - id: sa-8.18 + title: Trusted Communications Channels + rules: [] + status: pending + - id: sa-8.19 + title: Continuous Protection + rules: [] + status: pending + - id: sa-8.20 + title: Secure Metadata Management + rules: [] + status: pending + - id: sa-8.21 + title: Self-analysis + rules: [] + status: pending + - id: sa-8.22 + title: Accountability and Traceability + rules: [] + status: pending + - id: sa-8.23 + title: Secure Defaults + rules: [] + status: pending + - id: sa-8.24 + title: Secure Failure and Recovery + rules: [] + status: pending + - id: sa-8.25 + title: Economic Security + rules: [] + status: pending + - id: sa-8.26 + title: Performance Security + rules: [] + status: pending + - id: sa-8.27 + title: Human Factored Security + rules: [] + status: pending + - id: sa-8.28 + title: Acceptable Security + rules: [] + status: pending + - id: sa-8.29 + title: Repeatable and Documented Procedures + rules: [] + status: pending + - id: sa-8.30 + title: Procedural Rigor + rules: [] + status: pending + - id: sa-8.31 + title: Secure System Modification + rules: [] + status: pending + - id: sa-8.32 + title: Sufficient Documentation + rules: [] + status: pending + - id: sa-8.33 + title: Minimization + rules: [] + status: pending + - id: sa-9 + title: External System Services + levels: + - low + rules: [] + status: pending + - id: sa-9.1 + title: Risk Assessments and Organizational Approvals + rules: [] + status: pending + - id: sa-9.2 + title: Identification of Functions, Ports, Protocols, and Services + levels: + - moderate + rules: [] + status: pending + - id: sa-9.3 + title: Establish and Maintain Trust Relationship with Providers + rules: [] + status: pending + - id: sa-9.4 + title: Consistent Interests of Consumers and Providers + rules: [] + status: pending + - id: sa-9.5 + title: Processing, Storage, and Service Location + rules: [] + status: pending + - id: sa-9.6 + title: Organization-controlled Cryptographic Keys + rules: [] + status: pending + - id: sa-9.7 + title: Organization-controlled Integrity Checking + rules: [] + status: pending + - id: sa-9.8 + title: Processing and Storage Location — U.S. Jurisdiction + rules: [] + status: pending + - id: sa-10 + title: Developer Configuration Management + levels: + - moderate + rules: [] + status: pending + - id: sa-10.1 + title: Software and Firmware Integrity Verification + rules: [] + status: pending + - id: sa-10.2 + title: Alternative Configuration Management Processes + rules: [] + status: pending + - id: sa-10.3 + title: Hardware Integrity Verification + rules: [] + status: pending + - id: sa-10.4 + title: Trusted Generation + rules: [] + status: pending + - id: sa-10.5 + title: Mapping Integrity for Version Control + rules: [] + status: pending + - id: sa-10.6 + title: Trusted Distribution + rules: [] + status: pending + - id: sa-10.7 + title: Security and Privacy Representatives + rules: [] + status: pending + - id: sa-11 + title: Developer Testing and Evaluation + levels: + - moderate + rules: [] + status: pending + - id: sa-11.1 + title: Static Code Analysis + rules: [] + status: pending + - id: sa-11.2 + title: Threat Modeling and Vulnerability Analyses + rules: [] + status: pending + - id: sa-11.3 + title: Independent Verification of Assessment Plans and Evidence + rules: [] + status: pending + - id: sa-11.4 + title: Manual Code Reviews + rules: [] + status: pending + - id: sa-11.5 + title: Penetration Testing + rules: [] + status: pending + - id: sa-11.6 + title: Attack Surface Reviews + rules: [] + status: pending + - id: sa-11.7 + title: Verify Scope of Testing and Evaluation + rules: [] + status: pending + - id: sa-11.8 + title: Dynamic Code Analysis + rules: [] + status: pending + - id: sa-11.9 + title: Interactive Application Security Testing + rules: [] + status: pending + - id: sa-12 + title: Supply Chain Protection + rules: [] + status: pending + - id: sa-12.1 + title: Acquisition Strategies / Tools / Methods + rules: [] + status: pending + - id: sa-12.2 + title: Supplier Reviews + rules: [] + status: pending + - id: sa-12.3 + title: Trusted Shipping and Warehousing + rules: [] + status: pending + - id: sa-12.4 + title: Diversity of Suppliers + rules: [] + status: pending + - id: sa-12.5 + title: Limitation of Harm + rules: [] + status: pending + - id: sa-12.6 + title: Minimizing Procurement Time + rules: [] + status: pending + - id: sa-12.7 + title: Assessments Prior to Selection / Acceptance / Update + rules: [] + status: pending + - id: sa-12.8 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: sa-12.9 + title: Operations Security + rules: [] + status: pending + - id: sa-12.10 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sa-12.11 + title: Penetration Testing / Analysis of Elements, Processes, and Actors + rules: [] + status: pending + - id: sa-12.12 + title: Inter-organizational Agreements + rules: [] + status: pending + - id: sa-12.13 + title: Critical Information System Components + rules: [] + status: pending + - id: sa-12.14 + title: Identity and Traceability + rules: [] + status: pending + - id: sa-12.15 + title: Processes to Address Weaknesses or Deficiencies + rules: [] + status: pending + - id: sa-13 + title: Trustworthiness + rules: [] + status: pending + - id: sa-14 + title: Criticality Analysis + rules: [] + status: pending + - id: sa-14.1 + title: Critical Components with No Viable Alternative Sourcing + rules: [] + status: pending + - id: sa-15 + title: Development Process, Standards, and Tools + levels: + - moderate + rules: [] + status: pending + - id: sa-15.1 + title: Quality Metrics + rules: [] + status: pending + - id: sa-15.2 + title: Security and Privacy Tracking Tools + rules: [] + status: pending + - id: sa-15.3 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: sa-15.4 + title: Threat Modeling and Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.5 + title: Attack Surface Reduction + rules: [] + status: pending + - id: sa-15.6 + title: Continuous Improvement + rules: [] + status: pending + - id: sa-15.7 + title: Automated Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.8 + title: Reuse of Threat and Vulnerability Information + rules: [] + status: pending + - id: sa-15.9 + title: Use of Live Data + rules: [] + status: pending + - id: sa-15.10 + title: Incident Response Plan + rules: [] + status: pending + - id: sa-15.11 + title: Archive System or Component + rules: [] + status: pending + - id: sa-15.12 + title: Minimize Personally Identifiable Information + rules: [] + status: pending + - id: sa-15.13 + title: Logging Syntax + rules: [] + status: pending + - id: sa-16 + title: Developer-provided Training + levels: + - high + rules: [] + status: pending + - id: sa-17 + title: Developer Security and Privacy Architecture and Design + levels: + - high + rules: [] + status: pending + - id: sa-17.1 + title: Formal Policy Model + rules: [] + status: pending + - id: sa-17.2 + title: Security-relevant Components + rules: [] + status: pending + - id: sa-17.3 + title: Formal Correspondence + rules: [] + status: pending + - id: sa-17.4 + title: Informal Correspondence + rules: [] + status: pending + - id: sa-17.5 + title: Conceptually Simple Design + rules: [] + status: pending + - id: sa-17.6 + title: Structure for Testing + rules: [] + status: pending + - id: sa-17.7 + title: Structure for Least Privilege + rules: [] + status: pending + - id: sa-17.8 + title: Orchestration + rules: [] + status: pending + - id: sa-17.9 + title: Design Diversity + rules: [] + status: pending + - id: sa-18 + title: Tamper Resistance and Detection + rules: [] + status: pending + - id: sa-18.1 + title: Multiple Phases of System Development Life Cycle + rules: [] + status: pending + - id: sa-18.2 + title: Inspection of Systems or Components + rules: [] + status: pending + - id: sa-19 + title: Component Authenticity + rules: [] + status: pending + - id: sa-19.1 + title: Anti-counterfeit Training + rules: [] + status: pending + - id: sa-19.2 + title: Configuration Control for Component Service and Repair + rules: [] + status: pending + - id: sa-19.3 + title: Component Disposal + rules: [] + status: pending + - id: sa-19.4 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sa-20 + title: Customized Development of Critical Components + rules: [] + status: pending + - id: sa-21 + title: Developer Screening + levels: + - high + rules: [] + status: pending + - id: sa-21.1 + title: Validation of Screening + rules: [] + status: pending + - id: sa-22 + title: Unsupported System Components + levels: + - low + rules: [] + status: pending + - id: sa-22.1 + title: Alternative Sources for Continued Support + rules: [] + status: pending + - id: sa-23 + title: Specialization + rules: [] + status: pending + - id: sa-24 + title: Design For Cyber Resiliency + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/sc.yml b/products/rhel10/controls/nist_800_53/sc.yml new file mode 100644 index 000000000000..1cea755d3a41 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/sc.yml @@ -0,0 +1,720 @@ +# NIST 800-53 SC Family: System and Communications Protection +controls: + - id: sc-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sc-2 + title: Separation of System and User Functionality + levels: + - moderate + rules: + - sysctl_kernel_dmesg_restrict + status: automated + - id: sc-2.1 + title: Interfaces for Non-privileged Users + rules: [] + status: pending + - id: sc-2.2 + title: Disassociability + rules: [] + status: pending + - id: sc-3 + title: Security Function Isolation + levels: + - high + rules: + - selinux_not_disabled + - selinux_state + - var_selinux_state=enforcing + status: automated + - id: sc-3.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-3.2 + title: Access and Flow Control Functions + rules: [] + status: pending + - id: sc-3.3 + title: Minimize Nonsecurity Functionality + rules: [] + status: pending + - id: sc-3.4 + title: Module Coupling and Cohesiveness + rules: [] + status: pending + - id: sc-3.5 + title: Layered Structures + rules: [] + status: pending + - id: sc-4 + title: Information in Shared System Resources + levels: + - moderate + rules: + - dir_perms_world_writable_sticky_bits + - file_permissions_unauthorized_world_writable + status: automated + - id: sc-4.1 + title: Security Levels + rules: [] + status: pending + - id: sc-4.2 + title: Multilevel or Periods Processing + rules: [] + status: pending + - id: sc-5 + title: Denial-of-service Protection + levels: + - low + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + - id: sc-5.1 + title: Restrict Ability to Attack Other Systems + rules: [] + status: pending + - id: sc-5.2 + title: Capacity, Bandwidth, and Redundancy + rules: [] + status: pending + - id: sc-5.3 + title: Detection and Monitoring + rules: [] + status: pending + - id: sc-6 + title: Resource Availability + rules: [] + status: pending + - id: sc-7 + title: Boundary Protection + levels: + - low + rules: + - service_firewalld_enabled + status: automated + - id: sc-7.1 + title: Physically Separated Subnetworks + rules: [] + status: pending + - id: sc-7.2 + title: Public Access + rules: [] + status: pending + - id: sc-7.3 + title: Access Points + levels: + - moderate + rules: [] + status: pending + - id: sc-7.4 + title: External Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: sc-7.5 + title: Deny by Default — Allow by Exception + levels: + - moderate + rules: [] + status: pending + - id: sc-7.6 + title: Response to Recognized Failures + rules: [] + status: pending + - id: sc-7.7 + title: Split Tunneling for Remote Devices + levels: + - moderate + rules: [] + status: pending + - id: sc-7.8 + title: Route Traffic to Authenticated Proxy Servers + levels: + - moderate + rules: [] + status: pending + - id: sc-7.9 + title: Restrict Threatening Outgoing Communications Traffic + rules: [] + status: pending + - id: sc-7.10 + title: Prevent Exfiltration + rules: [] + status: pending + - id: sc-7.11 + title: Restrict Incoming Communications Traffic + rules: [] + status: pending + - id: sc-7.12 + title: Host-based Protection + rules: [] + status: pending + - id: sc-7.13 + title: Isolation of Security Tools, Mechanisms, and Support Components + rules: [] + status: pending + - id: sc-7.14 + title: Protect Against Unauthorized Physical Connections + rules: [] + status: pending + - id: sc-7.15 + title: Networked Privileged Accesses + rules: [] + status: pending + - id: sc-7.16 + title: Prevent Discovery of System Components + rules: [] + status: pending + - id: sc-7.17 + title: Automated Enforcement of Protocol Formats + rules: [] + status: pending + - id: sc-7.18 + title: Fail Secure + levels: + - high + rules: [] + status: pending + - id: sc-7.19 + title: Block Communication from Non-organizationally Configured Hosts + rules: [] + status: pending + - id: sc-7.20 + title: Dynamic Isolation and Segregation + rules: [] + status: pending + - id: sc-7.21 + title: Isolation of System Components + levels: + - high + rules: [] + status: pending + - id: sc-7.22 + title: Separate Subnets for Connecting to Different Security Domains + rules: [] + status: pending + - id: sc-7.23 + title: Disable Sender Feedback on Protocol Validation Failure + rules: [] + status: pending + - id: sc-7.24 + title: Personally Identifiable Information + rules: [] + status: pending + - id: sc-7.25 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: sc-7.26 + title: Classified National Security System Connections + rules: [] + status: pending + - id: sc-7.27 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: sc-7.28 + title: Connections to Public Networks + rules: [] + status: pending + - id: sc-7.29 + title: Separate Subnets to Isolate Functions + rules: [] + status: pending + - id: sc-8 + title: Transmission Confidentiality and Integrity + levels: + - moderate + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: sc-8.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-8.2 + title: Pre- and Post-transmission Handling + rules: [] + status: pending + - id: sc-8.3 + title: Cryptographic Protection for Message Externals + rules: [] + status: pending + - id: sc-8.4 + title: Conceal or Randomize Communications + rules: [] + status: pending + - id: sc-8.5 + title: Protected Distribution System + rules: [] + status: pending + - id: sc-9 + title: Transmission Confidentiality + rules: [] + status: pending + - id: sc-10 + title: Network Disconnect + levels: + - moderate + rules: [] + status: pending + - id: sc-11 + title: Trusted Path + rules: [] + status: pending + - id: sc-11.1 + title: Irrefutable Communications Path + rules: [] + status: pending + - id: sc-12 + title: Cryptographic Key Establishment and Management + levels: + - low + rules: [] + status: pending + - id: sc-12.1 + title: Availability + levels: + - high + rules: [] + status: pending + - id: sc-12.2 + title: Symmetric Keys + rules: [] + status: pending + - id: sc-12.3 + title: Asymmetric Keys + rules: [] + status: pending + - id: sc-12.4 + title: PKI Certificates + rules: [] + status: pending + - id: sc-12.5 + title: PKI Certificates / Hardware Tokens + rules: [] + status: pending + - id: sc-12.6 + title: Physical Control of Keys + rules: [] + status: pending + - id: sc-13 + title: Cryptographic Protection + levels: + - low + rules: [] + status: pending + - id: sc-13.1 + title: FIPS-validated Cryptography + rules: [] + status: pending + - id: sc-13.2 + title: NSA-approved Cryptography + rules: [] + status: pending + - id: sc-13.3 + title: Individuals Without Formal Access Approvals + rules: [] + status: pending + - id: sc-13.4 + title: Digital Signatures + rules: [] + status: pending + - id: sc-14 + title: Public Access Protections + rules: [] + status: pending + - id: sc-15 + title: Collaborative Computing Devices and Applications + levels: + - low + rules: [] + status: pending + - id: sc-15.1 + title: Physical or Logical Disconnect + rules: [] + status: pending + - id: sc-15.2 + title: Blocking Inbound and Outbound Communications Traffic + rules: [] + status: pending + - id: sc-15.3 + title: Disabling and Removal in Secure Work Areas + rules: [] + status: pending + - id: sc-15.4 + title: Explicitly Indicate Current Participants + rules: [] + status: pending + - id: sc-16 + title: Transmission of Security and Privacy Attributes + rules: [] + status: pending + - id: sc-16.1 + title: Integrity Verification + rules: [] + status: pending + - id: sc-16.2 + title: Anti-spoofing Mechanisms + rules: [] + status: pending + - id: sc-16.3 + title: Cryptographic Binding + rules: [] + status: pending + - id: sc-17 + title: Public Key Infrastructure Certificates + levels: + - moderate + rules: [] + status: pending + - id: sc-18 + title: Mobile Code + levels: + - moderate + rules: [] + status: pending + - id: sc-18.1 + title: Identify Unacceptable Code and Take Corrective Actions + rules: [] + status: pending + - id: sc-18.2 + title: Acquisition, Development, and Use + rules: [] + status: pending + - id: sc-18.3 + title: Prevent Downloading and Execution + rules: [] + status: pending + - id: sc-18.4 + title: Prevent Automatic Execution + rules: [] + status: pending + - id: sc-18.5 + title: Allow Execution Only in Confined Environments + rules: [] + status: pending + - id: sc-19 + title: Voice Over Internet Protocol + rules: [] + status: pending + - id: sc-20 + title: Secure Name/Address Resolution Service (Authoritative Source) + levels: + - low + rules: [] + status: pending + - id: sc-20.1 + title: Child Subspaces + rules: [] + status: pending + - id: sc-20.2 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-21 + title: Secure Name/Address Resolution Service (Recursive or Caching Resolver) + levels: + - low + rules: [] + status: pending + - id: sc-21.1 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-22 + title: Architecture and Provisioning for Name/Address Resolution Service + levels: + - low + rules: [] + status: pending + - id: sc-23 + title: Session Authenticity + levels: + - moderate + rules: [] + status: pending + - id: sc-23.1 + title: Invalidate Session Identifiers at Logout + rules: [] + status: pending + - id: sc-23.2 + title: User-initiated Logouts and Message Displays + rules: [] + status: pending + - id: sc-23.3 + title: Unique System-generated Session Identifiers + rules: [] + status: pending + - id: sc-23.4 + title: Unique Session Identifiers with Randomization + rules: [] + status: pending + - id: sc-23.5 + title: Allowed Certificate Authorities + rules: [] + status: pending + - id: sc-24 + title: Fail in Known State + levels: + - high + rules: + - service_systemd-journald_enabled + status: automated + - id: sc-25 + title: Thin Nodes + rules: [] + status: pending + - id: sc-26 + title: Decoys + rules: [] + status: pending + - id: sc-26.1 + title: Detection of Malicious Code + rules: [] + status: pending + - id: sc-27 + title: Platform-independent Applications + rules: [] + status: pending + - id: sc-28 + title: Protection of Information at Rest + levels: + - moderate + rules: [] + status: pending + - id: sc-28.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-28.2 + title: Offline Storage + rules: [] + status: pending + - id: sc-28.3 + title: Cryptographic Keys + rules: [] + status: pending + - id: sc-29 + title: Heterogeneity + rules: [] + status: pending + - id: sc-29.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30 + title: Concealment and Misdirection + rules: [] + status: pending + - id: sc-30.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30.2 + title: Randomness + rules: [] + status: pending + - id: sc-30.3 + title: Change Processing and Storage Locations + rules: [] + status: pending + - id: sc-30.4 + title: Misleading Information + rules: [] + status: pending + - id: sc-30.5 + title: Concealment of System Components + rules: [] + status: pending + - id: sc-31 + title: Covert Channel Analysis + rules: [] + status: pending + - id: sc-31.1 + title: Test Covert Channels for Exploitability + rules: [] + status: pending + - id: sc-31.2 + title: Maximum Bandwidth + rules: [] + status: pending + - id: sc-31.3 + title: Measure Bandwidth in Operational Environments + rules: [] + status: pending + - id: sc-32 + title: System Partitioning + rules: [] + status: pending + - id: sc-32.1 + title: Separate Physical Domains for Privileged Functions + rules: [] + status: pending + - id: sc-33 + title: Transmission Preparation Integrity + rules: [] + status: pending + - id: sc-34 + title: Non-modifiable Executable Programs + rules: [] + status: pending + - id: sc-34.1 + title: No Writable Storage + rules: [] + status: pending + - id: sc-34.2 + title: Integrity Protection on Read-only Media + rules: [] + status: pending + - id: sc-34.3 + title: Hardware-based Protection + rules: [] + status: pending + - id: sc-35 + title: External Malicious Code Identification + rules: [] + status: pending + - id: sc-36 + title: Distributed Processing and Storage + rules: [] + status: pending + - id: sc-36.1 + title: Polling Techniques + rules: [] + status: pending + - id: sc-36.2 + title: Synchronization + rules: [] + status: pending + - id: sc-37 + title: Out-of-band Channels + rules: [] + status: pending + - id: sc-37.1 + title: Ensure Delivery and Transmission + rules: [] + status: pending + - id: sc-38 + title: Operations Security + rules: [] + status: pending + - id: sc-39 + title: Process Isolation + levels: + - low + rules: [] + status: pending + - id: sc-39.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-39.2 + title: Separate Execution Domain Per Thread + rules: [] + status: pending + - id: sc-40 + title: Wireless Link Protection + rules: [] + status: pending + - id: sc-40.1 + title: Electromagnetic Interference + rules: [] + status: pending + - id: sc-40.2 + title: Reduce Detection Potential + rules: [] + status: pending + - id: sc-40.3 + title: Imitative or Manipulative Communications Deception + rules: [] + status: pending + - id: sc-40.4 + title: Signal Parameter Identification + rules: [] + status: pending + - id: sc-41 + title: Port and I/O Device Access + rules: [] + status: pending + - id: sc-42 + title: Sensor Capability and Data + rules: [] + status: pending + - id: sc-42.1 + title: Reporting to Authorized Individuals or Roles + rules: [] + status: pending + - id: sc-42.2 + title: Authorized Use + rules: [] + status: pending + - id: sc-42.3 + title: Prohibit Use of Devices + rules: [] + status: pending + - id: sc-42.4 + title: Notice of Collection + rules: [] + status: pending + - id: sc-42.5 + title: Collection Minimization + rules: [] + status: pending + - id: sc-43 + title: Usage Restrictions + rules: [] + status: pending + - id: sc-44 + title: Detonation Chambers + rules: [] + status: pending + - id: sc-45 + title: System Time Synchronization + rules: [] + status: pending + - id: sc-45.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: sc-45.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: sc-46 + title: Cross Domain Policy Enforcement + rules: [] + status: pending + - id: sc-47 + title: Alternate Communications Paths + rules: [] + status: pending + - id: sc-48 + title: Sensor Relocation + rules: [] + status: pending + - id: sc-48.1 + title: Dynamic Relocation of Sensors or Monitoring Capabilities + rules: [] + status: pending + - id: sc-49 + title: Hardware-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-50 + title: Software-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-51 + title: Hardware-based Protection + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/si.yml b/products/rhel10/controls/nist_800_53/si.yml new file mode 100644 index 000000000000..d34ca6e0d67c --- /dev/null +++ b/products/rhel10/controls/nist_800_53/si.yml @@ -0,0 +1,544 @@ +# NIST 800-53 SI Family: System and Information Integrity +controls: + - id: si-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: si-2 + title: Flaw Remediation + levels: + - low + rules: + - ensure_gpgcheck_globally_activated + - ensure_redhat_gpgkey_installed + status: automated + - id: si-2.1 + title: Central Management + rules: [] + status: pending + - id: si-2.2 + title: Automated Flaw Remediation Status + levels: + - moderate + rules: [] + status: pending + - id: si-2.3 + title: Time to Remediate Flaws and Benchmarks for Corrective Actions + rules: [] + status: pending + - id: si-2.4 + title: Automated Patch Management Tools + rules: [] + status: pending + - id: si-2.5 + title: Automatic Software and Firmware Updates + rules: [] + status: pending + - id: si-2.6 + title: Removal of Previous Versions of Software and Firmware + rules: [] + status: pending + - id: si-2.7 + title: Root Cause Analysis + rules: [] + status: pending + - id: si-3 + title: Malicious Code Protection + levels: + - low + rules: + - kernel_module_usb-storage_disabled + - service_autofs_disabled + status: automated + - id: si-3.1 + title: Central Management + rules: [] + status: pending + - id: si-3.2 + title: Automatic Updates + rules: [] + status: pending + - id: si-3.3 + title: Non-privileged Users + rules: [] + status: pending + - id: si-3.4 + title: Updates Only by Privileged Users + rules: [] + status: pending + - id: si-3.5 + title: Portable Storage Devices + rules: [] + status: pending + - id: si-3.6 + title: Testing and Verification + rules: [] + status: pending + - id: si-3.7 + title: Nonsignature-based Detection + rules: [] + status: pending + - id: si-3.8 + title: Detect Unauthorized Commands + rules: [] + status: pending + - id: si-3.9 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: si-3.10 + title: Malicious Code Analysis + rules: [] + status: pending + - id: si-4 + title: System Monitoring + levels: + - low + rules: + - kernel_module_dccp_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_tipc_disabled + - service_avahi-daemon_disabled + status: automated + - id: si-4.1 + title: System-wide Intrusion Detection System + rules: [] + status: pending + - id: si-4.2 + title: Automated Tools and Mechanisms for Real-time Analysis + levels: + - moderate + rules: [] + status: pending + - id: si-4.3 + title: Automated Tool and Mechanism Integration + rules: [] + status: pending + - id: si-4.4 + title: Inbound and Outbound Communications Traffic + levels: + - moderate + rules: [] + status: pending + - id: si-4.5 + title: System-generated Alerts + levels: + - moderate + rules: [] + status: pending + - id: si-4.6 + title: Restrict Non-privileged Users + rules: [] + status: pending + - id: si-4.7 + title: Automated Response to Suspicious Events + rules: [] + status: pending + - id: si-4.8 + title: Protection of Monitoring Information + rules: [] + status: pending + - id: si-4.9 + title: Testing of Monitoring Tools and Mechanisms + rules: [] + status: pending + - id: si-4.10 + title: Visibility of Encrypted Communications + levels: + - high + rules: [] + status: pending + - id: si-4.11 + title: Analyze Communications Traffic Anomalies + rules: [] + status: pending + - id: si-4.12 + title: Automated Organization-generated Alerts + levels: + - high + rules: [] + status: pending + - id: si-4.13 + title: Analyze Traffic and Event Patterns + rules: [] + status: pending + - id: si-4.14 + title: Wireless Intrusion Detection + levels: + - high + rules: [] + status: pending + - id: si-4.15 + title: Wireless to Wireline Communications + rules: [] + status: pending + - id: si-4.16 + title: Correlate Monitoring Information + rules: [] + status: pending + - id: si-4.17 + title: Integrated Situational Awareness + rules: [] + status: pending + - id: si-4.18 + title: Analyze Traffic and Covert Exfiltration + rules: [] + status: pending + - id: si-4.19 + title: Risk for Individuals + rules: [] + status: pending + - id: si-4.20 + title: Privileged Users + levels: + - high + rules: [] + status: pending + - id: si-4.21 + title: Probationary Periods + rules: [] + status: pending + - id: si-4.22 + title: Unauthorized Network Services + levels: + - high + rules: [] + status: pending + - id: si-4.23 + title: Host-based Devices + rules: [] + status: pending + - id: si-4.24 + title: Indicators of Compromise + rules: [] + status: pending + - id: si-4.25 + title: Optimize Network Traffic Analysis + rules: [] + status: pending + - id: si-5 + title: Security Alerts, Advisories, and Directives + levels: + - low + rules: [] + status: pending + - id: si-5.1 + title: Automated Alerts and Advisories + levels: + - high + rules: [] + status: pending + - id: si-6 + title: Security and Privacy Function Verification + levels: + - high + rules: [] + status: pending + - id: si-6.1 + title: Notification of Failed Security Tests + rules: [] + status: pending + - id: si-6.2 + title: Automation Support for Distributed Testing + rules: [] + status: pending + - id: si-6.3 + title: Report Verification Results + rules: [] + status: pending + - id: si-7 + title: Software, Firmware, and Information Integrity + levels: + - moderate + rules: [] + status: pending + - id: si-7.1 + title: Integrity Checks + levels: + - moderate + rules: [] + status: pending + - id: si-7.2 + title: Automated Notifications of Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.3 + title: Centrally Managed Integrity Tools + rules: [] + status: pending + - id: si-7.4 + title: Tamper-evident Packaging + rules: [] + status: pending + - id: si-7.5 + title: Automated Response to Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: si-7.7 + title: Integration of Detection and Response + levels: + - moderate + rules: [] + status: pending + - id: si-7.8 + title: Auditing Capability for Significant Events + rules: [] + status: pending + - id: si-7.9 + title: Verify Boot Process + rules: [] + status: pending + - id: si-7.10 + title: Protection of Boot Firmware + rules: [] + status: pending + - id: si-7.11 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: si-7.12 + title: Integrity Verification + rules: [] + status: pending + - id: si-7.13 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: si-7.14 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: si-7.15 + title: Code Authentication + levels: + - high + rules: [] + status: pending + - id: si-7.16 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-7.17 + title: Runtime Application Self-protection + rules: [] + status: pending + - id: si-8 + title: Spam Protection + levels: + - moderate + rules: [] + status: pending + - id: si-8.1 + title: Central Management + rules: [] + status: pending + - id: si-8.2 + title: Automatic Updates + levels: + - moderate + rules: [] + status: pending + - id: si-8.3 + title: Continuous Learning Capability + rules: [] + status: pending + - id: si-9 + title: Information Input Restrictions + rules: [] + status: pending + - id: si-10 + title: Information Input Validation + levels: + - moderate + rules: [] + status: pending + - id: si-10.1 + title: Manual Override Capability + rules: [] + status: pending + - id: si-10.2 + title: Review and Resolve Errors + rules: [] + status: pending + - id: si-10.3 + title: Predictable Behavior + rules: [] + status: pending + - id: si-10.4 + title: Timing Interactions + rules: [] + status: pending + - id: si-10.5 + title: Restrict Inputs to Trusted Sources and Approved Formats + rules: [] + status: pending + - id: si-10.6 + title: Injection Prevention + rules: [] + status: pending + - id: si-11 + title: Error Handling + levels: + - moderate + rules: [] + status: pending + - id: si-12 + title: Information Management and Retention + levels: + - low + rules: [] + status: pending + - id: si-12.1 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: si-12.2 + title: Minimize Personally Identifiable Information in Testing, Training, and Research + rules: [] + status: pending + - id: si-12.3 + title: Information Disposal + rules: [] + status: pending + - id: si-13 + title: Predictable Failure Prevention + rules: [] + status: pending + - id: si-13.1 + title: Transferring Component Responsibilities + rules: [] + status: pending + - id: si-13.2 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-13.3 + title: Manual Transfer Between Components + rules: [] + status: pending + - id: si-13.4 + title: Standby Component Installation and Notification + rules: [] + status: pending + - id: si-13.5 + title: Failover Capability + rules: [] + status: pending + - id: si-14 + title: Non-persistence + rules: [] + status: pending + - id: si-14.1 + title: Refresh from Trusted Sources + rules: [] + status: pending + - id: si-14.2 + title: Non-persistent Information + rules: [] + status: pending + - id: si-14.3 + title: Non-persistent Connectivity + rules: [] + status: pending + - id: si-15 + title: Information Output Filtering + rules: [] + status: pending + - id: si-16 + title: Memory Protection + levels: + - moderate + rules: + - sysctl_kernel_randomize_va_space + status: automated + - id: si-17 + title: Fail-safe Procedures + rules: [] + status: pending + - id: si-18 + title: Personally Identifiable Information Quality Operations + rules: [] + status: pending + - id: si-18.1 + title: Automation Support + rules: [] + status: pending + - id: si-18.2 + title: Data Tags + rules: [] + status: pending + - id: si-18.3 + title: Collection + rules: [] + status: pending + - id: si-18.4 + title: Individual Requests + rules: [] + status: pending + - id: si-18.5 + title: Notice of Correction or Deletion + rules: [] + status: pending + - id: si-19 + title: De-identification + rules: [] + status: pending + - id: si-19.1 + title: Collection + rules: [] + status: pending + - id: si-19.2 + title: Archiving + rules: [] + status: pending + - id: si-19.3 + title: Release + rules: [] + status: pending + - id: si-19.4 + title: Removal, Masking, Encryption, Hashing, or Replacement of Direct Identifiers + rules: [] + status: pending + - id: si-19.5 + title: Statistical Disclosure Control + rules: [] + status: pending + - id: si-19.6 + title: Differential Privacy + rules: [] + status: pending + - id: si-19.7 + title: Validated Algorithms and Software + rules: [] + status: pending + - id: si-19.8 + title: Motivated Intruder + rules: [] + status: pending + - id: si-20 + title: Tainting + rules: [] + status: pending + - id: si-21 + title: Information Refresh + rules: [] + status: pending + - id: si-22 + title: Information Diversity + rules: [] + status: pending + - id: si-23 + title: Information Fragmentation + rules: [] + status: pending diff --git a/products/rhel10/controls/nist_800_53/sr.yml b/products/rhel10/controls/nist_800_53/sr.yml new file mode 100644 index 000000000000..1e130f32cd89 --- /dev/null +++ b/products/rhel10/controls/nist_800_53/sr.yml @@ -0,0 +1,138 @@ +# NIST 800-53 SR Family: Supply Chain Risk Management +controls: + - id: sr-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sr-2 + title: Supply Chain Risk Management Plan + levels: + - low + rules: [] + status: pending + - id: sr-2.1 + title: Establish SCRM Team + levels: + - low + rules: [] + status: pending + - id: sr-3 + title: Supply Chain Controls and Processes + levels: + - low + rules: [] + status: pending + - id: sr-3.1 + title: Diverse Supply Base + rules: [] + status: pending + - id: sr-3.2 + title: Limitation of Harm + rules: [] + status: pending + - id: sr-3.3 + title: Sub-tier Flow Down + rules: [] + status: pending + - id: sr-4 + title: Provenance + rules: [] + status: pending + - id: sr-4.1 + title: Identity + rules: [] + status: pending + - id: sr-4.2 + title: Track and Trace + rules: [] + status: pending + - id: sr-4.3 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sr-4.4 + title: Supply Chain Integrity — Pedigree + rules: [] + status: pending + - id: sr-5 + title: Acquisition Strategies, Tools, and Methods + levels: + - low + rules: [] + status: pending + - id: sr-5.1 + title: Adequate Supply + rules: [] + status: pending + - id: sr-5.2 + title: Assessments Prior to Selection, Acceptance, Modification, or Update + rules: [] + status: pending + - id: sr-6 + title: Supplier Assessments and Reviews + levels: + - moderate + rules: [] + status: pending + - id: sr-6.1 + title: Testing and Analysis + rules: [] + status: pending + - id: sr-7 + title: Supply Chain Operations Security + rules: [] + status: pending + - id: sr-8 + title: Notification Agreements + levels: + - low + rules: [] + status: pending + - id: sr-9 + title: Tamper Resistance and Detection + levels: + - high + rules: [] + status: pending + - id: sr-9.1 + title: Multiple Stages of System Development Life Cycle + levels: + - high + rules: [] + status: pending + - id: sr-10 + title: Inspection of Systems or Components + levels: + - low + rules: [] + status: pending + - id: sr-11 + title: Component Authenticity + levels: + - low + rules: [] + status: pending + - id: sr-11.1 + title: Anti-counterfeit Training + levels: + - low + rules: [] + status: pending + - id: sr-11.2 + title: Configuration Control for Component Service and Repair + levels: + - low + rules: [] + status: pending + - id: sr-11.3 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sr-12 + title: Component Disposal + levels: + - low + rules: [] + status: pending diff --git a/products/rhel10/profiles/anssi_bp28_enhanced.profile b/products/rhel10/profiles/anssi_bp28_enhanced.profile index c6892d6a6677..7eee5c589436 100644 --- a/products/rhel10/profiles/anssi_bp28_enhanced.profile +++ b/products/rhel10/profiles/anssi_bp28_enhanced.profile @@ -9,8 +9,7 @@ metadata: title: 'ANSSI-BP-028 (enhanced)' description: |- - This is a draft profile for experimental purposes. - This draft profile contains configurations that align to ANSSI-BP-028 v2.0 at the enhanced hardening level. + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the enhanced hardening level. ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. diff --git a/products/rhel10/profiles/anssi_bp28_high.profile b/products/rhel10/profiles/anssi_bp28_high.profile index 62700ff5810b..f5e77401a7ed 100644 --- a/products/rhel10/profiles/anssi_bp28_high.profile +++ b/products/rhel10/profiles/anssi_bp28_high.profile @@ -9,8 +9,7 @@ metadata: title: 'ANSSI-BP-028 (high)' description: |- - This is a draft profile for experimental purposes. - This draft profile contains configurations that align to ANSSI-BP-028 v2.0 at the high hardening level. + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the high hardening level. ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. diff --git a/products/rhel10/profiles/anssi_bp28_intermediary.profile b/products/rhel10/profiles/anssi_bp28_intermediary.profile index de410b88e840..11c4b0c86cdc 100644 --- a/products/rhel10/profiles/anssi_bp28_intermediary.profile +++ b/products/rhel10/profiles/anssi_bp28_intermediary.profile @@ -9,8 +9,7 @@ metadata: title: 'ANSSI-BP-028 (intermediary)' description: |- - This is a draft profile for experimental purposes. - This draft profile contains configurations that align to ANSSI-BP-028 v2.0 at the intermediary hardening level. + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the intermediary hardening level. ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. diff --git a/products/rhel10/profiles/anssi_bp28_minimal.profile b/products/rhel10/profiles/anssi_bp28_minimal.profile index 2a16f6860894..4bd6e88bb05c 100644 --- a/products/rhel10/profiles/anssi_bp28_minimal.profile +++ b/products/rhel10/profiles/anssi_bp28_minimal.profile @@ -9,8 +9,7 @@ metadata: title: 'ANSSI-BP-028 (minimal)' description: |- - This is a draft profile for experimental purposes. - This draft profile contains configurations that align to ANSSI-BP-028 v2.0 at the minimal hardening level. + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the minimal hardening level. ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. diff --git a/products/rhel10/profiles/default.profile b/products/rhel10/profiles/default.profile index 4d9b46867bc6..0c4878a9e7d0 100644 --- a/products/rhel10/profiles/default.profile +++ b/products/rhel10/profiles/default.profile @@ -45,3 +45,5 @@ selections: - file_etc_security_opasswd - sshd_use_strong_macs - configure_ssh_crypto_policy + - package_dnsmasq_removed + - chrony_set_nts diff --git a/products/rhel10/profiles/e8.profile b/products/rhel10/profiles/e8.profile index 05d7fbf6c281..641aec5d2e1e 100644 --- a/products/rhel10/profiles/e8.profile +++ b/products/rhel10/profiles/e8.profile @@ -11,9 +11,7 @@ reference: https://www.cyber.gov.au/acsc/view-all-content/publications/hardening title: 'Australian Cyber Security Centre (ACSC) Essential Eight' description: |- - This is a draft profile for experimental purposes. - - This draft profile contains configuration checks for Red Hat Enterprise Linux 10 + This profile contains configuration checks for Red Hat Enterprise Linux 10 that align to the Australian Cyber Security Centre (ACSC) Essential Eight. A copy of the Essential Eight in Linux Environments guide can be found at the diff --git a/products/rhel10/profiles/hipaa.profile b/products/rhel10/profiles/hipaa.profile index 30635f497846..f40b05e3e3ee 100644 --- a/products/rhel10/profiles/hipaa.profile +++ b/products/rhel10/profiles/hipaa.profile @@ -10,8 +10,6 @@ reference: https://www.hhs.gov/hipaa/for-professionals/index.html title: 'Health Insurance Portability and Accountability Act (HIPAA)' description: |- - This is a draft profile for experimental purposes. - The HIPAA Security Rule establishes U.S. national standards to protect individuals's electronic personal health information that is created, received, used, or maintained by a covered entity. The Security Rule requires appropriate @@ -19,7 +17,7 @@ description: |- confidentiality, integrity, and security of electronic protected health information. - This draft profile configures Red Hat Enterprise Linux 10 to the HIPAA Security + This profile configures Red Hat Enterprise Linux 10 to the HIPAA Security Rule identified for securing of electronic protected health information. Use of this profile in no way guarantees or makes claims against legal compliance against the HIPAA Security Rule(s). diff --git a/products/rhel10/profiles/ism_o.profile b/products/rhel10/profiles/ism_o.profile index f4dac5f9b53d..36d5b18cedda 100644 --- a/products/rhel10/profiles/ism_o.profile +++ b/products/rhel10/profiles/ism_o.profile @@ -14,7 +14,7 @@ reference: https://www.cyber.gov.au/ism title: 'Australian Cyber Security Centre (ACSC) ISM Official - Base' description: |- - This draft profile contains configuration checks for Red Hat Enterprise Linux 10 + This profile contains configuration checks for Red Hat Enterprise Linux 10 that align to the Australian Cyber Security Centre (ACSC) Information Security Manual (ISM). The ISM uses a risk-based approach to cyber security. This profile provides a guide to aligning diff --git a/products/rhel10/profiles/ism_o_secret.profile b/products/rhel10/profiles/ism_o_secret.profile index 9ced033943f7..f5d6bba01fe0 100644 --- a/products/rhel10/profiles/ism_o_secret.profile +++ b/products/rhel10/profiles/ism_o_secret.profile @@ -14,9 +14,7 @@ reference: https://www.cyber.gov.au/ism title: 'Australian Cyber Security Centre (ACSC) ISM Official - Secret' description: |- - This is a draft profile for experimental purposes. - - This draft profile contains configuration checks for Red Hat Enterprise Linux 10 + This profile contains configuration checks for Red Hat Enterprise Linux 10 that align to the Australian Cyber Security Centre (ACSC) Information Security Manual (ISM). The ISM uses a risk-based approach to cyber security. This profile provides a guide to aligning diff --git a/products/rhel10/profiles/ism_o_top_secret.profile b/products/rhel10/profiles/ism_o_top_secret.profile index a2c5304b3b60..b48077269c05 100644 --- a/products/rhel10/profiles/ism_o_top_secret.profile +++ b/products/rhel10/profiles/ism_o_top_secret.profile @@ -14,7 +14,7 @@ reference: https://www.cyber.gov.au/ism title: 'Australian Cyber Security Centre (ACSC) ISM Official - Top Secret' description: |- - This draft profile contains configuration checks for Red Hat Enterprise Linux 10 + This profile contains configuration checks for Red Hat Enterprise Linux 10 that align to the Australian Cyber Security Centre (ACSC) Information Security Manual (ISM). The ISM uses a risk-based approach to cyber security. This profile provides a guide to aligning diff --git a/products/rhel10/profiles/ospp.profile b/products/rhel10/profiles/ospp.profile index 7a27e4534707..b5a346ad14ba 100644 --- a/products/rhel10/profiles/ospp.profile +++ b/products/rhel10/profiles/ospp.profile @@ -9,11 +9,10 @@ metadata: reference: https://www.niap-ccevs.org/Profile/Info.cfm?PPID=469&id=469 -title: 'DRAFT - Protection Profile for General Purpose Operating Systems' +title: 'Protection Profile for General Purpose Operating Systems' description: |- - This is draft profile is based on the Red Hat Enterprise Linux 9 Common Criteria Guidance as - guidance for Red Hat Enterprise Linux 10 was not available at the time of release. + This profile is based on the Red Hat Enterprise Linux 10 Common Criteria Guidance. Where appropriate, CNSSI 1253 or DoD-specific values are used for configuration, based on Configuration Annex to the OSPP. diff --git a/products/rhel10/profiles/pci-dss.profile b/products/rhel10/profiles/pci-dss.profile index db0c16987250..70e52f3f6c9b 100644 --- a/products/rhel10/profiles/pci-dss.profile +++ b/products/rhel10/profiles/pci-dss.profile @@ -13,14 +13,12 @@ reference: https://docs-prv.pcisecuritystandards.org/PCI%20DSS/Standard/PCI-DSS- title: 'PCI-DSS v4.0.1 Control Baseline for Red Hat Enterprise Linux 10' description: |- - This is a draft profile for experimental purposes. - Payment Card Industry - Data Security Standard (PCI-DSS) is a set of security standards designed to ensure the secure handling of payment card data, with the goal of preventing data breaches and protecting sensitive financial information. - This draft profile ensures Red Hat Enterprise Linux 10 is configured in alignment + This profile ensures Red Hat Enterprise Linux 10 is configured in alignment with PCI-DSS v4.0.1 requirements. selections: diff --git a/products/rhel8/controls/cis_rhel8.yml b/products/rhel8/controls/cis_rhel8.yml index cbe5d4d6454e..8630325d4f10 100644 --- a/products/rhel8/controls/cis_rhel8.yml +++ b/products/rhel8/controls/cis_rhel8.yml @@ -379,9 +379,14 @@ controls: levels: - l1_server - l1_workstation - status: manual - related_rules: + status: partial + rules: - ensure_redhat_gpgkey_installed + notes: > + In CIS Benchmark, the requirement is manual, because of GPG keys for 3rd party repositories. + But, add the rule ensure_redhat_gpgkey_installed to the profile because the requirement 1.2.1.2 + adds ensure_gpgcheck_never_disabled which requires GPG key checking. If the Red Hat + GPG key wouldn't be installed, people won't be able to install any RPM package using dnf. - id: 1.2.1.2 title: Ensure gpgcheck is configured (Automated) @@ -740,7 +745,8 @@ controls: rules: - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_banners + - dconf_login_banner_text=cis_banners + - dconf_login_banner_contents=cis_default - id: 1.8.2 title: Ensure GDM disable-user-list is configured (Automated) @@ -860,6 +866,8 @@ controls: - l1_workstation status: automated rules: + - service_dnsmasq_disabled + related_rules: - package_dnsmasq_removed - id: 2.1.7 @@ -2076,7 +2084,8 @@ controls: - l2_workstation status: automated rules: - - accounts_passwords_pam_faillock_deny_root + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - var_accounts_passwords_pam_faillock_root_unlock_time=60 - id: 5.3.3.2.1 title: Ensure password number of changed characters is configured (Automated) diff --git a/products/rhel8/controls/nist_800_53.yml b/products/rhel8/controls/nist_800_53.yml new file mode 100644 index 000000000000..182b67f2aac8 --- /dev/null +++ b/products/rhel8/controls/nist_800_53.yml @@ -0,0 +1,15 @@ +policy: NIST 800-53 Revision 5 (RHEL8) +title: NIST Special Publication 800-53 Revision 5 for RHEL8 +id: nist_800_53 +version: Revision 5 +source: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +product: rhel8 +controls_dir: nist_800_53 +levels: + - id: low + - id: moderate + inherits_from: + - low + - id: high + inherits_from: + - moderate diff --git a/products/rhel8/controls/nist_800_53/ac.yml b/products/rhel8/controls/nist_800_53/ac.yml new file mode 100644 index 000000000000..391442a9f880 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ac.yml @@ -0,0 +1,848 @@ +# NIST 800-53 AC Family: Access Control +controls: + - id: ac-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ac-2 + title: Account Management + levels: + - low + rules: [] + status: pending + - id: ac-2.1 + title: Automated System Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.2 + title: Automated Temporary and Emergency Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.3 + title: Disable Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-2.4 + title: Automated Audit Actions + levels: + - moderate + rules: [] + status: pending + - id: ac-2.5 + title: Inactivity Logout + levels: + - moderate + rules: + - accounts_tmout + - inactivity_timeout_value=15_minutes + - no_invalid_shell_accounts_unlocked + - no_password_auth_for_systemaccounts + - no_shelllogin_for_systemaccounts + - var_accounts_tmout=15_min + status: automated + - id: ac-2.6 + title: Dynamic Privilege Management + rules: [] + status: pending + - id: ac-2.7 + title: Privileged User Accounts + rules: [] + status: pending + - id: ac-2.8 + title: Dynamic Account Management + rules: [] + status: pending + - id: ac-2.9 + title: Restrictions on Use of Shared and Group Accounts + rules: [] + status: pending + - id: ac-2.10 + title: Shared and Group Account Credential Change + rules: [] + status: pending + - id: ac-2.11 + title: Usage Conditions + levels: + - high + rules: [] + status: pending + - id: ac-2.12 + title: Account Monitoring for Atypical Usage + levels: + - high + rules: [] + status: pending + - id: ac-2.13 + title: Disable Accounts for High-risk Individuals + levels: + - moderate + rules: [] + status: pending + - id: ac-3 + title: Access Enforcement + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_umask_root + - audit_rules_immutable + - dir_perms_world_writable_sticky_bits + - ensure_pam_wheel_group_empty + - file_at_allow_exists + - file_at_deny_not_exist + - file_cron_allow_exists + - file_cron_deny_not_exist + - file_groupowner_at_allow + - file_groupowner_backup_etc_group + - file_groupowner_backup_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - file_groupowner_cron_allow + - file_groupowner_cron_d + - file_groupowner_cron_daily + - file_groupowner_cron_hourly + - file_groupowner_cron_monthly + - file_groupowner_cron_weekly + - file_groupowner_cron_yearly + - file_groupowner_crontab + - file_groupowner_etc_group + - file_groupowner_etc_gshadow + - file_groupowner_etc_issue + - file_groupowner_etc_issue_net + - file_groupowner_etc_motd + - file_groupowner_etc_passwd + - file_groupowner_etc_security_opasswd + - file_groupowner_etc_security_opasswd_old + - file_groupowner_etc_shadow + - file_groupowner_etc_shells + - file_groupowner_etc_sysconfig_sshd + - file_groupowner_grub2_cfg + - file_groupowner_sshd_config + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_at_allow + - file_owner_backup_etc_group + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_owner_backup_etc_shadow + - file_owner_cron_allow + - file_owner_cron_d + - file_owner_cron_daily + - file_owner_cron_hourly + - file_owner_cron_monthly + - file_owner_cron_weekly + - file_owner_cron_yearly + - file_owner_crontab + - file_owner_etc_group + - file_owner_etc_gshadow + - file_owner_etc_issue + - file_owner_etc_issue_net + - file_owner_etc_motd + - file_owner_etc_passwd + - file_owner_etc_security_opasswd + - file_owner_etc_security_opasswd_old + - file_owner_etc_shadow + - file_owner_etc_shells + - file_owner_etc_sysconfig_sshd + - file_owner_grub2_cfg + - file_owner_sshd_config + - file_owner_user_cfg + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_at_allow + - file_permissions_backup_etc_group + - file_permissions_backup_etc_gshadow + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_shadow + - file_permissions_cron_allow + - file_permissions_cron_d + - file_permissions_cron_daily + - file_permissions_cron_hourly + - file_permissions_cron_monthly + - file_permissions_cron_weekly + - file_permissions_cron_yearly + - file_permissions_crontab + - file_permissions_etc_group + - file_permissions_etc_gshadow + - file_permissions_etc_issue + - file_permissions_etc_issue_net + - file_permissions_etc_motd + - file_permissions_etc_passwd + - file_permissions_etc_security_opasswd + - file_permissions_etc_security_opasswd_old + - file_permissions_etc_shadow + - file_permissions_etc_shells + - file_permissions_etc_sysconfig_sshd + - file_permissions_grub2_cfg + - file_permissions_sshd_config + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_unauthorized_world_writable + - file_permissions_user_cfg + - grub2_enable_selinux + - grub2_password + - grub2_uefi_password + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_home_nodev + - mount_option_home_nosuid + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - mount_option_var_log_audit_nodev + - mount_option_var_log_audit_noexec + - mount_option_var_log_audit_nosuid + - mount_option_var_log_nodev + - mount_option_var_log_noexec + - mount_option_var_log_nosuid + - mount_option_var_nodev + - mount_option_var_nosuid + - mount_option_var_tmp_nodev + - mount_option_var_tmp_noexec + - mount_option_var_tmp_nosuid + - package_libselinux_installed + - package_mcstrans_removed + - package_setroubleshoot_removed + - rsyslog_filecreatemode + - rsyslog_files_groupownership + - rsyslog_files_ownership + - rsyslog_files_permissions + - selinux_not_disabled + - selinux_policytype + - sshd_limit_user_access + - sysctl_fs_protected_hardlinks + - sysctl_fs_protected_symlinks + - use_pam_wheel_group_for_su + - var_accounts_user_umask=027 + - var_pam_wheel_group_for_su=cis + - var_selinux_policy_name=targeted + status: automated + - id: ac-3.1 + title: Restricted Access to Privileged Functions + rules: [] + status: pending + - id: ac-3.2 + title: Dual Authorization + rules: [] + status: pending + - id: ac-3.3 + title: Mandatory Access Control + rules: [] + status: pending + - id: ac-3.4 + title: Discretionary Access Control + rules: [] + status: pending + - id: ac-3.5 + title: Security-relevant Information + rules: [] + status: pending + - id: ac-3.6 + title: Protection of User and System Information + rules: [] + status: pending + - id: ac-3.7 + title: Role-based Access Control + rules: [] + status: pending + - id: ac-3.8 + title: Revocation of Access Authorizations + rules: [] + status: pending + - id: ac-3.9 + title: Controlled Release + rules: [] + status: pending + - id: ac-3.10 + title: Audited Override of Access Control Mechanisms + rules: [] + status: pending + - id: ac-3.11 + title: Restrict Access to Specific Information Types + rules: [] + status: pending + - id: ac-3.12 + title: Assert and Enforce Application Access + rules: [] + status: pending + - id: ac-3.13 + title: Attribute-based Access Control + rules: [] + status: pending + - id: ac-3.14 + title: Individual Access + rules: [] + status: pending + - id: ac-3.15 + title: Discretionary and Mandatory Access Control + rules: [] + status: pending + - id: ac-4 + title: Information Flow Enforcement + levels: + - moderate + rules: [] + status: pending + - id: ac-4.1 + title: Object Security and Privacy Attributes + rules: [] + status: pending + - id: ac-4.2 + title: Processing Domains + rules: [] + status: pending + - id: ac-4.3 + title: Dynamic Information Flow Control + rules: [] + status: pending + - id: ac-4.4 + title: Flow Control of Encrypted Information + levels: + - high + rules: [] + status: pending + - id: ac-4.5 + title: Embedded Data Types + rules: [] + status: pending + - id: ac-4.6 + title: Metadata + rules: [] + status: pending + - id: ac-4.7 + title: One-way Flow Mechanisms + rules: [] + status: pending + - id: ac-4.8 + title: Security and Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.9 + title: Human Reviews + rules: [] + status: pending + - id: ac-4.10 + title: Enable and Disable Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.11 + title: Configuration of Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.12 + title: Data Type Identifiers + rules: [] + status: pending + - id: ac-4.13 + title: Decomposition into Policy-relevant Subcomponents + rules: [] + status: pending + - id: ac-4.14 + title: Security or Privacy Policy Filter Constraints + rules: [] + status: pending + - id: ac-4.15 + title: Detection of Unsanctioned Information + rules: [] + status: pending + - id: ac-4.16 + title: Information Transfers on Interconnected Systems + rules: [] + status: pending + - id: ac-4.17 + title: Domain Authentication + rules: [] + status: pending + - id: ac-4.18 + title: Security Attribute Binding + rules: [] + status: pending + - id: ac-4.19 + title: Validation of Metadata + rules: [] + status: pending + - id: ac-4.20 + title: Approved Solutions + rules: [] + status: pending + - id: ac-4.21 + title: Physical or Logical Separation of Information Flows + rules: [] + status: pending + - id: ac-4.22 + title: Access Only + rules: [] + status: pending + - id: ac-4.23 + title: Modify Non-releasable Information + rules: [] + status: pending + - id: ac-4.24 + title: Internal Normalized Format + rules: [] + status: pending + - id: ac-4.25 + title: Data Sanitization + rules: [] + status: pending + - id: ac-4.26 + title: Audit Filtering Actions + rules: [] + status: pending + - id: ac-4.27 + title: Redundant/Independent Filtering Mechanisms + rules: [] + status: pending + - id: ac-4.28 + title: Linear Filter Pipelines + rules: [] + status: pending + - id: ac-4.29 + title: Filter Orchestration Engines + rules: [] + status: pending + - id: ac-4.30 + title: Filter Mechanisms Using Multiple Processes + rules: [] + status: pending + - id: ac-4.31 + title: Failed Content Transfer Prevention + rules: [] + status: pending + - id: ac-4.32 + title: Process Requirements for Information Transfer + rules: [] + status: pending + - id: ac-5 + title: Separation of Duties + levels: + - moderate + rules: [] + status: pending + - id: ac-6 + title: Least Privilege + levels: + - moderate + rules: + - sshd_disable_root_login + - sudo_add_use_pty + - sudo_remove_no_authenticate + - sudo_remove_nopasswd + status: automated + - id: ac-6.1 + title: Authorize Access to Security Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.2 + title: Non-privileged Access for Nonsecurity Functions + levels: + - moderate + rules: + - package_sudo_installed + status: automated + - id: ac-6.3 + title: Network Access to Privileged Commands + levels: + - high + rules: [] + status: pending + - id: ac-6.4 + title: Separate Processing Domains + rules: [] + status: pending + - id: ac-6.5 + title: Privileged Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-6.6 + title: Privileged Access by Non-organizational Users + rules: [] + status: pending + - id: ac-6.7 + title: Review of User Privileges + levels: + - moderate + rules: [] + status: pending + - id: ac-6.8 + title: Privilege Levels for Code Execution + rules: [] + status: pending + - id: ac-6.9 + title: Log Use of Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.10 + title: Prohibit Non-privileged Users from Executing Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-7 + title: Unsuccessful Logon Attempts + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - accounts_passwords_pam_faillock_deny + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - accounts_passwords_pam_faillock_unlock_time_with_zero + - var_accounts_passwords_pam_faillock_deny=5 + - var_accounts_passwords_pam_faillock_dir=run + - var_accounts_passwords_pam_faillock_root_unlock_time=60 + - var_accounts_passwords_pam_faillock_unlock_time=900 + status: automated + - id: ac-7.1 + title: Automatic Account Lock + rules: [] + status: pending + - id: ac-7.2 + title: Purge or Wipe Mobile Device + rules: [] + status: pending + - id: ac-7.3 + title: Biometric Attempt Limiting + rules: [] + status: pending + - id: ac-7.4 + title: Use of Alternate Authentication Factor + rules: [] + status: pending + - id: ac-8 + title: System Use Notification + levels: + - low + rules: + - dconf_gnome_banner_enabled + - dconf_gnome_login_banner_text + status: automated + - id: ac-9 + title: Previous Logon Notification + rules: [] + status: pending + - id: ac-9.1 + title: Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.2 + title: Successful and Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.3 + title: Notification of Account Changes + rules: [] + status: pending + - id: ac-9.4 + title: Additional Logon Information + rules: [] + status: pending + - id: ac-10 + title: Concurrent Session Control + levels: + - high + rules: [] + status: pending + - id: ac-11 + title: Device Lock + levels: + - moderate + rules: + - dconf_gnome_screensaver_idle_delay + - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_user_locks + - dconf_gnome_session_idle_user_locks + - var_screensaver_lock_delay=5_seconds + status: automated + - id: ac-11.1 + title: Pattern-hiding Displays + levels: + - moderate + rules: [] + status: pending + - id: ac-12 + title: Session Termination + levels: + - moderate + rules: [] + status: pending + - id: ac-12.1 + title: User-initiated Logouts + rules: [] + status: pending + - id: ac-12.2 + title: Termination Message + rules: [] + status: pending + - id: ac-12.3 + title: Timeout Warning Message + rules: [] + status: pending + - id: ac-13 + title: Supervision and Review — Access Control + rules: [] + status: pending + - id: ac-14 + title: Permitted Actions Without Identification or Authentication + levels: + - low + rules: [] + status: pending + - id: ac-14.1 + title: Necessary Uses + rules: [] + status: pending + - id: ac-15 + title: Automated Marking + rules: [] + status: pending + - id: ac-16 + title: Security and Privacy Attributes + rules: [] + status: pending + - id: ac-16.1 + title: Dynamic Attribute Association + rules: [] + status: pending + - id: ac-16.2 + title: Attribute Value Changes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.3 + title: Maintenance of Attribute Associations by System + rules: [] + status: pending + - id: ac-16.4 + title: Association of Attributes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.5 + title: Attribute Displays on Objects to Be Output + rules: [] + status: pending + - id: ac-16.6 + title: Maintenance of Attribute Association + rules: [] + status: pending + - id: ac-16.7 + title: Consistent Attribute Interpretation + rules: [] + status: pending + - id: ac-16.8 + title: Association Techniques and Technologies + rules: [] + status: pending + - id: ac-16.9 + title: Attribute Reassignment — Regrading Mechanisms + rules: [] + status: pending + - id: ac-16.10 + title: Attribute Configuration by Authorized Individuals + rules: [] + status: pending + - id: ac-17 + title: Remote Access + levels: + - low + rules: + - configure_custom_crypto_policy_cis + - configure_ssh_crypto_policy + status: automated + - id: ac-17.1 + title: Monitoring and Control + levels: + - moderate + rules: [] + status: pending + - id: ac-17.2 + title: Protection of Confidentiality and Integrity Using Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-17.3 + title: Managed Access Control Points + levels: + - moderate + rules: [] + status: pending + - id: ac-17.4 + title: Privileged Commands and Access + levels: + - moderate + rules: [] + status: pending + - id: ac-17.5 + title: Monitoring for Unauthorized Connections + rules: [] + status: pending + - id: ac-17.6 + title: Protection of Mechanism Information + rules: [] + status: pending + - id: ac-17.7 + title: Additional Protection for Security Function Access + rules: [] + status: pending + - id: ac-17.8 + title: Disable Nonsecure Network Protocols + rules: [] + status: pending + - id: ac-17.9 + title: Disconnect or Disable Access + rules: [] + status: pending + - id: ac-17.10 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: ac-18 + title: Wireless Access + levels: + - low + rules: + - wireless_disable_interfaces + status: automated + - id: ac-18.1 + title: Authentication and Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-18.2 + title: Monitoring Unauthorized Connections + rules: [] + status: pending + - id: ac-18.3 + title: Disable Wireless Networking + levels: + - moderate + rules: [] + status: pending + - id: ac-18.4 + title: Restrict Configurations by Users + levels: + - high + rules: [] + status: pending + - id: ac-18.5 + title: Antennas and Transmission Power Levels + levels: + - high + rules: [] + status: pending + - id: ac-19 + title: Access Control for Mobile Devices + levels: + - low + rules: [] + status: pending + - id: ac-19.1 + title: Use of Writable and Portable Storage Devices + rules: [] + status: pending + - id: ac-19.2 + title: Use of Personally Owned Portable Storage Devices + rules: [] + status: pending + - id: ac-19.3 + title: Use of Portable Storage Devices with No Identifiable Owner + rules: [] + status: pending + - id: ac-19.4 + title: Restrictions for Classified Information + rules: [] + status: pending + - id: ac-19.5 + title: Full Device or Container-based Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-20 + title: Use of External Systems + levels: + - low + rules: [] + status: pending + - id: ac-20.1 + title: Limits on Authorized Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.2 + title: Portable Storage Devices — Restricted Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.3 + title: Non-organizationally Owned Systems — Restricted Use + rules: [] + status: pending + - id: ac-20.4 + title: Network Accessible Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-20.5 + title: Portable Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-21 + title: Information Sharing + levels: + - moderate + rules: [] + status: pending + - id: ac-21.1 + title: Automated Decision Support + rules: [] + status: pending + - id: ac-21.2 + title: Information Search and Retrieval + rules: [] + status: pending + - id: ac-22 + title: Publicly Accessible Content + levels: + - low + rules: [] + status: pending + - id: ac-23 + title: Data Mining Protection + rules: [] + status: pending + - id: ac-24 + title: Access Control Decisions + rules: [] + status: pending + - id: ac-24.1 + title: Transmit Access Authorization Information + rules: [] + status: pending + - id: ac-24.2 + title: No User or Process Identity + rules: [] + status: pending + - id: ac-25 + title: Reference Monitor + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/at.yml b/products/rhel8/controls/nist_800_53/at.yml new file mode 100644 index 000000000000..80211cdb5591 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/at.yml @@ -0,0 +1,82 @@ +# NIST 800-53 AT Family: Awareness and Training +controls: + - id: at-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: at-2 + title: Literacy Training and Awareness + levels: + - low + rules: [] + status: pending + - id: at-2.1 + title: Practical Exercises + rules: [] + status: pending + - id: at-2.2 + title: Insider Threat + levels: + - low + rules: [] + status: pending + - id: at-2.3 + title: Social Engineering and Mining + levels: + - moderate + rules: [] + status: pending + - id: at-2.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-2.5 + title: Advanced Persistent Threat + rules: [] + status: pending + - id: at-2.6 + title: Cyber Threat Environment + rules: [] + status: pending + - id: at-3 + title: Role-based Training + levels: + - low + rules: [] + status: pending + - id: at-3.1 + title: Environmental Controls + rules: [] + status: pending + - id: at-3.2 + title: Physical Security Controls + rules: [] + status: pending + - id: at-3.3 + title: Practical Exercises + rules: [] + status: pending + - id: at-3.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-3.5 + title: Processing Personally Identifiable Information + rules: [] + status: pending + - id: at-4 + title: Training Records + levels: + - low + rules: [] + status: pending + - id: at-5 + title: Contacts with Security Groups and Associations + rules: [] + status: pending + - id: at-6 + title: Training Feedback + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/au.yml b/products/rhel8/controls/nist_800_53/au.yml new file mode 100644 index 000000000000..013f87f2f85d --- /dev/null +++ b/products/rhel8/controls/nist_800_53/au.yml @@ -0,0 +1,478 @@ +# NIST 800-53 AU Family: Audit and Accountability +controls: + - id: au-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: au-2 + title: Event Logging + levels: + - low + rules: + - aide_build_database + - aide_periodic_cron_checking + - audit_rules_execution_chacl + - audit_rules_execution_chcon + - audit_rules_execution_setfacl + - audit_rules_privileged_commands_usermod + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - auditd_data_retention_admin_space_left_action + - auditd_data_retention_space_left_action + - grub2_audit_backlog_limit_argument + - journald_disable_forward_to_syslog + - package_aide_installed + - package_audit-libs_installed + - package_audit_installed + - package_systemd-journal-remote_installed + - rsyslog_nolisten + - service_auditd_enabled + - service_rsyslog_enabled + - service_systemd-journal-upload_enabled + - service_systemd-journald_enabled + - socket_systemd-journal-remote_disabled + - var_audit_backlog_limit=8192 + - var_auditd_admin_space_left_action=cis_rhel8 + - var_auditd_space_left_action=cis_rhel8 + status: automated + - id: au-2.1 + title: Compilation of Audit Records from Multiple Sources + rules: [] + status: pending + - id: au-2.2 + title: Selection of Audit Events by Component + rules: [] + status: pending + - id: au-2.3 + title: Reviews and Updates + rules: [] + status: pending + - id: au-2.4 + title: Privileged Functions + rules: [] + status: pending + - id: au-3 + title: Content of Audit Records + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_mac_modification + - audit_rules_mac_modification_usr_share + - audit_rules_networkconfig_modification + - audit_rules_networkconfig_modification_network_scripts + - audit_rules_privileged_commands + - audit_rules_privileged_commands_kmod + - audit_rules_session_events_btmp + - audit_rules_session_events_utmp + - audit_rules_session_events_wtmp + - audit_rules_suid_auid_privilege_function + - audit_rules_sysadmin_actions + - audit_rules_time_adjtimex + - audit_rules_time_clock_settime + - audit_rules_time_settimeofday + - audit_rules_time_watch_localtime + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - chronyd_specify_remote_server + - directory_permissions_var_log_audit + - file_groupownership_audit_binaries + - file_ownership_var_log_audit_stig + - file_permissions_audit_binaries + - journald_storage + - package_chrony_installed + - sshd_set_loglevel_verbose + - sshd_set_max_auth_tries + - sudo_custom_logfile + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_default_log_martians + - sshd_max_auth_tries_value=4 + - var_multiple_time_servers=rhel + status: automated + - id: au-3.1 + title: Additional Audit Information + levels: + - moderate + rules: [] + status: pending + - id: au-3.2 + title: Centralized Management of Planned Audit Record Content + rules: [] + status: pending + - id: au-3.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: au-4 + title: Audit Log Storage Capacity + levels: + - low + rules: + - journald_compress + status: automated + - id: au-4.1 + title: Transfer to Alternate Storage + rules: [] + status: pending + - id: au-5 + title: Response to Audit Logging Process Failures + levels: + - low + rules: + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - var_auditd_disk_error_action=cis_rhel8 + - var_auditd_disk_full_action=cis_rhel8 + status: automated + - id: au-5.1 + title: Storage Capacity Warning + levels: + - high + rules: [] + status: pending + - id: au-5.2 + title: Real-time Alerts + levels: + - high + rules: [] + status: pending + - id: au-5.3 + title: Configurable Traffic Volume Thresholds + rules: [] + status: pending + - id: au-5.4 + title: Shutdown on Failure + rules: [] + status: pending + - id: au-5.5 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-6 + title: Audit Record Review, Analysis, and Reporting + levels: + - low + rules: [] + status: pending + - id: au-6.1 + title: Automated Process Integration + levels: + - moderate + rules: [] + status: pending + - id: au-6.2 + title: Automated Security Alerts + rules: [] + status: pending + - id: au-6.3 + title: Correlate Audit Record Repositories + levels: + - moderate + rules: [] + status: pending + - id: au-6.4 + title: Central Review and Analysis + rules: [] + status: pending + - id: au-6.5 + title: Integrated Analysis of Audit Records + levels: + - high + rules: [] + status: pending + - id: au-6.6 + title: Correlation with Physical Monitoring + levels: + - high + rules: [] + status: pending + - id: au-6.7 + title: Permitted Actions + rules: [] + status: pending + - id: au-6.8 + title: Full Text Analysis of Privileged Commands + rules: [] + status: pending + - id: au-6.9 + title: Correlation with Information from Nontechnical Sources + rules: [] + status: pending + - id: au-6.10 + title: Audit Level Adjustment + rules: [] + status: pending + - id: au-7 + title: Audit Record Reduction and Report Generation + levels: + - moderate + rules: [] + status: pending + - id: au-7.1 + title: Automatic Processing + levels: + - moderate + rules: [] + status: pending + - id: au-7.2 + title: Automatic Sort and Search + rules: [] + status: pending + - id: au-8 + title: Time Stamps + levels: + - low + rules: + - auditd_data_retention_max_log_file + - auditd_data_retention_max_log_file_action + - var_auditd_max_log_file=8 + - var_auditd_max_log_file_action=keep_logs + status: automated + - id: au-8.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: au-8.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: au-9 + title: Protection of Audit Information + levels: + - low + rules: + - audit_rules_immutable + - file_groupownership_audit_configuration + - file_ownership_audit_binaries + - file_ownership_audit_configuration + status: automated + - id: au-9.1 + title: Hardware Write-once Media + rules: [] + status: pending + - id: au-9.2 + title: Store on Separate Physical Systems or Components + levels: + - high + rules: [] + status: pending + - id: au-9.3 + title: Cryptographic Protection + levels: + - high + rules: + - aide_check_audit_tools + status: automated + - id: au-9.4 + title: Access by Subset of Privileged Users + levels: + - moderate + rules: + - file_group_ownership_var_log_audit + - file_permissions_var_log_audit + status: automated + - id: au-9.5 + title: Dual Authorization + rules: [] + status: pending + - id: au-9.6 + title: Read-only Access + rules: [] + status: pending + - id: au-9.7 + title: Store on Component with Different Operating System + rules: [] + status: pending + - id: au-10 + title: Non-repudiation + levels: + - high + rules: [] + status: pending + - id: au-10.1 + title: Association of Identities + rules: [] + status: pending + - id: au-10.2 + title: Validate Binding of Information Producer Identity + rules: [] + status: pending + - id: au-10.3 + title: Chain of Custody + rules: [] + status: pending + - id: au-10.4 + title: Validate Binding of Information Reviewer Identity + rules: [] + status: pending + - id: au-10.5 + title: Digital Signatures + rules: [] + status: pending + - id: au-11 + title: Audit Record Retention + levels: + - low + rules: [] + status: pending + - id: au-11.1 + title: Long-term Retrieval Capability + rules: [] + status: pending + - id: au-12 + title: Audit Record Generation + levels: + - low + rules: + - audit_rules_continue_loading + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_execution_chcon + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_unlinkat + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_media_export + - audit_rules_privileged_commands_kmod + - audit_rules_privileged_commands_usermod + - audit_rules_sysadmin_actions + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - audit_sudo_log_events + - file_permissions_audit_configuration + - grub2_audit_argument + - service_auditd_enabled + status: automated + - id: au-12.1 + title: System-wide and Time-correlated Audit Trail + levels: + - high + rules: [] + status: pending + - id: au-12.2 + title: Standardized Formats + rules: [] + status: pending + - id: au-12.3 + title: Changes by Authorized Individuals + levels: + - high + rules: [] + status: pending + - id: au-12.4 + title: Query Parameter Audits of Personally Identifiable Information + rules: [] + status: pending + - id: au-13 + title: Monitoring for Information Disclosure + rules: [] + status: pending + - id: au-13.1 + title: Use of Automated Tools + rules: [] + status: pending + - id: au-13.2 + title: Review of Monitored Sites + rules: [] + status: pending + - id: au-13.3 + title: Unauthorized Replication of Information + rules: [] + status: pending + - id: au-14 + title: Session Audit + rules: [] + status: pending + - id: au-14.1 + title: System Start-up + rules: [] + status: pending + - id: au-14.2 + title: Capture and Record Content + rules: [] + status: pending + - id: au-14.3 + title: Remote Viewing and Listening + rules: [] + status: pending + - id: au-15 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-16 + title: Cross-organizational Audit Logging + rules: [] + status: pending + - id: au-16.1 + title: Identity Preservation + rules: [] + status: pending + - id: au-16.2 + title: Sharing of Audit Information + rules: [] + status: pending + - id: au-16.3 + title: Disassociability + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/ca.yml b/products/rhel8/controls/nist_800_53/ca.yml new file mode 100644 index 000000000000..fd1a4f86bfb0 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ca.yml @@ -0,0 +1,160 @@ +# NIST 800-53 CA Family: Assessment, Authorization, and Monitoring +controls: + - id: ca-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ca-2 + title: Control Assessments + levels: + - low + rules: [] + status: pending + - id: ca-2.1 + title: Independent Assessors + levels: + - moderate + rules: [] + status: pending + - id: ca-2.2 + title: Specialized Assessments + levels: + - high + rules: [] + status: pending + - id: ca-2.3 + title: Leveraging Results from External Organizations + rules: [] + status: pending + - id: ca-3 + title: Information Exchange + levels: + - low + rules: [] + status: pending + - id: ca-3.1 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: ca-3.2 + title: Classified National Security System Connections + rules: [] + status: pending + - id: ca-3.3 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: ca-3.4 + title: Connections to Public Networks + rules: [] + status: pending + - id: ca-3.5 + title: Restrictions on External System Connections + rules: [] + status: pending + - id: ca-3.6 + title: Transfer Authorizations + levels: + - high + rules: [] + status: pending + - id: ca-3.7 + title: Transitive Information Exchanges + rules: [] + status: pending + - id: ca-4 + title: Security Certification + rules: [] + status: pending + - id: ca-5 + title: Plan of Action and Milestones + levels: + - low + rules: [] + status: pending + - id: ca-5.1 + title: Automation Support for Accuracy and Currency + rules: [] + status: pending + - id: ca-6 + title: Authorization + levels: + - low + rules: [] + status: pending + - id: ca-6.1 + title: Joint Authorization — Intra-organization + rules: [] + status: pending + - id: ca-6.2 + title: Joint Authorization — Inter-organization + rules: [] + status: pending + - id: ca-7 + title: Continuous Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.1 + title: Independent Assessment + levels: + - moderate + rules: [] + status: pending + - id: ca-7.2 + title: Types of Assessments + rules: [] + status: pending + - id: ca-7.3 + title: Trend Analyses + rules: [] + status: pending + - id: ca-7.4 + title: Risk Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.5 + title: Consistency Analysis + rules: [] + status: pending + - id: ca-7.6 + title: Automation Support for Monitoring + rules: [] + status: pending + - id: ca-8 + title: Penetration Testing + levels: + - high + rules: [] + status: pending + - id: ca-8.1 + title: Independent Penetration Testing Agent or Team + levels: + - high + rules: [] + status: pending + - id: ca-8.2 + title: Red Team Exercises + rules: [] + status: pending + - id: ca-8.3 + title: Facility Penetration Testing + rules: [] + status: pending + - id: ca-9 + title: Internal System Connections + levels: + - low + rules: + - firewalld-backend + - package_firewalld_installed + status: automated + - id: ca-9.1 + title: Compliance Checks + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/cm.yml b/products/rhel8/controls/nist_800_53/cm.yml new file mode 100644 index 000000000000..589fb62b5eff --- /dev/null +++ b/products/rhel8/controls/nist_800_53/cm.yml @@ -0,0 +1,566 @@ +# NIST 800-53 CM Family: Configuration Management +controls: + - id: cm-1 + title: Policy and Procedures + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - account_unique_id + - account_unique_name + - accounts_maximum_age_login_defs + - accounts_no_uid_except_zero + - accounts_password_set_max_life_existing + - accounts_root_gid_zero + - accounts_root_path_dirs_no_write + - accounts_user_dot_group_ownership + - accounts_user_dot_user_ownership + - configure_custom_crypto_policy_cis + - disable_host_auth + - file_permission_user_bash_history + - file_permission_user_init_files + - gid_passwd_group_same + - group_unique_id + - group_unique_name + - groups_no_zero_gid_except_root + - no_forward_files + - no_netrc_files + - no_nologin_in_shells + - no_rhost_files + - package_cron_installed + - root_path_no_dot + - service_crond_enabled + - sshd_disable_empty_passwords + - sshd_disable_gssapi_auth + - sshd_disable_rhosts + - sshd_do_not_permit_user_env + - sshd_enable_pam + - sshd_enable_warning_banner_net + - sshd_set_idle_timeout + - sshd_set_keepalive + - sshd_set_max_sessions + - sshd_set_maxstartups + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv4_tcp_syncookies + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sshd_idle_timeout_value=5_minutes + - sysctl_net_ipv4_tcp_syncookies_value=enabled + - var_sshd_max_sessions=10 + - var_sshd_set_keepalive=1 + - var_sshd_set_maxstartups=10:30:60 + - var_user_initialization_files_regex=all_dotfiles + status: automated + - id: cm-2 + title: Baseline Configuration + levels: + - low + rules: [] + status: pending + - id: cm-2.1 + title: Reviews and Updates + rules: [] + status: pending + - id: cm-2.2 + title: Automation Support for Accuracy and Currency + levels: + - moderate + rules: [] + status: pending + - id: cm-2.3 + title: Retention of Previous Configurations + levels: + - moderate + rules: [] + status: pending + - id: cm-2.4 + title: Unauthorized Software + rules: [] + status: pending + - id: cm-2.5 + title: Authorized Software + rules: [] + status: pending + - id: cm-2.6 + title: Development and Test Environments + rules: [] + status: pending + - id: cm-2.7 + title: Configure Systems and Components for High-risk Areas + levels: + - moderate + rules: [] + status: pending + - id: cm-3 + title: Configuration Change Control + levels: + - moderate + rules: [] + status: pending + - id: cm-3.1 + title: Automated Documentation, Notification, and Prohibition of Changes + levels: + - high + rules: [] + status: pending + - id: cm-3.2 + title: Testing, Validation, and Documentation of Changes + levels: + - moderate + rules: [] + status: pending + - id: cm-3.3 + title: Automated Change Implementation + rules: [] + status: pending + - id: cm-3.4 + title: Security and Privacy Representatives + levels: + - moderate + rules: [] + status: pending + - id: cm-3.5 + title: Automated Security Response + rules: [] + status: pending + - id: cm-3.6 + title: Cryptography Management + levels: + - high + rules: [] + status: pending + - id: cm-3.7 + title: Review System Changes + rules: [] + status: pending + - id: cm-3.8 + title: Prevent or Restrict Configuration Changes + rules: [] + status: pending + - id: cm-4 + title: Impact Analyses + levels: + - low + rules: [] + status: pending + - id: cm-4.1 + title: Separate Test Environments + levels: + - high + rules: [] + status: pending + - id: cm-4.2 + title: Verification of Controls + levels: + - moderate + rules: [] + status: pending + - id: cm-5 + title: Access Restrictions for Change + levels: + - low + rules: [] + status: pending + - id: cm-5.1 + title: Automated Access Enforcement and Audit Records + levels: + - high + rules: [] + status: pending + - id: cm-5.2 + title: Review System Changes + rules: [] + status: pending + - id: cm-5.3 + title: Signed Components + rules: [] + status: pending + - id: cm-5.4 + title: Dual Authorization + rules: [] + status: pending + - id: cm-5.5 + title: Privilege Limitation for Production and Operation + rules: [] + status: pending + - id: cm-5.6 + title: Limit Library Privileges + rules: [] + status: pending + - id: cm-5.7 + title: Automatic Implementation of Security Safeguards + rules: [] + status: pending + - id: cm-6 + title: Configuration Settings + levels: + - low + rules: + - accounts_password_pam_modules_in_authselect_profile + - accounts_password_pam_pwquality_password_auth + - accounts_password_pam_pwquality_system_auth + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_user_interactive_home_directory_exists + - audit_rules_media_export + - banner_etc_issue_cis + - banner_etc_issue_net_cis + - banner_etc_motd_cis + - coredump_disable_backtraces + - chronyd_run_as_chrony_user + - coredump_disable_storage + - dconf_db_up_to_date + - dconf_gnome_disable_user_list + - disable_host_auth + - enable_authselect + - disable_users_coredumps + - file_groupowner_efi_grub2_cfg + - file_groupowner_efi_user_cfg + - file_groupowner_grub2_cfg + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_efi_grub2_cfg + - file_owner_efi_user_cfg + - file_owner_grub2_cfg + - file_owner_user_cfg + - file_ownership_home_directories + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_efi_grub2_cfg + - file_permissions_efi_user_cfg + - file_permissions_grub2_cfg + - file_permissions_home_directories + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_user_cfg + - no_empty_passwords + - no_empty_passwords_etc_shadow + - no_files_or_dirs_ungroupowned + - no_files_or_dirs_unowned_by_user + - package_authselect_installed + - package_pam_installed + - package_pam_pwquality_installed + - package_rsync_removed + - package_rsyslog_installed + - package_samba_removed + - package_squid_removed + - partition_for_tmp + - partition_for_var_log + - service_nfs_disabled + - service_rpcbind_disabled + - sshd_disable_gssapi_auth + - sshd_set_login_grace_time + - sysctl_fs_suid_dumpable + - sysctl_kernel_kptr_restrict + - sysctl_kernel_randomize_va_space + - sysctl_kernel_yama_ptrace_scope + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_forwarding + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_forwarding + - sysctl_net_ipv4_conf_default_log_martians + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sysctl_net_ipv6_conf_default_forwarding + - cis_banner_text=cis + - dconf_login_banner_contents=cis_default + - dconf_login_banner_text=cis_banners + - sysctl_net_ipv4_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_all_log_martians_value=enabled + - sysctl_net_ipv4_conf_all_rp_filter_value=enabled + - sysctl_net_ipv4_conf_all_secure_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_default_forwarding_value=disabled + - sysctl_net_ipv4_conf_default_log_martians_value=enabled + - sysctl_net_ipv4_conf_default_rp_filter_value=enabled + - sysctl_net_ipv4_conf_default_secure_redirects_value=disabled + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled + - sysctl_net_ipv6_conf_all_accept_ra_value=disabled + - sysctl_net_ipv6_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_all_forwarding_value=disabled + - sysctl_net_ipv6_conf_default_accept_ra_value=disabled + - sysctl_net_ipv6_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_default_forwarding_value=disabled + - var_accounts_user_umask=027 + - var_authselect_profile=sssd + - var_sshd_set_login_grace_time=60 + status: automated + - id: cm-6.1 + title: Automated Management, Application, and Verification + levels: + - high + rules: [] + status: pending + - id: cm-6.2 + title: Respond to Unauthorized Changes + levels: + - high + rules: [] + status: pending + - id: cm-6.3 + title: Unauthorized Change Detection + rules: [] + status: pending + - id: cm-6.4 + title: Conformance Demonstration + rules: [] + status: pending + - id: cm-7 + title: Least Functionality + levels: + - low + rules: + - dconf_gnome_disable_autorun + - disable_weak_deps + - file_ownership_var_log_audit_stig + - gnome_gdm_disable_xdmcp + - has_nonlocal_mta + - kernel_module_atm_disabled + - kernel_module_can_disabled + - kernel_module_cramfs_disabled + - kernel_module_dccp_disabled + - kernel_module_firewire-core_disabled + - kernel_module_freevxfs_disabled + - kernel_module_hfs_disabled + - kernel_module_hfsplus_disabled + - kernel_module_jffs2_disabled + - kernel_module_overlayfs_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_squashfs_disabled + - kernel_module_tipc_disabled + - kernel_module_udf_disabled + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_tmp_nodev + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - package_bind_removed + - package_cyrus-imapd_removed + - package_dhcp_removed + - package_dovecot_removed + - package_ftp_removed + - package_gdm_removed + - package_httpd_removed + - package_net-snmp_removed + - package_nginx_removed + - package_openldap-clients_removed + - package_telnet-server_removed + - package_telnet_removed + - package_tftp-server_removed + - package_tftp_removed + - package_vsftpd_removed + - package_xinetd_removed + - package_ypbind_removed + - package_ypserv_removed + - partition_for_dev_shm + - partition_for_home + - partition_for_tmp + - partition_for_var + - partition_for_var_log + - partition_for_var_log_audit + - partition_for_var_tmp + - postfix_network_listening_disabled + - service_bluetooth_disabled + - service_cockpit_disabled + - service_cups_disabled + - service_dnsmasq_disabled + - sshd_disable_forwarding + - wireless_disable_interfaces + - xwayland_disabled + - var_postfix_inet_interfaces=loopback-only + status: automated + - id: cm-7.1 + title: Periodic Review + levels: + - moderate + rules: [] + status: pending + - id: cm-7.2 + title: Prevent Program Execution + levels: + - moderate + rules: [] + status: pending + - id: cm-7.3 + title: Registration Compliance + rules: [] + status: pending + - id: cm-7.4 + title: Unauthorized Software — Deny-by-exception + rules: [] + status: pending + - id: cm-7.5 + title: Authorized Software — Allow-by-exception + levels: + - moderate + rules: [] + status: pending + - id: cm-7.6 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: cm-7.7 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: cm-7.8 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: cm-7.9 + title: Prohibiting The Use of Unauthorized Hardware + rules: [] + status: pending + - id: cm-8 + title: System Component Inventory + levels: + - low + rules: [] + status: pending + - id: cm-8.1 + title: Updates During Installation and Removal + levels: + - moderate + rules: [] + status: pending + - id: cm-8.2 + title: Automated Maintenance + levels: + - high + rules: [] + status: pending + - id: cm-8.3 + title: Automated Unauthorized Component Detection + levels: + - moderate + rules: [] + status: pending + - id: cm-8.4 + title: Accountability Information + levels: + - high + rules: [] + status: pending + - id: cm-8.5 + title: No Duplicate Accounting of Components + rules: [] + status: pending + - id: cm-8.6 + title: Assessed Configurations and Approved Deviations + rules: [] + status: pending + - id: cm-8.7 + title: Centralized Repository + rules: [] + status: pending + - id: cm-8.8 + title: Automated Location Tracking + rules: [] + status: pending + - id: cm-8.9 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: cm-9 + title: Configuration Management Plan + levels: + - moderate + rules: [] + status: pending + - id: cm-9.1 + title: Assignment of Responsibility + rules: [] + status: pending + - id: cm-10 + title: Software Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: cm-10.1 + title: Open-source Software + rules: [] + status: pending + - id: cm-11 + title: User-installed Software + levels: + - low + rules: + - package_xorg-x11-server-Xwayland_removed + status: automated + - id: cm-11.1 + title: Alerts for Unauthorized Installations + rules: [] + status: pending + - id: cm-11.2 + title: Software Installation with Privileged Status + rules: [] + status: pending + - id: cm-11.3 + title: Automated Enforcement and Monitoring + rules: [] + status: pending + - id: cm-12 + title: Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-12.1 + title: Automated Tools to Support Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-13 + title: Data Action Mapping + rules: [] + status: pending + - id: cm-14 + title: Signed Components + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/cp.yml b/products/rhel8/controls/nist_800_53/cp.yml new file mode 100644 index 000000000000..53d97fb34990 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/cp.yml @@ -0,0 +1,296 @@ +# NIST 800-53 CP Family: Contingency Planning +controls: + - id: cp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: cp-2 + title: Contingency Plan + levels: + - low + rules: [] + status: pending + - id: cp-2.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-2.2 + title: Capacity Planning + levels: + - high + rules: [] + status: pending + - id: cp-2.3 + title: Resume Mission and Business Functions + levels: + - moderate + rules: [] + status: pending + - id: cp-2.4 + title: Resume All Mission and Business Functions + rules: [] + status: pending + - id: cp-2.5 + title: Continue Mission and Business Functions + levels: + - high + rules: [] + status: pending + - id: cp-2.6 + title: Alternate Processing and Storage Sites + rules: [] + status: pending + - id: cp-2.7 + title: Coordinate with External Service Providers + rules: [] + status: pending + - id: cp-2.8 + title: Identify Critical Assets + levels: + - moderate + rules: [] + status: pending + - id: cp-3 + title: Contingency Training + levels: + - low + rules: [] + status: pending + - id: cp-3.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: cp-3.2 + title: Mechanisms Used in Training Environments + rules: [] + status: pending + - id: cp-4 + title: Contingency Plan Testing + levels: + - low + rules: [] + status: pending + - id: cp-4.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-4.2 + title: Alternate Processing Site + levels: + - high + rules: [] + status: pending + - id: cp-4.3 + title: Automated Testing + rules: [] + status: pending + - id: cp-4.4 + title: Full Recovery and Reconstitution + rules: [] + status: pending + - id: cp-4.5 + title: Self-challenge + rules: [] + status: pending + - id: cp-5 + title: Contingency Plan Update + rules: [] + status: pending + - id: cp-6 + title: Alternate Storage Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.2 + title: Recovery Time and Recovery Point Objectives + levels: + - high + rules: [] + status: pending + - id: cp-6.3 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7 + title: Alternate Processing Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.2 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7.3 + title: Priority of Service + levels: + - moderate + rules: [] + status: pending + - id: cp-7.4 + title: Preparation for Use + levels: + - high + rules: [] + status: pending + - id: cp-7.5 + title: Equivalent Information Security Safeguards + rules: [] + status: pending + - id: cp-7.6 + title: Inability to Return to Primary Site + rules: [] + status: pending + - id: cp-8 + title: Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: cp-8.1 + title: Priority of Service Provisions + levels: + - moderate + rules: [] + status: pending + - id: cp-8.2 + title: Single Points of Failure + levels: + - moderate + rules: [] + status: pending + - id: cp-8.3 + title: Separation of Primary and Alternate Providers + levels: + - high + rules: [] + status: pending + - id: cp-8.4 + title: Provider Contingency Plan + levels: + - high + rules: [] + status: pending + - id: cp-8.5 + title: Alternate Telecommunication Service Testing + rules: [] + status: pending + - id: cp-9 + title: System Backup + levels: + - low + rules: [] + status: pending + - id: cp-9.1 + title: Testing for Reliability and Integrity + levels: + - moderate + rules: [] + status: pending + - id: cp-9.2 + title: Test Restoration Using Sampling + levels: + - high + rules: [] + status: pending + - id: cp-9.3 + title: Separate Storage for Critical Information + levels: + - high + rules: [] + status: pending + - id: cp-9.4 + title: Protection from Unauthorized Modification + rules: [] + status: pending + - id: cp-9.5 + title: Transfer to Alternate Storage Site + levels: + - high + rules: [] + status: pending + - id: cp-9.6 + title: Redundant Secondary System + rules: [] + status: pending + - id: cp-9.7 + title: Dual Authorization for Deletion or Destruction + rules: [] + status: pending + - id: cp-9.8 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: cp-10 + title: System Recovery and Reconstitution + levels: + - low + rules: [] + status: pending + - id: cp-10.1 + title: Contingency Plan Testing + rules: [] + status: pending + - id: cp-10.2 + title: Transaction Recovery + levels: + - moderate + rules: [] + status: pending + - id: cp-10.3 + title: Compensating Security Controls + rules: [] + status: pending + - id: cp-10.4 + title: Restore Within Time Period + levels: + - high + rules: [] + status: pending + - id: cp-10.5 + title: Failover Capability + rules: [] + status: pending + - id: cp-10.6 + title: Component Protection + rules: [] + status: pending + - id: cp-11 + title: Alternate Communications Protocols + rules: [] + status: pending + - id: cp-12 + title: Safe Mode + rules: [] + status: pending + - id: cp-13 + title: Alternative Security Mechanisms + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/ia.yml b/products/rhel8/controls/nist_800_53/ia.yml new file mode 100644 index 000000000000..890ff216cf8f --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ia.yml @@ -0,0 +1,393 @@ +# NIST 800-53 IA Family: Identification and Authentication +controls: + - id: ia-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ia-2 + title: Identification and Authentication (Organizational Users) + levels: + - low + rules: + - account_unique_id + status: automated + - id: ia-2.1 + title: Multi-factor Authentication to Privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.2 + title: Multi-factor Authentication to Non-privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.3 + title: Local Access to Privileged Accounts + rules: [] + status: pending + - id: ia-2.4 + title: Local Access to Non-privileged Accounts + rules: [] + status: pending + - id: ia-2.5 + title: Individual Authentication with Group Authentication + levels: + - high + rules: [] + status: pending + - id: ia-2.6 + title: Access to Accounts —separate Device + rules: [] + status: pending + - id: ia-2.7 + title: Network Access to Non-privileged Accounts — Separate Device + rules: [] + status: pending + - id: ia-2.8 + title: Access to Accounts — Replay Resistant + levels: + - low + rules: [] + status: pending + - id: ia-2.9 + title: Network Access to Non-privileged Accounts — Replay Resistant + rules: [] + status: pending + - id: ia-2.10 + title: Single Sign-on + rules: [] + status: pending + - id: ia-2.11 + title: Remote Access — Separate Device + rules: [] + status: pending + - id: ia-2.12 + title: Acceptance of PIV Credentials + levels: + - low + rules: [] + status: pending + - id: ia-2.13 + title: Out-of-band Authentication + rules: [] + status: pending + - id: ia-3 + title: Device Identification and Authentication + levels: + - moderate + rules: + - dconf_gnome_disable_automount + - dconf_gnome_disable_automount_open + - kernel_module_usb-storage_disabled + status: automated + - id: ia-3.1 + title: Cryptographic Bidirectional Authentication + rules: [] + status: pending + - id: ia-3.2 + title: Cryptographic Bidirectional Network Authentication + rules: [] + status: pending + - id: ia-3.3 + title: Dynamic Address Allocation + rules: [] + status: pending + - id: ia-3.4 + title: Device Attestation + rules: [] + status: pending + - id: ia-4 + title: Identifier Management + levels: + - low + rules: + - account_disable_post_pw_expiration + - accounts_set_post_pw_existing + - var_account_disable_post_pw_expiration=45 + status: automated + - id: ia-4.1 + title: Prohibit Account Identifiers as Public Identifiers + rules: [] + status: pending + - id: ia-4.2 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-4.3 + title: Multiple Forms of Certification + rules: [] + status: pending + - id: ia-4.4 + title: Identify User Status + levels: + - moderate + rules: [] + status: pending + - id: ia-4.5 + title: Dynamic Management + rules: [] + status: pending + - id: ia-4.6 + title: Cross-organization Management + rules: [] + status: pending + - id: ia-4.7 + title: In-person Registration + rules: [] + status: pending + - id: ia-4.8 + title: Pairwise Pseudonymous Identifiers + rules: [] + status: pending + - id: ia-4.9 + title: Attribute Maintenance and Protection + rules: [] + status: pending + - id: ia-5 + title: Authenticator Management + levels: + - low + rules: + - accounts_maximum_age_login_defs + - accounts_password_all_shadowed + - accounts_password_last_change_is_in_past + - accounts_password_pam_dictcheck + - accounts_password_pam_difok + - accounts_password_pam_enforce_root + - accounts_password_pam_maxrepeat + - accounts_password_pam_maxsequence + - accounts_password_pam_minlen + - accounts_password_pam_pwhistory_enforce_for_root + - accounts_password_pam_pwhistory_use_authtok + - accounts_password_pam_unix_authtok + - accounts_password_set_warn_age_existing + - accounts_password_warn_age_login_defs + - ensure_root_password_configured + - no_empty_passwords_etc_shadow + - set_password_hashing_algorithm_logindefs + - set_password_hashing_algorithm_passwordauth + - set_password_hashing_algorithm_systemauth + - var_accounts_maximum_age_login_defs=365 + - var_accounts_password_warn_age_login_defs=7 + - var_password_hashing_algorithm=cis_rhel8 + - var_password_hashing_algorithm_pam=cis_rhel8 + - var_password_pam_dictcheck=1 + - var_password_pam_difok=2 + - var_password_pam_maxrepeat=3 + - var_password_pam_maxsequence=3 + - var_password_pam_minlen=14 + status: automated + - id: ia-5.1 + title: Password-based Authentication + levels: + - low + rules: + - accounts_password_pam_pwhistory_remember_password_auth + - accounts_password_pam_pwhistory_remember_system_auth + - accounts_password_pam_unix_enabled + - accounts_password_pam_unix_no_remember + - var_password_pam_remember=24 + - var_password_pam_remember_control_flag=requisite_or_required + status: automated + - id: ia-5.2 + title: Public Key-based Authentication + levels: + - moderate + rules: [] + status: pending + - id: ia-5.3 + title: In-person or Trusted External Party Registration + rules: [] + status: pending + - id: ia-5.4 + title: Automated Support for Password Strength Determination + rules: [] + status: pending + - id: ia-5.5 + title: Change Authenticators Prior to Delivery + rules: [] + status: pending + - id: ia-5.6 + title: Protection of Authenticators + levels: + - moderate + rules: [] + status: pending + - id: ia-5.7 + title: No Embedded Unencrypted Static Authenticators + rules: [] + status: pending + - id: ia-5.8 + title: Multiple System Accounts + rules: [] + status: pending + - id: ia-5.9 + title: Federated Credential Management + rules: [] + status: pending + - id: ia-5.10 + title: Dynamic Credential Binding + rules: [] + status: pending + - id: ia-5.11 + title: Hardware Token-based Authentication + rules: [] + status: pending + - id: ia-5.12 + title: Biometric Authentication Performance + rules: [] + status: pending + - id: ia-5.13 + title: Expiration of Cached Authenticators + rules: [] + status: pending + - id: ia-5.14 + title: Managing Content of PKI Trust Stores + rules: [] + status: pending + - id: ia-5.15 + title: GSA-approved Products and Services + rules: [] + status: pending + - id: ia-5.16 + title: In-person or Trusted External Party Authenticator Issuance + rules: [] + status: pending + - id: ia-5.17 + title: Presentation Attack Detection for Biometric Authenticators + rules: [] + status: pending + - id: ia-5.18 + title: Password Managers + rules: [] + status: pending + - id: ia-6 + title: Authentication Feedback + levels: + - low + rules: [] + status: pending + - id: ia-7 + title: Cryptographic Module Authentication + levels: + - low + rules: [] + status: pending + - id: ia-8 + title: Identification and Authentication (Non-organizational Users) + levels: + - low + rules: [] + status: pending + - id: ia-8.1 + title: Acceptance of PIV Credentials from Other Agencies + levels: + - low + rules: [] + status: pending + - id: ia-8.2 + title: Acceptance of External Authenticators + levels: + - low + rules: [] + status: pending + - id: ia-8.3 + title: Use of FICAM-approved Products + rules: [] + status: pending + - id: ia-8.4 + title: Use of Defined Profiles + levels: + - low + rules: [] + status: pending + - id: ia-8.5 + title: Acceptance of PIV-I Credentials + rules: [] + status: pending + - id: ia-8.6 + title: Disassociability + rules: [] + status: pending + - id: ia-9 + title: Service Identification and Authentication + rules: [] + status: pending + - id: ia-9.1 + title: Information Exchange + rules: [] + status: pending + - id: ia-9.2 + title: Transmission of Decisions + rules: [] + status: pending + - id: ia-10 + title: Adaptive Authentication + rules: [] + status: pending + - id: ia-11 + title: Re-authentication + levels: + - low + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=15_minutes + status: automated + - id: ia-12 + title: Identity Proofing + levels: + - moderate + rules: [] + status: pending + - id: ia-12.1 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-12.2 + title: Identity Evidence + levels: + - moderate + rules: [] + status: pending + - id: ia-12.3 + title: Identity Evidence Validation and Verification + levels: + - moderate + rules: [] + status: pending + - id: ia-12.4 + title: In-person Validation and Verification + levels: + - high + rules: [] + status: pending + - id: ia-12.5 + title: Address Confirmation + levels: + - moderate + rules: [] + status: pending + - id: ia-12.6 + title: Accept Externally-proofed Identities + rules: [] + status: pending + - id: ia-13 + title: Identity Providers and Authorization Servers + rules: [] + status: pending + - id: ia-13.1 + title: Protection of Cryptographic Keys + rules: [] + status: pending + - id: ia-13.2 + title: Verification of Identity Assertions and Access Tokens + rules: [] + status: pending + - id: ia-13.3 + title: Token Management + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/ir.yml b/products/rhel8/controls/nist_800_53/ir.yml new file mode 100644 index 000000000000..2d443099c957 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ir.yml @@ -0,0 +1,206 @@ +# NIST 800-53 IR Family: Incident Response +controls: + - id: ir-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ir-2 + title: Incident Response Training + levels: + - low + rules: [] + status: pending + - id: ir-2.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: ir-2.2 + title: Automated Training Environments + levels: + - high + rules: [] + status: pending + - id: ir-2.3 + title: Breach + rules: [] + status: pending + - id: ir-3 + title: Incident Response Testing + levels: + - moderate + rules: [] + status: pending + - id: ir-3.1 + title: Automated Testing + rules: [] + status: pending + - id: ir-3.2 + title: Coordination with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: ir-3.3 + title: Continuous Improvement + rules: [] + status: pending + - id: ir-4 + title: Incident Handling + levels: + - low + rules: [] + status: pending + - id: ir-4.1 + title: Automated Incident Handling Processes + levels: + - moderate + rules: [] + status: pending + - id: ir-4.2 + title: Dynamic Reconfiguration + rules: [] + status: pending + - id: ir-4.3 + title: Continuity of Operations + rules: [] + status: pending + - id: ir-4.4 + title: Information Correlation + levels: + - high + rules: [] + status: pending + - id: ir-4.5 + title: Automatic Disabling of System + rules: [] + status: pending + - id: ir-4.6 + title: Insider Threats + rules: [] + status: pending + - id: ir-4.7 + title: Insider Threats — Intra-organization Coordination + rules: [] + status: pending + - id: ir-4.8 + title: Correlation with External Organizations + rules: [] + status: pending + - id: ir-4.9 + title: Dynamic Response Capability + rules: [] + status: pending + - id: ir-4.10 + title: Supply Chain Coordination + rules: [] + status: pending + - id: ir-4.11 + title: Integrated Incident Response Team + levels: + - high + rules: [] + status: pending + - id: ir-4.12 + title: Malicious Code and Forensic Analysis + rules: [] + status: pending + - id: ir-4.13 + title: Behavior Analysis + rules: [] + status: pending + - id: ir-4.14 + title: Security Operations Center + rules: [] + status: pending + - id: ir-4.15 + title: Public Relations and Reputation Repair + rules: [] + status: pending + - id: ir-5 + title: Incident Monitoring + levels: + - low + rules: [] + status: pending + - id: ir-5.1 + title: Automated Tracking, Data Collection, and Analysis + levels: + - high + rules: [] + status: pending + - id: ir-6 + title: Incident Reporting + levels: + - low + rules: [] + status: pending + - id: ir-6.1 + title: Automated Reporting + levels: + - moderate + rules: [] + status: pending + - id: ir-6.2 + title: Vulnerabilities Related to Incidents + rules: [] + status: pending + - id: ir-6.3 + title: Supply Chain Coordination + levels: + - moderate + rules: [] + status: pending + - id: ir-7 + title: Incident Response Assistance + levels: + - low + rules: [] + status: pending + - id: ir-7.1 + title: Automation Support for Availability of Information and Support + levels: + - moderate + rules: [] + status: pending + - id: ir-7.2 + title: Coordination with External Providers + rules: [] + status: pending + - id: ir-8 + title: Incident Response Plan + levels: + - low + rules: [] + status: pending + - id: ir-8.1 + title: Breaches + rules: [] + status: pending + - id: ir-9 + title: Information Spillage Response + rules: [] + status: pending + - id: ir-9.1 + title: Responsible Personnel + rules: [] + status: pending + - id: ir-9.2 + title: Training + rules: [] + status: pending + - id: ir-9.3 + title: Post-spill Operations + rules: [] + status: pending + - id: ir-9.4 + title: Exposure to Unauthorized Personnel + rules: [] + status: pending + - id: ir-10 + title: Integrated Information Security Analysis Team + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/ma.yml b/products/rhel8/controls/nist_800_53/ma.yml new file mode 100644 index 000000000000..77bd02932613 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ma.yml @@ -0,0 +1,146 @@ +# NIST 800-53 MA Family: Maintenance +controls: + - id: ma-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ma-2 + title: Controlled Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-2.1 + title: Record Content + rules: [] + status: pending + - id: ma-2.2 + title: Automated Maintenance Activities + levels: + - high + rules: [] + status: pending + - id: ma-3 + title: Maintenance Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.1 + title: Inspect Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.2 + title: Inspect Media + levels: + - moderate + rules: [] + status: pending + - id: ma-3.3 + title: Prevent Unauthorized Removal + levels: + - moderate + rules: [] + status: pending + - id: ma-3.4 + title: Restricted Tool Use + rules: [] + status: pending + - id: ma-3.5 + title: Execution with Privilege + rules: [] + status: pending + - id: ma-3.6 + title: Software Updates and Patches + rules: [] + status: pending + - id: ma-4 + title: Nonlocal Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-4.1 + title: Logging and Review + rules: [] + status: pending + - id: ma-4.2 + title: Document Nonlocal Maintenance + rules: [] + status: pending + - id: ma-4.3 + title: Comparable Security and Sanitization + levels: + - high + rules: [] + status: pending + - id: ma-4.4 + title: Authentication and Separation of Maintenance Sessions + rules: [] + status: pending + - id: ma-4.5 + title: Approvals and Notifications + rules: [] + status: pending + - id: ma-4.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: ma-4.7 + title: Disconnect Verification + rules: [] + status: pending + - id: ma-5 + title: Maintenance Personnel + levels: + - low + rules: [] + status: pending + - id: ma-5.1 + title: Individuals Without Appropriate Access + levels: + - high + rules: [] + status: pending + - id: ma-5.2 + title: Security Clearances for Classified Systems + rules: [] + status: pending + - id: ma-5.3 + title: Citizenship Requirements for Classified Systems + rules: [] + status: pending + - id: ma-5.4 + title: Foreign Nationals + rules: [] + status: pending + - id: ma-5.5 + title: Non-system Maintenance + rules: [] + status: pending + - id: ma-6 + title: Timely Maintenance + levels: + - moderate + rules: [] + status: pending + - id: ma-6.1 + title: Preventive Maintenance + rules: [] + status: pending + - id: ma-6.2 + title: Predictive Maintenance + rules: [] + status: pending + - id: ma-6.3 + title: Automated Support for Predictive Maintenance + rules: [] + status: pending + - id: ma-7 + title: Field Maintenance + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/mp.yml b/products/rhel8/controls/nist_800_53/mp.yml new file mode 100644 index 000000000000..6c8e8f46e4e4 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/mp.yml @@ -0,0 +1,142 @@ +# NIST 800-53 MP Family: Media Protection +controls: + - id: mp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: mp-2 + title: Media Access + levels: + - low + rules: [] + status: pending + - id: mp-2.1 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-2.2 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-3 + title: Media Marking + levels: + - moderate + rules: [] + status: pending + - id: mp-4 + title: Media Storage + levels: + - moderate + rules: [] + status: pending + - id: mp-4.1 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-4.2 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-5 + title: Media Transport + levels: + - moderate + rules: [] + status: pending + - id: mp-5.1 + title: Protection Outside of Controlled Areas + rules: [] + status: pending + - id: mp-5.2 + title: Documentation of Activities + rules: [] + status: pending + - id: mp-5.3 + title: Custodians + rules: [] + status: pending + - id: mp-5.4 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-6 + title: Media Sanitization + levels: + - low + rules: [] + status: pending + - id: mp-6.1 + title: Review, Approve, Track, Document, and Verify + levels: + - high + rules: [] + status: pending + - id: mp-6.2 + title: Equipment Testing + levels: + - high + rules: [] + status: pending + - id: mp-6.3 + title: Nondestructive Techniques + levels: + - high + rules: [] + status: pending + - id: mp-6.4 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-6.5 + title: Classified Information + rules: [] + status: pending + - id: mp-6.6 + title: Media Destruction + rules: [] + status: pending + - id: mp-6.7 + title: Dual Authorization + rules: [] + status: pending + - id: mp-6.8 + title: Remote Purging or Wiping of Information + rules: [] + status: pending + - id: mp-7 + title: Media Use + levels: + - low + rules: [] + status: pending + - id: mp-7.1 + title: Prohibit Use Without Owner + rules: [] + status: pending + - id: mp-7.2 + title: Prohibit Use of Sanitization-resistant Media + rules: [] + status: pending + - id: mp-8 + title: Media Downgrading + rules: [] + status: pending + - id: mp-8.1 + title: Documentation of Process + rules: [] + status: pending + - id: mp-8.2 + title: Equipment Testing + rules: [] + status: pending + - id: mp-8.3 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-8.4 + title: Classified Information + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/pe.yml b/products/rhel8/controls/nist_800_53/pe.yml new file mode 100644 index 000000000000..b6728c7d49d5 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/pe.yml @@ -0,0 +1,288 @@ +# NIST 800-53 PE Family: Physical and Environmental Protection +controls: + - id: pe-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pe-2 + title: Physical Access Authorizations + levels: + - low + rules: [] + status: pending + - id: pe-2.1 + title: Access by Position or Role + rules: [] + status: pending + - id: pe-2.2 + title: Two Forms of Identification + rules: [] + status: pending + - id: pe-2.3 + title: Restrict Unescorted Access + rules: [] + status: pending + - id: pe-3 + title: Physical Access Control + levels: + - low + rules: [] + status: pending + - id: pe-3.1 + title: System Access + levels: + - high + rules: [] + status: pending + - id: pe-3.2 + title: Facility and Systems + rules: [] + status: pending + - id: pe-3.3 + title: Continuous Guards + rules: [] + status: pending + - id: pe-3.4 + title: Lockable Casings + rules: [] + status: pending + - id: pe-3.5 + title: Tamper Protection + rules: [] + status: pending + - id: pe-3.6 + title: Facility Penetration Testing + rules: [] + status: pending + - id: pe-3.7 + title: Physical Barriers + rules: [] + status: pending + - id: pe-3.8 + title: Access Control Vestibules + rules: [] + status: pending + - id: pe-4 + title: Access Control for Transmission + levels: + - moderate + rules: [] + status: pending + - id: pe-5 + title: Access Control for Output Devices + levels: + - moderate + rules: [] + status: pending + - id: pe-5.1 + title: Access to Output by Authorized Individuals + rules: [] + status: pending + - id: pe-5.2 + title: Link to Individual Identity + rules: [] + status: pending + - id: pe-5.3 + title: Marking Output Devices + rules: [] + status: pending + - id: pe-6 + title: Monitoring Physical Access + levels: + - low + rules: [] + status: pending + - id: pe-6.1 + title: Intrusion Alarms and Surveillance Equipment + levels: + - moderate + rules: [] + status: pending + - id: pe-6.2 + title: Automated Intrusion Recognition and Responses + rules: [] + status: pending + - id: pe-6.3 + title: Video Surveillance + rules: [] + status: pending + - id: pe-6.4 + title: Monitoring Physical Access to Systems + levels: + - high + rules: [] + status: pending + - id: pe-7 + title: Visitor Control + rules: [] + status: pending + - id: pe-8 + title: Visitor Access Records + levels: + - low + rules: [] + status: pending + - id: pe-8.1 + title: Automated Records Maintenance and Review + levels: + - high + rules: [] + status: pending + - id: pe-8.2 + title: Physical Access Records + rules: [] + status: pending + - id: pe-8.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: pe-9 + title: Power Equipment and Cabling + levels: + - moderate + rules: [] + status: pending + - id: pe-9.1 + title: Redundant Cabling + rules: [] + status: pending + - id: pe-9.2 + title: Automatic Voltage Controls + rules: [] + status: pending + - id: pe-10 + title: Emergency Shutoff + levels: + - moderate + rules: [] + status: pending + - id: pe-10.1 + title: Accidental and Unauthorized Activation + rules: [] + status: pending + - id: pe-11 + title: Emergency Power + levels: + - moderate + rules: [] + status: pending + - id: pe-11.1 + title: Alternate Power Supply — Minimal Operational Capability + levels: + - high + rules: [] + status: pending + - id: pe-11.2 + title: Alternate Power Supply — Self-contained + rules: [] + status: pending + - id: pe-12 + title: Emergency Lighting + levels: + - low + rules: [] + status: pending + - id: pe-12.1 + title: Essential Mission and Business Functions + rules: [] + status: pending + - id: pe-13 + title: Fire Protection + levels: + - low + rules: [] + status: pending + - id: pe-13.1 + title: Detection Systems — Automatic Activation and Notification + levels: + - moderate + rules: [] + status: pending + - id: pe-13.2 + title: Suppression Systems — Automatic Activation and Notification + levels: + - high + rules: [] + status: pending + - id: pe-13.3 + title: Automatic Fire Suppression + rules: [] + status: pending + - id: pe-13.4 + title: Inspections + rules: [] + status: pending + - id: pe-14 + title: Environmental Controls + levels: + - low + rules: [] + status: pending + - id: pe-14.1 + title: Automatic Controls + rules: [] + status: pending + - id: pe-14.2 + title: Monitoring with Alarms and Notifications + rules: [] + status: pending + - id: pe-15 + title: Water Damage Protection + levels: + - low + rules: [] + status: pending + - id: pe-15.1 + title: Automation Support + levels: + - high + rules: [] + status: pending + - id: pe-16 + title: Delivery and Removal + levels: + - low + rules: [] + status: pending + - id: pe-17 + title: Alternate Work Site + levels: + - moderate + rules: [] + status: pending + - id: pe-18 + title: Location of System Components + levels: + - high + rules: [] + status: pending + - id: pe-18.1 + title: Facility Site + rules: [] + status: pending + - id: pe-19 + title: Information Leakage + rules: [] + status: pending + - id: pe-19.1 + title: National Emissions Policies and Procedures + rules: [] + status: pending + - id: pe-20 + title: Asset Monitoring and Tracking + rules: [] + status: pending + - id: pe-21 + title: Electromagnetic Pulse Protection + rules: [] + status: pending + - id: pe-22 + title: Component Marking + rules: [] + status: pending + - id: pe-23 + title: Facility Location + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/pl.yml b/products/rhel8/controls/nist_800_53/pl.yml new file mode 100644 index 000000000000..d670e154e380 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/pl.yml @@ -0,0 +1,84 @@ +# NIST 800-53 PL Family: Planning +controls: + - id: pl-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pl-2 + title: System Security and Privacy Plans + levels: + - low + rules: [] + status: pending + - id: pl-2.1 + title: Concept of Operations + rules: [] + status: pending + - id: pl-2.2 + title: Functional Architecture + rules: [] + status: pending + - id: pl-2.3 + title: Plan and Coordinate with Other Organizational Entities + rules: [] + status: pending + - id: pl-3 + title: System Security Plan Update + rules: [] + status: pending + - id: pl-4 + title: Rules of Behavior + levels: + - low + rules: [] + status: pending + - id: pl-4.1 + title: Social Media and External Site/Application Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: pl-5 + title: Privacy Impact Assessment + rules: [] + status: pending + - id: pl-6 + title: Security-related Activity Planning + rules: [] + status: pending + - id: pl-7 + title: Concept of Operations + rules: [] + status: pending + - id: pl-8 + title: Security and Privacy Architectures + levels: + - moderate + rules: [] + status: pending + - id: pl-8.1 + title: Defense in Depth + rules: [] + status: pending + - id: pl-8.2 + title: Supplier Diversity + rules: [] + status: pending + - id: pl-9 + title: Central Management + rules: [] + status: pending + - id: pl-10 + title: Baseline Selection + levels: + - low + rules: [] + status: pending + - id: pl-11 + title: Baseline Tailoring + levels: + - low + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/pm.yml b/products/rhel8/controls/nist_800_53/pm.yml new file mode 100644 index 000000000000..97a32be05deb --- /dev/null +++ b/products/rhel8/controls/nist_800_53/pm.yml @@ -0,0 +1,151 @@ +# NIST 800-53 PM Family: Program Management +controls: + - id: pm-1 + title: Information Security Program Plan + rules: [] + status: pending + - id: pm-2 + title: Information Security Program Leadership Role + rules: [] + status: pending + - id: pm-3 + title: Information Security and Privacy Resources + rules: [] + status: pending + - id: pm-4 + title: Plan of Action and Milestones Process + rules: [] + status: pending + - id: pm-5 + title: System Inventory + rules: [] + status: pending + - id: pm-5.1 + title: Inventory of Personally Identifiable Information + rules: [] + status: pending + - id: pm-6 + title: Measures of Performance + rules: [] + status: pending + - id: pm-7 + title: Enterprise Architecture + rules: [] + status: pending + - id: pm-7.1 + title: Offloading + rules: [] + status: pending + - id: pm-8 + title: Critical Infrastructure Plan + rules: [] + status: pending + - id: pm-9 + title: Risk Management Strategy + rules: [] + status: pending + - id: pm-10 + title: Authorization Process + rules: [] + status: pending + - id: pm-11 + title: Mission and Business Process Definition + rules: [] + status: pending + - id: pm-12 + title: Insider Threat Program + rules: [] + status: pending + - id: pm-13 + title: Security and Privacy Workforce + rules: [] + status: pending + - id: pm-14 + title: Testing, Training, and Monitoring + rules: [] + status: pending + - id: pm-15 + title: Security and Privacy Groups and Associations + rules: [] + status: pending + - id: pm-16 + title: Threat Awareness Program + rules: [] + status: pending + - id: pm-16.1 + title: Automated Means for Sharing Threat Intelligence + rules: [] + status: pending + - id: pm-17 + title: Protecting Controlled Unclassified Information on External Systems + rules: [] + status: pending + - id: pm-18 + title: Privacy Program Plan + rules: [] + status: pending + - id: pm-19 + title: Privacy Program Leadership Role + rules: [] + status: pending + - id: pm-20 + title: Dissemination of Privacy Program Information + rules: [] + status: pending + - id: pm-20.1 + title: Privacy Policies on Websites, Applications, and Digital Services + rules: [] + status: pending + - id: pm-21 + title: Accounting of Disclosures + rules: [] + status: pending + - id: pm-22 + title: Personally Identifiable Information Quality Management + rules: [] + status: pending + - id: pm-23 + title: Data Governance Body + rules: [] + status: pending + - id: pm-24 + title: Data Integrity Board + rules: [] + status: pending + - id: pm-25 + title: Minimization of Personally Identifiable Information Used in Testing, Training, and + Research + rules: [] + status: pending + - id: pm-26 + title: Complaint Management + rules: [] + status: pending + - id: pm-27 + title: Privacy Reporting + rules: [] + status: pending + - id: pm-28 + title: Risk Framing + rules: [] + status: pending + - id: pm-29 + title: Risk Management Program Leadership Roles + rules: [] + status: pending + - id: pm-30 + title: Supply Chain Risk Management Strategy + rules: [] + status: pending + - id: pm-30.1 + title: Suppliers of Critical or Mission-essential Items + rules: [] + status: pending + - id: pm-31 + title: Continuous Monitoring Strategy + rules: [] + status: pending + - id: pm-32 + title: Purposing + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/ps.yml b/products/rhel8/controls/nist_800_53/ps.yml new file mode 100644 index 000000000000..ad7d70333c17 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ps.yml @@ -0,0 +1,94 @@ +# NIST 800-53 PS Family: Personnel Security +controls: + - id: ps-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ps-2 + title: Position Risk Designation + levels: + - low + rules: [] + status: pending + - id: ps-3 + title: Personnel Screening + levels: + - low + rules: [] + status: pending + - id: ps-3.1 + title: Classified Information + rules: [] + status: pending + - id: ps-3.2 + title: Formal Indoctrination + rules: [] + status: pending + - id: ps-3.3 + title: Information Requiring Special Protective Measures + rules: [] + status: pending + - id: ps-3.4 + title: Citizenship Requirements + rules: [] + status: pending + - id: ps-4 + title: Personnel Termination + levels: + - low + rules: [] + status: pending + - id: ps-4.1 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-4.2 + title: Automated Actions + levels: + - high + rules: [] + status: pending + - id: ps-5 + title: Personnel Transfer + levels: + - low + rules: [] + status: pending + - id: ps-6 + title: Access Agreements + levels: + - low + rules: [] + status: pending + - id: ps-6.1 + title: Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.2 + title: Classified Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.3 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-7 + title: External Personnel Security + levels: + - low + rules: [] + status: pending + - id: ps-8 + title: Personnel Sanctions + levels: + - low + rules: [] + status: pending + - id: ps-9 + title: Position Descriptions + levels: + - low + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/pt.yml b/products/rhel8/controls/nist_800_53/pt.yml new file mode 100644 index 000000000000..fe3d1ee54437 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/pt.yml @@ -0,0 +1,86 @@ +# NIST 800-53 PT Family: PII Processing and Transparency +controls: + - id: pt-1 + title: Policy and Procedures + rules: [] + status: pending + - id: pt-2 + title: Authority to Process Personally Identifiable Information + rules: [] + status: pending + - id: pt-2.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-2.2 + title: Automation + rules: [] + status: pending + - id: pt-3 + title: Personally Identifiable Information Processing Purposes + rules: [] + status: pending + - id: pt-3.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-3.2 + title: Automation + rules: [] + status: pending + - id: pt-4 + title: Consent + rules: [] + status: pending + - id: pt-4.1 + title: Tailored Consent + rules: [] + status: pending + - id: pt-4.2 + title: Just-in-time Consent + rules: [] + status: pending + - id: pt-4.3 + title: Revocation + rules: [] + status: pending + - id: pt-5 + title: Privacy Notice + rules: [] + status: pending + - id: pt-5.1 + title: Just-in-time Notice + rules: [] + status: pending + - id: pt-5.2 + title: Privacy Act Statements + rules: [] + status: pending + - id: pt-6 + title: System of Records Notice + rules: [] + status: pending + - id: pt-6.1 + title: Routine Uses + rules: [] + status: pending + - id: pt-6.2 + title: Exemption Rules + rules: [] + status: pending + - id: pt-7 + title: Specific Categories of Personally Identifiable Information + rules: [] + status: pending + - id: pt-7.1 + title: Social Security Numbers + rules: [] + status: pending + - id: pt-7.2 + title: First Amendment Information + rules: [] + status: pending + - id: pt-8 + title: Computer Matching Requirements + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/ra.yml b/products/rhel8/controls/nist_800_53/ra.yml new file mode 100644 index 000000000000..ca44e21f4e67 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/ra.yml @@ -0,0 +1,128 @@ +# NIST 800-53 RA Family: Risk Assessment +controls: + - id: ra-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ra-2 + title: Security Categorization + levels: + - low + rules: [] + status: pending + - id: ra-2.1 + title: Impact-level Prioritization + rules: [] + status: pending + - id: ra-3 + title: Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.1 + title: Supply Chain Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.2 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: ra-3.3 + title: Dynamic Threat Awareness + rules: [] + status: pending + - id: ra-3.4 + title: Predictive Cyber Analytics + rules: [] + status: pending + - id: ra-4 + title: Risk Assessment Update + rules: [] + status: pending + - id: ra-5 + title: Vulnerability Monitoring and Scanning + levels: + - low + rules: [] + status: pending + - id: ra-5.1 + title: Update Tool Capability + rules: [] + status: pending + - id: ra-5.2 + title: Update Vulnerabilities to Be Scanned + levels: + - low + rules: [] + status: pending + - id: ra-5.3 + title: Breadth and Depth of Coverage + rules: [] + status: pending + - id: ra-5.4 + title: Discoverable Information + levels: + - high + rules: [] + status: pending + - id: ra-5.5 + title: Privileged Access + levels: + - moderate + rules: [] + status: pending + - id: ra-5.6 + title: Automated Trend Analyses + rules: [] + status: pending + - id: ra-5.7 + title: Automated Detection and Notification of Unauthorized Components + rules: [] + status: pending + - id: ra-5.8 + title: Review Historic Audit Logs + rules: [] + status: pending + - id: ra-5.9 + title: Penetration Testing and Analyses + rules: [] + status: pending + - id: ra-5.10 + title: Correlate Scanning Information + rules: [] + status: pending + - id: ra-5.11 + title: Public Disclosure Program + levels: + - low + rules: [] + status: pending + - id: ra-6 + title: Technical Surveillance Countermeasures Survey + rules: [] + status: pending + - id: ra-7 + title: Risk Response + levels: + - low + rules: [] + status: pending + - id: ra-8 + title: Privacy Impact Assessments + rules: [] + status: pending + - id: ra-9 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: ra-10 + title: Threat Hunting + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/sa.yml b/products/rhel8/controls/nist_800_53/sa.yml new file mode 100644 index 000000000000..89a619dd4589 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/sa.yml @@ -0,0 +1,632 @@ +# NIST 800-53 SA Family: System and Services Acquisition +controls: + - id: sa-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sa-2 + title: Allocation of Resources + levels: + - low + rules: [] + status: pending + - id: sa-3 + title: System Development Life Cycle + levels: + - low + rules: [] + status: pending + - id: sa-3.1 + title: Manage Preproduction Environment + rules: [] + status: pending + - id: sa-3.2 + title: Use of Live or Operational Data + rules: [] + status: pending + - id: sa-3.3 + title: Technology Refresh + rules: [] + status: pending + - id: sa-4 + title: Acquisition Process + levels: + - low + rules: [] + status: pending + - id: sa-4.1 + title: Functional Properties of Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.2 + title: Design and Implementation Information for Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.3 + title: Development Methods, Techniques, and Practices + rules: [] + status: pending + - id: sa-4.4 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: sa-4.5 + title: System, Component, and Service Configurations + levels: + - high + rules: [] + status: pending + - id: sa-4.6 + title: Use of Information Assurance Products + rules: [] + status: pending + - id: sa-4.7 + title: 'NIAP-approved Protection Profiles ' + rules: [] + status: pending + - id: sa-4.8 + title: Continuous Monitoring Plan for Controls + rules: [] + status: pending + - id: sa-4.9 + title: Functions, Ports, Protocols, and Services in Use + levels: + - moderate + rules: [] + status: pending + - id: sa-4.10 + title: Use of Approved PIV Products + levels: + - low + rules: [] + status: pending + - id: sa-4.11 + title: System of Records + rules: [] + status: pending + - id: sa-4.12 + title: Data Ownership + rules: [] + status: pending + - id: sa-5 + title: System Documentation + levels: + - low + rules: [] + status: pending + - id: sa-5.1 + title: Functional Properties of Security Controls + rules: [] + status: pending + - id: sa-5.2 + title: Security-relevant External System Interfaces + rules: [] + status: pending + - id: sa-5.3 + title: High-level Design + rules: [] + status: pending + - id: sa-5.4 + title: Low-level Design + rules: [] + status: pending + - id: sa-5.5 + title: Source Code + rules: [] + status: pending + - id: sa-6 + title: Software Usage Restrictions + rules: [] + status: pending + - id: sa-7 + title: User-installed Software + rules: [] + status: pending + - id: sa-8 + title: Security and Privacy Engineering Principles + levels: + - low + rules: [] + status: pending + - id: sa-8.1 + title: Clear Abstractions + rules: [] + status: pending + - id: sa-8.2 + title: Least Common Mechanism + rules: [] + status: pending + - id: sa-8.3 + title: Modularity and Layering + rules: [] + status: pending + - id: sa-8.4 + title: Partially Ordered Dependencies + rules: [] + status: pending + - id: sa-8.5 + title: Efficiently Mediated Access + rules: [] + status: pending + - id: sa-8.6 + title: Minimized Sharing + rules: [] + status: pending + - id: sa-8.7 + title: Reduced Complexity + rules: [] + status: pending + - id: sa-8.8 + title: Secure Evolvability + rules: [] + status: pending + - id: sa-8.9 + title: Trusted Components + rules: [] + status: pending + - id: sa-8.10 + title: Hierarchical Trust + rules: [] + status: pending + - id: sa-8.11 + title: Inverse Modification Threshold + rules: [] + status: pending + - id: sa-8.12 + title: Hierarchical Protection + rules: [] + status: pending + - id: sa-8.13 + title: Minimized Security Elements + rules: [] + status: pending + - id: sa-8.14 + title: Least Privilege + rules: [] + status: pending + - id: sa-8.15 + title: Predicate Permission + rules: [] + status: pending + - id: sa-8.16 + title: Self-reliant Trustworthiness + rules: [] + status: pending + - id: sa-8.17 + title: Secure Distributed Composition + rules: [] + status: pending + - id: sa-8.18 + title: Trusted Communications Channels + rules: [] + status: pending + - id: sa-8.19 + title: Continuous Protection + rules: [] + status: pending + - id: sa-8.20 + title: Secure Metadata Management + rules: [] + status: pending + - id: sa-8.21 + title: Self-analysis + rules: [] + status: pending + - id: sa-8.22 + title: Accountability and Traceability + rules: [] + status: pending + - id: sa-8.23 + title: Secure Defaults + rules: [] + status: pending + - id: sa-8.24 + title: Secure Failure and Recovery + rules: [] + status: pending + - id: sa-8.25 + title: Economic Security + rules: [] + status: pending + - id: sa-8.26 + title: Performance Security + rules: [] + status: pending + - id: sa-8.27 + title: Human Factored Security + rules: [] + status: pending + - id: sa-8.28 + title: Acceptable Security + rules: [] + status: pending + - id: sa-8.29 + title: Repeatable and Documented Procedures + rules: [] + status: pending + - id: sa-8.30 + title: Procedural Rigor + rules: [] + status: pending + - id: sa-8.31 + title: Secure System Modification + rules: [] + status: pending + - id: sa-8.32 + title: Sufficient Documentation + rules: [] + status: pending + - id: sa-8.33 + title: Minimization + rules: [] + status: pending + - id: sa-9 + title: External System Services + levels: + - low + rules: [] + status: pending + - id: sa-9.1 + title: Risk Assessments and Organizational Approvals + rules: [] + status: pending + - id: sa-9.2 + title: Identification of Functions, Ports, Protocols, and Services + levels: + - moderate + rules: [] + status: pending + - id: sa-9.3 + title: Establish and Maintain Trust Relationship with Providers + rules: [] + status: pending + - id: sa-9.4 + title: Consistent Interests of Consumers and Providers + rules: [] + status: pending + - id: sa-9.5 + title: Processing, Storage, and Service Location + rules: [] + status: pending + - id: sa-9.6 + title: Organization-controlled Cryptographic Keys + rules: [] + status: pending + - id: sa-9.7 + title: Organization-controlled Integrity Checking + rules: [] + status: pending + - id: sa-9.8 + title: Processing and Storage Location — U.S. Jurisdiction + rules: [] + status: pending + - id: sa-10 + title: Developer Configuration Management + levels: + - moderate + rules: [] + status: pending + - id: sa-10.1 + title: Software and Firmware Integrity Verification + rules: [] + status: pending + - id: sa-10.2 + title: Alternative Configuration Management Processes + rules: [] + status: pending + - id: sa-10.3 + title: Hardware Integrity Verification + rules: [] + status: pending + - id: sa-10.4 + title: Trusted Generation + rules: [] + status: pending + - id: sa-10.5 + title: Mapping Integrity for Version Control + rules: [] + status: pending + - id: sa-10.6 + title: Trusted Distribution + rules: [] + status: pending + - id: sa-10.7 + title: Security and Privacy Representatives + rules: [] + status: pending + - id: sa-11 + title: Developer Testing and Evaluation + levels: + - moderate + rules: [] + status: pending + - id: sa-11.1 + title: Static Code Analysis + rules: [] + status: pending + - id: sa-11.2 + title: Threat Modeling and Vulnerability Analyses + rules: [] + status: pending + - id: sa-11.3 + title: Independent Verification of Assessment Plans and Evidence + rules: [] + status: pending + - id: sa-11.4 + title: Manual Code Reviews + rules: [] + status: pending + - id: sa-11.5 + title: Penetration Testing + rules: [] + status: pending + - id: sa-11.6 + title: Attack Surface Reviews + rules: [] + status: pending + - id: sa-11.7 + title: Verify Scope of Testing and Evaluation + rules: [] + status: pending + - id: sa-11.8 + title: Dynamic Code Analysis + rules: [] + status: pending + - id: sa-11.9 + title: Interactive Application Security Testing + rules: [] + status: pending + - id: sa-12 + title: Supply Chain Protection + rules: [] + status: pending + - id: sa-12.1 + title: Acquisition Strategies / Tools / Methods + rules: [] + status: pending + - id: sa-12.2 + title: Supplier Reviews + rules: [] + status: pending + - id: sa-12.3 + title: Trusted Shipping and Warehousing + rules: [] + status: pending + - id: sa-12.4 + title: Diversity of Suppliers + rules: [] + status: pending + - id: sa-12.5 + title: Limitation of Harm + rules: [] + status: pending + - id: sa-12.6 + title: Minimizing Procurement Time + rules: [] + status: pending + - id: sa-12.7 + title: Assessments Prior to Selection / Acceptance / Update + rules: [] + status: pending + - id: sa-12.8 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: sa-12.9 + title: Operations Security + rules: [] + status: pending + - id: sa-12.10 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sa-12.11 + title: Penetration Testing / Analysis of Elements, Processes, and Actors + rules: [] + status: pending + - id: sa-12.12 + title: Inter-organizational Agreements + rules: [] + status: pending + - id: sa-12.13 + title: Critical Information System Components + rules: [] + status: pending + - id: sa-12.14 + title: Identity and Traceability + rules: [] + status: pending + - id: sa-12.15 + title: Processes to Address Weaknesses or Deficiencies + rules: [] + status: pending + - id: sa-13 + title: Trustworthiness + rules: [] + status: pending + - id: sa-14 + title: Criticality Analysis + rules: [] + status: pending + - id: sa-14.1 + title: Critical Components with No Viable Alternative Sourcing + rules: [] + status: pending + - id: sa-15 + title: Development Process, Standards, and Tools + levels: + - moderate + rules: [] + status: pending + - id: sa-15.1 + title: Quality Metrics + rules: [] + status: pending + - id: sa-15.2 + title: Security and Privacy Tracking Tools + rules: [] + status: pending + - id: sa-15.3 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: sa-15.4 + title: Threat Modeling and Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.5 + title: Attack Surface Reduction + rules: [] + status: pending + - id: sa-15.6 + title: Continuous Improvement + rules: [] + status: pending + - id: sa-15.7 + title: Automated Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.8 + title: Reuse of Threat and Vulnerability Information + rules: [] + status: pending + - id: sa-15.9 + title: Use of Live Data + rules: [] + status: pending + - id: sa-15.10 + title: Incident Response Plan + rules: [] + status: pending + - id: sa-15.11 + title: Archive System or Component + rules: [] + status: pending + - id: sa-15.12 + title: Minimize Personally Identifiable Information + rules: [] + status: pending + - id: sa-15.13 + title: Logging Syntax + rules: [] + status: pending + - id: sa-16 + title: Developer-provided Training + levels: + - high + rules: [] + status: pending + - id: sa-17 + title: Developer Security and Privacy Architecture and Design + levels: + - high + rules: [] + status: pending + - id: sa-17.1 + title: Formal Policy Model + rules: [] + status: pending + - id: sa-17.2 + title: Security-relevant Components + rules: [] + status: pending + - id: sa-17.3 + title: Formal Correspondence + rules: [] + status: pending + - id: sa-17.4 + title: Informal Correspondence + rules: [] + status: pending + - id: sa-17.5 + title: Conceptually Simple Design + rules: [] + status: pending + - id: sa-17.6 + title: Structure for Testing + rules: [] + status: pending + - id: sa-17.7 + title: Structure for Least Privilege + rules: [] + status: pending + - id: sa-17.8 + title: Orchestration + rules: [] + status: pending + - id: sa-17.9 + title: Design Diversity + rules: [] + status: pending + - id: sa-18 + title: Tamper Resistance and Detection + rules: [] + status: pending + - id: sa-18.1 + title: Multiple Phases of System Development Life Cycle + rules: [] + status: pending + - id: sa-18.2 + title: Inspection of Systems or Components + rules: [] + status: pending + - id: sa-19 + title: Component Authenticity + rules: [] + status: pending + - id: sa-19.1 + title: Anti-counterfeit Training + rules: [] + status: pending + - id: sa-19.2 + title: Configuration Control for Component Service and Repair + rules: [] + status: pending + - id: sa-19.3 + title: Component Disposal + rules: [] + status: pending + - id: sa-19.4 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sa-20 + title: Customized Development of Critical Components + rules: [] + status: pending + - id: sa-21 + title: Developer Screening + levels: + - high + rules: [] + status: pending + - id: sa-21.1 + title: Validation of Screening + rules: [] + status: pending + - id: sa-22 + title: Unsupported System Components + levels: + - low + rules: [] + status: pending + - id: sa-22.1 + title: Alternative Sources for Continued Support + rules: [] + status: pending + - id: sa-23 + title: Specialization + rules: [] + status: pending + - id: sa-24 + title: Design For Cyber Resiliency + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/sc.yml b/products/rhel8/controls/nist_800_53/sc.yml new file mode 100644 index 000000000000..1cea755d3a41 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/sc.yml @@ -0,0 +1,720 @@ +# NIST 800-53 SC Family: System and Communications Protection +controls: + - id: sc-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sc-2 + title: Separation of System and User Functionality + levels: + - moderate + rules: + - sysctl_kernel_dmesg_restrict + status: automated + - id: sc-2.1 + title: Interfaces for Non-privileged Users + rules: [] + status: pending + - id: sc-2.2 + title: Disassociability + rules: [] + status: pending + - id: sc-3 + title: Security Function Isolation + levels: + - high + rules: + - selinux_not_disabled + - selinux_state + - var_selinux_state=enforcing + status: automated + - id: sc-3.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-3.2 + title: Access and Flow Control Functions + rules: [] + status: pending + - id: sc-3.3 + title: Minimize Nonsecurity Functionality + rules: [] + status: pending + - id: sc-3.4 + title: Module Coupling and Cohesiveness + rules: [] + status: pending + - id: sc-3.5 + title: Layered Structures + rules: [] + status: pending + - id: sc-4 + title: Information in Shared System Resources + levels: + - moderate + rules: + - dir_perms_world_writable_sticky_bits + - file_permissions_unauthorized_world_writable + status: automated + - id: sc-4.1 + title: Security Levels + rules: [] + status: pending + - id: sc-4.2 + title: Multilevel or Periods Processing + rules: [] + status: pending + - id: sc-5 + title: Denial-of-service Protection + levels: + - low + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + - id: sc-5.1 + title: Restrict Ability to Attack Other Systems + rules: [] + status: pending + - id: sc-5.2 + title: Capacity, Bandwidth, and Redundancy + rules: [] + status: pending + - id: sc-5.3 + title: Detection and Monitoring + rules: [] + status: pending + - id: sc-6 + title: Resource Availability + rules: [] + status: pending + - id: sc-7 + title: Boundary Protection + levels: + - low + rules: + - service_firewalld_enabled + status: automated + - id: sc-7.1 + title: Physically Separated Subnetworks + rules: [] + status: pending + - id: sc-7.2 + title: Public Access + rules: [] + status: pending + - id: sc-7.3 + title: Access Points + levels: + - moderate + rules: [] + status: pending + - id: sc-7.4 + title: External Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: sc-7.5 + title: Deny by Default — Allow by Exception + levels: + - moderate + rules: [] + status: pending + - id: sc-7.6 + title: Response to Recognized Failures + rules: [] + status: pending + - id: sc-7.7 + title: Split Tunneling for Remote Devices + levels: + - moderate + rules: [] + status: pending + - id: sc-7.8 + title: Route Traffic to Authenticated Proxy Servers + levels: + - moderate + rules: [] + status: pending + - id: sc-7.9 + title: Restrict Threatening Outgoing Communications Traffic + rules: [] + status: pending + - id: sc-7.10 + title: Prevent Exfiltration + rules: [] + status: pending + - id: sc-7.11 + title: Restrict Incoming Communications Traffic + rules: [] + status: pending + - id: sc-7.12 + title: Host-based Protection + rules: [] + status: pending + - id: sc-7.13 + title: Isolation of Security Tools, Mechanisms, and Support Components + rules: [] + status: pending + - id: sc-7.14 + title: Protect Against Unauthorized Physical Connections + rules: [] + status: pending + - id: sc-7.15 + title: Networked Privileged Accesses + rules: [] + status: pending + - id: sc-7.16 + title: Prevent Discovery of System Components + rules: [] + status: pending + - id: sc-7.17 + title: Automated Enforcement of Protocol Formats + rules: [] + status: pending + - id: sc-7.18 + title: Fail Secure + levels: + - high + rules: [] + status: pending + - id: sc-7.19 + title: Block Communication from Non-organizationally Configured Hosts + rules: [] + status: pending + - id: sc-7.20 + title: Dynamic Isolation and Segregation + rules: [] + status: pending + - id: sc-7.21 + title: Isolation of System Components + levels: + - high + rules: [] + status: pending + - id: sc-7.22 + title: Separate Subnets for Connecting to Different Security Domains + rules: [] + status: pending + - id: sc-7.23 + title: Disable Sender Feedback on Protocol Validation Failure + rules: [] + status: pending + - id: sc-7.24 + title: Personally Identifiable Information + rules: [] + status: pending + - id: sc-7.25 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: sc-7.26 + title: Classified National Security System Connections + rules: [] + status: pending + - id: sc-7.27 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: sc-7.28 + title: Connections to Public Networks + rules: [] + status: pending + - id: sc-7.29 + title: Separate Subnets to Isolate Functions + rules: [] + status: pending + - id: sc-8 + title: Transmission Confidentiality and Integrity + levels: + - moderate + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: sc-8.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-8.2 + title: Pre- and Post-transmission Handling + rules: [] + status: pending + - id: sc-8.3 + title: Cryptographic Protection for Message Externals + rules: [] + status: pending + - id: sc-8.4 + title: Conceal or Randomize Communications + rules: [] + status: pending + - id: sc-8.5 + title: Protected Distribution System + rules: [] + status: pending + - id: sc-9 + title: Transmission Confidentiality + rules: [] + status: pending + - id: sc-10 + title: Network Disconnect + levels: + - moderate + rules: [] + status: pending + - id: sc-11 + title: Trusted Path + rules: [] + status: pending + - id: sc-11.1 + title: Irrefutable Communications Path + rules: [] + status: pending + - id: sc-12 + title: Cryptographic Key Establishment and Management + levels: + - low + rules: [] + status: pending + - id: sc-12.1 + title: Availability + levels: + - high + rules: [] + status: pending + - id: sc-12.2 + title: Symmetric Keys + rules: [] + status: pending + - id: sc-12.3 + title: Asymmetric Keys + rules: [] + status: pending + - id: sc-12.4 + title: PKI Certificates + rules: [] + status: pending + - id: sc-12.5 + title: PKI Certificates / Hardware Tokens + rules: [] + status: pending + - id: sc-12.6 + title: Physical Control of Keys + rules: [] + status: pending + - id: sc-13 + title: Cryptographic Protection + levels: + - low + rules: [] + status: pending + - id: sc-13.1 + title: FIPS-validated Cryptography + rules: [] + status: pending + - id: sc-13.2 + title: NSA-approved Cryptography + rules: [] + status: pending + - id: sc-13.3 + title: Individuals Without Formal Access Approvals + rules: [] + status: pending + - id: sc-13.4 + title: Digital Signatures + rules: [] + status: pending + - id: sc-14 + title: Public Access Protections + rules: [] + status: pending + - id: sc-15 + title: Collaborative Computing Devices and Applications + levels: + - low + rules: [] + status: pending + - id: sc-15.1 + title: Physical or Logical Disconnect + rules: [] + status: pending + - id: sc-15.2 + title: Blocking Inbound and Outbound Communications Traffic + rules: [] + status: pending + - id: sc-15.3 + title: Disabling and Removal in Secure Work Areas + rules: [] + status: pending + - id: sc-15.4 + title: Explicitly Indicate Current Participants + rules: [] + status: pending + - id: sc-16 + title: Transmission of Security and Privacy Attributes + rules: [] + status: pending + - id: sc-16.1 + title: Integrity Verification + rules: [] + status: pending + - id: sc-16.2 + title: Anti-spoofing Mechanisms + rules: [] + status: pending + - id: sc-16.3 + title: Cryptographic Binding + rules: [] + status: pending + - id: sc-17 + title: Public Key Infrastructure Certificates + levels: + - moderate + rules: [] + status: pending + - id: sc-18 + title: Mobile Code + levels: + - moderate + rules: [] + status: pending + - id: sc-18.1 + title: Identify Unacceptable Code and Take Corrective Actions + rules: [] + status: pending + - id: sc-18.2 + title: Acquisition, Development, and Use + rules: [] + status: pending + - id: sc-18.3 + title: Prevent Downloading and Execution + rules: [] + status: pending + - id: sc-18.4 + title: Prevent Automatic Execution + rules: [] + status: pending + - id: sc-18.5 + title: Allow Execution Only in Confined Environments + rules: [] + status: pending + - id: sc-19 + title: Voice Over Internet Protocol + rules: [] + status: pending + - id: sc-20 + title: Secure Name/Address Resolution Service (Authoritative Source) + levels: + - low + rules: [] + status: pending + - id: sc-20.1 + title: Child Subspaces + rules: [] + status: pending + - id: sc-20.2 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-21 + title: Secure Name/Address Resolution Service (Recursive or Caching Resolver) + levels: + - low + rules: [] + status: pending + - id: sc-21.1 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-22 + title: Architecture and Provisioning for Name/Address Resolution Service + levels: + - low + rules: [] + status: pending + - id: sc-23 + title: Session Authenticity + levels: + - moderate + rules: [] + status: pending + - id: sc-23.1 + title: Invalidate Session Identifiers at Logout + rules: [] + status: pending + - id: sc-23.2 + title: User-initiated Logouts and Message Displays + rules: [] + status: pending + - id: sc-23.3 + title: Unique System-generated Session Identifiers + rules: [] + status: pending + - id: sc-23.4 + title: Unique Session Identifiers with Randomization + rules: [] + status: pending + - id: sc-23.5 + title: Allowed Certificate Authorities + rules: [] + status: pending + - id: sc-24 + title: Fail in Known State + levels: + - high + rules: + - service_systemd-journald_enabled + status: automated + - id: sc-25 + title: Thin Nodes + rules: [] + status: pending + - id: sc-26 + title: Decoys + rules: [] + status: pending + - id: sc-26.1 + title: Detection of Malicious Code + rules: [] + status: pending + - id: sc-27 + title: Platform-independent Applications + rules: [] + status: pending + - id: sc-28 + title: Protection of Information at Rest + levels: + - moderate + rules: [] + status: pending + - id: sc-28.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-28.2 + title: Offline Storage + rules: [] + status: pending + - id: sc-28.3 + title: Cryptographic Keys + rules: [] + status: pending + - id: sc-29 + title: Heterogeneity + rules: [] + status: pending + - id: sc-29.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30 + title: Concealment and Misdirection + rules: [] + status: pending + - id: sc-30.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30.2 + title: Randomness + rules: [] + status: pending + - id: sc-30.3 + title: Change Processing and Storage Locations + rules: [] + status: pending + - id: sc-30.4 + title: Misleading Information + rules: [] + status: pending + - id: sc-30.5 + title: Concealment of System Components + rules: [] + status: pending + - id: sc-31 + title: Covert Channel Analysis + rules: [] + status: pending + - id: sc-31.1 + title: Test Covert Channels for Exploitability + rules: [] + status: pending + - id: sc-31.2 + title: Maximum Bandwidth + rules: [] + status: pending + - id: sc-31.3 + title: Measure Bandwidth in Operational Environments + rules: [] + status: pending + - id: sc-32 + title: System Partitioning + rules: [] + status: pending + - id: sc-32.1 + title: Separate Physical Domains for Privileged Functions + rules: [] + status: pending + - id: sc-33 + title: Transmission Preparation Integrity + rules: [] + status: pending + - id: sc-34 + title: Non-modifiable Executable Programs + rules: [] + status: pending + - id: sc-34.1 + title: No Writable Storage + rules: [] + status: pending + - id: sc-34.2 + title: Integrity Protection on Read-only Media + rules: [] + status: pending + - id: sc-34.3 + title: Hardware-based Protection + rules: [] + status: pending + - id: sc-35 + title: External Malicious Code Identification + rules: [] + status: pending + - id: sc-36 + title: Distributed Processing and Storage + rules: [] + status: pending + - id: sc-36.1 + title: Polling Techniques + rules: [] + status: pending + - id: sc-36.2 + title: Synchronization + rules: [] + status: pending + - id: sc-37 + title: Out-of-band Channels + rules: [] + status: pending + - id: sc-37.1 + title: Ensure Delivery and Transmission + rules: [] + status: pending + - id: sc-38 + title: Operations Security + rules: [] + status: pending + - id: sc-39 + title: Process Isolation + levels: + - low + rules: [] + status: pending + - id: sc-39.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-39.2 + title: Separate Execution Domain Per Thread + rules: [] + status: pending + - id: sc-40 + title: Wireless Link Protection + rules: [] + status: pending + - id: sc-40.1 + title: Electromagnetic Interference + rules: [] + status: pending + - id: sc-40.2 + title: Reduce Detection Potential + rules: [] + status: pending + - id: sc-40.3 + title: Imitative or Manipulative Communications Deception + rules: [] + status: pending + - id: sc-40.4 + title: Signal Parameter Identification + rules: [] + status: pending + - id: sc-41 + title: Port and I/O Device Access + rules: [] + status: pending + - id: sc-42 + title: Sensor Capability and Data + rules: [] + status: pending + - id: sc-42.1 + title: Reporting to Authorized Individuals or Roles + rules: [] + status: pending + - id: sc-42.2 + title: Authorized Use + rules: [] + status: pending + - id: sc-42.3 + title: Prohibit Use of Devices + rules: [] + status: pending + - id: sc-42.4 + title: Notice of Collection + rules: [] + status: pending + - id: sc-42.5 + title: Collection Minimization + rules: [] + status: pending + - id: sc-43 + title: Usage Restrictions + rules: [] + status: pending + - id: sc-44 + title: Detonation Chambers + rules: [] + status: pending + - id: sc-45 + title: System Time Synchronization + rules: [] + status: pending + - id: sc-45.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: sc-45.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: sc-46 + title: Cross Domain Policy Enforcement + rules: [] + status: pending + - id: sc-47 + title: Alternate Communications Paths + rules: [] + status: pending + - id: sc-48 + title: Sensor Relocation + rules: [] + status: pending + - id: sc-48.1 + title: Dynamic Relocation of Sensors or Monitoring Capabilities + rules: [] + status: pending + - id: sc-49 + title: Hardware-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-50 + title: Software-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-51 + title: Hardware-based Protection + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/si.yml b/products/rhel8/controls/nist_800_53/si.yml new file mode 100644 index 000000000000..4cabcafda2db --- /dev/null +++ b/products/rhel8/controls/nist_800_53/si.yml @@ -0,0 +1,545 @@ +# NIST 800-53 SI Family: System and Information Integrity +controls: + - id: si-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: si-2 + title: Flaw Remediation + levels: + - low + rules: + - ensure_gpgcheck_globally_activated + - ensure_gpgcheck_never_disabled + - ensure_redhat_gpgkey_installed + status: automated + - id: si-2.1 + title: Central Management + rules: [] + status: pending + - id: si-2.2 + title: Automated Flaw Remediation Status + levels: + - moderate + rules: [] + status: pending + - id: si-2.3 + title: Time to Remediate Flaws and Benchmarks for Corrective Actions + rules: [] + status: pending + - id: si-2.4 + title: Automated Patch Management Tools + rules: [] + status: pending + - id: si-2.5 + title: Automatic Software and Firmware Updates + rules: [] + status: pending + - id: si-2.6 + title: Removal of Previous Versions of Software and Firmware + rules: [] + status: pending + - id: si-2.7 + title: Root Cause Analysis + rules: [] + status: pending + - id: si-3 + title: Malicious Code Protection + levels: + - low + rules: + - kernel_module_usb-storage_disabled + - service_autofs_disabled + status: automated + - id: si-3.1 + title: Central Management + rules: [] + status: pending + - id: si-3.2 + title: Automatic Updates + rules: [] + status: pending + - id: si-3.3 + title: Non-privileged Users + rules: [] + status: pending + - id: si-3.4 + title: Updates Only by Privileged Users + rules: [] + status: pending + - id: si-3.5 + title: Portable Storage Devices + rules: [] + status: pending + - id: si-3.6 + title: Testing and Verification + rules: [] + status: pending + - id: si-3.7 + title: Nonsignature-based Detection + rules: [] + status: pending + - id: si-3.8 + title: Detect Unauthorized Commands + rules: [] + status: pending + - id: si-3.9 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: si-3.10 + title: Malicious Code Analysis + rules: [] + status: pending + - id: si-4 + title: System Monitoring + levels: + - low + rules: + - kernel_module_dccp_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_tipc_disabled + - service_avahi-daemon_disabled + status: automated + - id: si-4.1 + title: System-wide Intrusion Detection System + rules: [] + status: pending + - id: si-4.2 + title: Automated Tools and Mechanisms for Real-time Analysis + levels: + - moderate + rules: [] + status: pending + - id: si-4.3 + title: Automated Tool and Mechanism Integration + rules: [] + status: pending + - id: si-4.4 + title: Inbound and Outbound Communications Traffic + levels: + - moderate + rules: [] + status: pending + - id: si-4.5 + title: System-generated Alerts + levels: + - moderate + rules: [] + status: pending + - id: si-4.6 + title: Restrict Non-privileged Users + rules: [] + status: pending + - id: si-4.7 + title: Automated Response to Suspicious Events + rules: [] + status: pending + - id: si-4.8 + title: Protection of Monitoring Information + rules: [] + status: pending + - id: si-4.9 + title: Testing of Monitoring Tools and Mechanisms + rules: [] + status: pending + - id: si-4.10 + title: Visibility of Encrypted Communications + levels: + - high + rules: [] + status: pending + - id: si-4.11 + title: Analyze Communications Traffic Anomalies + rules: [] + status: pending + - id: si-4.12 + title: Automated Organization-generated Alerts + levels: + - high + rules: [] + status: pending + - id: si-4.13 + title: Analyze Traffic and Event Patterns + rules: [] + status: pending + - id: si-4.14 + title: Wireless Intrusion Detection + levels: + - high + rules: [] + status: pending + - id: si-4.15 + title: Wireless to Wireline Communications + rules: [] + status: pending + - id: si-4.16 + title: Correlate Monitoring Information + rules: [] + status: pending + - id: si-4.17 + title: Integrated Situational Awareness + rules: [] + status: pending + - id: si-4.18 + title: Analyze Traffic and Covert Exfiltration + rules: [] + status: pending + - id: si-4.19 + title: Risk for Individuals + rules: [] + status: pending + - id: si-4.20 + title: Privileged Users + levels: + - high + rules: [] + status: pending + - id: si-4.21 + title: Probationary Periods + rules: [] + status: pending + - id: si-4.22 + title: Unauthorized Network Services + levels: + - high + rules: [] + status: pending + - id: si-4.23 + title: Host-based Devices + rules: [] + status: pending + - id: si-4.24 + title: Indicators of Compromise + rules: [] + status: pending + - id: si-4.25 + title: Optimize Network Traffic Analysis + rules: [] + status: pending + - id: si-5 + title: Security Alerts, Advisories, and Directives + levels: + - low + rules: [] + status: pending + - id: si-5.1 + title: Automated Alerts and Advisories + levels: + - high + rules: [] + status: pending + - id: si-6 + title: Security and Privacy Function Verification + levels: + - high + rules: [] + status: pending + - id: si-6.1 + title: Notification of Failed Security Tests + rules: [] + status: pending + - id: si-6.2 + title: Automation Support for Distributed Testing + rules: [] + status: pending + - id: si-6.3 + title: Report Verification Results + rules: [] + status: pending + - id: si-7 + title: Software, Firmware, and Information Integrity + levels: + - moderate + rules: [] + status: pending + - id: si-7.1 + title: Integrity Checks + levels: + - moderate + rules: [] + status: pending + - id: si-7.2 + title: Automated Notifications of Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.3 + title: Centrally Managed Integrity Tools + rules: [] + status: pending + - id: si-7.4 + title: Tamper-evident Packaging + rules: [] + status: pending + - id: si-7.5 + title: Automated Response to Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: si-7.7 + title: Integration of Detection and Response + levels: + - moderate + rules: [] + status: pending + - id: si-7.8 + title: Auditing Capability for Significant Events + rules: [] + status: pending + - id: si-7.9 + title: Verify Boot Process + rules: [] + status: pending + - id: si-7.10 + title: Protection of Boot Firmware + rules: [] + status: pending + - id: si-7.11 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: si-7.12 + title: Integrity Verification + rules: [] + status: pending + - id: si-7.13 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: si-7.14 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: si-7.15 + title: Code Authentication + levels: + - high + rules: [] + status: pending + - id: si-7.16 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-7.17 + title: Runtime Application Self-protection + rules: [] + status: pending + - id: si-8 + title: Spam Protection + levels: + - moderate + rules: [] + status: pending + - id: si-8.1 + title: Central Management + rules: [] + status: pending + - id: si-8.2 + title: Automatic Updates + levels: + - moderate + rules: [] + status: pending + - id: si-8.3 + title: Continuous Learning Capability + rules: [] + status: pending + - id: si-9 + title: Information Input Restrictions + rules: [] + status: pending + - id: si-10 + title: Information Input Validation + levels: + - moderate + rules: [] + status: pending + - id: si-10.1 + title: Manual Override Capability + rules: [] + status: pending + - id: si-10.2 + title: Review and Resolve Errors + rules: [] + status: pending + - id: si-10.3 + title: Predictable Behavior + rules: [] + status: pending + - id: si-10.4 + title: Timing Interactions + rules: [] + status: pending + - id: si-10.5 + title: Restrict Inputs to Trusted Sources and Approved Formats + rules: [] + status: pending + - id: si-10.6 + title: Injection Prevention + rules: [] + status: pending + - id: si-11 + title: Error Handling + levels: + - moderate + rules: [] + status: pending + - id: si-12 + title: Information Management and Retention + levels: + - low + rules: [] + status: pending + - id: si-12.1 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: si-12.2 + title: Minimize Personally Identifiable Information in Testing, Training, and Research + rules: [] + status: pending + - id: si-12.3 + title: Information Disposal + rules: [] + status: pending + - id: si-13 + title: Predictable Failure Prevention + rules: [] + status: pending + - id: si-13.1 + title: Transferring Component Responsibilities + rules: [] + status: pending + - id: si-13.2 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-13.3 + title: Manual Transfer Between Components + rules: [] + status: pending + - id: si-13.4 + title: Standby Component Installation and Notification + rules: [] + status: pending + - id: si-13.5 + title: Failover Capability + rules: [] + status: pending + - id: si-14 + title: Non-persistence + rules: [] + status: pending + - id: si-14.1 + title: Refresh from Trusted Sources + rules: [] + status: pending + - id: si-14.2 + title: Non-persistent Information + rules: [] + status: pending + - id: si-14.3 + title: Non-persistent Connectivity + rules: [] + status: pending + - id: si-15 + title: Information Output Filtering + rules: [] + status: pending + - id: si-16 + title: Memory Protection + levels: + - moderate + rules: + - sysctl_kernel_randomize_va_space + status: automated + - id: si-17 + title: Fail-safe Procedures + rules: [] + status: pending + - id: si-18 + title: Personally Identifiable Information Quality Operations + rules: [] + status: pending + - id: si-18.1 + title: Automation Support + rules: [] + status: pending + - id: si-18.2 + title: Data Tags + rules: [] + status: pending + - id: si-18.3 + title: Collection + rules: [] + status: pending + - id: si-18.4 + title: Individual Requests + rules: [] + status: pending + - id: si-18.5 + title: Notice of Correction or Deletion + rules: [] + status: pending + - id: si-19 + title: De-identification + rules: [] + status: pending + - id: si-19.1 + title: Collection + rules: [] + status: pending + - id: si-19.2 + title: Archiving + rules: [] + status: pending + - id: si-19.3 + title: Release + rules: [] + status: pending + - id: si-19.4 + title: Removal, Masking, Encryption, Hashing, or Replacement of Direct Identifiers + rules: [] + status: pending + - id: si-19.5 + title: Statistical Disclosure Control + rules: [] + status: pending + - id: si-19.6 + title: Differential Privacy + rules: [] + status: pending + - id: si-19.7 + title: Validated Algorithms and Software + rules: [] + status: pending + - id: si-19.8 + title: Motivated Intruder + rules: [] + status: pending + - id: si-20 + title: Tainting + rules: [] + status: pending + - id: si-21 + title: Information Refresh + rules: [] + status: pending + - id: si-22 + title: Information Diversity + rules: [] + status: pending + - id: si-23 + title: Information Fragmentation + rules: [] + status: pending diff --git a/products/rhel8/controls/nist_800_53/sr.yml b/products/rhel8/controls/nist_800_53/sr.yml new file mode 100644 index 000000000000..1e130f32cd89 --- /dev/null +++ b/products/rhel8/controls/nist_800_53/sr.yml @@ -0,0 +1,138 @@ +# NIST 800-53 SR Family: Supply Chain Risk Management +controls: + - id: sr-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sr-2 + title: Supply Chain Risk Management Plan + levels: + - low + rules: [] + status: pending + - id: sr-2.1 + title: Establish SCRM Team + levels: + - low + rules: [] + status: pending + - id: sr-3 + title: Supply Chain Controls and Processes + levels: + - low + rules: [] + status: pending + - id: sr-3.1 + title: Diverse Supply Base + rules: [] + status: pending + - id: sr-3.2 + title: Limitation of Harm + rules: [] + status: pending + - id: sr-3.3 + title: Sub-tier Flow Down + rules: [] + status: pending + - id: sr-4 + title: Provenance + rules: [] + status: pending + - id: sr-4.1 + title: Identity + rules: [] + status: pending + - id: sr-4.2 + title: Track and Trace + rules: [] + status: pending + - id: sr-4.3 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sr-4.4 + title: Supply Chain Integrity — Pedigree + rules: [] + status: pending + - id: sr-5 + title: Acquisition Strategies, Tools, and Methods + levels: + - low + rules: [] + status: pending + - id: sr-5.1 + title: Adequate Supply + rules: [] + status: pending + - id: sr-5.2 + title: Assessments Prior to Selection, Acceptance, Modification, or Update + rules: [] + status: pending + - id: sr-6 + title: Supplier Assessments and Reviews + levels: + - moderate + rules: [] + status: pending + - id: sr-6.1 + title: Testing and Analysis + rules: [] + status: pending + - id: sr-7 + title: Supply Chain Operations Security + rules: [] + status: pending + - id: sr-8 + title: Notification Agreements + levels: + - low + rules: [] + status: pending + - id: sr-9 + title: Tamper Resistance and Detection + levels: + - high + rules: [] + status: pending + - id: sr-9.1 + title: Multiple Stages of System Development Life Cycle + levels: + - high + rules: [] + status: pending + - id: sr-10 + title: Inspection of Systems or Components + levels: + - low + rules: [] + status: pending + - id: sr-11 + title: Component Authenticity + levels: + - low + rules: [] + status: pending + - id: sr-11.1 + title: Anti-counterfeit Training + levels: + - low + rules: [] + status: pending + - id: sr-11.2 + title: Configuration Control for Component Service and Repair + levels: + - low + rules: [] + status: pending + - id: sr-11.3 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sr-12 + title: Component Disposal + levels: + - low + rules: [] + status: pending diff --git a/products/rhel8/controls/stig_rhel8.yml b/products/rhel8/controls/stig_rhel8.yml index b70ea1d7eab9..7a67bd20eb9b 100644 --- a/products/rhel8/controls/stig_rhel8.yml +++ b/products/rhel8/controls/stig_rhel8.yml @@ -2,7 +2,7 @@ policy: Red Hat Enterprise Linux 8 Security Technical Implementation Guide title: Red Hat Enterprise Linux 8 Security Technical Implementation Guide id: stig_rhel8 -version: V2R5 +version: V2R7 source: https://www.cyber.mil/stigs/downloads reference_type: stigid product: rhel8 @@ -67,17 +67,12 @@ controls: - var_auditd_disk_full_action=rhel8 - var_sssd_certificate_verification_digest_function=sha1 - login_banner_text=dod_banners + - login_banner_contents=dod_default + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default - var_authselect_profile=sssd - var_multiple_time_servers=stig - var_time_service_set_maxpoll=18_hours - # Enable / Configure FIPS - - enable_fips_mode - - var_system_crypto_policy=fips - - configure_crypto_policy - - configure_bind_crypto_policy - - configure_libreswan_crypto_policy - - configure_kerberos_crypto_policy - - enable_dracut_fips_module # Other needed rules - enable_authselect @@ -97,24 +92,23 @@ controls: - security_patches_up_to_date status: automated + - id: RHEL-08-010015 + levels: + - high + title: RHEL 8 must have the crypto-policies package installed. + rules: + - package_crypto-policies_installed + status: automated + - id: RHEL-08-010020 levels: - high - title: 'RHEL 8 must implement NIST FIPS-validated cryptography for the following: To provision - digital signatures, to generate cryptographic hashes, and to protect data requiring data-at-rest - protections in accordance with applicable federal laws, Executive Orders, directives, policies, - regulations, and standards.' + title: RHEL 8 must implement a FIPS 140-3-compliant systemwide cryptographic policy. rules: - - configure_bind_crypto_policy - configure_crypto_policy - - configure_kerberos_crypto_policy - - configure_libreswan_crypto_policy - - enable_dracut_fips_module - - enable_fips_mode - fips_crypto_subpolicy - - harden_sshd_ciphers_openssh_conf_crypto_policy - - harden_sshd_macs_openssh_conf_crypto_policy - - sysctl_crypto_fips_enabled + - fips_custom_stig_sub_policy + - var_system_crypto_policy=fips_stig status: automated - id: RHEL-08-010030 @@ -338,54 +332,62 @@ controls: - file_groupowner_var_log status: automated - - id: RHEL-08-010290 + - id: RHEL-08-010270 levels: - - medium - title: The RHEL 8 SSH server must be configured to use only Message Authentication Codes (MACs) - employing FIPS 140-3 validated cryptographic hash algorithms. + - high + title: RHEL 8 cryptographic policy must not be overridden. rules: - - harden_sshd_macs_opensshserver_conf_crypto_policy + - configure_crypto_policy status: automated - - id: RHEL-08-010291 + - id: RHEL-08-010275 levels: - medium - title: The RHEL 8 operating system must implement DOD-approved encryption to protect the confidentiality - of SSH server connections. + title: RHEL 8 must implement DOD-approved encryption in the bind package. rules: - - harden_sshd_ciphers_opensshserver_conf_crypto_policy + - configure_bind_crypto_policy status: automated - - id: RHEL-08-010292 + - id: RHEL-08-010280 levels: - - low - title: RHEL 8 must ensure the SSH server uses strong entropy. + - medium + title: RHEL 8 IP tunnels must use FIPS 140-3-approved cryptographic algorithms. rules: - - sshd_use_strong_rng + - configure_libreswan_crypto_policy status: automated - - id: RHEL-08-010293 + - id: RHEL-08-010290 levels: - medium - title: The RHEL 8 operating system must implement DoD-approved encryption in the OpenSSL package. + title: The RHEL 8 SSH server must be configured to use only Message Authentication Codes (MACs) + employing FIPS 140-3 validated cryptographic hash algorithms. + notes: This is implemented by a special STIG subpolicy. rules: - - configure_openssl_crypto_policy + - configure_crypto_policy + - fips_crypto_subpolicy + - fips_custom_stig_sub_policy + - var_system_crypto_policy=fips_stig status: automated - - id: RHEL-08-010294 + - id: RHEL-08-010291 levels: - medium - title: The RHEL 8 operating system must implement DoD-approved TLS encryption in the OpenSSL package. + title: The RHEL 8 operating system must implement DOD-approved encryption to protect the confidentiality + of SSH server connections. + notes: This is implemented by a special STIG subpolicy. rules: - - configure_openssl_tls_crypto_policy + - configure_crypto_policy + - fips_crypto_subpolicy + - fips_custom_stig_sub_policy + - var_system_crypto_policy=fips_stig status: automated - - id: RHEL-08-010295 + - id: RHEL-08-010292 levels: - - medium - title: The RHEL 8 operating system must implement DoD-approved TLS encryption in the GnuTLS package. + - low + title: RHEL 8 must ensure the SSH server uses strong entropy. rules: - - configure_gnutls_tls_crypto_policy + - sshd_use_strong_rng status: automated - id: RHEL-08-010300 @@ -807,14 +809,6 @@ controls: - mount_option_nosuid_remote_filesystems status: automated - - id: RHEL-08-010660 - levels: - - medium - title: Local RHEL 8 initialization files must not execute world-writable programs. - rules: - - accounts_user_dot_no_world_writable_programs - status: automated - - id: RHEL-08-010670 levels: - medium @@ -975,6 +969,7 @@ controls: equivalent). rules: - partition_for_home + - accounts_user_interactive_home_directory_on_separate_partition status: automated - id: RHEL-08-010820 @@ -1375,14 +1370,6 @@ controls: - sshd_disable_empty_passwords status: automated - - id: RHEL-08-020340 - levels: - - low - title: RHEL 8 must display the date and time of the last successful account logon upon logon. - rules: - - display_login_attempts - status: automated - - id: RHEL-08-020350 levels: - medium @@ -1418,6 +1405,16 @@ controls: - accounts_umask_etc_profile status: automated + - id: RHEL-08-020353 + levels: + - medium + title: RHEL 8 must automatically exit interactive command shell user sessions after 10 minutes of inactivity. + rules: + - accounts_tmout + - var_accounts_tmout=10_min + status: automated + + - id: RHEL-08-030000 levels: - medium @@ -2124,6 +2121,7 @@ controls: title: RHEL 8 must disable network management of the chrony daemon. rules: - chronyd_no_chronyc_network + - chronyd_configure_local_socket status: automated - id: RHEL-08-040000 @@ -2810,14 +2808,6 @@ controls: - sshd_set_idle_timeout status: automated - - id: RHEL-08-010287 - levels: - - medium - title: The RHEL 8 SSH daemon must be configured to use system-wide crypto policies. - rules: - - configure_ssh_crypto_policy - status: automated - - id: RHEL-08-010472 levels: - low @@ -3159,14 +3149,6 @@ controls: - selinux_user_login_roles status: automated - - id: RHEL-08-040342 - levels: - - medium - title: RHEL 8 SSH server must be configured to use only FIPS-validated key exchange algorithms. - rules: - - sshd_use_approved_kex_ordered_stig - status: automated - - id: RHEL-08-010019 levels: - medium @@ -3204,20 +3186,26 @@ controls: - id: RHEL-08-010296 levels: - medium - title: RHEL 8 SSH client must be configured to use only Message Authentication Codes (MACs) employing - FIPS 140-3 validated cryptographic hash algorithms. + title: The RHEL 8 SSH client must be configured to use only DOD-approved Message Authentication Codes (MACs) employing FIPS 140-3-validated cryptographic hash algorithms to protect the confidentiality of SSH client connections. + notes: This is implemented by a special STIG subpolicy. rules: - - harden_sshd_ciphers_openssh_conf_crypto_policy - - harden_sshd_macs_openssh_conf_crypto_policy + - configure_crypto_policy + - fips_crypto_subpolicy + - fips_custom_stig_sub_policy + - var_system_crypto_policy=fips_stig status: automated - id: RHEL-08-010297 levels: - medium - title: RHEL 8 SSH client must be configured to use only ciphers employing FIPS 140-3 validated - cryptographic hash algorithms. - rules: [] - status: pending + title: The RHEL 8 SSH client must be configured to use only DOD-approved encryption ciphers employing FIPS 140-3-validated cryptographic hash algorithms to protect the confidentiality of SSH client connections. + notes: This is implemented by a special STIG subpolicy. + rules: + - configure_crypto_policy + - fips_crypto_subpolicy + - fips_custom_stig_sub_policy + - var_system_crypto_policy=fips_stig + status: automated - id: RHEL-08-010455 levels: diff --git a/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_enhanced-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_enhanced-ks.cfg index 74fc1bfcc934..069855e80d26 100644 --- a/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_enhanced-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_enhanced-ks.cfg @@ -80,35 +80,36 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=3192 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6536 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid" +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /srv Located On Separate Partition -logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid" +logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=512 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log Located On Separate Partition logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition @@ -117,17 +118,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/performing_an_advanced_rhel_8_installation/kickstart-commands-and-options-reference_installing-rhel-as-an-experienced-user#addon-org_fedora_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon org_fedora_oscap diff --git a/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_high-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_high-ks.cfg index 58eb988ab11f..3477225767b6 100644 --- a/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_high-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_high-ks.cfg @@ -84,35 +84,36 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=3192 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6536 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid" +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /srv Located On Separate Partition -logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid" +logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=512 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log Located On Separate Partition logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition @@ -122,17 +123,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/performing_an_advanced_rhel_8_installation/kickstart-commands-and-options-reference_installing-rhel-as-an-experienced-user#addon-org_fedora_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon org_fedora_oscap diff --git a/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_intermediary-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_intermediary-ks.cfg index 09755ea7ab54..5789b94da59d 100644 --- a/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_intermediary-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-anssi_bp28_intermediary-ks.cfg @@ -81,35 +81,36 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=3192 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6536 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid" +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /srv Located On Separate Partition -logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid" +logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=512 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log Located On Separate Partition logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition @@ -118,17 +119,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/performing_an_advanced_rhel_8_installation/kickstart-commands-and-options-reference_installing-rhel-as-an-experienced-user#addon-org_fedora_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon org_fedora_oscap diff --git a/products/rhel8/kickstart/ssg-rhel8-cis-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-cis-ks.cfg index 60e0081eea3b..b482de7e05ed 100644 --- a/products/rhel8/kickstart/ssg-rhel8-cis-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-cis-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel8/kickstart/ssg-rhel8-cis_server_l1-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-cis_server_l1-ks.cfg index 68f0d8b8d5a8..6dda7c1a9ac3 100644 --- a/products/rhel8/kickstart/ssg-rhel8-cis_server_l1-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-cis_server_l1-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l1-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l1-ks.cfg index 68f8958d1500..028728e494d5 100644 --- a/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l1-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l1-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l2-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l2-ks.cfg index 7fbf68e7793b..5ed02f55f1cf 100644 --- a/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l2-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-cis_workstation_l2-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel8/kickstart/ssg-rhel8-cui-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-cui-ks.cfg index 96f140344c5d..5a41305ae85d 100644 --- a/products/rhel8/kickstart/ssg-rhel8-cui-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-cui-ks.cfg @@ -86,18 +86,19 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition diff --git a/products/rhel8/kickstart/ssg-rhel8-ospp-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-ospp-ks.cfg index 921df42221fd..b7c654666ba3 100644 --- a/products/rhel8/kickstart/ssg-rhel8-ospp-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-ospp-ks.cfg @@ -86,18 +86,19 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition diff --git a/products/rhel8/kickstart/ssg-rhel8-pci-dss-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-pci-dss-ks.cfg index af3eee9f0d0f..fff38dc2e77e 100644 --- a/products/rhel8/kickstart/ssg-rhel8-pci-dss-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-pci-dss-ks.cfg @@ -83,16 +83,17 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=11264 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # CCE-26557-9: Ensure /home Located On Separate Partition logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" # CCE-26435-8: Ensure /tmp Located On Separate Partition diff --git a/products/rhel8/kickstart/ssg-rhel8-stig-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-stig-ks.cfg index 105d166e0919..4e106b48e30f 100644 --- a/products/rhel8/kickstart/ssg-rhel8-stig-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-stig-ks.cfg @@ -88,18 +88,19 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition diff --git a/products/rhel8/kickstart/ssg-rhel8-stig_gui-ks.cfg b/products/rhel8/kickstart/ssg-rhel8-stig_gui-ks.cfg index e14bfab738b8..bb8933c429ac 100644 --- a/products/rhel8/kickstart/ssg-rhel8-stig_gui-ks.cfg +++ b/products/rhel8/kickstart/ssg-rhel8-stig_gui-ks.cfg @@ -87,18 +87,19 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition diff --git a/products/rhel8/profiles/default.profile b/products/rhel8/profiles/default.profile index 8b3cd0016da6..7e7401a04ac7 100644 --- a/products/rhel8/profiles/default.profile +++ b/products/rhel8/profiles/default.profile @@ -731,3 +731,11 @@ selections: - package_xorg-x11-server-common_removed - accounts_users_netrc_file_permissions - journald_forward_to_syslog + - harden_sshd_ciphers_opensshserver_conf_crypto_policy + - harden_sshd_macs_opensshserver_conf_crypto_policy + - sysctl_crypto_fips_enabled + - configure_gnutls_tls_crypto_policy + - configure_openssl_tls_crypto_policy + - sshd_use_approved_kex_ordered_stig + - accounts_user_dot_no_world_writable_programs + - package_dnsmasq_removed diff --git a/products/rhel8/profiles/ospp.profile b/products/rhel8/profiles/ospp.profile index d93a50b532a6..d3caff553236 100644 --- a/products/rhel8/profiles/ospp.profile +++ b/products/rhel8/profiles/ospp.profile @@ -149,6 +149,7 @@ selections: - package_abrt-addon-kerneloops_removed - ssh_client_use_strong_rng_csh - chronyd_no_chronyc_network + - chronyd_configure_local_socket - mount_option_var_log_noexec - sysctl_kernel_core_pattern - var_sshd_set_keepalive=1 @@ -206,4 +207,3 @@ selections: - '!zipl_systemd_debug-shell_argument_absent' - '!audit_modify_failed_ppc64le' - '!package_sequoia-sq_installed' - diff --git a/products/rhel8/profiles/rht-ccp.profile b/products/rhel8/profiles/rht-ccp.profile index 4e67d3893c0c..cff0b644c55a 100644 --- a/products/rhel8/profiles/rht-ccp.profile +++ b/products/rhel8/profiles/rht-ccp.profile @@ -27,6 +27,7 @@ selections: - var_password_pam_difok=3 - var_password_pam_unix_remember=5 - var_accounts_user_umask=077 + - login_banner_contents=usgcb_default - login_banner_text=usgcb_default - partition_for_tmp - partition_for_var diff --git a/products/rhel8/profiles/stig.profile b/products/rhel8/profiles/stig.profile index 0369365b5d48..3de33f98cbba 100644 --- a/products/rhel8/profiles/stig.profile +++ b/products/rhel8/profiles/stig.profile @@ -2,7 +2,7 @@ documentation_complete: true metadata: - version: V2R5 + version: V2R7 SMEs: - mab879 - ggbecker @@ -13,7 +13,7 @@ title: 'DISA STIG for Red Hat Enterprise Linux 8' description: |- This profile contains configuration checks that align to the - DISA STIG for Red Hat Enterprise Linux 8 V2R5. + DISA STIG for Red Hat Enterprise Linux 8 V2R7. In addition to being applicable to Red Hat Enterprise Linux 8, this configuration baseline is applicable to the operating system tier of diff --git a/products/rhel8/profiles/stig_gui.profile b/products/rhel8/profiles/stig_gui.profile index 6d3e322442a5..8abe06b19e24 100644 --- a/products/rhel8/profiles/stig_gui.profile +++ b/products/rhel8/profiles/stig_gui.profile @@ -2,7 +2,7 @@ documentation_complete: true metadata: - version: V2R5 + version: V2R7 SMEs: - mab879 - ggbecker @@ -13,7 +13,7 @@ title: 'DISA STIG with GUI for Red Hat Enterprise Linux 8' description: |- This profile contains configuration checks that align to the - DISA STIG with GUI for Red Hat Enterprise Linux 8 V2R5. + DISA STIG with GUI for Red Hat Enterprise Linux 8 V2R7. In addition to being applicable to Red Hat Enterprise Linux 8, this configuration baseline is applicable to the operating system tier of diff --git a/products/rhel9/controls/ccn_rhel9.yml b/products/rhel9/controls/ccn_rhel9.yml index 6f0dcc2928f3..a0388e1a6233 100644 --- a/products/rhel9/controls/ccn_rhel9.yml +++ b/products/rhel9/controls/ccn_rhel9.yml @@ -3,7 +3,7 @@ policy: CCN-STIC-610A22 title: Security Profile Application Guide for Red Hat Enterprise Linux 9 id: ccn_rhel9 version: '2022-10' -source: https://www.ccn-cert.cni.es/pdf/guias/series-ccn-stic/guias-de-acceso-publico-ccn-stic/6768-ccn-stic-610a22-perfilado-de-seguridad-red-hat-enterprise-linux-9-0/file.html +source: https://www.ccn-cert.cni.es/pdf/guias/series-ccn-stic/guias-de-acceso-publico-ccn-stic/6768-ccn-stic-610a22-perfilado-de-seguridad-red-hat-enterprise-linux-9-0/file.html # yamllint disable-line rule:line-length levels: - id: basic @@ -121,10 +121,14 @@ controls: - var_auditd_max_log_file_action=rotate - id: A.3.SEC-RHEL7 - title: Modifications to the Sudoers File Are Audited, As Are Changes to Permissions, Users, Groups, + title: >- + Modifications to the Sudoers File Are Audited, + As Are Changes to Permissions, Users, Groups, and Passwords - original_title: Se auditan las modificaciones del fichero sudoers, así como los cambios en permisos, - usuarios, grupos y contraseñas. + original_title: >- + Se auditan las modificaciones del fichero sudoers, + así como los cambios en permisos, usuarios, + grupos y contraseñas. levels: - basic - intermediate @@ -154,15 +158,20 @@ controls: - id: A.3.SEC-RHEL8 title: Changes to Cron Settings and Scheduled Tasks Including Startup Scripts Are Audited - original_title: Se auditan los cambios en la configuración de Cron y en tareas programadas incluyendo - los de scripts de inicio. + original_title: >- + Se auditan los cambios en la configuración de + Cron y en tareas programadas incluyendo los de + scripts de inicio. levels: - advanced status: pending notes: |- - Some possible rules were included here but it is not clear if the requirement intends to - check more than these rules. We can see if more related rules are available in the project - and include everything that makes sense in the context of cron and chrony. + Some possible rules were included here but it is + not clear if the requirement intends to check + more than these rules. We can see if more related + rules are available in the project and include + everything that makes sense in the context of + cron and chrony. related_rules: - audit_rules_time_adjtimex - audit_rules_time_settimeofday @@ -185,15 +194,19 @@ controls: - id: A.3.SEC-RHEL10 title: All Mount Operations on the System and Changes to the Swap Are Audited - original_title: Se audita toda operación de montaje en el sistema y modificaciones en la memoria - de intercambio. + original_title: >- + Se audita toda operación de montaje en el + sistema y modificaciones en la memoria de + intercambio. levels: - intermediate - advanced status: partial notes: |- - We probably have audit related rule to monitor mount related syscalls, but it is not clear - about the swap. Is the intention to monitor when swap is changed? + We probably have audit related rule to monitor + mount related syscalls, but it is not clear + about the swap. Is the intention to monitor + when swap is changed? rules: - audit_rules_media_export @@ -204,13 +217,18 @@ controls: - advanced status: pending notes: |- - The intention here is probably to audit changes in /etc/pam.d files, but we need to confirm + The intention here is probably to audit changes + in /etc/pam.d files, but we need to confirm this assumption and get more context. - id: A.4.SEC-RHEL1 - title: Common Users Do Dot Have Local Administrator Permissions and Are Not Included in a Sudo + title: >- + Common Users Do Dot Have Local Administrator + Permissions and Are Not Included in a Sudo Group - original_title: Los usuarios estándar no disponen de permisos de administrador local ni se encuentran + original_title: >- + Los usuarios estándar no disponen de permisos + de administrador local ni se encuentran incluidos en un grupo sudoer. levels: - basic @@ -218,9 +236,12 @@ controls: - advanced status: pending notes: |- - It is a little tricky to interpret this requirement. Assuming the "Common users" are actually - interactive users, this requirement would automatically enforce all admin actions to be - performed only by the root user. I am not sure if this is the intetion here. + It is a little tricky to interpret this + requirement. Assuming the "Common users" are + actually interactive users, this requirement + would automatically enforce all admin actions + to be performed only by the root user. I am + not sure if this is the intetion here. - id: A.4.SEC-RHEL2 title: The System Has an Updated Antivirus @@ -231,9 +252,11 @@ controls: - advanced status: pending notes: |- - New templated rule is necessary to install the package. But to ensure the chosen antivirus - is actually updated would demand a more complex rule. Maybe this requirement can have at - leastthe partial status after the templated rule. + New templated rule is necessary to install the + package. But to ensure the chosen antivirus + is actually updated would demand a more complex + rule. Maybe this requirement can have at least + the partial status after the templated rule. - id: A.4.SEC-RHEL3 title: Permissions by Partitions Are Modified @@ -266,7 +289,9 @@ controls: - id: A.5.SEC-RHEL2 title: Elevation Attempts Are Controlled by Defining Users and Sudoer Groups - original_title: Se controlan los intentos de elevación mediante definición de usuarios y grupos + original_title: >- + Se controlan los intentos de elevación + mediante definición de usuarios y grupos sudoers. levels: - basic @@ -286,7 +311,9 @@ controls: - advanced status: pending notes: |- - There are rules for ssh_keys, for example. We need to confirm the scope of this requirement + There are rules for ssh_keys, for example. + We need to confirm the scope of this + requirement - id: A.5.SEC-RHEL4 title: Disable Insecure Encryption Algorithms @@ -374,8 +401,10 @@ controls: - id: A.6.SEC-RHEL2 title: Access in Recovery Mode Including Grub Boot Modification Mode is Restricted - original_title: Se restringen accesos en modo recuperación incluido el modo modificación de inicio - de grub. + original_title: >- + Se restringen accesos en modo recuperación + incluido el modo modificación de inicio de + grub. levels: - basic - intermediate @@ -472,7 +501,9 @@ controls: - id: A.8.SEC-RHEL4 title: Unnecessary Services are Disabled, Reducing the Attack Surface - original_title: Se deshabilitan servicios innecesarios, reduciendo la superficie de exposición. + original_title: >- + Se deshabilitan servicios innecesarios, + reduciendo la superficie de exposición. levels: - intermediate - advanced @@ -488,6 +519,7 @@ controls: - package_telnet-server_removed - package_tftp-server_removed - package_vsftpd_removed + - service_kdump_disabled - id: A.8.SEC-RHEL5 title: Application Execution is Controlled @@ -541,8 +573,10 @@ controls: - id: A.8.SEC-RHEL7 title: Password Encrypted Boot That Prevents Modification is Enabled (Protected GRUB) - original_title: Está habilitado el arranque cifrado con contraseña que evite modificaciones (GRUB - protegido). + original_title: >- + Está habilitado el arranque cifrado con + contraseña que evite modificaciones + (GRUB protegido). levels: - basic - intermediate @@ -560,8 +594,9 @@ controls: - advanced status: pending notes: |- - Is it related to downloads from the Internet to the system or from the system to an external - storage, for example? + Is it related to downloads from the Internet + to the system or from the system to an + external storage, for example? related_rules: - audit_rules_file_deletion_events_rename - audit_rules_file_deletion_events_renameat @@ -622,9 +657,13 @@ controls: - var_accounts_password_minlen_login_defs=12 - id: A.11.SEC-RHEL4 - title: During Login, the System Displays a Text in Compliance With the Organization's Standards + title: >- + During Login, the System Displays a Text in + Compliance With the Organization's Standards or Directives - original_title: Durante el inicio de sesión, el sistema muestra un texto en cumplimiento con las + original_title: >- + Durante el inicio de sesión, el sistema + muestra un texto en cumplimiento con las normas o directivas de la organización. levels: - basic @@ -635,11 +674,17 @@ controls: - banner_etc_issue - banner_etc_issue_net - banner_etc_motd + - motd_banner_text=cis_banners + - motd_banner_contents=cis_default - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text + - dconf_login_banner_text=cis_banners + - dconf_login_banner_contents=cis_default - sshd_enable_warning_banner_net - login_banner_text=cis_banners + - login_banner_contents=cis_default - remote_login_banner_text=cis_banners + - remote_login_banner_contents=cis_default - id: A.11.SEC-RHEL5 title: Network Acess to the System is Controlled @@ -779,7 +824,9 @@ controls: - id: A.23.SEC-RHEL1 title: The Installation And Use of Any Device Connected to the Equipment is Controlled - original_title: Se controla la instalación y uso de cualquier dispositivo conectado al equipo. + original_title: >- + Se controla la instalación y uso de cualquier + dispositivo conectado al equipo. levels: - basic - intermediate diff --git a/products/rhel9/controls/cis_rhel9.yml b/products/rhel9/controls/cis_rhel9.yml index f73fbd1f6d79..7ef265daaba1 100644 --- a/products/rhel9/controls/cis_rhel9.yml +++ b/products/rhel9/controls/cis_rhel9.yml @@ -361,9 +361,14 @@ controls: levels: - l1_server - l1_workstation - status: manual - related_rules: + status: partial + rules: - ensure_redhat_gpgkey_installed + notes: > + In CIS Benchmark, the requirement is manual, because of GPG keys for 3rd party repositories. + But, add the rule ensure_redhat_gpgkey_installed to the profile because the requirement 1.2.1.2 + adds ensure_gpgcheck_never_disabled which requires GPG key checking. If the Red Hat + GPG key wouldn't be installed, people won't be able to install any RPM package using dnf. - id: 1.2.1.2 title: Ensure gpgcheck is globally activated (Automated) @@ -690,7 +695,8 @@ controls: rules: - dconf_gnome_banner_enabled - dconf_gnome_login_banner_text - - login_banner_text=cis_banners + - dconf_login_banner_text=cis_banners + - dconf_login_banner_contents=cis_default - id: 1.8.3 title: Ensure GDM disable-user-list option is enabled (Automated) @@ -819,6 +825,8 @@ controls: - l1_workstation status: automated rules: + - service_dnsmasq_disabled + related_rules: - package_dnsmasq_removed - id: 2.1.6 @@ -1908,7 +1916,8 @@ controls: - l2_workstation status: automated rules: - - accounts_passwords_pam_faillock_deny_root + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - var_accounts_passwords_pam_faillock_root_unlock_time=60 - id: 5.3.3.2.1 title: Ensure password number of changed characters is configured (Automated) @@ -2419,8 +2428,8 @@ controls: levels: - l1_server - l1_workstation - status: supported - related_rules: + status: automated + rules: - rsyslog_filecreatemode - id: 6.2.3.5 @@ -2552,6 +2561,7 @@ controls: - auditd_data_retention_action_mail_acct - auditd_data_retention_admin_space_left_action - auditd_data_retention_space_left_action + - package_postfix_installed - var_auditd_action_mail_acct=root - var_auditd_admin_space_left_action=cis_rhel9 - var_auditd_space_left_action=cis_rhel9 diff --git a/products/rhel9/controls/nist_800_53.yml b/products/rhel9/controls/nist_800_53.yml new file mode 100644 index 000000000000..d8055a5d27d8 --- /dev/null +++ b/products/rhel9/controls/nist_800_53.yml @@ -0,0 +1,15 @@ +policy: NIST 800-53 Revision 5 (RHEL9) +title: NIST Special Publication 800-53 Revision 5 for RHEL9 +id: nist_800_53 +version: Revision 5 +source: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +product: rhel9 +controls_dir: nist_800_53 +levels: + - id: low + - id: moderate + inherits_from: + - low + - id: high + inherits_from: + - moderate diff --git a/products/rhel9/controls/nist_800_53/ac.yml b/products/rhel9/controls/nist_800_53/ac.yml new file mode 100644 index 000000000000..67203ffabc14 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ac.yml @@ -0,0 +1,832 @@ +# NIST 800-53 AC Family: Access Control +controls: + - id: ac-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ac-2 + title: Account Management + levels: + - low + rules: [] + status: pending + - id: ac-2.1 + title: Automated System Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.2 + title: Automated Temporary and Emergency Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.3 + title: Disable Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-2.4 + title: Automated Audit Actions + levels: + - moderate + rules: [] + status: pending + - id: ac-2.5 + title: Inactivity Logout + levels: + - moderate + rules: + - accounts_tmout + - inactivity_timeout_value=15_minutes + - no_invalid_shell_accounts_unlocked + - no_password_auth_for_systemaccounts + - no_shelllogin_for_systemaccounts + - var_accounts_tmout=15_min + status: automated + - id: ac-2.6 + title: Dynamic Privilege Management + rules: [] + status: pending + - id: ac-2.7 + title: Privileged User Accounts + rules: [] + status: pending + - id: ac-2.8 + title: Dynamic Account Management + rules: [] + status: pending + - id: ac-2.9 + title: Restrictions on Use of Shared and Group Accounts + rules: [] + status: pending + - id: ac-2.10 + title: Shared and Group Account Credential Change + rules: [] + status: pending + - id: ac-2.11 + title: Usage Conditions + levels: + - high + rules: [] + status: pending + - id: ac-2.12 + title: Account Monitoring for Atypical Usage + levels: + - high + rules: [] + status: pending + - id: ac-2.13 + title: Disable Accounts for High-risk Individuals + levels: + - moderate + rules: [] + status: pending + - id: ac-3 + title: Access Enforcement + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - audit_rules_immutable + - dir_perms_world_writable_sticky_bits + - ensure_pam_wheel_group_empty + - file_at_allow_exists + - file_at_deny_not_exist + - file_cron_allow_exists + - file_cron_deny_not_exist + - file_etc_security_opasswd + - file_groupowner_at_allow + - file_groupowner_backup_etc_group + - file_groupowner_backup_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - file_groupowner_cron_allow + - file_groupowner_cron_d + - file_groupowner_cron_daily + - file_groupowner_cron_hourly + - file_groupowner_cron_monthly + - file_groupowner_cron_weekly + - file_groupowner_crontab + - file_groupowner_etc_group + - file_groupowner_etc_gshadow + - file_groupowner_etc_issue + - file_groupowner_etc_issue_net + - file_groupowner_etc_motd + - file_groupowner_etc_passwd + - file_groupowner_etc_shadow + - file_groupowner_etc_shells + - file_groupowner_grub2_cfg + - file_groupowner_sshd_config + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_at_allow + - file_owner_backup_etc_group + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_owner_backup_etc_shadow + - file_owner_cron_allow + - file_owner_cron_d + - file_owner_cron_daily + - file_owner_cron_hourly + - file_owner_cron_monthly + - file_owner_cron_weekly + - file_owner_crontab + - file_owner_etc_group + - file_owner_etc_gshadow + - file_owner_etc_issue + - file_owner_etc_issue_net + - file_owner_etc_motd + - file_owner_etc_passwd + - file_owner_etc_shadow + - file_owner_etc_shells + - file_owner_grub2_cfg + - file_owner_sshd_config + - file_owner_user_cfg + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_at_allow + - file_permissions_backup_etc_group + - file_permissions_backup_etc_gshadow + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_shadow + - file_permissions_cron_allow + - file_permissions_cron_d + - file_permissions_cron_daily + - file_permissions_cron_hourly + - file_permissions_cron_monthly + - file_permissions_cron_weekly + - file_permissions_crontab + - file_permissions_etc_group + - file_permissions_etc_gshadow + - file_permissions_etc_issue + - file_permissions_etc_issue_net + - file_permissions_etc_motd + - file_permissions_etc_passwd + - file_permissions_etc_shadow + - file_permissions_etc_shells + - file_permissions_grub2_cfg + - file_permissions_sshd_config + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_unauthorized_world_writable + - file_permissions_ungroupowned + - file_permissions_user_cfg + - grub2_enable_selinux + - grub2_password + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_home_nodev + - mount_option_home_nosuid + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - mount_option_var_log_audit_nodev + - mount_option_var_log_audit_noexec + - mount_option_var_log_audit_nosuid + - mount_option_var_log_nodev + - mount_option_var_log_noexec + - mount_option_var_log_nosuid + - mount_option_var_nodev + - mount_option_var_nosuid + - mount_option_var_tmp_nodev + - mount_option_var_tmp_noexec + - mount_option_var_tmp_nosuid + - no_files_unowned_by_user + - package_libselinux_installed + - package_mcstrans_removed + - package_setroubleshoot_removed + - rsyslog_files_groupownership + - rsyslog_files_ownership + - rsyslog_files_permissions + - selinux_not_disabled + - selinux_policytype + - sshd_limit_user_access + - use_pam_wheel_group_for_su + - var_accounts_user_umask=027 + - var_pam_wheel_group_for_su=cis + status: automated + - id: ac-3.1 + title: Restricted Access to Privileged Functions + rules: [] + status: pending + - id: ac-3.2 + title: Dual Authorization + rules: [] + status: pending + - id: ac-3.3 + title: Mandatory Access Control + rules: [] + status: pending + - id: ac-3.4 + title: Discretionary Access Control + rules: [] + status: pending + - id: ac-3.5 + title: Security-relevant Information + rules: [] + status: pending + - id: ac-3.6 + title: Protection of User and System Information + rules: [] + status: pending + - id: ac-3.7 + title: Role-based Access Control + rules: [] + status: pending + - id: ac-3.8 + title: Revocation of Access Authorizations + rules: [] + status: pending + - id: ac-3.9 + title: Controlled Release + rules: [] + status: pending + - id: ac-3.10 + title: Audited Override of Access Control Mechanisms + rules: [] + status: pending + - id: ac-3.11 + title: Restrict Access to Specific Information Types + rules: [] + status: pending + - id: ac-3.12 + title: Assert and Enforce Application Access + rules: [] + status: pending + - id: ac-3.13 + title: Attribute-based Access Control + rules: [] + status: pending + - id: ac-3.14 + title: Individual Access + rules: [] + status: pending + - id: ac-3.15 + title: Discretionary and Mandatory Access Control + rules: [] + status: pending + - id: ac-4 + title: Information Flow Enforcement + levels: + - moderate + rules: [] + status: pending + - id: ac-4.1 + title: Object Security and Privacy Attributes + rules: [] + status: pending + - id: ac-4.2 + title: Processing Domains + rules: [] + status: pending + - id: ac-4.3 + title: Dynamic Information Flow Control + rules: [] + status: pending + - id: ac-4.4 + title: Flow Control of Encrypted Information + levels: + - high + rules: [] + status: pending + - id: ac-4.5 + title: Embedded Data Types + rules: [] + status: pending + - id: ac-4.6 + title: Metadata + rules: [] + status: pending + - id: ac-4.7 + title: One-way Flow Mechanisms + rules: [] + status: pending + - id: ac-4.8 + title: Security and Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.9 + title: Human Reviews + rules: [] + status: pending + - id: ac-4.10 + title: Enable and Disable Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.11 + title: Configuration of Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.12 + title: Data Type Identifiers + rules: [] + status: pending + - id: ac-4.13 + title: Decomposition into Policy-relevant Subcomponents + rules: [] + status: pending + - id: ac-4.14 + title: Security or Privacy Policy Filter Constraints + rules: [] + status: pending + - id: ac-4.15 + title: Detection of Unsanctioned Information + rules: [] + status: pending + - id: ac-4.16 + title: Information Transfers on Interconnected Systems + rules: [] + status: pending + - id: ac-4.17 + title: Domain Authentication + rules: [] + status: pending + - id: ac-4.18 + title: Security Attribute Binding + rules: [] + status: pending + - id: ac-4.19 + title: Validation of Metadata + rules: [] + status: pending + - id: ac-4.20 + title: Approved Solutions + rules: [] + status: pending + - id: ac-4.21 + title: Physical or Logical Separation of Information Flows + rules: [] + status: pending + - id: ac-4.22 + title: Access Only + rules: [] + status: pending + - id: ac-4.23 + title: Modify Non-releasable Information + rules: [] + status: pending + - id: ac-4.24 + title: Internal Normalized Format + rules: [] + status: pending + - id: ac-4.25 + title: Data Sanitization + rules: [] + status: pending + - id: ac-4.26 + title: Audit Filtering Actions + rules: [] + status: pending + - id: ac-4.27 + title: Redundant/Independent Filtering Mechanisms + rules: [] + status: pending + - id: ac-4.28 + title: Linear Filter Pipelines + rules: [] + status: pending + - id: ac-4.29 + title: Filter Orchestration Engines + rules: [] + status: pending + - id: ac-4.30 + title: Filter Mechanisms Using Multiple Processes + rules: [] + status: pending + - id: ac-4.31 + title: Failed Content Transfer Prevention + rules: [] + status: pending + - id: ac-4.32 + title: Process Requirements for Information Transfer + rules: [] + status: pending + - id: ac-5 + title: Separation of Duties + levels: + - moderate + rules: [] + status: pending + - id: ac-6 + title: Least Privilege + levels: + - moderate + rules: + - sshd_disable_root_login + - sudo_add_use_pty + - sudo_remove_no_authenticate + - sudo_remove_nopasswd + status: automated + - id: ac-6.1 + title: Authorize Access to Security Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.2 + title: Non-privileged Access for Nonsecurity Functions + levels: + - moderate + rules: + - package_sudo_installed + status: automated + - id: ac-6.3 + title: Network Access to Privileged Commands + levels: + - high + rules: [] + status: pending + - id: ac-6.4 + title: Separate Processing Domains + rules: [] + status: pending + - id: ac-6.5 + title: Privileged Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-6.6 + title: Privileged Access by Non-organizational Users + rules: [] + status: pending + - id: ac-6.7 + title: Review of User Privileges + levels: + - moderate + rules: [] + status: pending + - id: ac-6.8 + title: Privilege Levels for Code Execution + rules: [] + status: pending + - id: ac-6.9 + title: Log Use of Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.10 + title: Prohibit Non-privileged Users from Executing Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-7 + title: Unsuccessful Logon Attempts + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - accounts_passwords_pam_faillock_deny + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - accounts_passwords_pam_faillock_unlock_time + - var_accounts_passwords_pam_faillock_deny=5 + - var_accounts_passwords_pam_faillock_dir=run + - var_accounts_passwords_pam_faillock_root_unlock_time=60 + - var_accounts_passwords_pam_faillock_unlock_time=900 + status: automated + - id: ac-7.1 + title: Automatic Account Lock + rules: [] + status: pending + - id: ac-7.2 + title: Purge or Wipe Mobile Device + rules: [] + status: pending + - id: ac-7.3 + title: Biometric Attempt Limiting + rules: [] + status: pending + - id: ac-7.4 + title: Use of Alternate Authentication Factor + rules: [] + status: pending + - id: ac-8 + title: System Use Notification + levels: + - low + rules: + - dconf_gnome_banner_enabled + - dconf_gnome_login_banner_text + status: automated + - id: ac-9 + title: Previous Logon Notification + rules: [] + status: pending + - id: ac-9.1 + title: Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.2 + title: Successful and Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.3 + title: Notification of Account Changes + rules: [] + status: pending + - id: ac-9.4 + title: Additional Logon Information + rules: [] + status: pending + - id: ac-10 + title: Concurrent Session Control + levels: + - high + rules: [] + status: pending + - id: ac-11 + title: Device Lock + levels: + - moderate + rules: + - dconf_gnome_screensaver_idle_delay + - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_user_locks + - dconf_gnome_session_idle_user_locks + - var_screensaver_lock_delay=5_seconds + status: automated + - id: ac-11.1 + title: Pattern-hiding Displays + levels: + - moderate + rules: [] + status: pending + - id: ac-12 + title: Session Termination + levels: + - moderate + rules: [] + status: pending + - id: ac-12.1 + title: User-initiated Logouts + rules: [] + status: pending + - id: ac-12.2 + title: Termination Message + rules: [] + status: pending + - id: ac-12.3 + title: Timeout Warning Message + rules: [] + status: pending + - id: ac-13 + title: Supervision and Review — Access Control + rules: [] + status: pending + - id: ac-14 + title: Permitted Actions Without Identification or Authentication + levels: + - low + rules: [] + status: pending + - id: ac-14.1 + title: Necessary Uses + rules: [] + status: pending + - id: ac-15 + title: Automated Marking + rules: [] + status: pending + - id: ac-16 + title: Security and Privacy Attributes + rules: [] + status: pending + - id: ac-16.1 + title: Dynamic Attribute Association + rules: [] + status: pending + - id: ac-16.2 + title: Attribute Value Changes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.3 + title: Maintenance of Attribute Associations by System + rules: [] + status: pending + - id: ac-16.4 + title: Association of Attributes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.5 + title: Attribute Displays on Objects to Be Output + rules: [] + status: pending + - id: ac-16.6 + title: Maintenance of Attribute Association + rules: [] + status: pending + - id: ac-16.7 + title: Consistent Attribute Interpretation + rules: [] + status: pending + - id: ac-16.8 + title: Association Techniques and Technologies + rules: [] + status: pending + - id: ac-16.9 + title: Attribute Reassignment — Regrading Mechanisms + rules: [] + status: pending + - id: ac-16.10 + title: Attribute Configuration by Authorized Individuals + rules: [] + status: pending + - id: ac-17 + title: Remote Access + levels: + - low + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: ac-17.1 + title: Monitoring and Control + levels: + - moderate + rules: [] + status: pending + - id: ac-17.2 + title: Protection of Confidentiality and Integrity Using Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-17.3 + title: Managed Access Control Points + levels: + - moderate + rules: [] + status: pending + - id: ac-17.4 + title: Privileged Commands and Access + levels: + - moderate + rules: [] + status: pending + - id: ac-17.5 + title: Monitoring for Unauthorized Connections + rules: [] + status: pending + - id: ac-17.6 + title: Protection of Mechanism Information + rules: [] + status: pending + - id: ac-17.7 + title: Additional Protection for Security Function Access + rules: [] + status: pending + - id: ac-17.8 + title: Disable Nonsecure Network Protocols + rules: [] + status: pending + - id: ac-17.9 + title: Disconnect or Disable Access + rules: [] + status: pending + - id: ac-17.10 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: ac-18 + title: Wireless Access + levels: + - low + rules: + - wireless_disable_interfaces + status: automated + - id: ac-18.1 + title: Authentication and Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-18.2 + title: Monitoring Unauthorized Connections + rules: [] + status: pending + - id: ac-18.3 + title: Disable Wireless Networking + levels: + - moderate + rules: [] + status: pending + - id: ac-18.4 + title: Restrict Configurations by Users + levels: + - high + rules: [] + status: pending + - id: ac-18.5 + title: Antennas and Transmission Power Levels + levels: + - high + rules: [] + status: pending + - id: ac-19 + title: Access Control for Mobile Devices + levels: + - low + rules: [] + status: pending + - id: ac-19.1 + title: Use of Writable and Portable Storage Devices + rules: [] + status: pending + - id: ac-19.2 + title: Use of Personally Owned Portable Storage Devices + rules: [] + status: pending + - id: ac-19.3 + title: Use of Portable Storage Devices with No Identifiable Owner + rules: [] + status: pending + - id: ac-19.4 + title: Restrictions for Classified Information + rules: [] + status: pending + - id: ac-19.5 + title: Full Device or Container-based Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-20 + title: Use of External Systems + levels: + - low + rules: [] + status: pending + - id: ac-20.1 + title: Limits on Authorized Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.2 + title: Portable Storage Devices — Restricted Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.3 + title: Non-organizationally Owned Systems — Restricted Use + rules: [] + status: pending + - id: ac-20.4 + title: Network Accessible Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-20.5 + title: Portable Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-21 + title: Information Sharing + levels: + - moderate + rules: [] + status: pending + - id: ac-21.1 + title: Automated Decision Support + rules: [] + status: pending + - id: ac-21.2 + title: Information Search and Retrieval + rules: [] + status: pending + - id: ac-22 + title: Publicly Accessible Content + levels: + - low + rules: [] + status: pending + - id: ac-23 + title: Data Mining Protection + rules: [] + status: pending + - id: ac-24 + title: Access Control Decisions + rules: [] + status: pending + - id: ac-24.1 + title: Transmit Access Authorization Information + rules: [] + status: pending + - id: ac-24.2 + title: No User or Process Identity + rules: [] + status: pending + - id: ac-25 + title: Reference Monitor + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/at.yml b/products/rhel9/controls/nist_800_53/at.yml new file mode 100644 index 000000000000..80211cdb5591 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/at.yml @@ -0,0 +1,82 @@ +# NIST 800-53 AT Family: Awareness and Training +controls: + - id: at-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: at-2 + title: Literacy Training and Awareness + levels: + - low + rules: [] + status: pending + - id: at-2.1 + title: Practical Exercises + rules: [] + status: pending + - id: at-2.2 + title: Insider Threat + levels: + - low + rules: [] + status: pending + - id: at-2.3 + title: Social Engineering and Mining + levels: + - moderate + rules: [] + status: pending + - id: at-2.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-2.5 + title: Advanced Persistent Threat + rules: [] + status: pending + - id: at-2.6 + title: Cyber Threat Environment + rules: [] + status: pending + - id: at-3 + title: Role-based Training + levels: + - low + rules: [] + status: pending + - id: at-3.1 + title: Environmental Controls + rules: [] + status: pending + - id: at-3.2 + title: Physical Security Controls + rules: [] + status: pending + - id: at-3.3 + title: Practical Exercises + rules: [] + status: pending + - id: at-3.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-3.5 + title: Processing Personally Identifiable Information + rules: [] + status: pending + - id: at-4 + title: Training Records + levels: + - low + rules: [] + status: pending + - id: at-5 + title: Contacts with Security Groups and Associations + rules: [] + status: pending + - id: at-6 + title: Training Feedback + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/au.yml b/products/rhel9/controls/nist_800_53/au.yml new file mode 100644 index 000000000000..3df900ee202a --- /dev/null +++ b/products/rhel9/controls/nist_800_53/au.yml @@ -0,0 +1,478 @@ +# NIST 800-53 AU Family: Audit and Accountability +controls: + - id: au-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: au-2 + title: Event Logging + levels: + - low + rules: + - aide_build_database + - aide_periodic_cron_checking + - audit_rules_execution_chacl + - audit_rules_execution_chcon + - audit_rules_execution_setfacl + - audit_rules_privileged_commands_usermod + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - auditd_data_retention_action_mail_acct + - auditd_data_retention_admin_space_left_action + - auditd_data_retention_space_left_action + - grub2_audit_backlog_limit_argument + - package_aide_installed + - package_audit-libs_installed + - package_audit_installed + - package_systemd-journal-remote_installed + - service_auditd_enabled + - service_systemd-journald_enabled + - socket_systemd-journal-remote_disabled + - var_audit_backlog_limit=8192 + - var_auditd_action_mail_acct=root + - var_auditd_admin_space_left_action=cis_rhel9 + - var_auditd_space_left_action=cis_rhel9 + status: automated + - id: au-2.1 + title: Compilation of Audit Records from Multiple Sources + rules: [] + status: pending + - id: au-2.2 + title: Selection of Audit Events by Component + rules: [] + status: pending + - id: au-2.3 + title: Reviews and Updates + rules: [] + status: pending + - id: au-2.4 + title: Privileged Functions + rules: [] + status: pending + - id: au-3 + title: Content of Audit Records + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_mac_modification + - audit_rules_mac_modification_usr_share + - audit_rules_networkconfig_modification + - audit_rules_networkconfig_modification_hostname_file + - audit_rules_networkconfig_modification_network_scripts + - audit_rules_networkconfig_modification_networkmanager + - audit_rules_privileged_commands + - audit_rules_privileged_commands_kmod + - audit_rules_session_events_btmp + - audit_rules_session_events_utmp + - audit_rules_session_events_wtmp + - audit_rules_suid_auid_privilege_function + - audit_rules_sysadmin_actions + - audit_rules_time_adjtimex + - audit_rules_time_clock_settime + - audit_rules_time_settimeofday + - audit_rules_time_watch_localtime + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - chronyd_specify_remote_server + - directory_permissions_var_log_audit + - file_groupownership_audit_binaries + - file_ownership_var_log_audit_stig + - file_permissions_audit_binaries + - journald_storage + - package_chrony_installed + - sshd_set_loglevel_verbose + - sshd_set_max_auth_tries + - sudo_custom_logfile + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_default_log_martians + - sshd_max_auth_tries_value=4 + - var_multiple_time_servers=rhel + status: automated + - id: au-3.1 + title: Additional Audit Information + levels: + - moderate + rules: [] + status: pending + - id: au-3.2 + title: Centralized Management of Planned Audit Record Content + rules: [] + status: pending + - id: au-3.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: au-4 + title: Audit Log Storage Capacity + levels: + - low + rules: + - journald_compress + status: automated + - id: au-4.1 + title: Transfer to Alternate Storage + rules: [] + status: pending + - id: au-5 + title: Response to Audit Logging Process Failures + levels: + - low + rules: + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - package_postfix_installed + - var_auditd_disk_error_action=cis_rhel9 + - var_auditd_disk_full_action=cis_rhel9 + status: automated + - id: au-5.1 + title: Storage Capacity Warning + levels: + - high + rules: [] + status: pending + - id: au-5.2 + title: Real-time Alerts + levels: + - high + rules: [] + status: pending + - id: au-5.3 + title: Configurable Traffic Volume Thresholds + rules: [] + status: pending + - id: au-5.4 + title: Shutdown on Failure + rules: [] + status: pending + - id: au-5.5 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-6 + title: Audit Record Review, Analysis, and Reporting + levels: + - low + rules: [] + status: pending + - id: au-6.1 + title: Automated Process Integration + levels: + - moderate + rules: [] + status: pending + - id: au-6.2 + title: Automated Security Alerts + rules: [] + status: pending + - id: au-6.3 + title: Correlate Audit Record Repositories + levels: + - moderate + rules: [] + status: pending + - id: au-6.4 + title: Central Review and Analysis + rules: [] + status: pending + - id: au-6.5 + title: Integrated Analysis of Audit Records + levels: + - high + rules: [] + status: pending + - id: au-6.6 + title: Correlation with Physical Monitoring + levels: + - high + rules: [] + status: pending + - id: au-6.7 + title: Permitted Actions + rules: [] + status: pending + - id: au-6.8 + title: Full Text Analysis of Privileged Commands + rules: [] + status: pending + - id: au-6.9 + title: Correlation with Information from Nontechnical Sources + rules: [] + status: pending + - id: au-6.10 + title: Audit Level Adjustment + rules: [] + status: pending + - id: au-7 + title: Audit Record Reduction and Report Generation + levels: + - moderate + rules: [] + status: pending + - id: au-7.1 + title: Automatic Processing + levels: + - moderate + rules: [] + status: pending + - id: au-7.2 + title: Automatic Sort and Search + rules: [] + status: pending + - id: au-8 + title: Time Stamps + levels: + - low + rules: + - auditd_data_retention_max_log_file + - auditd_data_retention_max_log_file_action + - var_auditd_max_log_file=6 + - var_auditd_max_log_file_action=keep_logs + status: automated + - id: au-8.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: au-8.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: au-9 + title: Protection of Audit Information + levels: + - low + rules: + - audit_rules_immutable + - file_groupownership_audit_configuration + - file_ownership_audit_binaries + - file_ownership_audit_configuration + status: automated + - id: au-9.1 + title: Hardware Write-once Media + rules: [] + status: pending + - id: au-9.2 + title: Store on Separate Physical Systems or Components + levels: + - high + rules: [] + status: pending + - id: au-9.3 + title: Cryptographic Protection + levels: + - high + rules: + - aide_check_audit_tools + status: automated + - id: au-9.4 + title: Access by Subset of Privileged Users + levels: + - moderate + rules: + - file_group_ownership_var_log_audit + - file_permissions_var_log_audit + status: automated + - id: au-9.5 + title: Dual Authorization + rules: [] + status: pending + - id: au-9.6 + title: Read-only Access + rules: [] + status: pending + - id: au-9.7 + title: Store on Component with Different Operating System + rules: [] + status: pending + - id: au-10 + title: Non-repudiation + levels: + - high + rules: [] + status: pending + - id: au-10.1 + title: Association of Identities + rules: [] + status: pending + - id: au-10.2 + title: Validate Binding of Information Producer Identity + rules: [] + status: pending + - id: au-10.3 + title: Chain of Custody + rules: [] + status: pending + - id: au-10.4 + title: Validate Binding of Information Reviewer Identity + rules: [] + status: pending + - id: au-10.5 + title: Digital Signatures + rules: [] + status: pending + - id: au-11 + title: Audit Record Retention + levels: + - low + rules: [] + status: pending + - id: au-11.1 + title: Long-term Retrieval Capability + rules: [] + status: pending + - id: au-12 + title: Audit Record Generation + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_execution_chcon + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_unlinkat + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_media_export + - audit_rules_privileged_commands_kmod + - audit_rules_privileged_commands_usermod + - audit_rules_sysadmin_actions + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - audit_sudo_log_events + - file_permissions_audit_configuration + - grub2_audit_argument + - service_auditd_enabled + status: automated + - id: au-12.1 + title: System-wide and Time-correlated Audit Trail + levels: + - high + rules: [] + status: pending + - id: au-12.2 + title: Standardized Formats + rules: [] + status: pending + - id: au-12.3 + title: Changes by Authorized Individuals + levels: + - high + rules: [] + status: pending + - id: au-12.4 + title: Query Parameter Audits of Personally Identifiable Information + rules: [] + status: pending + - id: au-13 + title: Monitoring for Information Disclosure + rules: [] + status: pending + - id: au-13.1 + title: Use of Automated Tools + rules: [] + status: pending + - id: au-13.2 + title: Review of Monitored Sites + rules: [] + status: pending + - id: au-13.3 + title: Unauthorized Replication of Information + rules: [] + status: pending + - id: au-14 + title: Session Audit + rules: [] + status: pending + - id: au-14.1 + title: System Start-up + rules: [] + status: pending + - id: au-14.2 + title: Capture and Record Content + rules: [] + status: pending + - id: au-14.3 + title: Remote Viewing and Listening + rules: [] + status: pending + - id: au-15 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-16 + title: Cross-organizational Audit Logging + rules: [] + status: pending + - id: au-16.1 + title: Identity Preservation + rules: [] + status: pending + - id: au-16.2 + title: Sharing of Audit Information + rules: [] + status: pending + - id: au-16.3 + title: Disassociability + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/ca.yml b/products/rhel9/controls/nist_800_53/ca.yml new file mode 100644 index 000000000000..f0d2ab912085 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ca.yml @@ -0,0 +1,162 @@ +# NIST 800-53 CA Family: Assessment, Authorization, and Monitoring +controls: + - id: ca-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ca-2 + title: Control Assessments + levels: + - low + rules: [] + status: pending + - id: ca-2.1 + title: Independent Assessors + levels: + - moderate + rules: [] + status: pending + - id: ca-2.2 + title: Specialized Assessments + levels: + - high + rules: [] + status: pending + - id: ca-2.3 + title: Leveraging Results from External Organizations + rules: [] + status: pending + - id: ca-3 + title: Information Exchange + levels: + - low + rules: [] + status: pending + - id: ca-3.1 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: ca-3.2 + title: Classified National Security System Connections + rules: [] + status: pending + - id: ca-3.3 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: ca-3.4 + title: Connections to Public Networks + rules: [] + status: pending + - id: ca-3.5 + title: Restrictions on External System Connections + rules: [] + status: pending + - id: ca-3.6 + title: Transfer Authorizations + levels: + - high + rules: [] + status: pending + - id: ca-3.7 + title: Transitive Information Exchanges + rules: [] + status: pending + - id: ca-4 + title: Security Certification + rules: [] + status: pending + - id: ca-5 + title: Plan of Action and Milestones + levels: + - low + rules: [] + status: pending + - id: ca-5.1 + title: Automation Support for Accuracy and Currency + rules: [] + status: pending + - id: ca-6 + title: Authorization + levels: + - low + rules: [] + status: pending + - id: ca-6.1 + title: Joint Authorization — Intra-organization + rules: [] + status: pending + - id: ca-6.2 + title: Joint Authorization — Inter-organization + rules: [] + status: pending + - id: ca-7 + title: Continuous Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.1 + title: Independent Assessment + levels: + - moderate + rules: [] + status: pending + - id: ca-7.2 + title: Types of Assessments + rules: [] + status: pending + - id: ca-7.3 + title: Trend Analyses + rules: [] + status: pending + - id: ca-7.4 + title: Risk Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.5 + title: Consistency Analysis + rules: [] + status: pending + - id: ca-7.6 + title: Automation Support for Monitoring + rules: [] + status: pending + - id: ca-8 + title: Penetration Testing + levels: + - high + rules: [] + status: pending + - id: ca-8.1 + title: Independent Penetration Testing Agent or Team + levels: + - high + rules: [] + status: pending + - id: ca-8.2 + title: Red Team Exercises + rules: [] + status: pending + - id: ca-8.3 + title: Facility Penetration Testing + rules: [] + status: pending + - id: ca-9 + title: Internal System Connections + levels: + - low + rules: + - firewalld_loopback_traffic_restricted + - firewalld_loopback_traffic_trusted + - package_firewalld_installed + - package_nftables_installed + status: automated + - id: ca-9.1 + title: Compliance Checks + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/cm.yml b/products/rhel9/controls/nist_800_53/cm.yml new file mode 100644 index 000000000000..8f5da9aeb350 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/cm.yml @@ -0,0 +1,537 @@ +# NIST 800-53 CM Family: Configuration Management +controls: + - id: cm-1 + title: Policy and Procedures + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - account_unique_id + - account_unique_name + - accounts_maximum_age_login_defs + - accounts_no_uid_except_zero + - accounts_password_set_max_life_existing + - accounts_root_gid_zero + - accounts_root_path_dirs_no_write + - accounts_user_dot_group_ownership + - accounts_user_dot_user_ownership + - configure_custom_crypto_policy_cis + - disable_host_auth + - file_permission_user_init_files + - gid_passwd_group_same + - group_unique_id + - group_unique_name + - groups_no_zero_gid_except_root + - no_dirs_unowned_by_root + - no_forward_files + - no_netrc_files + - no_rsh_trust_files + - package_cron_installed + - root_path_all_dirs + - root_path_no_dot + - service_crond_enabled + - sshd_disable_empty_passwords + - sshd_disable_gssapi_auth + - sshd_disable_rhosts + - sshd_do_not_permit_user_env + - sshd_enable_pam + - sshd_enable_warning_banner_net + - sshd_set_idle_timeout + - sshd_set_keepalive + - sshd_set_max_sessions + - sshd_set_maxstartups + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv4_tcp_syncookies + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sshd_idle_timeout_value=5_minutes + - sysctl_net_ipv4_tcp_syncookies_value=enabled + - var_sshd_max_sessions=10 + - var_sshd_set_keepalive=1 + - var_sshd_set_maxstartups=10:30:60 + - var_user_initialization_files_regex=all_dotfiles + status: automated + - id: cm-2 + title: Baseline Configuration + levels: + - low + rules: [] + status: pending + - id: cm-2.1 + title: Reviews and Updates + rules: [] + status: pending + - id: cm-2.2 + title: Automation Support for Accuracy and Currency + levels: + - moderate + rules: [] + status: pending + - id: cm-2.3 + title: Retention of Previous Configurations + levels: + - moderate + rules: [] + status: pending + - id: cm-2.4 + title: Unauthorized Software + rules: [] + status: pending + - id: cm-2.5 + title: Authorized Software + rules: [] + status: pending + - id: cm-2.6 + title: Development and Test Environments + rules: [] + status: pending + - id: cm-2.7 + title: Configure Systems and Components for High-risk Areas + levels: + - moderate + rules: [] + status: pending + - id: cm-3 + title: Configuration Change Control + levels: + - moderate + rules: [] + status: pending + - id: cm-3.1 + title: Automated Documentation, Notification, and Prohibition of Changes + levels: + - high + rules: [] + status: pending + - id: cm-3.2 + title: Testing, Validation, and Documentation of Changes + levels: + - moderate + rules: [] + status: pending + - id: cm-3.3 + title: Automated Change Implementation + rules: [] + status: pending + - id: cm-3.4 + title: Security and Privacy Representatives + levels: + - moderate + rules: [] + status: pending + - id: cm-3.5 + title: Automated Security Response + rules: [] + status: pending + - id: cm-3.6 + title: Cryptography Management + levels: + - high + rules: [] + status: pending + - id: cm-3.7 + title: Review System Changes + rules: [] + status: pending + - id: cm-3.8 + title: Prevent or Restrict Configuration Changes + rules: [] + status: pending + - id: cm-4 + title: Impact Analyses + levels: + - low + rules: [] + status: pending + - id: cm-4.1 + title: Separate Test Environments + levels: + - high + rules: [] + status: pending + - id: cm-4.2 + title: Verification of Controls + levels: + - moderate + rules: [] + status: pending + - id: cm-5 + title: Access Restrictions for Change + levels: + - low + rules: [] + status: pending + - id: cm-5.1 + title: Automated Access Enforcement and Audit Records + levels: + - high + rules: [] + status: pending + - id: cm-5.2 + title: Review System Changes + rules: [] + status: pending + - id: cm-5.3 + title: Signed Components + rules: [] + status: pending + - id: cm-5.4 + title: Dual Authorization + rules: [] + status: pending + - id: cm-5.5 + title: Privilege Limitation for Production and Operation + rules: [] + status: pending + - id: cm-5.6 + title: Limit Library Privileges + rules: [] + status: pending + - id: cm-5.7 + title: Automatic Implementation of Security Safeguards + rules: [] + status: pending + - id: cm-6 + title: Configuration Settings + levels: + - low + rules: + - accounts_password_pam_modules_in_authselect_profile + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_user_interactive_home_directory_exists + - audit_rules_media_export + - banner_etc_issue_cis + - banner_etc_issue_net_cis + - banner_etc_motd_cis + - coredump_disable_backtraces + - chronyd_run_as_chrony_user + - coredump_disable_storage + - dconf_db_up_to_date + - dconf_gnome_disable_user_list + - disable_host_auth + - enable_authselect + - file_groupowner_grub2_cfg + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_grub2_cfg + - file_owner_user_cfg + - file_ownership_home_directories + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_grub2_cfg + - file_permissions_home_directories + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_user_cfg + - no_empty_passwords + - no_empty_passwords_etc_shadow + - package_pam_pwquality_installed + - package_rsync_removed + - package_samba_removed + - package_squid_removed + - partition_for_tmp + - partition_for_var_log + - service_nfs_disabled + - service_rpcbind_disabled + - sshd_disable_gssapi_auth + - sshd_set_login_grace_time + - sysctl_kernel_randomize_va_space + - sysctl_kernel_yama_ptrace_scope + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_log_martians + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - cis_banner_text=cis + - dconf_login_banner_contents=cis_default + - dconf_login_banner_text=cis_banners + - sysctl_net_ipv4_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_all_log_martians_value=enabled + - sysctl_net_ipv4_conf_all_rp_filter_value=enabled + - sysctl_net_ipv4_conf_all_secure_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_default_log_martians_value=enabled + - sysctl_net_ipv4_conf_default_rp_filter_value=enabled + - sysctl_net_ipv4_conf_default_secure_redirects_value=disabled + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled + - sysctl_net_ipv6_conf_all_accept_ra_value=disabled + - sysctl_net_ipv6_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_all_forwarding_value=disabled + - sysctl_net_ipv6_conf_default_accept_ra_value=disabled + - sysctl_net_ipv6_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_default_accept_source_route_value=disabled + - var_accounts_user_umask=027 + - var_authselect_profile=sssd + - var_sshd_set_login_grace_time=60 + status: automated + - id: cm-6.1 + title: Automated Management, Application, and Verification + levels: + - high + rules: [] + status: pending + - id: cm-6.2 + title: Respond to Unauthorized Changes + levels: + - high + rules: [] + status: pending + - id: cm-6.3 + title: Unauthorized Change Detection + rules: [] + status: pending + - id: cm-6.4 + title: Conformance Demonstration + rules: [] + status: pending + - id: cm-7 + title: Least Functionality + levels: + - low + rules: + - dconf_gnome_disable_autorun + - file_ownership_var_log_audit_stig + - gnome_gdm_disable_xdmcp + - has_nonlocal_mta + - kernel_module_cramfs_disabled + - kernel_module_dccp_disabled + - kernel_module_freevxfs_disabled + - kernel_module_hfs_disabled + - kernel_module_hfsplus_disabled + - kernel_module_jffs2_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_squashfs_disabled + - kernel_module_tipc_disabled + - kernel_module_udf_disabled + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_tmp_nodev + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - package_bind_removed + - package_cyrus-imapd_removed + - package_dhcp_removed + - package_dovecot_removed + - package_ftp_removed + - package_gdm_removed + - package_httpd_removed + - package_net-snmp_removed + - package_nginx_removed + - package_openldap-clients_removed + - package_telnet-server_removed + - package_telnet_removed + - package_tftp-server_removed + - package_tftp_removed + - package_vsftpd_removed + - partition_for_dev_shm + - partition_for_home + - partition_for_tmp + - partition_for_var + - partition_for_var_log + - partition_for_var_log_audit + - partition_for_var_tmp + - postfix_network_listening_disabled + - service_bluetooth_disabled + - service_cups_disabled + - service_dnsmasq_disabled + - service_nftables_disabled + - sshd_disable_forwarding + - wireless_disable_interfaces + - var_postfix_inet_interfaces=loopback-only + status: automated + - id: cm-7.1 + title: Periodic Review + levels: + - moderate + rules: [] + status: pending + - id: cm-7.2 + title: Prevent Program Execution + levels: + - moderate + rules: [] + status: pending + - id: cm-7.3 + title: Registration Compliance + rules: [] + status: pending + - id: cm-7.4 + title: Unauthorized Software — Deny-by-exception + rules: [] + status: pending + - id: cm-7.5 + title: Authorized Software — Allow-by-exception + levels: + - moderate + rules: [] + status: pending + - id: cm-7.6 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: cm-7.7 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: cm-7.8 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: cm-7.9 + title: Prohibiting The Use of Unauthorized Hardware + rules: [] + status: pending + - id: cm-8 + title: System Component Inventory + levels: + - low + rules: [] + status: pending + - id: cm-8.1 + title: Updates During Installation and Removal + levels: + - moderate + rules: [] + status: pending + - id: cm-8.2 + title: Automated Maintenance + levels: + - high + rules: [] + status: pending + - id: cm-8.3 + title: Automated Unauthorized Component Detection + levels: + - moderate + rules: [] + status: pending + - id: cm-8.4 + title: Accountability Information + levels: + - high + rules: [] + status: pending + - id: cm-8.5 + title: No Duplicate Accounting of Components + rules: [] + status: pending + - id: cm-8.6 + title: Assessed Configurations and Approved Deviations + rules: [] + status: pending + - id: cm-8.7 + title: Centralized Repository + rules: [] + status: pending + - id: cm-8.8 + title: Automated Location Tracking + rules: [] + status: pending + - id: cm-8.9 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: cm-9 + title: Configuration Management Plan + levels: + - moderate + rules: [] + status: pending + - id: cm-9.1 + title: Assignment of Responsibility + rules: [] + status: pending + - id: cm-10 + title: Software Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: cm-10.1 + title: Open-source Software + rules: [] + status: pending + - id: cm-11 + title: User-installed Software + levels: + - low + rules: + - package_xorg-x11-server-common_removed + - xwindows_runlevel_target + status: automated + - id: cm-11.1 + title: Alerts for Unauthorized Installations + rules: [] + status: pending + - id: cm-11.2 + title: Software Installation with Privileged Status + rules: [] + status: pending + - id: cm-11.3 + title: Automated Enforcement and Monitoring + rules: [] + status: pending + - id: cm-12 + title: Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-12.1 + title: Automated Tools to Support Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-13 + title: Data Action Mapping + rules: [] + status: pending + - id: cm-14 + title: Signed Components + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/cp.yml b/products/rhel9/controls/nist_800_53/cp.yml new file mode 100644 index 000000000000..53d97fb34990 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/cp.yml @@ -0,0 +1,296 @@ +# NIST 800-53 CP Family: Contingency Planning +controls: + - id: cp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: cp-2 + title: Contingency Plan + levels: + - low + rules: [] + status: pending + - id: cp-2.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-2.2 + title: Capacity Planning + levels: + - high + rules: [] + status: pending + - id: cp-2.3 + title: Resume Mission and Business Functions + levels: + - moderate + rules: [] + status: pending + - id: cp-2.4 + title: Resume All Mission and Business Functions + rules: [] + status: pending + - id: cp-2.5 + title: Continue Mission and Business Functions + levels: + - high + rules: [] + status: pending + - id: cp-2.6 + title: Alternate Processing and Storage Sites + rules: [] + status: pending + - id: cp-2.7 + title: Coordinate with External Service Providers + rules: [] + status: pending + - id: cp-2.8 + title: Identify Critical Assets + levels: + - moderate + rules: [] + status: pending + - id: cp-3 + title: Contingency Training + levels: + - low + rules: [] + status: pending + - id: cp-3.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: cp-3.2 + title: Mechanisms Used in Training Environments + rules: [] + status: pending + - id: cp-4 + title: Contingency Plan Testing + levels: + - low + rules: [] + status: pending + - id: cp-4.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-4.2 + title: Alternate Processing Site + levels: + - high + rules: [] + status: pending + - id: cp-4.3 + title: Automated Testing + rules: [] + status: pending + - id: cp-4.4 + title: Full Recovery and Reconstitution + rules: [] + status: pending + - id: cp-4.5 + title: Self-challenge + rules: [] + status: pending + - id: cp-5 + title: Contingency Plan Update + rules: [] + status: pending + - id: cp-6 + title: Alternate Storage Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.2 + title: Recovery Time and Recovery Point Objectives + levels: + - high + rules: [] + status: pending + - id: cp-6.3 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7 + title: Alternate Processing Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.2 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7.3 + title: Priority of Service + levels: + - moderate + rules: [] + status: pending + - id: cp-7.4 + title: Preparation for Use + levels: + - high + rules: [] + status: pending + - id: cp-7.5 + title: Equivalent Information Security Safeguards + rules: [] + status: pending + - id: cp-7.6 + title: Inability to Return to Primary Site + rules: [] + status: pending + - id: cp-8 + title: Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: cp-8.1 + title: Priority of Service Provisions + levels: + - moderate + rules: [] + status: pending + - id: cp-8.2 + title: Single Points of Failure + levels: + - moderate + rules: [] + status: pending + - id: cp-8.3 + title: Separation of Primary and Alternate Providers + levels: + - high + rules: [] + status: pending + - id: cp-8.4 + title: Provider Contingency Plan + levels: + - high + rules: [] + status: pending + - id: cp-8.5 + title: Alternate Telecommunication Service Testing + rules: [] + status: pending + - id: cp-9 + title: System Backup + levels: + - low + rules: [] + status: pending + - id: cp-9.1 + title: Testing for Reliability and Integrity + levels: + - moderate + rules: [] + status: pending + - id: cp-9.2 + title: Test Restoration Using Sampling + levels: + - high + rules: [] + status: pending + - id: cp-9.3 + title: Separate Storage for Critical Information + levels: + - high + rules: [] + status: pending + - id: cp-9.4 + title: Protection from Unauthorized Modification + rules: [] + status: pending + - id: cp-9.5 + title: Transfer to Alternate Storage Site + levels: + - high + rules: [] + status: pending + - id: cp-9.6 + title: Redundant Secondary System + rules: [] + status: pending + - id: cp-9.7 + title: Dual Authorization for Deletion or Destruction + rules: [] + status: pending + - id: cp-9.8 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: cp-10 + title: System Recovery and Reconstitution + levels: + - low + rules: [] + status: pending + - id: cp-10.1 + title: Contingency Plan Testing + rules: [] + status: pending + - id: cp-10.2 + title: Transaction Recovery + levels: + - moderate + rules: [] + status: pending + - id: cp-10.3 + title: Compensating Security Controls + rules: [] + status: pending + - id: cp-10.4 + title: Restore Within Time Period + levels: + - high + rules: [] + status: pending + - id: cp-10.5 + title: Failover Capability + rules: [] + status: pending + - id: cp-10.6 + title: Component Protection + rules: [] + status: pending + - id: cp-11 + title: Alternate Communications Protocols + rules: [] + status: pending + - id: cp-12 + title: Safe Mode + rules: [] + status: pending + - id: cp-13 + title: Alternative Security Mechanisms + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/ia.yml b/products/rhel9/controls/nist_800_53/ia.yml new file mode 100644 index 000000000000..095e4d524cf7 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ia.yml @@ -0,0 +1,395 @@ +# NIST 800-53 IA Family: Identification and Authentication +controls: + - id: ia-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ia-2 + title: Identification and Authentication (Organizational Users) + levels: + - low + rules: + - account_unique_id + status: automated + - id: ia-2.1 + title: Multi-factor Authentication to Privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.2 + title: Multi-factor Authentication to Non-privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.3 + title: Local Access to Privileged Accounts + rules: [] + status: pending + - id: ia-2.4 + title: Local Access to Non-privileged Accounts + rules: [] + status: pending + - id: ia-2.5 + title: Individual Authentication with Group Authentication + levels: + - high + rules: [] + status: pending + - id: ia-2.6 + title: Access to Accounts —separate Device + rules: [] + status: pending + - id: ia-2.7 + title: Network Access to Non-privileged Accounts — Separate Device + rules: [] + status: pending + - id: ia-2.8 + title: Access to Accounts — Replay Resistant + levels: + - low + rules: [] + status: pending + - id: ia-2.9 + title: Network Access to Non-privileged Accounts — Replay Resistant + rules: [] + status: pending + - id: ia-2.10 + title: Single Sign-on + rules: [] + status: pending + - id: ia-2.11 + title: Remote Access — Separate Device + rules: [] + status: pending + - id: ia-2.12 + title: Acceptance of PIV Credentials + levels: + - low + rules: [] + status: pending + - id: ia-2.13 + title: Out-of-band Authentication + rules: [] + status: pending + - id: ia-3 + title: Device Identification and Authentication + levels: + - moderate + rules: + - dconf_gnome_disable_automount + - dconf_gnome_disable_automount_open + - kernel_module_usb-storage_disabled + status: automated + - id: ia-3.1 + title: Cryptographic Bidirectional Authentication + rules: [] + status: pending + - id: ia-3.2 + title: Cryptographic Bidirectional Network Authentication + rules: [] + status: pending + - id: ia-3.3 + title: Dynamic Address Allocation + rules: [] + status: pending + - id: ia-3.4 + title: Device Attestation + rules: [] + status: pending + - id: ia-4 + title: Identifier Management + levels: + - low + rules: + - account_disable_post_pw_expiration + - accounts_set_post_pw_existing + - var_account_disable_post_pw_expiration=45 + status: automated + - id: ia-4.1 + title: Prohibit Account Identifiers as Public Identifiers + rules: [] + status: pending + - id: ia-4.2 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-4.3 + title: Multiple Forms of Certification + rules: [] + status: pending + - id: ia-4.4 + title: Identify User Status + levels: + - moderate + rules: [] + status: pending + - id: ia-4.5 + title: Dynamic Management + rules: [] + status: pending + - id: ia-4.6 + title: Cross-organization Management + rules: [] + status: pending + - id: ia-4.7 + title: In-person Registration + rules: [] + status: pending + - id: ia-4.8 + title: Pairwise Pseudonymous Identifiers + rules: [] + status: pending + - id: ia-4.9 + title: Attribute Maintenance and Protection + rules: [] + status: pending + - id: ia-5 + title: Authenticator Management + levels: + - low + rules: + - accounts_minimum_age_login_defs + - accounts_password_all_shadowed + - accounts_password_last_change_is_in_past + - accounts_password_pam_dictcheck + - accounts_password_pam_difok + - accounts_password_pam_enforce_root + - accounts_password_pam_maxrepeat + - accounts_password_pam_maxsequence + - accounts_password_pam_minclass + - accounts_password_pam_minlen + - accounts_password_pam_pwhistory_enforce_for_root + - accounts_password_set_min_life_existing + - accounts_password_set_warn_age_existing + - accounts_password_warn_age_login_defs + - ensure_root_password_configured + - no_empty_passwords_etc_shadow + - set_password_hashing_algorithm_libuserconf + - set_password_hashing_algorithm_logindefs + - set_password_hashing_algorithm_passwordauth + - set_password_hashing_algorithm_systemauth + - var_accounts_maximum_age_login_defs=365 + - var_accounts_minimum_age_login_defs=1 + - var_accounts_password_warn_age_login_defs=7 + - var_password_hashing_algorithm=SHA512 + - var_password_hashing_algorithm_pam=sha512 + - var_password_pam_dictcheck=1 + - var_password_pam_difok=2 + - var_password_pam_maxrepeat=3 + - var_password_pam_maxsequence=3 + - var_password_pam_minclass=4 + - var_password_pam_minlen=14 + status: automated + - id: ia-5.1 + title: Password-based Authentication + levels: + - low + rules: + - accounts_password_pam_pwhistory_remember_password_auth + - accounts_password_pam_pwhistory_remember_system_auth + - accounts_password_pam_unix_no_remember + - var_password_pam_remember=24 + - var_password_pam_remember_control_flag=requisite_or_required + status: automated + - id: ia-5.2 + title: Public Key-based Authentication + levels: + - moderate + rules: [] + status: pending + - id: ia-5.3 + title: In-person or Trusted External Party Registration + rules: [] + status: pending + - id: ia-5.4 + title: Automated Support for Password Strength Determination + rules: [] + status: pending + - id: ia-5.5 + title: Change Authenticators Prior to Delivery + rules: [] + status: pending + - id: ia-5.6 + title: Protection of Authenticators + levels: + - moderate + rules: [] + status: pending + - id: ia-5.7 + title: No Embedded Unencrypted Static Authenticators + rules: [] + status: pending + - id: ia-5.8 + title: Multiple System Accounts + rules: [] + status: pending + - id: ia-5.9 + title: Federated Credential Management + rules: [] + status: pending + - id: ia-5.10 + title: Dynamic Credential Binding + rules: [] + status: pending + - id: ia-5.11 + title: Hardware Token-based Authentication + rules: [] + status: pending + - id: ia-5.12 + title: Biometric Authentication Performance + rules: [] + status: pending + - id: ia-5.13 + title: Expiration of Cached Authenticators + rules: [] + status: pending + - id: ia-5.14 + title: Managing Content of PKI Trust Stores + rules: [] + status: pending + - id: ia-5.15 + title: GSA-approved Products and Services + rules: [] + status: pending + - id: ia-5.16 + title: In-person or Trusted External Party Authenticator Issuance + rules: [] + status: pending + - id: ia-5.17 + title: Presentation Attack Detection for Biometric Authenticators + rules: [] + status: pending + - id: ia-5.18 + title: Password Managers + rules: [] + status: pending + - id: ia-6 + title: Authentication Feedback + levels: + - low + rules: [] + status: pending + - id: ia-7 + title: Cryptographic Module Authentication + levels: + - low + rules: [] + status: pending + - id: ia-8 + title: Identification and Authentication (Non-organizational Users) + levels: + - low + rules: [] + status: pending + - id: ia-8.1 + title: Acceptance of PIV Credentials from Other Agencies + levels: + - low + rules: [] + status: pending + - id: ia-8.2 + title: Acceptance of External Authenticators + levels: + - low + rules: [] + status: pending + - id: ia-8.3 + title: Use of FICAM-approved Products + rules: [] + status: pending + - id: ia-8.4 + title: Use of Defined Profiles + levels: + - low + rules: [] + status: pending + - id: ia-8.5 + title: Acceptance of PIV-I Credentials + rules: [] + status: pending + - id: ia-8.6 + title: Disassociability + rules: [] + status: pending + - id: ia-9 + title: Service Identification and Authentication + rules: [] + status: pending + - id: ia-9.1 + title: Information Exchange + rules: [] + status: pending + - id: ia-9.2 + title: Transmission of Decisions + rules: [] + status: pending + - id: ia-10 + title: Adaptive Authentication + rules: [] + status: pending + - id: ia-11 + title: Re-authentication + levels: + - low + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=15_minutes + status: automated + - id: ia-12 + title: Identity Proofing + levels: + - moderate + rules: [] + status: pending + - id: ia-12.1 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-12.2 + title: Identity Evidence + levels: + - moderate + rules: [] + status: pending + - id: ia-12.3 + title: Identity Evidence Validation and Verification + levels: + - moderate + rules: [] + status: pending + - id: ia-12.4 + title: In-person Validation and Verification + levels: + - high + rules: [] + status: pending + - id: ia-12.5 + title: Address Confirmation + levels: + - moderate + rules: [] + status: pending + - id: ia-12.6 + title: Accept Externally-proofed Identities + rules: [] + status: pending + - id: ia-13 + title: Identity Providers and Authorization Servers + rules: [] + status: pending + - id: ia-13.1 + title: Protection of Cryptographic Keys + rules: [] + status: pending + - id: ia-13.2 + title: Verification of Identity Assertions and Access Tokens + rules: [] + status: pending + - id: ia-13.3 + title: Token Management + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/ir.yml b/products/rhel9/controls/nist_800_53/ir.yml new file mode 100644 index 000000000000..2d443099c957 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ir.yml @@ -0,0 +1,206 @@ +# NIST 800-53 IR Family: Incident Response +controls: + - id: ir-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ir-2 + title: Incident Response Training + levels: + - low + rules: [] + status: pending + - id: ir-2.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: ir-2.2 + title: Automated Training Environments + levels: + - high + rules: [] + status: pending + - id: ir-2.3 + title: Breach + rules: [] + status: pending + - id: ir-3 + title: Incident Response Testing + levels: + - moderate + rules: [] + status: pending + - id: ir-3.1 + title: Automated Testing + rules: [] + status: pending + - id: ir-3.2 + title: Coordination with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: ir-3.3 + title: Continuous Improvement + rules: [] + status: pending + - id: ir-4 + title: Incident Handling + levels: + - low + rules: [] + status: pending + - id: ir-4.1 + title: Automated Incident Handling Processes + levels: + - moderate + rules: [] + status: pending + - id: ir-4.2 + title: Dynamic Reconfiguration + rules: [] + status: pending + - id: ir-4.3 + title: Continuity of Operations + rules: [] + status: pending + - id: ir-4.4 + title: Information Correlation + levels: + - high + rules: [] + status: pending + - id: ir-4.5 + title: Automatic Disabling of System + rules: [] + status: pending + - id: ir-4.6 + title: Insider Threats + rules: [] + status: pending + - id: ir-4.7 + title: Insider Threats — Intra-organization Coordination + rules: [] + status: pending + - id: ir-4.8 + title: Correlation with External Organizations + rules: [] + status: pending + - id: ir-4.9 + title: Dynamic Response Capability + rules: [] + status: pending + - id: ir-4.10 + title: Supply Chain Coordination + rules: [] + status: pending + - id: ir-4.11 + title: Integrated Incident Response Team + levels: + - high + rules: [] + status: pending + - id: ir-4.12 + title: Malicious Code and Forensic Analysis + rules: [] + status: pending + - id: ir-4.13 + title: Behavior Analysis + rules: [] + status: pending + - id: ir-4.14 + title: Security Operations Center + rules: [] + status: pending + - id: ir-4.15 + title: Public Relations and Reputation Repair + rules: [] + status: pending + - id: ir-5 + title: Incident Monitoring + levels: + - low + rules: [] + status: pending + - id: ir-5.1 + title: Automated Tracking, Data Collection, and Analysis + levels: + - high + rules: [] + status: pending + - id: ir-6 + title: Incident Reporting + levels: + - low + rules: [] + status: pending + - id: ir-6.1 + title: Automated Reporting + levels: + - moderate + rules: [] + status: pending + - id: ir-6.2 + title: Vulnerabilities Related to Incidents + rules: [] + status: pending + - id: ir-6.3 + title: Supply Chain Coordination + levels: + - moderate + rules: [] + status: pending + - id: ir-7 + title: Incident Response Assistance + levels: + - low + rules: [] + status: pending + - id: ir-7.1 + title: Automation Support for Availability of Information and Support + levels: + - moderate + rules: [] + status: pending + - id: ir-7.2 + title: Coordination with External Providers + rules: [] + status: pending + - id: ir-8 + title: Incident Response Plan + levels: + - low + rules: [] + status: pending + - id: ir-8.1 + title: Breaches + rules: [] + status: pending + - id: ir-9 + title: Information Spillage Response + rules: [] + status: pending + - id: ir-9.1 + title: Responsible Personnel + rules: [] + status: pending + - id: ir-9.2 + title: Training + rules: [] + status: pending + - id: ir-9.3 + title: Post-spill Operations + rules: [] + status: pending + - id: ir-9.4 + title: Exposure to Unauthorized Personnel + rules: [] + status: pending + - id: ir-10 + title: Integrated Information Security Analysis Team + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/ma.yml b/products/rhel9/controls/nist_800_53/ma.yml new file mode 100644 index 000000000000..77bd02932613 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ma.yml @@ -0,0 +1,146 @@ +# NIST 800-53 MA Family: Maintenance +controls: + - id: ma-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ma-2 + title: Controlled Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-2.1 + title: Record Content + rules: [] + status: pending + - id: ma-2.2 + title: Automated Maintenance Activities + levels: + - high + rules: [] + status: pending + - id: ma-3 + title: Maintenance Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.1 + title: Inspect Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.2 + title: Inspect Media + levels: + - moderate + rules: [] + status: pending + - id: ma-3.3 + title: Prevent Unauthorized Removal + levels: + - moderate + rules: [] + status: pending + - id: ma-3.4 + title: Restricted Tool Use + rules: [] + status: pending + - id: ma-3.5 + title: Execution with Privilege + rules: [] + status: pending + - id: ma-3.6 + title: Software Updates and Patches + rules: [] + status: pending + - id: ma-4 + title: Nonlocal Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-4.1 + title: Logging and Review + rules: [] + status: pending + - id: ma-4.2 + title: Document Nonlocal Maintenance + rules: [] + status: pending + - id: ma-4.3 + title: Comparable Security and Sanitization + levels: + - high + rules: [] + status: pending + - id: ma-4.4 + title: Authentication and Separation of Maintenance Sessions + rules: [] + status: pending + - id: ma-4.5 + title: Approvals and Notifications + rules: [] + status: pending + - id: ma-4.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: ma-4.7 + title: Disconnect Verification + rules: [] + status: pending + - id: ma-5 + title: Maintenance Personnel + levels: + - low + rules: [] + status: pending + - id: ma-5.1 + title: Individuals Without Appropriate Access + levels: + - high + rules: [] + status: pending + - id: ma-5.2 + title: Security Clearances for Classified Systems + rules: [] + status: pending + - id: ma-5.3 + title: Citizenship Requirements for Classified Systems + rules: [] + status: pending + - id: ma-5.4 + title: Foreign Nationals + rules: [] + status: pending + - id: ma-5.5 + title: Non-system Maintenance + rules: [] + status: pending + - id: ma-6 + title: Timely Maintenance + levels: + - moderate + rules: [] + status: pending + - id: ma-6.1 + title: Preventive Maintenance + rules: [] + status: pending + - id: ma-6.2 + title: Predictive Maintenance + rules: [] + status: pending + - id: ma-6.3 + title: Automated Support for Predictive Maintenance + rules: [] + status: pending + - id: ma-7 + title: Field Maintenance + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/mp.yml b/products/rhel9/controls/nist_800_53/mp.yml new file mode 100644 index 000000000000..6c8e8f46e4e4 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/mp.yml @@ -0,0 +1,142 @@ +# NIST 800-53 MP Family: Media Protection +controls: + - id: mp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: mp-2 + title: Media Access + levels: + - low + rules: [] + status: pending + - id: mp-2.1 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-2.2 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-3 + title: Media Marking + levels: + - moderate + rules: [] + status: pending + - id: mp-4 + title: Media Storage + levels: + - moderate + rules: [] + status: pending + - id: mp-4.1 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-4.2 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-5 + title: Media Transport + levels: + - moderate + rules: [] + status: pending + - id: mp-5.1 + title: Protection Outside of Controlled Areas + rules: [] + status: pending + - id: mp-5.2 + title: Documentation of Activities + rules: [] + status: pending + - id: mp-5.3 + title: Custodians + rules: [] + status: pending + - id: mp-5.4 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-6 + title: Media Sanitization + levels: + - low + rules: [] + status: pending + - id: mp-6.1 + title: Review, Approve, Track, Document, and Verify + levels: + - high + rules: [] + status: pending + - id: mp-6.2 + title: Equipment Testing + levels: + - high + rules: [] + status: pending + - id: mp-6.3 + title: Nondestructive Techniques + levels: + - high + rules: [] + status: pending + - id: mp-6.4 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-6.5 + title: Classified Information + rules: [] + status: pending + - id: mp-6.6 + title: Media Destruction + rules: [] + status: pending + - id: mp-6.7 + title: Dual Authorization + rules: [] + status: pending + - id: mp-6.8 + title: Remote Purging or Wiping of Information + rules: [] + status: pending + - id: mp-7 + title: Media Use + levels: + - low + rules: [] + status: pending + - id: mp-7.1 + title: Prohibit Use Without Owner + rules: [] + status: pending + - id: mp-7.2 + title: Prohibit Use of Sanitization-resistant Media + rules: [] + status: pending + - id: mp-8 + title: Media Downgrading + rules: [] + status: pending + - id: mp-8.1 + title: Documentation of Process + rules: [] + status: pending + - id: mp-8.2 + title: Equipment Testing + rules: [] + status: pending + - id: mp-8.3 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-8.4 + title: Classified Information + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/pe.yml b/products/rhel9/controls/nist_800_53/pe.yml new file mode 100644 index 000000000000..b6728c7d49d5 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/pe.yml @@ -0,0 +1,288 @@ +# NIST 800-53 PE Family: Physical and Environmental Protection +controls: + - id: pe-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pe-2 + title: Physical Access Authorizations + levels: + - low + rules: [] + status: pending + - id: pe-2.1 + title: Access by Position or Role + rules: [] + status: pending + - id: pe-2.2 + title: Two Forms of Identification + rules: [] + status: pending + - id: pe-2.3 + title: Restrict Unescorted Access + rules: [] + status: pending + - id: pe-3 + title: Physical Access Control + levels: + - low + rules: [] + status: pending + - id: pe-3.1 + title: System Access + levels: + - high + rules: [] + status: pending + - id: pe-3.2 + title: Facility and Systems + rules: [] + status: pending + - id: pe-3.3 + title: Continuous Guards + rules: [] + status: pending + - id: pe-3.4 + title: Lockable Casings + rules: [] + status: pending + - id: pe-3.5 + title: Tamper Protection + rules: [] + status: pending + - id: pe-3.6 + title: Facility Penetration Testing + rules: [] + status: pending + - id: pe-3.7 + title: Physical Barriers + rules: [] + status: pending + - id: pe-3.8 + title: Access Control Vestibules + rules: [] + status: pending + - id: pe-4 + title: Access Control for Transmission + levels: + - moderate + rules: [] + status: pending + - id: pe-5 + title: Access Control for Output Devices + levels: + - moderate + rules: [] + status: pending + - id: pe-5.1 + title: Access to Output by Authorized Individuals + rules: [] + status: pending + - id: pe-5.2 + title: Link to Individual Identity + rules: [] + status: pending + - id: pe-5.3 + title: Marking Output Devices + rules: [] + status: pending + - id: pe-6 + title: Monitoring Physical Access + levels: + - low + rules: [] + status: pending + - id: pe-6.1 + title: Intrusion Alarms and Surveillance Equipment + levels: + - moderate + rules: [] + status: pending + - id: pe-6.2 + title: Automated Intrusion Recognition and Responses + rules: [] + status: pending + - id: pe-6.3 + title: Video Surveillance + rules: [] + status: pending + - id: pe-6.4 + title: Monitoring Physical Access to Systems + levels: + - high + rules: [] + status: pending + - id: pe-7 + title: Visitor Control + rules: [] + status: pending + - id: pe-8 + title: Visitor Access Records + levels: + - low + rules: [] + status: pending + - id: pe-8.1 + title: Automated Records Maintenance and Review + levels: + - high + rules: [] + status: pending + - id: pe-8.2 + title: Physical Access Records + rules: [] + status: pending + - id: pe-8.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: pe-9 + title: Power Equipment and Cabling + levels: + - moderate + rules: [] + status: pending + - id: pe-9.1 + title: Redundant Cabling + rules: [] + status: pending + - id: pe-9.2 + title: Automatic Voltage Controls + rules: [] + status: pending + - id: pe-10 + title: Emergency Shutoff + levels: + - moderate + rules: [] + status: pending + - id: pe-10.1 + title: Accidental and Unauthorized Activation + rules: [] + status: pending + - id: pe-11 + title: Emergency Power + levels: + - moderate + rules: [] + status: pending + - id: pe-11.1 + title: Alternate Power Supply — Minimal Operational Capability + levels: + - high + rules: [] + status: pending + - id: pe-11.2 + title: Alternate Power Supply — Self-contained + rules: [] + status: pending + - id: pe-12 + title: Emergency Lighting + levels: + - low + rules: [] + status: pending + - id: pe-12.1 + title: Essential Mission and Business Functions + rules: [] + status: pending + - id: pe-13 + title: Fire Protection + levels: + - low + rules: [] + status: pending + - id: pe-13.1 + title: Detection Systems — Automatic Activation and Notification + levels: + - moderate + rules: [] + status: pending + - id: pe-13.2 + title: Suppression Systems — Automatic Activation and Notification + levels: + - high + rules: [] + status: pending + - id: pe-13.3 + title: Automatic Fire Suppression + rules: [] + status: pending + - id: pe-13.4 + title: Inspections + rules: [] + status: pending + - id: pe-14 + title: Environmental Controls + levels: + - low + rules: [] + status: pending + - id: pe-14.1 + title: Automatic Controls + rules: [] + status: pending + - id: pe-14.2 + title: Monitoring with Alarms and Notifications + rules: [] + status: pending + - id: pe-15 + title: Water Damage Protection + levels: + - low + rules: [] + status: pending + - id: pe-15.1 + title: Automation Support + levels: + - high + rules: [] + status: pending + - id: pe-16 + title: Delivery and Removal + levels: + - low + rules: [] + status: pending + - id: pe-17 + title: Alternate Work Site + levels: + - moderate + rules: [] + status: pending + - id: pe-18 + title: Location of System Components + levels: + - high + rules: [] + status: pending + - id: pe-18.1 + title: Facility Site + rules: [] + status: pending + - id: pe-19 + title: Information Leakage + rules: [] + status: pending + - id: pe-19.1 + title: National Emissions Policies and Procedures + rules: [] + status: pending + - id: pe-20 + title: Asset Monitoring and Tracking + rules: [] + status: pending + - id: pe-21 + title: Electromagnetic Pulse Protection + rules: [] + status: pending + - id: pe-22 + title: Component Marking + rules: [] + status: pending + - id: pe-23 + title: Facility Location + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/pl.yml b/products/rhel9/controls/nist_800_53/pl.yml new file mode 100644 index 000000000000..d670e154e380 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/pl.yml @@ -0,0 +1,84 @@ +# NIST 800-53 PL Family: Planning +controls: + - id: pl-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pl-2 + title: System Security and Privacy Plans + levels: + - low + rules: [] + status: pending + - id: pl-2.1 + title: Concept of Operations + rules: [] + status: pending + - id: pl-2.2 + title: Functional Architecture + rules: [] + status: pending + - id: pl-2.3 + title: Plan and Coordinate with Other Organizational Entities + rules: [] + status: pending + - id: pl-3 + title: System Security Plan Update + rules: [] + status: pending + - id: pl-4 + title: Rules of Behavior + levels: + - low + rules: [] + status: pending + - id: pl-4.1 + title: Social Media and External Site/Application Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: pl-5 + title: Privacy Impact Assessment + rules: [] + status: pending + - id: pl-6 + title: Security-related Activity Planning + rules: [] + status: pending + - id: pl-7 + title: Concept of Operations + rules: [] + status: pending + - id: pl-8 + title: Security and Privacy Architectures + levels: + - moderate + rules: [] + status: pending + - id: pl-8.1 + title: Defense in Depth + rules: [] + status: pending + - id: pl-8.2 + title: Supplier Diversity + rules: [] + status: pending + - id: pl-9 + title: Central Management + rules: [] + status: pending + - id: pl-10 + title: Baseline Selection + levels: + - low + rules: [] + status: pending + - id: pl-11 + title: Baseline Tailoring + levels: + - low + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/pm.yml b/products/rhel9/controls/nist_800_53/pm.yml new file mode 100644 index 000000000000..97a32be05deb --- /dev/null +++ b/products/rhel9/controls/nist_800_53/pm.yml @@ -0,0 +1,151 @@ +# NIST 800-53 PM Family: Program Management +controls: + - id: pm-1 + title: Information Security Program Plan + rules: [] + status: pending + - id: pm-2 + title: Information Security Program Leadership Role + rules: [] + status: pending + - id: pm-3 + title: Information Security and Privacy Resources + rules: [] + status: pending + - id: pm-4 + title: Plan of Action and Milestones Process + rules: [] + status: pending + - id: pm-5 + title: System Inventory + rules: [] + status: pending + - id: pm-5.1 + title: Inventory of Personally Identifiable Information + rules: [] + status: pending + - id: pm-6 + title: Measures of Performance + rules: [] + status: pending + - id: pm-7 + title: Enterprise Architecture + rules: [] + status: pending + - id: pm-7.1 + title: Offloading + rules: [] + status: pending + - id: pm-8 + title: Critical Infrastructure Plan + rules: [] + status: pending + - id: pm-9 + title: Risk Management Strategy + rules: [] + status: pending + - id: pm-10 + title: Authorization Process + rules: [] + status: pending + - id: pm-11 + title: Mission and Business Process Definition + rules: [] + status: pending + - id: pm-12 + title: Insider Threat Program + rules: [] + status: pending + - id: pm-13 + title: Security and Privacy Workforce + rules: [] + status: pending + - id: pm-14 + title: Testing, Training, and Monitoring + rules: [] + status: pending + - id: pm-15 + title: Security and Privacy Groups and Associations + rules: [] + status: pending + - id: pm-16 + title: Threat Awareness Program + rules: [] + status: pending + - id: pm-16.1 + title: Automated Means for Sharing Threat Intelligence + rules: [] + status: pending + - id: pm-17 + title: Protecting Controlled Unclassified Information on External Systems + rules: [] + status: pending + - id: pm-18 + title: Privacy Program Plan + rules: [] + status: pending + - id: pm-19 + title: Privacy Program Leadership Role + rules: [] + status: pending + - id: pm-20 + title: Dissemination of Privacy Program Information + rules: [] + status: pending + - id: pm-20.1 + title: Privacy Policies on Websites, Applications, and Digital Services + rules: [] + status: pending + - id: pm-21 + title: Accounting of Disclosures + rules: [] + status: pending + - id: pm-22 + title: Personally Identifiable Information Quality Management + rules: [] + status: pending + - id: pm-23 + title: Data Governance Body + rules: [] + status: pending + - id: pm-24 + title: Data Integrity Board + rules: [] + status: pending + - id: pm-25 + title: Minimization of Personally Identifiable Information Used in Testing, Training, and + Research + rules: [] + status: pending + - id: pm-26 + title: Complaint Management + rules: [] + status: pending + - id: pm-27 + title: Privacy Reporting + rules: [] + status: pending + - id: pm-28 + title: Risk Framing + rules: [] + status: pending + - id: pm-29 + title: Risk Management Program Leadership Roles + rules: [] + status: pending + - id: pm-30 + title: Supply Chain Risk Management Strategy + rules: [] + status: pending + - id: pm-30.1 + title: Suppliers of Critical or Mission-essential Items + rules: [] + status: pending + - id: pm-31 + title: Continuous Monitoring Strategy + rules: [] + status: pending + - id: pm-32 + title: Purposing + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/ps.yml b/products/rhel9/controls/nist_800_53/ps.yml new file mode 100644 index 000000000000..ad7d70333c17 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ps.yml @@ -0,0 +1,94 @@ +# NIST 800-53 PS Family: Personnel Security +controls: + - id: ps-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ps-2 + title: Position Risk Designation + levels: + - low + rules: [] + status: pending + - id: ps-3 + title: Personnel Screening + levels: + - low + rules: [] + status: pending + - id: ps-3.1 + title: Classified Information + rules: [] + status: pending + - id: ps-3.2 + title: Formal Indoctrination + rules: [] + status: pending + - id: ps-3.3 + title: Information Requiring Special Protective Measures + rules: [] + status: pending + - id: ps-3.4 + title: Citizenship Requirements + rules: [] + status: pending + - id: ps-4 + title: Personnel Termination + levels: + - low + rules: [] + status: pending + - id: ps-4.1 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-4.2 + title: Automated Actions + levels: + - high + rules: [] + status: pending + - id: ps-5 + title: Personnel Transfer + levels: + - low + rules: [] + status: pending + - id: ps-6 + title: Access Agreements + levels: + - low + rules: [] + status: pending + - id: ps-6.1 + title: Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.2 + title: Classified Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.3 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-7 + title: External Personnel Security + levels: + - low + rules: [] + status: pending + - id: ps-8 + title: Personnel Sanctions + levels: + - low + rules: [] + status: pending + - id: ps-9 + title: Position Descriptions + levels: + - low + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/pt.yml b/products/rhel9/controls/nist_800_53/pt.yml new file mode 100644 index 000000000000..fe3d1ee54437 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/pt.yml @@ -0,0 +1,86 @@ +# NIST 800-53 PT Family: PII Processing and Transparency +controls: + - id: pt-1 + title: Policy and Procedures + rules: [] + status: pending + - id: pt-2 + title: Authority to Process Personally Identifiable Information + rules: [] + status: pending + - id: pt-2.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-2.2 + title: Automation + rules: [] + status: pending + - id: pt-3 + title: Personally Identifiable Information Processing Purposes + rules: [] + status: pending + - id: pt-3.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-3.2 + title: Automation + rules: [] + status: pending + - id: pt-4 + title: Consent + rules: [] + status: pending + - id: pt-4.1 + title: Tailored Consent + rules: [] + status: pending + - id: pt-4.2 + title: Just-in-time Consent + rules: [] + status: pending + - id: pt-4.3 + title: Revocation + rules: [] + status: pending + - id: pt-5 + title: Privacy Notice + rules: [] + status: pending + - id: pt-5.1 + title: Just-in-time Notice + rules: [] + status: pending + - id: pt-5.2 + title: Privacy Act Statements + rules: [] + status: pending + - id: pt-6 + title: System of Records Notice + rules: [] + status: pending + - id: pt-6.1 + title: Routine Uses + rules: [] + status: pending + - id: pt-6.2 + title: Exemption Rules + rules: [] + status: pending + - id: pt-7 + title: Specific Categories of Personally Identifiable Information + rules: [] + status: pending + - id: pt-7.1 + title: Social Security Numbers + rules: [] + status: pending + - id: pt-7.2 + title: First Amendment Information + rules: [] + status: pending + - id: pt-8 + title: Computer Matching Requirements + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/ra.yml b/products/rhel9/controls/nist_800_53/ra.yml new file mode 100644 index 000000000000..ca44e21f4e67 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/ra.yml @@ -0,0 +1,128 @@ +# NIST 800-53 RA Family: Risk Assessment +controls: + - id: ra-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ra-2 + title: Security Categorization + levels: + - low + rules: [] + status: pending + - id: ra-2.1 + title: Impact-level Prioritization + rules: [] + status: pending + - id: ra-3 + title: Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.1 + title: Supply Chain Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.2 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: ra-3.3 + title: Dynamic Threat Awareness + rules: [] + status: pending + - id: ra-3.4 + title: Predictive Cyber Analytics + rules: [] + status: pending + - id: ra-4 + title: Risk Assessment Update + rules: [] + status: pending + - id: ra-5 + title: Vulnerability Monitoring and Scanning + levels: + - low + rules: [] + status: pending + - id: ra-5.1 + title: Update Tool Capability + rules: [] + status: pending + - id: ra-5.2 + title: Update Vulnerabilities to Be Scanned + levels: + - low + rules: [] + status: pending + - id: ra-5.3 + title: Breadth and Depth of Coverage + rules: [] + status: pending + - id: ra-5.4 + title: Discoverable Information + levels: + - high + rules: [] + status: pending + - id: ra-5.5 + title: Privileged Access + levels: + - moderate + rules: [] + status: pending + - id: ra-5.6 + title: Automated Trend Analyses + rules: [] + status: pending + - id: ra-5.7 + title: Automated Detection and Notification of Unauthorized Components + rules: [] + status: pending + - id: ra-5.8 + title: Review Historic Audit Logs + rules: [] + status: pending + - id: ra-5.9 + title: Penetration Testing and Analyses + rules: [] + status: pending + - id: ra-5.10 + title: Correlate Scanning Information + rules: [] + status: pending + - id: ra-5.11 + title: Public Disclosure Program + levels: + - low + rules: [] + status: pending + - id: ra-6 + title: Technical Surveillance Countermeasures Survey + rules: [] + status: pending + - id: ra-7 + title: Risk Response + levels: + - low + rules: [] + status: pending + - id: ra-8 + title: Privacy Impact Assessments + rules: [] + status: pending + - id: ra-9 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: ra-10 + title: Threat Hunting + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/sa.yml b/products/rhel9/controls/nist_800_53/sa.yml new file mode 100644 index 000000000000..89a619dd4589 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/sa.yml @@ -0,0 +1,632 @@ +# NIST 800-53 SA Family: System and Services Acquisition +controls: + - id: sa-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sa-2 + title: Allocation of Resources + levels: + - low + rules: [] + status: pending + - id: sa-3 + title: System Development Life Cycle + levels: + - low + rules: [] + status: pending + - id: sa-3.1 + title: Manage Preproduction Environment + rules: [] + status: pending + - id: sa-3.2 + title: Use of Live or Operational Data + rules: [] + status: pending + - id: sa-3.3 + title: Technology Refresh + rules: [] + status: pending + - id: sa-4 + title: Acquisition Process + levels: + - low + rules: [] + status: pending + - id: sa-4.1 + title: Functional Properties of Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.2 + title: Design and Implementation Information for Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.3 + title: Development Methods, Techniques, and Practices + rules: [] + status: pending + - id: sa-4.4 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: sa-4.5 + title: System, Component, and Service Configurations + levels: + - high + rules: [] + status: pending + - id: sa-4.6 + title: Use of Information Assurance Products + rules: [] + status: pending + - id: sa-4.7 + title: 'NIAP-approved Protection Profiles ' + rules: [] + status: pending + - id: sa-4.8 + title: Continuous Monitoring Plan for Controls + rules: [] + status: pending + - id: sa-4.9 + title: Functions, Ports, Protocols, and Services in Use + levels: + - moderate + rules: [] + status: pending + - id: sa-4.10 + title: Use of Approved PIV Products + levels: + - low + rules: [] + status: pending + - id: sa-4.11 + title: System of Records + rules: [] + status: pending + - id: sa-4.12 + title: Data Ownership + rules: [] + status: pending + - id: sa-5 + title: System Documentation + levels: + - low + rules: [] + status: pending + - id: sa-5.1 + title: Functional Properties of Security Controls + rules: [] + status: pending + - id: sa-5.2 + title: Security-relevant External System Interfaces + rules: [] + status: pending + - id: sa-5.3 + title: High-level Design + rules: [] + status: pending + - id: sa-5.4 + title: Low-level Design + rules: [] + status: pending + - id: sa-5.5 + title: Source Code + rules: [] + status: pending + - id: sa-6 + title: Software Usage Restrictions + rules: [] + status: pending + - id: sa-7 + title: User-installed Software + rules: [] + status: pending + - id: sa-8 + title: Security and Privacy Engineering Principles + levels: + - low + rules: [] + status: pending + - id: sa-8.1 + title: Clear Abstractions + rules: [] + status: pending + - id: sa-8.2 + title: Least Common Mechanism + rules: [] + status: pending + - id: sa-8.3 + title: Modularity and Layering + rules: [] + status: pending + - id: sa-8.4 + title: Partially Ordered Dependencies + rules: [] + status: pending + - id: sa-8.5 + title: Efficiently Mediated Access + rules: [] + status: pending + - id: sa-8.6 + title: Minimized Sharing + rules: [] + status: pending + - id: sa-8.7 + title: Reduced Complexity + rules: [] + status: pending + - id: sa-8.8 + title: Secure Evolvability + rules: [] + status: pending + - id: sa-8.9 + title: Trusted Components + rules: [] + status: pending + - id: sa-8.10 + title: Hierarchical Trust + rules: [] + status: pending + - id: sa-8.11 + title: Inverse Modification Threshold + rules: [] + status: pending + - id: sa-8.12 + title: Hierarchical Protection + rules: [] + status: pending + - id: sa-8.13 + title: Minimized Security Elements + rules: [] + status: pending + - id: sa-8.14 + title: Least Privilege + rules: [] + status: pending + - id: sa-8.15 + title: Predicate Permission + rules: [] + status: pending + - id: sa-8.16 + title: Self-reliant Trustworthiness + rules: [] + status: pending + - id: sa-8.17 + title: Secure Distributed Composition + rules: [] + status: pending + - id: sa-8.18 + title: Trusted Communications Channels + rules: [] + status: pending + - id: sa-8.19 + title: Continuous Protection + rules: [] + status: pending + - id: sa-8.20 + title: Secure Metadata Management + rules: [] + status: pending + - id: sa-8.21 + title: Self-analysis + rules: [] + status: pending + - id: sa-8.22 + title: Accountability and Traceability + rules: [] + status: pending + - id: sa-8.23 + title: Secure Defaults + rules: [] + status: pending + - id: sa-8.24 + title: Secure Failure and Recovery + rules: [] + status: pending + - id: sa-8.25 + title: Economic Security + rules: [] + status: pending + - id: sa-8.26 + title: Performance Security + rules: [] + status: pending + - id: sa-8.27 + title: Human Factored Security + rules: [] + status: pending + - id: sa-8.28 + title: Acceptable Security + rules: [] + status: pending + - id: sa-8.29 + title: Repeatable and Documented Procedures + rules: [] + status: pending + - id: sa-8.30 + title: Procedural Rigor + rules: [] + status: pending + - id: sa-8.31 + title: Secure System Modification + rules: [] + status: pending + - id: sa-8.32 + title: Sufficient Documentation + rules: [] + status: pending + - id: sa-8.33 + title: Minimization + rules: [] + status: pending + - id: sa-9 + title: External System Services + levels: + - low + rules: [] + status: pending + - id: sa-9.1 + title: Risk Assessments and Organizational Approvals + rules: [] + status: pending + - id: sa-9.2 + title: Identification of Functions, Ports, Protocols, and Services + levels: + - moderate + rules: [] + status: pending + - id: sa-9.3 + title: Establish and Maintain Trust Relationship with Providers + rules: [] + status: pending + - id: sa-9.4 + title: Consistent Interests of Consumers and Providers + rules: [] + status: pending + - id: sa-9.5 + title: Processing, Storage, and Service Location + rules: [] + status: pending + - id: sa-9.6 + title: Organization-controlled Cryptographic Keys + rules: [] + status: pending + - id: sa-9.7 + title: Organization-controlled Integrity Checking + rules: [] + status: pending + - id: sa-9.8 + title: Processing and Storage Location — U.S. Jurisdiction + rules: [] + status: pending + - id: sa-10 + title: Developer Configuration Management + levels: + - moderate + rules: [] + status: pending + - id: sa-10.1 + title: Software and Firmware Integrity Verification + rules: [] + status: pending + - id: sa-10.2 + title: Alternative Configuration Management Processes + rules: [] + status: pending + - id: sa-10.3 + title: Hardware Integrity Verification + rules: [] + status: pending + - id: sa-10.4 + title: Trusted Generation + rules: [] + status: pending + - id: sa-10.5 + title: Mapping Integrity for Version Control + rules: [] + status: pending + - id: sa-10.6 + title: Trusted Distribution + rules: [] + status: pending + - id: sa-10.7 + title: Security and Privacy Representatives + rules: [] + status: pending + - id: sa-11 + title: Developer Testing and Evaluation + levels: + - moderate + rules: [] + status: pending + - id: sa-11.1 + title: Static Code Analysis + rules: [] + status: pending + - id: sa-11.2 + title: Threat Modeling and Vulnerability Analyses + rules: [] + status: pending + - id: sa-11.3 + title: Independent Verification of Assessment Plans and Evidence + rules: [] + status: pending + - id: sa-11.4 + title: Manual Code Reviews + rules: [] + status: pending + - id: sa-11.5 + title: Penetration Testing + rules: [] + status: pending + - id: sa-11.6 + title: Attack Surface Reviews + rules: [] + status: pending + - id: sa-11.7 + title: Verify Scope of Testing and Evaluation + rules: [] + status: pending + - id: sa-11.8 + title: Dynamic Code Analysis + rules: [] + status: pending + - id: sa-11.9 + title: Interactive Application Security Testing + rules: [] + status: pending + - id: sa-12 + title: Supply Chain Protection + rules: [] + status: pending + - id: sa-12.1 + title: Acquisition Strategies / Tools / Methods + rules: [] + status: pending + - id: sa-12.2 + title: Supplier Reviews + rules: [] + status: pending + - id: sa-12.3 + title: Trusted Shipping and Warehousing + rules: [] + status: pending + - id: sa-12.4 + title: Diversity of Suppliers + rules: [] + status: pending + - id: sa-12.5 + title: Limitation of Harm + rules: [] + status: pending + - id: sa-12.6 + title: Minimizing Procurement Time + rules: [] + status: pending + - id: sa-12.7 + title: Assessments Prior to Selection / Acceptance / Update + rules: [] + status: pending + - id: sa-12.8 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: sa-12.9 + title: Operations Security + rules: [] + status: pending + - id: sa-12.10 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sa-12.11 + title: Penetration Testing / Analysis of Elements, Processes, and Actors + rules: [] + status: pending + - id: sa-12.12 + title: Inter-organizational Agreements + rules: [] + status: pending + - id: sa-12.13 + title: Critical Information System Components + rules: [] + status: pending + - id: sa-12.14 + title: Identity and Traceability + rules: [] + status: pending + - id: sa-12.15 + title: Processes to Address Weaknesses or Deficiencies + rules: [] + status: pending + - id: sa-13 + title: Trustworthiness + rules: [] + status: pending + - id: sa-14 + title: Criticality Analysis + rules: [] + status: pending + - id: sa-14.1 + title: Critical Components with No Viable Alternative Sourcing + rules: [] + status: pending + - id: sa-15 + title: Development Process, Standards, and Tools + levels: + - moderate + rules: [] + status: pending + - id: sa-15.1 + title: Quality Metrics + rules: [] + status: pending + - id: sa-15.2 + title: Security and Privacy Tracking Tools + rules: [] + status: pending + - id: sa-15.3 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: sa-15.4 + title: Threat Modeling and Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.5 + title: Attack Surface Reduction + rules: [] + status: pending + - id: sa-15.6 + title: Continuous Improvement + rules: [] + status: pending + - id: sa-15.7 + title: Automated Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.8 + title: Reuse of Threat and Vulnerability Information + rules: [] + status: pending + - id: sa-15.9 + title: Use of Live Data + rules: [] + status: pending + - id: sa-15.10 + title: Incident Response Plan + rules: [] + status: pending + - id: sa-15.11 + title: Archive System or Component + rules: [] + status: pending + - id: sa-15.12 + title: Minimize Personally Identifiable Information + rules: [] + status: pending + - id: sa-15.13 + title: Logging Syntax + rules: [] + status: pending + - id: sa-16 + title: Developer-provided Training + levels: + - high + rules: [] + status: pending + - id: sa-17 + title: Developer Security and Privacy Architecture and Design + levels: + - high + rules: [] + status: pending + - id: sa-17.1 + title: Formal Policy Model + rules: [] + status: pending + - id: sa-17.2 + title: Security-relevant Components + rules: [] + status: pending + - id: sa-17.3 + title: Formal Correspondence + rules: [] + status: pending + - id: sa-17.4 + title: Informal Correspondence + rules: [] + status: pending + - id: sa-17.5 + title: Conceptually Simple Design + rules: [] + status: pending + - id: sa-17.6 + title: Structure for Testing + rules: [] + status: pending + - id: sa-17.7 + title: Structure for Least Privilege + rules: [] + status: pending + - id: sa-17.8 + title: Orchestration + rules: [] + status: pending + - id: sa-17.9 + title: Design Diversity + rules: [] + status: pending + - id: sa-18 + title: Tamper Resistance and Detection + rules: [] + status: pending + - id: sa-18.1 + title: Multiple Phases of System Development Life Cycle + rules: [] + status: pending + - id: sa-18.2 + title: Inspection of Systems or Components + rules: [] + status: pending + - id: sa-19 + title: Component Authenticity + rules: [] + status: pending + - id: sa-19.1 + title: Anti-counterfeit Training + rules: [] + status: pending + - id: sa-19.2 + title: Configuration Control for Component Service and Repair + rules: [] + status: pending + - id: sa-19.3 + title: Component Disposal + rules: [] + status: pending + - id: sa-19.4 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sa-20 + title: Customized Development of Critical Components + rules: [] + status: pending + - id: sa-21 + title: Developer Screening + levels: + - high + rules: [] + status: pending + - id: sa-21.1 + title: Validation of Screening + rules: [] + status: pending + - id: sa-22 + title: Unsupported System Components + levels: + - low + rules: [] + status: pending + - id: sa-22.1 + title: Alternative Sources for Continued Support + rules: [] + status: pending + - id: sa-23 + title: Specialization + rules: [] + status: pending + - id: sa-24 + title: Design For Cyber Resiliency + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/sc.yml b/products/rhel9/controls/nist_800_53/sc.yml new file mode 100644 index 000000000000..a746caa687a7 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/sc.yml @@ -0,0 +1,720 @@ +# NIST 800-53 SC Family: System and Communications Protection +controls: + - id: sc-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sc-2 + title: Separation of System and User Functionality + levels: + - moderate + rules: [] + status: pending + - id: sc-2.1 + title: Interfaces for Non-privileged Users + rules: [] + status: pending + - id: sc-2.2 + title: Disassociability + rules: [] + status: pending + - id: sc-3 + title: Security Function Isolation + levels: + - high + rules: + - selinux_not_disabled + - selinux_state + - var_selinux_policy_name=targeted + - var_selinux_state=enforcing + status: automated + - id: sc-3.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-3.2 + title: Access and Flow Control Functions + rules: [] + status: pending + - id: sc-3.3 + title: Minimize Nonsecurity Functionality + rules: [] + status: pending + - id: sc-3.4 + title: Module Coupling and Cohesiveness + rules: [] + status: pending + - id: sc-3.5 + title: Layered Structures + rules: [] + status: pending + - id: sc-4 + title: Information in Shared System Resources + levels: + - moderate + rules: + - dir_perms_world_writable_sticky_bits + - file_permissions_unauthorized_world_writable + status: automated + - id: sc-4.1 + title: Security Levels + rules: [] + status: pending + - id: sc-4.2 + title: Multilevel or Periods Processing + rules: [] + status: pending + - id: sc-5 + title: Denial-of-service Protection + levels: + - low + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + - id: sc-5.1 + title: Restrict Ability to Attack Other Systems + rules: [] + status: pending + - id: sc-5.2 + title: Capacity, Bandwidth, and Redundancy + rules: [] + status: pending + - id: sc-5.3 + title: Detection and Monitoring + rules: [] + status: pending + - id: sc-6 + title: Resource Availability + rules: [] + status: pending + - id: sc-7 + title: Boundary Protection + levels: + - low + rules: + - service_firewalld_enabled + status: automated + - id: sc-7.1 + title: Physically Separated Subnetworks + rules: [] + status: pending + - id: sc-7.2 + title: Public Access + rules: [] + status: pending + - id: sc-7.3 + title: Access Points + levels: + - moderate + rules: [] + status: pending + - id: sc-7.4 + title: External Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: sc-7.5 + title: Deny by Default — Allow by Exception + levels: + - moderate + rules: [] + status: pending + - id: sc-7.6 + title: Response to Recognized Failures + rules: [] + status: pending + - id: sc-7.7 + title: Split Tunneling for Remote Devices + levels: + - moderate + rules: [] + status: pending + - id: sc-7.8 + title: Route Traffic to Authenticated Proxy Servers + levels: + - moderate + rules: [] + status: pending + - id: sc-7.9 + title: Restrict Threatening Outgoing Communications Traffic + rules: [] + status: pending + - id: sc-7.10 + title: Prevent Exfiltration + rules: [] + status: pending + - id: sc-7.11 + title: Restrict Incoming Communications Traffic + rules: [] + status: pending + - id: sc-7.12 + title: Host-based Protection + rules: [] + status: pending + - id: sc-7.13 + title: Isolation of Security Tools, Mechanisms, and Support Components + rules: [] + status: pending + - id: sc-7.14 + title: Protect Against Unauthorized Physical Connections + rules: [] + status: pending + - id: sc-7.15 + title: Networked Privileged Accesses + rules: [] + status: pending + - id: sc-7.16 + title: Prevent Discovery of System Components + rules: [] + status: pending + - id: sc-7.17 + title: Automated Enforcement of Protocol Formats + rules: [] + status: pending + - id: sc-7.18 + title: Fail Secure + levels: + - high + rules: [] + status: pending + - id: sc-7.19 + title: Block Communication from Non-organizationally Configured Hosts + rules: [] + status: pending + - id: sc-7.20 + title: Dynamic Isolation and Segregation + rules: [] + status: pending + - id: sc-7.21 + title: Isolation of System Components + levels: + - high + rules: [] + status: pending + - id: sc-7.22 + title: Separate Subnets for Connecting to Different Security Domains + rules: [] + status: pending + - id: sc-7.23 + title: Disable Sender Feedback on Protocol Validation Failure + rules: [] + status: pending + - id: sc-7.24 + title: Personally Identifiable Information + rules: [] + status: pending + - id: sc-7.25 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: sc-7.26 + title: Classified National Security System Connections + rules: [] + status: pending + - id: sc-7.27 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: sc-7.28 + title: Connections to Public Networks + rules: [] + status: pending + - id: sc-7.29 + title: Separate Subnets to Isolate Functions + rules: [] + status: pending + - id: sc-8 + title: Transmission Confidentiality and Integrity + levels: + - moderate + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: sc-8.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-8.2 + title: Pre- and Post-transmission Handling + rules: [] + status: pending + - id: sc-8.3 + title: Cryptographic Protection for Message Externals + rules: [] + status: pending + - id: sc-8.4 + title: Conceal or Randomize Communications + rules: [] + status: pending + - id: sc-8.5 + title: Protected Distribution System + rules: [] + status: pending + - id: sc-9 + title: Transmission Confidentiality + rules: [] + status: pending + - id: sc-10 + title: Network Disconnect + levels: + - moderate + rules: [] + status: pending + - id: sc-11 + title: Trusted Path + rules: [] + status: pending + - id: sc-11.1 + title: Irrefutable Communications Path + rules: [] + status: pending + - id: sc-12 + title: Cryptographic Key Establishment and Management + levels: + - low + rules: [] + status: pending + - id: sc-12.1 + title: Availability + levels: + - high + rules: [] + status: pending + - id: sc-12.2 + title: Symmetric Keys + rules: [] + status: pending + - id: sc-12.3 + title: Asymmetric Keys + rules: [] + status: pending + - id: sc-12.4 + title: PKI Certificates + rules: [] + status: pending + - id: sc-12.5 + title: PKI Certificates / Hardware Tokens + rules: [] + status: pending + - id: sc-12.6 + title: Physical Control of Keys + rules: [] + status: pending + - id: sc-13 + title: Cryptographic Protection + levels: + - low + rules: [] + status: pending + - id: sc-13.1 + title: FIPS-validated Cryptography + rules: [] + status: pending + - id: sc-13.2 + title: NSA-approved Cryptography + rules: [] + status: pending + - id: sc-13.3 + title: Individuals Without Formal Access Approvals + rules: [] + status: pending + - id: sc-13.4 + title: Digital Signatures + rules: [] + status: pending + - id: sc-14 + title: Public Access Protections + rules: [] + status: pending + - id: sc-15 + title: Collaborative Computing Devices and Applications + levels: + - low + rules: [] + status: pending + - id: sc-15.1 + title: Physical or Logical Disconnect + rules: [] + status: pending + - id: sc-15.2 + title: Blocking Inbound and Outbound Communications Traffic + rules: [] + status: pending + - id: sc-15.3 + title: Disabling and Removal in Secure Work Areas + rules: [] + status: pending + - id: sc-15.4 + title: Explicitly Indicate Current Participants + rules: [] + status: pending + - id: sc-16 + title: Transmission of Security and Privacy Attributes + rules: [] + status: pending + - id: sc-16.1 + title: Integrity Verification + rules: [] + status: pending + - id: sc-16.2 + title: Anti-spoofing Mechanisms + rules: [] + status: pending + - id: sc-16.3 + title: Cryptographic Binding + rules: [] + status: pending + - id: sc-17 + title: Public Key Infrastructure Certificates + levels: + - moderate + rules: [] + status: pending + - id: sc-18 + title: Mobile Code + levels: + - moderate + rules: [] + status: pending + - id: sc-18.1 + title: Identify Unacceptable Code and Take Corrective Actions + rules: [] + status: pending + - id: sc-18.2 + title: Acquisition, Development, and Use + rules: [] + status: pending + - id: sc-18.3 + title: Prevent Downloading and Execution + rules: [] + status: pending + - id: sc-18.4 + title: Prevent Automatic Execution + rules: [] + status: pending + - id: sc-18.5 + title: Allow Execution Only in Confined Environments + rules: [] + status: pending + - id: sc-19 + title: Voice Over Internet Protocol + rules: [] + status: pending + - id: sc-20 + title: Secure Name/Address Resolution Service (Authoritative Source) + levels: + - low + rules: [] + status: pending + - id: sc-20.1 + title: Child Subspaces + rules: [] + status: pending + - id: sc-20.2 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-21 + title: Secure Name/Address Resolution Service (Recursive or Caching Resolver) + levels: + - low + rules: [] + status: pending + - id: sc-21.1 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-22 + title: Architecture and Provisioning for Name/Address Resolution Service + levels: + - low + rules: [] + status: pending + - id: sc-23 + title: Session Authenticity + levels: + - moderate + rules: [] + status: pending + - id: sc-23.1 + title: Invalidate Session Identifiers at Logout + rules: [] + status: pending + - id: sc-23.2 + title: User-initiated Logouts and Message Displays + rules: [] + status: pending + - id: sc-23.3 + title: Unique System-generated Session Identifiers + rules: [] + status: pending + - id: sc-23.4 + title: Unique Session Identifiers with Randomization + rules: [] + status: pending + - id: sc-23.5 + title: Allowed Certificate Authorities + rules: [] + status: pending + - id: sc-24 + title: Fail in Known State + levels: + - high + rules: + - service_systemd-journald_enabled + status: automated + - id: sc-25 + title: Thin Nodes + rules: [] + status: pending + - id: sc-26 + title: Decoys + rules: [] + status: pending + - id: sc-26.1 + title: Detection of Malicious Code + rules: [] + status: pending + - id: sc-27 + title: Platform-independent Applications + rules: [] + status: pending + - id: sc-28 + title: Protection of Information at Rest + levels: + - moderate + rules: [] + status: pending + - id: sc-28.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-28.2 + title: Offline Storage + rules: [] + status: pending + - id: sc-28.3 + title: Cryptographic Keys + rules: [] + status: pending + - id: sc-29 + title: Heterogeneity + rules: [] + status: pending + - id: sc-29.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30 + title: Concealment and Misdirection + rules: [] + status: pending + - id: sc-30.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30.2 + title: Randomness + rules: [] + status: pending + - id: sc-30.3 + title: Change Processing and Storage Locations + rules: [] + status: pending + - id: sc-30.4 + title: Misleading Information + rules: [] + status: pending + - id: sc-30.5 + title: Concealment of System Components + rules: [] + status: pending + - id: sc-31 + title: Covert Channel Analysis + rules: [] + status: pending + - id: sc-31.1 + title: Test Covert Channels for Exploitability + rules: [] + status: pending + - id: sc-31.2 + title: Maximum Bandwidth + rules: [] + status: pending + - id: sc-31.3 + title: Measure Bandwidth in Operational Environments + rules: [] + status: pending + - id: sc-32 + title: System Partitioning + rules: [] + status: pending + - id: sc-32.1 + title: Separate Physical Domains for Privileged Functions + rules: [] + status: pending + - id: sc-33 + title: Transmission Preparation Integrity + rules: [] + status: pending + - id: sc-34 + title: Non-modifiable Executable Programs + rules: [] + status: pending + - id: sc-34.1 + title: No Writable Storage + rules: [] + status: pending + - id: sc-34.2 + title: Integrity Protection on Read-only Media + rules: [] + status: pending + - id: sc-34.3 + title: Hardware-based Protection + rules: [] + status: pending + - id: sc-35 + title: External Malicious Code Identification + rules: [] + status: pending + - id: sc-36 + title: Distributed Processing and Storage + rules: [] + status: pending + - id: sc-36.1 + title: Polling Techniques + rules: [] + status: pending + - id: sc-36.2 + title: Synchronization + rules: [] + status: pending + - id: sc-37 + title: Out-of-band Channels + rules: [] + status: pending + - id: sc-37.1 + title: Ensure Delivery and Transmission + rules: [] + status: pending + - id: sc-38 + title: Operations Security + rules: [] + status: pending + - id: sc-39 + title: Process Isolation + levels: + - low + rules: [] + status: pending + - id: sc-39.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-39.2 + title: Separate Execution Domain Per Thread + rules: [] + status: pending + - id: sc-40 + title: Wireless Link Protection + rules: [] + status: pending + - id: sc-40.1 + title: Electromagnetic Interference + rules: [] + status: pending + - id: sc-40.2 + title: Reduce Detection Potential + rules: [] + status: pending + - id: sc-40.3 + title: Imitative or Manipulative Communications Deception + rules: [] + status: pending + - id: sc-40.4 + title: Signal Parameter Identification + rules: [] + status: pending + - id: sc-41 + title: Port and I/O Device Access + rules: [] + status: pending + - id: sc-42 + title: Sensor Capability and Data + rules: [] + status: pending + - id: sc-42.1 + title: Reporting to Authorized Individuals or Roles + rules: [] + status: pending + - id: sc-42.2 + title: Authorized Use + rules: [] + status: pending + - id: sc-42.3 + title: Prohibit Use of Devices + rules: [] + status: pending + - id: sc-42.4 + title: Notice of Collection + rules: [] + status: pending + - id: sc-42.5 + title: Collection Minimization + rules: [] + status: pending + - id: sc-43 + title: Usage Restrictions + rules: [] + status: pending + - id: sc-44 + title: Detonation Chambers + rules: [] + status: pending + - id: sc-45 + title: System Time Synchronization + rules: [] + status: pending + - id: sc-45.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: sc-45.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: sc-46 + title: Cross Domain Policy Enforcement + rules: [] + status: pending + - id: sc-47 + title: Alternate Communications Paths + rules: [] + status: pending + - id: sc-48 + title: Sensor Relocation + rules: [] + status: pending + - id: sc-48.1 + title: Dynamic Relocation of Sensors or Monitoring Capabilities + rules: [] + status: pending + - id: sc-49 + title: Hardware-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-50 + title: Software-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-51 + title: Hardware-based Protection + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/si.yml b/products/rhel9/controls/nist_800_53/si.yml new file mode 100644 index 000000000000..4cabcafda2db --- /dev/null +++ b/products/rhel9/controls/nist_800_53/si.yml @@ -0,0 +1,545 @@ +# NIST 800-53 SI Family: System and Information Integrity +controls: + - id: si-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: si-2 + title: Flaw Remediation + levels: + - low + rules: + - ensure_gpgcheck_globally_activated + - ensure_gpgcheck_never_disabled + - ensure_redhat_gpgkey_installed + status: automated + - id: si-2.1 + title: Central Management + rules: [] + status: pending + - id: si-2.2 + title: Automated Flaw Remediation Status + levels: + - moderate + rules: [] + status: pending + - id: si-2.3 + title: Time to Remediate Flaws and Benchmarks for Corrective Actions + rules: [] + status: pending + - id: si-2.4 + title: Automated Patch Management Tools + rules: [] + status: pending + - id: si-2.5 + title: Automatic Software and Firmware Updates + rules: [] + status: pending + - id: si-2.6 + title: Removal of Previous Versions of Software and Firmware + rules: [] + status: pending + - id: si-2.7 + title: Root Cause Analysis + rules: [] + status: pending + - id: si-3 + title: Malicious Code Protection + levels: + - low + rules: + - kernel_module_usb-storage_disabled + - service_autofs_disabled + status: automated + - id: si-3.1 + title: Central Management + rules: [] + status: pending + - id: si-3.2 + title: Automatic Updates + rules: [] + status: pending + - id: si-3.3 + title: Non-privileged Users + rules: [] + status: pending + - id: si-3.4 + title: Updates Only by Privileged Users + rules: [] + status: pending + - id: si-3.5 + title: Portable Storage Devices + rules: [] + status: pending + - id: si-3.6 + title: Testing and Verification + rules: [] + status: pending + - id: si-3.7 + title: Nonsignature-based Detection + rules: [] + status: pending + - id: si-3.8 + title: Detect Unauthorized Commands + rules: [] + status: pending + - id: si-3.9 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: si-3.10 + title: Malicious Code Analysis + rules: [] + status: pending + - id: si-4 + title: System Monitoring + levels: + - low + rules: + - kernel_module_dccp_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_tipc_disabled + - service_avahi-daemon_disabled + status: automated + - id: si-4.1 + title: System-wide Intrusion Detection System + rules: [] + status: pending + - id: si-4.2 + title: Automated Tools and Mechanisms for Real-time Analysis + levels: + - moderate + rules: [] + status: pending + - id: si-4.3 + title: Automated Tool and Mechanism Integration + rules: [] + status: pending + - id: si-4.4 + title: Inbound and Outbound Communications Traffic + levels: + - moderate + rules: [] + status: pending + - id: si-4.5 + title: System-generated Alerts + levels: + - moderate + rules: [] + status: pending + - id: si-4.6 + title: Restrict Non-privileged Users + rules: [] + status: pending + - id: si-4.7 + title: Automated Response to Suspicious Events + rules: [] + status: pending + - id: si-4.8 + title: Protection of Monitoring Information + rules: [] + status: pending + - id: si-4.9 + title: Testing of Monitoring Tools and Mechanisms + rules: [] + status: pending + - id: si-4.10 + title: Visibility of Encrypted Communications + levels: + - high + rules: [] + status: pending + - id: si-4.11 + title: Analyze Communications Traffic Anomalies + rules: [] + status: pending + - id: si-4.12 + title: Automated Organization-generated Alerts + levels: + - high + rules: [] + status: pending + - id: si-4.13 + title: Analyze Traffic and Event Patterns + rules: [] + status: pending + - id: si-4.14 + title: Wireless Intrusion Detection + levels: + - high + rules: [] + status: pending + - id: si-4.15 + title: Wireless to Wireline Communications + rules: [] + status: pending + - id: si-4.16 + title: Correlate Monitoring Information + rules: [] + status: pending + - id: si-4.17 + title: Integrated Situational Awareness + rules: [] + status: pending + - id: si-4.18 + title: Analyze Traffic and Covert Exfiltration + rules: [] + status: pending + - id: si-4.19 + title: Risk for Individuals + rules: [] + status: pending + - id: si-4.20 + title: Privileged Users + levels: + - high + rules: [] + status: pending + - id: si-4.21 + title: Probationary Periods + rules: [] + status: pending + - id: si-4.22 + title: Unauthorized Network Services + levels: + - high + rules: [] + status: pending + - id: si-4.23 + title: Host-based Devices + rules: [] + status: pending + - id: si-4.24 + title: Indicators of Compromise + rules: [] + status: pending + - id: si-4.25 + title: Optimize Network Traffic Analysis + rules: [] + status: pending + - id: si-5 + title: Security Alerts, Advisories, and Directives + levels: + - low + rules: [] + status: pending + - id: si-5.1 + title: Automated Alerts and Advisories + levels: + - high + rules: [] + status: pending + - id: si-6 + title: Security and Privacy Function Verification + levels: + - high + rules: [] + status: pending + - id: si-6.1 + title: Notification of Failed Security Tests + rules: [] + status: pending + - id: si-6.2 + title: Automation Support for Distributed Testing + rules: [] + status: pending + - id: si-6.3 + title: Report Verification Results + rules: [] + status: pending + - id: si-7 + title: Software, Firmware, and Information Integrity + levels: + - moderate + rules: [] + status: pending + - id: si-7.1 + title: Integrity Checks + levels: + - moderate + rules: [] + status: pending + - id: si-7.2 + title: Automated Notifications of Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.3 + title: Centrally Managed Integrity Tools + rules: [] + status: pending + - id: si-7.4 + title: Tamper-evident Packaging + rules: [] + status: pending + - id: si-7.5 + title: Automated Response to Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: si-7.7 + title: Integration of Detection and Response + levels: + - moderate + rules: [] + status: pending + - id: si-7.8 + title: Auditing Capability for Significant Events + rules: [] + status: pending + - id: si-7.9 + title: Verify Boot Process + rules: [] + status: pending + - id: si-7.10 + title: Protection of Boot Firmware + rules: [] + status: pending + - id: si-7.11 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: si-7.12 + title: Integrity Verification + rules: [] + status: pending + - id: si-7.13 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: si-7.14 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: si-7.15 + title: Code Authentication + levels: + - high + rules: [] + status: pending + - id: si-7.16 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-7.17 + title: Runtime Application Self-protection + rules: [] + status: pending + - id: si-8 + title: Spam Protection + levels: + - moderate + rules: [] + status: pending + - id: si-8.1 + title: Central Management + rules: [] + status: pending + - id: si-8.2 + title: Automatic Updates + levels: + - moderate + rules: [] + status: pending + - id: si-8.3 + title: Continuous Learning Capability + rules: [] + status: pending + - id: si-9 + title: Information Input Restrictions + rules: [] + status: pending + - id: si-10 + title: Information Input Validation + levels: + - moderate + rules: [] + status: pending + - id: si-10.1 + title: Manual Override Capability + rules: [] + status: pending + - id: si-10.2 + title: Review and Resolve Errors + rules: [] + status: pending + - id: si-10.3 + title: Predictable Behavior + rules: [] + status: pending + - id: si-10.4 + title: Timing Interactions + rules: [] + status: pending + - id: si-10.5 + title: Restrict Inputs to Trusted Sources and Approved Formats + rules: [] + status: pending + - id: si-10.6 + title: Injection Prevention + rules: [] + status: pending + - id: si-11 + title: Error Handling + levels: + - moderate + rules: [] + status: pending + - id: si-12 + title: Information Management and Retention + levels: + - low + rules: [] + status: pending + - id: si-12.1 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: si-12.2 + title: Minimize Personally Identifiable Information in Testing, Training, and Research + rules: [] + status: pending + - id: si-12.3 + title: Information Disposal + rules: [] + status: pending + - id: si-13 + title: Predictable Failure Prevention + rules: [] + status: pending + - id: si-13.1 + title: Transferring Component Responsibilities + rules: [] + status: pending + - id: si-13.2 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-13.3 + title: Manual Transfer Between Components + rules: [] + status: pending + - id: si-13.4 + title: Standby Component Installation and Notification + rules: [] + status: pending + - id: si-13.5 + title: Failover Capability + rules: [] + status: pending + - id: si-14 + title: Non-persistence + rules: [] + status: pending + - id: si-14.1 + title: Refresh from Trusted Sources + rules: [] + status: pending + - id: si-14.2 + title: Non-persistent Information + rules: [] + status: pending + - id: si-14.3 + title: Non-persistent Connectivity + rules: [] + status: pending + - id: si-15 + title: Information Output Filtering + rules: [] + status: pending + - id: si-16 + title: Memory Protection + levels: + - moderate + rules: + - sysctl_kernel_randomize_va_space + status: automated + - id: si-17 + title: Fail-safe Procedures + rules: [] + status: pending + - id: si-18 + title: Personally Identifiable Information Quality Operations + rules: [] + status: pending + - id: si-18.1 + title: Automation Support + rules: [] + status: pending + - id: si-18.2 + title: Data Tags + rules: [] + status: pending + - id: si-18.3 + title: Collection + rules: [] + status: pending + - id: si-18.4 + title: Individual Requests + rules: [] + status: pending + - id: si-18.5 + title: Notice of Correction or Deletion + rules: [] + status: pending + - id: si-19 + title: De-identification + rules: [] + status: pending + - id: si-19.1 + title: Collection + rules: [] + status: pending + - id: si-19.2 + title: Archiving + rules: [] + status: pending + - id: si-19.3 + title: Release + rules: [] + status: pending + - id: si-19.4 + title: Removal, Masking, Encryption, Hashing, or Replacement of Direct Identifiers + rules: [] + status: pending + - id: si-19.5 + title: Statistical Disclosure Control + rules: [] + status: pending + - id: si-19.6 + title: Differential Privacy + rules: [] + status: pending + - id: si-19.7 + title: Validated Algorithms and Software + rules: [] + status: pending + - id: si-19.8 + title: Motivated Intruder + rules: [] + status: pending + - id: si-20 + title: Tainting + rules: [] + status: pending + - id: si-21 + title: Information Refresh + rules: [] + status: pending + - id: si-22 + title: Information Diversity + rules: [] + status: pending + - id: si-23 + title: Information Fragmentation + rules: [] + status: pending diff --git a/products/rhel9/controls/nist_800_53/sr.yml b/products/rhel9/controls/nist_800_53/sr.yml new file mode 100644 index 000000000000..1e130f32cd89 --- /dev/null +++ b/products/rhel9/controls/nist_800_53/sr.yml @@ -0,0 +1,138 @@ +# NIST 800-53 SR Family: Supply Chain Risk Management +controls: + - id: sr-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sr-2 + title: Supply Chain Risk Management Plan + levels: + - low + rules: [] + status: pending + - id: sr-2.1 + title: Establish SCRM Team + levels: + - low + rules: [] + status: pending + - id: sr-3 + title: Supply Chain Controls and Processes + levels: + - low + rules: [] + status: pending + - id: sr-3.1 + title: Diverse Supply Base + rules: [] + status: pending + - id: sr-3.2 + title: Limitation of Harm + rules: [] + status: pending + - id: sr-3.3 + title: Sub-tier Flow Down + rules: [] + status: pending + - id: sr-4 + title: Provenance + rules: [] + status: pending + - id: sr-4.1 + title: Identity + rules: [] + status: pending + - id: sr-4.2 + title: Track and Trace + rules: [] + status: pending + - id: sr-4.3 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sr-4.4 + title: Supply Chain Integrity — Pedigree + rules: [] + status: pending + - id: sr-5 + title: Acquisition Strategies, Tools, and Methods + levels: + - low + rules: [] + status: pending + - id: sr-5.1 + title: Adequate Supply + rules: [] + status: pending + - id: sr-5.2 + title: Assessments Prior to Selection, Acceptance, Modification, or Update + rules: [] + status: pending + - id: sr-6 + title: Supplier Assessments and Reviews + levels: + - moderate + rules: [] + status: pending + - id: sr-6.1 + title: Testing and Analysis + rules: [] + status: pending + - id: sr-7 + title: Supply Chain Operations Security + rules: [] + status: pending + - id: sr-8 + title: Notification Agreements + levels: + - low + rules: [] + status: pending + - id: sr-9 + title: Tamper Resistance and Detection + levels: + - high + rules: [] + status: pending + - id: sr-9.1 + title: Multiple Stages of System Development Life Cycle + levels: + - high + rules: [] + status: pending + - id: sr-10 + title: Inspection of Systems or Components + levels: + - low + rules: [] + status: pending + - id: sr-11 + title: Component Authenticity + levels: + - low + rules: [] + status: pending + - id: sr-11.1 + title: Anti-counterfeit Training + levels: + - low + rules: [] + status: pending + - id: sr-11.2 + title: Configuration Control for Component Service and Repair + levels: + - low + rules: [] + status: pending + - id: sr-11.3 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sr-12 + title: Component Disposal + levels: + - low + rules: [] + status: pending diff --git a/products/rhel9/controls/stig_rhel9.yml b/products/rhel9/controls/stig_rhel9.yml index 7007e84787f1..76fd04b8c832 100644 --- a/products/rhel9/controls/stig_rhel9.yml +++ b/products/rhel9/controls/stig_rhel9.yml @@ -3,7 +3,7 @@ policy: 'Red Hat Enterprise Linux 9 Security Technical Implementation Guide' title: 'Red Hat Enterprise Linux 9 Security Technical Implementation Guide' id: stig_rhel9 source: https://www.cyber.mil/stigs/downloads/ -version: V2R4 +version: V2R8 reference_type: stigid product: rhel9 @@ -25,6 +25,8 @@ controls: - medium rules: - dconf_gnome_login_banner_text + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default - id: RHEL-09-211010 levels: - high @@ -36,7 +38,8 @@ controls: - id: RHEL-09-211015 levels: - medium - title: RHEL 9 vendor packaged system security patches and updates must be installed and up to date. + title: RHEL 9 vendor packaged system security patches and updates must be installed and up to + date. rules: - security_patches_up_to_date status: automated @@ -44,17 +47,20 @@ controls: - id: RHEL-09-211020 levels: - medium - title: RHEL 9 must display the Standard Mandatory DOD Notice and Consent Banner before granting + title: RHEL 9 must display the Standard Mandatory DOD Notice and Consent Banner before + granting local or remote access to the system via a command line user logon. rules: - banner_etc_issue - login_banner_text=dod_banners + - login_banner_contents=dod_default status: automated - id: RHEL-09-211030 levels: - medium - title: The graphical display manager must not be the default target on RHEL 9 unless approved. + title: The graphical display manager must not be the default target on RHEL 9 unless + approved. rules: - xwindows_runlevel_target status: automated @@ -64,7 +70,9 @@ controls: - low title: RHEL 9 must enable the hardware random number generator entropy gatherer service. related_rules: - - service_rngd_enabled # This rule is causing test failures, See https://github.com/ComplianceAsCode/content/pull/10153 + - service_rngd_enabled + # This rule is causing test failures, See + # https://github.com/ComplianceAsCode/content/pull/10153 status: pending - id: RHEL-09-211040 @@ -118,7 +126,8 @@ controls: - id: RHEL-09-212020 levels: - high - title: RHEL 9 must require a unique superusers name upon booting into single-user and maintenance + title: RHEL 9 must require a unique superusers name upon booting into single-user and + maintenance modes. rules: - grub2_admin_username @@ -215,7 +224,8 @@ controls: - id: RHEL-09-213030 levels: - medium - title: RHEL 9 must enable kernel parameters to enforce discretionary access control on hardlinks. + title: RHEL 9 must enable kernel parameters to enforce discretionary access control on + hardlinks. rules: - sysctl_fs_protected_hardlinks status: automated @@ -223,7 +233,8 @@ controls: - id: RHEL-09-213035 levels: - medium - title: RHEL 9 must enable kernel parameters to enforce discretionary access control on symlinks. + title: RHEL 9 must enable kernel parameters to enforce discretionary access control on + symlinks. rules: - sysctl_fs_protected_symlinks status: automated @@ -279,7 +290,8 @@ controls: - id: RHEL-09-213070 levels: - medium - title: RHEL 9 must implement address space layout randomization (ASLR) to protect its memory from + title: RHEL 9 must implement address space layout randomization (ASLR) to protect its memory + from unauthorized code execution. rules: - sysctl_kernel_randomize_va_space @@ -344,7 +356,8 @@ controls: - id: RHEL-09-213110 levels: - medium - title: RHEL 9 must implement nonexecutable data to protect its memory from unauthorized code execution. + title: RHEL 9 must implement nonexecutable data to protect its memory from unauthorized code + execution. rules: - sysctl_kernel_exec_shield status: automated @@ -368,7 +381,8 @@ controls: - id: RHEL-09-214015 levels: - high - title: RHEL 9 must check the GPG signature of software packages originating from external software + title: RHEL 9 must check the GPG signature of software packages originating from external + software repositories before installation. rules: - ensure_gpgcheck_globally_activated @@ -377,7 +391,8 @@ controls: - id: RHEL-09-214020 levels: - high - title: RHEL 9 must check the GPG signature of locally installed software packages before installation. + title: RHEL 9 must check the GPG signature of locally installed software packages before + installation. rules: - ensure_gpgcheck_local_packages status: automated @@ -393,7 +408,8 @@ controls: - id: RHEL-09-214030 levels: - medium - title: RHEL 9 must be configured so that the cryptographic hashes of system files match vendor + title: RHEL 9 must be configured so that the cryptographic hashes of system files match + vendor values. related_rules: - rpm_verify_hashes # Due to crypto policies this cannot be selected at this time @@ -450,7 +466,8 @@ controls: - id: RHEL-09-215035 levels: - medium - title: RHEL 9 must not install packages from the Extra Packages for Enterprise Linux (EPEL) repository. + title: RHEL 9 must not install packages from the Extra Packages for Enterprise Linux (EPEL) + repository. rules: - ensure_epel_repos_disabled status: automated @@ -575,12 +592,14 @@ controls: - configure_crypto_policy - fips_crypto_subpolicy - fips_custom_stig_sub_policy + - var_system_crypto_policy=fips_stig status: automated - id: RHEL-09-231010 levels: - medium - title: A separate RHEL 9 file system must be used for user home directories (such as /home or an + title: A separate RHEL 9 file system must be used for user home directories (such as /home or + an equivalent). rules: - partition_for_home @@ -637,7 +656,8 @@ controls: - id: RHEL-09-231045 levels: - medium - title: RHEL 9 must prevent device files from being interpreted on file systems that contain user + title: RHEL 9 must prevent device files from being interpreted on file systems that contain + user home directories. rules: - mount_option_home_nodev @@ -646,7 +666,8 @@ controls: - id: RHEL-09-231050 levels: - medium - title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on file + title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on + file systems that contain user home directories. rules: - mount_option_home_nosuid @@ -655,7 +676,8 @@ controls: - id: RHEL-09-231055 levels: - medium - title: RHEL 9 must prevent code from being executed on file systems that contain user home directories. + title: RHEL 9 must prevent code from being executed on file systems that contain user home + directories. rules: - mount_option_home_noexec status: automated @@ -663,7 +685,8 @@ controls: - id: RHEL-09-231065 levels: - medium - title: RHEL 9 must prevent special devices on file systems that are imported via Network File System + title: RHEL 9 must prevent special devices on file systems that are imported via Network File + System (NFS). rules: - mount_option_nodev_remote_filesystems @@ -672,8 +695,8 @@ controls: - id: RHEL-09-231070 levels: - medium - title: RHEL 9 must prevent code from being executed on file systems that are imported via Network - File System (NFS). + title: RHEL 9 must prevent code from being executed on file + systems that are imported via Network File System (NFS). rules: - mount_option_noexec_remote_filesystems status: automated @@ -681,7 +704,8 @@ controls: - id: RHEL-09-231075 levels: - medium - title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on file + title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on + file systems that are imported via Network File System (NFS). rules: - mount_option_nosuid_remote_filesystems @@ -690,7 +714,8 @@ controls: - id: RHEL-09-231080 levels: - medium - title: RHEL 9 must prevent code from being executed on file systems that are used with removable + title: RHEL 9 must prevent code from being executed on file systems that are used with + removable media. rules: - mount_option_noexec_removable_partitions @@ -699,7 +724,8 @@ controls: - id: RHEL-09-231085 levels: - medium - title: RHEL 9 must prevent special devices on file systems that are used with removable media. + title: RHEL 9 must prevent special devices on file systems that are used with removable + media. rules: - mount_option_nodev_removable_partitions status: automated @@ -707,7 +733,8 @@ controls: - id: RHEL-09-231090 levels: - medium - title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on file + title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on + file systems that are used with removable media. rules: - mount_option_nosuid_removable_partitions @@ -724,7 +751,8 @@ controls: - id: RHEL-09-231100 levels: - medium - title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on the + title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on + the /boot directory. rules: - mount_option_boot_nosuid @@ -733,7 +761,8 @@ controls: - id: RHEL-09-231105 levels: - medium - title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on the + title: RHEL 9 must prevent files with the setuid and setgid bit set from being executed on + the /boot/efi directory. rules: - mount_option_boot_efi_nosuid @@ -870,7 +899,8 @@ controls: - id: RHEL-09-231190 levels: - high - title: RHEL 9 local disk partitions must implement cryptographic mechanisms to prevent unauthorized + title: RHEL 9 local disk partitions must implement cryptographic mechanisms to prevent + unauthorized disclosure or modification of all information that requires at rest protection. rules: - encrypt_partitions @@ -966,7 +996,8 @@ controls: - id: RHEL-09-232050 levels: - medium - title: All RHEL 9 local interactive user home directories must have mode 0750 or less permissive. + title: All RHEL 9 local interactive user home directories must have mode 0750 or less + permissive. rules: - file_permissions_home_directories status: automated @@ -974,7 +1005,8 @@ controls: - id: RHEL-09-232055 levels: - medium - title: RHEL 9 /etc/group file must have mode 0644 or less permissive to prevent unauthorized access. + title: RHEL 9 /etc/group file must have mode 0644 or less permissive to prevent unauthorized + access. rules: - file_permissions_etc_group status: automated @@ -982,7 +1014,8 @@ controls: - id: RHEL-09-232060 levels: - medium - title: RHEL 9 /etc/group- file must have mode 0644 or less permissive to prevent unauthorized access. + title: RHEL 9 /etc/group- file must have mode 0644 or less permissive to prevent unauthorized + access. rules: - file_permissions_backup_etc_group status: automated @@ -990,7 +1023,8 @@ controls: - id: RHEL-09-232065 levels: - medium - title: RHEL 9 /etc/gshadow file must have mode 0000 or less permissive to prevent unauthorized + title: RHEL 9 /etc/gshadow file must have mode 0000 or less permissive to prevent + unauthorized access. rules: - file_permissions_etc_gshadow @@ -999,7 +1033,8 @@ controls: - id: RHEL-09-232070 levels: - medium - title: RHEL 9 /etc/gshadow- file must have mode 0000 or less permissive to prevent unauthorized + title: RHEL 9 /etc/gshadow- file must have mode 0000 or less permissive to prevent + unauthorized access. rules: - file_permissions_backup_etc_gshadow @@ -1008,7 +1043,8 @@ controls: - id: RHEL-09-232075 levels: - medium - title: RHEL 9 /etc/passwd file must have mode 0644 or less permissive to prevent unauthorized access. + title: RHEL 9 /etc/passwd file must have mode 0644 or less permissive to prevent unauthorized + access. rules: - file_permissions_etc_passwd status: automated @@ -1016,7 +1052,8 @@ controls: - id: RHEL-09-232080 levels: - medium - title: RHEL 9 /etc/passwd- file must have mode 0644 or less permissive to prevent unauthorized + title: RHEL 9 /etc/passwd- file must have mode 0644 or less permissive to prevent + unauthorized access. rules: - file_permissions_backup_etc_passwd @@ -1025,7 +1062,8 @@ controls: - id: RHEL-09-232085 levels: - medium - title: RHEL 9 /etc/shadow- file must have mode 0000 or less permissive to prevent unauthorized + title: RHEL 9 /etc/shadow- file must have mode 0000 or less permissive to prevent + unauthorized access. rules: - file_permissions_backup_etc_shadow @@ -1300,10 +1338,11 @@ controls: - id: RHEL-09-232240 levels: - medium - title: All RHEL 9 world-writable directories must be owned by root, sys, bin, or an application + title: All RHEL 9 world-writable directories must be owned by root, sys, bin, or an + application user. rules: - - dir_perms_world_writable_root_owned + - dir_perms_world_writable_system_owned status: automated - id: RHEL-09-232245 @@ -1333,7 +1372,8 @@ controls: - id: RHEL-09-232260 levels: - medium - title: RHEL 9 must be configured so that all system device files are correctly labeled to prevent + title: RHEL 9 must be configured so that all system device files are correctly labeled to + prevent unauthorized modification. rules: - selinux_all_devicefiles_labeled @@ -1366,7 +1406,8 @@ controls: - id: RHEL-09-251020 levels: - medium - title: A RHEL 9 firewall must employ a deny-all, allow-by-exception policy for allowing connections + title: A RHEL 9 firewall must employ a deny-all, allow-by-exception policy for allowing + connections to other systems. rules: - configured_firewalld_default_deny @@ -1375,7 +1416,8 @@ controls: - id: RHEL-09-251030 levels: - medium - title: RHEL 9 must protect against or limit the effects of denial-of-service (DoS) attacks by ensuring + title: RHEL 9 must protect against or limit the effects of denial-of-service (DoS) attacks by + ensuring rate-limiting measures on impacted network interfaces are implemented. rules: - firewalld-backend @@ -1384,8 +1426,10 @@ controls: - id: RHEL-09-251035 levels: - medium - title: RHEL 9 must be configured to prohibit or restrict the use of functions, ports, protocols, - and/or services, as defined in the Ports, Protocols, and Services Management (PPSM) Category + title: RHEL 9 must be configured to prohibit or restrict the use of functions, ports, + protocols, + and/or services, as defined in the Ports, Protocols, and Services Management (PPSM) + Category Assignments List (CAL) and vulnerability assessments. rules: - firewalld_sshd_port_enabled @@ -1426,7 +1470,8 @@ controls: - id: RHEL-09-252020 levels: - medium - title: RHEL 9 must securely compare internal information system clocks at least every 24 hours. + title: RHEL 9 must securely compare internal information system clocks at least every 24 + hours. rules: - chronyd_or_ntpd_set_maxpoll - chronyd_server_directive @@ -1449,12 +1494,14 @@ controls: title: RHEL 9 must disable network management of the chrony daemon. rules: - chronyd_no_chronyc_network + - chronyd_configure_local_socket status: automated - id: RHEL-09-252035 levels: - medium - title: RHEL 9 systems using Domain Name Servers (DNS) resolution must have at least two name servers + title: RHEL 9 systems using Domain Name Servers (DNS) resolution must have at least two name + servers configured. rules: - network_configure_name_resolution @@ -1528,7 +1575,8 @@ controls: - id: RHEL-09-253015 levels: - medium - title: RHEL 9 must ignore Internet Protocol version 4 (IPv4) Internet Control Message Protocol + title: RHEL 9 must ignore Internet Protocol version 4 (IPv4) Internet Control Message + Protocol (ICMP) redirect messages. rules: - sysctl_net_ipv4_conf_all_accept_redirects @@ -1569,7 +1617,8 @@ controls: - id: RHEL-09-253040 levels: - medium - title: RHEL 9 must prevent IPv4 Internet Control Message Protocol (ICMP) redirect messages from + title: RHEL 9 must prevent IPv4 Internet Control Message Protocol (ICMP) redirect messages + from being accepted. rules: - sysctl_net_ipv4_conf_default_accept_redirects @@ -1586,7 +1635,8 @@ controls: - id: RHEL-09-253050 levels: - medium - title: RHEL 9 must use a reverse-path filter for IPv4 network traffic when possible by default. + title: RHEL 9 must use a reverse-path filter for IPv4 network traffic when possible by + default. rules: - sysctl_net_ipv4_conf_default_rp_filter status: automated @@ -1594,7 +1644,8 @@ controls: - id: RHEL-09-253055 levels: - medium - title: RHEL 9 must not respond to Internet Control Message Protocol (ICMP) echoes sent to a broadcast + title: RHEL 9 must not respond to Internet Control Message Protocol (ICMP) echoes sent to a + broadcast address. rules: - sysctl_net_ipv4_icmp_echo_ignore_broadcasts @@ -1603,7 +1654,8 @@ controls: - id: RHEL-09-253060 levels: - medium - title: RHEL 9 must limit the number of bogus Internet Control Message Protocol (ICMP) response + title: RHEL 9 must limit the number of bogus Internet Control Message Protocol (ICMP) + response errors logs. rules: - sysctl_net_ipv4_icmp_ignore_bogus_error_responses @@ -1620,7 +1672,8 @@ controls: - id: RHEL-09-253070 levels: - medium - title: RHEL 9 must not allow interfaces to perform Internet Control Message Protocol (ICMP) redirects + title: RHEL 9 must not allow interfaces to perform Internet Control Message Protocol (ICMP) + redirects by default. rules: - sysctl_net_ipv4_conf_default_send_redirects @@ -1677,7 +1730,8 @@ controls: - id: RHEL-09-254035 levels: - medium - title: RHEL 9 must prevent IPv6 Internet Control Message Protocol (ICMP) redirect messages from + title: RHEL 9 must prevent IPv6 Internet Control Message Protocol (ICMP) redirect messages + from being accepted. rules: - sysctl_net_ipv6_conf_default_accept_redirects @@ -1702,8 +1756,10 @@ controls: - id: RHEL-09-255015 levels: - medium - title: All RHEL 9 networked systems must have and implement SSH to protect the confidentiality - and integrity of transmitted and received information, as well as information during preparation + title: All RHEL 9 networked systems must have and implement SSH to protect the + confidentiality + and integrity of transmitted and received information, as well as information during + preparation for transmission. rules: - service_sshd_enabled @@ -1720,7 +1776,8 @@ controls: - id: RHEL-09-255025 levels: - medium - title: RHEL 9 must display the Standard Mandatory DOD Notice and Consent Banner before granting + title: RHEL 9 must display the Standard Mandatory DOD Notice and Consent Banner before + granting local or remote access to the system via a SSH logon. rules: - sshd_enable_warning_banner @@ -1766,26 +1823,11 @@ controls: - sshd_enable_pam status: automated - - id: RHEL-09-255055 - levels: - - medium - title: RHEL 9 SSH daemon must be configured to use system-wide crypto policies. - rules: - - file_sshd_50_redhat_exists - - sshd_include_crypto_policy - status: automated - - - id: RHEL-09-255060 - levels: - - medium - title: RHEL 9 must implement DOD-approved encryption ciphers to protect the confidentiality of - SSH client connections. - rules: - - sshd_include_crypto_policy - status: automated - id: RHEL-09-255064 - title: The RHEL 9 SSH client must be configured to use only DOD-approved encryption ciphers employing - FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH client + title: The RHEL 9 SSH client must be configured to use only DOD-approved encryption ciphers + employing + FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH + client connections. levels: - medium @@ -1795,17 +1837,22 @@ controls: - id: RHEL-09-255065 levels: - medium - title: RHEL 9 must implement DOD-approved encryption ciphers to protect the confidentiality of - SSH server connections. + title: The RHEL 9 SSH server must be configured to use only DOD-approved encryption ciphers + employing + FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH + server connections. rules: + - sshd_include_crypto_policy - harden_sshd_ciphers_opensshserver_conf_crypto_policy - sshd_approved_ciphers=stig_rhel9 status: automated - id: RHEL-09-255070 levels: - medium - title: The RHEL 9 SSH client must be configured to use only DOD-approved Message Authentication - Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality + title: The RHEL 9 SSH client must be configured to use only DOD-approved Message + Authentication + Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms to protect the + confidentiality of SSH client connections. rules: - harden_sshd_macs_openssh_conf_crypto_policy @@ -1814,7 +1861,8 @@ controls: - id: RHEL-09-255075 levels: - medium - title: RHEL 9 SSH server must be configured to use only Message Authentication Codes (MACs) employing + title: RHEL 9 SSH server must be configured to use only Message Authentication Codes (MACs) + employing FIPS 140-3 validated cryptographic hash algorithms. status: automated rules: @@ -1840,7 +1888,8 @@ controls: - id: RHEL-09-255090 levels: - medium - title: RHEL 9 must force a frequent session key renegotiation for SSH connections to the server. + title: RHEL 9 must force a frequent session key renegotiation for SSH connections to the + server. rules: - sshd_rekey_limit - var_rekey_limit_size=1G @@ -1850,7 +1899,8 @@ controls: - id: RHEL-09-255095 levels: - medium - title: RHEL 9 must be configured so that all network connections associated with SSH traffic terminate + title: RHEL 9 must be configured so that all network connections associated with SSH traffic + terminate after becoming unresponsive. rules: - sshd_set_keepalive @@ -1860,7 +1910,8 @@ controls: - id: RHEL-09-255100 levels: - medium - title: RHEL 9 must be configured so that all network connections associated with SSH traffic are + title: RHEL 9 must be configured so that all network connections associated with SSH traffic + are terminated after 10 minutes of becoming unresponsive. rules: - sshd_set_idle_timeout @@ -1872,6 +1923,7 @@ controls: - medium title: RHEL 9 SSH server configuration file must be group-owned by root. rules: + - file_sshd_50_redhat_exists - file_groupowner_sshd_config - directory_groupowner_sshd_config_d - file_groupowner_sshd_drop_in_config @@ -1882,6 +1934,7 @@ controls: - medium title: RHEL 9 SSH server configuration file must be owned by root. rules: + - file_sshd_50_redhat_exists - file_owner_sshd_config - directory_owner_sshd_config_d - file_owner_sshd_drop_in_config @@ -1916,7 +1969,8 @@ controls: - id: RHEL-09-255130 levels: - medium - title: RHEL 9 SSH daemon must not allow compression or must only allow compression after successful + title: RHEL 9 SSH daemon must not allow compression or must only allow compression after + successful authentication. rules: - sshd_disable_compression @@ -1966,7 +2020,8 @@ controls: - id: RHEL-09-255160 levels: - medium - title: RHEL 9 SSH daemon must perform strict mode checking of home directory configuration files. + title: RHEL 9 SSH daemon must perform strict mode checking of home directory configuration + files. rules: - sshd_enable_strictmodes status: automated @@ -1974,7 +2029,8 @@ controls: - id: RHEL-09-255165 levels: - medium - title: RHEL 9 SSH daemon must display the date and time of the last successful account logon upon + title: RHEL 9 SSH daemon must display the date and time of the last successful account logon + upon an SSH logon. rules: - sshd_print_last_log @@ -1991,7 +2047,8 @@ controls: - id: RHEL-09-271010 levels: - medium - title: RHEL 9 must display the Standard Mandatory DOD Notice and Consent Banner before granting + title: RHEL 9 must display the Standard Mandatory DOD Notice and Consent Banner before + granting local or remote access to the system via a graphical user logon. rules: - dconf_gnome_banner_enabled @@ -2000,7 +2057,8 @@ controls: - id: RHEL-09-271015 levels: - medium - title: RHEL 9 must prevent a user from overriding the banner-message-enable setting for the graphical + title: RHEL 9 must prevent a user from overriding the banner-message-enable setting for the + graphical user interface. rules: - dconf_gnome_banner_enabled @@ -2017,7 +2075,8 @@ controls: - id: RHEL-09-271025 levels: - medium - title: RHEL 9 must prevent a user from overriding the disabling of the graphical user interface + title: RHEL 9 must prevent a user from overriding the disabling of the graphical user + interface automount function. rules: - dconf_gnome_disable_automount_open @@ -2034,7 +2093,8 @@ controls: - id: RHEL-09-271035 levels: - medium - title: RHEL 9 must prevent a user from overriding the disabling of the graphical user interface + title: RHEL 9 must prevent a user from overriding the disabling of the graphical user + interface autorun function. rules: - dconf_gnome_disable_autorun @@ -2051,7 +2111,8 @@ controls: - id: RHEL-09-271045 levels: - medium - title: RHEL 9 must be able to initiate directly a session lock for all connection types using smart + title: RHEL 9 must be able to initiate directly a session lock for all connection types using + smart card when the smart card is removed. rules: - dconf_gnome_lock_screen_on_smartcard_removal @@ -2060,7 +2121,8 @@ controls: - id: RHEL-09-271050 levels: - medium - title: RHEL 9 must prevent a user from overriding the disabling of the graphical user smart card + title: RHEL 9 must prevent a user from overriding the disabling of the graphical user smart + card removal action. rules: - dconf_gnome_lock_screen_on_smartcard_removal @@ -2069,7 +2131,8 @@ controls: - id: RHEL-09-271055 levels: - medium - title: RHEL 9 must enable a user session lock until that user re-establishes access using established + title: RHEL 9 must enable a user session lock until that user re-establishes access using + established identification and authentication procedures for graphical user sessions. rules: - dconf_gnome_screensaver_lock_enabled @@ -2078,7 +2141,8 @@ controls: - id: RHEL-09-271060 levels: - medium - title: RHEL 9 must prevent a user from overriding the screensaver lock-enabled setting for the + title: RHEL 9 must prevent a user from overriding the screensaver lock-enabled setting for + the graphical user interface. rules: - dconf_gnome_screensaver_lock_enabled @@ -2087,15 +2151,17 @@ controls: - id: RHEL-09-271065 levels: - medium - title: RHEL 9 must automatically lock graphical user sessions after 15 minutes of inactivity. + title: RHEL 9 must automatically lock graphical user sessions after 10 minutes of inactivity. rules: - dconf_gnome_screensaver_idle_delay + - inactivity_timeout_value=10_minutes status: automated - id: RHEL-09-271070 levels: - medium - title: RHEL 9 must prevent a user from overriding the session idle-delay setting for the graphical + title: RHEL 9 must prevent a user from overriding the session idle-delay setting for the + graphical user interface. rules: - dconf_gnome_session_idle_user_locks @@ -2104,7 +2170,8 @@ controls: - id: RHEL-09-271075 levels: - medium - title: RHEL 9 must initiate a session lock for graphical user interfaces when the screensaver is + title: RHEL 9 must initiate a session lock for graphical user interfaces when the screensaver + is activated. rules: - dconf_gnome_screensaver_lock_delay @@ -2113,7 +2180,8 @@ controls: - id: RHEL-09-271080 levels: - medium - title: RHEL 9 must prevent a user from overriding the session lock-delay setting for the graphical + title: RHEL 9 must prevent a user from overriding the session lock-delay setting for the + graphical user interface. rules: - dconf_gnome_screensaver_user_locks @@ -2122,7 +2190,8 @@ controls: - id: RHEL-09-271085 levels: - medium - title: RHEL 9 must conceal, via the session lock, information previously visible on the display + title: RHEL 9 must conceal, via the session lock, information previously visible on the + display with a publicly viewable image. rules: - dconf_gnome_screensaver_mode_blank @@ -2147,7 +2216,8 @@ controls: - id: RHEL-09-271100 levels: - medium - title: RHEL 9 must prevent a user from overriding the disable-restart-buttons setting for the graphical + title: RHEL 9 must prevent a user from overriding the disable-restart-buttons setting for the + graphical user interface. rules: - dconf_gnome_disable_restart_shutdown @@ -2156,7 +2226,8 @@ controls: - id: RHEL-09-271105 levels: - medium - title: RHEL 9 must disable the ability of a user to accidentally press Ctrl-Alt-Del and cause a + title: RHEL 9 must disable the ability of a user to accidentally press Ctrl-Alt-Del and cause + a system to shut down or reboot. rules: - dconf_gnome_disable_ctrlaltdel_reboot @@ -2165,7 +2236,8 @@ controls: - id: RHEL-09-271110 levels: - medium - title: RHEL 9 must prevent a user from overriding the Ctrl-Alt-Del sequence settings for the graphical + title: RHEL 9 must prevent a user from overriding the Ctrl-Alt-Del sequence settings for the + graphical user interface. rules: - dconf_gnome_disable_ctrlaltdel_reboot @@ -2238,7 +2310,8 @@ controls: - id: RHEL-09-411010 levels: - medium - title: RHEL 9 user account passwords for new users or password changes must have a 60-day maximum + title: RHEL 9 user account passwords for new users or password changes must have a 60-day + maximum password lifetime restriction in /etc/login.defs. rules: - accounts_maximum_age_login_defs @@ -2247,7 +2320,8 @@ controls: - id: RHEL-09-411015 levels: - medium - title: RHEL 9 user account passwords must have a 60-day maximum password lifetime restriction. + title: RHEL 9 user account passwords must have a 60-day maximum password lifetime + restriction. rules: - accounts_password_set_max_life_existing - var_accounts_maximum_age_login_defs=60 @@ -2256,7 +2330,8 @@ controls: - id: RHEL-09-411020 levels: - medium - title: All RHEL 9 local interactive user accounts must be assigned a home directory upon creation. + title: All RHEL 9 local interactive user accounts must be assigned a home directory upon + creation. rules: - accounts_have_homedir_login_defs status: automated @@ -2305,7 +2380,8 @@ controls: - id: RHEL-09-411050 levels: - medium - title: RHEL 9 must disable account identifiers (individuals, groups, roles, and devices) after + title: RHEL 9 must disable account identifiers (individuals, groups, roles, and devices) + after 35 days of inactivity. rules: - account_disable_post_pw_expiration @@ -2315,8 +2391,10 @@ controls: - id: RHEL-09-411055 levels: - medium - title: Executable search paths within the initialization files of all local interactive RHEL 9 - users must only contain paths that resolve to the system default or the users home directory. + title: Executable search paths within the initialization files of all local interactive RHEL + 9 + users must only contain paths that resolve to the system default or the users home + directory. rules: - accounts_user_home_paths_only status: automated @@ -2324,7 +2402,8 @@ controls: - id: RHEL-09-411060 levels: - medium - title: All RHEL 9 local interactive users must have a home directory assigned in the /etc/passwd + title: All RHEL 9 local interactive users must have a home directory assigned in the + /etc/passwd file. rules: - accounts_user_interactive_home_directory_defined @@ -2333,7 +2412,8 @@ controls: - id: RHEL-09-411065 levels: - medium - title: All RHEL 9 local interactive user home directories defined in the /etc/passwd file must + title: All RHEL 9 local interactive user home directories defined in the /etc/passwd file + must exist. rules: - accounts_user_interactive_home_directory_exists @@ -2342,7 +2422,8 @@ controls: - id: RHEL-09-411070 levels: - medium - title: All RHEL 9 local interactive user home directories must be group-owned by the home directory + title: All RHEL 9 local interactive user home directories must be group-owned by the home + directory owner's primary group. rules: - file_groupownership_home_directories @@ -2351,7 +2432,8 @@ controls: - id: RHEL-09-411075 levels: - medium - title: RHEL 9 must automatically lock an account when three unsuccessful logon attempts occur. + title: RHEL 9 must automatically lock an account when three unsuccessful logon attempts + occur. rules: - accounts_passwords_pam_faillock_deny - var_accounts_passwords_pam_faillock_deny=3 @@ -2360,8 +2442,10 @@ controls: - id: RHEL-09-411080 levels: - medium - title: RHEL 9 must automatically lock the root account until the root account is released by an - administrator when three unsuccessful logon attempts occur during a 15-minute time period. + title: RHEL 9 must automatically lock the root account until the root account is released by + an + administrator when three unsuccessful logon attempts occur during a 15-minute time + period. rules: - accounts_passwords_pam_faillock_deny_root status: automated @@ -2369,7 +2453,8 @@ controls: - id: RHEL-09-411085 levels: - medium - title: RHEL 9 must automatically lock an account when three unsuccessful logon attempts occur during + title: RHEL 9 must automatically lock an account when three unsuccessful logon attempts occur + during a 15-minute time period. rules: - accounts_passwords_pam_faillock_interval @@ -2379,7 +2464,8 @@ controls: - id: RHEL-09-411090 levels: - medium - title: RHEL 9 must maintain an account lock until the locked account is released by an administrator. + title: RHEL 9 must maintain an account lock until the locked account is released by an + administrator. rules: - accounts_passwords_pam_faillock_unlock_time - var_accounts_passwords_pam_faillock_unlock_time=never @@ -2418,18 +2504,11 @@ controls: - group_unique_id status: automated - - id: RHEL-09-411115 - levels: - - medium - title: Local RHEL 9 initialization files must not execute world-writable programs. - rules: - - accounts_user_dot_no_world_writable_programs - status: automated - - id: RHEL-09-412035 levels: - medium - title: RHEL 9 must automatically exit interactive command shell user sessions after 15 minutes + title: RHEL 9 must automatically exit interactive command shell user sessions after 15 + minutes of inactivity. rules: - accounts_tmout @@ -2439,7 +2518,8 @@ controls: - id: RHEL-09-412040 levels: - low - title: RHEL 9 must limit the number of concurrent sessions to ten for all accounts and/or account + title: RHEL 9 must limit the number of concurrent sessions to ten for all accounts and/or + account types. rules: - accounts_max_concurrent_login_sessions @@ -2457,7 +2537,8 @@ controls: - id: RHEL-09-412050 levels: - medium - title: RHEL 9 must enforce a delay of at least four seconds between logon prompts following a failed + title: RHEL 9 must enforce a delay of at least four seconds between logon prompts following a + failed logon attempt. rules: - accounts_logon_fail_delay @@ -2483,7 +2564,8 @@ controls: - id: RHEL-09-412065 levels: - medium - title: RHEL 9 must define default permissions for all authenticated users in such a way that the + title: RHEL 9 must define default permissions for all authenticated users in such a way that + the user can only read and modify their own files. rules: - accounts_umask_etc_login_defs @@ -2497,27 +2579,20 @@ controls: - accounts_umask_etc_profile status: automated - - id: RHEL-09-412075 - levels: - - low - title: RHEL 9 must display the date and time of the last successful account logon upon logon. - rules: - - display_login_attempts - status: automated - - id: RHEL-09-412080 levels: - medium title: RHEL 9 must terminate idle user sessions. rules: - logind_session_timeout - - var_logind_session_timeout=15_minutes + - var_logind_session_timeout=10_minutes status: automated - id: RHEL-09-431010 levels: - high - title: RHEL 9 must use a Linux Security Module configured to enforce limits on system services. + title: RHEL 9 must use a Linux Security Module configured to enforce limits on system + services. rules: - selinux_state - var_selinux_state=enforcing @@ -2533,7 +2608,8 @@ controls: status: automated - id: RHEL-09-431016 - title: 'RHEL 9 must elevate the SELinux context when an administrator calls the sudo command.' + title: 'RHEL 9 must elevate the SELinux context when an administrator calls the sudo + command.' rules: - selinux_context_elevation_for_sudo status: automated @@ -2541,7 +2617,8 @@ controls: - id: RHEL-09-431020 levels: - medium - title: RHEL 9 must configure SELinux context type to allow the use of a nondefault faillock tally + title: RHEL 9 must configure SELinux context type to allow the use of a nondefault faillock + tally directory. rules: - account_password_selinux_faillock_dir @@ -2583,7 +2660,8 @@ controls: - id: RHEL-09-432020 levels: - medium - title: RHEL 9 must use the invoking user's password for privilege escalation when using "sudo". + title: RHEL 9 must use the invoking user's password for privilege escalation when using + "sudo". rules: - sudoers_validate_passwd status: automated @@ -2631,7 +2709,8 @@ controls: - id: RHEL-09-433016 levels: - medium - title: The RHEL 9 fapolicy module must be configured to employ a deny-all, permit-by-exception + title: The RHEL 9 fapolicy module must be configured to employ a deny-all, + permit-by-exception policy to allow the execution of authorized software programs. rules: - fapolicy_default_deny @@ -2640,7 +2719,8 @@ controls: - id: RHEL-09-611010 levels: - medium - title: RHEL 9 must ensure the password complexity module in the system-auth file is configured + title: RHEL 9 must ensure the password complexity module in the system-auth file is + configured for three retries or less. rules: - accounts_password_pam_pwquality_retry @@ -2658,7 +2738,8 @@ controls: - id: RHEL-09-611030 levels: - medium - title: RHEL 9 must configure the use of the pam_faillock.so module in the /etc/pam.d/system-auth + title: RHEL 9 must configure the use of the pam_faillock.so module in the + /etc/pam.d/system-auth file. rules: - account_password_pam_faillock_system_auth @@ -2667,7 +2748,8 @@ controls: - id: RHEL-09-611035 levels: - medium - title: RHEL 9 must configure the use of the pam_faillock.so module in the /etc/pam.d/password-auth + title: RHEL 9 must configure the use of the pam_faillock.so module in the + /etc/pam.d/password-auth file. rules: - account_password_pam_faillock_password_auth @@ -2676,7 +2758,8 @@ controls: - id: RHEL-09-611040 levels: - medium - title: RHEL 9 must ensure the password complexity module is enabled in the password-auth file. + title: RHEL 9 must ensure the password complexity module is enabled in the password-auth + file. rules: - accounts_password_pam_pwquality_password_auth status: automated @@ -2717,7 +2800,8 @@ controls: - id: RHEL-09-611065 levels: - medium - title: RHEL 9 must enforce password complexity by requiring that at least one lowercase character + title: RHEL 9 must enforce password complexity by requiring that at least one lowercase + character be used. rules: - accounts_password_pam_lcredit @@ -2727,7 +2811,8 @@ controls: - id: RHEL-09-611070 levels: - medium - title: RHEL 9 must enforce password complexity by requiring that at least one numeric character + title: RHEL 9 must enforce password complexity by requiring that at least one numeric + character be used. rules: - accounts_password_pam_dcredit @@ -2737,7 +2822,8 @@ controls: - id: RHEL-09-611075 levels: - medium - title: RHEL 9 passwords for new users or password changes must have a 24 hours minimum password + title: RHEL 9 passwords for new users or password changes must have a 24 hours minimum + password lifetime restriction in /etc/login.defs. rules: - accounts_minimum_age_login_defs @@ -2746,7 +2832,8 @@ controls: - id: RHEL-09-611080 levels: - medium - title: RHEL 9 passwords must have a 24 hours minimum password lifetime restriction in /etc/shadow. + title: RHEL 9 passwords must have a 24 hours minimum password lifetime restriction in + /etc/shadow. rules: - accounts_password_set_min_life_existing - var_accounts_minimum_age_login_defs=1 @@ -2772,7 +2859,8 @@ controls: - id: RHEL-09-611100 levels: - medium - title: RHEL 9 must enforce password complexity by requiring that at least one special character + title: RHEL 9 must enforce password complexity by requiring that at least one special + character be used. rules: - accounts_password_pam_ocredit @@ -2791,7 +2879,8 @@ controls: - id: RHEL-09-611110 levels: - medium - title: RHEL 9 must enforce password complexity by requiring that at least one uppercase character + title: RHEL 9 must enforce password complexity by requiring that at least one uppercase + character be used. rules: - accounts_password_pam_ucredit @@ -2801,7 +2890,8 @@ controls: - id: RHEL-09-611115 levels: - medium - title: RHEL 9 must require the change of at least eight characters when passwords are changed. + title: RHEL 9 must require the change of at least eight characters when passwords are + changed. rules: - accounts_password_pam_difok - var_password_pam_difok=8 @@ -2810,7 +2900,8 @@ controls: - id: RHEL-09-611120 levels: - medium - title: RHEL 9 must require the maximum number of repeating characters of the same character class + title: RHEL 9 must require the maximum number of repeating characters of the same character + class be limited to four when passwords are changed. rules: - accounts_password_pam_maxclassrepeat @@ -2820,7 +2911,8 @@ controls: - id: RHEL-09-611125 levels: - medium - title: RHEL 9 must require the maximum number of repeating characters be limited to three when + title: RHEL 9 must require the maximum number of repeating characters be limited to three + when passwords are changed. rules: - accounts_password_pam_maxrepeat @@ -2830,7 +2922,8 @@ controls: - id: RHEL-09-611130 levels: - medium - title: RHEL 9 must require the change of at least four character classes when passwords are changed. + title: RHEL 9 must require the change of at least four character classes when passwords are + changed. rules: - accounts_password_pam_minclass - var_password_pam_minclass=4 @@ -2839,7 +2932,8 @@ controls: - id: RHEL-09-611135 levels: - medium - title: RHEL 9 must be configured so that user and group account administration utilities are configured + title: RHEL 9 must be configured so that user and group account administration utilities are + configured to store only encrypted representations of passwords. rules: - set_password_hashing_algorithm_libuserconf @@ -2849,7 +2943,8 @@ controls: - id: RHEL-09-611140 levels: - medium - title: RHEL 9 must be configured to use the shadow file to store only encrypted representations + title: RHEL 9 must be configured to use the shadow file to store only encrypted + representations of passwords. rules: - set_password_hashing_algorithm_logindefs @@ -2859,7 +2954,8 @@ controls: - id: RHEL-09-611145 levels: - medium - title: RHEL 9 must not be configured to bypass password requirements for privilege escalation. + title: RHEL 9 must not be configured to bypass password requirements for privilege + escalation. rules: - disallow_bypass_password_sudo status: automated @@ -2925,7 +3021,8 @@ controls: - id: RHEL-09-611190 levels: - medium - title: RHEL 9, for PKI-based authentication, must enforce authorized access to the corresponding + title: RHEL 9, for PKI-based authentication, must enforce authorized access to the + corresponding private key. rules: - ssh_keys_passphrase_protected @@ -2950,7 +3047,8 @@ controls: - id: RHEL-09-631010 levels: - medium - title: RHEL 9, for PKI-based authentication, must validate certificates by constructing a certification + title: RHEL 9, for PKI-based authentication, must validate certificates by constructing a + certification path (which includes status information) to an accepted trust anchor. rules: - sssd_has_trust_anchor @@ -2959,7 +3057,8 @@ controls: - id: RHEL-09-631015 levels: - medium - title: RHEL 9 must map the authenticated identity to the user or group account for PKI-based authentication. + title: RHEL 9 must map the authenticated identity to the user or group account for PKI-based + authentication. rules: - sssd_enable_certmap status: automated @@ -2984,8 +3083,10 @@ controls: - id: RHEL-09-651015 levels: - medium - title: RHEL 9 must routinely check the baseline configuration for unauthorized changes and notify - the system administrator when anomalies in the operation of any security functions are discovered. + title: RHEL 9 must routinely check the baseline configuration for unauthorized changes and + notify + the system administrator when anomalies in the operation of any security functions are + discovered. rules: - aide_scan_notification status: automated @@ -2993,7 +3094,8 @@ controls: - id: RHEL-09-651020 levels: - medium - title: RHEL 9 must use a file integrity tool that is configured to use FIPS 140-3-approved cryptographic + title: RHEL 9 must use a file integrity tool that is configured to use FIPS 140-3-approved + cryptographic hashes for validating file contents and directories. rules: - aide_use_fips_hashes @@ -3010,7 +3112,8 @@ controls: - id: RHEL-09-651030 levels: - low - title: RHEL 9 must be configured so that the file integrity tool verifies Access Control Lists + title: RHEL 9 must be configured so that the file integrity tool verifies Access Control + Lists (ACLs). rules: - aide_verify_acls @@ -3019,7 +3122,8 @@ controls: - id: RHEL-09-651035 levels: - low - title: RHEL 9 must be configured so that the file integrity tool verifies extended attributes. + title: RHEL 9 must be configured so that the file integrity tool verifies extended + attributes. rules: - aide_verify_ext_attributes status: automated @@ -3051,7 +3155,8 @@ controls: - id: RHEL-09-652025 levels: - medium - title: RHEL 9 must be configured so that the rsyslog daemon does not accept log messages from other + title: RHEL 9 must be configured so that the rsyslog daemon does not accept log messages from + other servers unless the server is being used for log aggregation. rules: - rsyslog_nolisten @@ -3068,7 +3173,8 @@ controls: - id: RHEL-09-652040 levels: - medium - title: RHEL 9 must authenticate the remote logging server for offloading audit logs via rsyslog. + title: RHEL 9 must authenticate the remote logging server for offloading audit logs via + rsyslog. rules: - rsyslog_encrypt_offload_actionsendstreamdriverauthmode status: automated @@ -3076,7 +3182,8 @@ controls: - id: RHEL-09-652045 levels: - medium - title: RHEL 9 must encrypt the transfer of audit records offloaded onto a different system or media + title: RHEL 9 must encrypt the transfer of audit records offloaded onto a different system or + media from the system being audited via rsyslog. rules: - rsyslog_encrypt_offload_actionsendstreamdrivermode @@ -3085,7 +3192,8 @@ controls: - id: RHEL-09-652050 levels: - medium - title: RHEL 9 must encrypt via the gtls driver the transfer of audit records offloaded onto a different + title: RHEL 9 must encrypt via the gtls driver the transfer of audit records offloaded onto a + different system or media from the system being audited via rsyslog. rules: - rsyslog_encrypt_offload_defaultnetstreamdriver @@ -3094,7 +3202,8 @@ controls: - id: RHEL-09-652055 levels: - medium - title: RHEL 9 must be configured to forward audit records via TCP to a different system or media + title: RHEL 9 must be configured to forward audit records via TCP to a different system or + media from the system being audited via rsyslog. rules: - rsyslog_remote_loghost @@ -3127,7 +3236,8 @@ controls: - id: RHEL-09-653020 levels: - medium - title: RHEL 9 audit system must take appropriate action when an error writing to the audit storage + title: RHEL 9 audit system must take appropriate action when an error writing to the audit + storage volume occurs. rules: - auditd_data_disk_error_action_stig @@ -3137,7 +3247,8 @@ controls: - id: RHEL-09-653025 levels: - medium - title: RHEL 9 audit system must take appropriate action when the audit storage volume is full. + title: RHEL 9 audit system must take appropriate action when the audit storage volume is + full. rules: - auditd_data_disk_full_action_stig - var_auditd_disk_full_action=halt @@ -3146,7 +3257,8 @@ controls: - id: RHEL-09-653030 levels: - medium - title: RHEL 9 must allocate audit record storage capacity to store at least one week's worth of + title: RHEL 9 must allocate audit record storage capacity to store at least one week's worth + of audit records. rules: - auditd_audispd_configure_sufficiently_large_partition @@ -3155,7 +3267,8 @@ controls: - id: RHEL-09-653035 levels: - medium - title: RHEL 9 must take action when allocated audit record storage volume reaches 75 percent of + title: RHEL 9 must take action when allocated audit record storage volume reaches 75 percent + of the repository maximum audit record storage capacity. rules: - auditd_data_retention_space_left_percentage @@ -3165,7 +3278,8 @@ controls: - id: RHEL-09-653040 levels: - medium - title: RHEL 9 must notify the system administrator (SA) and information system security officer + title: RHEL 9 must notify the system administrator (SA) and information system security + officer (ISSO) (at a minimum) when allocated audit record storage volume 75 percent utilization. rules: - auditd_data_retention_space_left_action @@ -3175,7 +3289,8 @@ controls: - id: RHEL-09-653045 levels: - medium - title: RHEL 9 must take action when allocated audit record storage volume reaches 95 percent of + title: RHEL 9 must take action when allocated audit record storage volume reaches 95 percent + of the audit record storage capacity. rules: - auditd_data_retention_admin_space_left_percentage @@ -3185,7 +3300,8 @@ controls: - id: RHEL-09-653050 levels: - medium - title: RHEL 9 must take action when allocated audit record storage volume reaches 95 percent of + title: RHEL 9 must take action when allocated audit record storage volume reaches 95 percent + of the repository maximum audit record storage capacity. rules: - auditd_data_retention_admin_space_left_action @@ -3195,7 +3311,8 @@ controls: - id: RHEL-09-653055 levels: - medium - title: RHEL 9 audit system must take appropriate action when the audit files have reached maximum + title: RHEL 9 audit system must take appropriate action when the audit files have reached + maximum size. rules: - auditd_data_retention_max_log_file_action_stig @@ -3205,7 +3322,8 @@ controls: - id: RHEL-09-653060 levels: - medium - title: RHEL 9 must label all offloaded audit logs before sending them to the central log server. + title: RHEL 9 must label all offloaded audit logs before sending them to the central log + server. rules: - auditd_name_format - var_auditd_name_format=stig @@ -3222,7 +3340,8 @@ controls: - id: RHEL-09-653070 levels: - medium - title: RHEL 9 System Administrator (SA) and/or information system security officer (ISSO) (at a + title: RHEL 9 System Administrator (SA) and/or information system security officer (ISSO) (at + a minimum) must be alerted of an audit processing failure event. rules: - auditd_data_retention_action_mail_acct @@ -3240,7 +3359,8 @@ controls: - id: RHEL-09-653080 levels: - medium - title: RHEL 9 audit logs must be group-owned by root or by a restricted logging group to prevent + title: RHEL 9 audit logs must be group-owned by root or by a restricted logging group to + prevent unauthorized read access. rules: - directory_group_ownership_var_log_audit @@ -3257,7 +3377,8 @@ controls: - id: RHEL-09-653090 levels: - medium - title: RHEL 9 audit logs file must have mode 0600 or less permissive to prevent unauthorized access + title: RHEL 9 audit logs file must have mode 0600 or less permissive to prevent unauthorized + access to the audit log. rules: - file_permissions_var_log_audit @@ -3266,7 +3387,8 @@ controls: - id: RHEL-09-653095 levels: - medium - title: RHEL 9 must periodically flush audit records to disk to prevent the loss of audit records. + title: RHEL 9 must periodically flush audit records to disk to prevent the loss of audit + records. rules: - auditd_freq - var_auditd_freq=100 @@ -3275,7 +3397,8 @@ controls: - id: RHEL-09-653100 levels: - medium - title: RHEL 9 must produce audit records containing information to establish the identity of any + title: RHEL 9 must produce audit records containing information to establish the identity of + any individual or process associated with the event. rules: - auditd_log_format @@ -3292,25 +3415,19 @@ controls: - id: RHEL-09-653110 levels: - medium - title: RHEL 9 must allow only the information system security manager (ISSM) (or individuals or + title: RHEL 9 must allow only the information system security manager (ISSM) (or individuals + or roles appointed by the ISSM) to select which auditable events are to be audited. rules: - file_permissions_audit_configuration - status: automated - - - id: RHEL-09-653115 - levels: - - medium - title: RHEL 9 /etc/audit/auditd.conf file must have 0640 or less permissive to prevent unauthorized - access. - rules: - file_permissions_etc_audit_auditd status: automated - id: RHEL-09-653120 levels: - low - title: RHEL 9 must allocate an audit_backlog_limit of sufficient size to capture processes that + title: RHEL 9 must allocate an audit_backlog_limit of sufficient size to capture processes + that start prior to the audit daemon. rules: - grub2_audit_backlog_limit_argument @@ -3320,7 +3437,8 @@ controls: - id: RHEL-09-653125 levels: - medium - title: RHEL 9 must have mail aliases to notify the information system security officer (ISSO) and + title: RHEL 9 must have mail aliases to notify the information system security officer (ISSO) + and system administrator (SA) (at a minimum) in the event of an audit processing failure. rules: - postfix_client_configure_mail_alias @@ -3366,7 +3484,8 @@ controls: - id: RHEL-09-654025 levels: - medium - title: RHEL 9 must audit all uses of the setxattr, fsetxattr, lsetxattr, removexattr, fremovexattr, + title: RHEL 9 must audit all uses of the setxattr, fsetxattr, lsetxattr, removexattr, + fremovexattr, and lremovexattr system calls. rules: - audit_rules_dac_modification_setxattr @@ -3436,7 +3555,8 @@ controls: - id: RHEL-09-654065 levels: - medium - title: RHEL 9 must audit all uses of the rename, unlink, rmdir, renameat, and unlinkat system calls. + title: RHEL 9 must audit all uses of the rename, unlink, rmdir, renameat, and unlinkat system + calls. rules: - audit_rules_file_deletion_events_rename - audit_rules_file_deletion_events_unlink @@ -3448,7 +3568,8 @@ controls: - id: RHEL-09-654070 levels: - medium - title: RHEL 9 must audit all uses of the truncate, ftruncate, creat, open, openat, and open_by_handle_at + title: RHEL 9 must audit all uses of the truncate, ftruncate, creat, open, openat, and + open_by_handle_at system calls. rules: - audit_rules_unsuccessful_file_modification_creat @@ -3500,6 +3621,17 @@ controls: - audit_rules_privileged_commands_crontab status: automated + - id: RHEL-09-654097 + levels: + - medium + title: RHEL 9 must audit any script or executable called by cron as root or by any privileged + user. + rules: + - audit_rules_etc_cron_d + - audit_rules_var_spool_cron + status: automated + + - id: RHEL-09-654100 levels: - medium @@ -3639,7 +3771,8 @@ controls: - id: RHEL-09-654185 levels: - medium - title: Successful/unsuccessful uses of the init command in RHEL 9 must generate an audit record. + title: Successful/unsuccessful uses of the init command in RHEL 9 must generate an audit + record. rules: - audit_privileged_commands_init status: automated @@ -3647,7 +3780,8 @@ controls: - id: RHEL-09-654190 levels: - medium - title: Successful/unsuccessful uses of the poweroff command in RHEL 9 must generate an audit record. + title: Successful/unsuccessful uses of the poweroff command in RHEL 9 must generate an audit + record. rules: - audit_privileged_commands_poweroff status: automated @@ -3655,7 +3789,8 @@ controls: - id: RHEL-09-654195 levels: - medium - title: Successful/unsuccessful uses of the reboot command in RHEL 9 must generate an audit record. + title: Successful/unsuccessful uses of the reboot command in RHEL 9 must generate an audit + record. rules: - audit_privileged_commands_reboot status: automated @@ -3663,7 +3798,8 @@ controls: - id: RHEL-09-654200 levels: - medium - title: Successful/unsuccessful uses of the shutdown command in RHEL 9 must generate an audit record. + title: Successful/unsuccessful uses of the shutdown command in RHEL 9 must generate an audit + record. rules: - audit_privileged_commands_shutdown status: automated @@ -3671,7 +3807,8 @@ controls: - id: RHEL-09-654205 levels: - medium - title: Successful/unsuccessful uses of the umount system call in RHEL 9 must generate an audit + title: Successful/unsuccessful uses of the umount system call in RHEL 9 must generate an + audit record. rules: - audit_rules_dac_modification_umount @@ -3680,7 +3817,8 @@ controls: - id: RHEL-09-654210 levels: - medium - title: Successful/unsuccessful uses of the umount2 system call in RHEL 9 must generate an audit + title: Successful/unsuccessful uses of the umount2 system call in RHEL 9 must generate an + audit record. rules: - audit_rules_dac_modification_umount2 @@ -3689,7 +3827,8 @@ controls: - id: RHEL-09-654215 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/sudoers. rules: - audit_rules_sudoers @@ -3698,7 +3837,8 @@ controls: - id: RHEL-09-654220 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/sudoers.d/ directory. rules: - audit_rules_sudoers_d @@ -3707,7 +3847,8 @@ controls: - id: RHEL-09-654225 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/group. rules: - audit_rules_usergroup_modification_group @@ -3716,7 +3857,8 @@ controls: - id: RHEL-09-654230 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/gshadow. rules: - audit_rules_usergroup_modification_gshadow @@ -3725,7 +3867,8 @@ controls: - id: RHEL-09-654235 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/opasswd. rules: - audit_rules_usergroup_modification_opasswd @@ -3734,7 +3877,8 @@ controls: - id: RHEL-09-654240 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/passwd. rules: - audit_rules_usergroup_modification_passwd @@ -3743,7 +3887,8 @@ controls: - id: RHEL-09-654245 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /etc/shadow. rules: - audit_rules_usergroup_modification_shadow @@ -3752,7 +3897,8 @@ controls: - id: RHEL-09-654250 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /var/log/faillock. rules: - audit_rules_login_events_faillock @@ -3761,7 +3907,8 @@ controls: - id: RHEL-09-654255 levels: - medium - title: RHEL 9 must generate audit records for all account creations, modifications, disabling, + title: RHEL 9 must generate audit records for all account creations, modifications, + disabling, and termination events that affect /var/log/lastlog. rules: - audit_rules_login_events_lastlog @@ -3796,16 +3943,14 @@ controls: - high title: RHEL 9 must enable FIPS mode. rules: - - enable_fips_mode - sysctl_crypto_fips_enabled - - var_system_crypto_policy=fips_stig - - enable_dracut_fips_module status: automated - id: RHEL-09-671015 levels: - medium - title: RHEL 9 must employ FIPS 140-3 approved cryptographic hashing algorithms for all stored passwords. + title: RHEL 9 must employ FIPS 140-3 approved cryptographic hashing algorithms for all stored + passwords. rules: - accounts_password_all_shadowed_sha512 status: automated @@ -3821,7 +3966,8 @@ controls: - id: RHEL-09-671025 levels: - medium - title: RHEL 9 pam_unix.so module must be configured in the password-auth file to use a FIPS 140-3 + title: RHEL 9 pam_unix.so module must be configured in the password-auth file to use a FIPS + 140-3 approved cryptographic hashing algorithm for system authentication. rules: - set_password_hashing_algorithm_passwordauth @@ -3836,24 +3982,12 @@ controls: - id: RHEL-09-672020 levels: - medium - title: RHEL 9 crypto policy must not be overridden. - notes: Rules for this control are intentionally not implemented. Checking whether files under /etc/crypto-policies/back-ends/ - are symlinks is not an appropriate way to verify the consistency of the system's cryptographic settings. - The suggested fix mentioned in the STIG does not fully satisfy its own requirements, as it also symlinks the nss.config file. - Furthermore, running sudo 'update-crypto-policies --set FIPS' is not a reliable way to ensure FIPS compliance. Customers should - refer to the official Red Hat Documentation and use the 'fips=1' kernel option during system installation to ensure the system is - in FIPS mode. - More information can be found at https://docs.redhat.com/en/documentation/red_hat_enterprise_linux/9/html/security_hardening/switching-rhel-to-fips-mode_security-hardening - status: pending - - - id: RHEL-09-672025 - levels: - - medium - title: RHEL 9 must use mechanisms meeting the requirements of applicable federal laws, executive - orders, directives, policies, regulations, standards, and guidance for authentication to a - cryptographic module. + title: RHEL 9 cryptographic policy must not be overridden. + notes: >- + This rule only contains SCE (Script Check Engine) content. The package + openscap-engine-sce must be installed on the target system for the check to work. rules: - - configure_kerberos_crypto_policy + - crypto_policy_not_overridden status: automated - id: RHEL-09-672030 diff --git a/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_enhanced-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_enhanced-ks.cfg index dc7442fef49b..48dbcf396ce8 100644 --- a/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_enhanced-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_enhanced-ks.cfg @@ -80,35 +80,36 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=3192 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=5000 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /srv Located On Separate Partition -logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" +logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=128 --fsoptions="nodev,noexec,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log Located On Separate Partition logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition @@ -117,17 +118,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html-single/performing_an_advanced_rhel_9_installation/index#addon-com_redhat_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon com_redhat_oscap diff --git a/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_high-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_high-ks.cfg index 627a9f987ee7..bbb3a2cadf90 100644 --- a/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_high-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_high-ks.cfg @@ -84,35 +84,36 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=3192 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=5000 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /srv Located On Separate Partition -logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" +logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log Located On Separate Partition logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition @@ -121,17 +122,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html-single/performing_an_advanced_rhel_9_installation/index#addon-com_redhat_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon com_redhat_oscap diff --git a/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_intermediary-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_intermediary-ks.cfg index 6766ee536a5e..d5649e10ece3 100644 --- a/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_intermediary-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-anssi_bp28_intermediary-ks.cfg @@ -80,35 +80,36 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=3192 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=5000 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /srv Located On Separate Partition -logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" +logvol /srv --fstype=xfs --name=srv --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid" # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=128 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log Located On Separate Partition logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition @@ -117,17 +118,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html-single/performing_an_advanced_rhel_9_installation/index#addon-com_redhat_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon com_redhat_oscap diff --git a/products/rhel9/kickstart/ssg-rhel9-bsi-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-bsi-ks.cfg index 682e01927d3b..68a69d4d0d9c 100644 --- a/products/rhel9/kickstart/ssg-rhel9-bsi-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-bsi-ks.cfg @@ -87,25 +87,26 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=4272 +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /usr Located On Separate Partition # partition_for_usr -logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=5000 --fsoptions="nodev" +logvol /usr --fstype=xfs --name=usr --vgname=VolGroup --size=6667 --fsoptions="nodev" # Ensure /opt Located On Separate Partition # partition_for_opt -logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=1024 +logvol /opt --fstype=xfs --name=opt --vgname=VolGroup --size=128 # Ensure /home Located On Separate Partition # partition_for_home -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=512 --fsoptions="nodev" # Ensure /tmp Located On Separate Partition # partition_for_tmp logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" @@ -114,7 +115,7 @@ logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="n logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition # partition_for_var -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=4096 # Ensure /var/log Located On Separate Partition # partition_for_var_log logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 diff --git a/products/rhel9/kickstart/ssg-rhel9-ccn_advanced-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-ccn_advanced-ks.cfg index 720aade95957..84b0be8d8b30 100644 --- a/products/rhel9/kickstart/ssg-rhel9-ccn_advanced-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-ccn_advanced-ks.cfg @@ -84,16 +84,17 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" # Ensure /tmp Located On Separate Partition diff --git a/products/rhel9/kickstart/ssg-rhel9-ccn_basic-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-ccn_basic-ks.cfg index 243c6c1af99b..38a797588751 100644 --- a/products/rhel9/kickstart/ssg-rhel9-ccn_basic-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-ccn_basic-ks.cfg @@ -84,16 +84,17 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" # Ensure /tmp Located On Separate Partition diff --git a/products/rhel9/kickstart/ssg-rhel9-ccn_intermediate-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-ccn_intermediate-ks.cfg index d7071327eb0d..73e367ce22dc 100644 --- a/products/rhel9/kickstart/ssg-rhel9-ccn_intermediate-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-ccn_intermediate-ks.cfg @@ -84,16 +84,17 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid,noexec" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # Ensure /home Located On Separate Partition logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" # Ensure /tmp Located On Separate Partition @@ -110,17 +111,17 @@ logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html-single/performing_an_advanced_rhel_9_installation/index#addon-com_redhat_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon com_redhat_oscap diff --git a/products/rhel9/kickstart/ssg-rhel9-cis-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-cis-ks.cfg index 83d72e423ae2..0f25da7cd1ae 100644 --- a/products/rhel9/kickstart/ssg-rhel9-cis-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-cis-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel9/kickstart/ssg-rhel9-cis_server_l1-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-cis_server_l1-ks.cfg index b34d58aeea25..a34c7e138284 100644 --- a/products/rhel9/kickstart/ssg-rhel9-cis_server_l1-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-cis_server_l1-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l1-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l1-ks.cfg index 7af0fd805a52..c82ab4301e4b 100644 --- a/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l1-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l1-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l2-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l2-ks.cfg index 653b9e700737..9be86efea1f4 100644 --- a/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l2-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-cis_workstation_l2-ks.cfg @@ -87,28 +87,29 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=9728 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # Ensure /var/tmp Located On Separate Partition logvol /var/tmp --fstype=xfs --name=vartmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev,nosuid" # Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/log/audit Located On Separate Partition -logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 +logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev,nosuid,noexec" logvol swap --name=swap --vgname=VolGroup --size=2016 diff --git a/products/rhel9/kickstart/ssg-rhel9-cui-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-cui-ks.cfg index da7115c076e7..142d3ed2e577 100644 --- a/products/rhel9/kickstart/ssg-rhel9-cui-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-cui-ks.cfg @@ -86,16 +86,17 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" # Ensure /tmp Located On Separate Partition diff --git a/products/rhel9/kickstart/ssg-rhel9-ospp-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-ospp-ks.cfg index 520f87c87028..e24d81c5c227 100644 --- a/products/rhel9/kickstart/ssg-rhel9-ospp-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-ospp-ks.cfg @@ -86,16 +86,17 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" # Ensure /tmp Located On Separate Partition diff --git a/products/rhel9/kickstart/ssg-rhel9-pci-dss-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-pci-dss-ks.cfg index cb6919efe8fa..cbb5ce7e2dcb 100644 --- a/products/rhel9/kickstart/ssg-rhel9-pci-dss-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-pci-dss-ks.cfg @@ -78,46 +78,47 @@ zerombr # The following partition layout scheme assumes disk of size 20GB or larger # Modify size of partitions appropriately to reflect actual machine's hardware -# +# # Remove Linux partitions from the system prior to creating new ones (optional) # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 +part /boot --fstype=xfs --size=2048 part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=11264 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=1024 --grow # CCE-26557-9: Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=512 --fsoptions="nodev" # CCE-26435-8: Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,noexec,nosuid" # CCE-26639-5: Ensure /var Located On Separate Partition -logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=3072 --fsoptions="nodev" +logvol /var --fstype=xfs --name=var --vgname=VolGroup --size=4096 --fsoptions="nodev" # CCE-26215-4: Ensure /var/log Located On Separate Partition -logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /var/log --fstype=xfs --name=varlog --vgname=VolGroup --size=512 --fsoptions="nodev" # CCE-26436-6: Ensure /var/log/audit Located On Separate Partition logvol /var/log/audit --fstype=xfs --name=varlogaudit --vgname=VolGroup --size=512 --fsoptions="nodev" logvol swap --name=swap --vgname=VolGroup --size=2016 # The OpenSCAP installer add-on is used to apply SCAP (Security Content Automation Protocol) # content - security policies - on the installed system.This add-on has been enabled by default -# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this +# since Red Hat Enterprise Linux 7.2. When enabled, the packages necessary to provide this # functionality will automatically be installed. However, by default, no policies are enforced, # meaning that no checks are performed during or after installation unless specifically configured. -# +# # Important # Applying a security policy is not necessary on all systems. This screen should only be used # when a specific policy is mandated by your organization rules or government regulations. # Unlike most other commands, this add-on does not accept regular options, but uses key-value # pairs in the body of the %addon definition instead. These pairs are whitespace-agnostic. # Values can be optionally enclosed in single quotes (') or double quotes ("). -# +# # For more details and configuration options see # https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/9/html-single/performing_an_advanced_rhel_9_installation/index#addon-com_redhat_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program %addon com_redhat_oscap diff --git a/products/rhel9/kickstart/ssg-rhel9-stig-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-stig-ks.cfg index d2048c3005ed..9f2340a8e655 100644 --- a/products/rhel9/kickstart/ssg-rhel9-stig-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-stig-ks.cfg @@ -87,18 +87,19 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition diff --git a/products/rhel9/kickstart/ssg-rhel9-stig_gui-ks.cfg b/products/rhel9/kickstart/ssg-rhel9-stig_gui-ks.cfg index 4dc6e1316dbb..dadfc126fab4 100644 --- a/products/rhel9/kickstart/ssg-rhel9-stig_gui-ks.cfg +++ b/products/rhel9/kickstart/ssg-rhel9-stig_gui-ks.cfg @@ -88,18 +88,19 @@ zerombr # --linux erase all Linux partitions # --initlabel initialize the disk label to the default based on the underlying architecture clearpart --linux --initlabel +reqpart # Create primary system partitions (required for installs) -part /boot --fstype=xfs --size=512 --fsoptions="nodev,nosuid,noexec" +part /boot --fstype=xfs --size=2048 --fsoptions="nodev,nosuid" part pv.01 --grow --size=1 # Create a Logical Volume Management (LVM) group (optional) volgroup VolGroup pv.01 # Create particular logical volumes (optional) -logvol / --fstype=xfs --name=root --vgname=VolGroup --size=10240 --grow +logvol / --fstype=xfs --name=root --vgname=VolGroup --size=5120 --grow # Ensure /home Located On Separate Partition -logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev" +logvol /home --fstype=xfs --name=home --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /tmp Located On Separate Partition logvol /tmp --fstype=xfs --name=tmp --vgname=VolGroup --size=1024 --fsoptions="nodev,nosuid,noexec" # Ensure /var/tmp Located On Separate Partition diff --git a/products/rhel9/profiles/default.profile b/products/rhel9/profiles/default.profile index 4eb85b767f5a..3d8d44f04d4a 100644 --- a/products/rhel9/profiles/default.profile +++ b/products/rhel9/profiles/default.profile @@ -13,6 +13,7 @@ description: |- is to keep a rule in the product's XCCDF Benchmark. selections: + - configure_kerberos_crypto_policy - sshd_use_strong_kex - sebool_nfsd_anon_write - sebool_squid_connect_any @@ -437,7 +438,6 @@ selections: - package_telnetd-ssl_removed - sebool_puppetmaster_use_db - audit_rules_successful_file_modification_ftruncate - - fapolicy_default_deny - dconf_gnome_disable_power_settings - sebool_mozilla_plugin_bind_unreserved_ports - package_MFEhiplsm_installed @@ -590,3 +590,5 @@ selections: - audit_rules_var_spool_cron - audit_rules_login_events_tallylog - configure_ssh_crypto_policy + - accounts_user_dot_no_world_writable_programs + - package_dnsmasq_removed diff --git a/products/rhel9/profiles/hipaa.profile b/products/rhel9/profiles/hipaa.profile index 14b6bd693f79..807c12d5b283 100644 --- a/products/rhel9/profiles/hipaa.profile +++ b/products/rhel9/profiles/hipaa.profile @@ -63,6 +63,7 @@ selections: - "!grub2_admin_username" - "!grub2_uefi_admin_username" - "!grub2_uefi_password" + - "!auditd_audispd_syslog_plugin_activated" - "!package_audit-audispd-plugins_installed" - "!package_audit_installed" - "!package_rsh-server_removed" diff --git a/products/rhel9/profiles/stig.profile b/products/rhel9/profiles/stig.profile index 25ec12884fcc..5b2211a80fad 100644 --- a/products/rhel9/profiles/stig.profile +++ b/products/rhel9/profiles/stig.profile @@ -2,7 +2,7 @@ documentation_complete: true metadata: - version: V2R6 + version: V2R8 SMEs: - mab879 - ggbecker @@ -13,7 +13,7 @@ title: 'DISA STIG for Red Hat Enterprise Linux 9' description: |- This profile contains configuration checks that align to the - DISA STIG for Red Hat Enterprise Linux 9 V2R6. + DISA STIG for Red Hat Enterprise Linux 9 V2R8. In addition to being applicable to Red Hat Enterprise Linux 9, this configuration baseline is applicable to the operating system tier of diff --git a/products/rhel9/profiles/stig_gui.profile b/products/rhel9/profiles/stig_gui.profile index 84f6010b8bce..38240e32e067 100644 --- a/products/rhel9/profiles/stig_gui.profile +++ b/products/rhel9/profiles/stig_gui.profile @@ -2,7 +2,7 @@ documentation_complete: true metadata: - version: V2R6 + version: V2R8 SMEs: - mab879 - ggbecker @@ -13,7 +13,7 @@ title: 'DISA STIG with GUI for Red Hat Enterprise Linux 9' description: |- This profile contains configuration checks that align to the - DISA STIG for Red Hat Enterprise Linux 9 V2R6. + DISA STIG for Red Hat Enterprise Linux 9 V2R8. In addition to being applicable to Red Hat Enterprise Linux 9, this configuration baseline is applicable to the operating system tier of @@ -43,5 +43,6 @@ selections: # RHEL-09-215025 - '!package_nfs-utils_removed' - # locking of idle sessions is handled by screensaver when GUI is present, the following rule is therefore redundant + # locking of idle sessions is handled by screensaver when GUI is present, + # the following rule is therefore redundant - '!logind_session_timeout' diff --git a/products/rhv4/profiles/rhvh-stig.profile b/products/rhv4/profiles/rhvh-stig.profile index ec2dd7bdbfb5..a0c8bc01d309 100644 --- a/products/rhv4/profiles/rhvh-stig.profile +++ b/products/rhv4/profiles/rhvh-stig.profile @@ -17,6 +17,7 @@ description: |- selections: - installed_OS_is_FIPS_certified - login_banner_text=dod_banners + - login_banner_contents=dod_default - inactivity_timeout_value=15_minutes - var_password_pam_minlen=15 - accounts_password_pam_minlen diff --git a/products/sle12/profiles/default.profile b/products/sle12/profiles/default.profile index 0e63f6b8b0f9..4a2db7bc6cde 100644 --- a/products/sle12/profiles/default.profile +++ b/products/sle12/profiles/default.profile @@ -33,7 +33,6 @@ selections: - sudo_vdsm_nopasswd - ntpd_configure_restrictions - fapolicyd_prevent_home_folder_access - - package_postfix_installed - audit_privileged_commands_poweroff - accounts_password_pam_unix_rounds_password_auth - sudoers_no_root_target diff --git a/products/sle12/profiles/pci-dss-4.profile b/products/sle12/profiles/pci-dss-4.profile index 3dbc587bb6b6..28a75d78edb5 100644 --- a/products/sle12/profiles/pci-dss-4.profile +++ b/products/sle12/profiles/pci-dss-4.profile @@ -95,6 +95,7 @@ selections: - '!use_pam_wheel_for_su' - use_pam_wheel_group_for_su - var_pam_wheel_group_for_su=cis + - '!package_postfix_installed' # Following rules once had a prodtype incompatible with the sle12 product - '!set_firewalld_default_zone' - '!accounts_password_pam_dcredit' diff --git a/products/sle12/profiles/pci-dss.profile b/products/sle12/profiles/pci-dss.profile index 435a459c9baa..9ddae89654a3 100644 --- a/products/sle12/profiles/pci-dss.profile +++ b/products/sle12/profiles/pci-dss.profile @@ -17,6 +17,7 @@ selections: - sshd_approved_ciphers=cis_sle12 - var_multiple_time_servers=suse - var_multiple_time_pools=suse + - '!package_postfix_installed' # Exclude from PCI DISS profile all rules related to ntp and timesyncd and keep only # rules related to chrony - '!ntpd_specify_multiple_servers' diff --git a/products/sle12/profiles/stig.profile b/products/sle12/profiles/stig.profile index 33b341569721..f0d811635e51 100644 --- a/products/sle12/profiles/stig.profile +++ b/products/sle12/profiles/stig.profile @@ -1,7 +1,7 @@ documentation_complete: true metadata: - version: V3R3 + version: V3R5 SMEs: - svet-se - rumch-se @@ -13,7 +13,7 @@ title: 'DISA STIG for SUSE Linux Enterprise 12' description: |- This profile contains configuration checks that align to the - DISA STIG for SUSE Linux Enterprise 12 V3R3. + DISA STIG for SUSE Linux Enterprise 12 V3R5. selections: - sshd_approved_macs=stig @@ -32,6 +32,9 @@ selections: - var_password_pam_ucredit=1 - var_accounts_maximum_age_login_defs=60 - login_banner_text=dod_banners + - login_banner_contents=dod_default + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default # # Note: must configure "var_accounts_authorized_local_users_regex" when # "accounts_authorized_local_users" rule is enabled @@ -176,7 +179,6 @@ selections: - dir_system_commands_root_owned - disable_ctrlaltdel_reboot - disallow_bypass_password_sudo - - display_login_attempts - enable_dconf_user_profile - encrypt_partitions - ensure_gpgcheck_globally_activated diff --git a/products/sle15/product.yml b/products/sle15/product.yml index 1e05518539f7..2ef7afb29e6a 100644 --- a/products/sle15/product.yml +++ b/products/sle15/product.yml @@ -14,13 +14,16 @@ profiles_root: "./profiles" init_system: "systemd" +sshd_distributed_config: "true" + pkg_manager: "zypper" pkg_manager_config_file: "/etc/zypp/zypp.conf" pkg_release: "5f68629b" pkg_version: "39db7c82" release_key_fingerprint: "FEAB502539D846DB2C0961CA70AF9E8139DB7C82" -oval_feed_url: "https://ftp.suse.com/pub/projects/security/oval/suse.linux.enterprise.15-patch.xml.bz2" +oval_feed_url: >- + https://ftp.suse.com/pub/projects/security/oval/suse.linux.enterprise.15-patch.xml.bz2 aide_bin_path: "/usr/bin/aide" audisp_conf_path: "/etc/audit" diff --git a/products/sle15/profiles/anssi_bp28_enhanced.profile b/products/sle15/profiles/anssi_bp28_enhanced.profile index ecd54b8d3f83..f961028e670d 100644 --- a/products/sle15/profiles/anssi_bp28_enhanced.profile +++ b/products/sle15/profiles/anssi_bp28_enhanced.profile @@ -78,3 +78,5 @@ selections: - '!audit_rules_mac_modification_etc_selinux' - '!no_nis_in_nsswitch' - '!service_chronyd_enabled' + - '!audit_rules_immutable' + diff --git a/products/sle15/profiles/anssi_bp28_high.profile b/products/sle15/profiles/anssi_bp28_high.profile index 9f6751e4eebf..1a1547096600 100644 --- a/products/sle15/profiles/anssi_bp28_high.profile +++ b/products/sle15/profiles/anssi_bp28_high.profile @@ -104,3 +104,5 @@ selections: - '!service_chronyd_enabled' - '!audit_rules_mac_modification_etc_selinux' - '!no_nis_in_nsswitch' + - '!audit_rules_immutable' + diff --git a/products/sle15/profiles/anssi_bp28_intermediary.profile b/products/sle15/profiles/anssi_bp28_intermediary.profile index a5f7082561aa..0c4f0a2681fa 100644 --- a/products/sle15/profiles/anssi_bp28_intermediary.profile +++ b/products/sle15/profiles/anssi_bp28_intermediary.profile @@ -72,3 +72,5 @@ selections: - '!ldap_client_start_tls' - '!ldap_client_tls_cacertpath' - '!no_nis_in_nsswitch' + - '!audit_rules_immutable' + diff --git a/products/sle15/profiles/anssi_bp28_minimal.profile b/products/sle15/profiles/anssi_bp28_minimal.profile index d1a31f8730de..1e8491a10ebb 100644 --- a/products/sle15/profiles/anssi_bp28_minimal.profile +++ b/products/sle15/profiles/anssi_bp28_minimal.profile @@ -42,6 +42,7 @@ selections: - '!accounts_passwords_pam_faillock_interval' - '!accounts_password_pam_ucredit' - '!accounts_password_pam_minlen' + - '!audit_rules_immutable' - '!ensure_oracle_gpgkey_installed' - '!ensure_almalinux_gpgkey_installed' - '!enable_authselect' diff --git a/products/sle15/profiles/default.profile b/products/sle15/profiles/default.profile index d43fc05c0535..a89ecd426a77 100644 --- a/products/sle15/profiles/default.profile +++ b/products/sle15/profiles/default.profile @@ -27,7 +27,6 @@ selections: - sudo_vdsm_nopasswd - package_mcstrans_removed - fapolicyd_prevent_home_folder_access - - package_postfix_installed - accounts_password_pam_unix_rounds_password_auth - audit_privileged_commands_poweroff - configure_etc_hosts_deny diff --git a/products/sle15/profiles/hipaa.profile b/products/sle15/profiles/hipaa.profile index 1c7e4b9aad37..a260d697581a 100644 --- a/products/sle15/profiles/hipaa.profile +++ b/products/sle15/profiles/hipaa.profile @@ -70,7 +70,7 @@ selections: - service_auditd_enabled - audit_rules_privileged_commands_sudo - audit_rules_privileged_commands_su - - audit_rules_immutable + - '!audit_rules_immutable' - kernel_module_usb-storage_disabled - service_autofs_disabled - auditd_audispd_syslog_plugin_activated diff --git a/products/sle15/profiles/pci-dss-4.profile b/products/sle15/profiles/pci-dss-4.profile index 52bb158df271..103abd2ee32d 100644 --- a/products/sle15/profiles/pci-dss-4.profile +++ b/products/sle15/profiles/pci-dss-4.profile @@ -20,6 +20,7 @@ selections: - var_multiple_time_servers=suse - var_multiple_time_pools=suse - audit_rules_enable_syscall_auditing + - '!package_postfix_installed' # Exclude from PCI DISS profile all rules related to ntp and timesyncd and keep only # rules related to chrony - '!ntpd_specify_multiple_servers' diff --git a/products/sle15/profiles/pcs-hardening-sap.profile b/products/sle15/profiles/pcs-hardening-sap.profile index 63231a2b3b34..22c9e487becf 100644 --- a/products/sle15/profiles/pcs-hardening-sap.profile +++ b/products/sle15/profiles/pcs-hardening-sap.profile @@ -5,7 +5,7 @@ metadata: SMEs: - esampson -reference: +reference: title: 'Hardening for Public Cloud Image of SUSE Linux Enterprise Server (SLES) for SAP Applications 15' @@ -24,8 +24,9 @@ selections: - var_apparmor_mode=complain - motd_banner_text=cis_banners - login_banner_text=cis_banners + - login_banner_contents=cis_default - remote_login_banner_text=cis_banners - - login_banner_text=cis_default + - remote_login_banner_contents=cis_default - var_multiple_time_servers=suse - var_multiple_time_pools=suse - var_postfix_inet_interfaces=loopback-only diff --git a/products/sle15/profiles/pcs-hardening.profile b/products/sle15/profiles/pcs-hardening.profile index 69da010c6d09..9d47cd6e6886 100644 --- a/products/sle15/profiles/pcs-hardening.profile +++ b/products/sle15/profiles/pcs-hardening.profile @@ -5,7 +5,7 @@ metadata: SMEs: - esampson -reference: +reference: title: 'Public Cloud Hardening for SUSE Linux Enterprise 15' @@ -31,6 +31,9 @@ selections: - var_password_pam_delay=4000000 #- login_banner_text=dod_banners - login_banner_text=cis_banners + - login_banner_contents=cis_default + - motd_banner_text=cis_banners + - motd_banner_contents=cis_default # # Note: must configure "var_accounts_authorized_local_users_regex" when # "accounts_authorized_local_users" rule is enabled @@ -152,7 +155,7 @@ selections: - audit_rules_file_deletion_events_renameat - audit_rules_file_deletion_events_unlink - audit_rules_file_deletion_events_unlinkat - - audit_rules_immutable + - '!audit_rules_immutable' - audit_rules_kernel_module_loading_delete - audit_rules_kernel_module_loading_finit - audit_rules_kernel_module_loading_init @@ -410,7 +413,7 @@ selections: #- package_net-snmp_removed #- package_telnet_removed #- package_telnet-server_removed - #### OTHER + #### OTHER #### can't do at image build time #- accounts_authorized_local_users #- accounts_max_concurrent_login_sessions diff --git a/products/sle15/profiles/stig.profile b/products/sle15/profiles/stig.profile index 309c043b17a3..a4c36dd810bb 100644 --- a/products/sle15/profiles/stig.profile +++ b/products/sle15/profiles/stig.profile @@ -1,7 +1,7 @@ documentation_complete: true metadata: - version: V2R5 + version: V2R7 SMEs: - svet-se - rumch-se @@ -13,7 +13,7 @@ title: 'DISA STIG for SUSE Linux Enterprise 15' description: |- This profile contains configuration checks that align to the - DISA STIG for SUSE Linux Enterprise 15 V2R5. + DISA STIG for SUSE Linux Enterprise 15 V2R7. selections: @@ -31,6 +31,9 @@ selections: - var_accounts_maximum_age_login_defs=60 - var_password_pam_delay=4000000 - login_banner_text=dod_banners + - login_banner_contents=dod_default + - dconf_login_banner_text=dod_banners + - dconf_login_banner_contents=dod_default # # Note: must configure "var_accounts_authorized_local_users_regex" when # "accounts_authorized_local_users" rule is enabled @@ -67,9 +70,7 @@ selections: - accounts_user_home_paths_only - accounts_user_interactive_home_directory_defined - accounts_user_interactive_home_directory_exists - - account_temp_expire_date - account_unique_id - - agent_mfetpd_running - aide_build_database - aide_check_audit_tools - aide_periodic_cron_checking @@ -191,7 +192,6 @@ selections: - disable_ctrlaltdel_reboot - disable_ctrlaltdel_reboot - disallow_bypass_password_sudo - - display_login_attempts - enable_dconf_user_profile - encrypt_partitions - ensure_gpgcheck_globally_activated diff --git a/products/sle16/profiles/anssi_bp28_enhanced.profile b/products/sle16/profiles/anssi_bp28_enhanced.profile new file mode 100644 index 000000000000..d93e440d079a --- /dev/null +++ b/products/sle16/profiles/anssi_bp28_enhanced.profile @@ -0,0 +1,76 @@ +--- +documentation_complete: true + +metadata: + SMEs: + - svet-se + - teacup-on-rockingchair + +title: 'ANSSI-BP-028 (enhanced)' + +description: |- + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the enhanced hardening level. + + ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. + ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. + + A copy of the ANSSI-BP-028 can be found at the ANSSI website: + https://www.ssi.gouv.fr/administration/guide/recommandations-de-securite-relatives-a-un-systeme-gnulinux/ + + An English version of the ANSSI-BP-028 can also be found at the ANSSI website: + https://messervices.cyber.gouv.fr/guides/en-configuration-recommendations-gnulinux-system + +selections: + - anssi:all:enhanced + - var_multiple_time_servers=suse + - var_multiple_time_pools=suse + - var_sudo_dedicated_group=root + - accounts_password_pam_pwhistory_remember + - set_password_hashing_min_rounds_logindefs + - '!cracklib_accounts_password_pam_dcredit' + - '!cracklib_accounts_password_pam_lcredit' + - '!cracklib_accounts_password_pam_minlen' + - '!cracklib_accounts_password_pam_ocredit' + - '!cracklib_accounts_password_pam_ucredit' + - '!accounts_password_pam_unix_rounds_system_auth' + - '!accounts_passwords_pam_tally2_deny_root' + - '!accounts_passwords_pam_tally2_unlock_time' + - '!accounts_passwords_pam_tally2' + - '!aide_periodic_cron_checking' + - '!all_apparmor_profiles_enforced' + - '!apparmor_configured' + - '!audit_rules_immutable' + - '!dnf-automatic_apply_updates' + - '!dnf-automatic_security_updates_only' + - '!enable_authselect' + - '!ensure_almalinux_gpgkey_installed' + - '!ensure_oracle_gpgkey_installed' + - '!ensure_redhat_gpgkey_installed' + - '!file_groupowner_user_cfg' + - '!file_owner_user_cfg' + - '!file_permissions_sudo' + - '!file_permissions_user_cfg' + - '!grub2_enable_apparmor' + - '!kernel_config_arm64_sw_ttbr0_pan' + - '!kernel_config_gcc_plugin_latent_entropy' + - '!kernel_config_gcc_plugin_randstruct' + - '!kernel_config_gcc_plugin_stackleak' + - '!kernel_config_gcc_plugin_structleak_byref_all' + - '!kernel_config_gcc_plugin_structleak' + - '!kernel_config_legacy_vsyscall_emulate' + - '!kernel_config_modify_ldt_syscall' + - '!kernel_config_refcount_full' + - '!kernel_config_slab_merge_default' + - '!ldap_client_start_tls' + - '!ldap_client_tls_cacertpath' + - '!no_nis_in_nsswitch' + - '!package_apparmor_installed' + - '!package_dnf-automatic_installed' + - '!package_dracut-fips-aesni_installed' + - '!package_pam_apparmor_installed' + - '!package_rsh_removed' + - '!package_rsh-server_removed' + - '!package_ypbind_removed' + - '!package_ypserv_removed' + - '!sebool_secure_mode_insmod' + - '!timer_dnf-automatic_enabled' diff --git a/products/sle16/profiles/anssi_bp28_high.profile b/products/sle16/profiles/anssi_bp28_high.profile new file mode 100644 index 000000000000..c0c4fd81912c --- /dev/null +++ b/products/sle16/profiles/anssi_bp28_high.profile @@ -0,0 +1,76 @@ +--- +documentation_complete: true + +metadata: + SMEs: + - svet-se + - teacup-on-rockingchair + +title: 'ANSSI-BP-028 (high)' + +description: |- + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the high hardening level. + + ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. + ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. + + A copy of the ANSSI-BP-028 can be found at the ANSSI website: + https://www.ssi.gouv.fr/administration/guide/recommandations-de-securite-relatives-a-un-systeme-gnulinux/ + + An English version of the ANSSI-BP-028 can also be found at the ANSSI website: + https://messervices.cyber.gouv.fr/guides/en-configuration-recommendations-gnulinux-system + +selections: + - anssi:all:high + - var_multiple_time_servers=suse + - var_multiple_time_pools=suse + - var_sudo_dedicated_group=root + - accounts_password_pam_pwhistory_remember + - set_password_hashing_min_rounds_logindefs + - '!cracklib_accounts_password_pam_dcredit' + - '!cracklib_accounts_password_pam_lcredit' + - '!cracklib_accounts_password_pam_minlen' + - '!cracklib_accounts_password_pam_ocredit' + - '!cracklib_accounts_password_pam_ucredit' + - '!accounts_password_pam_unix_rounds_system_auth' + - '!accounts_passwords_pam_tally2_deny_root' + - '!accounts_passwords_pam_tally2_unlock_time' + - '!accounts_passwords_pam_tally2' + - '!aide_periodic_cron_checking' + - '!all_apparmor_profiles_enforced' + - '!apparmor_configured' + - '!audit_rules_immutable' + - '!dnf-automatic_apply_updates' + - '!dnf-automatic_security_updates_only' + - '!enable_authselect' + - '!ensure_almalinux_gpgkey_installed' + - '!ensure_oracle_gpgkey_installed' + - '!ensure_redhat_gpgkey_installed' + - '!file_groupowner_user_cfg' + - '!file_owner_user_cfg' + - '!file_permissions_sudo' + - '!file_permissions_user_cfg' + - '!grub2_enable_apparmor' + - '!kernel_config_arm64_sw_ttbr0_pan' + - '!kernel_config_gcc_plugin_latent_entropy' + - '!kernel_config_gcc_plugin_randstruct' + - '!kernel_config_gcc_plugin_stackleak' + - '!kernel_config_gcc_plugin_structleak_byref_all' + - '!kernel_config_gcc_plugin_structleak' + - '!kernel_config_legacy_vsyscall_emulate' + - '!kernel_config_modify_ldt_syscall' + - '!kernel_config_refcount_full' + - '!kernel_config_slab_merge_default' + - '!ldap_client_start_tls' + - '!ldap_client_tls_cacertpath' + - '!no_nis_in_nsswitch' + - '!package_apparmor_installed' + - '!package_dnf-automatic_installed' + - '!package_dracut-fips-aesni_installed' + - '!package_pam_apparmor_installed' + - '!package_rsh_removed' + - '!package_rsh-server_removed' + - '!package_ypbind_removed' + - '!package_ypserv_removed' + - '!sebool_secure_mode_insmod' + - '!timer_dnf-automatic_enabled' diff --git a/products/sle16/profiles/anssi_bp28_intermediary.profile b/products/sle16/profiles/anssi_bp28_intermediary.profile new file mode 100644 index 000000000000..5fbf1d3ee013 --- /dev/null +++ b/products/sle16/profiles/anssi_bp28_intermediary.profile @@ -0,0 +1,76 @@ +--- +documentation_complete: true + +metadata: + SMEs: + - svet-se + - teacup-on-rockingchair + +title: 'ANSSI-BP-028 (intermediary)' + +description: |- + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the intermediary hardening level. + + ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. + ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. + + A copy of the ANSSI-BP-028 can be found at the ANSSI website: + https://www.ssi.gouv.fr/administration/guide/recommandations-de-securite-relatives-a-un-systeme-gnulinux/ + + An English version of the ANSSI-BP-028 can also be found at the ANSSI website: + https://messervices.cyber.gouv.fr/guides/en-configuration-recommendations-gnulinux-system + +selections: + - anssi:all:intermediary + - var_multiple_time_servers=suse + - var_multiple_time_pools=suse + - var_sudo_dedicated_group=root + - accounts_password_pam_pwhistory_remember + - set_password_hashing_min_rounds_logindefs + - '!cracklib_accounts_password_pam_dcredit' + - '!cracklib_accounts_password_pam_lcredit' + - '!cracklib_accounts_password_pam_minlen' + - '!cracklib_accounts_password_pam_ocredit' + - '!cracklib_accounts_password_pam_ucredit' + - '!accounts_password_pam_unix_rounds_system_auth' + - '!accounts_passwords_pam_tally2_deny_root' + - '!accounts_passwords_pam_tally2_unlock_time' + - '!accounts_passwords_pam_tally2' + - '!aide_periodic_cron_checking' + - '!all_apparmor_profiles_enforced' + - '!apparmor_configured' + - '!audit_rules_immutable' + - '!dnf-automatic_apply_updates' + - '!dnf-automatic_security_updates_only' + - '!enable_authselect' + - '!ensure_almalinux_gpgkey_installed' + - '!ensure_oracle_gpgkey_installed' + - '!ensure_redhat_gpgkey_installed' + - '!file_groupowner_user_cfg' + - '!file_owner_user_cfg' + - '!file_permissions_sudo' + - '!file_permissions_user_cfg' + - '!grub2_enable_apparmor' + - '!kernel_config_arm64_sw_ttbr0_pan' + - '!kernel_config_gcc_plugin_latent_entropy' + - '!kernel_config_gcc_plugin_randstruct' + - '!kernel_config_gcc_plugin_stackleak' + - '!kernel_config_gcc_plugin_structleak_byref_all' + - '!kernel_config_gcc_plugin_structleak' + - '!kernel_config_legacy_vsyscall_emulate' + - '!kernel_config_modify_ldt_syscall' + - '!kernel_config_refcount_full' + - '!kernel_config_slab_merge_default' + - '!ldap_client_start_tls' + - '!ldap_client_tls_cacertpath' + - '!no_nis_in_nsswitch' + - '!package_apparmor_installed' + - '!package_dnf-automatic_installed' + - '!package_dracut-fips-aesni_installed' + - '!package_pam_apparmor_installed' + - '!package_rsh_removed' + - '!package_rsh-server_removed' + - '!package_ypbind_removed' + - '!package_ypserv_removed' + - '!sebool_secure_mode_insmod' + - '!timer_dnf-automatic_enabled' diff --git a/products/sle16/profiles/anssi_bp28_minimal.profile b/products/sle16/profiles/anssi_bp28_minimal.profile new file mode 100644 index 000000000000..441229a07086 --- /dev/null +++ b/products/sle16/profiles/anssi_bp28_minimal.profile @@ -0,0 +1,76 @@ +--- +documentation_complete: true + +metadata: + SMEs: + - svet-se + - teacup-on-rockingchair + +title: 'ANSSI-BP-028 (minimal)' + +description: |- + This profile contains configurations that align to ANSSI-BP-028 v2.0 at the minimal hardening level. + + ANSSI is the French National Information Security Agency, and stands for Agence nationale de la sécurité des systèmes d'information. + ANSSI-BP-028 is a configuration recommendation for GNU/Linux systems. + + A copy of the ANSSI-BP-028 can be found at the ANSSI website: + https://www.ssi.gouv.fr/administration/guide/recommandations-de-securite-relatives-a-un-systeme-gnulinux/ + + An English version of the ANSSI-BP-028 can also be found at the ANSSI website: + https://messervices.cyber.gouv.fr/guides/en-configuration-recommendations-gnulinux-system + +selections: + - anssi:all:minimal + - var_multiple_time_servers=suse + - var_multiple_time_pools=suse + - var_sudo_dedicated_group=root + - accounts_password_pam_pwhistory_remember + - set_password_hashing_min_rounds_logindefs + - '!cracklib_accounts_password_pam_dcredit' + - '!cracklib_accounts_password_pam_lcredit' + - '!cracklib_accounts_password_pam_minlen' + - '!cracklib_accounts_password_pam_ocredit' + - '!cracklib_accounts_password_pam_ucredit' + - '!accounts_password_pam_unix_rounds_system_auth' + - '!accounts_passwords_pam_tally2_deny_root' + - '!accounts_passwords_pam_tally2_unlock_time' + - '!accounts_passwords_pam_tally2' + - '!aide_periodic_cron_checking' + - '!all_apparmor_profiles_enforced' + - '!apparmor_configured' + - '!audit_rules_immutable' + - '!dnf-automatic_apply_updates' + - '!dnf-automatic_security_updates_only' + - '!enable_authselect' + - '!ensure_almalinux_gpgkey_installed' + - '!ensure_oracle_gpgkey_installed' + - '!ensure_redhat_gpgkey_installed' + - '!file_groupowner_user_cfg' + - '!file_owner_user_cfg' + - '!file_permissions_sudo' + - '!file_permissions_user_cfg' + - '!grub2_enable_apparmor' + - '!kernel_config_arm64_sw_ttbr0_pan' + - '!kernel_config_gcc_plugin_latent_entropy' + - '!kernel_config_gcc_plugin_randstruct' + - '!kernel_config_gcc_plugin_stackleak' + - '!kernel_config_gcc_plugin_structleak_byref_all' + - '!kernel_config_gcc_plugin_structleak' + - '!kernel_config_legacy_vsyscall_emulate' + - '!kernel_config_modify_ldt_syscall' + - '!kernel_config_refcount_full' + - '!kernel_config_slab_merge_default' + - '!ldap_client_start_tls' + - '!ldap_client_tls_cacertpath' + - '!no_nis_in_nsswitch' + - '!package_apparmor_installed' + - '!package_dnf-automatic_installed' + - '!package_dracut-fips-aesni_installed' + - '!package_pam_apparmor_installed' + - '!package_rsh_removed' + - '!package_rsh-server_removed' + - '!package_ypbind_removed' + - '!package_ypserv_removed' + - '!sebool_secure_mode_insmod' + - '!timer_dnf-automatic_enabled' diff --git a/products/sle16/profiles/pci-dss-4.profile b/products/sle16/profiles/pci-dss-4.profile index 6b771a83155a..ba7de6b6ccc2 100644 --- a/products/sle16/profiles/pci-dss-4.profile +++ b/products/sle16/profiles/pci-dss-4.profile @@ -27,6 +27,7 @@ selections: - var_multiple_time_servers=suse - var_multiple_time_pools=suse - var_accounts_tmout=15_min + - var_accounts_passwords_pam_faillock_dir=run - audit_rules_enable_syscall_auditing - '!ntpd_specify_multiple_servers' - '!ntpd_specify_remote_server' @@ -36,25 +37,20 @@ selections: - '!package_libreswan_installed' - '!use_pam_wheel_for_su' - '!aide_periodic_cron_checking' - - '!accounts_password_pam_dcredit' - '!accounts_password_pam_pwhistory_remember_system_auth' - '!sysctl_kernel_core_pattern' - '!configure_firewalld_ports' - '!accounts_passwords_pam_tally2' - '!accounts_passwords_pam_tally2_unlock_time' - '!audit_rules_login_events_tallylog' - - '!accounts_passwords_pam_faillock_deny' - '!file_owner_user_cfg' - - '!accounts_passwords_pam_faillock_unlock_time' - '!ensure_redhat_gpgkey_installed' - '!package_sequoia-sq_installed' - '!ensure_almalinux_gpgkey_installed' - '!firewalld_loopback_traffic_restricted' - - '!accounts_password_pam_lcredit' - '!file_group_ownership_var_log_audit' - '!package_ftp_removed' - '!gnome_gdm_disable_guest_login' - - '!accounts_password_pam_minlen' - '!no_password_auth_for_systemaccounts' - '!file_groupowner_user_cfg' - '!ensure_root_password_configured' @@ -83,3 +79,8 @@ selections: - '!set_ipv6_loopback_traffic' - '!set_loopback_traffic' - '!nftables_ensure_default_deny_policy' + - '!cracklib_accounts_password_pam_dcredit' + - '!cracklib_accounts_password_pam_lcredit' + - '!cracklib_accounts_password_pam_minlen' + - '!cracklib_accounts_password_pam_retry' + - 'accounts_password_pam_retry' diff --git a/products/slmicro5/profiles/stig.profile b/products/slmicro5/profiles/stig.profile index f5024ff753bd..0f986168ec6f 100644 --- a/products/slmicro5/profiles/stig.profile +++ b/products/slmicro5/profiles/stig.profile @@ -1,7 +1,7 @@ documentation_complete: true metadata: - version: V1R2 + version: V1R4 SMEs: - svet-se - rumch-se @@ -13,7 +13,7 @@ title: 'DISA STIG for SUSE Linux Enterprise Micro (SLEM) 5' description: |- This profile contains configuration checks that align to the - DISA STIG for SUSE Linux Enterprise Micro (SLEM) 5 V1R2. + DISA STIG for SUSE Linux Enterprise Micro (SLEM) 5 V1R4. selections: - stig_slmicro5:all diff --git a/products/ubuntu2204/profiles/default.profile b/products/ubuntu2204/profiles/default.profile index 982095129892..54a33e3d1ac9 100644 --- a/products/ubuntu2204/profiles/default.profile +++ b/products/ubuntu2204/profiles/default.profile @@ -582,8 +582,7 @@ selections: - sudo_add_use_pty - sudo_custom_logfile - sudo_remove_no_authenticate - - sudo_require_authentication - - sudo_require_reauthentication + - sudo_remove_nopasswd - sysctl_fs_suid_dumpable - sysctl_kernel_dmesg_restrict - sysctl_kernel_randomize_va_space diff --git a/products/ubuntu2204/profiles/stig.profile b/products/ubuntu2204/profiles/stig.profile index 0a7b4bf2fb2e..ccc40b0a53b3 100644 --- a/products/ubuntu2204/profiles/stig.profile +++ b/products/ubuntu2204/profiles/stig.profile @@ -2,7 +2,7 @@ documentation_complete: true metadata: - version: V2R3 + version: V2R7 SMEs: - mpurg - dodys @@ -11,11 +11,11 @@ metadata: reference: https://www.cyber.mil/stigs/downloads -title: 'Canonical Ubuntu 22.04 LTS Security Technical Implementation Guide (STIG) V2R3' +title: 'Canonical Ubuntu 22.04 LTS Security Technical Implementation Guide (STIG) V2R7' description: |- This profile contains configuration checks that align to the - DISA STIG for Canonical Ubuntu 22.04 LTS V2R3. + DISA STIG for Canonical Ubuntu 22.04 LTS V2R7. selections: - stig_ubuntu2204:all diff --git a/pyproject.toml b/pyproject.toml index 3acf91a4a68b..6290304e2901 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -11,7 +11,7 @@ dependencies = [ "Jinja2", "setuptools" ] -requires-python = ">= 3" +requires-python = ">=3.6" maintainers = [ {name = "Gabriel Gaspar Becker", email = "ggasparb@redhat.com"}, {name = "Jan Cerny", email = "jcerny@redhat.com"}, diff --git a/renovate.json b/renovate.json new file mode 100644 index 000000000000..8306f3183ad6 --- /dev/null +++ b/renovate.json @@ -0,0 +1,13 @@ +{ + "$schema": "https://docs.renovatebot.com/renovate-schema.json", + "extends": [ + "config:recommended" + ], + "labels": [ + "ok-to-test" + ], + "enabledManagers": [ + "tekton", + "rpm-lockfile" + ] +} diff --git a/requirements.txt b/requirements.txt index bcca1c6c2aaf..a2951000c47a 100644 --- a/requirements.txt +++ b/requirements.txt @@ -13,8 +13,6 @@ lxml-stubs pycompliance # used in utils/controleval_metrics.py prometheus_client -# used in utils/oscal requests -compliance-trestle==3.11.0 pyopenssl>=23.2.0 pcre2 diff --git a/ruff.toml b/ruff.toml index d5e89e0e13c1..266d8054ff15 100644 --- a/ruff.toml +++ b/ruff.toml @@ -1,9 +1,10 @@ line-length = 99 indent-width = 4 -target-version = "py39" +target-version = "py37" [lint] select = [ + "B", # flake8-bugbear "F", # Pyflakes "E", # pycodestyle "W", # pycodestyle diff --git a/shared/applicability/os_linux.yml b/shared/applicability/os_linux.yml index bd923dcd2b6e..233e0880b755 100644 --- a/shared/applicability/os_linux.yml +++ b/shared/applicability/os_linux.yml @@ -20,3 +20,7 @@ args: os_name: "SUSE Linux Enterprise Server" os_id: 'sles' os_id_ansible: "SLES" + amzn: + os_name: "Amazon Linux" + os_id: "amzn" + os_id_ansible: "Amazon" diff --git a/shared/applicability/oval/system_with_kernel.xml b/shared/applicability/oval/system_with_kernel.xml index d1cbf79c4d20..65a9ca34ab7f 100644 --- a/shared/applicability/oval/system_with_kernel.xml +++ b/shared/applicability/oval/system_with_kernel.xml @@ -8,17 +8,26 @@ {{% endif %}} {{% if 'sle' in product or 'slmicro' in product %}} + {{% endif %}} + {{% if 'debian' in product or 'ubuntu' in product %}} {{{ oval_test_package_installed(package="linux-base", test_id="inventory_test_kernel_installed") }}} + {{% elif 'sle' in product or 'slmicro' in product %}} {{{ oval_test_package_installed(package="kernel-default", test_id="inventory_test_kernel_installed") }}} {{{ oval_test_package_installed(package="kernel-default-base", test_id="inventory_test_kernel_default_base_installed") }}} -{{% else %}} +{{{ oval_test_package_installed(package="kernel-azure", test_id="inventory_test_kernel_azure_installed") }}} + +{{% elif product == "fedora" or "rhel" in product %}} {{{ oval_test_package_installed(package="kernel-core", test_id="inventory_test_kernel_installed") }}} + +{{% else %}} +{{{ oval_test_package_installed(package="kernel", test_id="inventory_test_kernel_installed") }}} {{% endif %}} + {{% if "ol" in families %}} {{{ oval_test_package_installed(package="kernel-uek", test_id="inventory_test_kernel_uek_installed") }}} {{% endif %}} diff --git a/shared/applicability/package.yml b/shared/applicability/package.yml index 75cd60e08c3c..bfb3104263b6 100644 --- a/shared/applicability/package.yml +++ b/shared/applicability/package.yml @@ -50,6 +50,8 @@ args: {{% endif %}} iptables: pkgname: iptables + krb5-libs: + pkgname: krb5-libs libpwquality: {{% if 'debian' in product or 'sle' in product or 'slmicro' in product or 'ubuntu' in product %}} pkgname: libpwquality1 @@ -95,8 +97,12 @@ args: title: NTP daemon and utilities openssh: pkgname: openssh + openssh-clients: + pkgname: openssh-clients openssh-server: pkgname: openssh-server + openssl: + pkgname: openssl pam: {{% if pkg_system == "rpm" %}} pkgname: pam @@ -166,3 +172,5 @@ args: pkgname: rsyslog rootfiles: pkgname: rootfiles + tcsh: + pkgname: tcsh diff --git a/shared/applicability/system_with_kernel.yml b/shared/applicability/system_with_kernel.yml index 07793b1a1a2f..a35c0ab0d7e8 100644 --- a/shared/applicability/system_with_kernel.yml +++ b/shared/applicability/system_with_kernel.yml @@ -17,29 +17,43 @@ title: Bare-metal systems, virtual machines, bootc container images, running boo check_id: system_with_kernel {{% if pkg_system == "rpm" %}} {{% if "sle" in product or "slmicro" in product %}} -bash_conditional: "rpm --quiet -q kernel-default || rpm --quiet -q kernel-default-base" +bash_conditional: >- + rpm --quiet -q kernel-default || + rpm --quiet -q kernel-default-base || + rpm --quiet -q kernel-azure {{% elif "ol" in families %}} bash_conditional: "rpm --quiet -q kernel || rpm --quiet -q kernel-uek" {{% elif product == "fedora" or "rhel" in product %}} bash_conditional: "rpm --quiet -q kernel-core" +{{% elif "amazon" in product or product == "al2023" %}} +bash_conditional: "rpm --quiet -q kernel || rpm --quiet -q kernel-modules" {{% else %}} bash_conditional: "rpm --quiet -q kernel" {{% endif %}} {{% else %}} {{% if "debian" in product or "ubuntu" in product %}} -bash_conditional: "dpkg-query --show --showformat='${db:Status-Status}' 'linux-base' 2>/dev/null | grep -q '^installed$'" +bash_conditional: >- + dpkg-query --show --showformat='${db:Status-Status}' 'linux-base' 2>/dev/null | + grep -q '^installed$' {{% else %}} -bash_conditional: "dpkg-query --show --showformat='${db:Status-Status}' 'kernel' 2>/dev/null | grep -q '^installed$'" +bash_conditional: >- + dpkg-query --show --showformat='${db:Status-Status}' 'kernel' 2>/dev/null | + grep -q '^installed$' {{% endif %}} {{% endif %}} {{% if "debian" in product or "ubuntu" in product %}} ansible_conditional: '"linux-base" in ansible_facts.packages' {{% elif "sle" in product or "slmicro" in product %}} -ansible_conditional: '("kernel-default" in ansible_facts.packages or "kernel-default-base" in ansible_facts.packages)' +ansible_conditional: >- + "kernel-default" in ansible_facts.packages or + "kernel-default-base" in ansible_facts.packages or + "kernel-azure" in ansible_facts.packages {{% elif "ol" in families %}} ansible_conditional: '("kernel" in ansible_facts.packages or "kernel-uek" in ansible_facts.packages)' {{% elif product == "fedora" or "rhel" in product %}} ansible_conditional: '"kernel-core" in ansible_facts.packages' +{{% elif "amazon" in product or product == "al2023" %}} +ansible_conditional: '("kernel" in ansible_facts.packages or "kernel-modules" in ansible_facts.packages)' {{% else %}} ansible_conditional: '"kernel" in ansible_facts.packages' {{% endif %}} diff --git a/shared/checks/oval/audit_rules_auditctl.xml b/shared/checks/oval/audit_rules_auditctl.xml index b08adf438882..27a4e5489599 100644 --- a/shared/checks/oval/audit_rules_auditctl.xml +++ b/shared/checks/oval/audit_rules_auditctl.xml @@ -18,7 +18,7 @@ -{{% if product in ['rhel10', 'ol10'] %}} +{{% if product in ['fedora', 'rhel10', 'ol10'] %}} /usr/lib/systemd/system/audit-rules.service ^ExecStart=\/sbin\/auditctl.*$ {{% else %}} diff --git a/shared/checks/oval/audit_rules_augenrules.xml b/shared/checks/oval/audit_rules_augenrules.xml index 7d651e43a0fb..7b46a1c9f136 100644 --- a/shared/checks/oval/audit_rules_augenrules.xml +++ b/shared/checks/oval/audit_rules_augenrules.xml @@ -21,15 +21,16 @@ {{% if product in ['rhel10', 'ol10'] %}} /usr/lib/systemd/system/audit-rules.service ^ExecStart=(\/usr|)?\/sbin\/augenrules.*$ + {{% elif product in ['fedora'] %}} + /usr/lib/systemd/system/audit-rules.service + ^ExecStart=\/usr\/bin\/augenrules.*$ + {{% elif product in ['debian13'] %}} + /usr/lib/systemd/system/audit-rules.service + ^ExecStart=\/usr\/sbin\/augenrules.*$ {{% else %}} - {{% if product in ['debian13'] %}} - /usr/lib/systemd/system/audit-rules.service - ^ExecStart=\/usr\/sbin\/augenrules.*$ - {{% else %}} - /usr/lib/systemd/system/auditd.service - ^(ExecStartPost=\-\/sbin\/augenrules.*$|Requires=augenrules.service) - {{% endif %}} -{{% endif %}} + /usr/lib/systemd/system/auditd.service + ^(ExecStartPost=\-\/sbin\/augenrules.*$|Requires=augenrules.service) + {{% endif %}} 1 diff --git a/shared/checks/oval/installed_OS_is_al2023.xml b/shared/checks/oval/installed_OS_is_al2023.xml index 0755643adbec..b3f751ae8d75 100644 --- a/shared/checks/oval/installed_OS_is_al2023.xml +++ b/shared/checks/oval/installed_OS_is_al2023.xml @@ -1,5 +1,5 @@ - + Amazon Linux 2023 @@ -8,36 +8,58 @@ The operating system installed on the system is Amazon Linux 2023 + - - - + + + + + - - - + + + - + + /etc/os-release - ^ID=\"(\w+)\"$ + ID="?amzn"? 1 - - amzn - - - - + + + + - + + /etc/os-release - ^VERSION_ID=\"(\w+)\"$ + VERSION_ID="?2023"? 1 - - 2023 - diff --git a/shared/checks/oval/installed_OS_is_hummingbird.xml b/shared/checks/oval/installed_OS_is_hummingbird.xml new file mode 100644 index 000000000000..da3b70d59ec8 --- /dev/null +++ b/shared/checks/oval/installed_OS_is_hummingbird.xml @@ -0,0 +1,34 @@ + + + + Installed operating system is hummingbird + + multi_platform_all + + + The operating system installed on the system is hummingbird + + + + + + + + + + + + + hummingbird-release.* + + + + + + + /etc/system-release-cpe + ^cpe:\/a:redhat:hummingbird:[\d]+$ + 1 + + + diff --git a/shared/checks/oval/sysctl_kernel_ipv6_disable.xml b/shared/checks/oval/sysctl_kernel_ipv6_disable.xml index b718ded260cc..5ed3e7e14415 100644 --- a/shared/checks/oval/sysctl_kernel_ipv6_disable.xml +++ b/shared/checks/oval/sysctl_kernel_ipv6_disable.xml @@ -3,24 +3,7 @@ Kernel Runtime Parameter IPv6 Check - multi_platform_alinux - multi_platform_almalinux - multi_platform_anolis - multi_platform_debian - multi_platform_example - multi_platform_fedora - multi_platform_kylinserver - multi_platform_openembedded - multi_platform_openeuler - multi_platform_opensuse - multi_platform_ol - multi_platform_rhcos - multi_platform_rhel - multi_platform_rhv - multi_platform_sle - multi_platform_slmicro - multi_platform_tencentos - multi_platform_ubuntu + multi_platform_all Disables IPv6 for all network interfaces. diff --git a/shared/macros/01-general.jinja b/shared/macros/01-general.jinja index 80dc6eeca5e3..190c833d79e0 100644 --- a/shared/macros/01-general.jinja +++ b/shared/macros/01-general.jinja @@ -774,8 +774,12 @@ substituting the correct package management software. #}} {{%- macro describe_package_install(package) -%}} +{{%- if product == "hummingbird" -%}} + The {{{ package }}} package needs to be present in the container or container image. +{{%- else -%}} The {{{ package }}} package can be installed with the following command:
{{{ package_install(package) }}}
+{{%- endif %}} {{%- endmacro %}} @@ -810,8 +814,13 @@ substituting the correct package management software. #}} {{%- macro describe_package_remove(package) -%}} +{{%- if product == "hummingbird" -%}} + The {{{ package }}} package should not be present in the container or container image. + Remove the {{{ package }}} package from Containerfile and rebuild the container image. +{{%- else -%}} The {{{ package }}} package can be removed with the following command:
{{{ package_remove(package) }}}
+{{%- endif %}} {{%- endmacro %}} @@ -825,8 +834,12 @@ substituting the correct package management software. #}} {{%- macro describe_file_permissions(file, perms) %}} +{{%- if product == "hummingbird" -%}} + The {{{ file }}} shall have the {{{ perms }}} permission mode. +{{%- else -%}} To properly set the permissions of {{{ file }}}, run the command:
$ sudo chmod {{{ perms }}} {{{ file }}}
+{{%- endif %}} {{%- endmacro %}} @@ -840,11 +853,17 @@ substituting the correct package management software. #}} {{%- macro describe_file_owner(file, owner) %}} +{{%- if product == "hummingbird" -%}} + The {{{ file }}} should be owned by the + {{%- for own in owner.split("|") %}} {{{ own }}} {{% if not loop.last %}} or {{% endif %}}{{% endfor -%}} + user. +{{%- else -%}} To properly set the owner of {{{ file }}}, run the command: {{% for own in owner.split("|") %}}
$ sudo chown {{{ own }}} {{{ file }}} 
{{% if not loop.last %}} or {{% endif %}} {{% endfor %}} +{{%- endif -%}} {{%- endmacro %}} {{# @@ -889,11 +908,17 @@ substituting the correct package management software. #}} {{%- macro describe_file_group_owner(file, group) %}} +{{%- if product == "hummingbird" -%}} + The {{{ file }}} should be group-owned by the + {{%- for grp in group.split("|") %}} {{{ grp }}} {{% if not loop.last %}} or {{% endif %}}{{% endfor -%}} + group. +{{%- else -%}} To properly set the group owner of {{{ file }}}, run the command: {{% for grp in group.split("|") %}}
$ sudo chgrp {{{ grp }}} {{{ file }}}
{{% if not loop.last %}} or {{% endif %}} {{% endfor %}} +{{%- endif %}} {{%- endmacro %}} {{# diff --git a/shared/macros/10-ansible.jinja b/shared/macros/10-ansible.jinja index 33417159b0a1..a5f61c720e09 100644 --- a/shared/macros/10-ansible.jinja +++ b/shared/macros/10-ansible.jinja @@ -163,23 +163,37 @@ value: :code:`Setting={{ varname1 }}` {{%- set dir_parameter = var_dir + "_has_parameter" -%}} {{%- set line_regex = prefix_regex + "{{ \"" + parameter + "\"| regex_escape }}" + separator_regex -%}} {{%- set find_when = dir_exists + ".stat.isdir is defined and " + dir_exists + ".stat.isdir" -%}} -{{%- set lineinfile_items = "{{ " + dir_parameter + ".files }}" -%}} +{{%- set lineinfile_items = "{{ " + dir_parameter + ".files | default([]) }}" -%}} {{%- set lineinfile_when = dir_parameter + ".matched > 0" -%}} {{%- set new_line = parameter + separator + value -%}} -- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured in {{{ config_file }}} + ansible.builtin.lineinfile: + path: {{{ config_file }}} + regexp: {{{ line_regex }}} + state: absent + check_mode: true + changed_when: false + register: _config_file_has_parameter +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured in {{{ config_dir }}} ansible.builtin.find: paths: - - {{{ config_file }}} - {{{ config_dir }}} contains: {{{ line_regex }}} - register: _sshd_config_has_parameter -- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured correctly + register: _config_dir_has_parameter +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured correctly in {{{ config_file }}} + ansible.builtin.lineinfile: + path: {{{ config_file }}} + regexp: {{{ line_regex ~ value ~ "$" }}} + state: absent + check_mode: true + changed_when: false + register: _config_file_correctly +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured correctly in {{{ config_dir }}} ansible.builtin.find: paths: - - {{{ config_file }}} - {{{ config_dir }}} contains: {{{ line_regex ~ value ~ "$" }}} - register: _sshd_config_correctly + register: _config_dir_correctly - name: '{{{ msg or rule_title }}}' block: {{{ ansible_lineinfile("Deduplicate values from " + config_file, config_file, regex=line_regex, insensitive=insensitive, create='no', state='absent')|indent }}} @@ -187,7 +201,7 @@ value: :code:`Setting={{ varname1 }}` {{{ ansible_find("Check if the parameter " + parameter + " is present in " + config_dir, paths=config_dir, contains=line_regex, register=dir_parameter, when=find_when)|indent }}} {{{ ansible_lineinfile("Remove parameter from files in " + config_dir, path="{{ item.path }}", regex=line_regex, insensitive=insensitive, state="absent", with_items=lineinfile_items, when=lineinfile_when)|indent }}} {{{ ansible_lineinfile("Insert correct line to " + set_file, set_file, regex=line_regex, insensitive=insensitive, new_line=new_line, create=create, state='present', validate=validate, insert_after=insert_after, insert_before=insert_before)|indent }}} - when: _sshd_config_correctly.matched == 0 or _sshd_config_has_parameter.matched != 1 + when: (_config_file_correctly.found == 0 and _config_dir_correctly.matched == 0) or ((_config_file_has_parameter.found | int) + (_config_dir_has_parameter.matched | int)) != 1 {{%- endmacro %}} @@ -198,7 +212,7 @@ value: :code:`Setting={{ varname1 }}` (but case-sensitive values). We also specify the validation program here; -t specifies test and -f allows Ansible to pass a file at a different path. - Set set a parameter in /etc/sshd_config or /etc/ssh/sshd_config.d/ + Set a parameter in ``sshd_main_config_file`` or ``sshd_config_dir``. :parameter msg: Message to be set as Task Title, if not set the rule's title will be used instead :type msg: str @@ -206,17 +220,20 @@ value: :code:`Setting={{ varname1 }}` :type parameter: str :parameter value: The value to set :type value: str -:parameter config_is_distributed: If true, will ok look in /etc/ssh/sshd_config.d +:parameter config_is_distributed: If true, use ``sshd_config_dir`` for configuration :type config_is_distributed: str :parameter config_basename: Filename of configuration file when using distributed configuration :type config_basename: str #}} -{{%- macro ansible_sshd_set(msg='', parameter='', value='', config_is_distributed="false", config_basename="00-complianceascode-hardening.conf", rule_title=None) %}} +{{%- macro ansible_sshd_set(msg='', parameter='', value='', config_is_distributed="false", config_basename="", rule_title=None) %}} +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set sshd_base_dir = sshd_config_base_dir -%}} {{% if product in ["ol8", "ol9"] %}} - name: "Find sshd_config included files" ansible.builtin.shell: |- - included_files=$(grep -oP "^\s*(?i)include.*" /etc/ssh/sshd_config | sed -e 's/\s*Include\s*//i' | sed -e 's|^[^/]|/etc/ssh/&|') + included_files=$(grep -oP "^\s*(?i)include.*" {{{ sshd_main_config }}} | sed -e 's/\s*Include\s*//i' | sed -e 's|^[^/]|{{{ sshd_base_dir }}}/&|') [[ -n $included_files ]] && ls $included_files || true register: sshd_config_included_files @@ -229,9 +246,10 @@ value: :code:`Setting={{ varname1 }}` {{% endif %}} {{%- if config_is_distributed == "true" %}} -{{% set config_dir = "/etc/ssh/sshd_config.d" %}} -{{% set config_file = "/etc/ssh/sshd_config.d" ~ "/" ~ config_basename %}} -{{{ ansible_set_config_file_dir(msg, config_file="/etc/ssh/sshd_config", config_dir=config_dir, set_file=config_file, parameter=parameter, separator_regex="\s+", value=value, prefix_regex="(?i)^\s*", create='yes', validate='/usr/sbin/sshd -t -f %s', insert_after='', insert_before="BOF", rule_title=rule_title) }}} +{{% set hardening_config_basename = config_basename or sshd_hardening_config_basename %}} +{{% set config_dir = sshd_drop_in_dir %}} +{{% set config_file = sshd_drop_in_dir ~ "/" ~ hardening_config_basename %}} +{{{ ansible_set_config_file_dir(msg, config_file=sshd_main_config, config_dir=config_dir, set_file=config_file, parameter=parameter, separator_regex="\s+", value=value, prefix_regex="(?i)^\s*", create='yes', validate='/usr/sbin/sshd -t -f %s', insert_after='', insert_before="BOF", rule_title=rule_title) }}} - name: {{{ rule_title }}} - set file mode for {{{ config_file }}} ansible.builtin.file: path: {{{ config_file }}} @@ -240,7 +258,7 @@ value: :code:`Setting={{ varname1 }}` modification_time: preserve access_time: preserve {{%- else %}} -{{{ ansible_set_config_file(msg, "/etc/ssh/sshd_config", parameter, value=value, create="yes", prefix_regex='(?i)^\s*', validate="/usr/sbin/sshd -t -f %s", insert_before="BOF", rule_title=rule_title) }}} +{{{ ansible_set_config_file(msg, sshd_main_config, parameter, value=value, create="yes", prefix_regex='(?i)^\s*', validate="/usr/sbin/sshd -t -f %s", insert_before="BOF", rule_title=rule_title) }}} {{%- endif %}} {{%- endmacro %}} @@ -829,6 +847,9 @@ The following macro remediates Audit syscall rule in :code:`/etc/audit/audit.rul with_items: - { path: /etc/sudoers } - "{{ sudoers.files }}" +{{% if product in [ 'sle16', 'slmicro6' ] %}} + when: not ansible_check_mode +{{% endif %}} {{%- endmacro -%}} @@ -926,9 +947,15 @@ The following macro remediates Audit syscall rule in :code:`/etc/audit/audit.rul #}} {{% macro ansible_authselect_force_reselect(rule_title=None) -%}} +- name: '{{{ rule_title }}} - Get current authselect profile' + ansible.builtin.command: + cmd: authselect current --raw + register: authselect_current_profile + changed_when: false + - name: '{{{ rule_title }}} - Force reselect authselect profile' - ansible.builtin.shell: - cmd: authselect select "$(authselect current --raw)" --force + ansible.builtin.command: + cmd: "authselect select {{ authselect_current_profile.stdout }} --force" {{%- endmacro %}} {{# @@ -1458,7 +1485,6 @@ The following macro remediates Audit syscall rule in :code:`/etc/audit/audit.rul {{{ ansible_remove_pam_module_option_configuration('/etc/pam.d/password-auth','auth','','pam_faillock.so',parameter, rule_title=rule_title) | indent(4) }}} when: - result_faillock_conf_check.stat.exists -{{%- endif %}} - name: {{{ rule_title }}} - Ensure the pam_faillock.so {{{ parameter }}} parameter in PAM files block: @@ -1538,6 +1564,7 @@ The following macro remediates Audit syscall rule in :code:`/etc/audit/audit.rul {{%- endif %}} when: - not result_faillock_conf_check.stat.exists +{{%- endif %}} {{%- endmacro -%}} {{# @@ -1595,49 +1622,58 @@ Part of the grub2_bootloader_argument template. #}} {{%- macro ansible_grub2_bootloader_argument(arg_name, arg_name_value, arg_variable) -%}} {{% if 'ubuntu' in product or 'debian' in product or product in ['ol7', 'sle12', 'sle15', 'sle16', 'slmicro5'] %}} -- name: Check {{{ arg_name }}} argument exists - ansible.builtin.command: grep '^\s*GRUB_CMDLINE_LINUX=.*{{{ arg_name }}}=' /etc/default/grub + +{{%- if 'ubuntu' in product %}} +{{%- set grub_vars = ['GRUB_CMDLINE_LINUX', 'GRUB_CMDLINE_LINUX_DEFAULT'] -%}} +{{%- else %}} +{{%- set grub_vars = ['GRUB_CMDLINE_LINUX'] -%}} +{{%- endif %}} + +{{%- for grub_var in grub_vars %}} +- name: Check {{{ arg_name }}} argument exists in {{{ grub_var }}} + ansible.builtin.command: grep '^\s*{{{ grub_var }}}=.*{{{ arg_name }}}=' /etc/default/grub check_mode: False failed_when: False changed_when: False - register: argcheck + register: argcheck_{{{ grub_var }}} -- name: Check {{{ arg_name }}} argument exists - ansible.builtin.command: grep '^\s*GRUB_CMDLINE_LINUX=' /etc/default/grub +- name: Check {{{ grub_var }}} line exists + ansible.builtin.command: grep '^\s*{{{ grub_var }}}=' /etc/default/grub check_mode: False failed_when: False changed_when: False - register: linecheck + register: linecheck_{{{ grub_var }}} -- name: Add {{{ arg_name }}} argument +- name: Add {{{ arg_name }}} argument to {{{ grub_var }}} ansible.builtin.lineinfile: - line: 'GRUB_CMDLINE_LINUX="{{{ arg_name_value }}} "' + line: '{{{ grub_var }}}="{{{ arg_name_value }}} "' state: present dest: /etc/default/grub create: yes mode: '0644' - when: argcheck is not skipped and linecheck is not skipped and argcheck.rc != 0 and linecheck.rc != 0 + when: argcheck_{{{ grub_var }}} is not skipped and linecheck_{{{ grub_var }}} is not skipped and argcheck_{{{ grub_var }}}.rc != 0 and linecheck_{{{ grub_var }}}.rc != 0 -- name: Replace existing {{{ arg_name }}} argument +- name: Replace existing {{{ arg_name }}} argument in {{{ grub_var }}} ansible.builtin.replace: path: /etc/default/grub - regexp: '{{{ arg_name }}}=[a-zA-Z0-9,]+' - replace: '{{{ arg_name_value }}}' - when: argcheck is not skipped and linecheck is not skipped and argcheck.rc == 0 and linecheck.rc == 0 + regexp: '(^\s*{{{ grub_var }}}=.*){{{ arg_name }}}=[a-zA-Z0-9,]+(.*)' + replace: '\1{{{ arg_name_value }}}\2' + when: argcheck_{{{ grub_var }}} is not skipped and linecheck_{{{ grub_var }}} is not skipped and argcheck_{{{ grub_var }}}.rc == 0 and linecheck_{{{ grub_var }}}.rc == 0 -- name: Add {{{ arg_name }}} argument +- name: Add {{{ arg_name }}} argument to {{{ grub_var }}} ansible.builtin.replace: path: /etc/default/grub - regexp: '(^\s*GRUB_CMDLINE_LINUX=.*)"' + regexp: '(^\s*{{{ grub_var }}}=.*)"' replace: '\1 {{{ arg_name_value }}}"' - when: argcheck is not skipped and linecheck is not skipped and argcheck.rc != 0 and linecheck.rc == 0 + when: argcheck_{{{ grub_var }}} is not skipped and linecheck_{{{ grub_var }}} is not skipped and argcheck_{{{ grub_var }}}.rc != 0 and linecheck_{{{ grub_var }}}.rc == 0 +{{%- endfor %}} {{% endif -%}} {{% if product in ['sle12', 'sle15', 'sle16', 'slmicro5'] %}} - name: Update grub defaults and the bootloader menu ansible.builtin.command: /usr/sbin/grub2-mkconfig -o {{{ grub2_boot_path }}}/grub.cfg -{{% elif 'debian' in product %}} +{{% elif 'debian' in product or 'ubuntu' in product %}} - name: Update grub defaults and the bootloader menu ansible.builtin.command: /usr/sbin/update-grub {{% else %}} @@ -2353,3 +2389,272 @@ Part of the grub2_bootloader_argument_absent template. ansible.builtin.shell: find /etc/rsyslog.d -type f -name "*.conf" -exec sed -i '/^{{{ start_pattern }}}/,/{{{ end_pattern }}}/d' {} + changed_when: true {{%- endmacro -%}} + +{{# +Macro for enabling dconf user profile in /etc/dconf/profile/ + +The macro adds the following lines to the profile: +--- +user-db:user +system-db: +--- +If the profile exists but does not contain the above lines, the +lines will be inserted at the beginning of the profile. + +:param profile: name of dconf profile (e.g. user, gdm) +:type profile: str +:param database: name of dconf database (e.g. local, gdm) +:type database: str +#}} +{{% macro ansible_enable_dconf_user_profile(profile, database) -%}} + +- name: "Configure GNOME3 DConf User Profile" + ansible.builtin.lineinfile: + path: "/etc/dconf/profile/{{{ profile }}}" + line: "{{ item }}" + create: yes + state: present + loop: + - "user-db:user" + - "system-db:{{{ database }}}" + register: dconf_user_profile_blockinfile + +- name: Dconf Update + ansible.builtin.command: dconf update + when: dconf_user_profile_blockinfile is changed +{{%- endmacro -%}} + + +{{# + + Set a sshd configuration parameter to a value for system with /usr - located default config + +:parameter msg: Message to be set as Task Title, if not set the rule's title will be used instead +:type msg: str +:parameter parameter: Parameter to set +:type parameter: str +:parameter value: The value to set +:type value: str +:param copy_defaults: If true default sshd configuration in /usr/etc/ssh/sshd_config will be +copied onto /etc/ssh/sshd_config, if /etc/ssh/sshd_config does not exist +:type copy_defaults: bool +:parameter config_basename: drop-in filename of sshd configuration file +:type config_basename: str + +#}} +{{%- macro ansible_sshd_set_usr(msg='', parameter='', value='', copy_defaults=true, config_basename="00-complianceascode-hardening.conf", rule_title=None) %}} +{{%- set sshd_config_path = "/etc/ssh/sshd_config" %}} +{{%- set sshd_usr_config_path = "/usr/etc/ssh/sshd_config" %}} +{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} +{{%- set sshd_usr_config_dir = "/usr/etc/ssh/sshd_config.d" -%}} +{{%- set ssh_paths = ['/etc/ssh/sshd_config.d', '/usr/etc/ssh/sshd_config.d'] -%}} +{{%- set config_file = "/etc/ssh/sshd_config.d/" ~ config_basename -%}} +{{%- set new_line = parameter + ' ' + value -%}} +{{%- set line_regex = "(?i)^\s*" + "{{ \"" + parameter + "\"| regex_escape }}" + "\s+" -%}} +{{%- set dir_parameter = "sshd_config_d_has_parameter" -%}} +{{%- set lineinfile_items = "{{ " + dir_parameter + ".files }}" -%}} + +- name: {{{ rule_title }}} - Copy default {{{ sshd_usr_config_path }}} to {{{ sshd_config_path }}} + ansible.builtin.copy: + src: {{{ sshd_usr_config_path }}} + dest: {{{ sshd_config_path }}} + force: no + mode: '0600' +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured in sshd configuration(s) + ansible.builtin.find: + paths: + - '/etc/ssh' + - '/usr/etc/ssh' + - {{{ sshd_config_dir }}} + - {{{ sshd_usr_config_dir }}} + contains: {{{ line_regex }}} + patterns: + - '*.conf' + - 'sshd_config' + register: _sshd_config_has_parameter +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured correctly in sshd configuration(s) + ansible.builtin.find: + paths: + - '/etc/ssh' + - '/usr/etc/ssh' + - {{{ sshd_config_dir }}} + - {{{ sshd_usr_config_dir }}} + contains: {{{ line_regex ~ value ~ "$" }}} + patterns: + - '*.conf' + - 'sshd_config' + register: _sshd_config_correctly +- name: '{{{ msg or rule_title }}}' + block: + {{{ ansible_lineinfile( + "Deduplicate values from " + sshd_config_path, + sshd_config_path, + regex=line_regex, + insensitive='false', + create='no', + state='absent')|indent }}} + {{{ ansible_lineinfile( + "Deduplicate values from " + sshd_usr_config_path, + sshd_usr_config_path, + regex=line_regex, + insensitive='false', + create='no', + state='absent')|indent }}} + - name: "{{{ rule_title }}} - Check if the parameter {{{ parameter }}} is present in {{{ sshd_config_dir }}} and in {{{ sshd_usr_config_dir }}}" + ansible.builtin.find: + paths: {{{ ssh_paths }}} + recurse: 'yes' + follow: 'no' + contains: '(?i)^\s*{{ "{{{ parameter }}}"| regex_escape }}\s+' + register: {{{ dir_parameter }}} + {{{ ansible_lineinfile( + "Remove parameter from files in " + sshd_config_dir, + path="{{ item.path }}", + regex=line_regex, + state="absent", + with_items=lineinfile_items)|indent}}} + {{{ ansible_lineinfile( + "Remove parameter from files in " + sshd_usr_config_dir, + path="{{ item.path }}", + regex=line_regex, + state="absent", + with_items=lineinfile_items)|indent }}} + {{{ ansible_lineinfile( + "Insert correct line to " + config_file, + config_file, + regex=line_regex, + insensitive='false', + new_line=new_line, + create='yes', + state='present', + validate='/usr/sbin/sshd -t -f %s', + insert_after='', + insert_before="BOF" )|indent }}} + when: _sshd_config_correctly.matched == 0 or _sshd_config_has_parameter.matched != 1 + +- name: {{{ rule_title }}} - set file mode for {{{ config_file }}} + ansible.builtin.file: + path: {{{ config_file }}} + mode: '0600' + state: touch + modification_time: preserve + access_time: preserve +{{%- endmacro %}} + + +{{# + copy source file to destination file if destination + does not exist + +:parameter source: source filename +:type source: str +:parameter destination: destination filename +:type destination: str + +#}} +{{% macro ansible_copy_distro_defaults(source, destination, rule_title) -%}} +- name: {{{ rule_title }}} - Copy distro defaults {{{ source }}} to {{{ destination }}} + ansible.builtin.copy: + src: {{{ source }}} + dest: {{{ destination }}} + force: no + mode: 'preserve' + remote_src: yes +{{%- endmacro %}} + +{{# + set parameter to value in /etc/login.defs.d/ drop in configuration + and remove parameter for user drop ins and main configuration + +:parameter parameter: parameter to set +:type parameter: str +:parameter value: value to set +:type value: str + +#}} + +{{%- macro ansible_login_defs(parameter='', value='', rule_title=None, cce='') %}} +{{%- set new_line = parameter + ' ' + value -%}} +{{%- set line_regex = "(?i)^\s*" + "{{ \"" + parameter + "\"| regex_escape }}" + "\s+" -%}} +{{%- set dir_parameter = "login_defs_d_has_parameter" -%}} +{{%- set lineinfile_items = "{{ " + dir_parameter + ".files }}" -%}} +{{%- set login_defs_config_dir = "/".join(login_defs_path.split("/")[:-1]) -%}} +{{%- set login_defs_d_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) -%}} +{{%- set login_defs_has_parameter = parameter + "_login_defs_has_parameter" -%}} +{{%- set login_defs_correctly = parameter + "_login_defs_correctly" -%}} + +{{% if product in ["sle16", "slmicro6"] %}} +{{{ ansible_copy_distro_defaults(login_defs_defaults_path, login_defs_path, rule_title) }}} +{{% endif %}} + +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured in login.defs configuration(s) + ansible.builtin.find: + paths: + - {{{ login_defs_config_dir }}} + - {{{ login_defs_d_config_dir }}} + contains: {{{ line_regex }}} + patterns: + - '*.defs' + register: {{{ login_defs_has_parameter }}} +- name: {{{ rule_title }}} - Check if the parameter {{{ parameter }}} is configured correctly in login.defs configuration(s) + ansible.builtin.find: + paths: + - {{{ login_defs_config_dir }}} + - {{{ login_defs_d_config_dir }}} + contains: '{{{ line_regex ~ value ~ "$" }}}' + patterns: + - '*.defs' + register: {{{ login_defs_correctly }}} +- name: '{{{ rule_title }}}' + block: + {{{ + ansible_lineinfile( + rule_title + " - Deduplicate values from " + login_defs_path, + login_defs_path, + regex=line_regex, + insensitive='false', + create='no', + state='absent' + )|indent + }}} + - name: "{{{ rule_title }}} - Check if the parameter {{{ parameter }}} is present in {{{ login_defs_d_config_dir }}}" + ansible.builtin.find: + paths: {{{ login_defs_d_config_dir }}} + recurse: 'yes' + follow: 'no' + contains: '(?i)^\s*{{ "{{{ parameter }}}"| regex_escape }}\s+' + patterns: + - '*.defs' + register: {{{ dir_parameter }}} + {{{ + ansible_lineinfile( + rule_title + " - Remove parameter from files in " + login_defs_d_config_dir, + path="{{ item.path }}", + regex=line_regex, + state="absent", + with_items=lineinfile_items + )|indent + }}} + {{{ + ansible_lineinfile( + rule_title + " - Insert correct line to " + login_defs_drop_in_path, + login_defs_drop_in_path, + regex=line_regex, + insensitive='false', + new_line=new_line, + create='yes', + state='present', + insert_after='', + insert_before="BOF" + )|indent + }}} + - name: "{{{ rule_title }}} - Add comment in {{{ login_defs_drop_in_path }}}" + ansible.builtin.lineinfile: + path: {{{ login_defs_drop_in_path }}} + line: '# Per {{{ cce }}} Set {{{ new_line }}} in {{{ login_defs_drop_in_path }}}' + state: present + insertbefore: {{{ new_line }}} + when: not ansible_check_mode + when: {{{ login_defs_correctly }}}.matched == 0 or {{{ login_defs_has_parameter }}}.matched != 1 + +{{%- endmacro %}} diff --git a/shared/macros/10-bash.jinja b/shared/macros/10-bash.jinja index 7a92cfd8cdb7..6b3f61ec3223 100644 --- a/shared/macros/10-bash.jinja +++ b/shared/macros/10-bash.jinja @@ -173,8 +173,9 @@ test "$(stat -c %d:%i /)" != "$(stat -c %d:%i /proc/1/root/.)" #}} {{%- macro bash_sshd_config_set(parameter, value, rule_id=None) -%}} +{{%- set sshd_config_path = sshd_main_config_file -%}} {{{ set_config_file( - path="/etc/ssh/sshd_config", + path=sshd_config_path, parameter=parameter, value=value, create=true, @@ -201,14 +202,15 @@ test "$(stat -c %d:%i /)" != "$(stat -c %d:%i /proc/1/root/.)" :type config_basename: str #}} -{{% macro bash_sshd_remediation(parameter, value, config_is_distributed="false", config_basename="00-complianceascode-hardening.conf", rule_id=None) -%}} -{{%- set sshd_config_path = "/etc/ssh/sshd_config" %}} -{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} +{{% macro bash_sshd_remediation(parameter, value, config_is_distributed="false", config_basename="", rule_id=None) -%}} +{{%- set sshd_config_path = sshd_main_config_file %}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set sshd_base_dir = sshd_config_base_dir -%}} {{% if product in ["ol8", "ol9"] %}} # Find the include keyword, extract from the line the glob expression representing included files. -# And if it is a relative path prepend '/etc/ssh/' -included_files=$(grep -oP "^\s*(?i)include.*" /etc/ssh/sshd_config | sed -e 's/\s*include\s*//I' | sed -e 's|^[^/]|/etc/ssh/&|') +# And if it is a relative path prepend '{{{ sshd_base_dir }}}/' +included_files=$(grep -oP "^\s*(?i)include.*" {{{ sshd_config_path }}} | sed -e 's/\s*include\s*//I' | sed -e 's|^[^/]|{{{ sshd_base_dir }}}/&|') for included_file in ${included_files} ; do {{{ lineinfile_absent("$included_file", "^\s*" ~ parameter, insensitive=true, rule_id=rule_id) | indent(4) }}} done @@ -216,15 +218,15 @@ done {{%- if config_is_distributed == "true" %}} {{%- set prefix_regex = "^\s*" -%}} {{%- set separator_regex = "\s\+" -%}} -{{%- set hardening_config_basename = config_basename %}} +{{%- set hardening_config_basename = config_basename or sshd_hardening_config_basename %}} {{%- set line_regex = prefix_regex ~ parameter ~ separator_regex %}} -mkdir -p {{{ sshd_config_dir }}} -touch {{{ sshd_config_dir }}}/{{{ hardening_config_basename }}} -chmod 0600 {{{ sshd_config_dir }}}/{{{ hardening_config_basename }}} +mkdir -p {{{ sshd_drop_in_dir }}} +touch {{{ sshd_drop_in_dir }}}/{{{ hardening_config_basename }}} +chmod 0600 {{{ sshd_drop_in_dir }}}/{{{ hardening_config_basename }}} {{{ lineinfile_absent(sshd_config_path, line_regex, insensitive=true, rule_id=rule_id) }}} -{{{ lineinfile_absent_in_directory(sshd_config_dir, line_regex, insensitive=true, filename_glob="*.conf") }}} +{{{ lineinfile_absent_in_directory(sshd_drop_in_dir, line_regex, insensitive=true, filename_glob="*.conf") }}} {{{ set_config_file( - path=sshd_config_dir ~ "/" ~ hardening_config_basename, + path=sshd_drop_in_dir ~ "/" ~ hardening_config_basename, parameter=parameter, value=value, create=true, @@ -500,7 +502,9 @@ fi {{%- elif pkg_manager == "apt_get" -%}} DEBIAN_FRONTEND=noninteractive apt-get -o DPkg::Lock::Timeout=60 remove -y "{{{ package }}}" {{%- elif pkg_manager == "zypper" -%}} -zypper remove -y "{{{ package }}}" +if rpm -q --quiet "{{{ package }}}" ; then + zypper remove -y "{{{ package }}}" +fi {{%- else -%}} {{{ die("Can't generate a remediation for " + pkg_manager) }}} {{%- endif -%}} @@ -807,7 +811,7 @@ pam_file="/etc/pam.d/common-auth" if ! grep -qE '^\s*auth\s+required\s+pam_faillock\.so\s+preauth.*$' "$pam_file" ; then {{% if product in ['sle15', 'sle16'] %}} # insert before pam_unix.so - sed -i --follow-symlinks '/^auth.*required.*pam_unix\.so.*/i auth required pam_faillock.so preauth' "$pam_file" + sed -i --follow-symlinks '/^auth.*pam_unix\.so.*/i auth required pam_faillock.so preauth' "$pam_file" {{% else %}} # insert at the top sed -i --follow-symlinks '/^# here are the per-package modules/i auth required pam_faillock.so preauth' "$pam_file" @@ -844,6 +848,19 @@ if ! grep -qE '^\s*account\s+required\s+pam_faillock\.so.*$' "$pam_file" ; then echo 'account required pam_faillock.so' >> "$pam_file" {{% endif %}} fi + +{{% if product in ['sle15', 'sle16'] %}} +{{{ + bash_ensure_pam_module_configuration( + '/etc/pam.d/common-auth', + 'auth', + 'sufficient', + 'pam_unix.so', + '', + '', + '') +}}} +{{% endif %}} {{% elif 'ubuntu' in product %}} conf_name=cac_faillock @@ -1308,7 +1325,13 @@ fi {{% if sed_path_separator in regex %}} {{{ raise("regex (" + regex + ") uses sed path separator (" + sed_path_separator + ") in " + rule_id) }}} {{% endif %}} -LC_ALL=C sed -i "{{{ sed_path_separator }}}{{{ regex }}}{{{ sed_path_separator }}}{{{ modifier }}}" "{{{ path }}}" + {{%- if sed_path_separator != "/" -%}} + # non default delimiter with delete operation needs to be escaped + LC_ALL=C sed -i "\{{{ sed_path_separator }}}{{{ regex }}}{{{ sed_path_separator }}}{{{ modifier }}}" "{{{ path }}}" + {{%- else -%}} + LC_ALL=C sed -i "{{{ sed_path_separator }}}{{{ regex }}}{{{ sed_path_separator }}}{{{ modifier }}}" "{{{ path }}}" + {{%- endif -%}} + {{%- endmacro -%}} @@ -1947,18 +1970,26 @@ fi #}} {{%- macro update_etc_default_grub_manually(arg_name, arg_name_value) -%}} +{{%- if 'ubuntu' in product -%}} +{{%- set grub_vars = ['GRUB_CMDLINE_LINUX', 'GRUB_CMDLINE_LINUX_DEFAULT'] -%}} +{{%- else -%}} +{{%- set grub_vars = ['GRUB_CMDLINE_LINUX'] -%}} +{{%- endif -%}} + # Correct the form of default kernel command line in GRUB -if grep -q '^\s*GRUB_CMDLINE_LINUX=.*{{{ arg_name }}}=.*"' '/etc/default/grub' ; then - # modify the GRUB command-line if an {{{ arg_name }}}= arg already exists - sed -i "s/\(^\s*GRUB_CMDLINE_LINUX=\".*\){{{ arg_name }}}=[^[:space:]]\+\(.*\"\)/\1{{{ arg_name_value }}}\2/" '/etc/default/grub' -# Add to already existing GRUB_CMDLINE_LINUX parameters -elif grep -q '^\s*GRUB_CMDLINE_LINUX=' '/etc/default/grub' ; then - # no {{{ arg_name }}}=arg is present, append it - sed -i "s/\(^\s*GRUB_CMDLINE_LINUX=\".*\)\"/\1 {{{ arg_name_value }}}\"/" '/etc/default/grub' -# Add GRUB_CMDLINE_LINUX parameters line +{{%- for grub_var in grub_vars %}} +if grep -q '^\s*{{{ grub_var }}}=.*{{{ arg_name }}}=.*\"' '/etc/default/grub' ; then + # modify the GRUB command-line if an {{{ arg_name }}}= arg already exists + sed -i 's/\(^\s*{{{ grub_var }}}=".*\){{{ arg_name }}}=[^[:space:]]\+\(.*"\)/\1{{{ arg_name_value }}}\2/' '/etc/default/grub' +# Add to already existing parameters +elif grep -q '^\s*{{{ grub_var }}}=' '/etc/default/grub' ; then + # no {{{ arg_name }}}=arg is present, append it + sed -i 's/\(^\s*{{{ grub_var }}}=".*\)"/\1 {{{ arg_name_value }}}"/' '/etc/default/grub' +# Add parameters line if completely missing else - echo "GRUB_CMDLINE_LINUX=\"{{{ arg_name_value }}}\"" >> '/etc/default/grub' + echo '{{{ grub_var }}}="{{{ arg_name_value }}}"' >> '/etc/default/grub' fi +{{%- endfor %}} {{%- endmacro %}} @@ -2253,23 +2284,23 @@ for f in $(echo -n "{{{ files }}}"); do fi # find key in section and change value - if grep -qzosP "[[:space:]]*\[{{{ section }}}\]([^\n\[]*\n+)+?[[:space:]]*{{{ key }}}" "$f"; then - if ! grep -qPz "{{{ key }}}={{{ value }}}" "$f"; then + if grep -qzosP "(?m)^[[:space:]]*\[{{{ section }}}\]([^\n\[]*\n+)+?[[:space:]]*{{{ key }}}" "$f"; then + if ! grep -qzosP "(?m)^[[:space:]]*{{{ key }}}[[:space:]]*=[[:space:]]*{{{ value }}}" "$f"; then {{% if no_quotes %}} - sed -i "s/{{{ key }}}[^(\n)]*/{{{ key }}}={{{ value | replace("/", "\/") }}}/" "$f" + sed -i "/^[[:space:]]*{{{ key }}}/s/\([[:blank:]]*=[[:blank:]]*\).*/\1{{{ value | replace("/", "\/") }}}/" "$f" {{% else %}} - sed -i 's/{{{ key }}}[^(\n)]*/{{{ key }}}="{{{ value | replace("/", "\/") }}}"/' "$f" + sed -i '/^[[:space:]]*{{{ key }}}/s/\([[:blank:]]*=[[:blank:]]*\).*/\1"{{{ value | replace("/", "\/") }}}"/' "$f" {{% endif %}} fi found=true # find section and add key = value to it - elif grep -qs "[[:space:]]*\[{{{ section }}}\]" "$f"; then + elif grep -qs "^[[:space:]]*\[{{{ section }}}\]" "$f"; then {{% if no_quotes %}} - sed -i "/[[:space:]]*\[{{{ section }}}\]/a {{{ key }}}={{{ value | replace("/", "\/") }}}" "$f" + sed -i "/^[[:space:]]*\[{{{ section }}}\]/a {{{ key }}}={{{ value | replace("/", "\/") }}}" "$f" {{% else %}} - sed -i '/[[:space:]]*\[{{{ section }}}\]/a {{{ key }}}="{{{ value | replace ("/", "\/") }}}"' "$f" + sed -i '/^[[:space:]]*\[{{{ section }}}\]/a {{{ key }}}="{{{ value | replace ("/", "\/") }}}"' "$f" {{% endif %}} found=true fi @@ -2459,7 +2490,8 @@ fi #}} {{% macro bash_authselect_force_reselect() -%}} -authselect select "$(authselect current --raw)" --force +read -ra authselect_args < <(authselect current --raw) +authselect select "${authselect_args[@]}" --force {{%- endmacro %}} @@ -2569,6 +2601,7 @@ if [ -e "{{{ pam_file }}}" ] ; then else echo "{{{ pam_file }}} was not found" >&2 fi + {{%- endmacro -%}} @@ -2746,3 +2779,100 @@ This macro creates a Bash conditional which checks the system architecture in /p {{%- macro bash_arch_conditional(arch) -%}} ( grep -sqE "^.*\.{{{ arch }}}$" /proc/sys/kernel/osrelease || grep -sqE "^{{{ arch }}}$" /proc/sys/kernel/arch; ) {{%- endmacro -%}} + + +{{# + Set a sshd configuration parameter to a value for system with default configuration in /usr subdir + +:parameter parameter: Parameter to set +:type parameter: str +:parameter value: The value to set +:type value: str +:param copy_defaults: If true default sshd configuration in /usr/etc/ssh/sshd_config will be +copied onto /etc/ssh/sshd_config, if /etc/ssh/sshd_config does not exist +:type copy_defaults: bool +:parameter config_basename: drop-in filename of sshd configuration file +:type config_basename: str + +#}} +{{% macro bash_sshd_remediation_usr(parameter, value, copy_defaults="true", config_basename="00-complianceascode-hardening.conf", rule_id=None) -%}} +{{%- set sshd_config_path = "/etc/ssh/sshd_config" %}} +{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} +{{%- set sshd_usr_config_path = "/usr/etc/ssh/sshd_config" %}} +{{%- set sshd_usr_config_dir = "/usr/etc/ssh/sshd_config.d" -%}} +{{%- set prefix_regex = "^\s*" -%}} +{{%- set separator_regex = "\s\+" -%}} +{{%- set hardening_config_basename = config_basename %}} +{{%- set line_regex = prefix_regex ~ parameter ~ separator_regex %}} + +if ! [ -e "{{{ sshd_config_path }}}" ] ; then + cp "{{{ sshd_usr_config_path }}}" "{{{ sshd_config_path }}}" +fi + +mkdir -p {{{ sshd_config_dir }}} +touch {{{ sshd_config_dir }}}/{{{ hardening_config_basename }}} +chmod 0600 {{{ sshd_config_dir }}}/{{{ hardening_config_basename }}} +{{{ lineinfile_absent(sshd_config_path, line_regex, insensitive=true, rule_id=rule_id) }}} +{{{ lineinfile_absent_in_directory(sshd_config_dir, line_regex, insensitive=true, filename_glob="*.conf") }}} +{{{ lineinfile_absent(sshd_usr_config_path, line_regex, insensitive=true, rule_id=rule_id) }}} +{{{ lineinfile_absent_in_directory(sshd_usr_config_dir, line_regex, insensitive=true, filename_glob="*.conf") }}} +{{{ set_config_file( + path=sshd_config_dir ~ "/" ~ hardening_config_basename, + parameter=parameter, + value=value, + create=true, + insert_after="", + insert_before="BOF", + insensitive=true, + separator=" ", + separator_regex=separator_regex, + prefix_regex=prefix_regex, rule_id=rule_id) + }}} +{{%- endmacro %}} + + + +{{# + copy source file to destination file if destination + does not exist + +:parameter source: source filename +:type source: str +:parameter destination: destination filename +:type destination: str + +#}} +{{% macro bash_copy_distro_defaults(source, destination) -%}} + +{{% if product in ["sle16", "slmicro6"] %}} +if ! [ -e "{{{ destination }}}" ] ; then + cp -p "{{{ source }}}" "{{{ destination }}}" +fi +{{% endif %}} +{{%- endmacro %}} + +{{# + set parameter to value in /etc/login.defs.d/ drop in configuration + and remove parameter for user drop ins and main configuration + +:parameter parameter: parameter to set +:type parameter: str +:parameter value: value to set +:type value: str + +#}} + +{{%- macro bash_login_defs(parameter, value, cce_identifiers) %}} + +{{%- set line_regex_absent = "^\s*" + parameter + "\s\+" -%}} +{{%- set line_regex_replace = "^" + parameter -%}} +{{%- set login_defs_d_config_dir = "/".join(login_defs_drop_in_path.split("/")[:-1]) -%}} + +{{% if product in [ 'slmicro6', 'sle16' ] %}} +{{{ bash_copy_distro_defaults(login_defs_defaults_path, login_defs_path) }}} +{{% endif %}} + +{{{ lineinfile_absent_in_directory(login_defs_d_config_dir, line_regex_absent, filename_glob="*.defs") }}} +{{{ bash_replace_or_append(login_defs_drop_in_path, line_regex_replace, value, '%s %s', cce_identifiers=cce_identifiers) }}} + +{{%- endmacro %}} diff --git a/shared/macros/10-fixtext.jinja b/shared/macros/10-fixtext.jinja index 1ecca316fe66..ebba0ef3a26b 100644 --- a/shared/macros/10-fixtext.jinja +++ b/shared/macros/10-fixtext.jinja @@ -233,10 +233,12 @@ The audit daemon must be restarted for the changes to take effect. #}} {{%- macro fixtext_sshd_lineinfile(parameter, value, config_is_distributed) -%}} +{{%- set sshd_main_config = sshd_main_config_file -%}} +{{%- set sshd_hardening_config = sshd_config_dir ~ "/" ~ sshd_hardening_config_basename -%}} {{%- if config_is_distributed -%}} -{{%- set path = "/etc/ssh/sshd_config.d/00-complianceascode-hardening.conf" -%}} +{{%- set path = sshd_hardening_config -%}} {{%- else -%}} -{{%- set path = "/etc/ssh/sshd_config" -%}} +{{%- set path = sshd_main_config -%}} {{%- endif -%}} To configure the system add or modify the following line in "{{{ path }}}". diff --git a/shared/macros/10-kubernetes.jinja b/shared/macros/10-kubernetes.jinja index 15a7eea15294..a3fd31a9ae82 100644 --- a/shared/macros/10-kubernetes.jinja +++ b/shared/macros/10-kubernetes.jinja @@ -643,7 +643,7 @@ spec: storage: files: - contents: - source: data:,{{ %23%20Allow%20for%20extra%20configuration%20files.%20This%20is%20useful%0A%23%20for%20admins%20specifying%20their%20own%20NTP%20servers%0Ainclude%20/etc/chrony.d/%2A.conf%0A%0A%23%20Set%20chronyd%20as%20client-only.%0Aport%200%0A%0A%23%20Disable%20chronyc%20from%20the%20network%0Acmdport%200%0A%0A%23%20Record%20the%20rate%20at%20which%20the%20system%20clock%20gains/losses%20time.%0Adriftfile%20/var/lib/chrony/drift%0A%0A%23%20Allow%20the%20system%20clock%20to%20be%20stepped%20in%20the%20first%20three%20updates%0A%23%20if%20its%20offset%20is%20larger%20than%201%20second.%0Amakestep%201.0%203%0A%0A%23%20Enable%20kernel%20synchronization%20of%20the%20real-time%20clock%20%28RTC%29.%0Artcsync%0A%0A%23%20Enable%20hardware%20timestamping%20on%20all%20interfaces%20that%20support%20it.%0A%23hwtimestamp%20%2A%0A%0A%23%20Increase%20the%20minimum%20number%20of%20selectable%20sources%20required%20to%20adjust%0A%23%20the%20system%20clock.%0A%23minsources%202%0A%0A%23%20Allow%20NTP%20client%20access%20from%20local%20network.%0A%23allow%20192.168.0.0/16%0A%0A%23%20Serve%20time%20even%20if%20not%20synchronized%20to%20a%20time%20source.%0A%23local%20stratum%2010%0A%0A%23%20Require%20authentication%20%28nts%20or%20key%20option%29%20for%20all%20NTP%20sources.%0A%23authselectmode%20require%0A%0A%23%20Specify%20file%20containing%20keys%20for%20NTP%20authentication.%0Akeyfile%20/etc/chrony.keys%0A%0A%23%20Insert/delete%20leap%20seconds%20by%20slewing%20instead%20of%20stepping.%0A%23leapsecmode%20slew%0A%0A%23%20Get%20TAI-UTC%20offset%20and%20leap%20seconds%20from%20the%20system%20tz%20database.%0Aleapsectz%20right/UTC%0A%0A%23%20Specify%20directory%20for%20log%20files.%0Alogdir%20/var/log/chrony%0A%0A%23%20Select%20which%20information%20is%20logged.%0A%23log%20measurements%20statistics%20tracking }} + source: data:,{{ %23%20Allow%20for%20extra%20configuration%20files.%20This%20is%20useful%0A%23%20for%20admins%20specifying%20their%20own%20NTP%20servers%0Aconfdir%20/etc/chrony.d%0A%0A%23%20Set%20chronyd%20as%20client-only.%0Aport%200%0A%0A%23%20Disable%20chronyc%20from%20the%20network%0Acmdport%200%0A%0A%23%20Record%20the%20rate%20at%20which%20the%20system%20clock%20gains/losses%20time.%0Adriftfile%20/var/lib/chrony/drift%0A%0A%23%20Allow%20the%20system%20clock%20to%20be%20stepped%20in%20the%20first%20three%20updates%0A%23%20if%20its%20offset%20is%20larger%20than%201%20second.%0Amakestep%201.0%203%0A%0A%23%20Enable%20kernel%20synchronization%20of%20the%20real-time%20clock%20%28RTC%29.%0Artcsync%0A%0A%23%20Enable%20hardware%20timestamping%20on%20all%20interfaces%20that%20support%20it.%0A%23hwtimestamp%20%2A%0A%0A%23%20Increase%20the%20minimum%20number%20of%20selectable%20sources%20required%20to%20adjust%0A%23%20the%20system%20clock.%0A%23minsources%202%0A%0A%23%20Allow%20NTP%20client%20access%20from%20local%20network.%0A%23allow%20192.168.0.0/16%0A%0A%23%20Serve%20time%20even%20if%20not%20synchronized%20to%20a%20time%20source.%0A%23local%20stratum%2010%0A%0A%23%20Require%20authentication%20%28nts%20or%20key%20option%29%20for%20all%20NTP%20sources.%0A%23authselectmode%20require%0A%0A%23%20Specify%20file%20containing%20keys%20for%20NTP%20authentication.%0Akeyfile%20/etc/chrony.keys%0A%0A%23%20Insert/delete%20leap%20seconds%20by%20slewing%20instead%20of%20stepping.%0A%23leapsecmode%20slew%0A%0A%23%20Get%20TAI-UTC%20offset%20and%20leap%20seconds%20from%20the%20system%20tz%20database.%0Aleapsectz%20right/UTC%0A%0A%23%20Specify%20directory%20for%20log%20files.%0Alogdir%20/var/log/chrony%0A%0A%23%20Select%20which%20information%20is%20logged.%0A%23log%20measurements%20statistics%20tracking }} mode: 420 overwrite: true path: /etc/chrony.conf diff --git a/shared/macros/10-ocil.jinja b/shared/macros/10-ocil.jinja index ab94d0956921..cd398e7c370f 100644 --- a/shared/macros/10-ocil.jinja +++ b/shared/macros/10-ocil.jinja @@ -26,10 +26,12 @@ $ oc get {{% if all_namespaces %}}--all-namespaces{{% elif namespace %}}-n {{{ n {{% macro sshd_config_file() %}} + {{% set sshd_main_config = sshd_main_config_file %}} + {{% set sshd_hardening_config = sshd_config_dir ~ "/" ~ sshd_hardening_config_basename %}} {{% if sshd_distributed_config == "true" %}} - /etc/ssh/sshd_config.d/00-complianceascode-hardening.conf: + {{{ sshd_hardening_config }}}: {{% else %}} - /etc/ssh/sshd_config: + {{{ sshd_main_config }}}: {{% endif %}} {{%- endmacro %}} @@ -165,105 +167,63 @@ ocil: | {{%- endmacro %}} -{{# Package macros #}} +{{# Package macros -#}} {{# - Describe how to check if a package is installed with rpm. - -:param package: The package to check -:type package: str - -#}} -{{%- macro rpm_ocil_package(package) -%}} - Run the following command to determine if the {{{ package }}} package is installed: -
$ rpm -q {{{ package }}}
-{{%- endmacro -%}} - - -{{# - Describe how to check if a package is installed with dpkg. - -:param package: The package to check -:type package: str + OCIL entry with instructions how to check if a package is installed + :param package: Package name + :type package: str #}} -{{%- macro dpkg_ocil_package(package) %}} - Run the following command to determine if the {{{ package }}} package is installed: -
$ dpkg -l  {{{ package }}}
-{{%- endmacro %}} - - -{{# - Insert general ocil clause to check if a package is installed, substituting the - correct package management software. - -:param package: Name of package -:type package: str - -#}} -{{% macro ocil_package(package) -%}} - {{% if pkg_system is defined %}} - {{%- if pkg_system == "rpm" -%}} - {{{ rpm_ocil_package(package) }}} - {{%- elif pkg_system == "dpkg" -%}} - {{{ dpkg_ocil_package(package) }}} - {{%- else -%}} -JINJA MACRO ERROR - Unknown package system '{{{ pkg_system }}}'. - {{%- endif -%}} +{{%- macro ocil_package_installed_how_to_check(package) -%}} +ocil: |- + {{% if pkg_system is undefined or pkg_system not in ["rpm", "dpkg"] -%}} + JINJA MACRO ERROR - Unknown package system '{{{ pkg_system | default("undefined") }}}'. Has to be either 'rpm' or 'dpkg'. + {{%- else -%}} + Run the following command to determine if the {{{ package }}} package is installed:
$ {{% if pkg_system == "rpm" %}}rpm -q {{% elif pkg_system == "dpkg" %}}dpkg -l {{% endif %}}{{{ package }}}
{{%- endif -%}} -{{%- endmacro %}} +{{% endmacro -%}} {{# - OCIL and OCIL clause how to check if a package is installed with rpm. - -:param package: The package to check -:type package: str + Set ocil_clause - a finding: when the rule expects the package to be: + - absent, a finding is an installed package. + - present, a finding is an absent package. + :param package: Package name + :type package: str + :param clause_predicate: "not installed" if the rule requires the package to be installed + and "installed" if it must be absent. + :type clause_predicate: str #}} -{{%- macro rpm_complete_ocil_entry_package(package) %}} -ocil: |- - {{{ rpm_ocil_package(package) }}} - -ocil_clause: "the package is installed" -{{%- endmacro %}} +{{%- macro ocil_clause_package(package, clause_predicate) -%}} +ocil_clause: "the {{{ package }}} package is {{{ clause_predicate }}}" +{{% endmacro -%}} {{# - OCIL and OCIL clause how to check if a package is installed with dpkg. - -:param package: The package to check -:type package: str - -#}} -{{%- macro dpkg_complete_ocil_entry_package(package) %}} -ocil: |- - {{{ dpkg_ocil_package(package) }}} - -ocil_clause: "the package is installed" -{{%- endmacro %}} - + OCIL complete entries (ocil_clause: followed by ocil:) for package install/remove rules. -{{# - Insert a complete OCIL block for a case when a package should be removed, - substituting the correct package management software. + complete_ocil_entry_package_installed(package) + Use when the rule requires the package to be installed. The finding is + that the package is not installed. -:param package: Name of package -:type package: str + complete_ocil_entry_package_removed(package) + Use when the rule requires the package to be absent. The finding is + that the package is still installed. + :param package: Package name + :type package: str #}} -{{% macro complete_ocil_entry_package(package) -%}} - {{% if pkg_system is defined %}} - {{%- if pkg_system == "rpm" %}} - {{{ rpm_complete_ocil_entry_package(package) }}} - {{%- elif pkg_system == "dpkg" %}} - {{{ dpkg_complete_ocil_entry_package(package) }}} - {{%- else -%}} -ocil: |- - JINJA MACRO ERROR - Unknown package system '{{{ pkg_system }}}'. - {{%- endif -%}} - {{%- endif -%}} -{{%- endmacro %}} +{{%- macro complete_ocil_entry_package_installed(package) %}} +{{{ ocil_clause_package(package, "not installed") }}} +{{{ ocil_package_installed_how_to_check(package) }}} +{{% endmacro -%}} + +{{%- macro complete_ocil_entry_package_removed(package) %}} +{{{ ocil_clause_package(package, "installed") }}} +{{{ ocil_package_installed_how_to_check(package) }}} +{{% endmacro -%}} {{# Service Enabled macros #}} @@ -509,14 +469,17 @@ ocil_clause: "the required value is not set" #}} {{% macro ocil_sshd_option(default, option, value) -%}} + {{% set sshd_main_config = sshd_main_config_file %}} + {{% set sshd_hardening_config = sshd_config_dir ~ "/" ~ sshd_hardening_config_basename %}} + {{% set sshd_reinforce_defaults_config = sshd_config_dir ~ "/01-complianceascode-reinforce-os-defaults.conf" %}} To determine how the SSH daemon's {{{ option }}} option is set, run the following command: {{% if sshd_distributed_config == "true" %}} -
$ sudo grep -i {{{ option }}} /etc/ssh/sshd_config.d/00-complianceascode-hardening.conf
+
$ sudo grep -i {{{ option }}} {{{ sshd_hardening_config }}}
{{% if default == "yes" -%}} -
$ sudo grep -i {{{ option }}} /etc/ssh/sshd_config.d/01-complianceascode-reinforce-os-defaults.conf
+
$ sudo grep -i {{{ option }}} {{{ sshd_reinforce_defaults_config }}}
{{%- endif %}} {{% else %}} -
$ sudo grep -i {{{ option }}} /etc/ssh/sshd_config
+
$ sudo grep -i {{{ option }}} {{{ sshd_main_config }}}
{{% endif %}} If a line indicating {{{ value }}} is returned, then the required value is set. {{%- endmacro %}} diff --git a/shared/macros/10-oval.jinja b/shared/macros/10-oval.jinja index 6466728189db..fdea8f3d0d5c 100644 --- a/shared/macros/10-oval.jinja +++ b/shared/macros/10-oval.jinja @@ -1034,16 +1034,17 @@ Generates the :code:`` tag for OVAL check using correct product platfo #}} {{%- macro sshd_oval_check(parameter, value, missing_parameter_pass, config_is_distributed, runtime_check="false", xccdf_variable="", datatype="", rule_id=None, rule_title=None) -%}} -{{%- set sshd_config_path = "/etc/ssh/sshd_config" %}} -{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} +{{%- set sshd_main_config = sshd_main_config_file %}} +{{%- set sshd_drop_in_dir = sshd_config_dir -%}} +{{%- set sshd_base_dir = sshd_config_base_dir -%}} {{%- set sshd_runtime_path = "/tmp/runtime/sshd_effective_config" -%}} {{%- if xccdf_variable -%}} -{{%- set description = "Ensure '" ~ parameter ~ "' is configured with value configured in " ~ xccdf_variable ~ " variable in " ~ sshd_config_path %}} +{{%- set description = "Ensure '" ~ parameter ~ "' is configured with value configured in " ~ xccdf_variable ~ " variable in " ~ sshd_main_config %}} {{%- else -%}} -{{%- set description = "Ensure '" ~ parameter ~ "' is configured with value '" ~ value ~ "' in " ~ sshd_config_path %}} +{{%- set description = "Ensure '" ~ parameter ~ "' is configured with value '" ~ value ~ "' in " ~ sshd_main_config %}} {{%- endif -%}} {{%- if config_is_distributed == "true" %}} -{{%- set description = description ~ " or in " ~ sshd_config_dir -%}} +{{%- set description = description ~ " or in " ~ sshd_drop_in_dir -%}} {{%- endif %}} {{%- set case_insensitivity_kwargs = dict(prefix_regex="^[ \\t]*(?i)", separator_regex = "(?-i)[ \\t]+") -%}} @@ -1081,10 +1082,10 @@ Generates the :code:`` tag for OVAL check using correct product platfo {{%- endif %}} {{%- if runtime_check != "true" %}} - - {{{- oval_line_in_file_criterion(sshd_config_path, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12)}}} + + {{{- oval_line_in_file_criterion(sshd_main_config, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12)}}} {{%- if config_is_distributed == "true" %}} - {{{- oval_line_in_directory_criterion(sshd_config_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12) }}} + {{{- oval_line_in_directory_criterion(sshd_drop_in_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12) }}} {{%- endif %}} {{% if product in ["ol8", "ol9"] %}} {{{- oval_line_in_file_criterion("sshd_config included", parameter, id_stem=rule_id ~ "_sshd_included_files", avoid_conflicting=true, rule_id=rule_id) | indent(12)}}} @@ -1105,11 +1106,11 @@ Generates the :code:`` tag for OVAL check using correct product platfo {{% endif %}} {{% if product in ["ol8", "ol9"] %}} - {{{ oval_line_in_file_object(sshd_config_path, parameter="include", id_stem="sshd_include_value_" ~ rule_id, rule_id=rule_id, ** case_insensitivity_kwargs)| indent (2) }}} + {{{ oval_line_in_file_object(sshd_main_config, parameter="include", id_stem="sshd_include_value_" ~ rule_id, rule_id=rule_id, ** case_insensitivity_kwargs)| indent (2) }}} - ^(/etc/ssh/(?!/))? + ^({{{ sshd_base_dir }}}/(?!/))? @@ -1136,8 +1137,8 @@ Generates the :code:`` tag for OVAL check using correct product platfo {{% endif %}} - {{{ oval_line_in_file_test(sshd_config_path, parameter, avoid_conflicting=true, rule_id=rule_id) | indent (2) }}} - {{{ oval_line_in_file_object(sshd_config_path, parameter=parameter, rule_id=rule_id, ** case_insensitivity_kwargs)| indent (2) }}} + {{{ oval_line_in_file_test(sshd_main_config, parameter, avoid_conflicting=true, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_file_object(sshd_main_config, parameter=parameter, rule_id=rule_id, ** case_insensitivity_kwargs)| indent (2) }}} {{%- if xccdf_variable -%}} {{{ oval_line_in_file_state_xccdf_variable(xccdf_variable, datatype=datatype, rule_id=rule_id) }}} {{%- else -%}} @@ -1145,8 +1146,8 @@ Generates the :code:`` tag for OVAL check using correct product platfo {{%- endif -%}} {{%- if config_is_distributed == "true" %}} - {{{ oval_line_in_directory_test(sshd_config_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent (2) }}} - {{{ oval_line_in_directory_object(sshd_config_dir, parameter=parameter, rule_id=rule_id, ** case_insensitivity_kwargs) | indent (2) }}} + {{{ oval_line_in_directory_test(sshd_drop_in_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_directory_object(sshd_drop_in_dir, parameter=parameter, rule_id=rule_id, ** case_insensitivity_kwargs) | indent (2) }}} {{%- if xccdf_variable -%}} {{{ oval_line_in_directory_state_xccdf_variable(xccdf_variable, datatype, rule_id=rule_id) | indent (2) }}} {{%- else -%}} @@ -1320,7 +1321,12 @@ Generates the :code:`` tag for OVAL check using correct product platfo state_{{{ object_id }}}_users_ignored
+ {{%- if product == "hummingbird" -%}} + {{# Hummingbird contains special "default" user named 65532 which has the home directory set to /tmp because distroless images ship no /home directory. #}} + {{%- set ignored_users_list="(nobody|nfsnobody|65532)" %}} + {{%- else -%}} {{%- set ignored_users_list="(nobody|nfsnobody)" %}} + {{%- endif -%}} ^{{{ ignored_users_list }}}$ @@ -1878,3 +1884,212 @@ Macro generates an OVAL test definition to verify that a specified audit tool is
{{%- endmacro -%}} + + +{{# + Create a full OVAL check for an sshd parameter and value in /etc/ssh/sshd_config or /usr/etc/ssh/sshd_config. + Including /etc/ssh/sshd_config.d/*.conf and /usr/etc/ssh/sshd_config.d/*.conf (default on SUSE Linux Enterprise Server 16) + +:param parameter: Parameter to check +:type parameter: str +:param value: Value to check +:type value: str +:param missing_parameter_pass: If true, the check will pass if the parameter missing. +:type missing_parameter_pass: bool +:param xccdf_variable: the name of an XCCDF variable carrying the value, this conflicts with the value parameter +:type xccdf_variable: str +:param datatype: a data type of the value +:type datatype: str + +#}} +{{%- macro sshd_oval_check_usr(parameter, value, missing_parameter_pass, xccdf_variable="", datatype="", rule_id=None, rule_title=None) -%}} +{{%- set sshd_config_path = "/etc/ssh/sshd_config" %}} +{{%- set sshd_usr_config_path = "/usr/etc/ssh/sshd_config" -%}} +{{%- set sshd_config_dir = "/etc/ssh/sshd_config.d" -%}} +{{%- set sshd_usr_config_dir = "/usr/etc/ssh/sshd_config.d" -%}} +{{%- if xccdf_variable -%}} +{{%- set description = "Ensure '" ~ parameter ~ "' is configured with value configured in " ~ xccdf_variable ~ " variable in " ~ sshd_config_path %}} +{{%- else -%}} +{{%- set description = "Ensure '" ~ parameter ~ "' is configured with value '" ~ value ~ "' in " ~ sshd_config_path -%}} +{{%- endif -%}} +{{%- set description = description ~ " or in " ~ sshd_config_dir -%}} +{{%- set description = description ~ " or in " ~ sshd_usr_config_path -%}} +{{%- set description = description ~ " or in " ~ sshd_usr_config_dir -%}} +{{%- set case_insensitivity_kwargs = dict(prefix_regex="^[ \\t]*(?i)", separator_regex = "(?-i)[ \\t]+") -%}} + + + + {{{ oval_metadata(description, rule_title=rule_title) }}} + + + + + + + + + + + + + {{{ oval_line_in_file_criterion(sshd_config_path, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12)}}} + {{{ oval_line_in_directory_criterion(sshd_config_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12) }}} + {{{ oval_line_in_file_criterion(sshd_usr_config_dir, parameter, id_stem=rule_id ~ "_sshd_usr_config_dir") | indent(12) }}} + + {{%- if not missing_parameter_pass -%}} + + {{%- endif -%}} + + + + + + + + + + + {{{ oval_line_in_file_criterion(sshd_usr_config_path, parameter, avoid_conflicting=true, id_stem=rule_id ~ "_sshd_usr_config_path") | indent(12)}}} + {{{ oval_line_in_directory_criterion(sshd_config_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent(12) }}} + {{{ oval_line_in_file_criterion(sshd_usr_config_dir, parameter, id_stem=rule_id ~ "_sshd_usr_config_dir") | indent(12) }}} + + {{%- if not missing_parameter_pass -%}} + + {{%- endif -%}} + + + + + + + {{{ oval_config_file_exists_test(sshd_config_path, rule_id=rule_id) }}} + {{{ oval_config_file_exists_object(sshd_config_path, rule_id=rule_id) }}} + + {{{ oval_line_in_file_test(sshd_config_path, parameter, avoid_conflicting=true, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_file_object(sshd_config_path, parameter=parameter, rule_id=rule_id, ** case_insensitivity_kwargs)| indent (2) }}} + + {{{ oval_line_in_directory_test(sshd_config_dir, parameter, avoid_conflicting=true, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_directory_object(sshd_config_dir, parameter=parameter, rule_id=rule_id, ** case_insensitivity_kwargs) | indent (2) }}} + {{%- if xccdf_variable -%}} + {{{ oval_line_in_file_define_variable(xccdf_variable, datatype) }}} + {{{ oval_line_in_file_state_xccdf_variable(xccdf_variable, datatype=datatype, rule_id=rule_id) }}} + {{{ oval_line_in_directory_state_xccdf_variable(xccdf_variable, datatype, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_file_state_xccdf_variable(var_name=xccdf_variable, datatype=datatype, id_stem=rule_id ~ "_sshd_usr_config_path") | indent (2) }}} + {{{ oval_line_in_file_state_xccdf_variable(var_name=xccdf_variable, datatype=datatype, id_stem=rule_id ~ "_sshd_usr_config_dir") | indent (2) }}} + {{%- else -%}} + {{{ oval_line_in_file_state(value, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_directory_state(value, rule_id=rule_id) | indent (2) }}} + {{{ oval_line_in_file_state(value, id_stem=rule_id ~ "_sshd_usr_config_path") | indent (2) }}} + {{{ oval_line_in_file_state(value, id_stem=rule_id ~ "_sshd_usr_config_dir") | indent (2) }}} + {{%- endif -%}} + + {{{ oval_line_in_file_test(sshd_usr_config_path, parameter, avoid_conflicting=true, id_stem=rule_id ~ "_sshd_usr_config_path") | indent (2) }}} + {{{ oval_line_in_file_object(sshd_usr_config_path, parameter=parameter, id_stem=rule_id ~ "_sshd_usr_config_path", ** case_insensitivity_kwargs)| indent (2) }}} + {{{ oval_line_in_file_test(sshd_usr_config_dir, parameter, avoid_conflicting=true, id_stem=rule_id ~ "_sshd_usr_config_dir") | indent (2) }}} + {{{ oval_line_in_file_object(sshd_usr_config_dir, parameter=parameter, filename_regex=".*\.conf$", id_stem=rule_id ~ "_sshd_usr_config_dir", ** case_insensitivity_kwargs) | indent (2) }}} + + {{%- if not missing_parameter_pass -%}} + + + + obj_{{{ rule_id }}} + obj_{{{ rule_id }}}_config_dir + + + obj_{{{ rule_id }}}_sshd_usr_config_dir + + + + + + + + + + + + obj_{{{ rule_id }}}_config_dir + + + obj_{{{ rule_id }}}_sshd_usr_config_path + obj_{{{ rule_id }}}_sshd_usr_config_dir + + + + + + + + {{%- endif -%}} + +{{%- endmacro -%}} + + +{{# +Macro to check if external variable is set to value + :param filepath: Path to the configuration file to be checked. + :type filepath: str + :param filename_regex: If specified, the first argument is interpreted as `path`, and this will serve as `filename` regex. + :type filename_regex: str + :param parameter: Name of Parameter to check + :type parameter: str + :param variable: External variable name + :type variable: str + :param pattern: Pattern to match in configuration path + :type pattern: regex + :param regex_capture: regex capture in local variable + :type regex_capture: regex + :param test_id: test id to create + :type test_id: str + :param type: variable type + :type type: str + :param operation: operation + :type operation: str +#}} +{{%- macro oval_param_in_file_variable_test(filepath, parameter, variable, pattern, regex_capture, test_id, filename_regex='', type='int', operation='equals') -%}} + + + + + + + + + {{% if filename_regex %}} + {{{ filepath }}} + {{{ filename_regex }}} + {{% else %}} + {{{ filepath }}} + {{% endif %}} + {{{ pattern }}} + 1 + + + + + + + + + + local_variable_{{{ test_id }}} + + + + + + + + + +{{%- endmacro -%}} diff --git a/shared/macros/20-test-scenarios.jinja b/shared/macros/20-test-scenarios.jinja index 53bfe16e7338..87015c86b9f8 100644 --- a/shared/macros/20-test-scenarios.jinja +++ b/shared/macros/20-test-scenarios.jinja @@ -15,6 +15,23 @@ This macro changes the configuration of the audit service so that it looks like {{%- endmacro -%}} +{{# +This macro changes the configuration of the audit service so that it looks like augenrules is used to load rules. +#}} + +{{%- macro setup_augenrules_environment () -%}} + {{% if product in ["fedora", "ol10", "rhel10"] %}} + sed -i "s%^ExecStart=.*%ExecStart=/sbin/augenrules%" /usr/lib/systemd/system/audit-rules.service + {{% else %}} + {{% if product == "sle15" %}} + sed -i "s%^#ExecStartPost=.*%ExecStartPost=-/sbin/augenrules%" /usr/lib/systemd/system/auditd.service + {{% else %}} + sed -i "s%^ExecStartPost=.*%ExecStartPost=-/sbin/augenrules%" /usr/lib/systemd/system/auditd.service + {{% endif %}} + {{% endif %}} +{{%- endmacro -%}} + + {{# This macro is used by pam_account_password_faillock template to initialize the external variable and parameter value to a desired state. diff --git a/shared/references/cce-redhat-avail.txt b/shared/references/cce-redhat-avail.txt index f1dff1792b67..91b104d88076 100644 --- a/shared/references/cce-redhat-avail.txt +++ b/shared/references/cce-redhat-avail.txt @@ -1,14 +1,5 @@ -CCE-86459-5 -CCE-86461-1 -CCE-86465-2 -CCE-86466-0 -CCE-86468-6 -CCE-86469-4 -CCE-86482-7 -CCE-86483-5 CCE-86484-3 CCE-86492-6 -CCE-86493-4 CCE-86494-2 CCE-86497-5 CCE-86498-3 @@ -33,12 +24,8 @@ CCE-86601-2 CCE-86602-0 CCE-86604-6 CCE-86627-7 -CCE-86629-3 -CCE-86630-1 -CCE-86631-9 CCE-86633-5 CCE-86637-6 -CCE-86641-8 CCE-86648-3 CCE-86650-9 CCE-86654-1 @@ -65,7 +52,6 @@ CCE-86703-6 CCE-86704-4 CCE-86706-9 CCE-86708-5 -CCE-86709-3 CCE-86710-1 CCE-86712-7 CCE-86713-5 @@ -140,7 +126,6 @@ CCE-86919-8 CCE-86920-6 CCE-86925-5 CCE-86927-1 -CCE-86928-9 CCE-86929-7 CCE-86930-5 CCE-86934-7 @@ -220,7 +205,6 @@ CCE-87129-3 CCE-87130-1 CCE-87131-9 CCE-87132-7 -CCE-87133-5 CCE-87134-3 CCE-87136-8 CCE-87138-4 @@ -612,7 +596,6 @@ CCE-87796-9 CCE-87797-7 CCE-87798-5 CCE-87799-3 -CCE-87800-9 CCE-87801-7 CCE-87802-5 CCE-87803-3 @@ -635,7 +618,6 @@ CCE-87833-0 CCE-87834-8 CCE-87839-7 CCE-87840-5 -CCE-87843-9 CCE-87845-4 CCE-87846-2 CCE-87847-0 @@ -658,7 +640,6 @@ CCE-87867-8 CCE-87868-6 CCE-87869-4 CCE-87870-2 -CCE-87871-0 CCE-87873-6 CCE-87875-1 CCE-87877-7 @@ -700,7 +681,6 @@ CCE-87933-8 CCE-87934-6 CCE-87935-3 CCE-87938-7 -CCE-87939-5 CCE-87941-1 CCE-87942-9 CCE-87943-7 @@ -752,7 +732,6 @@ CCE-88019-5 CCE-88020-3 CCE-88021-1 CCE-88022-9 -CCE-88024-5 CCE-88026-0 CCE-88028-6 CCE-88029-4 @@ -820,7 +799,6 @@ CCE-88130-0 CCE-88131-8 CCE-88138-3 CCE-88139-1 -CCE-88141-7 CCE-88142-5 CCE-88143-3 CCE-88144-1 @@ -847,11 +825,9 @@ CCE-88182-1 CCE-88184-7 CCE-88186-2 CCE-88187-0 -CCE-88189-6 CCE-88190-4 CCE-88191-2 CCE-88195-3 -CCE-88196-1 CCE-88197-9 CCE-88199-5 CCE-88201-9 @@ -912,7 +888,6 @@ CCE-88291-0 CCE-88292-8 CCE-88295-1 CCE-88297-7 -CCE-88298-5 CCE-88301-7 CCE-88302-5 CCE-88304-1 @@ -1046,7 +1021,6 @@ CCE-88509-5 CCE-88510-3 CCE-88513-7 CCE-88514-5 -CCE-88516-0 CCE-88517-8 CCE-88519-4 CCE-88522-8 @@ -1091,7 +1065,6 @@ CCE-88582-2 CCE-88584-8 CCE-88594-7 CCE-88595-4 -CCE-88596-2 CCE-88597-0 CCE-88598-8 CCE-88600-2 @@ -1151,7 +1124,6 @@ CCE-88679-6 CCE-88680-4 CCE-88681-2 CCE-88684-6 -CCE-88685-3 CCE-88690-3 CCE-88694-5 CCE-88695-2 @@ -1216,7 +1188,6 @@ CCE-88803-2 CCE-88805-7 CCE-88811-5 CCE-88812-3 -CCE-88819-8 CCE-88820-6 CCE-88823-0 CCE-88829-7 @@ -1226,7 +1197,6 @@ CCE-88832-1 CCE-88833-9 CCE-88835-4 CCE-88836-2 -CCE-88839-6 CCE-88842-0 CCE-88846-1 CCE-88849-5 @@ -1235,7 +1205,6 @@ CCE-88851-1 CCE-88852-9 CCE-88853-7 CCE-88854-5 -CCE-88856-0 CCE-88857-8 CCE-88858-6 CCE-88859-4 @@ -1315,7 +1284,6 @@ CCE-88991-5 CCE-88992-3 CCE-88993-1 CCE-88994-9 -CCE-88995-6 CCE-88997-2 CCE-88999-8 CCE-89003-8 @@ -1385,7 +1353,6 @@ CCE-89118-4 CCE-89120-0 CCE-89124-2 CCE-89125-9 -CCE-89127-5 CCE-89128-3 CCE-89130-9 CCE-89131-7 @@ -1403,7 +1370,6 @@ CCE-89149-9 CCE-89150-7 CCE-89152-3 CCE-89154-9 -CCE-89156-4 CCE-89158-0 CCE-89161-4 CCE-89162-2 @@ -1485,7 +1451,6 @@ CCE-89305-7 CCE-89308-1 CCE-89310-7 CCE-89311-5 -CCE-89312-3 CCE-89315-6 CCE-89316-4 CCE-89317-2 @@ -1516,7 +1481,6 @@ CCE-89357-8 CCE-89358-6 CCE-89359-4 CCE-89360-2 -CCE-89361-0 CCE-89363-6 CCE-89364-4 CCE-89366-9 @@ -1583,7 +1547,6 @@ CCE-89475-8 CCE-89478-2 CCE-89482-4 CCE-89483-2 -CCE-89484-0 CCE-89485-7 CCE-89487-3 CCE-89489-9 @@ -1596,7 +1559,6 @@ CCE-89495-6 CCE-89500-3 CCE-89501-1 CCE-89502-9 -CCE-89503-7 CCE-89504-5 CCE-89506-0 CCE-89509-4 @@ -1604,7 +1566,6 @@ CCE-89511-0 CCE-89512-8 CCE-89513-6 CCE-89515-1 -CCE-89516-9 CCE-89517-7 CCE-89518-5 CCE-89522-7 @@ -1657,7 +1618,6 @@ CCE-89599-5 CCE-89600-1 CCE-89602-7 CCE-89604-3 -CCE-89605-0 CCE-89608-4 CCE-89609-2 CCE-89610-0 @@ -1697,7 +1657,6 @@ CCE-89664-7 CCE-89665-4 CCE-89666-2 CCE-89669-6 -CCE-89670-4 CCE-89671-2 CCE-89672-0 CCE-89673-8 @@ -1937,7 +1896,6 @@ CCE-90028-2 CCE-90030-8 CCE-90031-6 CCE-90032-4 -CCE-90033-2 CCE-90034-0 CCE-90036-5 CCE-90037-3 @@ -1996,7 +1954,6 @@ CCE-90117-3 CCE-90118-1 CCE-90120-7 CCE-90123-1 -CCE-90126-4 CCE-90127-2 CCE-90130-6 CCE-90131-4 @@ -2075,7 +2032,6 @@ CCE-90245-2 CCE-90246-0 CCE-90247-8 CCE-90248-6 -CCE-90250-2 CCE-90252-8 CCE-90253-6 CCE-90255-1 @@ -2180,7 +2136,6 @@ CCE-90407-8 CCE-90408-6 CCE-90412-8 CCE-90414-4 -CCE-90416-9 CCE-90417-7 CCE-90418-5 CCE-90419-3 @@ -2255,7 +2210,6 @@ CCE-90529-9 CCE-90530-7 CCE-90533-1 CCE-90535-6 -CCE-90536-4 CCE-90537-2 CCE-90538-0 CCE-90539-8 @@ -2345,8 +2299,4 @@ CCE-90705-5 CCE-90706-3 CCE-90707-1 CCE-90710-5 -CCE-90711-3 CCE-90715-4 -CCE-90720-4 -CCE-90721-2 -CCE-90722-0 diff --git a/shared/references/cce-sle16-avail.txt b/shared/references/cce-sle16-avail.txt index 85d8169d528f..f0e358f3e7e6 100644 --- a/shared/references/cce-sle16-avail.txt +++ b/shared/references/cce-sle16-avail.txt @@ -1,84 +1,49 @@ CCE-95718-3 -CCE-95719-1 CCE-95720-9 -CCE-95722-5 -CCE-95723-3 -CCE-95724-1 CCE-95725-8 -CCE-95726-6 -CCE-95727-4 -CCE-95729-0 CCE-95730-8 CCE-95731-6 CCE-95732-4 -CCE-95733-2 CCE-95735-7 -CCE-95736-5 -CCE-95737-3 -CCE-95738-1 CCE-95741-5 -CCE-95742-3 CCE-95751-4 CCE-95752-2 -CCE-95753-0 CCE-95754-8 CCE-95755-5 -CCE-95756-3 CCE-95758-9 CCE-95759-7 -CCE-95760-5 -CCE-95761-3 -CCE-95762-1 CCE-95766-2 CCE-95767-0 CCE-95768-8 CCE-95770-4 CCE-95772-0 -CCE-95774-6 CCE-95775-3 -CCE-95777-9 CCE-95779-5 CCE-95781-1 CCE-95785-2 CCE-95786-0 -CCE-95787-8 -CCE-95788-6 CCE-95789-4 CCE-95790-2 CCE-95791-0 -CCE-95794-4 CCE-95798-5 -CCE-95799-3 CCE-95800-9 CCE-95802-5 CCE-95803-3 CCE-95804-1 -CCE-95806-6 -CCE-95807-4 CCE-95808-2 -CCE-95810-8 CCE-95813-2 -CCE-95814-0 CCE-95815-7 -CCE-95816-5 CCE-95819-9 -CCE-95822-3 CCE-95823-1 CCE-95824-9 CCE-95826-4 -CCE-95827-2 CCE-95829-8 -CCE-95831-4 CCE-95832-2 CCE-95833-0 CCE-95834-8 CCE-95836-3 CCE-95838-9 CCE-95839-7 -CCE-95841-3 -CCE-95842-1 -CCE-95847-0 -CCE-95848-8 CCE-95849-6 CCE-95852-0 CCE-95853-8 @@ -86,58 +51,40 @@ CCE-95854-6 CCE-95856-1 CCE-95857-9 CCE-95858-7 -CCE-95859-5 CCE-95860-3 CCE-95861-1 -CCE-95862-9 -CCE-95863-7 CCE-95864-5 -CCE-95865-2 CCE-95867-8 CCE-95868-6 CCE-95869-4 CCE-95870-2 CCE-95871-0 -CCE-95872-8 CCE-95875-1 CCE-95876-9 CCE-95877-7 CCE-95878-5 -CCE-95879-3 CCE-95881-9 CCE-95883-5 -CCE-95884-3 CCE-95887-6 CCE-95890-0 CCE-95892-6 CCE-95894-2 CCE-95896-7 -CCE-95897-5 CCE-95899-1 CCE-95901-5 CCE-95904-9 CCE-95906-4 CCE-95907-2 CCE-95908-0 -CCE-95909-8 -CCE-95910-6 CCE-95912-2 CCE-95913-0 CCE-95914-8 -CCE-95915-5 CCE-95916-3 CCE-95917-1 -CCE-95918-9 -CCE-95919-7 CCE-95920-5 -CCE-95922-1 CCE-95923-9 -CCE-95924-7 CCE-95925-4 CCE-95926-2 -CCE-95927-0 -CCE-95928-8 -CCE-95929-6 CCE-95930-4 CCE-95932-0 CCE-95934-6 @@ -145,19 +92,14 @@ CCE-95935-3 CCE-95937-9 CCE-95938-7 CCE-95939-5 -CCE-95940-3 CCE-95941-1 CCE-95943-7 -CCE-95945-2 -CCE-95946-0 CCE-95947-8 CCE-95948-6 CCE-95949-4 -CCE-95950-2 CCE-95951-0 CCE-95952-8 CCE-95953-6 -CCE-95955-1 CCE-95956-9 CCE-95957-7 CCE-95958-5 @@ -165,7 +107,6 @@ CCE-95960-1 CCE-95962-7 CCE-95963-5 CCE-95964-3 -CCE-95966-8 CCE-95967-6 CCE-95969-2 CCE-95970-0 @@ -176,17 +117,11 @@ CCE-95976-7 CCE-95977-5 CCE-95978-3 CCE-95979-1 -CCE-95980-9 -CCE-95981-7 CCE-95984-1 CCE-95986-6 -CCE-95987-4 CCE-95988-2 -CCE-95989-0 CCE-95990-8 CCE-95991-6 -CCE-95993-2 -CCE-95994-0 CCE-95995-7 CCE-95997-3 CCE-95998-1 @@ -198,11 +133,7 @@ CCE-96004-7 CCE-96006-2 CCE-96009-6 CCE-96011-2 -CCE-96015-3 -CCE-96017-9 CCE-96022-9 -CCE-96023-7 -CCE-96025-2 CCE-96026-0 CCE-96028-6 CCE-96029-4 @@ -212,39 +143,23 @@ CCE-96034-4 CCE-96035-1 CCE-96036-9 CCE-96037-7 -CCE-96038-5 -CCE-96039-3 CCE-96040-1 CCE-96041-9 CCE-96042-7 CCE-96044-3 CCE-96045-0 CCE-96046-8 -CCE-96048-4 -CCE-96050-0 CCE-96051-8 -CCE-96054-2 -CCE-96055-9 CCE-96056-7 -CCE-96057-5 CCE-96059-1 -CCE-96060-9 CCE-96061-7 -CCE-96062-5 -CCE-96064-1 -CCE-96065-8 CCE-96067-4 -CCE-96069-0 CCE-96070-8 CCE-96071-6 CCE-96073-2 -CCE-96076-5 CCE-96078-1 CCE-96079-9 -CCE-96081-5 CCE-96082-3 -CCE-96083-1 -CCE-96085-6 CCE-96086-4 CCE-96087-2 CCE-96091-4 @@ -253,15 +168,12 @@ CCE-96093-0 CCE-96095-5 CCE-96097-1 CCE-96098-9 -CCE-96099-7 CCE-96100-3 CCE-96103-7 CCE-96104-5 CCE-96105-2 -CCE-96106-0 CCE-96108-6 CCE-96109-4 -CCE-96110-2 CCE-96111-0 CCE-96112-8 CCE-96113-6 @@ -275,26 +187,18 @@ CCE-96121-9 CCE-96124-3 CCE-96125-0 CCE-96126-8 -CCE-96129-2 -CCE-96130-0 -CCE-96132-6 CCE-96136-7 CCE-96137-5 -CCE-96138-3 CCE-96139-1 -CCE-96140-9 CCE-96143-3 -CCE-96146-6 CCE-96147-4 CCE-96149-0 CCE-96150-8 CCE-96151-6 CCE-96153-2 CCE-96154-0 -CCE-96157-3 CCE-96159-9 CCE-96160-7 -CCE-96161-5 CCE-96162-3 CCE-96163-1 CCE-96164-9 @@ -304,92 +208,56 @@ CCE-96167-2 CCE-96168-0 CCE-96170-6 CCE-96173-0 -CCE-96174-8 CCE-96175-5 CCE-96176-3 -CCE-96177-1 -CCE-96178-9 CCE-96179-7 CCE-96180-5 CCE-96181-3 CCE-96182-1 CCE-96184-7 CCE-96186-2 -CCE-96187-0 -CCE-96189-6 -CCE-96190-4 CCE-96191-2 -CCE-96192-0 -CCE-96193-8 -CCE-96194-6 -CCE-96195-3 -CCE-96196-1 CCE-96197-9 CCE-96198-7 -CCE-96199-5 CCE-96200-1 CCE-96204-3 CCE-96205-0 CCE-96206-8 -CCE-96208-4 CCE-96209-2 -CCE-96211-8 CCE-96214-2 CCE-96216-7 CCE-96219-1 -CCE-96220-9 CCE-96222-5 CCE-96223-3 CCE-96224-1 CCE-96225-8 -CCE-96227-4 CCE-96228-2 -CCE-96229-0 CCE-96230-8 CCE-96231-6 CCE-96233-2 -CCE-96235-7 -CCE-96236-5 CCE-96237-3 CCE-96238-1 CCE-96240-7 -CCE-96241-5 -CCE-96245-6 -CCE-96246-4 CCE-96248-0 CCE-96249-8 CCE-96250-6 CCE-96251-4 -CCE-96252-2 CCE-96253-0 -CCE-96255-5 -CCE-96256-3 CCE-96258-9 -CCE-96259-7 CCE-96260-5 CCE-96261-3 CCE-96264-7 -CCE-96265-4 CCE-96267-0 -CCE-96268-8 CCE-96269-6 CCE-96270-4 -CCE-96274-6 -CCE-96275-3 CCE-96277-9 -CCE-96278-7 CCE-96280-3 CCE-96281-1 -CCE-96285-2 -CCE-96288-6 CCE-96289-4 CCE-96291-0 CCE-96292-8 -CCE-96293-6 -CCE-96294-4 CCE-96296-9 CCE-96297-7 -CCE-96298-5 CCE-96302-5 CCE-96303-3 CCE-96304-1 @@ -401,14 +269,11 @@ CCE-96311-6 CCE-96312-4 CCE-96313-2 CCE-96316-5 -CCE-96318-1 CCE-96319-9 CCE-96320-7 -CCE-96321-5 CCE-96322-3 CCE-96324-9 CCE-96326-4 -CCE-96327-2 CCE-96331-4 CCE-96332-2 CCE-96333-0 @@ -417,9 +282,7 @@ CCE-96336-3 CCE-96337-1 CCE-96338-9 CCE-96339-7 -CCE-96340-5 CCE-96343-9 -CCE-96344-7 CCE-96345-4 CCE-96346-2 CCE-96347-0 @@ -428,85 +291,44 @@ CCE-96349-6 CCE-96351-2 CCE-96352-0 CCE-96354-6 -CCE-96355-3 -CCE-96356-1 CCE-96357-9 -CCE-96358-7 -CCE-96359-5 -CCE-96361-1 CCE-96362-9 -CCE-96363-7 -CCE-96366-0 -CCE-96367-8 CCE-96369-4 -CCE-96370-2 -CCE-96371-0 -CCE-96372-8 CCE-96374-4 CCE-96375-1 CCE-96379-3 CCE-96380-1 -CCE-96383-5 CCE-96387-6 CCE-96389-2 -CCE-96390-0 CCE-96392-6 -CCE-96394-2 CCE-96395-9 -CCE-96396-7 -CCE-96397-5 CCE-96399-1 CCE-96400-7 CCE-96401-5 CCE-96402-3 CCE-96403-1 -CCE-96404-9 -CCE-96405-6 -CCE-96407-2 -CCE-96408-0 CCE-96410-6 -CCE-96411-4 CCE-96412-2 CCE-96413-0 -CCE-96414-8 CCE-96415-5 CCE-96417-1 CCE-96418-9 CCE-96419-7 CCE-96421-3 -CCE-96423-9 CCE-96424-7 CCE-96425-4 CCE-96426-2 CCE-96427-0 -CCE-96428-8 -CCE-96430-4 -CCE-96431-2 CCE-96432-0 -CCE-96438-7 CCE-96439-5 -CCE-96440-3 -CCE-96441-1 -CCE-96444-5 -CCE-96445-2 -CCE-96446-0 -CCE-96447-8 -CCE-96448-6 CCE-96449-4 -CCE-96450-2 -CCE-96452-8 CCE-96454-4 CCE-96455-1 -CCE-96456-9 CCE-96459-3 -CCE-96460-1 CCE-96461-9 -CCE-96462-7 CCE-96463-5 -CCE-96464-3 CCE-96466-8 CCE-96469-2 -CCE-96470-0 CCE-96471-8 CCE-96472-6 CCE-96474-2 @@ -523,79 +345,51 @@ CCE-96492-4 CCE-96493-2 CCE-96494-0 CCE-96495-7 -CCE-96496-5 CCE-96497-3 CCE-96498-1 CCE-96502-0 -CCE-96503-8 CCE-96504-6 CCE-96507-9 CCE-96508-7 -CCE-96510-3 CCE-96511-1 -CCE-96512-9 -CCE-96513-7 -CCE-96514-5 CCE-96515-2 CCE-96517-8 CCE-96518-6 -CCE-96519-4 CCE-96520-2 CCE-96523-6 CCE-96524-4 CCE-96525-1 -CCE-96527-7 CCE-96528-5 -CCE-96529-3 CCE-96530-1 -CCE-96533-5 CCE-96536-8 CCE-96537-6 CCE-96538-4 CCE-96539-2 -CCE-96540-0 CCE-96542-6 CCE-96543-4 CCE-96545-9 CCE-96546-7 CCE-96548-3 -CCE-96549-1 -CCE-96551-7 CCE-96552-5 CCE-96553-3 CCE-96554-1 -CCE-96555-8 -CCE-96557-4 CCE-96558-2 CCE-96559-0 -CCE-96560-8 CCE-96561-6 CCE-96562-4 CCE-96563-2 CCE-96564-0 CCE-96565-7 -CCE-96566-5 -CCE-96569-9 -CCE-96570-7 -CCE-96571-5 CCE-96572-3 -CCE-96573-1 -CCE-96574-9 -CCE-96575-6 CCE-96577-2 CCE-96580-6 -CCE-96582-2 CCE-96583-0 CCE-96586-3 CCE-96587-1 CCE-96588-9 -CCE-96589-7 CCE-96590-5 CCE-96594-7 -CCE-96595-4 CCE-96596-2 -CCE-96597-0 -CCE-96599-6 CCE-96600-2 CCE-96601-0 CCE-96602-8 @@ -603,63 +397,28 @@ CCE-96603-6 CCE-96605-1 CCE-96607-7 CCE-96608-5 -CCE-96609-3 CCE-96610-1 -CCE-96612-7 CCE-96613-5 CCE-96614-3 -CCE-96615-0 -CCE-96618-4 CCE-96619-2 -CCE-96620-0 CCE-96621-8 -CCE-96622-6 -CCE-96623-4 -CCE-96624-2 -CCE-96626-7 CCE-96628-3 -CCE-96629-1 CCE-96630-9 -CCE-96632-5 -CCE-96633-3 CCE-96635-8 CCE-96636-6 CCE-96637-4 CCE-96638-2 -CCE-96640-8 -CCE-96642-4 CCE-96643-2 CCE-96644-0 CCE-96645-7 CCE-96647-3 -CCE-96648-1 -CCE-96649-9 CCE-96651-5 CCE-96652-3 -CCE-96653-1 CCE-96655-6 -CCE-96656-4 CCE-96657-2 CCE-96659-8 CCE-96662-2 -CCE-96663-0 -CCE-96664-8 -CCE-96665-5 -CCE-96666-3 -CCE-96668-9 -CCE-96669-7 -CCE-96671-3 -CCE-96672-1 -CCE-96674-7 -CCE-96676-2 -CCE-96679-6 -CCE-96680-4 -CCE-96682-0 -CCE-96684-6 CCE-96685-3 CCE-96687-9 CCE-96689-5 CCE-96690-3 -CCE-96692-9 -CCE-96693-7 -CCE-96696-0 diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10.yml new file mode 100644 index 000000000000..b9bde23495df --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10.yml @@ -0,0 +1,24 @@ +# AUTO-GENERATED Product-Specific CIS Reference File (RHEL10) +# +# This file contains only metadata for RHEL10. +# Control families are in nist_800_53_cis_reference_rhel10/ +# Do NOT edit manually. Updated by weekly sync workflow. +# +# OSCAL metadata (description, parameters, guidance, related_controls) is NOT +# included in control files. Retrieve from OSCAL catalog when needed. +# +policy: NIST 800-53 Revision 5 CIS Reference (RHEL10) +title: NIST Special Publication 800-53 Revision 5 CIS Reference for RHEL10 +id: nist_800_53_cis_reference_rhel10 +version: Revision 5 +source: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +product: rhel10 +controls_dir: nist_800_53_cis_reference_rhel10 +levels: + - id: low + - id: moderate + inherits_from: + - low + - id: high + inherits_from: + - moderate diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ac.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ac.yml new file mode 100644 index 000000000000..e052dceaf7a4 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ac.yml @@ -0,0 +1,842 @@ +# NIST 800-53 AC Family: Access Control +controls: + - id: ac-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ac-2 + title: Account Management + levels: + - low + rules: [] + status: pending + - id: ac-2.1 + title: Automated System Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.2 + title: Automated Temporary and Emergency Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.3 + title: Disable Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-2.4 + title: Automated Audit Actions + levels: + - moderate + rules: [] + status: pending + - id: ac-2.5 + title: Inactivity Logout + levels: + - moderate + rules: + - accounts_tmout + - no_invalid_shell_accounts_unlocked + - no_password_auth_for_systemaccounts + - no_shelllogin_for_systemaccounts + - inactivity_timeout_value=15_minutes + - var_accounts_tmout=15_min + status: automated + - id: ac-2.6 + title: Dynamic Privilege Management + rules: [] + status: pending + - id: ac-2.7 + title: Privileged User Accounts + rules: [] + status: pending + - id: ac-2.8 + title: Dynamic Account Management + rules: [] + status: pending + - id: ac-2.9 + title: Restrictions on Use of Shared and Group Accounts + rules: [] + status: pending + - id: ac-2.10 + title: Shared and Group Account Credential Change + rules: [] + status: pending + - id: ac-2.11 + title: Usage Conditions + levels: + - high + rules: [] + status: pending + - id: ac-2.12 + title: Account Monitoring for Atypical Usage + levels: + - high + rules: [] + status: pending + - id: ac-2.13 + title: Disable Accounts for High-risk Individuals + levels: + - moderate + rules: [] + status: pending + - id: ac-3 + title: Access Enforcement + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_umask_root + - audit_rules_immutable + - dir_perms_world_writable_sticky_bits + - directory_groupowner_sshd_config_d + - directory_owner_sshd_config_d + - directory_permissions_sshd_config_d + - ensure_pam_wheel_group_empty + - file_at_allow_exists + - file_at_deny_not_exist + - file_cron_allow_exists + - file_cron_deny_not_exist + - file_groupowner_at_allow + - file_groupowner_backup_etc_group + - file_groupowner_backup_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - file_groupowner_cron_allow + - file_groupowner_cron_d + - file_groupowner_cron_daily + - file_groupowner_cron_hourly + - file_groupowner_cron_monthly + - file_groupowner_cron_weekly + - file_groupowner_cron_yearly + - file_groupowner_crontab + - file_groupowner_etc_group + - file_groupowner_etc_gshadow + - file_groupowner_etc_issue + - file_groupowner_etc_issue_net + - file_groupowner_etc_motd + - file_groupowner_etc_passwd + - file_groupowner_etc_security_opasswd + - file_groupowner_etc_security_opasswd_old + - file_groupowner_etc_shadow + - file_groupowner_etc_shells + - file_groupowner_sshd_config + - file_groupowner_sshd_drop_in_config + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_at_allow + - file_owner_backup_etc_group + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_owner_backup_etc_shadow + - file_owner_cron_allow + - file_owner_cron_d + - file_owner_cron_daily + - file_owner_cron_hourly + - file_owner_cron_monthly + - file_owner_cron_weekly + - file_owner_cron_yearly + - file_owner_crontab + - file_owner_etc_group + - file_owner_etc_gshadow + - file_owner_etc_issue + - file_owner_etc_issue_net + - file_owner_etc_motd + - file_owner_etc_passwd + - file_owner_etc_security_opasswd + - file_owner_etc_security_opasswd_old + - file_owner_etc_shadow + - file_owner_etc_shells + - file_owner_sshd_config + - file_owner_sshd_drop_in_config + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_at_allow + - file_permissions_backup_etc_group + - file_permissions_backup_etc_gshadow + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_shadow + - file_permissions_cron_allow + - file_permissions_cron_d + - file_permissions_cron_daily + - file_permissions_cron_hourly + - file_permissions_cron_monthly + - file_permissions_cron_weekly + - file_permissions_cron_yearly + - file_permissions_crontab + - file_permissions_etc_group + - file_permissions_etc_gshadow + - file_permissions_etc_issue + - file_permissions_etc_issue_net + - file_permissions_etc_motd + - file_permissions_etc_passwd + - file_permissions_etc_security_opasswd + - file_permissions_etc_security_opasswd_old + - file_permissions_etc_shadow + - file_permissions_etc_shells + - file_permissions_sshd_config + - file_permissions_sshd_drop_in_config + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_unauthorized_world_writable + - grub2_enable_selinux + - grub2_password + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_home_nodev + - mount_option_home_nosuid + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - mount_option_var_log_audit_nodev + - mount_option_var_log_audit_noexec + - mount_option_var_log_audit_nosuid + - mount_option_var_log_nodev + - mount_option_var_log_noexec + - mount_option_var_log_nosuid + - mount_option_var_nodev + - mount_option_var_nosuid + - mount_option_var_tmp_nodev + - mount_option_var_tmp_noexec + - mount_option_var_tmp_nosuid + - package_libselinux_installed + - package_mcstrans_removed + - package_setroubleshoot_removed + - rsyslog_files_groupownership + - rsyslog_files_ownership + - rsyslog_files_permissions + - selinux_not_disabled + - selinux_policytype + - sshd_limit_user_access + - sysctl_fs_protected_hardlinks + - sysctl_fs_protected_symlinks + - use_pam_wheel_group_for_su + - var_accounts_user_umask=027 + - var_pam_wheel_group_for_su=cis + - var_selinux_policy_name=targeted + status: automated + - id: ac-3.1 + title: Restricted Access to Privileged Functions + rules: [] + status: pending + - id: ac-3.2 + title: Dual Authorization + rules: [] + status: pending + - id: ac-3.3 + title: Mandatory Access Control + rules: [] + status: pending + - id: ac-3.4 + title: Discretionary Access Control + rules: [] + status: pending + - id: ac-3.5 + title: Security-relevant Information + rules: [] + status: pending + - id: ac-3.6 + title: Protection of User and System Information + rules: [] + status: pending + - id: ac-3.7 + title: Role-based Access Control + rules: [] + status: pending + - id: ac-3.8 + title: Revocation of Access Authorizations + rules: [] + status: pending + - id: ac-3.9 + title: Controlled Release + rules: [] + status: pending + - id: ac-3.10 + title: Audited Override of Access Control Mechanisms + rules: [] + status: pending + - id: ac-3.11 + title: Restrict Access to Specific Information Types + rules: [] + status: pending + - id: ac-3.12 + title: Assert and Enforce Application Access + rules: [] + status: pending + - id: ac-3.13 + title: Attribute-based Access Control + rules: [] + status: pending + - id: ac-3.14 + title: Individual Access + rules: [] + status: pending + - id: ac-3.15 + title: Discretionary and Mandatory Access Control + rules: [] + status: pending + - id: ac-4 + title: Information Flow Enforcement + levels: + - moderate + rules: [] + status: pending + - id: ac-4.1 + title: Object Security and Privacy Attributes + rules: [] + status: pending + - id: ac-4.2 + title: Processing Domains + rules: [] + status: pending + - id: ac-4.3 + title: Dynamic Information Flow Control + rules: [] + status: pending + - id: ac-4.4 + title: Flow Control of Encrypted Information + levels: + - high + rules: [] + status: pending + - id: ac-4.5 + title: Embedded Data Types + rules: [] + status: pending + - id: ac-4.6 + title: Metadata + rules: [] + status: pending + - id: ac-4.7 + title: One-way Flow Mechanisms + rules: [] + status: pending + - id: ac-4.8 + title: Security and Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.9 + title: Human Reviews + rules: [] + status: pending + - id: ac-4.10 + title: Enable and Disable Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.11 + title: Configuration of Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.12 + title: Data Type Identifiers + rules: [] + status: pending + - id: ac-4.13 + title: Decomposition into Policy-relevant Subcomponents + rules: [] + status: pending + - id: ac-4.14 + title: Security or Privacy Policy Filter Constraints + rules: [] + status: pending + - id: ac-4.15 + title: Detection of Unsanctioned Information + rules: [] + status: pending + - id: ac-4.16 + title: Information Transfers on Interconnected Systems + rules: [] + status: pending + - id: ac-4.17 + title: Domain Authentication + rules: [] + status: pending + - id: ac-4.18 + title: Security Attribute Binding + rules: [] + status: pending + - id: ac-4.19 + title: Validation of Metadata + rules: [] + status: pending + - id: ac-4.20 + title: Approved Solutions + rules: [] + status: pending + - id: ac-4.21 + title: Physical or Logical Separation of Information Flows + rules: [] + status: pending + - id: ac-4.22 + title: Access Only + rules: [] + status: pending + - id: ac-4.23 + title: Modify Non-releasable Information + rules: [] + status: pending + - id: ac-4.24 + title: Internal Normalized Format + rules: [] + status: pending + - id: ac-4.25 + title: Data Sanitization + rules: [] + status: pending + - id: ac-4.26 + title: Audit Filtering Actions + rules: [] + status: pending + - id: ac-4.27 + title: Redundant/Independent Filtering Mechanisms + rules: [] + status: pending + - id: ac-4.28 + title: Linear Filter Pipelines + rules: [] + status: pending + - id: ac-4.29 + title: Filter Orchestration Engines + rules: [] + status: pending + - id: ac-4.30 + title: Filter Mechanisms Using Multiple Processes + rules: [] + status: pending + - id: ac-4.31 + title: Failed Content Transfer Prevention + rules: [] + status: pending + - id: ac-4.32 + title: Process Requirements for Information Transfer + rules: [] + status: pending + - id: ac-5 + title: Separation of Duties + levels: + - moderate + rules: [] + status: pending + - id: ac-6 + title: Least Privilege + levels: + - moderate + rules: + - sshd_disable_root_login + - sudo_add_use_pty + - sudo_remove_no_authenticate + - sudo_remove_nopasswd + status: automated + - id: ac-6.1 + title: Authorize Access to Security Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.2 + title: Non-privileged Access for Nonsecurity Functions + levels: + - moderate + rules: + - package_sudo_installed + status: automated + - id: ac-6.3 + title: Network Access to Privileged Commands + levels: + - high + rules: [] + status: pending + - id: ac-6.4 + title: Separate Processing Domains + rules: [] + status: pending + - id: ac-6.5 + title: Privileged Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-6.6 + title: Privileged Access by Non-organizational Users + rules: [] + status: pending + - id: ac-6.7 + title: Review of User Privileges + levels: + - moderate + rules: [] + status: pending + - id: ac-6.8 + title: Privilege Levels for Code Execution + rules: [] + status: pending + - id: ac-6.9 + title: Log Use of Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.10 + title: Prohibit Non-privileged Users from Executing Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-7 + title: Unsuccessful Logon Attempts + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - accounts_passwords_pam_faillock_deny + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - accounts_passwords_pam_faillock_unlock_time_with_zero + - var_accounts_passwords_pam_faillock_deny=5 + - var_accounts_passwords_pam_faillock_dir=run + - var_accounts_passwords_pam_faillock_root_unlock_time=60 + - var_accounts_passwords_pam_faillock_unlock_time=900 + status: automated + - id: ac-7.1 + title: Automatic Account Lock + rules: [] + status: pending + - id: ac-7.2 + title: Purge or Wipe Mobile Device + rules: [] + status: pending + - id: ac-7.3 + title: Biometric Attempt Limiting + rules: [] + status: pending + - id: ac-7.4 + title: Use of Alternate Authentication Factor + rules: [] + status: pending + - id: ac-8 + title: System Use Notification + levels: + - low + rules: + - dconf_gnome_banner_enabled + - dconf_gnome_login_banner_text + status: automated + - id: ac-9 + title: Previous Logon Notification + rules: [] + status: pending + - id: ac-9.1 + title: Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.2 + title: Successful and Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.3 + title: Notification of Account Changes + rules: [] + status: pending + - id: ac-9.4 + title: Additional Logon Information + rules: [] + status: pending + - id: ac-10 + title: Concurrent Session Control + levels: + - high + rules: [] + status: pending + - id: ac-11 + title: Device Lock + levels: + - moderate + rules: + - dconf_gnome_screensaver_idle_delay + - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_user_locks + - dconf_gnome_session_idle_user_locks + - var_screensaver_lock_delay=5_seconds + status: automated + - id: ac-11.1 + title: Pattern-hiding Displays + levels: + - moderate + rules: [] + status: pending + - id: ac-12 + title: Session Termination + levels: + - moderate + rules: [] + status: pending + - id: ac-12.1 + title: User-initiated Logouts + rules: [] + status: pending + - id: ac-12.2 + title: Termination Message + rules: [] + status: pending + - id: ac-12.3 + title: Timeout Warning Message + rules: [] + status: pending + - id: ac-13 + title: Supervision and Review — Access Control + rules: [] + status: pending + - id: ac-14 + title: Permitted Actions Without Identification or Authentication + levels: + - low + rules: [] + status: pending + - id: ac-14.1 + title: Necessary Uses + rules: [] + status: pending + - id: ac-15 + title: Automated Marking + rules: [] + status: pending + - id: ac-16 + title: Security and Privacy Attributes + rules: [] + status: pending + - id: ac-16.1 + title: Dynamic Attribute Association + rules: [] + status: pending + - id: ac-16.2 + title: Attribute Value Changes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.3 + title: Maintenance of Attribute Associations by System + rules: [] + status: pending + - id: ac-16.4 + title: Association of Attributes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.5 + title: Attribute Displays on Objects to Be Output + rules: [] + status: pending + - id: ac-16.6 + title: Maintenance of Attribute Association + rules: [] + status: pending + - id: ac-16.7 + title: Consistent Attribute Interpretation + rules: [] + status: pending + - id: ac-16.8 + title: Association Techniques and Technologies + rules: [] + status: pending + - id: ac-16.9 + title: Attribute Reassignment — Regrading Mechanisms + rules: [] + status: pending + - id: ac-16.10 + title: Attribute Configuration by Authorized Individuals + rules: [] + status: pending + - id: ac-17 + title: Remote Access + levels: + - low + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: ac-17.1 + title: Monitoring and Control + levels: + - moderate + rules: [] + status: pending + - id: ac-17.2 + title: Protection of Confidentiality and Integrity Using Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-17.3 + title: Managed Access Control Points + levels: + - moderate + rules: [] + status: pending + - id: ac-17.4 + title: Privileged Commands and Access + levels: + - moderate + rules: [] + status: pending + - id: ac-17.5 + title: Monitoring for Unauthorized Connections + rules: [] + status: pending + - id: ac-17.6 + title: Protection of Mechanism Information + rules: [] + status: pending + - id: ac-17.7 + title: Additional Protection for Security Function Access + rules: [] + status: pending + - id: ac-17.8 + title: Disable Nonsecure Network Protocols + rules: [] + status: pending + - id: ac-17.9 + title: Disconnect or Disable Access + rules: [] + status: pending + - id: ac-17.10 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: ac-18 + title: Wireless Access + levels: + - low + rules: + - wireless_disable_interfaces + status: automated + - id: ac-18.1 + title: Authentication and Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-18.2 + title: Monitoring Unauthorized Connections + rules: [] + status: pending + - id: ac-18.3 + title: Disable Wireless Networking + levels: + - moderate + rules: [] + status: pending + - id: ac-18.4 + title: Restrict Configurations by Users + levels: + - high + rules: [] + status: pending + - id: ac-18.5 + title: Antennas and Transmission Power Levels + levels: + - high + rules: [] + status: pending + - id: ac-19 + title: Access Control for Mobile Devices + levels: + - low + rules: [] + status: pending + - id: ac-19.1 + title: Use of Writable and Portable Storage Devices + rules: [] + status: pending + - id: ac-19.2 + title: Use of Personally Owned Portable Storage Devices + rules: [] + status: pending + - id: ac-19.3 + title: Use of Portable Storage Devices with No Identifiable Owner + rules: [] + status: pending + - id: ac-19.4 + title: Restrictions for Classified Information + rules: [] + status: pending + - id: ac-19.5 + title: Full Device or Container-based Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-20 + title: Use of External Systems + levels: + - low + rules: [] + status: pending + - id: ac-20.1 + title: Limits on Authorized Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.2 + title: Portable Storage Devices — Restricted Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.3 + title: Non-organizationally Owned Systems — Restricted Use + rules: [] + status: pending + - id: ac-20.4 + title: Network Accessible Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-20.5 + title: Portable Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-21 + title: Information Sharing + levels: + - moderate + rules: [] + status: pending + - id: ac-21.1 + title: Automated Decision Support + rules: [] + status: pending + - id: ac-21.2 + title: Information Search and Retrieval + rules: [] + status: pending + - id: ac-22 + title: Publicly Accessible Content + levels: + - low + rules: [] + status: pending + - id: ac-23 + title: Data Mining Protection + rules: [] + status: pending + - id: ac-24 + title: Access Control Decisions + rules: [] + status: pending + - id: ac-24.1 + title: Transmit Access Authorization Information + rules: [] + status: pending + - id: ac-24.2 + title: No User or Process Identity + rules: [] + status: pending + - id: ac-25 + title: Reference Monitor + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/at.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/at.yml new file mode 100644 index 000000000000..80211cdb5591 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/at.yml @@ -0,0 +1,82 @@ +# NIST 800-53 AT Family: Awareness and Training +controls: + - id: at-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: at-2 + title: Literacy Training and Awareness + levels: + - low + rules: [] + status: pending + - id: at-2.1 + title: Practical Exercises + rules: [] + status: pending + - id: at-2.2 + title: Insider Threat + levels: + - low + rules: [] + status: pending + - id: at-2.3 + title: Social Engineering and Mining + levels: + - moderate + rules: [] + status: pending + - id: at-2.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-2.5 + title: Advanced Persistent Threat + rules: [] + status: pending + - id: at-2.6 + title: Cyber Threat Environment + rules: [] + status: pending + - id: at-3 + title: Role-based Training + levels: + - low + rules: [] + status: pending + - id: at-3.1 + title: Environmental Controls + rules: [] + status: pending + - id: at-3.2 + title: Physical Security Controls + rules: [] + status: pending + - id: at-3.3 + title: Practical Exercises + rules: [] + status: pending + - id: at-3.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-3.5 + title: Processing Personally Identifiable Information + rules: [] + status: pending + - id: at-4 + title: Training Records + levels: + - low + rules: [] + status: pending + - id: at-5 + title: Contacts with Security Groups and Associations + rules: [] + status: pending + - id: at-6 + title: Training Feedback + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/au.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/au.yml new file mode 100644 index 000000000000..5708017ad864 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/au.yml @@ -0,0 +1,486 @@ +# NIST 800-53 AU Family: Audit and Accountability +controls: + - id: au-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: au-2 + title: Event Logging + levels: + - low + rules: + - aide_build_database + - aide_periodic_cron_checking + - audit_rules_execution_chacl + - audit_rules_execution_chcon + - audit_rules_execution_setfacl + - audit_rules_privileged_commands_usermod + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - auditd_data_retention_action_mail_acct + - auditd_data_retention_admin_space_left_action + - auditd_data_retention_space_left_action + - ensure_journald_and_rsyslog_not_active_together + - grub2_audit_backlog_limit_argument + - journald_disable_forward_to_syslog + - package_aide_installed + - package_audit-libs_installed + - package_audit_installed + - package_systemd-journal-remote_installed + - service_auditd_enabled + - service_systemd-journal-upload_enabled + - service_systemd-journald_enabled + - socket_systemd-journal-remote_disabled + - var_audit_backlog_limit=8192 + - var_auditd_action_mail_acct=root + - var_auditd_admin_space_left_action=cis_rhel10 + - var_auditd_space_left_action=cis_rhel10 + status: automated + - id: au-2.1 + title: Compilation of Audit Records from Multiple Sources + rules: [] + status: pending + - id: au-2.2 + title: Selection of Audit Events by Component + rules: [] + status: pending + - id: au-2.3 + title: Reviews and Updates + rules: [] + status: pending + - id: au-2.4 + title: Privileged Functions + rules: [] + status: pending + - id: au-3 + title: Content of Audit Records + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_mac_modification_etc_selinux + - audit_rules_mac_modification_usr_share + - audit_rules_networkconfig_modification_etc_hosts + - audit_rules_networkconfig_modification_etc_issue + - audit_rules_networkconfig_modification_etc_issue_net + - audit_rules_networkconfig_modification_etc_networkmanager_system_connections + - audit_rules_networkconfig_modification_etc_sysconfig_network + - audit_rules_networkconfig_modification_hostname_file + - audit_rules_networkconfig_modification_networkmanager + - audit_rules_networkconfig_modification_setdomainname + - audit_rules_networkconfig_modification_sethostname + - audit_rules_privileged_commands + - audit_rules_privileged_commands_kmod + - audit_rules_session_events_btmp + - audit_rules_session_events_utmp + - audit_rules_session_events_wtmp + - audit_rules_suid_auid_privilege_function + - audit_rules_sysadmin_actions + - audit_rules_time_adjtimex + - audit_rules_time_clock_settime + - audit_rules_time_settimeofday + - audit_rules_time_watch_localtime + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - chronyd_run_as_chrony_user + - chronyd_specify_remote_server + - directory_permissions_var_log_audit + - file_groupownership_audit_binaries + - file_ownership_var_log_audit_stig + - file_permissions_audit_binaries + - journald_storage + - sshd_set_loglevel_verbose + - sshd_set_max_auth_tries + - sudo_custom_logfile + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_default_log_martians + - sshd_max_auth_tries_value=4 + - var_multiple_time_servers=rhel + status: automated + - id: au-3.1 + title: Additional Audit Information + levels: + - moderate + rules: [] + status: pending + - id: au-3.2 + title: Centralized Management of Planned Audit Record Content + rules: [] + status: pending + - id: au-3.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: au-4 + title: Audit Log Storage Capacity + levels: + - low + rules: + - journald_compress + status: automated + - id: au-4.1 + title: Transfer to Alternate Storage + rules: [] + status: pending + - id: au-5 + title: Response to Audit Logging Process Failures + levels: + - low + rules: + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - var_auditd_disk_error_action=cis_rhel10 + - var_auditd_disk_full_action=cis_rhel10 + status: automated + - id: au-5.1 + title: Storage Capacity Warning + levels: + - high + rules: [] + status: pending + - id: au-5.2 + title: Real-time Alerts + levels: + - high + rules: [] + status: pending + - id: au-5.3 + title: Configurable Traffic Volume Thresholds + rules: [] + status: pending + - id: au-5.4 + title: Shutdown on Failure + rules: [] + status: pending + - id: au-5.5 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-6 + title: Audit Record Review, Analysis, and Reporting + levels: + - low + rules: [] + status: pending + - id: au-6.1 + title: Automated Process Integration + levels: + - moderate + rules: [] + status: pending + - id: au-6.2 + title: Automated Security Alerts + rules: [] + status: pending + - id: au-6.3 + title: Correlate Audit Record Repositories + levels: + - moderate + rules: [] + status: pending + - id: au-6.4 + title: Central Review and Analysis + rules: [] + status: pending + - id: au-6.5 + title: Integrated Analysis of Audit Records + levels: + - high + rules: [] + status: pending + - id: au-6.6 + title: Correlation with Physical Monitoring + levels: + - high + rules: [] + status: pending + - id: au-6.7 + title: Permitted Actions + rules: [] + status: pending + - id: au-6.8 + title: Full Text Analysis of Privileged Commands + rules: [] + status: pending + - id: au-6.9 + title: Correlation with Information from Nontechnical Sources + rules: [] + status: pending + - id: au-6.10 + title: Audit Level Adjustment + rules: [] + status: pending + - id: au-7 + title: Audit Record Reduction and Report Generation + levels: + - moderate + rules: [] + status: pending + - id: au-7.1 + title: Automatic Processing + levels: + - moderate + rules: [] + status: pending + - id: au-7.2 + title: Automatic Sort and Search + rules: [] + status: pending + - id: au-8 + title: Time Stamps + levels: + - low + rules: + - auditd_data_retention_max_log_file + - auditd_data_retention_max_log_file_action + - var_auditd_max_log_file=8 + - var_auditd_max_log_file_action=keep_logs + status: automated + - id: au-8.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: au-8.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: au-9 + title: Protection of Audit Information + levels: + - low + rules: + - audit_rules_immutable + - file_groupownership_audit_configuration + - file_ownership_audit_binaries + - file_ownership_audit_configuration + status: automated + - id: au-9.1 + title: Hardware Write-once Media + rules: [] + status: pending + - id: au-9.2 + title: Store on Separate Physical Systems or Components + levels: + - high + rules: [] + status: pending + - id: au-9.3 + title: Cryptographic Protection + levels: + - high + rules: + - aide_check_audit_tools + status: automated + - id: au-9.4 + title: Access by Subset of Privileged Users + levels: + - moderate + rules: + - file_group_ownership_var_log_audit + - file_permissions_var_log_audit + status: automated + - id: au-9.5 + title: Dual Authorization + rules: [] + status: pending + - id: au-9.6 + title: Read-only Access + rules: [] + status: pending + - id: au-9.7 + title: Store on Component with Different Operating System + rules: [] + status: pending + - id: au-10 + title: Non-repudiation + levels: + - high + rules: [] + status: pending + - id: au-10.1 + title: Association of Identities + rules: [] + status: pending + - id: au-10.2 + title: Validate Binding of Information Producer Identity + rules: [] + status: pending + - id: au-10.3 + title: Chain of Custody + rules: [] + status: pending + - id: au-10.4 + title: Validate Binding of Information Reviewer Identity + rules: [] + status: pending + - id: au-10.5 + title: Digital Signatures + rules: [] + status: pending + - id: au-11 + title: Audit Record Retention + levels: + - low + rules: [] + status: pending + - id: au-11.1 + title: Long-term Retrieval Capability + rules: [] + status: pending + - id: au-12 + title: Audit Record Generation + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchmodat2 + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_continue_loading + - audit_rules_execution_chcon + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_renameat2 + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_unlinkat + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_media_export + - audit_rules_privileged_commands_kmod + - audit_rules_privileged_commands_usermod + - audit_rules_sysadmin_actions + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - audit_sudo_log_events + - file_permissions_audit_configuration + - grub2_audit_argument + - service_auditd_enabled + status: automated + - id: au-12.1 + title: System-wide and Time-correlated Audit Trail + levels: + - high + rules: [] + status: pending + - id: au-12.2 + title: Standardized Formats + rules: [] + status: pending + - id: au-12.3 + title: Changes by Authorized Individuals + levels: + - high + rules: [] + status: pending + - id: au-12.4 + title: Query Parameter Audits of Personally Identifiable Information + rules: [] + status: pending + - id: au-13 + title: Monitoring for Information Disclosure + rules: [] + status: pending + - id: au-13.1 + title: Use of Automated Tools + rules: [] + status: pending + - id: au-13.2 + title: Review of Monitored Sites + rules: [] + status: pending + - id: au-13.3 + title: Unauthorized Replication of Information + rules: [] + status: pending + - id: au-14 + title: Session Audit + rules: [] + status: pending + - id: au-14.1 + title: System Start-up + rules: [] + status: pending + - id: au-14.2 + title: Capture and Record Content + rules: [] + status: pending + - id: au-14.3 + title: Remote Viewing and Listening + rules: [] + status: pending + - id: au-15 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-16 + title: Cross-organizational Audit Logging + rules: [] + status: pending + - id: au-16.1 + title: Identity Preservation + rules: [] + status: pending + - id: au-16.2 + title: Sharing of Audit Information + rules: [] + status: pending + - id: au-16.3 + title: Disassociability + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ca.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ca.yml new file mode 100644 index 000000000000..35a07ac6ba5f --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ca.yml @@ -0,0 +1,161 @@ +# NIST 800-53 CA Family: Assessment, Authorization, and Monitoring +controls: + - id: ca-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ca-2 + title: Control Assessments + levels: + - low + rules: [] + status: pending + - id: ca-2.1 + title: Independent Assessors + levels: + - moderate + rules: [] + status: pending + - id: ca-2.2 + title: Specialized Assessments + levels: + - high + rules: [] + status: pending + - id: ca-2.3 + title: Leveraging Results from External Organizations + rules: [] + status: pending + - id: ca-3 + title: Information Exchange + levels: + - low + rules: [] + status: pending + - id: ca-3.1 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: ca-3.2 + title: Classified National Security System Connections + rules: [] + status: pending + - id: ca-3.3 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: ca-3.4 + title: Connections to Public Networks + rules: [] + status: pending + - id: ca-3.5 + title: Restrictions on External System Connections + rules: [] + status: pending + - id: ca-3.6 + title: Transfer Authorizations + levels: + - high + rules: [] + status: pending + - id: ca-3.7 + title: Transitive Information Exchanges + rules: [] + status: pending + - id: ca-4 + title: Security Certification + rules: [] + status: pending + - id: ca-5 + title: Plan of Action and Milestones + levels: + - low + rules: [] + status: pending + - id: ca-5.1 + title: Automation Support for Accuracy and Currency + rules: [] + status: pending + - id: ca-6 + title: Authorization + levels: + - low + rules: [] + status: pending + - id: ca-6.1 + title: Joint Authorization — Intra-organization + rules: [] + status: pending + - id: ca-6.2 + title: Joint Authorization — Inter-organization + rules: [] + status: pending + - id: ca-7 + title: Continuous Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.1 + title: Independent Assessment + levels: + - moderate + rules: [] + status: pending + - id: ca-7.2 + title: Types of Assessments + rules: [] + status: pending + - id: ca-7.3 + title: Trend Analyses + rules: [] + status: pending + - id: ca-7.4 + title: Risk Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.5 + title: Consistency Analysis + rules: [] + status: pending + - id: ca-7.6 + title: Automation Support for Monitoring + rules: [] + status: pending + - id: ca-8 + title: Penetration Testing + levels: + - high + rules: [] + status: pending + - id: ca-8.1 + title: Independent Penetration Testing Agent or Team + levels: + - high + rules: [] + status: pending + - id: ca-8.2 + title: Red Team Exercises + rules: [] + status: pending + - id: ca-8.3 + title: Facility Penetration Testing + rules: [] + status: pending + - id: ca-9 + title: Internal System Connections + levels: + - low + rules: + - firewalld-backend + - firewalld_loopback_traffic_trusted + - package_firewalld_installed + status: automated + - id: ca-9.1 + title: Compliance Checks + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/cm.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/cm.yml new file mode 100644 index 000000000000..d43e634aaa4b --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/cm.yml @@ -0,0 +1,549 @@ +# NIST 800-53 CM Family: Configuration Management +controls: + - id: cm-1 + title: Policy and Procedures + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - account_unique_id + - account_unique_name + - accounts_maximum_age_login_defs + - accounts_no_uid_except_zero + - accounts_password_set_max_life_existing + - accounts_root_gid_zero + - accounts_root_path_dirs_no_write + - accounts_user_dot_group_ownership + - accounts_user_dot_user_ownership + - configure_custom_crypto_policy_cis + - disable_host_auth + - file_permission_user_bash_history + - file_permission_user_init_files + - gid_passwd_group_same + - group_unique_id + - group_unique_name + - groups_no_zero_gid_except_root + - no_forward_files + - no_netrc_files + - no_nologin_in_shells + - no_rhost_files + - package_cron_installed + - root_path_no_dot + - service_crond_enabled + - sshd_disable_empty_passwords + - sshd_disable_gssapi_auth + - sshd_disable_rhosts + - sshd_do_not_permit_user_env + - sshd_enable_pam + - sshd_enable_warning_banner_net + - sshd_set_idle_timeout + - sshd_set_keepalive + - sshd_set_max_sessions + - sshd_set_maxstartups + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv4_tcp_syncookies + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sshd_idle_timeout_value=5_minutes + - sysctl_net_ipv4_tcp_syncookies_value=enabled + - var_accounts_maximum_age_login_defs=365 + - var_sshd_max_sessions=10 + - var_sshd_set_keepalive=1 + - var_sshd_set_maxstartups=10:30:60 + - var_user_initialization_files_regex=all_dotfiles + status: automated + - id: cm-2 + title: Baseline Configuration + levels: + - low + rules: [] + status: pending + - id: cm-2.1 + title: Reviews and Updates + rules: [] + status: pending + - id: cm-2.2 + title: Automation Support for Accuracy and Currency + levels: + - moderate + rules: [] + status: pending + - id: cm-2.3 + title: Retention of Previous Configurations + levels: + - moderate + rules: [] + status: pending + - id: cm-2.4 + title: Unauthorized Software + rules: [] + status: pending + - id: cm-2.5 + title: Authorized Software + rules: [] + status: pending + - id: cm-2.6 + title: Development and Test Environments + rules: [] + status: pending + - id: cm-2.7 + title: Configure Systems and Components for High-risk Areas + levels: + - moderate + rules: [] + status: pending + - id: cm-3 + title: Configuration Change Control + levels: + - moderate + rules: [] + status: pending + - id: cm-3.1 + title: Automated Documentation, Notification, and Prohibition of Changes + levels: + - high + rules: [] + status: pending + - id: cm-3.2 + title: Testing, Validation, and Documentation of Changes + levels: + - moderate + rules: [] + status: pending + - id: cm-3.3 + title: Automated Change Implementation + rules: [] + status: pending + - id: cm-3.4 + title: Security and Privacy Representatives + levels: + - moderate + rules: [] + status: pending + - id: cm-3.5 + title: Automated Security Response + rules: [] + status: pending + - id: cm-3.6 + title: Cryptography Management + levels: + - high + rules: [] + status: pending + - id: cm-3.7 + title: Review System Changes + rules: [] + status: pending + - id: cm-3.8 + title: Prevent or Restrict Configuration Changes + rules: [] + status: pending + - id: cm-4 + title: Impact Analyses + levels: + - low + rules: [] + status: pending + - id: cm-4.1 + title: Separate Test Environments + levels: + - high + rules: [] + status: pending + - id: cm-4.2 + title: Verification of Controls + levels: + - moderate + rules: [] + status: pending + - id: cm-5 + title: Access Restrictions for Change + levels: + - low + rules: [] + status: pending + - id: cm-5.1 + title: Automated Access Enforcement and Audit Records + levels: + - high + rules: [] + status: pending + - id: cm-5.2 + title: Review System Changes + rules: [] + status: pending + - id: cm-5.3 + title: Signed Components + rules: [] + status: pending + - id: cm-5.4 + title: Dual Authorization + rules: [] + status: pending + - id: cm-5.5 + title: Privilege Limitation for Production and Operation + rules: [] + status: pending + - id: cm-5.6 + title: Limit Library Privileges + rules: [] + status: pending + - id: cm-5.7 + title: Automatic Implementation of Security Safeguards + rules: [] + status: pending + - id: cm-6 + title: Configuration Settings + levels: + - low + rules: + - accounts_password_pam_pwquality_password_auth + - accounts_password_pam_pwquality_system_auth + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_user_interactive_home_directory_exists + - audit_rules_media_export + - banner_etc_issue_cis + - banner_etc_issue_net_cis + - banner_etc_motd_cis + - coredump_disable_backtraces + - coredump_disable_storage + - dconf_db_up_to_date + - dconf_gnome_disable_user_list + - disable_host_auth + - disable_users_coredumps + - file_groupowner_boot_grub2 + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_boot_grub2 + - file_ownership_home_directories + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_boot_grub2 + - file_permissions_home_directories + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - no_empty_passwords + - no_empty_passwords_etc_shadow + - no_files_or_dirs_ungroupowned + - no_files_or_dirs_unowned_by_user + - package_pam_pwquality_installed + - package_rsync_removed + - package_samba_removed + - package_squid_removed + - partition_for_tmp + - partition_for_var_log + - service_nfs_disabled + - service_rpcbind_disabled + - sshd_disable_gssapi_auth + - sshd_set_login_grace_time + - sysctl_fs_suid_dumpable + - sysctl_kernel_kptr_restrict + - sysctl_kernel_randomize_va_space + - sysctl_kernel_yama_ptrace_scope + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_forwarding + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_forwarding + - sysctl_net_ipv4_conf_default_log_martians + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sysctl_net_ipv6_conf_default_forwarding + - cis_banner_text=cis + - dconf_login_banner_contents=cis_default + - dconf_login_banner_text=cis_banners + - sysctl_net_ipv4_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_all_log_martians_value=enabled + - sysctl_net_ipv4_conf_all_rp_filter_value=enabled + - sysctl_net_ipv4_conf_all_secure_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_default_forwarding_value=disabled + - sysctl_net_ipv4_conf_default_log_martians_value=enabled + - sysctl_net_ipv4_conf_default_rp_filter_value=enabled + - sysctl_net_ipv4_conf_default_secure_redirects_value=disabled + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled + - sysctl_net_ipv6_conf_all_accept_ra_value=disabled + - sysctl_net_ipv6_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_all_forwarding_value=disabled + - sysctl_net_ipv6_conf_default_accept_ra_value=disabled + - sysctl_net_ipv6_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_default_forwarding_value=disabled + - var_accounts_user_umask=027 + - var_sshd_set_login_grace_time=60 + status: automated + - id: cm-6.1 + title: Automated Management, Application, and Verification + levels: + - high + rules: [] + status: pending + - id: cm-6.2 + title: Respond to Unauthorized Changes + levels: + - high + rules: [] + status: pending + - id: cm-6.3 + title: Unauthorized Change Detection + rules: [] + status: pending + - id: cm-6.4 + title: Conformance Demonstration + rules: [] + status: pending + - id: cm-7 + title: Least Functionality + levels: + - low + rules: + - dconf_gnome_disable_autorun + - disable_weak_deps + - file_ownership_var_log_audit_stig + - has_nonlocal_mta + - kernel_module_atm_disabled + - kernel_module_can_disabled + - kernel_module_cramfs_disabled + - kernel_module_dccp_disabled + - kernel_module_firewire-core_disabled + - kernel_module_freevxfs_disabled + - kernel_module_hfs_disabled + - kernel_module_hfsplus_disabled + - kernel_module_jffs2_disabled + - kernel_module_overlayfs_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_squashfs_disabled + - kernel_module_tipc_disabled + - kernel_module_udf_disabled + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_tmp_nodev + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - package_bind_removed + - package_cyrus-imapd_removed + - package_dovecot_removed + - package_ftp_removed + - package_gdm_removed + - package_httpd_removed + - package_kea_removed + - package_net-snmp_removed + - package_nginx_removed + - package_openldap-clients_removed + - package_postfix_installed + - package_sequoia-sq_installed + - package_telnet-server_removed + - package_telnet_removed + - package_tftp-server_removed + - package_tftp_removed + - package_vsftpd_removed + - partition_for_dev_shm + - partition_for_home + - partition_for_tmp + - partition_for_var + - partition_for_var_log + - partition_for_var_log_audit + - partition_for_var_tmp + - postfix_network_listening_disabled + - service_bluetooth_disabled + - service_cockpit_disabled + - service_cups_disabled + - service_dnsmasq_disabled + - sshd_disable_forwarding + - wireless_disable_interfaces + - xwayland_disabled + - var_postfix_inet_interfaces=loopback-only + status: automated + - id: cm-7.1 + title: Periodic Review + levels: + - moderate + rules: [] + status: pending + - id: cm-7.2 + title: Prevent Program Execution + levels: + - moderate + rules: [] + status: pending + - id: cm-7.3 + title: Registration Compliance + rules: [] + status: pending + - id: cm-7.4 + title: Unauthorized Software — Deny-by-exception + rules: [] + status: pending + - id: cm-7.5 + title: Authorized Software — Allow-by-exception + levels: + - moderate + rules: [] + status: pending + - id: cm-7.6 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: cm-7.7 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: cm-7.8 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: cm-7.9 + title: Prohibiting The Use of Unauthorized Hardware + rules: [] + status: pending + - id: cm-8 + title: System Component Inventory + levels: + - low + rules: [] + status: pending + - id: cm-8.1 + title: Updates During Installation and Removal + levels: + - moderate + rules: [] + status: pending + - id: cm-8.2 + title: Automated Maintenance + levels: + - high + rules: [] + status: pending + - id: cm-8.3 + title: Automated Unauthorized Component Detection + levels: + - moderate + rules: [] + status: pending + - id: cm-8.4 + title: Accountability Information + levels: + - high + rules: [] + status: pending + - id: cm-8.5 + title: No Duplicate Accounting of Components + rules: [] + status: pending + - id: cm-8.6 + title: Assessed Configurations and Approved Deviations + rules: [] + status: pending + - id: cm-8.7 + title: Centralized Repository + rules: [] + status: pending + - id: cm-8.8 + title: Automated Location Tracking + rules: [] + status: pending + - id: cm-8.9 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: cm-9 + title: Configuration Management Plan + levels: + - moderate + rules: [] + status: pending + - id: cm-9.1 + title: Assignment of Responsibility + rules: [] + status: pending + - id: cm-10 + title: Software Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: cm-10.1 + title: Open-source Software + rules: [] + status: pending + - id: cm-11 + title: User-installed Software + levels: + - low + rules: + - package_xorg-x11-server-Xwayland_removed + status: automated + - id: cm-11.1 + title: Alerts for Unauthorized Installations + rules: [] + status: pending + - id: cm-11.2 + title: Software Installation with Privileged Status + rules: [] + status: pending + - id: cm-11.3 + title: Automated Enforcement and Monitoring + rules: [] + status: pending + - id: cm-12 + title: Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-12.1 + title: Automated Tools to Support Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-13 + title: Data Action Mapping + rules: [] + status: pending + - id: cm-14 + title: Signed Components + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/cp.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/cp.yml new file mode 100644 index 000000000000..53d97fb34990 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/cp.yml @@ -0,0 +1,296 @@ +# NIST 800-53 CP Family: Contingency Planning +controls: + - id: cp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: cp-2 + title: Contingency Plan + levels: + - low + rules: [] + status: pending + - id: cp-2.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-2.2 + title: Capacity Planning + levels: + - high + rules: [] + status: pending + - id: cp-2.3 + title: Resume Mission and Business Functions + levels: + - moderate + rules: [] + status: pending + - id: cp-2.4 + title: Resume All Mission and Business Functions + rules: [] + status: pending + - id: cp-2.5 + title: Continue Mission and Business Functions + levels: + - high + rules: [] + status: pending + - id: cp-2.6 + title: Alternate Processing and Storage Sites + rules: [] + status: pending + - id: cp-2.7 + title: Coordinate with External Service Providers + rules: [] + status: pending + - id: cp-2.8 + title: Identify Critical Assets + levels: + - moderate + rules: [] + status: pending + - id: cp-3 + title: Contingency Training + levels: + - low + rules: [] + status: pending + - id: cp-3.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: cp-3.2 + title: Mechanisms Used in Training Environments + rules: [] + status: pending + - id: cp-4 + title: Contingency Plan Testing + levels: + - low + rules: [] + status: pending + - id: cp-4.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-4.2 + title: Alternate Processing Site + levels: + - high + rules: [] + status: pending + - id: cp-4.3 + title: Automated Testing + rules: [] + status: pending + - id: cp-4.4 + title: Full Recovery and Reconstitution + rules: [] + status: pending + - id: cp-4.5 + title: Self-challenge + rules: [] + status: pending + - id: cp-5 + title: Contingency Plan Update + rules: [] + status: pending + - id: cp-6 + title: Alternate Storage Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.2 + title: Recovery Time and Recovery Point Objectives + levels: + - high + rules: [] + status: pending + - id: cp-6.3 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7 + title: Alternate Processing Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.2 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7.3 + title: Priority of Service + levels: + - moderate + rules: [] + status: pending + - id: cp-7.4 + title: Preparation for Use + levels: + - high + rules: [] + status: pending + - id: cp-7.5 + title: Equivalent Information Security Safeguards + rules: [] + status: pending + - id: cp-7.6 + title: Inability to Return to Primary Site + rules: [] + status: pending + - id: cp-8 + title: Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: cp-8.1 + title: Priority of Service Provisions + levels: + - moderate + rules: [] + status: pending + - id: cp-8.2 + title: Single Points of Failure + levels: + - moderate + rules: [] + status: pending + - id: cp-8.3 + title: Separation of Primary and Alternate Providers + levels: + - high + rules: [] + status: pending + - id: cp-8.4 + title: Provider Contingency Plan + levels: + - high + rules: [] + status: pending + - id: cp-8.5 + title: Alternate Telecommunication Service Testing + rules: [] + status: pending + - id: cp-9 + title: System Backup + levels: + - low + rules: [] + status: pending + - id: cp-9.1 + title: Testing for Reliability and Integrity + levels: + - moderate + rules: [] + status: pending + - id: cp-9.2 + title: Test Restoration Using Sampling + levels: + - high + rules: [] + status: pending + - id: cp-9.3 + title: Separate Storage for Critical Information + levels: + - high + rules: [] + status: pending + - id: cp-9.4 + title: Protection from Unauthorized Modification + rules: [] + status: pending + - id: cp-9.5 + title: Transfer to Alternate Storage Site + levels: + - high + rules: [] + status: pending + - id: cp-9.6 + title: Redundant Secondary System + rules: [] + status: pending + - id: cp-9.7 + title: Dual Authorization for Deletion or Destruction + rules: [] + status: pending + - id: cp-9.8 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: cp-10 + title: System Recovery and Reconstitution + levels: + - low + rules: [] + status: pending + - id: cp-10.1 + title: Contingency Plan Testing + rules: [] + status: pending + - id: cp-10.2 + title: Transaction Recovery + levels: + - moderate + rules: [] + status: pending + - id: cp-10.3 + title: Compensating Security Controls + rules: [] + status: pending + - id: cp-10.4 + title: Restore Within Time Period + levels: + - high + rules: [] + status: pending + - id: cp-10.5 + title: Failover Capability + rules: [] + status: pending + - id: cp-10.6 + title: Component Protection + rules: [] + status: pending + - id: cp-11 + title: Alternate Communications Protocols + rules: [] + status: pending + - id: cp-12 + title: Safe Mode + rules: [] + status: pending + - id: cp-13 + title: Alternative Security Mechanisms + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ia.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ia.yml new file mode 100644 index 000000000000..25435cbd93b5 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ia.yml @@ -0,0 +1,397 @@ +# NIST 800-53 IA Family: Identification and Authentication +controls: + - id: ia-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ia-2 + title: Identification and Authentication (Organizational Users) + levels: + - low + rules: + - account_unique_id + status: automated + - id: ia-2.1 + title: Multi-factor Authentication to Privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.2 + title: Multi-factor Authentication to Non-privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.3 + title: Local Access to Privileged Accounts + rules: [] + status: pending + - id: ia-2.4 + title: Local Access to Non-privileged Accounts + rules: [] + status: pending + - id: ia-2.5 + title: Individual Authentication with Group Authentication + levels: + - high + rules: [] + status: pending + - id: ia-2.6 + title: Access to Accounts —separate Device + rules: [] + status: pending + - id: ia-2.7 + title: Network Access to Non-privileged Accounts — Separate Device + rules: [] + status: pending + - id: ia-2.8 + title: Access to Accounts — Replay Resistant + levels: + - low + rules: [] + status: pending + - id: ia-2.9 + title: Network Access to Non-privileged Accounts — Replay Resistant + rules: [] + status: pending + - id: ia-2.10 + title: Single Sign-on + rules: [] + status: pending + - id: ia-2.11 + title: Remote Access — Separate Device + rules: [] + status: pending + - id: ia-2.12 + title: Acceptance of PIV Credentials + levels: + - low + rules: [] + status: pending + - id: ia-2.13 + title: Out-of-band Authentication + rules: [] + status: pending + - id: ia-3 + title: Device Identification and Authentication + levels: + - moderate + rules: + - dconf_gnome_disable_automount + - dconf_gnome_disable_automount_open + - kernel_module_usb-storage_disabled + status: automated + - id: ia-3.1 + title: Cryptographic Bidirectional Authentication + rules: [] + status: pending + - id: ia-3.2 + title: Cryptographic Bidirectional Network Authentication + rules: [] + status: pending + - id: ia-3.3 + title: Dynamic Address Allocation + rules: [] + status: pending + - id: ia-3.4 + title: Device Attestation + rules: [] + status: pending + - id: ia-4 + title: Identifier Management + levels: + - low + rules: + - account_disable_post_pw_expiration + - accounts_set_post_pw_existing + - var_account_disable_post_pw_expiration=45 + status: automated + - id: ia-4.1 + title: Prohibit Account Identifiers as Public Identifiers + rules: [] + status: pending + - id: ia-4.2 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-4.3 + title: Multiple Forms of Certification + rules: [] + status: pending + - id: ia-4.4 + title: Identify User Status + levels: + - moderate + rules: [] + status: pending + - id: ia-4.5 + title: Dynamic Management + rules: [] + status: pending + - id: ia-4.6 + title: Cross-organization Management + rules: [] + status: pending + - id: ia-4.7 + title: In-person Registration + rules: [] + status: pending + - id: ia-4.8 + title: Pairwise Pseudonymous Identifiers + rules: [] + status: pending + - id: ia-4.9 + title: Attribute Maintenance and Protection + rules: [] + status: pending + - id: ia-5 + title: Authenticator Management + levels: + - low + rules: + - accounts_minimum_age_login_defs + - accounts_password_all_shadowed + - accounts_password_last_change_is_in_past + - accounts_password_pam_dictcheck + - accounts_password_pam_difok + - accounts_password_pam_enforce_root + - accounts_password_pam_maxrepeat + - accounts_password_pam_maxsequence + - accounts_password_pam_minclass + - accounts_password_pam_minlen + - accounts_password_pam_modules_in_authselect_profile + - accounts_password_pam_pwhistory_enforce_for_root + - accounts_password_pam_pwhistory_use_authtok + - accounts_password_pam_unix_authtok + - accounts_password_set_min_life_existing + - accounts_password_set_warn_age_existing + - accounts_password_warn_age_login_defs + - ensure_root_password_configured + - no_empty_passwords_etc_shadow + - set_password_hashing_algorithm_logindefs + - set_password_hashing_algorithm_passwordauth + - set_password_hashing_algorithm_systemauth + - var_accounts_minimum_age_login_defs=1 + - var_accounts_password_warn_age_login_defs=7 + - var_password_hashing_algorithm=cis_rhel10 + - var_password_hashing_algorithm_pam=cis_rhel10 + - var_password_pam_dictcheck=1 + - var_password_pam_difok=2 + - var_password_pam_maxrepeat=3 + - var_password_pam_maxsequence=3 + - var_password_pam_minclass=4 + - var_password_pam_minlen=14 + status: automated + - id: ia-5.1 + title: Password-based Authentication + levels: + - low + rules: + - accounts_password_pam_pwhistory_remember_password_auth + - accounts_password_pam_pwhistory_remember_system_auth + - accounts_password_pam_unix_enabled + - accounts_password_pam_unix_no_remember + - var_password_pam_remember=24 + - var_password_pam_remember_control_flag=requisite_or_required + status: automated + - id: ia-5.2 + title: Public Key-based Authentication + levels: + - moderate + rules: [] + status: pending + - id: ia-5.3 + title: In-person or Trusted External Party Registration + rules: [] + status: pending + - id: ia-5.4 + title: Automated Support for Password Strength Determination + rules: [] + status: pending + - id: ia-5.5 + title: Change Authenticators Prior to Delivery + rules: [] + status: pending + - id: ia-5.6 + title: Protection of Authenticators + levels: + - moderate + rules: [] + status: pending + - id: ia-5.7 + title: No Embedded Unencrypted Static Authenticators + rules: [] + status: pending + - id: ia-5.8 + title: Multiple System Accounts + rules: [] + status: pending + - id: ia-5.9 + title: Federated Credential Management + rules: [] + status: pending + - id: ia-5.10 + title: Dynamic Credential Binding + rules: [] + status: pending + - id: ia-5.11 + title: Hardware Token-based Authentication + rules: [] + status: pending + - id: ia-5.12 + title: Biometric Authentication Performance + rules: [] + status: pending + - id: ia-5.13 + title: Expiration of Cached Authenticators + rules: [] + status: pending + - id: ia-5.14 + title: Managing Content of PKI Trust Stores + rules: [] + status: pending + - id: ia-5.15 + title: GSA-approved Products and Services + rules: [] + status: pending + - id: ia-5.16 + title: In-person or Trusted External Party Authenticator Issuance + rules: [] + status: pending + - id: ia-5.17 + title: Presentation Attack Detection for Biometric Authenticators + rules: [] + status: pending + - id: ia-5.18 + title: Password Managers + rules: [] + status: pending + - id: ia-6 + title: Authentication Feedback + levels: + - low + rules: [] + status: pending + - id: ia-7 + title: Cryptographic Module Authentication + levels: + - low + rules: [] + status: pending + - id: ia-8 + title: Identification and Authentication (Non-organizational Users) + levels: + - low + rules: [] + status: pending + - id: ia-8.1 + title: Acceptance of PIV Credentials from Other Agencies + levels: + - low + rules: [] + status: pending + - id: ia-8.2 + title: Acceptance of External Authenticators + levels: + - low + rules: [] + status: pending + - id: ia-8.3 + title: Use of FICAM-approved Products + rules: [] + status: pending + - id: ia-8.4 + title: Use of Defined Profiles + levels: + - low + rules: [] + status: pending + - id: ia-8.5 + title: Acceptance of PIV-I Credentials + rules: [] + status: pending + - id: ia-8.6 + title: Disassociability + rules: [] + status: pending + - id: ia-9 + title: Service Identification and Authentication + rules: [] + status: pending + - id: ia-9.1 + title: Information Exchange + rules: [] + status: pending + - id: ia-9.2 + title: Transmission of Decisions + rules: [] + status: pending + - id: ia-10 + title: Adaptive Authentication + rules: [] + status: pending + - id: ia-11 + title: Re-authentication + levels: + - low + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=15_minutes + status: automated + - id: ia-12 + title: Identity Proofing + levels: + - moderate + rules: [] + status: pending + - id: ia-12.1 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-12.2 + title: Identity Evidence + levels: + - moderate + rules: [] + status: pending + - id: ia-12.3 + title: Identity Evidence Validation and Verification + levels: + - moderate + rules: [] + status: pending + - id: ia-12.4 + title: In-person Validation and Verification + levels: + - high + rules: [] + status: pending + - id: ia-12.5 + title: Address Confirmation + levels: + - moderate + rules: [] + status: pending + - id: ia-12.6 + title: Accept Externally-proofed Identities + rules: [] + status: pending + - id: ia-13 + title: Identity Providers and Authorization Servers + rules: [] + status: pending + - id: ia-13.1 + title: Protection of Cryptographic Keys + rules: [] + status: pending + - id: ia-13.2 + title: Verification of Identity Assertions and Access Tokens + rules: [] + status: pending + - id: ia-13.3 + title: Token Management + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ir.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ir.yml new file mode 100644 index 000000000000..2d443099c957 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ir.yml @@ -0,0 +1,206 @@ +# NIST 800-53 IR Family: Incident Response +controls: + - id: ir-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ir-2 + title: Incident Response Training + levels: + - low + rules: [] + status: pending + - id: ir-2.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: ir-2.2 + title: Automated Training Environments + levels: + - high + rules: [] + status: pending + - id: ir-2.3 + title: Breach + rules: [] + status: pending + - id: ir-3 + title: Incident Response Testing + levels: + - moderate + rules: [] + status: pending + - id: ir-3.1 + title: Automated Testing + rules: [] + status: pending + - id: ir-3.2 + title: Coordination with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: ir-3.3 + title: Continuous Improvement + rules: [] + status: pending + - id: ir-4 + title: Incident Handling + levels: + - low + rules: [] + status: pending + - id: ir-4.1 + title: Automated Incident Handling Processes + levels: + - moderate + rules: [] + status: pending + - id: ir-4.2 + title: Dynamic Reconfiguration + rules: [] + status: pending + - id: ir-4.3 + title: Continuity of Operations + rules: [] + status: pending + - id: ir-4.4 + title: Information Correlation + levels: + - high + rules: [] + status: pending + - id: ir-4.5 + title: Automatic Disabling of System + rules: [] + status: pending + - id: ir-4.6 + title: Insider Threats + rules: [] + status: pending + - id: ir-4.7 + title: Insider Threats — Intra-organization Coordination + rules: [] + status: pending + - id: ir-4.8 + title: Correlation with External Organizations + rules: [] + status: pending + - id: ir-4.9 + title: Dynamic Response Capability + rules: [] + status: pending + - id: ir-4.10 + title: Supply Chain Coordination + rules: [] + status: pending + - id: ir-4.11 + title: Integrated Incident Response Team + levels: + - high + rules: [] + status: pending + - id: ir-4.12 + title: Malicious Code and Forensic Analysis + rules: [] + status: pending + - id: ir-4.13 + title: Behavior Analysis + rules: [] + status: pending + - id: ir-4.14 + title: Security Operations Center + rules: [] + status: pending + - id: ir-4.15 + title: Public Relations and Reputation Repair + rules: [] + status: pending + - id: ir-5 + title: Incident Monitoring + levels: + - low + rules: [] + status: pending + - id: ir-5.1 + title: Automated Tracking, Data Collection, and Analysis + levels: + - high + rules: [] + status: pending + - id: ir-6 + title: Incident Reporting + levels: + - low + rules: [] + status: pending + - id: ir-6.1 + title: Automated Reporting + levels: + - moderate + rules: [] + status: pending + - id: ir-6.2 + title: Vulnerabilities Related to Incidents + rules: [] + status: pending + - id: ir-6.3 + title: Supply Chain Coordination + levels: + - moderate + rules: [] + status: pending + - id: ir-7 + title: Incident Response Assistance + levels: + - low + rules: [] + status: pending + - id: ir-7.1 + title: Automation Support for Availability of Information and Support + levels: + - moderate + rules: [] + status: pending + - id: ir-7.2 + title: Coordination with External Providers + rules: [] + status: pending + - id: ir-8 + title: Incident Response Plan + levels: + - low + rules: [] + status: pending + - id: ir-8.1 + title: Breaches + rules: [] + status: pending + - id: ir-9 + title: Information Spillage Response + rules: [] + status: pending + - id: ir-9.1 + title: Responsible Personnel + rules: [] + status: pending + - id: ir-9.2 + title: Training + rules: [] + status: pending + - id: ir-9.3 + title: Post-spill Operations + rules: [] + status: pending + - id: ir-9.4 + title: Exposure to Unauthorized Personnel + rules: [] + status: pending + - id: ir-10 + title: Integrated Information Security Analysis Team + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ma.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ma.yml new file mode 100644 index 000000000000..77bd02932613 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ma.yml @@ -0,0 +1,146 @@ +# NIST 800-53 MA Family: Maintenance +controls: + - id: ma-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ma-2 + title: Controlled Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-2.1 + title: Record Content + rules: [] + status: pending + - id: ma-2.2 + title: Automated Maintenance Activities + levels: + - high + rules: [] + status: pending + - id: ma-3 + title: Maintenance Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.1 + title: Inspect Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.2 + title: Inspect Media + levels: + - moderate + rules: [] + status: pending + - id: ma-3.3 + title: Prevent Unauthorized Removal + levels: + - moderate + rules: [] + status: pending + - id: ma-3.4 + title: Restricted Tool Use + rules: [] + status: pending + - id: ma-3.5 + title: Execution with Privilege + rules: [] + status: pending + - id: ma-3.6 + title: Software Updates and Patches + rules: [] + status: pending + - id: ma-4 + title: Nonlocal Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-4.1 + title: Logging and Review + rules: [] + status: pending + - id: ma-4.2 + title: Document Nonlocal Maintenance + rules: [] + status: pending + - id: ma-4.3 + title: Comparable Security and Sanitization + levels: + - high + rules: [] + status: pending + - id: ma-4.4 + title: Authentication and Separation of Maintenance Sessions + rules: [] + status: pending + - id: ma-4.5 + title: Approvals and Notifications + rules: [] + status: pending + - id: ma-4.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: ma-4.7 + title: Disconnect Verification + rules: [] + status: pending + - id: ma-5 + title: Maintenance Personnel + levels: + - low + rules: [] + status: pending + - id: ma-5.1 + title: Individuals Without Appropriate Access + levels: + - high + rules: [] + status: pending + - id: ma-5.2 + title: Security Clearances for Classified Systems + rules: [] + status: pending + - id: ma-5.3 + title: Citizenship Requirements for Classified Systems + rules: [] + status: pending + - id: ma-5.4 + title: Foreign Nationals + rules: [] + status: pending + - id: ma-5.5 + title: Non-system Maintenance + rules: [] + status: pending + - id: ma-6 + title: Timely Maintenance + levels: + - moderate + rules: [] + status: pending + - id: ma-6.1 + title: Preventive Maintenance + rules: [] + status: pending + - id: ma-6.2 + title: Predictive Maintenance + rules: [] + status: pending + - id: ma-6.3 + title: Automated Support for Predictive Maintenance + rules: [] + status: pending + - id: ma-7 + title: Field Maintenance + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/mp.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/mp.yml new file mode 100644 index 000000000000..6c8e8f46e4e4 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/mp.yml @@ -0,0 +1,142 @@ +# NIST 800-53 MP Family: Media Protection +controls: + - id: mp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: mp-2 + title: Media Access + levels: + - low + rules: [] + status: pending + - id: mp-2.1 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-2.2 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-3 + title: Media Marking + levels: + - moderate + rules: [] + status: pending + - id: mp-4 + title: Media Storage + levels: + - moderate + rules: [] + status: pending + - id: mp-4.1 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-4.2 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-5 + title: Media Transport + levels: + - moderate + rules: [] + status: pending + - id: mp-5.1 + title: Protection Outside of Controlled Areas + rules: [] + status: pending + - id: mp-5.2 + title: Documentation of Activities + rules: [] + status: pending + - id: mp-5.3 + title: Custodians + rules: [] + status: pending + - id: mp-5.4 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-6 + title: Media Sanitization + levels: + - low + rules: [] + status: pending + - id: mp-6.1 + title: Review, Approve, Track, Document, and Verify + levels: + - high + rules: [] + status: pending + - id: mp-6.2 + title: Equipment Testing + levels: + - high + rules: [] + status: pending + - id: mp-6.3 + title: Nondestructive Techniques + levels: + - high + rules: [] + status: pending + - id: mp-6.4 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-6.5 + title: Classified Information + rules: [] + status: pending + - id: mp-6.6 + title: Media Destruction + rules: [] + status: pending + - id: mp-6.7 + title: Dual Authorization + rules: [] + status: pending + - id: mp-6.8 + title: Remote Purging or Wiping of Information + rules: [] + status: pending + - id: mp-7 + title: Media Use + levels: + - low + rules: [] + status: pending + - id: mp-7.1 + title: Prohibit Use Without Owner + rules: [] + status: pending + - id: mp-7.2 + title: Prohibit Use of Sanitization-resistant Media + rules: [] + status: pending + - id: mp-8 + title: Media Downgrading + rules: [] + status: pending + - id: mp-8.1 + title: Documentation of Process + rules: [] + status: pending + - id: mp-8.2 + title: Equipment Testing + rules: [] + status: pending + - id: mp-8.3 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-8.4 + title: Classified Information + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/pe.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/pe.yml new file mode 100644 index 000000000000..b6728c7d49d5 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/pe.yml @@ -0,0 +1,288 @@ +# NIST 800-53 PE Family: Physical and Environmental Protection +controls: + - id: pe-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pe-2 + title: Physical Access Authorizations + levels: + - low + rules: [] + status: pending + - id: pe-2.1 + title: Access by Position or Role + rules: [] + status: pending + - id: pe-2.2 + title: Two Forms of Identification + rules: [] + status: pending + - id: pe-2.3 + title: Restrict Unescorted Access + rules: [] + status: pending + - id: pe-3 + title: Physical Access Control + levels: + - low + rules: [] + status: pending + - id: pe-3.1 + title: System Access + levels: + - high + rules: [] + status: pending + - id: pe-3.2 + title: Facility and Systems + rules: [] + status: pending + - id: pe-3.3 + title: Continuous Guards + rules: [] + status: pending + - id: pe-3.4 + title: Lockable Casings + rules: [] + status: pending + - id: pe-3.5 + title: Tamper Protection + rules: [] + status: pending + - id: pe-3.6 + title: Facility Penetration Testing + rules: [] + status: pending + - id: pe-3.7 + title: Physical Barriers + rules: [] + status: pending + - id: pe-3.8 + title: Access Control Vestibules + rules: [] + status: pending + - id: pe-4 + title: Access Control for Transmission + levels: + - moderate + rules: [] + status: pending + - id: pe-5 + title: Access Control for Output Devices + levels: + - moderate + rules: [] + status: pending + - id: pe-5.1 + title: Access to Output by Authorized Individuals + rules: [] + status: pending + - id: pe-5.2 + title: Link to Individual Identity + rules: [] + status: pending + - id: pe-5.3 + title: Marking Output Devices + rules: [] + status: pending + - id: pe-6 + title: Monitoring Physical Access + levels: + - low + rules: [] + status: pending + - id: pe-6.1 + title: Intrusion Alarms and Surveillance Equipment + levels: + - moderate + rules: [] + status: pending + - id: pe-6.2 + title: Automated Intrusion Recognition and Responses + rules: [] + status: pending + - id: pe-6.3 + title: Video Surveillance + rules: [] + status: pending + - id: pe-6.4 + title: Monitoring Physical Access to Systems + levels: + - high + rules: [] + status: pending + - id: pe-7 + title: Visitor Control + rules: [] + status: pending + - id: pe-8 + title: Visitor Access Records + levels: + - low + rules: [] + status: pending + - id: pe-8.1 + title: Automated Records Maintenance and Review + levels: + - high + rules: [] + status: pending + - id: pe-8.2 + title: Physical Access Records + rules: [] + status: pending + - id: pe-8.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: pe-9 + title: Power Equipment and Cabling + levels: + - moderate + rules: [] + status: pending + - id: pe-9.1 + title: Redundant Cabling + rules: [] + status: pending + - id: pe-9.2 + title: Automatic Voltage Controls + rules: [] + status: pending + - id: pe-10 + title: Emergency Shutoff + levels: + - moderate + rules: [] + status: pending + - id: pe-10.1 + title: Accidental and Unauthorized Activation + rules: [] + status: pending + - id: pe-11 + title: Emergency Power + levels: + - moderate + rules: [] + status: pending + - id: pe-11.1 + title: Alternate Power Supply — Minimal Operational Capability + levels: + - high + rules: [] + status: pending + - id: pe-11.2 + title: Alternate Power Supply — Self-contained + rules: [] + status: pending + - id: pe-12 + title: Emergency Lighting + levels: + - low + rules: [] + status: pending + - id: pe-12.1 + title: Essential Mission and Business Functions + rules: [] + status: pending + - id: pe-13 + title: Fire Protection + levels: + - low + rules: [] + status: pending + - id: pe-13.1 + title: Detection Systems — Automatic Activation and Notification + levels: + - moderate + rules: [] + status: pending + - id: pe-13.2 + title: Suppression Systems — Automatic Activation and Notification + levels: + - high + rules: [] + status: pending + - id: pe-13.3 + title: Automatic Fire Suppression + rules: [] + status: pending + - id: pe-13.4 + title: Inspections + rules: [] + status: pending + - id: pe-14 + title: Environmental Controls + levels: + - low + rules: [] + status: pending + - id: pe-14.1 + title: Automatic Controls + rules: [] + status: pending + - id: pe-14.2 + title: Monitoring with Alarms and Notifications + rules: [] + status: pending + - id: pe-15 + title: Water Damage Protection + levels: + - low + rules: [] + status: pending + - id: pe-15.1 + title: Automation Support + levels: + - high + rules: [] + status: pending + - id: pe-16 + title: Delivery and Removal + levels: + - low + rules: [] + status: pending + - id: pe-17 + title: Alternate Work Site + levels: + - moderate + rules: [] + status: pending + - id: pe-18 + title: Location of System Components + levels: + - high + rules: [] + status: pending + - id: pe-18.1 + title: Facility Site + rules: [] + status: pending + - id: pe-19 + title: Information Leakage + rules: [] + status: pending + - id: pe-19.1 + title: National Emissions Policies and Procedures + rules: [] + status: pending + - id: pe-20 + title: Asset Monitoring and Tracking + rules: [] + status: pending + - id: pe-21 + title: Electromagnetic Pulse Protection + rules: [] + status: pending + - id: pe-22 + title: Component Marking + rules: [] + status: pending + - id: pe-23 + title: Facility Location + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/pl.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/pl.yml new file mode 100644 index 000000000000..d670e154e380 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/pl.yml @@ -0,0 +1,84 @@ +# NIST 800-53 PL Family: Planning +controls: + - id: pl-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pl-2 + title: System Security and Privacy Plans + levels: + - low + rules: [] + status: pending + - id: pl-2.1 + title: Concept of Operations + rules: [] + status: pending + - id: pl-2.2 + title: Functional Architecture + rules: [] + status: pending + - id: pl-2.3 + title: Plan and Coordinate with Other Organizational Entities + rules: [] + status: pending + - id: pl-3 + title: System Security Plan Update + rules: [] + status: pending + - id: pl-4 + title: Rules of Behavior + levels: + - low + rules: [] + status: pending + - id: pl-4.1 + title: Social Media and External Site/Application Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: pl-5 + title: Privacy Impact Assessment + rules: [] + status: pending + - id: pl-6 + title: Security-related Activity Planning + rules: [] + status: pending + - id: pl-7 + title: Concept of Operations + rules: [] + status: pending + - id: pl-8 + title: Security and Privacy Architectures + levels: + - moderate + rules: [] + status: pending + - id: pl-8.1 + title: Defense in Depth + rules: [] + status: pending + - id: pl-8.2 + title: Supplier Diversity + rules: [] + status: pending + - id: pl-9 + title: Central Management + rules: [] + status: pending + - id: pl-10 + title: Baseline Selection + levels: + - low + rules: [] + status: pending + - id: pl-11 + title: Baseline Tailoring + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/pm.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/pm.yml new file mode 100644 index 000000000000..97a32be05deb --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/pm.yml @@ -0,0 +1,151 @@ +# NIST 800-53 PM Family: Program Management +controls: + - id: pm-1 + title: Information Security Program Plan + rules: [] + status: pending + - id: pm-2 + title: Information Security Program Leadership Role + rules: [] + status: pending + - id: pm-3 + title: Information Security and Privacy Resources + rules: [] + status: pending + - id: pm-4 + title: Plan of Action and Milestones Process + rules: [] + status: pending + - id: pm-5 + title: System Inventory + rules: [] + status: pending + - id: pm-5.1 + title: Inventory of Personally Identifiable Information + rules: [] + status: pending + - id: pm-6 + title: Measures of Performance + rules: [] + status: pending + - id: pm-7 + title: Enterprise Architecture + rules: [] + status: pending + - id: pm-7.1 + title: Offloading + rules: [] + status: pending + - id: pm-8 + title: Critical Infrastructure Plan + rules: [] + status: pending + - id: pm-9 + title: Risk Management Strategy + rules: [] + status: pending + - id: pm-10 + title: Authorization Process + rules: [] + status: pending + - id: pm-11 + title: Mission and Business Process Definition + rules: [] + status: pending + - id: pm-12 + title: Insider Threat Program + rules: [] + status: pending + - id: pm-13 + title: Security and Privacy Workforce + rules: [] + status: pending + - id: pm-14 + title: Testing, Training, and Monitoring + rules: [] + status: pending + - id: pm-15 + title: Security and Privacy Groups and Associations + rules: [] + status: pending + - id: pm-16 + title: Threat Awareness Program + rules: [] + status: pending + - id: pm-16.1 + title: Automated Means for Sharing Threat Intelligence + rules: [] + status: pending + - id: pm-17 + title: Protecting Controlled Unclassified Information on External Systems + rules: [] + status: pending + - id: pm-18 + title: Privacy Program Plan + rules: [] + status: pending + - id: pm-19 + title: Privacy Program Leadership Role + rules: [] + status: pending + - id: pm-20 + title: Dissemination of Privacy Program Information + rules: [] + status: pending + - id: pm-20.1 + title: Privacy Policies on Websites, Applications, and Digital Services + rules: [] + status: pending + - id: pm-21 + title: Accounting of Disclosures + rules: [] + status: pending + - id: pm-22 + title: Personally Identifiable Information Quality Management + rules: [] + status: pending + - id: pm-23 + title: Data Governance Body + rules: [] + status: pending + - id: pm-24 + title: Data Integrity Board + rules: [] + status: pending + - id: pm-25 + title: Minimization of Personally Identifiable Information Used in Testing, Training, and + Research + rules: [] + status: pending + - id: pm-26 + title: Complaint Management + rules: [] + status: pending + - id: pm-27 + title: Privacy Reporting + rules: [] + status: pending + - id: pm-28 + title: Risk Framing + rules: [] + status: pending + - id: pm-29 + title: Risk Management Program Leadership Roles + rules: [] + status: pending + - id: pm-30 + title: Supply Chain Risk Management Strategy + rules: [] + status: pending + - id: pm-30.1 + title: Suppliers of Critical or Mission-essential Items + rules: [] + status: pending + - id: pm-31 + title: Continuous Monitoring Strategy + rules: [] + status: pending + - id: pm-32 + title: Purposing + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ps.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ps.yml new file mode 100644 index 000000000000..ad7d70333c17 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ps.yml @@ -0,0 +1,94 @@ +# NIST 800-53 PS Family: Personnel Security +controls: + - id: ps-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ps-2 + title: Position Risk Designation + levels: + - low + rules: [] + status: pending + - id: ps-3 + title: Personnel Screening + levels: + - low + rules: [] + status: pending + - id: ps-3.1 + title: Classified Information + rules: [] + status: pending + - id: ps-3.2 + title: Formal Indoctrination + rules: [] + status: pending + - id: ps-3.3 + title: Information Requiring Special Protective Measures + rules: [] + status: pending + - id: ps-3.4 + title: Citizenship Requirements + rules: [] + status: pending + - id: ps-4 + title: Personnel Termination + levels: + - low + rules: [] + status: pending + - id: ps-4.1 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-4.2 + title: Automated Actions + levels: + - high + rules: [] + status: pending + - id: ps-5 + title: Personnel Transfer + levels: + - low + rules: [] + status: pending + - id: ps-6 + title: Access Agreements + levels: + - low + rules: [] + status: pending + - id: ps-6.1 + title: Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.2 + title: Classified Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.3 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-7 + title: External Personnel Security + levels: + - low + rules: [] + status: pending + - id: ps-8 + title: Personnel Sanctions + levels: + - low + rules: [] + status: pending + - id: ps-9 + title: Position Descriptions + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/pt.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/pt.yml new file mode 100644 index 000000000000..fe3d1ee54437 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/pt.yml @@ -0,0 +1,86 @@ +# NIST 800-53 PT Family: PII Processing and Transparency +controls: + - id: pt-1 + title: Policy and Procedures + rules: [] + status: pending + - id: pt-2 + title: Authority to Process Personally Identifiable Information + rules: [] + status: pending + - id: pt-2.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-2.2 + title: Automation + rules: [] + status: pending + - id: pt-3 + title: Personally Identifiable Information Processing Purposes + rules: [] + status: pending + - id: pt-3.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-3.2 + title: Automation + rules: [] + status: pending + - id: pt-4 + title: Consent + rules: [] + status: pending + - id: pt-4.1 + title: Tailored Consent + rules: [] + status: pending + - id: pt-4.2 + title: Just-in-time Consent + rules: [] + status: pending + - id: pt-4.3 + title: Revocation + rules: [] + status: pending + - id: pt-5 + title: Privacy Notice + rules: [] + status: pending + - id: pt-5.1 + title: Just-in-time Notice + rules: [] + status: pending + - id: pt-5.2 + title: Privacy Act Statements + rules: [] + status: pending + - id: pt-6 + title: System of Records Notice + rules: [] + status: pending + - id: pt-6.1 + title: Routine Uses + rules: [] + status: pending + - id: pt-6.2 + title: Exemption Rules + rules: [] + status: pending + - id: pt-7 + title: Specific Categories of Personally Identifiable Information + rules: [] + status: pending + - id: pt-7.1 + title: Social Security Numbers + rules: [] + status: pending + - id: pt-7.2 + title: First Amendment Information + rules: [] + status: pending + - id: pt-8 + title: Computer Matching Requirements + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/ra.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/ra.yml new file mode 100644 index 000000000000..ca44e21f4e67 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/ra.yml @@ -0,0 +1,128 @@ +# NIST 800-53 RA Family: Risk Assessment +controls: + - id: ra-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ra-2 + title: Security Categorization + levels: + - low + rules: [] + status: pending + - id: ra-2.1 + title: Impact-level Prioritization + rules: [] + status: pending + - id: ra-3 + title: Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.1 + title: Supply Chain Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.2 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: ra-3.3 + title: Dynamic Threat Awareness + rules: [] + status: pending + - id: ra-3.4 + title: Predictive Cyber Analytics + rules: [] + status: pending + - id: ra-4 + title: Risk Assessment Update + rules: [] + status: pending + - id: ra-5 + title: Vulnerability Monitoring and Scanning + levels: + - low + rules: [] + status: pending + - id: ra-5.1 + title: Update Tool Capability + rules: [] + status: pending + - id: ra-5.2 + title: Update Vulnerabilities to Be Scanned + levels: + - low + rules: [] + status: pending + - id: ra-5.3 + title: Breadth and Depth of Coverage + rules: [] + status: pending + - id: ra-5.4 + title: Discoverable Information + levels: + - high + rules: [] + status: pending + - id: ra-5.5 + title: Privileged Access + levels: + - moderate + rules: [] + status: pending + - id: ra-5.6 + title: Automated Trend Analyses + rules: [] + status: pending + - id: ra-5.7 + title: Automated Detection and Notification of Unauthorized Components + rules: [] + status: pending + - id: ra-5.8 + title: Review Historic Audit Logs + rules: [] + status: pending + - id: ra-5.9 + title: Penetration Testing and Analyses + rules: [] + status: pending + - id: ra-5.10 + title: Correlate Scanning Information + rules: [] + status: pending + - id: ra-5.11 + title: Public Disclosure Program + levels: + - low + rules: [] + status: pending + - id: ra-6 + title: Technical Surveillance Countermeasures Survey + rules: [] + status: pending + - id: ra-7 + title: Risk Response + levels: + - low + rules: [] + status: pending + - id: ra-8 + title: Privacy Impact Assessments + rules: [] + status: pending + - id: ra-9 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: ra-10 + title: Threat Hunting + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/sa.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/sa.yml new file mode 100644 index 000000000000..89a619dd4589 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/sa.yml @@ -0,0 +1,632 @@ +# NIST 800-53 SA Family: System and Services Acquisition +controls: + - id: sa-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sa-2 + title: Allocation of Resources + levels: + - low + rules: [] + status: pending + - id: sa-3 + title: System Development Life Cycle + levels: + - low + rules: [] + status: pending + - id: sa-3.1 + title: Manage Preproduction Environment + rules: [] + status: pending + - id: sa-3.2 + title: Use of Live or Operational Data + rules: [] + status: pending + - id: sa-3.3 + title: Technology Refresh + rules: [] + status: pending + - id: sa-4 + title: Acquisition Process + levels: + - low + rules: [] + status: pending + - id: sa-4.1 + title: Functional Properties of Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.2 + title: Design and Implementation Information for Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.3 + title: Development Methods, Techniques, and Practices + rules: [] + status: pending + - id: sa-4.4 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: sa-4.5 + title: System, Component, and Service Configurations + levels: + - high + rules: [] + status: pending + - id: sa-4.6 + title: Use of Information Assurance Products + rules: [] + status: pending + - id: sa-4.7 + title: 'NIAP-approved Protection Profiles ' + rules: [] + status: pending + - id: sa-4.8 + title: Continuous Monitoring Plan for Controls + rules: [] + status: pending + - id: sa-4.9 + title: Functions, Ports, Protocols, and Services in Use + levels: + - moderate + rules: [] + status: pending + - id: sa-4.10 + title: Use of Approved PIV Products + levels: + - low + rules: [] + status: pending + - id: sa-4.11 + title: System of Records + rules: [] + status: pending + - id: sa-4.12 + title: Data Ownership + rules: [] + status: pending + - id: sa-5 + title: System Documentation + levels: + - low + rules: [] + status: pending + - id: sa-5.1 + title: Functional Properties of Security Controls + rules: [] + status: pending + - id: sa-5.2 + title: Security-relevant External System Interfaces + rules: [] + status: pending + - id: sa-5.3 + title: High-level Design + rules: [] + status: pending + - id: sa-5.4 + title: Low-level Design + rules: [] + status: pending + - id: sa-5.5 + title: Source Code + rules: [] + status: pending + - id: sa-6 + title: Software Usage Restrictions + rules: [] + status: pending + - id: sa-7 + title: User-installed Software + rules: [] + status: pending + - id: sa-8 + title: Security and Privacy Engineering Principles + levels: + - low + rules: [] + status: pending + - id: sa-8.1 + title: Clear Abstractions + rules: [] + status: pending + - id: sa-8.2 + title: Least Common Mechanism + rules: [] + status: pending + - id: sa-8.3 + title: Modularity and Layering + rules: [] + status: pending + - id: sa-8.4 + title: Partially Ordered Dependencies + rules: [] + status: pending + - id: sa-8.5 + title: Efficiently Mediated Access + rules: [] + status: pending + - id: sa-8.6 + title: Minimized Sharing + rules: [] + status: pending + - id: sa-8.7 + title: Reduced Complexity + rules: [] + status: pending + - id: sa-8.8 + title: Secure Evolvability + rules: [] + status: pending + - id: sa-8.9 + title: Trusted Components + rules: [] + status: pending + - id: sa-8.10 + title: Hierarchical Trust + rules: [] + status: pending + - id: sa-8.11 + title: Inverse Modification Threshold + rules: [] + status: pending + - id: sa-8.12 + title: Hierarchical Protection + rules: [] + status: pending + - id: sa-8.13 + title: Minimized Security Elements + rules: [] + status: pending + - id: sa-8.14 + title: Least Privilege + rules: [] + status: pending + - id: sa-8.15 + title: Predicate Permission + rules: [] + status: pending + - id: sa-8.16 + title: Self-reliant Trustworthiness + rules: [] + status: pending + - id: sa-8.17 + title: Secure Distributed Composition + rules: [] + status: pending + - id: sa-8.18 + title: Trusted Communications Channels + rules: [] + status: pending + - id: sa-8.19 + title: Continuous Protection + rules: [] + status: pending + - id: sa-8.20 + title: Secure Metadata Management + rules: [] + status: pending + - id: sa-8.21 + title: Self-analysis + rules: [] + status: pending + - id: sa-8.22 + title: Accountability and Traceability + rules: [] + status: pending + - id: sa-8.23 + title: Secure Defaults + rules: [] + status: pending + - id: sa-8.24 + title: Secure Failure and Recovery + rules: [] + status: pending + - id: sa-8.25 + title: Economic Security + rules: [] + status: pending + - id: sa-8.26 + title: Performance Security + rules: [] + status: pending + - id: sa-8.27 + title: Human Factored Security + rules: [] + status: pending + - id: sa-8.28 + title: Acceptable Security + rules: [] + status: pending + - id: sa-8.29 + title: Repeatable and Documented Procedures + rules: [] + status: pending + - id: sa-8.30 + title: Procedural Rigor + rules: [] + status: pending + - id: sa-8.31 + title: Secure System Modification + rules: [] + status: pending + - id: sa-8.32 + title: Sufficient Documentation + rules: [] + status: pending + - id: sa-8.33 + title: Minimization + rules: [] + status: pending + - id: sa-9 + title: External System Services + levels: + - low + rules: [] + status: pending + - id: sa-9.1 + title: Risk Assessments and Organizational Approvals + rules: [] + status: pending + - id: sa-9.2 + title: Identification of Functions, Ports, Protocols, and Services + levels: + - moderate + rules: [] + status: pending + - id: sa-9.3 + title: Establish and Maintain Trust Relationship with Providers + rules: [] + status: pending + - id: sa-9.4 + title: Consistent Interests of Consumers and Providers + rules: [] + status: pending + - id: sa-9.5 + title: Processing, Storage, and Service Location + rules: [] + status: pending + - id: sa-9.6 + title: Organization-controlled Cryptographic Keys + rules: [] + status: pending + - id: sa-9.7 + title: Organization-controlled Integrity Checking + rules: [] + status: pending + - id: sa-9.8 + title: Processing and Storage Location — U.S. Jurisdiction + rules: [] + status: pending + - id: sa-10 + title: Developer Configuration Management + levels: + - moderate + rules: [] + status: pending + - id: sa-10.1 + title: Software and Firmware Integrity Verification + rules: [] + status: pending + - id: sa-10.2 + title: Alternative Configuration Management Processes + rules: [] + status: pending + - id: sa-10.3 + title: Hardware Integrity Verification + rules: [] + status: pending + - id: sa-10.4 + title: Trusted Generation + rules: [] + status: pending + - id: sa-10.5 + title: Mapping Integrity for Version Control + rules: [] + status: pending + - id: sa-10.6 + title: Trusted Distribution + rules: [] + status: pending + - id: sa-10.7 + title: Security and Privacy Representatives + rules: [] + status: pending + - id: sa-11 + title: Developer Testing and Evaluation + levels: + - moderate + rules: [] + status: pending + - id: sa-11.1 + title: Static Code Analysis + rules: [] + status: pending + - id: sa-11.2 + title: Threat Modeling and Vulnerability Analyses + rules: [] + status: pending + - id: sa-11.3 + title: Independent Verification of Assessment Plans and Evidence + rules: [] + status: pending + - id: sa-11.4 + title: Manual Code Reviews + rules: [] + status: pending + - id: sa-11.5 + title: Penetration Testing + rules: [] + status: pending + - id: sa-11.6 + title: Attack Surface Reviews + rules: [] + status: pending + - id: sa-11.7 + title: Verify Scope of Testing and Evaluation + rules: [] + status: pending + - id: sa-11.8 + title: Dynamic Code Analysis + rules: [] + status: pending + - id: sa-11.9 + title: Interactive Application Security Testing + rules: [] + status: pending + - id: sa-12 + title: Supply Chain Protection + rules: [] + status: pending + - id: sa-12.1 + title: Acquisition Strategies / Tools / Methods + rules: [] + status: pending + - id: sa-12.2 + title: Supplier Reviews + rules: [] + status: pending + - id: sa-12.3 + title: Trusted Shipping and Warehousing + rules: [] + status: pending + - id: sa-12.4 + title: Diversity of Suppliers + rules: [] + status: pending + - id: sa-12.5 + title: Limitation of Harm + rules: [] + status: pending + - id: sa-12.6 + title: Minimizing Procurement Time + rules: [] + status: pending + - id: sa-12.7 + title: Assessments Prior to Selection / Acceptance / Update + rules: [] + status: pending + - id: sa-12.8 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: sa-12.9 + title: Operations Security + rules: [] + status: pending + - id: sa-12.10 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sa-12.11 + title: Penetration Testing / Analysis of Elements, Processes, and Actors + rules: [] + status: pending + - id: sa-12.12 + title: Inter-organizational Agreements + rules: [] + status: pending + - id: sa-12.13 + title: Critical Information System Components + rules: [] + status: pending + - id: sa-12.14 + title: Identity and Traceability + rules: [] + status: pending + - id: sa-12.15 + title: Processes to Address Weaknesses or Deficiencies + rules: [] + status: pending + - id: sa-13 + title: Trustworthiness + rules: [] + status: pending + - id: sa-14 + title: Criticality Analysis + rules: [] + status: pending + - id: sa-14.1 + title: Critical Components with No Viable Alternative Sourcing + rules: [] + status: pending + - id: sa-15 + title: Development Process, Standards, and Tools + levels: + - moderate + rules: [] + status: pending + - id: sa-15.1 + title: Quality Metrics + rules: [] + status: pending + - id: sa-15.2 + title: Security and Privacy Tracking Tools + rules: [] + status: pending + - id: sa-15.3 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: sa-15.4 + title: Threat Modeling and Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.5 + title: Attack Surface Reduction + rules: [] + status: pending + - id: sa-15.6 + title: Continuous Improvement + rules: [] + status: pending + - id: sa-15.7 + title: Automated Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.8 + title: Reuse of Threat and Vulnerability Information + rules: [] + status: pending + - id: sa-15.9 + title: Use of Live Data + rules: [] + status: pending + - id: sa-15.10 + title: Incident Response Plan + rules: [] + status: pending + - id: sa-15.11 + title: Archive System or Component + rules: [] + status: pending + - id: sa-15.12 + title: Minimize Personally Identifiable Information + rules: [] + status: pending + - id: sa-15.13 + title: Logging Syntax + rules: [] + status: pending + - id: sa-16 + title: Developer-provided Training + levels: + - high + rules: [] + status: pending + - id: sa-17 + title: Developer Security and Privacy Architecture and Design + levels: + - high + rules: [] + status: pending + - id: sa-17.1 + title: Formal Policy Model + rules: [] + status: pending + - id: sa-17.2 + title: Security-relevant Components + rules: [] + status: pending + - id: sa-17.3 + title: Formal Correspondence + rules: [] + status: pending + - id: sa-17.4 + title: Informal Correspondence + rules: [] + status: pending + - id: sa-17.5 + title: Conceptually Simple Design + rules: [] + status: pending + - id: sa-17.6 + title: Structure for Testing + rules: [] + status: pending + - id: sa-17.7 + title: Structure for Least Privilege + rules: [] + status: pending + - id: sa-17.8 + title: Orchestration + rules: [] + status: pending + - id: sa-17.9 + title: Design Diversity + rules: [] + status: pending + - id: sa-18 + title: Tamper Resistance and Detection + rules: [] + status: pending + - id: sa-18.1 + title: Multiple Phases of System Development Life Cycle + rules: [] + status: pending + - id: sa-18.2 + title: Inspection of Systems or Components + rules: [] + status: pending + - id: sa-19 + title: Component Authenticity + rules: [] + status: pending + - id: sa-19.1 + title: Anti-counterfeit Training + rules: [] + status: pending + - id: sa-19.2 + title: Configuration Control for Component Service and Repair + rules: [] + status: pending + - id: sa-19.3 + title: Component Disposal + rules: [] + status: pending + - id: sa-19.4 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sa-20 + title: Customized Development of Critical Components + rules: [] + status: pending + - id: sa-21 + title: Developer Screening + levels: + - high + rules: [] + status: pending + - id: sa-21.1 + title: Validation of Screening + rules: [] + status: pending + - id: sa-22 + title: Unsupported System Components + levels: + - low + rules: [] + status: pending + - id: sa-22.1 + title: Alternative Sources for Continued Support + rules: [] + status: pending + - id: sa-23 + title: Specialization + rules: [] + status: pending + - id: sa-24 + title: Design For Cyber Resiliency + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/sc.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/sc.yml new file mode 100644 index 000000000000..1cea755d3a41 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/sc.yml @@ -0,0 +1,720 @@ +# NIST 800-53 SC Family: System and Communications Protection +controls: + - id: sc-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sc-2 + title: Separation of System and User Functionality + levels: + - moderate + rules: + - sysctl_kernel_dmesg_restrict + status: automated + - id: sc-2.1 + title: Interfaces for Non-privileged Users + rules: [] + status: pending + - id: sc-2.2 + title: Disassociability + rules: [] + status: pending + - id: sc-3 + title: Security Function Isolation + levels: + - high + rules: + - selinux_not_disabled + - selinux_state + - var_selinux_state=enforcing + status: automated + - id: sc-3.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-3.2 + title: Access and Flow Control Functions + rules: [] + status: pending + - id: sc-3.3 + title: Minimize Nonsecurity Functionality + rules: [] + status: pending + - id: sc-3.4 + title: Module Coupling and Cohesiveness + rules: [] + status: pending + - id: sc-3.5 + title: Layered Structures + rules: [] + status: pending + - id: sc-4 + title: Information in Shared System Resources + levels: + - moderate + rules: + - dir_perms_world_writable_sticky_bits + - file_permissions_unauthorized_world_writable + status: automated + - id: sc-4.1 + title: Security Levels + rules: [] + status: pending + - id: sc-4.2 + title: Multilevel or Periods Processing + rules: [] + status: pending + - id: sc-5 + title: Denial-of-service Protection + levels: + - low + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + - id: sc-5.1 + title: Restrict Ability to Attack Other Systems + rules: [] + status: pending + - id: sc-5.2 + title: Capacity, Bandwidth, and Redundancy + rules: [] + status: pending + - id: sc-5.3 + title: Detection and Monitoring + rules: [] + status: pending + - id: sc-6 + title: Resource Availability + rules: [] + status: pending + - id: sc-7 + title: Boundary Protection + levels: + - low + rules: + - service_firewalld_enabled + status: automated + - id: sc-7.1 + title: Physically Separated Subnetworks + rules: [] + status: pending + - id: sc-7.2 + title: Public Access + rules: [] + status: pending + - id: sc-7.3 + title: Access Points + levels: + - moderate + rules: [] + status: pending + - id: sc-7.4 + title: External Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: sc-7.5 + title: Deny by Default — Allow by Exception + levels: + - moderate + rules: [] + status: pending + - id: sc-7.6 + title: Response to Recognized Failures + rules: [] + status: pending + - id: sc-7.7 + title: Split Tunneling for Remote Devices + levels: + - moderate + rules: [] + status: pending + - id: sc-7.8 + title: Route Traffic to Authenticated Proxy Servers + levels: + - moderate + rules: [] + status: pending + - id: sc-7.9 + title: Restrict Threatening Outgoing Communications Traffic + rules: [] + status: pending + - id: sc-7.10 + title: Prevent Exfiltration + rules: [] + status: pending + - id: sc-7.11 + title: Restrict Incoming Communications Traffic + rules: [] + status: pending + - id: sc-7.12 + title: Host-based Protection + rules: [] + status: pending + - id: sc-7.13 + title: Isolation of Security Tools, Mechanisms, and Support Components + rules: [] + status: pending + - id: sc-7.14 + title: Protect Against Unauthorized Physical Connections + rules: [] + status: pending + - id: sc-7.15 + title: Networked Privileged Accesses + rules: [] + status: pending + - id: sc-7.16 + title: Prevent Discovery of System Components + rules: [] + status: pending + - id: sc-7.17 + title: Automated Enforcement of Protocol Formats + rules: [] + status: pending + - id: sc-7.18 + title: Fail Secure + levels: + - high + rules: [] + status: pending + - id: sc-7.19 + title: Block Communication from Non-organizationally Configured Hosts + rules: [] + status: pending + - id: sc-7.20 + title: Dynamic Isolation and Segregation + rules: [] + status: pending + - id: sc-7.21 + title: Isolation of System Components + levels: + - high + rules: [] + status: pending + - id: sc-7.22 + title: Separate Subnets for Connecting to Different Security Domains + rules: [] + status: pending + - id: sc-7.23 + title: Disable Sender Feedback on Protocol Validation Failure + rules: [] + status: pending + - id: sc-7.24 + title: Personally Identifiable Information + rules: [] + status: pending + - id: sc-7.25 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: sc-7.26 + title: Classified National Security System Connections + rules: [] + status: pending + - id: sc-7.27 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: sc-7.28 + title: Connections to Public Networks + rules: [] + status: pending + - id: sc-7.29 + title: Separate Subnets to Isolate Functions + rules: [] + status: pending + - id: sc-8 + title: Transmission Confidentiality and Integrity + levels: + - moderate + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: sc-8.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-8.2 + title: Pre- and Post-transmission Handling + rules: [] + status: pending + - id: sc-8.3 + title: Cryptographic Protection for Message Externals + rules: [] + status: pending + - id: sc-8.4 + title: Conceal or Randomize Communications + rules: [] + status: pending + - id: sc-8.5 + title: Protected Distribution System + rules: [] + status: pending + - id: sc-9 + title: Transmission Confidentiality + rules: [] + status: pending + - id: sc-10 + title: Network Disconnect + levels: + - moderate + rules: [] + status: pending + - id: sc-11 + title: Trusted Path + rules: [] + status: pending + - id: sc-11.1 + title: Irrefutable Communications Path + rules: [] + status: pending + - id: sc-12 + title: Cryptographic Key Establishment and Management + levels: + - low + rules: [] + status: pending + - id: sc-12.1 + title: Availability + levels: + - high + rules: [] + status: pending + - id: sc-12.2 + title: Symmetric Keys + rules: [] + status: pending + - id: sc-12.3 + title: Asymmetric Keys + rules: [] + status: pending + - id: sc-12.4 + title: PKI Certificates + rules: [] + status: pending + - id: sc-12.5 + title: PKI Certificates / Hardware Tokens + rules: [] + status: pending + - id: sc-12.6 + title: Physical Control of Keys + rules: [] + status: pending + - id: sc-13 + title: Cryptographic Protection + levels: + - low + rules: [] + status: pending + - id: sc-13.1 + title: FIPS-validated Cryptography + rules: [] + status: pending + - id: sc-13.2 + title: NSA-approved Cryptography + rules: [] + status: pending + - id: sc-13.3 + title: Individuals Without Formal Access Approvals + rules: [] + status: pending + - id: sc-13.4 + title: Digital Signatures + rules: [] + status: pending + - id: sc-14 + title: Public Access Protections + rules: [] + status: pending + - id: sc-15 + title: Collaborative Computing Devices and Applications + levels: + - low + rules: [] + status: pending + - id: sc-15.1 + title: Physical or Logical Disconnect + rules: [] + status: pending + - id: sc-15.2 + title: Blocking Inbound and Outbound Communications Traffic + rules: [] + status: pending + - id: sc-15.3 + title: Disabling and Removal in Secure Work Areas + rules: [] + status: pending + - id: sc-15.4 + title: Explicitly Indicate Current Participants + rules: [] + status: pending + - id: sc-16 + title: Transmission of Security and Privacy Attributes + rules: [] + status: pending + - id: sc-16.1 + title: Integrity Verification + rules: [] + status: pending + - id: sc-16.2 + title: Anti-spoofing Mechanisms + rules: [] + status: pending + - id: sc-16.3 + title: Cryptographic Binding + rules: [] + status: pending + - id: sc-17 + title: Public Key Infrastructure Certificates + levels: + - moderate + rules: [] + status: pending + - id: sc-18 + title: Mobile Code + levels: + - moderate + rules: [] + status: pending + - id: sc-18.1 + title: Identify Unacceptable Code and Take Corrective Actions + rules: [] + status: pending + - id: sc-18.2 + title: Acquisition, Development, and Use + rules: [] + status: pending + - id: sc-18.3 + title: Prevent Downloading and Execution + rules: [] + status: pending + - id: sc-18.4 + title: Prevent Automatic Execution + rules: [] + status: pending + - id: sc-18.5 + title: Allow Execution Only in Confined Environments + rules: [] + status: pending + - id: sc-19 + title: Voice Over Internet Protocol + rules: [] + status: pending + - id: sc-20 + title: Secure Name/Address Resolution Service (Authoritative Source) + levels: + - low + rules: [] + status: pending + - id: sc-20.1 + title: Child Subspaces + rules: [] + status: pending + - id: sc-20.2 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-21 + title: Secure Name/Address Resolution Service (Recursive or Caching Resolver) + levels: + - low + rules: [] + status: pending + - id: sc-21.1 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-22 + title: Architecture and Provisioning for Name/Address Resolution Service + levels: + - low + rules: [] + status: pending + - id: sc-23 + title: Session Authenticity + levels: + - moderate + rules: [] + status: pending + - id: sc-23.1 + title: Invalidate Session Identifiers at Logout + rules: [] + status: pending + - id: sc-23.2 + title: User-initiated Logouts and Message Displays + rules: [] + status: pending + - id: sc-23.3 + title: Unique System-generated Session Identifiers + rules: [] + status: pending + - id: sc-23.4 + title: Unique Session Identifiers with Randomization + rules: [] + status: pending + - id: sc-23.5 + title: Allowed Certificate Authorities + rules: [] + status: pending + - id: sc-24 + title: Fail in Known State + levels: + - high + rules: + - service_systemd-journald_enabled + status: automated + - id: sc-25 + title: Thin Nodes + rules: [] + status: pending + - id: sc-26 + title: Decoys + rules: [] + status: pending + - id: sc-26.1 + title: Detection of Malicious Code + rules: [] + status: pending + - id: sc-27 + title: Platform-independent Applications + rules: [] + status: pending + - id: sc-28 + title: Protection of Information at Rest + levels: + - moderate + rules: [] + status: pending + - id: sc-28.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-28.2 + title: Offline Storage + rules: [] + status: pending + - id: sc-28.3 + title: Cryptographic Keys + rules: [] + status: pending + - id: sc-29 + title: Heterogeneity + rules: [] + status: pending + - id: sc-29.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30 + title: Concealment and Misdirection + rules: [] + status: pending + - id: sc-30.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30.2 + title: Randomness + rules: [] + status: pending + - id: sc-30.3 + title: Change Processing and Storage Locations + rules: [] + status: pending + - id: sc-30.4 + title: Misleading Information + rules: [] + status: pending + - id: sc-30.5 + title: Concealment of System Components + rules: [] + status: pending + - id: sc-31 + title: Covert Channel Analysis + rules: [] + status: pending + - id: sc-31.1 + title: Test Covert Channels for Exploitability + rules: [] + status: pending + - id: sc-31.2 + title: Maximum Bandwidth + rules: [] + status: pending + - id: sc-31.3 + title: Measure Bandwidth in Operational Environments + rules: [] + status: pending + - id: sc-32 + title: System Partitioning + rules: [] + status: pending + - id: sc-32.1 + title: Separate Physical Domains for Privileged Functions + rules: [] + status: pending + - id: sc-33 + title: Transmission Preparation Integrity + rules: [] + status: pending + - id: sc-34 + title: Non-modifiable Executable Programs + rules: [] + status: pending + - id: sc-34.1 + title: No Writable Storage + rules: [] + status: pending + - id: sc-34.2 + title: Integrity Protection on Read-only Media + rules: [] + status: pending + - id: sc-34.3 + title: Hardware-based Protection + rules: [] + status: pending + - id: sc-35 + title: External Malicious Code Identification + rules: [] + status: pending + - id: sc-36 + title: Distributed Processing and Storage + rules: [] + status: pending + - id: sc-36.1 + title: Polling Techniques + rules: [] + status: pending + - id: sc-36.2 + title: Synchronization + rules: [] + status: pending + - id: sc-37 + title: Out-of-band Channels + rules: [] + status: pending + - id: sc-37.1 + title: Ensure Delivery and Transmission + rules: [] + status: pending + - id: sc-38 + title: Operations Security + rules: [] + status: pending + - id: sc-39 + title: Process Isolation + levels: + - low + rules: [] + status: pending + - id: sc-39.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-39.2 + title: Separate Execution Domain Per Thread + rules: [] + status: pending + - id: sc-40 + title: Wireless Link Protection + rules: [] + status: pending + - id: sc-40.1 + title: Electromagnetic Interference + rules: [] + status: pending + - id: sc-40.2 + title: Reduce Detection Potential + rules: [] + status: pending + - id: sc-40.3 + title: Imitative or Manipulative Communications Deception + rules: [] + status: pending + - id: sc-40.4 + title: Signal Parameter Identification + rules: [] + status: pending + - id: sc-41 + title: Port and I/O Device Access + rules: [] + status: pending + - id: sc-42 + title: Sensor Capability and Data + rules: [] + status: pending + - id: sc-42.1 + title: Reporting to Authorized Individuals or Roles + rules: [] + status: pending + - id: sc-42.2 + title: Authorized Use + rules: [] + status: pending + - id: sc-42.3 + title: Prohibit Use of Devices + rules: [] + status: pending + - id: sc-42.4 + title: Notice of Collection + rules: [] + status: pending + - id: sc-42.5 + title: Collection Minimization + rules: [] + status: pending + - id: sc-43 + title: Usage Restrictions + rules: [] + status: pending + - id: sc-44 + title: Detonation Chambers + rules: [] + status: pending + - id: sc-45 + title: System Time Synchronization + rules: [] + status: pending + - id: sc-45.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: sc-45.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: sc-46 + title: Cross Domain Policy Enforcement + rules: [] + status: pending + - id: sc-47 + title: Alternate Communications Paths + rules: [] + status: pending + - id: sc-48 + title: Sensor Relocation + rules: [] + status: pending + - id: sc-48.1 + title: Dynamic Relocation of Sensors or Monitoring Capabilities + rules: [] + status: pending + - id: sc-49 + title: Hardware-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-50 + title: Software-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-51 + title: Hardware-based Protection + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/si.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/si.yml new file mode 100644 index 000000000000..d34ca6e0d67c --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/si.yml @@ -0,0 +1,544 @@ +# NIST 800-53 SI Family: System and Information Integrity +controls: + - id: si-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: si-2 + title: Flaw Remediation + levels: + - low + rules: + - ensure_gpgcheck_globally_activated + - ensure_redhat_gpgkey_installed + status: automated + - id: si-2.1 + title: Central Management + rules: [] + status: pending + - id: si-2.2 + title: Automated Flaw Remediation Status + levels: + - moderate + rules: [] + status: pending + - id: si-2.3 + title: Time to Remediate Flaws and Benchmarks for Corrective Actions + rules: [] + status: pending + - id: si-2.4 + title: Automated Patch Management Tools + rules: [] + status: pending + - id: si-2.5 + title: Automatic Software and Firmware Updates + rules: [] + status: pending + - id: si-2.6 + title: Removal of Previous Versions of Software and Firmware + rules: [] + status: pending + - id: si-2.7 + title: Root Cause Analysis + rules: [] + status: pending + - id: si-3 + title: Malicious Code Protection + levels: + - low + rules: + - kernel_module_usb-storage_disabled + - service_autofs_disabled + status: automated + - id: si-3.1 + title: Central Management + rules: [] + status: pending + - id: si-3.2 + title: Automatic Updates + rules: [] + status: pending + - id: si-3.3 + title: Non-privileged Users + rules: [] + status: pending + - id: si-3.4 + title: Updates Only by Privileged Users + rules: [] + status: pending + - id: si-3.5 + title: Portable Storage Devices + rules: [] + status: pending + - id: si-3.6 + title: Testing and Verification + rules: [] + status: pending + - id: si-3.7 + title: Nonsignature-based Detection + rules: [] + status: pending + - id: si-3.8 + title: Detect Unauthorized Commands + rules: [] + status: pending + - id: si-3.9 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: si-3.10 + title: Malicious Code Analysis + rules: [] + status: pending + - id: si-4 + title: System Monitoring + levels: + - low + rules: + - kernel_module_dccp_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_tipc_disabled + - service_avahi-daemon_disabled + status: automated + - id: si-4.1 + title: System-wide Intrusion Detection System + rules: [] + status: pending + - id: si-4.2 + title: Automated Tools and Mechanisms for Real-time Analysis + levels: + - moderate + rules: [] + status: pending + - id: si-4.3 + title: Automated Tool and Mechanism Integration + rules: [] + status: pending + - id: si-4.4 + title: Inbound and Outbound Communications Traffic + levels: + - moderate + rules: [] + status: pending + - id: si-4.5 + title: System-generated Alerts + levels: + - moderate + rules: [] + status: pending + - id: si-4.6 + title: Restrict Non-privileged Users + rules: [] + status: pending + - id: si-4.7 + title: Automated Response to Suspicious Events + rules: [] + status: pending + - id: si-4.8 + title: Protection of Monitoring Information + rules: [] + status: pending + - id: si-4.9 + title: Testing of Monitoring Tools and Mechanisms + rules: [] + status: pending + - id: si-4.10 + title: Visibility of Encrypted Communications + levels: + - high + rules: [] + status: pending + - id: si-4.11 + title: Analyze Communications Traffic Anomalies + rules: [] + status: pending + - id: si-4.12 + title: Automated Organization-generated Alerts + levels: + - high + rules: [] + status: pending + - id: si-4.13 + title: Analyze Traffic and Event Patterns + rules: [] + status: pending + - id: si-4.14 + title: Wireless Intrusion Detection + levels: + - high + rules: [] + status: pending + - id: si-4.15 + title: Wireless to Wireline Communications + rules: [] + status: pending + - id: si-4.16 + title: Correlate Monitoring Information + rules: [] + status: pending + - id: si-4.17 + title: Integrated Situational Awareness + rules: [] + status: pending + - id: si-4.18 + title: Analyze Traffic and Covert Exfiltration + rules: [] + status: pending + - id: si-4.19 + title: Risk for Individuals + rules: [] + status: pending + - id: si-4.20 + title: Privileged Users + levels: + - high + rules: [] + status: pending + - id: si-4.21 + title: Probationary Periods + rules: [] + status: pending + - id: si-4.22 + title: Unauthorized Network Services + levels: + - high + rules: [] + status: pending + - id: si-4.23 + title: Host-based Devices + rules: [] + status: pending + - id: si-4.24 + title: Indicators of Compromise + rules: [] + status: pending + - id: si-4.25 + title: Optimize Network Traffic Analysis + rules: [] + status: pending + - id: si-5 + title: Security Alerts, Advisories, and Directives + levels: + - low + rules: [] + status: pending + - id: si-5.1 + title: Automated Alerts and Advisories + levels: + - high + rules: [] + status: pending + - id: si-6 + title: Security and Privacy Function Verification + levels: + - high + rules: [] + status: pending + - id: si-6.1 + title: Notification of Failed Security Tests + rules: [] + status: pending + - id: si-6.2 + title: Automation Support for Distributed Testing + rules: [] + status: pending + - id: si-6.3 + title: Report Verification Results + rules: [] + status: pending + - id: si-7 + title: Software, Firmware, and Information Integrity + levels: + - moderate + rules: [] + status: pending + - id: si-7.1 + title: Integrity Checks + levels: + - moderate + rules: [] + status: pending + - id: si-7.2 + title: Automated Notifications of Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.3 + title: Centrally Managed Integrity Tools + rules: [] + status: pending + - id: si-7.4 + title: Tamper-evident Packaging + rules: [] + status: pending + - id: si-7.5 + title: Automated Response to Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: si-7.7 + title: Integration of Detection and Response + levels: + - moderate + rules: [] + status: pending + - id: si-7.8 + title: Auditing Capability for Significant Events + rules: [] + status: pending + - id: si-7.9 + title: Verify Boot Process + rules: [] + status: pending + - id: si-7.10 + title: Protection of Boot Firmware + rules: [] + status: pending + - id: si-7.11 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: si-7.12 + title: Integrity Verification + rules: [] + status: pending + - id: si-7.13 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: si-7.14 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: si-7.15 + title: Code Authentication + levels: + - high + rules: [] + status: pending + - id: si-7.16 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-7.17 + title: Runtime Application Self-protection + rules: [] + status: pending + - id: si-8 + title: Spam Protection + levels: + - moderate + rules: [] + status: pending + - id: si-8.1 + title: Central Management + rules: [] + status: pending + - id: si-8.2 + title: Automatic Updates + levels: + - moderate + rules: [] + status: pending + - id: si-8.3 + title: Continuous Learning Capability + rules: [] + status: pending + - id: si-9 + title: Information Input Restrictions + rules: [] + status: pending + - id: si-10 + title: Information Input Validation + levels: + - moderate + rules: [] + status: pending + - id: si-10.1 + title: Manual Override Capability + rules: [] + status: pending + - id: si-10.2 + title: Review and Resolve Errors + rules: [] + status: pending + - id: si-10.3 + title: Predictable Behavior + rules: [] + status: pending + - id: si-10.4 + title: Timing Interactions + rules: [] + status: pending + - id: si-10.5 + title: Restrict Inputs to Trusted Sources and Approved Formats + rules: [] + status: pending + - id: si-10.6 + title: Injection Prevention + rules: [] + status: pending + - id: si-11 + title: Error Handling + levels: + - moderate + rules: [] + status: pending + - id: si-12 + title: Information Management and Retention + levels: + - low + rules: [] + status: pending + - id: si-12.1 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: si-12.2 + title: Minimize Personally Identifiable Information in Testing, Training, and Research + rules: [] + status: pending + - id: si-12.3 + title: Information Disposal + rules: [] + status: pending + - id: si-13 + title: Predictable Failure Prevention + rules: [] + status: pending + - id: si-13.1 + title: Transferring Component Responsibilities + rules: [] + status: pending + - id: si-13.2 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-13.3 + title: Manual Transfer Between Components + rules: [] + status: pending + - id: si-13.4 + title: Standby Component Installation and Notification + rules: [] + status: pending + - id: si-13.5 + title: Failover Capability + rules: [] + status: pending + - id: si-14 + title: Non-persistence + rules: [] + status: pending + - id: si-14.1 + title: Refresh from Trusted Sources + rules: [] + status: pending + - id: si-14.2 + title: Non-persistent Information + rules: [] + status: pending + - id: si-14.3 + title: Non-persistent Connectivity + rules: [] + status: pending + - id: si-15 + title: Information Output Filtering + rules: [] + status: pending + - id: si-16 + title: Memory Protection + levels: + - moderate + rules: + - sysctl_kernel_randomize_va_space + status: automated + - id: si-17 + title: Fail-safe Procedures + rules: [] + status: pending + - id: si-18 + title: Personally Identifiable Information Quality Operations + rules: [] + status: pending + - id: si-18.1 + title: Automation Support + rules: [] + status: pending + - id: si-18.2 + title: Data Tags + rules: [] + status: pending + - id: si-18.3 + title: Collection + rules: [] + status: pending + - id: si-18.4 + title: Individual Requests + rules: [] + status: pending + - id: si-18.5 + title: Notice of Correction or Deletion + rules: [] + status: pending + - id: si-19 + title: De-identification + rules: [] + status: pending + - id: si-19.1 + title: Collection + rules: [] + status: pending + - id: si-19.2 + title: Archiving + rules: [] + status: pending + - id: si-19.3 + title: Release + rules: [] + status: pending + - id: si-19.4 + title: Removal, Masking, Encryption, Hashing, or Replacement of Direct Identifiers + rules: [] + status: pending + - id: si-19.5 + title: Statistical Disclosure Control + rules: [] + status: pending + - id: si-19.6 + title: Differential Privacy + rules: [] + status: pending + - id: si-19.7 + title: Validated Algorithms and Software + rules: [] + status: pending + - id: si-19.8 + title: Motivated Intruder + rules: [] + status: pending + - id: si-20 + title: Tainting + rules: [] + status: pending + - id: si-21 + title: Information Refresh + rules: [] + status: pending + - id: si-22 + title: Information Diversity + rules: [] + status: pending + - id: si-23 + title: Information Fragmentation + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel10/sr.yml b/shared/references/controls/nist_800_53_cis_reference_rhel10/sr.yml new file mode 100644 index 000000000000..1e130f32cd89 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel10/sr.yml @@ -0,0 +1,138 @@ +# NIST 800-53 SR Family: Supply Chain Risk Management +controls: + - id: sr-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sr-2 + title: Supply Chain Risk Management Plan + levels: + - low + rules: [] + status: pending + - id: sr-2.1 + title: Establish SCRM Team + levels: + - low + rules: [] + status: pending + - id: sr-3 + title: Supply Chain Controls and Processes + levels: + - low + rules: [] + status: pending + - id: sr-3.1 + title: Diverse Supply Base + rules: [] + status: pending + - id: sr-3.2 + title: Limitation of Harm + rules: [] + status: pending + - id: sr-3.3 + title: Sub-tier Flow Down + rules: [] + status: pending + - id: sr-4 + title: Provenance + rules: [] + status: pending + - id: sr-4.1 + title: Identity + rules: [] + status: pending + - id: sr-4.2 + title: Track and Trace + rules: [] + status: pending + - id: sr-4.3 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sr-4.4 + title: Supply Chain Integrity — Pedigree + rules: [] + status: pending + - id: sr-5 + title: Acquisition Strategies, Tools, and Methods + levels: + - low + rules: [] + status: pending + - id: sr-5.1 + title: Adequate Supply + rules: [] + status: pending + - id: sr-5.2 + title: Assessments Prior to Selection, Acceptance, Modification, or Update + rules: [] + status: pending + - id: sr-6 + title: Supplier Assessments and Reviews + levels: + - moderate + rules: [] + status: pending + - id: sr-6.1 + title: Testing and Analysis + rules: [] + status: pending + - id: sr-7 + title: Supply Chain Operations Security + rules: [] + status: pending + - id: sr-8 + title: Notification Agreements + levels: + - low + rules: [] + status: pending + - id: sr-9 + title: Tamper Resistance and Detection + levels: + - high + rules: [] + status: pending + - id: sr-9.1 + title: Multiple Stages of System Development Life Cycle + levels: + - high + rules: [] + status: pending + - id: sr-10 + title: Inspection of Systems or Components + levels: + - low + rules: [] + status: pending + - id: sr-11 + title: Component Authenticity + levels: + - low + rules: [] + status: pending + - id: sr-11.1 + title: Anti-counterfeit Training + levels: + - low + rules: [] + status: pending + - id: sr-11.2 + title: Configuration Control for Component Service and Repair + levels: + - low + rules: [] + status: pending + - id: sr-11.3 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sr-12 + title: Component Disposal + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8.yml new file mode 100644 index 000000000000..aa1045b48671 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8.yml @@ -0,0 +1,24 @@ +# AUTO-GENERATED Product-Specific CIS Reference File (RHEL8) +# +# This file contains only metadata for RHEL8. +# Control families are in nist_800_53_cis_reference_rhel8/ +# Do NOT edit manually. Updated by weekly sync workflow. +# +# OSCAL metadata (description, parameters, guidance, related_controls) is NOT +# included in control files. Retrieve from OSCAL catalog when needed. +# +policy: NIST 800-53 Revision 5 CIS Reference (RHEL8) +title: NIST Special Publication 800-53 Revision 5 CIS Reference for RHEL8 +id: nist_800_53_cis_reference_rhel8 +version: Revision 5 +source: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +product: rhel8 +controls_dir: nist_800_53_cis_reference_rhel8 +levels: + - id: low + - id: moderate + inherits_from: + - low + - id: high + inherits_from: + - moderate diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ac.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ac.yml new file mode 100644 index 000000000000..78c4fc76330f --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ac.yml @@ -0,0 +1,848 @@ +# NIST 800-53 AC Family: Access Control +controls: + - id: ac-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ac-2 + title: Account Management + levels: + - low + rules: [] + status: pending + - id: ac-2.1 + title: Automated System Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.2 + title: Automated Temporary and Emergency Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.3 + title: Disable Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-2.4 + title: Automated Audit Actions + levels: + - moderate + rules: [] + status: pending + - id: ac-2.5 + title: Inactivity Logout + levels: + - moderate + rules: + - accounts_tmout + - no_invalid_shell_accounts_unlocked + - no_password_auth_for_systemaccounts + - no_shelllogin_for_systemaccounts + - inactivity_timeout_value=15_minutes + - var_accounts_tmout=15_min + status: automated + - id: ac-2.6 + title: Dynamic Privilege Management + rules: [] + status: pending + - id: ac-2.7 + title: Privileged User Accounts + rules: [] + status: pending + - id: ac-2.8 + title: Dynamic Account Management + rules: [] + status: pending + - id: ac-2.9 + title: Restrictions on Use of Shared and Group Accounts + rules: [] + status: pending + - id: ac-2.10 + title: Shared and Group Account Credential Change + rules: [] + status: pending + - id: ac-2.11 + title: Usage Conditions + levels: + - high + rules: [] + status: pending + - id: ac-2.12 + title: Account Monitoring for Atypical Usage + levels: + - high + rules: [] + status: pending + - id: ac-2.13 + title: Disable Accounts for High-risk Individuals + levels: + - moderate + rules: [] + status: pending + - id: ac-3 + title: Access Enforcement + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_umask_root + - audit_rules_immutable + - dir_perms_world_writable_sticky_bits + - ensure_pam_wheel_group_empty + - file_at_allow_exists + - file_at_deny_not_exist + - file_cron_allow_exists + - file_cron_deny_not_exist + - file_groupowner_at_allow + - file_groupowner_backup_etc_group + - file_groupowner_backup_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - file_groupowner_cron_allow + - file_groupowner_cron_d + - file_groupowner_cron_daily + - file_groupowner_cron_hourly + - file_groupowner_cron_monthly + - file_groupowner_cron_weekly + - file_groupowner_cron_yearly + - file_groupowner_crontab + - file_groupowner_etc_group + - file_groupowner_etc_gshadow + - file_groupowner_etc_issue + - file_groupowner_etc_issue_net + - file_groupowner_etc_motd + - file_groupowner_etc_passwd + - file_groupowner_etc_security_opasswd + - file_groupowner_etc_security_opasswd_old + - file_groupowner_etc_shadow + - file_groupowner_etc_shells + - file_groupowner_etc_sysconfig_sshd + - file_groupowner_grub2_cfg + - file_groupowner_sshd_config + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_at_allow + - file_owner_backup_etc_group + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_owner_backup_etc_shadow + - file_owner_cron_allow + - file_owner_cron_d + - file_owner_cron_daily + - file_owner_cron_hourly + - file_owner_cron_monthly + - file_owner_cron_weekly + - file_owner_cron_yearly + - file_owner_crontab + - file_owner_etc_group + - file_owner_etc_gshadow + - file_owner_etc_issue + - file_owner_etc_issue_net + - file_owner_etc_motd + - file_owner_etc_passwd + - file_owner_etc_security_opasswd + - file_owner_etc_security_opasswd_old + - file_owner_etc_shadow + - file_owner_etc_shells + - file_owner_etc_sysconfig_sshd + - file_owner_grub2_cfg + - file_owner_sshd_config + - file_owner_user_cfg + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_at_allow + - file_permissions_backup_etc_group + - file_permissions_backup_etc_gshadow + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_shadow + - file_permissions_cron_allow + - file_permissions_cron_d + - file_permissions_cron_daily + - file_permissions_cron_hourly + - file_permissions_cron_monthly + - file_permissions_cron_weekly + - file_permissions_cron_yearly + - file_permissions_crontab + - file_permissions_etc_group + - file_permissions_etc_gshadow + - file_permissions_etc_issue + - file_permissions_etc_issue_net + - file_permissions_etc_motd + - file_permissions_etc_passwd + - file_permissions_etc_security_opasswd + - file_permissions_etc_security_opasswd_old + - file_permissions_etc_shadow + - file_permissions_etc_shells + - file_permissions_etc_sysconfig_sshd + - file_permissions_grub2_cfg + - file_permissions_sshd_config + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_unauthorized_world_writable + - file_permissions_user_cfg + - grub2_enable_selinux + - grub2_password + - grub2_uefi_password + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_home_nodev + - mount_option_home_nosuid + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - mount_option_var_log_audit_nodev + - mount_option_var_log_audit_noexec + - mount_option_var_log_audit_nosuid + - mount_option_var_log_nodev + - mount_option_var_log_noexec + - mount_option_var_log_nosuid + - mount_option_var_nodev + - mount_option_var_nosuid + - mount_option_var_tmp_nodev + - mount_option_var_tmp_noexec + - mount_option_var_tmp_nosuid + - package_libselinux_installed + - package_mcstrans_removed + - package_setroubleshoot_removed + - rsyslog_filecreatemode + - rsyslog_files_groupownership + - rsyslog_files_ownership + - rsyslog_files_permissions + - selinux_not_disabled + - selinux_policytype + - sshd_limit_user_access + - sysctl_fs_protected_hardlinks + - sysctl_fs_protected_symlinks + - use_pam_wheel_group_for_su + - var_accounts_user_umask=027 + - var_pam_wheel_group_for_su=cis + - var_selinux_policy_name=targeted + status: automated + - id: ac-3.1 + title: Restricted Access to Privileged Functions + rules: [] + status: pending + - id: ac-3.2 + title: Dual Authorization + rules: [] + status: pending + - id: ac-3.3 + title: Mandatory Access Control + rules: [] + status: pending + - id: ac-3.4 + title: Discretionary Access Control + rules: [] + status: pending + - id: ac-3.5 + title: Security-relevant Information + rules: [] + status: pending + - id: ac-3.6 + title: Protection of User and System Information + rules: [] + status: pending + - id: ac-3.7 + title: Role-based Access Control + rules: [] + status: pending + - id: ac-3.8 + title: Revocation of Access Authorizations + rules: [] + status: pending + - id: ac-3.9 + title: Controlled Release + rules: [] + status: pending + - id: ac-3.10 + title: Audited Override of Access Control Mechanisms + rules: [] + status: pending + - id: ac-3.11 + title: Restrict Access to Specific Information Types + rules: [] + status: pending + - id: ac-3.12 + title: Assert and Enforce Application Access + rules: [] + status: pending + - id: ac-3.13 + title: Attribute-based Access Control + rules: [] + status: pending + - id: ac-3.14 + title: Individual Access + rules: [] + status: pending + - id: ac-3.15 + title: Discretionary and Mandatory Access Control + rules: [] + status: pending + - id: ac-4 + title: Information Flow Enforcement + levels: + - moderate + rules: [] + status: pending + - id: ac-4.1 + title: Object Security and Privacy Attributes + rules: [] + status: pending + - id: ac-4.2 + title: Processing Domains + rules: [] + status: pending + - id: ac-4.3 + title: Dynamic Information Flow Control + rules: [] + status: pending + - id: ac-4.4 + title: Flow Control of Encrypted Information + levels: + - high + rules: [] + status: pending + - id: ac-4.5 + title: Embedded Data Types + rules: [] + status: pending + - id: ac-4.6 + title: Metadata + rules: [] + status: pending + - id: ac-4.7 + title: One-way Flow Mechanisms + rules: [] + status: pending + - id: ac-4.8 + title: Security and Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.9 + title: Human Reviews + rules: [] + status: pending + - id: ac-4.10 + title: Enable and Disable Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.11 + title: Configuration of Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.12 + title: Data Type Identifiers + rules: [] + status: pending + - id: ac-4.13 + title: Decomposition into Policy-relevant Subcomponents + rules: [] + status: pending + - id: ac-4.14 + title: Security or Privacy Policy Filter Constraints + rules: [] + status: pending + - id: ac-4.15 + title: Detection of Unsanctioned Information + rules: [] + status: pending + - id: ac-4.16 + title: Information Transfers on Interconnected Systems + rules: [] + status: pending + - id: ac-4.17 + title: Domain Authentication + rules: [] + status: pending + - id: ac-4.18 + title: Security Attribute Binding + rules: [] + status: pending + - id: ac-4.19 + title: Validation of Metadata + rules: [] + status: pending + - id: ac-4.20 + title: Approved Solutions + rules: [] + status: pending + - id: ac-4.21 + title: Physical or Logical Separation of Information Flows + rules: [] + status: pending + - id: ac-4.22 + title: Access Only + rules: [] + status: pending + - id: ac-4.23 + title: Modify Non-releasable Information + rules: [] + status: pending + - id: ac-4.24 + title: Internal Normalized Format + rules: [] + status: pending + - id: ac-4.25 + title: Data Sanitization + rules: [] + status: pending + - id: ac-4.26 + title: Audit Filtering Actions + rules: [] + status: pending + - id: ac-4.27 + title: Redundant/Independent Filtering Mechanisms + rules: [] + status: pending + - id: ac-4.28 + title: Linear Filter Pipelines + rules: [] + status: pending + - id: ac-4.29 + title: Filter Orchestration Engines + rules: [] + status: pending + - id: ac-4.30 + title: Filter Mechanisms Using Multiple Processes + rules: [] + status: pending + - id: ac-4.31 + title: Failed Content Transfer Prevention + rules: [] + status: pending + - id: ac-4.32 + title: Process Requirements for Information Transfer + rules: [] + status: pending + - id: ac-5 + title: Separation of Duties + levels: + - moderate + rules: [] + status: pending + - id: ac-6 + title: Least Privilege + levels: + - moderate + rules: + - sshd_disable_root_login + - sudo_add_use_pty + - sudo_remove_no_authenticate + - sudo_remove_nopasswd + status: automated + - id: ac-6.1 + title: Authorize Access to Security Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.2 + title: Non-privileged Access for Nonsecurity Functions + levels: + - moderate + rules: + - package_sudo_installed + status: automated + - id: ac-6.3 + title: Network Access to Privileged Commands + levels: + - high + rules: [] + status: pending + - id: ac-6.4 + title: Separate Processing Domains + rules: [] + status: pending + - id: ac-6.5 + title: Privileged Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-6.6 + title: Privileged Access by Non-organizational Users + rules: [] + status: pending + - id: ac-6.7 + title: Review of User Privileges + levels: + - moderate + rules: [] + status: pending + - id: ac-6.8 + title: Privilege Levels for Code Execution + rules: [] + status: pending + - id: ac-6.9 + title: Log Use of Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.10 + title: Prohibit Non-privileged Users from Executing Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-7 + title: Unsuccessful Logon Attempts + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - accounts_passwords_pam_faillock_deny + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - accounts_passwords_pam_faillock_unlock_time_with_zero + - var_accounts_passwords_pam_faillock_deny=5 + - var_accounts_passwords_pam_faillock_dir=run + - var_accounts_passwords_pam_faillock_root_unlock_time=60 + - var_accounts_passwords_pam_faillock_unlock_time=900 + status: automated + - id: ac-7.1 + title: Automatic Account Lock + rules: [] + status: pending + - id: ac-7.2 + title: Purge or Wipe Mobile Device + rules: [] + status: pending + - id: ac-7.3 + title: Biometric Attempt Limiting + rules: [] + status: pending + - id: ac-7.4 + title: Use of Alternate Authentication Factor + rules: [] + status: pending + - id: ac-8 + title: System Use Notification + levels: + - low + rules: + - dconf_gnome_banner_enabled + - dconf_gnome_login_banner_text + status: automated + - id: ac-9 + title: Previous Logon Notification + rules: [] + status: pending + - id: ac-9.1 + title: Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.2 + title: Successful and Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.3 + title: Notification of Account Changes + rules: [] + status: pending + - id: ac-9.4 + title: Additional Logon Information + rules: [] + status: pending + - id: ac-10 + title: Concurrent Session Control + levels: + - high + rules: [] + status: pending + - id: ac-11 + title: Device Lock + levels: + - moderate + rules: + - dconf_gnome_screensaver_idle_delay + - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_user_locks + - dconf_gnome_session_idle_user_locks + - var_screensaver_lock_delay=5_seconds + status: automated + - id: ac-11.1 + title: Pattern-hiding Displays + levels: + - moderate + rules: [] + status: pending + - id: ac-12 + title: Session Termination + levels: + - moderate + rules: [] + status: pending + - id: ac-12.1 + title: User-initiated Logouts + rules: [] + status: pending + - id: ac-12.2 + title: Termination Message + rules: [] + status: pending + - id: ac-12.3 + title: Timeout Warning Message + rules: [] + status: pending + - id: ac-13 + title: Supervision and Review — Access Control + rules: [] + status: pending + - id: ac-14 + title: Permitted Actions Without Identification or Authentication + levels: + - low + rules: [] + status: pending + - id: ac-14.1 + title: Necessary Uses + rules: [] + status: pending + - id: ac-15 + title: Automated Marking + rules: [] + status: pending + - id: ac-16 + title: Security and Privacy Attributes + rules: [] + status: pending + - id: ac-16.1 + title: Dynamic Attribute Association + rules: [] + status: pending + - id: ac-16.2 + title: Attribute Value Changes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.3 + title: Maintenance of Attribute Associations by System + rules: [] + status: pending + - id: ac-16.4 + title: Association of Attributes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.5 + title: Attribute Displays on Objects to Be Output + rules: [] + status: pending + - id: ac-16.6 + title: Maintenance of Attribute Association + rules: [] + status: pending + - id: ac-16.7 + title: Consistent Attribute Interpretation + rules: [] + status: pending + - id: ac-16.8 + title: Association Techniques and Technologies + rules: [] + status: pending + - id: ac-16.9 + title: Attribute Reassignment — Regrading Mechanisms + rules: [] + status: pending + - id: ac-16.10 + title: Attribute Configuration by Authorized Individuals + rules: [] + status: pending + - id: ac-17 + title: Remote Access + levels: + - low + rules: + - configure_custom_crypto_policy_cis + - configure_ssh_crypto_policy + status: automated + - id: ac-17.1 + title: Monitoring and Control + levels: + - moderate + rules: [] + status: pending + - id: ac-17.2 + title: Protection of Confidentiality and Integrity Using Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-17.3 + title: Managed Access Control Points + levels: + - moderate + rules: [] + status: pending + - id: ac-17.4 + title: Privileged Commands and Access + levels: + - moderate + rules: [] + status: pending + - id: ac-17.5 + title: Monitoring for Unauthorized Connections + rules: [] + status: pending + - id: ac-17.6 + title: Protection of Mechanism Information + rules: [] + status: pending + - id: ac-17.7 + title: Additional Protection for Security Function Access + rules: [] + status: pending + - id: ac-17.8 + title: Disable Nonsecure Network Protocols + rules: [] + status: pending + - id: ac-17.9 + title: Disconnect or Disable Access + rules: [] + status: pending + - id: ac-17.10 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: ac-18 + title: Wireless Access + levels: + - low + rules: + - wireless_disable_interfaces + status: automated + - id: ac-18.1 + title: Authentication and Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-18.2 + title: Monitoring Unauthorized Connections + rules: [] + status: pending + - id: ac-18.3 + title: Disable Wireless Networking + levels: + - moderate + rules: [] + status: pending + - id: ac-18.4 + title: Restrict Configurations by Users + levels: + - high + rules: [] + status: pending + - id: ac-18.5 + title: Antennas and Transmission Power Levels + levels: + - high + rules: [] + status: pending + - id: ac-19 + title: Access Control for Mobile Devices + levels: + - low + rules: [] + status: pending + - id: ac-19.1 + title: Use of Writable and Portable Storage Devices + rules: [] + status: pending + - id: ac-19.2 + title: Use of Personally Owned Portable Storage Devices + rules: [] + status: pending + - id: ac-19.3 + title: Use of Portable Storage Devices with No Identifiable Owner + rules: [] + status: pending + - id: ac-19.4 + title: Restrictions for Classified Information + rules: [] + status: pending + - id: ac-19.5 + title: Full Device or Container-based Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-20 + title: Use of External Systems + levels: + - low + rules: [] + status: pending + - id: ac-20.1 + title: Limits on Authorized Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.2 + title: Portable Storage Devices — Restricted Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.3 + title: Non-organizationally Owned Systems — Restricted Use + rules: [] + status: pending + - id: ac-20.4 + title: Network Accessible Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-20.5 + title: Portable Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-21 + title: Information Sharing + levels: + - moderate + rules: [] + status: pending + - id: ac-21.1 + title: Automated Decision Support + rules: [] + status: pending + - id: ac-21.2 + title: Information Search and Retrieval + rules: [] + status: pending + - id: ac-22 + title: Publicly Accessible Content + levels: + - low + rules: [] + status: pending + - id: ac-23 + title: Data Mining Protection + rules: [] + status: pending + - id: ac-24 + title: Access Control Decisions + rules: [] + status: pending + - id: ac-24.1 + title: Transmit Access Authorization Information + rules: [] + status: pending + - id: ac-24.2 + title: No User or Process Identity + rules: [] + status: pending + - id: ac-25 + title: Reference Monitor + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/at.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/at.yml new file mode 100644 index 000000000000..80211cdb5591 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/at.yml @@ -0,0 +1,82 @@ +# NIST 800-53 AT Family: Awareness and Training +controls: + - id: at-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: at-2 + title: Literacy Training and Awareness + levels: + - low + rules: [] + status: pending + - id: at-2.1 + title: Practical Exercises + rules: [] + status: pending + - id: at-2.2 + title: Insider Threat + levels: + - low + rules: [] + status: pending + - id: at-2.3 + title: Social Engineering and Mining + levels: + - moderate + rules: [] + status: pending + - id: at-2.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-2.5 + title: Advanced Persistent Threat + rules: [] + status: pending + - id: at-2.6 + title: Cyber Threat Environment + rules: [] + status: pending + - id: at-3 + title: Role-based Training + levels: + - low + rules: [] + status: pending + - id: at-3.1 + title: Environmental Controls + rules: [] + status: pending + - id: at-3.2 + title: Physical Security Controls + rules: [] + status: pending + - id: at-3.3 + title: Practical Exercises + rules: [] + status: pending + - id: at-3.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-3.5 + title: Processing Personally Identifiable Information + rules: [] + status: pending + - id: at-4 + title: Training Records + levels: + - low + rules: [] + status: pending + - id: at-5 + title: Contacts with Security Groups and Associations + rules: [] + status: pending + - id: at-6 + title: Training Feedback + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/au.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/au.yml new file mode 100644 index 000000000000..aba4aa5b8ec9 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/au.yml @@ -0,0 +1,479 @@ +# NIST 800-53 AU Family: Audit and Accountability +controls: + - id: au-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: au-2 + title: Event Logging + levels: + - low + rules: + - aide_build_database + - aide_periodic_cron_checking + - audit_rules_execution_chacl + - audit_rules_execution_chcon + - audit_rules_execution_setfacl + - audit_rules_privileged_commands_usermod + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - auditd_data_retention_admin_space_left_action + - auditd_data_retention_space_left_action + - grub2_audit_backlog_limit_argument + - journald_disable_forward_to_syslog + - package_aide_installed + - package_audit-libs_installed + - package_audit_installed + - package_systemd-journal-remote_installed + - rsyslog_nolisten + - service_auditd_enabled + - service_rsyslog_enabled + - service_systemd-journal-upload_enabled + - service_systemd-journald_enabled + - socket_systemd-journal-remote_disabled + - var_audit_backlog_limit=8192 + - var_auditd_admin_space_left_action=cis_rhel8 + - var_auditd_space_left_action=cis_rhel8 + status: automated + - id: au-2.1 + title: Compilation of Audit Records from Multiple Sources + rules: [] + status: pending + - id: au-2.2 + title: Selection of Audit Events by Component + rules: [] + status: pending + - id: au-2.3 + title: Reviews and Updates + rules: [] + status: pending + - id: au-2.4 + title: Privileged Functions + rules: [] + status: pending + - id: au-3 + title: Content of Audit Records + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_mac_modification + - audit_rules_mac_modification_usr_share + - audit_rules_networkconfig_modification + - audit_rules_networkconfig_modification_network_scripts + - audit_rules_privileged_commands + - audit_rules_privileged_commands_kmod + - audit_rules_session_events_btmp + - audit_rules_session_events_utmp + - audit_rules_session_events_wtmp + - audit_rules_suid_auid_privilege_function + - audit_rules_sysadmin_actions + - audit_rules_time_adjtimex + - audit_rules_time_clock_settime + - audit_rules_time_settimeofday + - audit_rules_time_watch_localtime + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - chronyd_run_as_chrony_user + - chronyd_specify_remote_server + - directory_permissions_var_log_audit + - file_groupownership_audit_binaries + - file_ownership_var_log_audit_stig + - file_permissions_audit_binaries + - journald_storage + - package_chrony_installed + - sshd_set_loglevel_verbose + - sshd_set_max_auth_tries + - sudo_custom_logfile + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_default_log_martians + - sshd_max_auth_tries_value=4 + - var_multiple_time_servers=rhel + status: automated + - id: au-3.1 + title: Additional Audit Information + levels: + - moderate + rules: [] + status: pending + - id: au-3.2 + title: Centralized Management of Planned Audit Record Content + rules: [] + status: pending + - id: au-3.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: au-4 + title: Audit Log Storage Capacity + levels: + - low + rules: + - journald_compress + status: automated + - id: au-4.1 + title: Transfer to Alternate Storage + rules: [] + status: pending + - id: au-5 + title: Response to Audit Logging Process Failures + levels: + - low + rules: + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - var_auditd_disk_error_action=cis_rhel8 + - var_auditd_disk_full_action=cis_rhel8 + status: automated + - id: au-5.1 + title: Storage Capacity Warning + levels: + - high + rules: [] + status: pending + - id: au-5.2 + title: Real-time Alerts + levels: + - high + rules: [] + status: pending + - id: au-5.3 + title: Configurable Traffic Volume Thresholds + rules: [] + status: pending + - id: au-5.4 + title: Shutdown on Failure + rules: [] + status: pending + - id: au-5.5 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-6 + title: Audit Record Review, Analysis, and Reporting + levels: + - low + rules: [] + status: pending + - id: au-6.1 + title: Automated Process Integration + levels: + - moderate + rules: [] + status: pending + - id: au-6.2 + title: Automated Security Alerts + rules: [] + status: pending + - id: au-6.3 + title: Correlate Audit Record Repositories + levels: + - moderate + rules: [] + status: pending + - id: au-6.4 + title: Central Review and Analysis + rules: [] + status: pending + - id: au-6.5 + title: Integrated Analysis of Audit Records + levels: + - high + rules: [] + status: pending + - id: au-6.6 + title: Correlation with Physical Monitoring + levels: + - high + rules: [] + status: pending + - id: au-6.7 + title: Permitted Actions + rules: [] + status: pending + - id: au-6.8 + title: Full Text Analysis of Privileged Commands + rules: [] + status: pending + - id: au-6.9 + title: Correlation with Information from Nontechnical Sources + rules: [] + status: pending + - id: au-6.10 + title: Audit Level Adjustment + rules: [] + status: pending + - id: au-7 + title: Audit Record Reduction and Report Generation + levels: + - moderate + rules: [] + status: pending + - id: au-7.1 + title: Automatic Processing + levels: + - moderate + rules: [] + status: pending + - id: au-7.2 + title: Automatic Sort and Search + rules: [] + status: pending + - id: au-8 + title: Time Stamps + levels: + - low + rules: + - auditd_data_retention_max_log_file + - auditd_data_retention_max_log_file_action + - var_auditd_max_log_file=8 + - var_auditd_max_log_file_action=keep_logs + status: automated + - id: au-8.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: au-8.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: au-9 + title: Protection of Audit Information + levels: + - low + rules: + - audit_rules_immutable + - file_groupownership_audit_configuration + - file_ownership_audit_binaries + - file_ownership_audit_configuration + status: automated + - id: au-9.1 + title: Hardware Write-once Media + rules: [] + status: pending + - id: au-9.2 + title: Store on Separate Physical Systems or Components + levels: + - high + rules: [] + status: pending + - id: au-9.3 + title: Cryptographic Protection + levels: + - high + rules: + - aide_check_audit_tools + status: automated + - id: au-9.4 + title: Access by Subset of Privileged Users + levels: + - moderate + rules: + - file_group_ownership_var_log_audit + - file_permissions_var_log_audit + status: automated + - id: au-9.5 + title: Dual Authorization + rules: [] + status: pending + - id: au-9.6 + title: Read-only Access + rules: [] + status: pending + - id: au-9.7 + title: Store on Component with Different Operating System + rules: [] + status: pending + - id: au-10 + title: Non-repudiation + levels: + - high + rules: [] + status: pending + - id: au-10.1 + title: Association of Identities + rules: [] + status: pending + - id: au-10.2 + title: Validate Binding of Information Producer Identity + rules: [] + status: pending + - id: au-10.3 + title: Chain of Custody + rules: [] + status: pending + - id: au-10.4 + title: Validate Binding of Information Reviewer Identity + rules: [] + status: pending + - id: au-10.5 + title: Digital Signatures + rules: [] + status: pending + - id: au-11 + title: Audit Record Retention + levels: + - low + rules: [] + status: pending + - id: au-11.1 + title: Long-term Retrieval Capability + rules: [] + status: pending + - id: au-12 + title: Audit Record Generation + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_continue_loading + - audit_rules_execution_chcon + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_unlinkat + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_media_export + - audit_rules_privileged_commands_kmod + - audit_rules_privileged_commands_usermod + - audit_rules_sysadmin_actions + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - audit_sudo_log_events + - file_permissions_audit_configuration + - grub2_audit_argument + - service_auditd_enabled + status: automated + - id: au-12.1 + title: System-wide and Time-correlated Audit Trail + levels: + - high + rules: [] + status: pending + - id: au-12.2 + title: Standardized Formats + rules: [] + status: pending + - id: au-12.3 + title: Changes by Authorized Individuals + levels: + - high + rules: [] + status: pending + - id: au-12.4 + title: Query Parameter Audits of Personally Identifiable Information + rules: [] + status: pending + - id: au-13 + title: Monitoring for Information Disclosure + rules: [] + status: pending + - id: au-13.1 + title: Use of Automated Tools + rules: [] + status: pending + - id: au-13.2 + title: Review of Monitored Sites + rules: [] + status: pending + - id: au-13.3 + title: Unauthorized Replication of Information + rules: [] + status: pending + - id: au-14 + title: Session Audit + rules: [] + status: pending + - id: au-14.1 + title: System Start-up + rules: [] + status: pending + - id: au-14.2 + title: Capture and Record Content + rules: [] + status: pending + - id: au-14.3 + title: Remote Viewing and Listening + rules: [] + status: pending + - id: au-15 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-16 + title: Cross-organizational Audit Logging + rules: [] + status: pending + - id: au-16.1 + title: Identity Preservation + rules: [] + status: pending + - id: au-16.2 + title: Sharing of Audit Information + rules: [] + status: pending + - id: au-16.3 + title: Disassociability + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ca.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ca.yml new file mode 100644 index 000000000000..fd1a4f86bfb0 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ca.yml @@ -0,0 +1,160 @@ +# NIST 800-53 CA Family: Assessment, Authorization, and Monitoring +controls: + - id: ca-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ca-2 + title: Control Assessments + levels: + - low + rules: [] + status: pending + - id: ca-2.1 + title: Independent Assessors + levels: + - moderate + rules: [] + status: pending + - id: ca-2.2 + title: Specialized Assessments + levels: + - high + rules: [] + status: pending + - id: ca-2.3 + title: Leveraging Results from External Organizations + rules: [] + status: pending + - id: ca-3 + title: Information Exchange + levels: + - low + rules: [] + status: pending + - id: ca-3.1 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: ca-3.2 + title: Classified National Security System Connections + rules: [] + status: pending + - id: ca-3.3 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: ca-3.4 + title: Connections to Public Networks + rules: [] + status: pending + - id: ca-3.5 + title: Restrictions on External System Connections + rules: [] + status: pending + - id: ca-3.6 + title: Transfer Authorizations + levels: + - high + rules: [] + status: pending + - id: ca-3.7 + title: Transitive Information Exchanges + rules: [] + status: pending + - id: ca-4 + title: Security Certification + rules: [] + status: pending + - id: ca-5 + title: Plan of Action and Milestones + levels: + - low + rules: [] + status: pending + - id: ca-5.1 + title: Automation Support for Accuracy and Currency + rules: [] + status: pending + - id: ca-6 + title: Authorization + levels: + - low + rules: [] + status: pending + - id: ca-6.1 + title: Joint Authorization — Intra-organization + rules: [] + status: pending + - id: ca-6.2 + title: Joint Authorization — Inter-organization + rules: [] + status: pending + - id: ca-7 + title: Continuous Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.1 + title: Independent Assessment + levels: + - moderate + rules: [] + status: pending + - id: ca-7.2 + title: Types of Assessments + rules: [] + status: pending + - id: ca-7.3 + title: Trend Analyses + rules: [] + status: pending + - id: ca-7.4 + title: Risk Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.5 + title: Consistency Analysis + rules: [] + status: pending + - id: ca-7.6 + title: Automation Support for Monitoring + rules: [] + status: pending + - id: ca-8 + title: Penetration Testing + levels: + - high + rules: [] + status: pending + - id: ca-8.1 + title: Independent Penetration Testing Agent or Team + levels: + - high + rules: [] + status: pending + - id: ca-8.2 + title: Red Team Exercises + rules: [] + status: pending + - id: ca-8.3 + title: Facility Penetration Testing + rules: [] + status: pending + - id: ca-9 + title: Internal System Connections + levels: + - low + rules: + - firewalld-backend + - package_firewalld_installed + status: automated + - id: ca-9.1 + title: Compliance Checks + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/cm.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/cm.yml new file mode 100644 index 000000000000..84616532e88b --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/cm.yml @@ -0,0 +1,565 @@ +# NIST 800-53 CM Family: Configuration Management +controls: + - id: cm-1 + title: Policy and Procedures + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - account_unique_id + - account_unique_name + - accounts_maximum_age_login_defs + - accounts_no_uid_except_zero + - accounts_password_set_max_life_existing + - accounts_root_gid_zero + - accounts_root_path_dirs_no_write + - accounts_user_dot_group_ownership + - accounts_user_dot_user_ownership + - configure_custom_crypto_policy_cis + - disable_host_auth + - file_permission_user_bash_history + - file_permission_user_init_files + - gid_passwd_group_same + - group_unique_id + - group_unique_name + - groups_no_zero_gid_except_root + - no_forward_files + - no_netrc_files + - no_nologin_in_shells + - no_rhost_files + - package_cron_installed + - root_path_no_dot + - service_crond_enabled + - sshd_disable_empty_passwords + - sshd_disable_gssapi_auth + - sshd_disable_rhosts + - sshd_do_not_permit_user_env + - sshd_enable_pam + - sshd_enable_warning_banner_net + - sshd_set_idle_timeout + - sshd_set_keepalive + - sshd_set_max_sessions + - sshd_set_maxstartups + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv4_tcp_syncookies + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sshd_idle_timeout_value=5_minutes + - sysctl_net_ipv4_tcp_syncookies_value=enabled + - var_accounts_maximum_age_login_defs=365 + - var_sshd_max_sessions=10 + - var_sshd_set_keepalive=1 + - var_sshd_set_maxstartups=10:30:60 + - var_user_initialization_files_regex=all_dotfiles + status: automated + - id: cm-2 + title: Baseline Configuration + levels: + - low + rules: [] + status: pending + - id: cm-2.1 + title: Reviews and Updates + rules: [] + status: pending + - id: cm-2.2 + title: Automation Support for Accuracy and Currency + levels: + - moderate + rules: [] + status: pending + - id: cm-2.3 + title: Retention of Previous Configurations + levels: + - moderate + rules: [] + status: pending + - id: cm-2.4 + title: Unauthorized Software + rules: [] + status: pending + - id: cm-2.5 + title: Authorized Software + rules: [] + status: pending + - id: cm-2.6 + title: Development and Test Environments + rules: [] + status: pending + - id: cm-2.7 + title: Configure Systems and Components for High-risk Areas + levels: + - moderate + rules: [] + status: pending + - id: cm-3 + title: Configuration Change Control + levels: + - moderate + rules: [] + status: pending + - id: cm-3.1 + title: Automated Documentation, Notification, and Prohibition of Changes + levels: + - high + rules: [] + status: pending + - id: cm-3.2 + title: Testing, Validation, and Documentation of Changes + levels: + - moderate + rules: [] + status: pending + - id: cm-3.3 + title: Automated Change Implementation + rules: [] + status: pending + - id: cm-3.4 + title: Security and Privacy Representatives + levels: + - moderate + rules: [] + status: pending + - id: cm-3.5 + title: Automated Security Response + rules: [] + status: pending + - id: cm-3.6 + title: Cryptography Management + levels: + - high + rules: [] + status: pending + - id: cm-3.7 + title: Review System Changes + rules: [] + status: pending + - id: cm-3.8 + title: Prevent or Restrict Configuration Changes + rules: [] + status: pending + - id: cm-4 + title: Impact Analyses + levels: + - low + rules: [] + status: pending + - id: cm-4.1 + title: Separate Test Environments + levels: + - high + rules: [] + status: pending + - id: cm-4.2 + title: Verification of Controls + levels: + - moderate + rules: [] + status: pending + - id: cm-5 + title: Access Restrictions for Change + levels: + - low + rules: [] + status: pending + - id: cm-5.1 + title: Automated Access Enforcement and Audit Records + levels: + - high + rules: [] + status: pending + - id: cm-5.2 + title: Review System Changes + rules: [] + status: pending + - id: cm-5.3 + title: Signed Components + rules: [] + status: pending + - id: cm-5.4 + title: Dual Authorization + rules: [] + status: pending + - id: cm-5.5 + title: Privilege Limitation for Production and Operation + rules: [] + status: pending + - id: cm-5.6 + title: Limit Library Privileges + rules: [] + status: pending + - id: cm-5.7 + title: Automatic Implementation of Security Safeguards + rules: [] + status: pending + - id: cm-6 + title: Configuration Settings + levels: + - low + rules: + - accounts_password_pam_pwquality_password_auth + - accounts_password_pam_pwquality_system_auth + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_user_interactive_home_directory_exists + - audit_rules_media_export + - banner_etc_issue_cis + - banner_etc_issue_net_cis + - banner_etc_motd_cis + - coredump_disable_backtraces + - coredump_disable_storage + - dconf_db_up_to_date + - dconf_gnome_disable_user_list + - disable_host_auth + - disable_users_coredumps + - enable_authselect + - file_groupowner_efi_grub2_cfg + - file_groupowner_efi_user_cfg + - file_groupowner_grub2_cfg + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_efi_grub2_cfg + - file_owner_efi_user_cfg + - file_owner_grub2_cfg + - file_owner_user_cfg + - file_ownership_home_directories + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_efi_grub2_cfg + - file_permissions_efi_user_cfg + - file_permissions_grub2_cfg + - file_permissions_home_directories + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_user_cfg + - no_empty_passwords + - no_empty_passwords_etc_shadow + - no_files_or_dirs_ungroupowned + - no_files_or_dirs_unowned_by_user + - package_pam_pwquality_installed + - package_rsync_removed + - package_rsyslog_installed + - package_samba_removed + - package_squid_removed + - partition_for_tmp + - partition_for_var_log + - service_nfs_disabled + - service_rpcbind_disabled + - sshd_disable_gssapi_auth + - sshd_set_login_grace_time + - sysctl_fs_suid_dumpable + - sysctl_kernel_kptr_restrict + - sysctl_kernel_randomize_va_space + - sysctl_kernel_yama_ptrace_scope + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_forwarding + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_forwarding + - sysctl_net_ipv4_conf_default_log_martians + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sysctl_net_ipv6_conf_default_forwarding + - cis_banner_text=cis + - dconf_login_banner_contents=cis_default + - dconf_login_banner_text=cis_banners + - sysctl_net_ipv4_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_all_log_martians_value=enabled + - sysctl_net_ipv4_conf_all_rp_filter_value=enabled + - sysctl_net_ipv4_conf_all_secure_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_default_forwarding_value=disabled + - sysctl_net_ipv4_conf_default_log_martians_value=enabled + - sysctl_net_ipv4_conf_default_rp_filter_value=enabled + - sysctl_net_ipv4_conf_default_secure_redirects_value=disabled + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled + - sysctl_net_ipv6_conf_all_accept_ra_value=disabled + - sysctl_net_ipv6_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_all_forwarding_value=disabled + - sysctl_net_ipv6_conf_default_accept_ra_value=disabled + - sysctl_net_ipv6_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_default_forwarding_value=disabled + - var_accounts_user_umask=027 + - var_authselect_profile=sssd + - var_sshd_set_login_grace_time=60 + status: automated + - id: cm-6.1 + title: Automated Management, Application, and Verification + levels: + - high + rules: [] + status: pending + - id: cm-6.2 + title: Respond to Unauthorized Changes + levels: + - high + rules: [] + status: pending + - id: cm-6.3 + title: Unauthorized Change Detection + rules: [] + status: pending + - id: cm-6.4 + title: Conformance Demonstration + rules: [] + status: pending + - id: cm-7 + title: Least Functionality + levels: + - low + rules: + - dconf_gnome_disable_autorun + - disable_weak_deps + - file_ownership_var_log_audit_stig + - gnome_gdm_disable_xdmcp + - has_nonlocal_mta + - kernel_module_atm_disabled + - kernel_module_can_disabled + - kernel_module_cramfs_disabled + - kernel_module_dccp_disabled + - kernel_module_firewire-core_disabled + - kernel_module_freevxfs_disabled + - kernel_module_hfs_disabled + - kernel_module_hfsplus_disabled + - kernel_module_jffs2_disabled + - kernel_module_overlayfs_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_squashfs_disabled + - kernel_module_tipc_disabled + - kernel_module_udf_disabled + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_tmp_nodev + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - package_authselect_installed + - package_bind_removed + - package_cyrus-imapd_removed + - package_dhcp_removed + - package_dovecot_removed + - package_ftp_removed + - package_gdm_removed + - package_httpd_removed + - package_net-snmp_removed + - package_nginx_removed + - package_openldap-clients_removed + - package_pam_installed + - package_telnet-server_removed + - package_telnet_removed + - package_tftp-server_removed + - package_tftp_removed + - package_vsftpd_removed + - package_xinetd_removed + - package_ypbind_removed + - package_ypserv_removed + - partition_for_dev_shm + - partition_for_home + - partition_for_tmp + - partition_for_var + - partition_for_var_log + - partition_for_var_log_audit + - partition_for_var_tmp + - postfix_network_listening_disabled + - service_bluetooth_disabled + - service_cockpit_disabled + - service_cups_disabled + - service_dnsmasq_disabled + - sshd_disable_forwarding + - wireless_disable_interfaces + - xwayland_disabled + - var_postfix_inet_interfaces=loopback-only + status: automated + - id: cm-7.1 + title: Periodic Review + levels: + - moderate + rules: [] + status: pending + - id: cm-7.2 + title: Prevent Program Execution + levels: + - moderate + rules: [] + status: pending + - id: cm-7.3 + title: Registration Compliance + rules: [] + status: pending + - id: cm-7.4 + title: Unauthorized Software — Deny-by-exception + rules: [] + status: pending + - id: cm-7.5 + title: Authorized Software — Allow-by-exception + levels: + - moderate + rules: [] + status: pending + - id: cm-7.6 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: cm-7.7 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: cm-7.8 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: cm-7.9 + title: Prohibiting The Use of Unauthorized Hardware + rules: [] + status: pending + - id: cm-8 + title: System Component Inventory + levels: + - low + rules: [] + status: pending + - id: cm-8.1 + title: Updates During Installation and Removal + levels: + - moderate + rules: [] + status: pending + - id: cm-8.2 + title: Automated Maintenance + levels: + - high + rules: [] + status: pending + - id: cm-8.3 + title: Automated Unauthorized Component Detection + levels: + - moderate + rules: [] + status: pending + - id: cm-8.4 + title: Accountability Information + levels: + - high + rules: [] + status: pending + - id: cm-8.5 + title: No Duplicate Accounting of Components + rules: [] + status: pending + - id: cm-8.6 + title: Assessed Configurations and Approved Deviations + rules: [] + status: pending + - id: cm-8.7 + title: Centralized Repository + rules: [] + status: pending + - id: cm-8.8 + title: Automated Location Tracking + rules: [] + status: pending + - id: cm-8.9 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: cm-9 + title: Configuration Management Plan + levels: + - moderate + rules: [] + status: pending + - id: cm-9.1 + title: Assignment of Responsibility + rules: [] + status: pending + - id: cm-10 + title: Software Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: cm-10.1 + title: Open-source Software + rules: [] + status: pending + - id: cm-11 + title: User-installed Software + levels: + - low + rules: + - package_xorg-x11-server-Xwayland_removed + status: automated + - id: cm-11.1 + title: Alerts for Unauthorized Installations + rules: [] + status: pending + - id: cm-11.2 + title: Software Installation with Privileged Status + rules: [] + status: pending + - id: cm-11.3 + title: Automated Enforcement and Monitoring + rules: [] + status: pending + - id: cm-12 + title: Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-12.1 + title: Automated Tools to Support Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-13 + title: Data Action Mapping + rules: [] + status: pending + - id: cm-14 + title: Signed Components + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/cp.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/cp.yml new file mode 100644 index 000000000000..53d97fb34990 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/cp.yml @@ -0,0 +1,296 @@ +# NIST 800-53 CP Family: Contingency Planning +controls: + - id: cp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: cp-2 + title: Contingency Plan + levels: + - low + rules: [] + status: pending + - id: cp-2.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-2.2 + title: Capacity Planning + levels: + - high + rules: [] + status: pending + - id: cp-2.3 + title: Resume Mission and Business Functions + levels: + - moderate + rules: [] + status: pending + - id: cp-2.4 + title: Resume All Mission and Business Functions + rules: [] + status: pending + - id: cp-2.5 + title: Continue Mission and Business Functions + levels: + - high + rules: [] + status: pending + - id: cp-2.6 + title: Alternate Processing and Storage Sites + rules: [] + status: pending + - id: cp-2.7 + title: Coordinate with External Service Providers + rules: [] + status: pending + - id: cp-2.8 + title: Identify Critical Assets + levels: + - moderate + rules: [] + status: pending + - id: cp-3 + title: Contingency Training + levels: + - low + rules: [] + status: pending + - id: cp-3.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: cp-3.2 + title: Mechanisms Used in Training Environments + rules: [] + status: pending + - id: cp-4 + title: Contingency Plan Testing + levels: + - low + rules: [] + status: pending + - id: cp-4.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-4.2 + title: Alternate Processing Site + levels: + - high + rules: [] + status: pending + - id: cp-4.3 + title: Automated Testing + rules: [] + status: pending + - id: cp-4.4 + title: Full Recovery and Reconstitution + rules: [] + status: pending + - id: cp-4.5 + title: Self-challenge + rules: [] + status: pending + - id: cp-5 + title: Contingency Plan Update + rules: [] + status: pending + - id: cp-6 + title: Alternate Storage Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.2 + title: Recovery Time and Recovery Point Objectives + levels: + - high + rules: [] + status: pending + - id: cp-6.3 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7 + title: Alternate Processing Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.2 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7.3 + title: Priority of Service + levels: + - moderate + rules: [] + status: pending + - id: cp-7.4 + title: Preparation for Use + levels: + - high + rules: [] + status: pending + - id: cp-7.5 + title: Equivalent Information Security Safeguards + rules: [] + status: pending + - id: cp-7.6 + title: Inability to Return to Primary Site + rules: [] + status: pending + - id: cp-8 + title: Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: cp-8.1 + title: Priority of Service Provisions + levels: + - moderate + rules: [] + status: pending + - id: cp-8.2 + title: Single Points of Failure + levels: + - moderate + rules: [] + status: pending + - id: cp-8.3 + title: Separation of Primary and Alternate Providers + levels: + - high + rules: [] + status: pending + - id: cp-8.4 + title: Provider Contingency Plan + levels: + - high + rules: [] + status: pending + - id: cp-8.5 + title: Alternate Telecommunication Service Testing + rules: [] + status: pending + - id: cp-9 + title: System Backup + levels: + - low + rules: [] + status: pending + - id: cp-9.1 + title: Testing for Reliability and Integrity + levels: + - moderate + rules: [] + status: pending + - id: cp-9.2 + title: Test Restoration Using Sampling + levels: + - high + rules: [] + status: pending + - id: cp-9.3 + title: Separate Storage for Critical Information + levels: + - high + rules: [] + status: pending + - id: cp-9.4 + title: Protection from Unauthorized Modification + rules: [] + status: pending + - id: cp-9.5 + title: Transfer to Alternate Storage Site + levels: + - high + rules: [] + status: pending + - id: cp-9.6 + title: Redundant Secondary System + rules: [] + status: pending + - id: cp-9.7 + title: Dual Authorization for Deletion or Destruction + rules: [] + status: pending + - id: cp-9.8 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: cp-10 + title: System Recovery and Reconstitution + levels: + - low + rules: [] + status: pending + - id: cp-10.1 + title: Contingency Plan Testing + rules: [] + status: pending + - id: cp-10.2 + title: Transaction Recovery + levels: + - moderate + rules: [] + status: pending + - id: cp-10.3 + title: Compensating Security Controls + rules: [] + status: pending + - id: cp-10.4 + title: Restore Within Time Period + levels: + - high + rules: [] + status: pending + - id: cp-10.5 + title: Failover Capability + rules: [] + status: pending + - id: cp-10.6 + title: Component Protection + rules: [] + status: pending + - id: cp-11 + title: Alternate Communications Protocols + rules: [] + status: pending + - id: cp-12 + title: Safe Mode + rules: [] + status: pending + - id: cp-13 + title: Alternative Security Mechanisms + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ia.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ia.yml new file mode 100644 index 000000000000..11c56277f996 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ia.yml @@ -0,0 +1,397 @@ +# NIST 800-53 IA Family: Identification and Authentication +controls: + - id: ia-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ia-2 + title: Identification and Authentication (Organizational Users) + levels: + - low + rules: + - account_unique_id + status: automated + - id: ia-2.1 + title: Multi-factor Authentication to Privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.2 + title: Multi-factor Authentication to Non-privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.3 + title: Local Access to Privileged Accounts + rules: [] + status: pending + - id: ia-2.4 + title: Local Access to Non-privileged Accounts + rules: [] + status: pending + - id: ia-2.5 + title: Individual Authentication with Group Authentication + levels: + - high + rules: [] + status: pending + - id: ia-2.6 + title: Access to Accounts —separate Device + rules: [] + status: pending + - id: ia-2.7 + title: Network Access to Non-privileged Accounts — Separate Device + rules: [] + status: pending + - id: ia-2.8 + title: Access to Accounts — Replay Resistant + levels: + - low + rules: [] + status: pending + - id: ia-2.9 + title: Network Access to Non-privileged Accounts — Replay Resistant + rules: [] + status: pending + - id: ia-2.10 + title: Single Sign-on + rules: [] + status: pending + - id: ia-2.11 + title: Remote Access — Separate Device + rules: [] + status: pending + - id: ia-2.12 + title: Acceptance of PIV Credentials + levels: + - low + rules: [] + status: pending + - id: ia-2.13 + title: Out-of-band Authentication + rules: [] + status: pending + - id: ia-3 + title: Device Identification and Authentication + levels: + - moderate + rules: + - dconf_gnome_disable_automount + - dconf_gnome_disable_automount_open + - kernel_module_usb-storage_disabled + status: automated + - id: ia-3.1 + title: Cryptographic Bidirectional Authentication + rules: [] + status: pending + - id: ia-3.2 + title: Cryptographic Bidirectional Network Authentication + rules: [] + status: pending + - id: ia-3.3 + title: Dynamic Address Allocation + rules: [] + status: pending + - id: ia-3.4 + title: Device Attestation + rules: [] + status: pending + - id: ia-4 + title: Identifier Management + levels: + - low + rules: + - account_disable_post_pw_expiration + - accounts_set_post_pw_existing + - var_account_disable_post_pw_expiration=45 + status: automated + - id: ia-4.1 + title: Prohibit Account Identifiers as Public Identifiers + rules: [] + status: pending + - id: ia-4.2 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-4.3 + title: Multiple Forms of Certification + rules: [] + status: pending + - id: ia-4.4 + title: Identify User Status + levels: + - moderate + rules: [] + status: pending + - id: ia-4.5 + title: Dynamic Management + rules: [] + status: pending + - id: ia-4.6 + title: Cross-organization Management + rules: [] + status: pending + - id: ia-4.7 + title: In-person Registration + rules: [] + status: pending + - id: ia-4.8 + title: Pairwise Pseudonymous Identifiers + rules: [] + status: pending + - id: ia-4.9 + title: Attribute Maintenance and Protection + rules: [] + status: pending + - id: ia-5 + title: Authenticator Management + levels: + - low + rules: + - accounts_minimum_age_login_defs + - accounts_password_all_shadowed + - accounts_password_last_change_is_in_past + - accounts_password_pam_dictcheck + - accounts_password_pam_difok + - accounts_password_pam_enforce_root + - accounts_password_pam_maxrepeat + - accounts_password_pam_maxsequence + - accounts_password_pam_minclass + - accounts_password_pam_minlen + - accounts_password_pam_modules_in_authselect_profile + - accounts_password_pam_pwhistory_enforce_for_root + - accounts_password_pam_pwhistory_use_authtok + - accounts_password_pam_unix_authtok + - accounts_password_set_min_life_existing + - accounts_password_set_warn_age_existing + - accounts_password_warn_age_login_defs + - ensure_root_password_configured + - no_empty_passwords_etc_shadow + - set_password_hashing_algorithm_logindefs + - set_password_hashing_algorithm_passwordauth + - set_password_hashing_algorithm_systemauth + - var_accounts_minimum_age_login_defs=1 + - var_accounts_password_warn_age_login_defs=7 + - var_password_hashing_algorithm=cis_rhel8 + - var_password_hashing_algorithm_pam=cis_rhel8 + - var_password_pam_dictcheck=1 + - var_password_pam_difok=2 + - var_password_pam_maxrepeat=3 + - var_password_pam_maxsequence=3 + - var_password_pam_minclass=4 + - var_password_pam_minlen=14 + status: automated + - id: ia-5.1 + title: Password-based Authentication + levels: + - low + rules: + - accounts_password_pam_pwhistory_remember_password_auth + - accounts_password_pam_pwhistory_remember_system_auth + - accounts_password_pam_unix_enabled + - accounts_password_pam_unix_no_remember + - var_password_pam_remember=24 + - var_password_pam_remember_control_flag=requisite_or_required + status: automated + - id: ia-5.2 + title: Public Key-based Authentication + levels: + - moderate + rules: [] + status: pending + - id: ia-5.3 + title: In-person or Trusted External Party Registration + rules: [] + status: pending + - id: ia-5.4 + title: Automated Support for Password Strength Determination + rules: [] + status: pending + - id: ia-5.5 + title: Change Authenticators Prior to Delivery + rules: [] + status: pending + - id: ia-5.6 + title: Protection of Authenticators + levels: + - moderate + rules: [] + status: pending + - id: ia-5.7 + title: No Embedded Unencrypted Static Authenticators + rules: [] + status: pending + - id: ia-5.8 + title: Multiple System Accounts + rules: [] + status: pending + - id: ia-5.9 + title: Federated Credential Management + rules: [] + status: pending + - id: ia-5.10 + title: Dynamic Credential Binding + rules: [] + status: pending + - id: ia-5.11 + title: Hardware Token-based Authentication + rules: [] + status: pending + - id: ia-5.12 + title: Biometric Authentication Performance + rules: [] + status: pending + - id: ia-5.13 + title: Expiration of Cached Authenticators + rules: [] + status: pending + - id: ia-5.14 + title: Managing Content of PKI Trust Stores + rules: [] + status: pending + - id: ia-5.15 + title: GSA-approved Products and Services + rules: [] + status: pending + - id: ia-5.16 + title: In-person or Trusted External Party Authenticator Issuance + rules: [] + status: pending + - id: ia-5.17 + title: Presentation Attack Detection for Biometric Authenticators + rules: [] + status: pending + - id: ia-5.18 + title: Password Managers + rules: [] + status: pending + - id: ia-6 + title: Authentication Feedback + levels: + - low + rules: [] + status: pending + - id: ia-7 + title: Cryptographic Module Authentication + levels: + - low + rules: [] + status: pending + - id: ia-8 + title: Identification and Authentication (Non-organizational Users) + levels: + - low + rules: [] + status: pending + - id: ia-8.1 + title: Acceptance of PIV Credentials from Other Agencies + levels: + - low + rules: [] + status: pending + - id: ia-8.2 + title: Acceptance of External Authenticators + levels: + - low + rules: [] + status: pending + - id: ia-8.3 + title: Use of FICAM-approved Products + rules: [] + status: pending + - id: ia-8.4 + title: Use of Defined Profiles + levels: + - low + rules: [] + status: pending + - id: ia-8.5 + title: Acceptance of PIV-I Credentials + rules: [] + status: pending + - id: ia-8.6 + title: Disassociability + rules: [] + status: pending + - id: ia-9 + title: Service Identification and Authentication + rules: [] + status: pending + - id: ia-9.1 + title: Information Exchange + rules: [] + status: pending + - id: ia-9.2 + title: Transmission of Decisions + rules: [] + status: pending + - id: ia-10 + title: Adaptive Authentication + rules: [] + status: pending + - id: ia-11 + title: Re-authentication + levels: + - low + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=15_minutes + status: automated + - id: ia-12 + title: Identity Proofing + levels: + - moderate + rules: [] + status: pending + - id: ia-12.1 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-12.2 + title: Identity Evidence + levels: + - moderate + rules: [] + status: pending + - id: ia-12.3 + title: Identity Evidence Validation and Verification + levels: + - moderate + rules: [] + status: pending + - id: ia-12.4 + title: In-person Validation and Verification + levels: + - high + rules: [] + status: pending + - id: ia-12.5 + title: Address Confirmation + levels: + - moderate + rules: [] + status: pending + - id: ia-12.6 + title: Accept Externally-proofed Identities + rules: [] + status: pending + - id: ia-13 + title: Identity Providers and Authorization Servers + rules: [] + status: pending + - id: ia-13.1 + title: Protection of Cryptographic Keys + rules: [] + status: pending + - id: ia-13.2 + title: Verification of Identity Assertions and Access Tokens + rules: [] + status: pending + - id: ia-13.3 + title: Token Management + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ir.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ir.yml new file mode 100644 index 000000000000..2d443099c957 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ir.yml @@ -0,0 +1,206 @@ +# NIST 800-53 IR Family: Incident Response +controls: + - id: ir-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ir-2 + title: Incident Response Training + levels: + - low + rules: [] + status: pending + - id: ir-2.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: ir-2.2 + title: Automated Training Environments + levels: + - high + rules: [] + status: pending + - id: ir-2.3 + title: Breach + rules: [] + status: pending + - id: ir-3 + title: Incident Response Testing + levels: + - moderate + rules: [] + status: pending + - id: ir-3.1 + title: Automated Testing + rules: [] + status: pending + - id: ir-3.2 + title: Coordination with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: ir-3.3 + title: Continuous Improvement + rules: [] + status: pending + - id: ir-4 + title: Incident Handling + levels: + - low + rules: [] + status: pending + - id: ir-4.1 + title: Automated Incident Handling Processes + levels: + - moderate + rules: [] + status: pending + - id: ir-4.2 + title: Dynamic Reconfiguration + rules: [] + status: pending + - id: ir-4.3 + title: Continuity of Operations + rules: [] + status: pending + - id: ir-4.4 + title: Information Correlation + levels: + - high + rules: [] + status: pending + - id: ir-4.5 + title: Automatic Disabling of System + rules: [] + status: pending + - id: ir-4.6 + title: Insider Threats + rules: [] + status: pending + - id: ir-4.7 + title: Insider Threats — Intra-organization Coordination + rules: [] + status: pending + - id: ir-4.8 + title: Correlation with External Organizations + rules: [] + status: pending + - id: ir-4.9 + title: Dynamic Response Capability + rules: [] + status: pending + - id: ir-4.10 + title: Supply Chain Coordination + rules: [] + status: pending + - id: ir-4.11 + title: Integrated Incident Response Team + levels: + - high + rules: [] + status: pending + - id: ir-4.12 + title: Malicious Code and Forensic Analysis + rules: [] + status: pending + - id: ir-4.13 + title: Behavior Analysis + rules: [] + status: pending + - id: ir-4.14 + title: Security Operations Center + rules: [] + status: pending + - id: ir-4.15 + title: Public Relations and Reputation Repair + rules: [] + status: pending + - id: ir-5 + title: Incident Monitoring + levels: + - low + rules: [] + status: pending + - id: ir-5.1 + title: Automated Tracking, Data Collection, and Analysis + levels: + - high + rules: [] + status: pending + - id: ir-6 + title: Incident Reporting + levels: + - low + rules: [] + status: pending + - id: ir-6.1 + title: Automated Reporting + levels: + - moderate + rules: [] + status: pending + - id: ir-6.2 + title: Vulnerabilities Related to Incidents + rules: [] + status: pending + - id: ir-6.3 + title: Supply Chain Coordination + levels: + - moderate + rules: [] + status: pending + - id: ir-7 + title: Incident Response Assistance + levels: + - low + rules: [] + status: pending + - id: ir-7.1 + title: Automation Support for Availability of Information and Support + levels: + - moderate + rules: [] + status: pending + - id: ir-7.2 + title: Coordination with External Providers + rules: [] + status: pending + - id: ir-8 + title: Incident Response Plan + levels: + - low + rules: [] + status: pending + - id: ir-8.1 + title: Breaches + rules: [] + status: pending + - id: ir-9 + title: Information Spillage Response + rules: [] + status: pending + - id: ir-9.1 + title: Responsible Personnel + rules: [] + status: pending + - id: ir-9.2 + title: Training + rules: [] + status: pending + - id: ir-9.3 + title: Post-spill Operations + rules: [] + status: pending + - id: ir-9.4 + title: Exposure to Unauthorized Personnel + rules: [] + status: pending + - id: ir-10 + title: Integrated Information Security Analysis Team + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ma.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ma.yml new file mode 100644 index 000000000000..77bd02932613 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ma.yml @@ -0,0 +1,146 @@ +# NIST 800-53 MA Family: Maintenance +controls: + - id: ma-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ma-2 + title: Controlled Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-2.1 + title: Record Content + rules: [] + status: pending + - id: ma-2.2 + title: Automated Maintenance Activities + levels: + - high + rules: [] + status: pending + - id: ma-3 + title: Maintenance Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.1 + title: Inspect Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.2 + title: Inspect Media + levels: + - moderate + rules: [] + status: pending + - id: ma-3.3 + title: Prevent Unauthorized Removal + levels: + - moderate + rules: [] + status: pending + - id: ma-3.4 + title: Restricted Tool Use + rules: [] + status: pending + - id: ma-3.5 + title: Execution with Privilege + rules: [] + status: pending + - id: ma-3.6 + title: Software Updates and Patches + rules: [] + status: pending + - id: ma-4 + title: Nonlocal Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-4.1 + title: Logging and Review + rules: [] + status: pending + - id: ma-4.2 + title: Document Nonlocal Maintenance + rules: [] + status: pending + - id: ma-4.3 + title: Comparable Security and Sanitization + levels: + - high + rules: [] + status: pending + - id: ma-4.4 + title: Authentication and Separation of Maintenance Sessions + rules: [] + status: pending + - id: ma-4.5 + title: Approvals and Notifications + rules: [] + status: pending + - id: ma-4.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: ma-4.7 + title: Disconnect Verification + rules: [] + status: pending + - id: ma-5 + title: Maintenance Personnel + levels: + - low + rules: [] + status: pending + - id: ma-5.1 + title: Individuals Without Appropriate Access + levels: + - high + rules: [] + status: pending + - id: ma-5.2 + title: Security Clearances for Classified Systems + rules: [] + status: pending + - id: ma-5.3 + title: Citizenship Requirements for Classified Systems + rules: [] + status: pending + - id: ma-5.4 + title: Foreign Nationals + rules: [] + status: pending + - id: ma-5.5 + title: Non-system Maintenance + rules: [] + status: pending + - id: ma-6 + title: Timely Maintenance + levels: + - moderate + rules: [] + status: pending + - id: ma-6.1 + title: Preventive Maintenance + rules: [] + status: pending + - id: ma-6.2 + title: Predictive Maintenance + rules: [] + status: pending + - id: ma-6.3 + title: Automated Support for Predictive Maintenance + rules: [] + status: pending + - id: ma-7 + title: Field Maintenance + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/mp.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/mp.yml new file mode 100644 index 000000000000..6c8e8f46e4e4 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/mp.yml @@ -0,0 +1,142 @@ +# NIST 800-53 MP Family: Media Protection +controls: + - id: mp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: mp-2 + title: Media Access + levels: + - low + rules: [] + status: pending + - id: mp-2.1 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-2.2 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-3 + title: Media Marking + levels: + - moderate + rules: [] + status: pending + - id: mp-4 + title: Media Storage + levels: + - moderate + rules: [] + status: pending + - id: mp-4.1 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-4.2 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-5 + title: Media Transport + levels: + - moderate + rules: [] + status: pending + - id: mp-5.1 + title: Protection Outside of Controlled Areas + rules: [] + status: pending + - id: mp-5.2 + title: Documentation of Activities + rules: [] + status: pending + - id: mp-5.3 + title: Custodians + rules: [] + status: pending + - id: mp-5.4 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-6 + title: Media Sanitization + levels: + - low + rules: [] + status: pending + - id: mp-6.1 + title: Review, Approve, Track, Document, and Verify + levels: + - high + rules: [] + status: pending + - id: mp-6.2 + title: Equipment Testing + levels: + - high + rules: [] + status: pending + - id: mp-6.3 + title: Nondestructive Techniques + levels: + - high + rules: [] + status: pending + - id: mp-6.4 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-6.5 + title: Classified Information + rules: [] + status: pending + - id: mp-6.6 + title: Media Destruction + rules: [] + status: pending + - id: mp-6.7 + title: Dual Authorization + rules: [] + status: pending + - id: mp-6.8 + title: Remote Purging or Wiping of Information + rules: [] + status: pending + - id: mp-7 + title: Media Use + levels: + - low + rules: [] + status: pending + - id: mp-7.1 + title: Prohibit Use Without Owner + rules: [] + status: pending + - id: mp-7.2 + title: Prohibit Use of Sanitization-resistant Media + rules: [] + status: pending + - id: mp-8 + title: Media Downgrading + rules: [] + status: pending + - id: mp-8.1 + title: Documentation of Process + rules: [] + status: pending + - id: mp-8.2 + title: Equipment Testing + rules: [] + status: pending + - id: mp-8.3 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-8.4 + title: Classified Information + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/pe.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/pe.yml new file mode 100644 index 000000000000..b6728c7d49d5 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/pe.yml @@ -0,0 +1,288 @@ +# NIST 800-53 PE Family: Physical and Environmental Protection +controls: + - id: pe-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pe-2 + title: Physical Access Authorizations + levels: + - low + rules: [] + status: pending + - id: pe-2.1 + title: Access by Position or Role + rules: [] + status: pending + - id: pe-2.2 + title: Two Forms of Identification + rules: [] + status: pending + - id: pe-2.3 + title: Restrict Unescorted Access + rules: [] + status: pending + - id: pe-3 + title: Physical Access Control + levels: + - low + rules: [] + status: pending + - id: pe-3.1 + title: System Access + levels: + - high + rules: [] + status: pending + - id: pe-3.2 + title: Facility and Systems + rules: [] + status: pending + - id: pe-3.3 + title: Continuous Guards + rules: [] + status: pending + - id: pe-3.4 + title: Lockable Casings + rules: [] + status: pending + - id: pe-3.5 + title: Tamper Protection + rules: [] + status: pending + - id: pe-3.6 + title: Facility Penetration Testing + rules: [] + status: pending + - id: pe-3.7 + title: Physical Barriers + rules: [] + status: pending + - id: pe-3.8 + title: Access Control Vestibules + rules: [] + status: pending + - id: pe-4 + title: Access Control for Transmission + levels: + - moderate + rules: [] + status: pending + - id: pe-5 + title: Access Control for Output Devices + levels: + - moderate + rules: [] + status: pending + - id: pe-5.1 + title: Access to Output by Authorized Individuals + rules: [] + status: pending + - id: pe-5.2 + title: Link to Individual Identity + rules: [] + status: pending + - id: pe-5.3 + title: Marking Output Devices + rules: [] + status: pending + - id: pe-6 + title: Monitoring Physical Access + levels: + - low + rules: [] + status: pending + - id: pe-6.1 + title: Intrusion Alarms and Surveillance Equipment + levels: + - moderate + rules: [] + status: pending + - id: pe-6.2 + title: Automated Intrusion Recognition and Responses + rules: [] + status: pending + - id: pe-6.3 + title: Video Surveillance + rules: [] + status: pending + - id: pe-6.4 + title: Monitoring Physical Access to Systems + levels: + - high + rules: [] + status: pending + - id: pe-7 + title: Visitor Control + rules: [] + status: pending + - id: pe-8 + title: Visitor Access Records + levels: + - low + rules: [] + status: pending + - id: pe-8.1 + title: Automated Records Maintenance and Review + levels: + - high + rules: [] + status: pending + - id: pe-8.2 + title: Physical Access Records + rules: [] + status: pending + - id: pe-8.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: pe-9 + title: Power Equipment and Cabling + levels: + - moderate + rules: [] + status: pending + - id: pe-9.1 + title: Redundant Cabling + rules: [] + status: pending + - id: pe-9.2 + title: Automatic Voltage Controls + rules: [] + status: pending + - id: pe-10 + title: Emergency Shutoff + levels: + - moderate + rules: [] + status: pending + - id: pe-10.1 + title: Accidental and Unauthorized Activation + rules: [] + status: pending + - id: pe-11 + title: Emergency Power + levels: + - moderate + rules: [] + status: pending + - id: pe-11.1 + title: Alternate Power Supply — Minimal Operational Capability + levels: + - high + rules: [] + status: pending + - id: pe-11.2 + title: Alternate Power Supply — Self-contained + rules: [] + status: pending + - id: pe-12 + title: Emergency Lighting + levels: + - low + rules: [] + status: pending + - id: pe-12.1 + title: Essential Mission and Business Functions + rules: [] + status: pending + - id: pe-13 + title: Fire Protection + levels: + - low + rules: [] + status: pending + - id: pe-13.1 + title: Detection Systems — Automatic Activation and Notification + levels: + - moderate + rules: [] + status: pending + - id: pe-13.2 + title: Suppression Systems — Automatic Activation and Notification + levels: + - high + rules: [] + status: pending + - id: pe-13.3 + title: Automatic Fire Suppression + rules: [] + status: pending + - id: pe-13.4 + title: Inspections + rules: [] + status: pending + - id: pe-14 + title: Environmental Controls + levels: + - low + rules: [] + status: pending + - id: pe-14.1 + title: Automatic Controls + rules: [] + status: pending + - id: pe-14.2 + title: Monitoring with Alarms and Notifications + rules: [] + status: pending + - id: pe-15 + title: Water Damage Protection + levels: + - low + rules: [] + status: pending + - id: pe-15.1 + title: Automation Support + levels: + - high + rules: [] + status: pending + - id: pe-16 + title: Delivery and Removal + levels: + - low + rules: [] + status: pending + - id: pe-17 + title: Alternate Work Site + levels: + - moderate + rules: [] + status: pending + - id: pe-18 + title: Location of System Components + levels: + - high + rules: [] + status: pending + - id: pe-18.1 + title: Facility Site + rules: [] + status: pending + - id: pe-19 + title: Information Leakage + rules: [] + status: pending + - id: pe-19.1 + title: National Emissions Policies and Procedures + rules: [] + status: pending + - id: pe-20 + title: Asset Monitoring and Tracking + rules: [] + status: pending + - id: pe-21 + title: Electromagnetic Pulse Protection + rules: [] + status: pending + - id: pe-22 + title: Component Marking + rules: [] + status: pending + - id: pe-23 + title: Facility Location + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/pl.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/pl.yml new file mode 100644 index 000000000000..d670e154e380 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/pl.yml @@ -0,0 +1,84 @@ +# NIST 800-53 PL Family: Planning +controls: + - id: pl-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pl-2 + title: System Security and Privacy Plans + levels: + - low + rules: [] + status: pending + - id: pl-2.1 + title: Concept of Operations + rules: [] + status: pending + - id: pl-2.2 + title: Functional Architecture + rules: [] + status: pending + - id: pl-2.3 + title: Plan and Coordinate with Other Organizational Entities + rules: [] + status: pending + - id: pl-3 + title: System Security Plan Update + rules: [] + status: pending + - id: pl-4 + title: Rules of Behavior + levels: + - low + rules: [] + status: pending + - id: pl-4.1 + title: Social Media and External Site/Application Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: pl-5 + title: Privacy Impact Assessment + rules: [] + status: pending + - id: pl-6 + title: Security-related Activity Planning + rules: [] + status: pending + - id: pl-7 + title: Concept of Operations + rules: [] + status: pending + - id: pl-8 + title: Security and Privacy Architectures + levels: + - moderate + rules: [] + status: pending + - id: pl-8.1 + title: Defense in Depth + rules: [] + status: pending + - id: pl-8.2 + title: Supplier Diversity + rules: [] + status: pending + - id: pl-9 + title: Central Management + rules: [] + status: pending + - id: pl-10 + title: Baseline Selection + levels: + - low + rules: [] + status: pending + - id: pl-11 + title: Baseline Tailoring + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/pm.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/pm.yml new file mode 100644 index 000000000000..97a32be05deb --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/pm.yml @@ -0,0 +1,151 @@ +# NIST 800-53 PM Family: Program Management +controls: + - id: pm-1 + title: Information Security Program Plan + rules: [] + status: pending + - id: pm-2 + title: Information Security Program Leadership Role + rules: [] + status: pending + - id: pm-3 + title: Information Security and Privacy Resources + rules: [] + status: pending + - id: pm-4 + title: Plan of Action and Milestones Process + rules: [] + status: pending + - id: pm-5 + title: System Inventory + rules: [] + status: pending + - id: pm-5.1 + title: Inventory of Personally Identifiable Information + rules: [] + status: pending + - id: pm-6 + title: Measures of Performance + rules: [] + status: pending + - id: pm-7 + title: Enterprise Architecture + rules: [] + status: pending + - id: pm-7.1 + title: Offloading + rules: [] + status: pending + - id: pm-8 + title: Critical Infrastructure Plan + rules: [] + status: pending + - id: pm-9 + title: Risk Management Strategy + rules: [] + status: pending + - id: pm-10 + title: Authorization Process + rules: [] + status: pending + - id: pm-11 + title: Mission and Business Process Definition + rules: [] + status: pending + - id: pm-12 + title: Insider Threat Program + rules: [] + status: pending + - id: pm-13 + title: Security and Privacy Workforce + rules: [] + status: pending + - id: pm-14 + title: Testing, Training, and Monitoring + rules: [] + status: pending + - id: pm-15 + title: Security and Privacy Groups and Associations + rules: [] + status: pending + - id: pm-16 + title: Threat Awareness Program + rules: [] + status: pending + - id: pm-16.1 + title: Automated Means for Sharing Threat Intelligence + rules: [] + status: pending + - id: pm-17 + title: Protecting Controlled Unclassified Information on External Systems + rules: [] + status: pending + - id: pm-18 + title: Privacy Program Plan + rules: [] + status: pending + - id: pm-19 + title: Privacy Program Leadership Role + rules: [] + status: pending + - id: pm-20 + title: Dissemination of Privacy Program Information + rules: [] + status: pending + - id: pm-20.1 + title: Privacy Policies on Websites, Applications, and Digital Services + rules: [] + status: pending + - id: pm-21 + title: Accounting of Disclosures + rules: [] + status: pending + - id: pm-22 + title: Personally Identifiable Information Quality Management + rules: [] + status: pending + - id: pm-23 + title: Data Governance Body + rules: [] + status: pending + - id: pm-24 + title: Data Integrity Board + rules: [] + status: pending + - id: pm-25 + title: Minimization of Personally Identifiable Information Used in Testing, Training, and + Research + rules: [] + status: pending + - id: pm-26 + title: Complaint Management + rules: [] + status: pending + - id: pm-27 + title: Privacy Reporting + rules: [] + status: pending + - id: pm-28 + title: Risk Framing + rules: [] + status: pending + - id: pm-29 + title: Risk Management Program Leadership Roles + rules: [] + status: pending + - id: pm-30 + title: Supply Chain Risk Management Strategy + rules: [] + status: pending + - id: pm-30.1 + title: Suppliers of Critical or Mission-essential Items + rules: [] + status: pending + - id: pm-31 + title: Continuous Monitoring Strategy + rules: [] + status: pending + - id: pm-32 + title: Purposing + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ps.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ps.yml new file mode 100644 index 000000000000..ad7d70333c17 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ps.yml @@ -0,0 +1,94 @@ +# NIST 800-53 PS Family: Personnel Security +controls: + - id: ps-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ps-2 + title: Position Risk Designation + levels: + - low + rules: [] + status: pending + - id: ps-3 + title: Personnel Screening + levels: + - low + rules: [] + status: pending + - id: ps-3.1 + title: Classified Information + rules: [] + status: pending + - id: ps-3.2 + title: Formal Indoctrination + rules: [] + status: pending + - id: ps-3.3 + title: Information Requiring Special Protective Measures + rules: [] + status: pending + - id: ps-3.4 + title: Citizenship Requirements + rules: [] + status: pending + - id: ps-4 + title: Personnel Termination + levels: + - low + rules: [] + status: pending + - id: ps-4.1 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-4.2 + title: Automated Actions + levels: + - high + rules: [] + status: pending + - id: ps-5 + title: Personnel Transfer + levels: + - low + rules: [] + status: pending + - id: ps-6 + title: Access Agreements + levels: + - low + rules: [] + status: pending + - id: ps-6.1 + title: Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.2 + title: Classified Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.3 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-7 + title: External Personnel Security + levels: + - low + rules: [] + status: pending + - id: ps-8 + title: Personnel Sanctions + levels: + - low + rules: [] + status: pending + - id: ps-9 + title: Position Descriptions + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/pt.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/pt.yml new file mode 100644 index 000000000000..fe3d1ee54437 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/pt.yml @@ -0,0 +1,86 @@ +# NIST 800-53 PT Family: PII Processing and Transparency +controls: + - id: pt-1 + title: Policy and Procedures + rules: [] + status: pending + - id: pt-2 + title: Authority to Process Personally Identifiable Information + rules: [] + status: pending + - id: pt-2.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-2.2 + title: Automation + rules: [] + status: pending + - id: pt-3 + title: Personally Identifiable Information Processing Purposes + rules: [] + status: pending + - id: pt-3.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-3.2 + title: Automation + rules: [] + status: pending + - id: pt-4 + title: Consent + rules: [] + status: pending + - id: pt-4.1 + title: Tailored Consent + rules: [] + status: pending + - id: pt-4.2 + title: Just-in-time Consent + rules: [] + status: pending + - id: pt-4.3 + title: Revocation + rules: [] + status: pending + - id: pt-5 + title: Privacy Notice + rules: [] + status: pending + - id: pt-5.1 + title: Just-in-time Notice + rules: [] + status: pending + - id: pt-5.2 + title: Privacy Act Statements + rules: [] + status: pending + - id: pt-6 + title: System of Records Notice + rules: [] + status: pending + - id: pt-6.1 + title: Routine Uses + rules: [] + status: pending + - id: pt-6.2 + title: Exemption Rules + rules: [] + status: pending + - id: pt-7 + title: Specific Categories of Personally Identifiable Information + rules: [] + status: pending + - id: pt-7.1 + title: Social Security Numbers + rules: [] + status: pending + - id: pt-7.2 + title: First Amendment Information + rules: [] + status: pending + - id: pt-8 + title: Computer Matching Requirements + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/ra.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/ra.yml new file mode 100644 index 000000000000..ca44e21f4e67 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/ra.yml @@ -0,0 +1,128 @@ +# NIST 800-53 RA Family: Risk Assessment +controls: + - id: ra-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ra-2 + title: Security Categorization + levels: + - low + rules: [] + status: pending + - id: ra-2.1 + title: Impact-level Prioritization + rules: [] + status: pending + - id: ra-3 + title: Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.1 + title: Supply Chain Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.2 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: ra-3.3 + title: Dynamic Threat Awareness + rules: [] + status: pending + - id: ra-3.4 + title: Predictive Cyber Analytics + rules: [] + status: pending + - id: ra-4 + title: Risk Assessment Update + rules: [] + status: pending + - id: ra-5 + title: Vulnerability Monitoring and Scanning + levels: + - low + rules: [] + status: pending + - id: ra-5.1 + title: Update Tool Capability + rules: [] + status: pending + - id: ra-5.2 + title: Update Vulnerabilities to Be Scanned + levels: + - low + rules: [] + status: pending + - id: ra-5.3 + title: Breadth and Depth of Coverage + rules: [] + status: pending + - id: ra-5.4 + title: Discoverable Information + levels: + - high + rules: [] + status: pending + - id: ra-5.5 + title: Privileged Access + levels: + - moderate + rules: [] + status: pending + - id: ra-5.6 + title: Automated Trend Analyses + rules: [] + status: pending + - id: ra-5.7 + title: Automated Detection and Notification of Unauthorized Components + rules: [] + status: pending + - id: ra-5.8 + title: Review Historic Audit Logs + rules: [] + status: pending + - id: ra-5.9 + title: Penetration Testing and Analyses + rules: [] + status: pending + - id: ra-5.10 + title: Correlate Scanning Information + rules: [] + status: pending + - id: ra-5.11 + title: Public Disclosure Program + levels: + - low + rules: [] + status: pending + - id: ra-6 + title: Technical Surveillance Countermeasures Survey + rules: [] + status: pending + - id: ra-7 + title: Risk Response + levels: + - low + rules: [] + status: pending + - id: ra-8 + title: Privacy Impact Assessments + rules: [] + status: pending + - id: ra-9 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: ra-10 + title: Threat Hunting + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/sa.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/sa.yml new file mode 100644 index 000000000000..89a619dd4589 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/sa.yml @@ -0,0 +1,632 @@ +# NIST 800-53 SA Family: System and Services Acquisition +controls: + - id: sa-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sa-2 + title: Allocation of Resources + levels: + - low + rules: [] + status: pending + - id: sa-3 + title: System Development Life Cycle + levels: + - low + rules: [] + status: pending + - id: sa-3.1 + title: Manage Preproduction Environment + rules: [] + status: pending + - id: sa-3.2 + title: Use of Live or Operational Data + rules: [] + status: pending + - id: sa-3.3 + title: Technology Refresh + rules: [] + status: pending + - id: sa-4 + title: Acquisition Process + levels: + - low + rules: [] + status: pending + - id: sa-4.1 + title: Functional Properties of Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.2 + title: Design and Implementation Information for Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.3 + title: Development Methods, Techniques, and Practices + rules: [] + status: pending + - id: sa-4.4 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: sa-4.5 + title: System, Component, and Service Configurations + levels: + - high + rules: [] + status: pending + - id: sa-4.6 + title: Use of Information Assurance Products + rules: [] + status: pending + - id: sa-4.7 + title: 'NIAP-approved Protection Profiles ' + rules: [] + status: pending + - id: sa-4.8 + title: Continuous Monitoring Plan for Controls + rules: [] + status: pending + - id: sa-4.9 + title: Functions, Ports, Protocols, and Services in Use + levels: + - moderate + rules: [] + status: pending + - id: sa-4.10 + title: Use of Approved PIV Products + levels: + - low + rules: [] + status: pending + - id: sa-4.11 + title: System of Records + rules: [] + status: pending + - id: sa-4.12 + title: Data Ownership + rules: [] + status: pending + - id: sa-5 + title: System Documentation + levels: + - low + rules: [] + status: pending + - id: sa-5.1 + title: Functional Properties of Security Controls + rules: [] + status: pending + - id: sa-5.2 + title: Security-relevant External System Interfaces + rules: [] + status: pending + - id: sa-5.3 + title: High-level Design + rules: [] + status: pending + - id: sa-5.4 + title: Low-level Design + rules: [] + status: pending + - id: sa-5.5 + title: Source Code + rules: [] + status: pending + - id: sa-6 + title: Software Usage Restrictions + rules: [] + status: pending + - id: sa-7 + title: User-installed Software + rules: [] + status: pending + - id: sa-8 + title: Security and Privacy Engineering Principles + levels: + - low + rules: [] + status: pending + - id: sa-8.1 + title: Clear Abstractions + rules: [] + status: pending + - id: sa-8.2 + title: Least Common Mechanism + rules: [] + status: pending + - id: sa-8.3 + title: Modularity and Layering + rules: [] + status: pending + - id: sa-8.4 + title: Partially Ordered Dependencies + rules: [] + status: pending + - id: sa-8.5 + title: Efficiently Mediated Access + rules: [] + status: pending + - id: sa-8.6 + title: Minimized Sharing + rules: [] + status: pending + - id: sa-8.7 + title: Reduced Complexity + rules: [] + status: pending + - id: sa-8.8 + title: Secure Evolvability + rules: [] + status: pending + - id: sa-8.9 + title: Trusted Components + rules: [] + status: pending + - id: sa-8.10 + title: Hierarchical Trust + rules: [] + status: pending + - id: sa-8.11 + title: Inverse Modification Threshold + rules: [] + status: pending + - id: sa-8.12 + title: Hierarchical Protection + rules: [] + status: pending + - id: sa-8.13 + title: Minimized Security Elements + rules: [] + status: pending + - id: sa-8.14 + title: Least Privilege + rules: [] + status: pending + - id: sa-8.15 + title: Predicate Permission + rules: [] + status: pending + - id: sa-8.16 + title: Self-reliant Trustworthiness + rules: [] + status: pending + - id: sa-8.17 + title: Secure Distributed Composition + rules: [] + status: pending + - id: sa-8.18 + title: Trusted Communications Channels + rules: [] + status: pending + - id: sa-8.19 + title: Continuous Protection + rules: [] + status: pending + - id: sa-8.20 + title: Secure Metadata Management + rules: [] + status: pending + - id: sa-8.21 + title: Self-analysis + rules: [] + status: pending + - id: sa-8.22 + title: Accountability and Traceability + rules: [] + status: pending + - id: sa-8.23 + title: Secure Defaults + rules: [] + status: pending + - id: sa-8.24 + title: Secure Failure and Recovery + rules: [] + status: pending + - id: sa-8.25 + title: Economic Security + rules: [] + status: pending + - id: sa-8.26 + title: Performance Security + rules: [] + status: pending + - id: sa-8.27 + title: Human Factored Security + rules: [] + status: pending + - id: sa-8.28 + title: Acceptable Security + rules: [] + status: pending + - id: sa-8.29 + title: Repeatable and Documented Procedures + rules: [] + status: pending + - id: sa-8.30 + title: Procedural Rigor + rules: [] + status: pending + - id: sa-8.31 + title: Secure System Modification + rules: [] + status: pending + - id: sa-8.32 + title: Sufficient Documentation + rules: [] + status: pending + - id: sa-8.33 + title: Minimization + rules: [] + status: pending + - id: sa-9 + title: External System Services + levels: + - low + rules: [] + status: pending + - id: sa-9.1 + title: Risk Assessments and Organizational Approvals + rules: [] + status: pending + - id: sa-9.2 + title: Identification of Functions, Ports, Protocols, and Services + levels: + - moderate + rules: [] + status: pending + - id: sa-9.3 + title: Establish and Maintain Trust Relationship with Providers + rules: [] + status: pending + - id: sa-9.4 + title: Consistent Interests of Consumers and Providers + rules: [] + status: pending + - id: sa-9.5 + title: Processing, Storage, and Service Location + rules: [] + status: pending + - id: sa-9.6 + title: Organization-controlled Cryptographic Keys + rules: [] + status: pending + - id: sa-9.7 + title: Organization-controlled Integrity Checking + rules: [] + status: pending + - id: sa-9.8 + title: Processing and Storage Location — U.S. Jurisdiction + rules: [] + status: pending + - id: sa-10 + title: Developer Configuration Management + levels: + - moderate + rules: [] + status: pending + - id: sa-10.1 + title: Software and Firmware Integrity Verification + rules: [] + status: pending + - id: sa-10.2 + title: Alternative Configuration Management Processes + rules: [] + status: pending + - id: sa-10.3 + title: Hardware Integrity Verification + rules: [] + status: pending + - id: sa-10.4 + title: Trusted Generation + rules: [] + status: pending + - id: sa-10.5 + title: Mapping Integrity for Version Control + rules: [] + status: pending + - id: sa-10.6 + title: Trusted Distribution + rules: [] + status: pending + - id: sa-10.7 + title: Security and Privacy Representatives + rules: [] + status: pending + - id: sa-11 + title: Developer Testing and Evaluation + levels: + - moderate + rules: [] + status: pending + - id: sa-11.1 + title: Static Code Analysis + rules: [] + status: pending + - id: sa-11.2 + title: Threat Modeling and Vulnerability Analyses + rules: [] + status: pending + - id: sa-11.3 + title: Independent Verification of Assessment Plans and Evidence + rules: [] + status: pending + - id: sa-11.4 + title: Manual Code Reviews + rules: [] + status: pending + - id: sa-11.5 + title: Penetration Testing + rules: [] + status: pending + - id: sa-11.6 + title: Attack Surface Reviews + rules: [] + status: pending + - id: sa-11.7 + title: Verify Scope of Testing and Evaluation + rules: [] + status: pending + - id: sa-11.8 + title: Dynamic Code Analysis + rules: [] + status: pending + - id: sa-11.9 + title: Interactive Application Security Testing + rules: [] + status: pending + - id: sa-12 + title: Supply Chain Protection + rules: [] + status: pending + - id: sa-12.1 + title: Acquisition Strategies / Tools / Methods + rules: [] + status: pending + - id: sa-12.2 + title: Supplier Reviews + rules: [] + status: pending + - id: sa-12.3 + title: Trusted Shipping and Warehousing + rules: [] + status: pending + - id: sa-12.4 + title: Diversity of Suppliers + rules: [] + status: pending + - id: sa-12.5 + title: Limitation of Harm + rules: [] + status: pending + - id: sa-12.6 + title: Minimizing Procurement Time + rules: [] + status: pending + - id: sa-12.7 + title: Assessments Prior to Selection / Acceptance / Update + rules: [] + status: pending + - id: sa-12.8 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: sa-12.9 + title: Operations Security + rules: [] + status: pending + - id: sa-12.10 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sa-12.11 + title: Penetration Testing / Analysis of Elements, Processes, and Actors + rules: [] + status: pending + - id: sa-12.12 + title: Inter-organizational Agreements + rules: [] + status: pending + - id: sa-12.13 + title: Critical Information System Components + rules: [] + status: pending + - id: sa-12.14 + title: Identity and Traceability + rules: [] + status: pending + - id: sa-12.15 + title: Processes to Address Weaknesses or Deficiencies + rules: [] + status: pending + - id: sa-13 + title: Trustworthiness + rules: [] + status: pending + - id: sa-14 + title: Criticality Analysis + rules: [] + status: pending + - id: sa-14.1 + title: Critical Components with No Viable Alternative Sourcing + rules: [] + status: pending + - id: sa-15 + title: Development Process, Standards, and Tools + levels: + - moderate + rules: [] + status: pending + - id: sa-15.1 + title: Quality Metrics + rules: [] + status: pending + - id: sa-15.2 + title: Security and Privacy Tracking Tools + rules: [] + status: pending + - id: sa-15.3 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: sa-15.4 + title: Threat Modeling and Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.5 + title: Attack Surface Reduction + rules: [] + status: pending + - id: sa-15.6 + title: Continuous Improvement + rules: [] + status: pending + - id: sa-15.7 + title: Automated Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.8 + title: Reuse of Threat and Vulnerability Information + rules: [] + status: pending + - id: sa-15.9 + title: Use of Live Data + rules: [] + status: pending + - id: sa-15.10 + title: Incident Response Plan + rules: [] + status: pending + - id: sa-15.11 + title: Archive System or Component + rules: [] + status: pending + - id: sa-15.12 + title: Minimize Personally Identifiable Information + rules: [] + status: pending + - id: sa-15.13 + title: Logging Syntax + rules: [] + status: pending + - id: sa-16 + title: Developer-provided Training + levels: + - high + rules: [] + status: pending + - id: sa-17 + title: Developer Security and Privacy Architecture and Design + levels: + - high + rules: [] + status: pending + - id: sa-17.1 + title: Formal Policy Model + rules: [] + status: pending + - id: sa-17.2 + title: Security-relevant Components + rules: [] + status: pending + - id: sa-17.3 + title: Formal Correspondence + rules: [] + status: pending + - id: sa-17.4 + title: Informal Correspondence + rules: [] + status: pending + - id: sa-17.5 + title: Conceptually Simple Design + rules: [] + status: pending + - id: sa-17.6 + title: Structure for Testing + rules: [] + status: pending + - id: sa-17.7 + title: Structure for Least Privilege + rules: [] + status: pending + - id: sa-17.8 + title: Orchestration + rules: [] + status: pending + - id: sa-17.9 + title: Design Diversity + rules: [] + status: pending + - id: sa-18 + title: Tamper Resistance and Detection + rules: [] + status: pending + - id: sa-18.1 + title: Multiple Phases of System Development Life Cycle + rules: [] + status: pending + - id: sa-18.2 + title: Inspection of Systems or Components + rules: [] + status: pending + - id: sa-19 + title: Component Authenticity + rules: [] + status: pending + - id: sa-19.1 + title: Anti-counterfeit Training + rules: [] + status: pending + - id: sa-19.2 + title: Configuration Control for Component Service and Repair + rules: [] + status: pending + - id: sa-19.3 + title: Component Disposal + rules: [] + status: pending + - id: sa-19.4 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sa-20 + title: Customized Development of Critical Components + rules: [] + status: pending + - id: sa-21 + title: Developer Screening + levels: + - high + rules: [] + status: pending + - id: sa-21.1 + title: Validation of Screening + rules: [] + status: pending + - id: sa-22 + title: Unsupported System Components + levels: + - low + rules: [] + status: pending + - id: sa-22.1 + title: Alternative Sources for Continued Support + rules: [] + status: pending + - id: sa-23 + title: Specialization + rules: [] + status: pending + - id: sa-24 + title: Design For Cyber Resiliency + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/sc.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/sc.yml new file mode 100644 index 000000000000..1cea755d3a41 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/sc.yml @@ -0,0 +1,720 @@ +# NIST 800-53 SC Family: System and Communications Protection +controls: + - id: sc-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sc-2 + title: Separation of System and User Functionality + levels: + - moderate + rules: + - sysctl_kernel_dmesg_restrict + status: automated + - id: sc-2.1 + title: Interfaces for Non-privileged Users + rules: [] + status: pending + - id: sc-2.2 + title: Disassociability + rules: [] + status: pending + - id: sc-3 + title: Security Function Isolation + levels: + - high + rules: + - selinux_not_disabled + - selinux_state + - var_selinux_state=enforcing + status: automated + - id: sc-3.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-3.2 + title: Access and Flow Control Functions + rules: [] + status: pending + - id: sc-3.3 + title: Minimize Nonsecurity Functionality + rules: [] + status: pending + - id: sc-3.4 + title: Module Coupling and Cohesiveness + rules: [] + status: pending + - id: sc-3.5 + title: Layered Structures + rules: [] + status: pending + - id: sc-4 + title: Information in Shared System Resources + levels: + - moderate + rules: + - dir_perms_world_writable_sticky_bits + - file_permissions_unauthorized_world_writable + status: automated + - id: sc-4.1 + title: Security Levels + rules: [] + status: pending + - id: sc-4.2 + title: Multilevel or Periods Processing + rules: [] + status: pending + - id: sc-5 + title: Denial-of-service Protection + levels: + - low + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + - id: sc-5.1 + title: Restrict Ability to Attack Other Systems + rules: [] + status: pending + - id: sc-5.2 + title: Capacity, Bandwidth, and Redundancy + rules: [] + status: pending + - id: sc-5.3 + title: Detection and Monitoring + rules: [] + status: pending + - id: sc-6 + title: Resource Availability + rules: [] + status: pending + - id: sc-7 + title: Boundary Protection + levels: + - low + rules: + - service_firewalld_enabled + status: automated + - id: sc-7.1 + title: Physically Separated Subnetworks + rules: [] + status: pending + - id: sc-7.2 + title: Public Access + rules: [] + status: pending + - id: sc-7.3 + title: Access Points + levels: + - moderate + rules: [] + status: pending + - id: sc-7.4 + title: External Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: sc-7.5 + title: Deny by Default — Allow by Exception + levels: + - moderate + rules: [] + status: pending + - id: sc-7.6 + title: Response to Recognized Failures + rules: [] + status: pending + - id: sc-7.7 + title: Split Tunneling for Remote Devices + levels: + - moderate + rules: [] + status: pending + - id: sc-7.8 + title: Route Traffic to Authenticated Proxy Servers + levels: + - moderate + rules: [] + status: pending + - id: sc-7.9 + title: Restrict Threatening Outgoing Communications Traffic + rules: [] + status: pending + - id: sc-7.10 + title: Prevent Exfiltration + rules: [] + status: pending + - id: sc-7.11 + title: Restrict Incoming Communications Traffic + rules: [] + status: pending + - id: sc-7.12 + title: Host-based Protection + rules: [] + status: pending + - id: sc-7.13 + title: Isolation of Security Tools, Mechanisms, and Support Components + rules: [] + status: pending + - id: sc-7.14 + title: Protect Against Unauthorized Physical Connections + rules: [] + status: pending + - id: sc-7.15 + title: Networked Privileged Accesses + rules: [] + status: pending + - id: sc-7.16 + title: Prevent Discovery of System Components + rules: [] + status: pending + - id: sc-7.17 + title: Automated Enforcement of Protocol Formats + rules: [] + status: pending + - id: sc-7.18 + title: Fail Secure + levels: + - high + rules: [] + status: pending + - id: sc-7.19 + title: Block Communication from Non-organizationally Configured Hosts + rules: [] + status: pending + - id: sc-7.20 + title: Dynamic Isolation and Segregation + rules: [] + status: pending + - id: sc-7.21 + title: Isolation of System Components + levels: + - high + rules: [] + status: pending + - id: sc-7.22 + title: Separate Subnets for Connecting to Different Security Domains + rules: [] + status: pending + - id: sc-7.23 + title: Disable Sender Feedback on Protocol Validation Failure + rules: [] + status: pending + - id: sc-7.24 + title: Personally Identifiable Information + rules: [] + status: pending + - id: sc-7.25 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: sc-7.26 + title: Classified National Security System Connections + rules: [] + status: pending + - id: sc-7.27 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: sc-7.28 + title: Connections to Public Networks + rules: [] + status: pending + - id: sc-7.29 + title: Separate Subnets to Isolate Functions + rules: [] + status: pending + - id: sc-8 + title: Transmission Confidentiality and Integrity + levels: + - moderate + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: sc-8.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-8.2 + title: Pre- and Post-transmission Handling + rules: [] + status: pending + - id: sc-8.3 + title: Cryptographic Protection for Message Externals + rules: [] + status: pending + - id: sc-8.4 + title: Conceal or Randomize Communications + rules: [] + status: pending + - id: sc-8.5 + title: Protected Distribution System + rules: [] + status: pending + - id: sc-9 + title: Transmission Confidentiality + rules: [] + status: pending + - id: sc-10 + title: Network Disconnect + levels: + - moderate + rules: [] + status: pending + - id: sc-11 + title: Trusted Path + rules: [] + status: pending + - id: sc-11.1 + title: Irrefutable Communications Path + rules: [] + status: pending + - id: sc-12 + title: Cryptographic Key Establishment and Management + levels: + - low + rules: [] + status: pending + - id: sc-12.1 + title: Availability + levels: + - high + rules: [] + status: pending + - id: sc-12.2 + title: Symmetric Keys + rules: [] + status: pending + - id: sc-12.3 + title: Asymmetric Keys + rules: [] + status: pending + - id: sc-12.4 + title: PKI Certificates + rules: [] + status: pending + - id: sc-12.5 + title: PKI Certificates / Hardware Tokens + rules: [] + status: pending + - id: sc-12.6 + title: Physical Control of Keys + rules: [] + status: pending + - id: sc-13 + title: Cryptographic Protection + levels: + - low + rules: [] + status: pending + - id: sc-13.1 + title: FIPS-validated Cryptography + rules: [] + status: pending + - id: sc-13.2 + title: NSA-approved Cryptography + rules: [] + status: pending + - id: sc-13.3 + title: Individuals Without Formal Access Approvals + rules: [] + status: pending + - id: sc-13.4 + title: Digital Signatures + rules: [] + status: pending + - id: sc-14 + title: Public Access Protections + rules: [] + status: pending + - id: sc-15 + title: Collaborative Computing Devices and Applications + levels: + - low + rules: [] + status: pending + - id: sc-15.1 + title: Physical or Logical Disconnect + rules: [] + status: pending + - id: sc-15.2 + title: Blocking Inbound and Outbound Communications Traffic + rules: [] + status: pending + - id: sc-15.3 + title: Disabling and Removal in Secure Work Areas + rules: [] + status: pending + - id: sc-15.4 + title: Explicitly Indicate Current Participants + rules: [] + status: pending + - id: sc-16 + title: Transmission of Security and Privacy Attributes + rules: [] + status: pending + - id: sc-16.1 + title: Integrity Verification + rules: [] + status: pending + - id: sc-16.2 + title: Anti-spoofing Mechanisms + rules: [] + status: pending + - id: sc-16.3 + title: Cryptographic Binding + rules: [] + status: pending + - id: sc-17 + title: Public Key Infrastructure Certificates + levels: + - moderate + rules: [] + status: pending + - id: sc-18 + title: Mobile Code + levels: + - moderate + rules: [] + status: pending + - id: sc-18.1 + title: Identify Unacceptable Code and Take Corrective Actions + rules: [] + status: pending + - id: sc-18.2 + title: Acquisition, Development, and Use + rules: [] + status: pending + - id: sc-18.3 + title: Prevent Downloading and Execution + rules: [] + status: pending + - id: sc-18.4 + title: Prevent Automatic Execution + rules: [] + status: pending + - id: sc-18.5 + title: Allow Execution Only in Confined Environments + rules: [] + status: pending + - id: sc-19 + title: Voice Over Internet Protocol + rules: [] + status: pending + - id: sc-20 + title: Secure Name/Address Resolution Service (Authoritative Source) + levels: + - low + rules: [] + status: pending + - id: sc-20.1 + title: Child Subspaces + rules: [] + status: pending + - id: sc-20.2 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-21 + title: Secure Name/Address Resolution Service (Recursive or Caching Resolver) + levels: + - low + rules: [] + status: pending + - id: sc-21.1 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-22 + title: Architecture and Provisioning for Name/Address Resolution Service + levels: + - low + rules: [] + status: pending + - id: sc-23 + title: Session Authenticity + levels: + - moderate + rules: [] + status: pending + - id: sc-23.1 + title: Invalidate Session Identifiers at Logout + rules: [] + status: pending + - id: sc-23.2 + title: User-initiated Logouts and Message Displays + rules: [] + status: pending + - id: sc-23.3 + title: Unique System-generated Session Identifiers + rules: [] + status: pending + - id: sc-23.4 + title: Unique Session Identifiers with Randomization + rules: [] + status: pending + - id: sc-23.5 + title: Allowed Certificate Authorities + rules: [] + status: pending + - id: sc-24 + title: Fail in Known State + levels: + - high + rules: + - service_systemd-journald_enabled + status: automated + - id: sc-25 + title: Thin Nodes + rules: [] + status: pending + - id: sc-26 + title: Decoys + rules: [] + status: pending + - id: sc-26.1 + title: Detection of Malicious Code + rules: [] + status: pending + - id: sc-27 + title: Platform-independent Applications + rules: [] + status: pending + - id: sc-28 + title: Protection of Information at Rest + levels: + - moderate + rules: [] + status: pending + - id: sc-28.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-28.2 + title: Offline Storage + rules: [] + status: pending + - id: sc-28.3 + title: Cryptographic Keys + rules: [] + status: pending + - id: sc-29 + title: Heterogeneity + rules: [] + status: pending + - id: sc-29.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30 + title: Concealment and Misdirection + rules: [] + status: pending + - id: sc-30.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30.2 + title: Randomness + rules: [] + status: pending + - id: sc-30.3 + title: Change Processing and Storage Locations + rules: [] + status: pending + - id: sc-30.4 + title: Misleading Information + rules: [] + status: pending + - id: sc-30.5 + title: Concealment of System Components + rules: [] + status: pending + - id: sc-31 + title: Covert Channel Analysis + rules: [] + status: pending + - id: sc-31.1 + title: Test Covert Channels for Exploitability + rules: [] + status: pending + - id: sc-31.2 + title: Maximum Bandwidth + rules: [] + status: pending + - id: sc-31.3 + title: Measure Bandwidth in Operational Environments + rules: [] + status: pending + - id: sc-32 + title: System Partitioning + rules: [] + status: pending + - id: sc-32.1 + title: Separate Physical Domains for Privileged Functions + rules: [] + status: pending + - id: sc-33 + title: Transmission Preparation Integrity + rules: [] + status: pending + - id: sc-34 + title: Non-modifiable Executable Programs + rules: [] + status: pending + - id: sc-34.1 + title: No Writable Storage + rules: [] + status: pending + - id: sc-34.2 + title: Integrity Protection on Read-only Media + rules: [] + status: pending + - id: sc-34.3 + title: Hardware-based Protection + rules: [] + status: pending + - id: sc-35 + title: External Malicious Code Identification + rules: [] + status: pending + - id: sc-36 + title: Distributed Processing and Storage + rules: [] + status: pending + - id: sc-36.1 + title: Polling Techniques + rules: [] + status: pending + - id: sc-36.2 + title: Synchronization + rules: [] + status: pending + - id: sc-37 + title: Out-of-band Channels + rules: [] + status: pending + - id: sc-37.1 + title: Ensure Delivery and Transmission + rules: [] + status: pending + - id: sc-38 + title: Operations Security + rules: [] + status: pending + - id: sc-39 + title: Process Isolation + levels: + - low + rules: [] + status: pending + - id: sc-39.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-39.2 + title: Separate Execution Domain Per Thread + rules: [] + status: pending + - id: sc-40 + title: Wireless Link Protection + rules: [] + status: pending + - id: sc-40.1 + title: Electromagnetic Interference + rules: [] + status: pending + - id: sc-40.2 + title: Reduce Detection Potential + rules: [] + status: pending + - id: sc-40.3 + title: Imitative or Manipulative Communications Deception + rules: [] + status: pending + - id: sc-40.4 + title: Signal Parameter Identification + rules: [] + status: pending + - id: sc-41 + title: Port and I/O Device Access + rules: [] + status: pending + - id: sc-42 + title: Sensor Capability and Data + rules: [] + status: pending + - id: sc-42.1 + title: Reporting to Authorized Individuals or Roles + rules: [] + status: pending + - id: sc-42.2 + title: Authorized Use + rules: [] + status: pending + - id: sc-42.3 + title: Prohibit Use of Devices + rules: [] + status: pending + - id: sc-42.4 + title: Notice of Collection + rules: [] + status: pending + - id: sc-42.5 + title: Collection Minimization + rules: [] + status: pending + - id: sc-43 + title: Usage Restrictions + rules: [] + status: pending + - id: sc-44 + title: Detonation Chambers + rules: [] + status: pending + - id: sc-45 + title: System Time Synchronization + rules: [] + status: pending + - id: sc-45.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: sc-45.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: sc-46 + title: Cross Domain Policy Enforcement + rules: [] + status: pending + - id: sc-47 + title: Alternate Communications Paths + rules: [] + status: pending + - id: sc-48 + title: Sensor Relocation + rules: [] + status: pending + - id: sc-48.1 + title: Dynamic Relocation of Sensors or Monitoring Capabilities + rules: [] + status: pending + - id: sc-49 + title: Hardware-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-50 + title: Software-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-51 + title: Hardware-based Protection + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/si.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/si.yml new file mode 100644 index 000000000000..4cabcafda2db --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/si.yml @@ -0,0 +1,545 @@ +# NIST 800-53 SI Family: System and Information Integrity +controls: + - id: si-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: si-2 + title: Flaw Remediation + levels: + - low + rules: + - ensure_gpgcheck_globally_activated + - ensure_gpgcheck_never_disabled + - ensure_redhat_gpgkey_installed + status: automated + - id: si-2.1 + title: Central Management + rules: [] + status: pending + - id: si-2.2 + title: Automated Flaw Remediation Status + levels: + - moderate + rules: [] + status: pending + - id: si-2.3 + title: Time to Remediate Flaws and Benchmarks for Corrective Actions + rules: [] + status: pending + - id: si-2.4 + title: Automated Patch Management Tools + rules: [] + status: pending + - id: si-2.5 + title: Automatic Software and Firmware Updates + rules: [] + status: pending + - id: si-2.6 + title: Removal of Previous Versions of Software and Firmware + rules: [] + status: pending + - id: si-2.7 + title: Root Cause Analysis + rules: [] + status: pending + - id: si-3 + title: Malicious Code Protection + levels: + - low + rules: + - kernel_module_usb-storage_disabled + - service_autofs_disabled + status: automated + - id: si-3.1 + title: Central Management + rules: [] + status: pending + - id: si-3.2 + title: Automatic Updates + rules: [] + status: pending + - id: si-3.3 + title: Non-privileged Users + rules: [] + status: pending + - id: si-3.4 + title: Updates Only by Privileged Users + rules: [] + status: pending + - id: si-3.5 + title: Portable Storage Devices + rules: [] + status: pending + - id: si-3.6 + title: Testing and Verification + rules: [] + status: pending + - id: si-3.7 + title: Nonsignature-based Detection + rules: [] + status: pending + - id: si-3.8 + title: Detect Unauthorized Commands + rules: [] + status: pending + - id: si-3.9 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: si-3.10 + title: Malicious Code Analysis + rules: [] + status: pending + - id: si-4 + title: System Monitoring + levels: + - low + rules: + - kernel_module_dccp_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_tipc_disabled + - service_avahi-daemon_disabled + status: automated + - id: si-4.1 + title: System-wide Intrusion Detection System + rules: [] + status: pending + - id: si-4.2 + title: Automated Tools and Mechanisms for Real-time Analysis + levels: + - moderate + rules: [] + status: pending + - id: si-4.3 + title: Automated Tool and Mechanism Integration + rules: [] + status: pending + - id: si-4.4 + title: Inbound and Outbound Communications Traffic + levels: + - moderate + rules: [] + status: pending + - id: si-4.5 + title: System-generated Alerts + levels: + - moderate + rules: [] + status: pending + - id: si-4.6 + title: Restrict Non-privileged Users + rules: [] + status: pending + - id: si-4.7 + title: Automated Response to Suspicious Events + rules: [] + status: pending + - id: si-4.8 + title: Protection of Monitoring Information + rules: [] + status: pending + - id: si-4.9 + title: Testing of Monitoring Tools and Mechanisms + rules: [] + status: pending + - id: si-4.10 + title: Visibility of Encrypted Communications + levels: + - high + rules: [] + status: pending + - id: si-4.11 + title: Analyze Communications Traffic Anomalies + rules: [] + status: pending + - id: si-4.12 + title: Automated Organization-generated Alerts + levels: + - high + rules: [] + status: pending + - id: si-4.13 + title: Analyze Traffic and Event Patterns + rules: [] + status: pending + - id: si-4.14 + title: Wireless Intrusion Detection + levels: + - high + rules: [] + status: pending + - id: si-4.15 + title: Wireless to Wireline Communications + rules: [] + status: pending + - id: si-4.16 + title: Correlate Monitoring Information + rules: [] + status: pending + - id: si-4.17 + title: Integrated Situational Awareness + rules: [] + status: pending + - id: si-4.18 + title: Analyze Traffic and Covert Exfiltration + rules: [] + status: pending + - id: si-4.19 + title: Risk for Individuals + rules: [] + status: pending + - id: si-4.20 + title: Privileged Users + levels: + - high + rules: [] + status: pending + - id: si-4.21 + title: Probationary Periods + rules: [] + status: pending + - id: si-4.22 + title: Unauthorized Network Services + levels: + - high + rules: [] + status: pending + - id: si-4.23 + title: Host-based Devices + rules: [] + status: pending + - id: si-4.24 + title: Indicators of Compromise + rules: [] + status: pending + - id: si-4.25 + title: Optimize Network Traffic Analysis + rules: [] + status: pending + - id: si-5 + title: Security Alerts, Advisories, and Directives + levels: + - low + rules: [] + status: pending + - id: si-5.1 + title: Automated Alerts and Advisories + levels: + - high + rules: [] + status: pending + - id: si-6 + title: Security and Privacy Function Verification + levels: + - high + rules: [] + status: pending + - id: si-6.1 + title: Notification of Failed Security Tests + rules: [] + status: pending + - id: si-6.2 + title: Automation Support for Distributed Testing + rules: [] + status: pending + - id: si-6.3 + title: Report Verification Results + rules: [] + status: pending + - id: si-7 + title: Software, Firmware, and Information Integrity + levels: + - moderate + rules: [] + status: pending + - id: si-7.1 + title: Integrity Checks + levels: + - moderate + rules: [] + status: pending + - id: si-7.2 + title: Automated Notifications of Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.3 + title: Centrally Managed Integrity Tools + rules: [] + status: pending + - id: si-7.4 + title: Tamper-evident Packaging + rules: [] + status: pending + - id: si-7.5 + title: Automated Response to Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: si-7.7 + title: Integration of Detection and Response + levels: + - moderate + rules: [] + status: pending + - id: si-7.8 + title: Auditing Capability for Significant Events + rules: [] + status: pending + - id: si-7.9 + title: Verify Boot Process + rules: [] + status: pending + - id: si-7.10 + title: Protection of Boot Firmware + rules: [] + status: pending + - id: si-7.11 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: si-7.12 + title: Integrity Verification + rules: [] + status: pending + - id: si-7.13 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: si-7.14 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: si-7.15 + title: Code Authentication + levels: + - high + rules: [] + status: pending + - id: si-7.16 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-7.17 + title: Runtime Application Self-protection + rules: [] + status: pending + - id: si-8 + title: Spam Protection + levels: + - moderate + rules: [] + status: pending + - id: si-8.1 + title: Central Management + rules: [] + status: pending + - id: si-8.2 + title: Automatic Updates + levels: + - moderate + rules: [] + status: pending + - id: si-8.3 + title: Continuous Learning Capability + rules: [] + status: pending + - id: si-9 + title: Information Input Restrictions + rules: [] + status: pending + - id: si-10 + title: Information Input Validation + levels: + - moderate + rules: [] + status: pending + - id: si-10.1 + title: Manual Override Capability + rules: [] + status: pending + - id: si-10.2 + title: Review and Resolve Errors + rules: [] + status: pending + - id: si-10.3 + title: Predictable Behavior + rules: [] + status: pending + - id: si-10.4 + title: Timing Interactions + rules: [] + status: pending + - id: si-10.5 + title: Restrict Inputs to Trusted Sources and Approved Formats + rules: [] + status: pending + - id: si-10.6 + title: Injection Prevention + rules: [] + status: pending + - id: si-11 + title: Error Handling + levels: + - moderate + rules: [] + status: pending + - id: si-12 + title: Information Management and Retention + levels: + - low + rules: [] + status: pending + - id: si-12.1 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: si-12.2 + title: Minimize Personally Identifiable Information in Testing, Training, and Research + rules: [] + status: pending + - id: si-12.3 + title: Information Disposal + rules: [] + status: pending + - id: si-13 + title: Predictable Failure Prevention + rules: [] + status: pending + - id: si-13.1 + title: Transferring Component Responsibilities + rules: [] + status: pending + - id: si-13.2 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-13.3 + title: Manual Transfer Between Components + rules: [] + status: pending + - id: si-13.4 + title: Standby Component Installation and Notification + rules: [] + status: pending + - id: si-13.5 + title: Failover Capability + rules: [] + status: pending + - id: si-14 + title: Non-persistence + rules: [] + status: pending + - id: si-14.1 + title: Refresh from Trusted Sources + rules: [] + status: pending + - id: si-14.2 + title: Non-persistent Information + rules: [] + status: pending + - id: si-14.3 + title: Non-persistent Connectivity + rules: [] + status: pending + - id: si-15 + title: Information Output Filtering + rules: [] + status: pending + - id: si-16 + title: Memory Protection + levels: + - moderate + rules: + - sysctl_kernel_randomize_va_space + status: automated + - id: si-17 + title: Fail-safe Procedures + rules: [] + status: pending + - id: si-18 + title: Personally Identifiable Information Quality Operations + rules: [] + status: pending + - id: si-18.1 + title: Automation Support + rules: [] + status: pending + - id: si-18.2 + title: Data Tags + rules: [] + status: pending + - id: si-18.3 + title: Collection + rules: [] + status: pending + - id: si-18.4 + title: Individual Requests + rules: [] + status: pending + - id: si-18.5 + title: Notice of Correction or Deletion + rules: [] + status: pending + - id: si-19 + title: De-identification + rules: [] + status: pending + - id: si-19.1 + title: Collection + rules: [] + status: pending + - id: si-19.2 + title: Archiving + rules: [] + status: pending + - id: si-19.3 + title: Release + rules: [] + status: pending + - id: si-19.4 + title: Removal, Masking, Encryption, Hashing, or Replacement of Direct Identifiers + rules: [] + status: pending + - id: si-19.5 + title: Statistical Disclosure Control + rules: [] + status: pending + - id: si-19.6 + title: Differential Privacy + rules: [] + status: pending + - id: si-19.7 + title: Validated Algorithms and Software + rules: [] + status: pending + - id: si-19.8 + title: Motivated Intruder + rules: [] + status: pending + - id: si-20 + title: Tainting + rules: [] + status: pending + - id: si-21 + title: Information Refresh + rules: [] + status: pending + - id: si-22 + title: Information Diversity + rules: [] + status: pending + - id: si-23 + title: Information Fragmentation + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel8/sr.yml b/shared/references/controls/nist_800_53_cis_reference_rhel8/sr.yml new file mode 100644 index 000000000000..1e130f32cd89 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel8/sr.yml @@ -0,0 +1,138 @@ +# NIST 800-53 SR Family: Supply Chain Risk Management +controls: + - id: sr-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sr-2 + title: Supply Chain Risk Management Plan + levels: + - low + rules: [] + status: pending + - id: sr-2.1 + title: Establish SCRM Team + levels: + - low + rules: [] + status: pending + - id: sr-3 + title: Supply Chain Controls and Processes + levels: + - low + rules: [] + status: pending + - id: sr-3.1 + title: Diverse Supply Base + rules: [] + status: pending + - id: sr-3.2 + title: Limitation of Harm + rules: [] + status: pending + - id: sr-3.3 + title: Sub-tier Flow Down + rules: [] + status: pending + - id: sr-4 + title: Provenance + rules: [] + status: pending + - id: sr-4.1 + title: Identity + rules: [] + status: pending + - id: sr-4.2 + title: Track and Trace + rules: [] + status: pending + - id: sr-4.3 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sr-4.4 + title: Supply Chain Integrity — Pedigree + rules: [] + status: pending + - id: sr-5 + title: Acquisition Strategies, Tools, and Methods + levels: + - low + rules: [] + status: pending + - id: sr-5.1 + title: Adequate Supply + rules: [] + status: pending + - id: sr-5.2 + title: Assessments Prior to Selection, Acceptance, Modification, or Update + rules: [] + status: pending + - id: sr-6 + title: Supplier Assessments and Reviews + levels: + - moderate + rules: [] + status: pending + - id: sr-6.1 + title: Testing and Analysis + rules: [] + status: pending + - id: sr-7 + title: Supply Chain Operations Security + rules: [] + status: pending + - id: sr-8 + title: Notification Agreements + levels: + - low + rules: [] + status: pending + - id: sr-9 + title: Tamper Resistance and Detection + levels: + - high + rules: [] + status: pending + - id: sr-9.1 + title: Multiple Stages of System Development Life Cycle + levels: + - high + rules: [] + status: pending + - id: sr-10 + title: Inspection of Systems or Components + levels: + - low + rules: [] + status: pending + - id: sr-11 + title: Component Authenticity + levels: + - low + rules: [] + status: pending + - id: sr-11.1 + title: Anti-counterfeit Training + levels: + - low + rules: [] + status: pending + - id: sr-11.2 + title: Configuration Control for Component Service and Repair + levels: + - low + rules: [] + status: pending + - id: sr-11.3 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sr-12 + title: Component Disposal + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9.yml new file mode 100644 index 000000000000..56b1526dfb4f --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9.yml @@ -0,0 +1,24 @@ +# AUTO-GENERATED Product-Specific CIS Reference File (RHEL9) +# +# This file contains only metadata for RHEL9. +# Control families are in nist_800_53_cis_reference_rhel9/ +# Do NOT edit manually. Updated by weekly sync workflow. +# +# OSCAL metadata (description, parameters, guidance, related_controls) is NOT +# included in control files. Retrieve from OSCAL catalog when needed. +# +policy: NIST 800-53 Revision 5 CIS Reference (RHEL9) +title: NIST Special Publication 800-53 Revision 5 CIS Reference for RHEL9 +id: nist_800_53_cis_reference_rhel9 +version: Revision 5 +source: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +product: rhel9 +controls_dir: nist_800_53_cis_reference_rhel9 +levels: + - id: low + - id: moderate + inherits_from: + - low + - id: high + inherits_from: + - moderate diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ac.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ac.yml new file mode 100644 index 000000000000..7e4e5d5edd90 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ac.yml @@ -0,0 +1,833 @@ +# NIST 800-53 AC Family: Access Control +controls: + - id: ac-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ac-2 + title: Account Management + levels: + - low + rules: [] + status: pending + - id: ac-2.1 + title: Automated System Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.2 + title: Automated Temporary and Emergency Account Management + levels: + - moderate + rules: [] + status: pending + - id: ac-2.3 + title: Disable Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-2.4 + title: Automated Audit Actions + levels: + - moderate + rules: [] + status: pending + - id: ac-2.5 + title: Inactivity Logout + levels: + - moderate + rules: + - accounts_tmout + - no_invalid_shell_accounts_unlocked + - no_password_auth_for_systemaccounts + - no_shelllogin_for_systemaccounts + - inactivity_timeout_value=15_minutes + - var_accounts_tmout=15_min + status: automated + - id: ac-2.6 + title: Dynamic Privilege Management + rules: [] + status: pending + - id: ac-2.7 + title: Privileged User Accounts + rules: [] + status: pending + - id: ac-2.8 + title: Dynamic Account Management + rules: [] + status: pending + - id: ac-2.9 + title: Restrictions on Use of Shared and Group Accounts + rules: [] + status: pending + - id: ac-2.10 + title: Shared and Group Account Credential Change + rules: [] + status: pending + - id: ac-2.11 + title: Usage Conditions + levels: + - high + rules: [] + status: pending + - id: ac-2.12 + title: Account Monitoring for Atypical Usage + levels: + - high + rules: [] + status: pending + - id: ac-2.13 + title: Disable Accounts for High-risk Individuals + levels: + - moderate + rules: [] + status: pending + - id: ac-3 + title: Access Enforcement + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - audit_rules_immutable + - dir_perms_world_writable_sticky_bits + - ensure_pam_wheel_group_empty + - file_at_allow_exists + - file_at_deny_not_exist + - file_cron_allow_exists + - file_cron_deny_not_exist + - file_etc_security_opasswd + - file_groupowner_at_allow + - file_groupowner_backup_etc_group + - file_groupowner_backup_etc_gshadow + - file_groupowner_backup_etc_passwd + - file_groupowner_backup_etc_shadow + - file_groupowner_cron_allow + - file_groupowner_cron_d + - file_groupowner_cron_daily + - file_groupowner_cron_hourly + - file_groupowner_cron_monthly + - file_groupowner_cron_weekly + - file_groupowner_crontab + - file_groupowner_etc_group + - file_groupowner_etc_gshadow + - file_groupowner_etc_issue + - file_groupowner_etc_issue_net + - file_groupowner_etc_motd + - file_groupowner_etc_passwd + - file_groupowner_etc_shadow + - file_groupowner_etc_shells + - file_groupowner_grub2_cfg + - file_groupowner_sshd_config + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_at_allow + - file_owner_backup_etc_group + - file_owner_backup_etc_gshadow + - file_owner_backup_etc_passwd + - file_owner_backup_etc_shadow + - file_owner_cron_allow + - file_owner_cron_d + - file_owner_cron_daily + - file_owner_cron_hourly + - file_owner_cron_monthly + - file_owner_cron_weekly + - file_owner_crontab + - file_owner_etc_group + - file_owner_etc_gshadow + - file_owner_etc_issue + - file_owner_etc_issue_net + - file_owner_etc_motd + - file_owner_etc_passwd + - file_owner_etc_shadow + - file_owner_etc_shells + - file_owner_grub2_cfg + - file_owner_sshd_config + - file_owner_user_cfg + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_at_allow + - file_permissions_backup_etc_group + - file_permissions_backup_etc_gshadow + - file_permissions_backup_etc_passwd + - file_permissions_backup_etc_shadow + - file_permissions_cron_allow + - file_permissions_cron_d + - file_permissions_cron_daily + - file_permissions_cron_hourly + - file_permissions_cron_monthly + - file_permissions_cron_weekly + - file_permissions_crontab + - file_permissions_etc_group + - file_permissions_etc_gshadow + - file_permissions_etc_issue + - file_permissions_etc_issue_net + - file_permissions_etc_motd + - file_permissions_etc_passwd + - file_permissions_etc_shadow + - file_permissions_etc_shells + - file_permissions_grub2_cfg + - file_permissions_sshd_config + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_unauthorized_world_writable + - file_permissions_ungroupowned + - file_permissions_user_cfg + - grub2_enable_selinux + - grub2_password + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_home_nodev + - mount_option_home_nosuid + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - mount_option_var_log_audit_nodev + - mount_option_var_log_audit_noexec + - mount_option_var_log_audit_nosuid + - mount_option_var_log_nodev + - mount_option_var_log_noexec + - mount_option_var_log_nosuid + - mount_option_var_nodev + - mount_option_var_nosuid + - mount_option_var_tmp_nodev + - mount_option_var_tmp_noexec + - mount_option_var_tmp_nosuid + - no_files_unowned_by_user + - package_libselinux_installed + - package_mcstrans_removed + - package_setroubleshoot_removed + - rsyslog_files_groupownership + - rsyslog_files_ownership + - rsyslog_files_permissions + - selinux_not_disabled + - selinux_policytype + - sshd_limit_user_access + - use_pam_wheel_group_for_su + - var_accounts_user_umask=027 + - var_pam_wheel_group_for_su=cis + - var_selinux_policy_name=targeted + status: automated + - id: ac-3.1 + title: Restricted Access to Privileged Functions + rules: [] + status: pending + - id: ac-3.2 + title: Dual Authorization + rules: [] + status: pending + - id: ac-3.3 + title: Mandatory Access Control + rules: [] + status: pending + - id: ac-3.4 + title: Discretionary Access Control + rules: [] + status: pending + - id: ac-3.5 + title: Security-relevant Information + rules: [] + status: pending + - id: ac-3.6 + title: Protection of User and System Information + rules: [] + status: pending + - id: ac-3.7 + title: Role-based Access Control + rules: [] + status: pending + - id: ac-3.8 + title: Revocation of Access Authorizations + rules: [] + status: pending + - id: ac-3.9 + title: Controlled Release + rules: [] + status: pending + - id: ac-3.10 + title: Audited Override of Access Control Mechanisms + rules: [] + status: pending + - id: ac-3.11 + title: Restrict Access to Specific Information Types + rules: [] + status: pending + - id: ac-3.12 + title: Assert and Enforce Application Access + rules: [] + status: pending + - id: ac-3.13 + title: Attribute-based Access Control + rules: [] + status: pending + - id: ac-3.14 + title: Individual Access + rules: [] + status: pending + - id: ac-3.15 + title: Discretionary and Mandatory Access Control + rules: [] + status: pending + - id: ac-4 + title: Information Flow Enforcement + levels: + - moderate + rules: [] + status: pending + - id: ac-4.1 + title: Object Security and Privacy Attributes + rules: [] + status: pending + - id: ac-4.2 + title: Processing Domains + rules: [] + status: pending + - id: ac-4.3 + title: Dynamic Information Flow Control + rules: [] + status: pending + - id: ac-4.4 + title: Flow Control of Encrypted Information + levels: + - high + rules: [] + status: pending + - id: ac-4.5 + title: Embedded Data Types + rules: [] + status: pending + - id: ac-4.6 + title: Metadata + rules: [] + status: pending + - id: ac-4.7 + title: One-way Flow Mechanisms + rules: [] + status: pending + - id: ac-4.8 + title: Security and Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.9 + title: Human Reviews + rules: [] + status: pending + - id: ac-4.10 + title: Enable and Disable Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.11 + title: Configuration of Security or Privacy Policy Filters + rules: [] + status: pending + - id: ac-4.12 + title: Data Type Identifiers + rules: [] + status: pending + - id: ac-4.13 + title: Decomposition into Policy-relevant Subcomponents + rules: [] + status: pending + - id: ac-4.14 + title: Security or Privacy Policy Filter Constraints + rules: [] + status: pending + - id: ac-4.15 + title: Detection of Unsanctioned Information + rules: [] + status: pending + - id: ac-4.16 + title: Information Transfers on Interconnected Systems + rules: [] + status: pending + - id: ac-4.17 + title: Domain Authentication + rules: [] + status: pending + - id: ac-4.18 + title: Security Attribute Binding + rules: [] + status: pending + - id: ac-4.19 + title: Validation of Metadata + rules: [] + status: pending + - id: ac-4.20 + title: Approved Solutions + rules: [] + status: pending + - id: ac-4.21 + title: Physical or Logical Separation of Information Flows + rules: [] + status: pending + - id: ac-4.22 + title: Access Only + rules: [] + status: pending + - id: ac-4.23 + title: Modify Non-releasable Information + rules: [] + status: pending + - id: ac-4.24 + title: Internal Normalized Format + rules: [] + status: pending + - id: ac-4.25 + title: Data Sanitization + rules: [] + status: pending + - id: ac-4.26 + title: Audit Filtering Actions + rules: [] + status: pending + - id: ac-4.27 + title: Redundant/Independent Filtering Mechanisms + rules: [] + status: pending + - id: ac-4.28 + title: Linear Filter Pipelines + rules: [] + status: pending + - id: ac-4.29 + title: Filter Orchestration Engines + rules: [] + status: pending + - id: ac-4.30 + title: Filter Mechanisms Using Multiple Processes + rules: [] + status: pending + - id: ac-4.31 + title: Failed Content Transfer Prevention + rules: [] + status: pending + - id: ac-4.32 + title: Process Requirements for Information Transfer + rules: [] + status: pending + - id: ac-5 + title: Separation of Duties + levels: + - moderate + rules: [] + status: pending + - id: ac-6 + title: Least Privilege + levels: + - moderate + rules: + - sshd_disable_root_login + - sudo_add_use_pty + - sudo_remove_no_authenticate + - sudo_remove_nopasswd + status: automated + - id: ac-6.1 + title: Authorize Access to Security Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.2 + title: Non-privileged Access for Nonsecurity Functions + levels: + - moderate + rules: + - package_sudo_installed + status: automated + - id: ac-6.3 + title: Network Access to Privileged Commands + levels: + - high + rules: [] + status: pending + - id: ac-6.4 + title: Separate Processing Domains + rules: [] + status: pending + - id: ac-6.5 + title: Privileged Accounts + levels: + - moderate + rules: [] + status: pending + - id: ac-6.6 + title: Privileged Access by Non-organizational Users + rules: [] + status: pending + - id: ac-6.7 + title: Review of User Privileges + levels: + - moderate + rules: [] + status: pending + - id: ac-6.8 + title: Privilege Levels for Code Execution + rules: [] + status: pending + - id: ac-6.9 + title: Log Use of Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-6.10 + title: Prohibit Non-privileged Users from Executing Privileged Functions + levels: + - moderate + rules: [] + status: pending + - id: ac-7 + title: Unsuccessful Logon Attempts + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - accounts_passwords_pam_faillock_deny + - accounts_passwords_pam_faillock_even_deny_root_or_root_unlock_time + - accounts_passwords_pam_faillock_unlock_time + - var_accounts_passwords_pam_faillock_deny=5 + - var_accounts_passwords_pam_faillock_dir=run + - var_accounts_passwords_pam_faillock_root_unlock_time=60 + - var_accounts_passwords_pam_faillock_unlock_time=900 + status: automated + - id: ac-7.1 + title: Automatic Account Lock + rules: [] + status: pending + - id: ac-7.2 + title: Purge or Wipe Mobile Device + rules: [] + status: pending + - id: ac-7.3 + title: Biometric Attempt Limiting + rules: [] + status: pending + - id: ac-7.4 + title: Use of Alternate Authentication Factor + rules: [] + status: pending + - id: ac-8 + title: System Use Notification + levels: + - low + rules: + - dconf_gnome_banner_enabled + - dconf_gnome_login_banner_text + status: automated + - id: ac-9 + title: Previous Logon Notification + rules: [] + status: pending + - id: ac-9.1 + title: Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.2 + title: Successful and Unsuccessful Logons + rules: [] + status: pending + - id: ac-9.3 + title: Notification of Account Changes + rules: [] + status: pending + - id: ac-9.4 + title: Additional Logon Information + rules: [] + status: pending + - id: ac-10 + title: Concurrent Session Control + levels: + - high + rules: [] + status: pending + - id: ac-11 + title: Device Lock + levels: + - moderate + rules: + - dconf_gnome_screensaver_idle_delay + - dconf_gnome_screensaver_lock_delay + - dconf_gnome_screensaver_user_locks + - dconf_gnome_session_idle_user_locks + - var_screensaver_lock_delay=5_seconds + status: automated + - id: ac-11.1 + title: Pattern-hiding Displays + levels: + - moderate + rules: [] + status: pending + - id: ac-12 + title: Session Termination + levels: + - moderate + rules: [] + status: pending + - id: ac-12.1 + title: User-initiated Logouts + rules: [] + status: pending + - id: ac-12.2 + title: Termination Message + rules: [] + status: pending + - id: ac-12.3 + title: Timeout Warning Message + rules: [] + status: pending + - id: ac-13 + title: Supervision and Review — Access Control + rules: [] + status: pending + - id: ac-14 + title: Permitted Actions Without Identification or Authentication + levels: + - low + rules: [] + status: pending + - id: ac-14.1 + title: Necessary Uses + rules: [] + status: pending + - id: ac-15 + title: Automated Marking + rules: [] + status: pending + - id: ac-16 + title: Security and Privacy Attributes + rules: [] + status: pending + - id: ac-16.1 + title: Dynamic Attribute Association + rules: [] + status: pending + - id: ac-16.2 + title: Attribute Value Changes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.3 + title: Maintenance of Attribute Associations by System + rules: [] + status: pending + - id: ac-16.4 + title: Association of Attributes by Authorized Individuals + rules: [] + status: pending + - id: ac-16.5 + title: Attribute Displays on Objects to Be Output + rules: [] + status: pending + - id: ac-16.6 + title: Maintenance of Attribute Association + rules: [] + status: pending + - id: ac-16.7 + title: Consistent Attribute Interpretation + rules: [] + status: pending + - id: ac-16.8 + title: Association Techniques and Technologies + rules: [] + status: pending + - id: ac-16.9 + title: Attribute Reassignment — Regrading Mechanisms + rules: [] + status: pending + - id: ac-16.10 + title: Attribute Configuration by Authorized Individuals + rules: [] + status: pending + - id: ac-17 + title: Remote Access + levels: + - low + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: ac-17.1 + title: Monitoring and Control + levels: + - moderate + rules: [] + status: pending + - id: ac-17.2 + title: Protection of Confidentiality and Integrity Using Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-17.3 + title: Managed Access Control Points + levels: + - moderate + rules: [] + status: pending + - id: ac-17.4 + title: Privileged Commands and Access + levels: + - moderate + rules: [] + status: pending + - id: ac-17.5 + title: Monitoring for Unauthorized Connections + rules: [] + status: pending + - id: ac-17.6 + title: Protection of Mechanism Information + rules: [] + status: pending + - id: ac-17.7 + title: Additional Protection for Security Function Access + rules: [] + status: pending + - id: ac-17.8 + title: Disable Nonsecure Network Protocols + rules: [] + status: pending + - id: ac-17.9 + title: Disconnect or Disable Access + rules: [] + status: pending + - id: ac-17.10 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: ac-18 + title: Wireless Access + levels: + - low + rules: + - wireless_disable_interfaces + status: automated + - id: ac-18.1 + title: Authentication and Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-18.2 + title: Monitoring Unauthorized Connections + rules: [] + status: pending + - id: ac-18.3 + title: Disable Wireless Networking + levels: + - moderate + rules: [] + status: pending + - id: ac-18.4 + title: Restrict Configurations by Users + levels: + - high + rules: [] + status: pending + - id: ac-18.5 + title: Antennas and Transmission Power Levels + levels: + - high + rules: [] + status: pending + - id: ac-19 + title: Access Control for Mobile Devices + levels: + - low + rules: [] + status: pending + - id: ac-19.1 + title: Use of Writable and Portable Storage Devices + rules: [] + status: pending + - id: ac-19.2 + title: Use of Personally Owned Portable Storage Devices + rules: [] + status: pending + - id: ac-19.3 + title: Use of Portable Storage Devices with No Identifiable Owner + rules: [] + status: pending + - id: ac-19.4 + title: Restrictions for Classified Information + rules: [] + status: pending + - id: ac-19.5 + title: Full Device or Container-based Encryption + levels: + - moderate + rules: [] + status: pending + - id: ac-20 + title: Use of External Systems + levels: + - low + rules: [] + status: pending + - id: ac-20.1 + title: Limits on Authorized Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.2 + title: Portable Storage Devices — Restricted Use + levels: + - moderate + rules: [] + status: pending + - id: ac-20.3 + title: Non-organizationally Owned Systems — Restricted Use + rules: [] + status: pending + - id: ac-20.4 + title: Network Accessible Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-20.5 + title: Portable Storage Devices — Prohibited Use + rules: [] + status: pending + - id: ac-21 + title: Information Sharing + levels: + - moderate + rules: [] + status: pending + - id: ac-21.1 + title: Automated Decision Support + rules: [] + status: pending + - id: ac-21.2 + title: Information Search and Retrieval + rules: [] + status: pending + - id: ac-22 + title: Publicly Accessible Content + levels: + - low + rules: [] + status: pending + - id: ac-23 + title: Data Mining Protection + rules: [] + status: pending + - id: ac-24 + title: Access Control Decisions + rules: [] + status: pending + - id: ac-24.1 + title: Transmit Access Authorization Information + rules: [] + status: pending + - id: ac-24.2 + title: No User or Process Identity + rules: [] + status: pending + - id: ac-25 + title: Reference Monitor + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/at.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/at.yml new file mode 100644 index 000000000000..80211cdb5591 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/at.yml @@ -0,0 +1,82 @@ +# NIST 800-53 AT Family: Awareness and Training +controls: + - id: at-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: at-2 + title: Literacy Training and Awareness + levels: + - low + rules: [] + status: pending + - id: at-2.1 + title: Practical Exercises + rules: [] + status: pending + - id: at-2.2 + title: Insider Threat + levels: + - low + rules: [] + status: pending + - id: at-2.3 + title: Social Engineering and Mining + levels: + - moderate + rules: [] + status: pending + - id: at-2.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-2.5 + title: Advanced Persistent Threat + rules: [] + status: pending + - id: at-2.6 + title: Cyber Threat Environment + rules: [] + status: pending + - id: at-3 + title: Role-based Training + levels: + - low + rules: [] + status: pending + - id: at-3.1 + title: Environmental Controls + rules: [] + status: pending + - id: at-3.2 + title: Physical Security Controls + rules: [] + status: pending + - id: at-3.3 + title: Practical Exercises + rules: [] + status: pending + - id: at-3.4 + title: Suspicious Communications and Anomalous System Behavior + rules: [] + status: pending + - id: at-3.5 + title: Processing Personally Identifiable Information + rules: [] + status: pending + - id: at-4 + title: Training Records + levels: + - low + rules: [] + status: pending + - id: at-5 + title: Contacts with Security Groups and Associations + rules: [] + status: pending + - id: at-6 + title: Training Feedback + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/au.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/au.yml new file mode 100644 index 000000000000..0f98811a7f5a --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/au.yml @@ -0,0 +1,478 @@ +# NIST 800-53 AU Family: Audit and Accountability +controls: + - id: au-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: au-2 + title: Event Logging + levels: + - low + rules: + - aide_build_database + - aide_periodic_cron_checking + - audit_rules_execution_chacl + - audit_rules_execution_chcon + - audit_rules_execution_setfacl + - audit_rules_privileged_commands_usermod + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - auditd_data_retention_action_mail_acct + - auditd_data_retention_admin_space_left_action + - auditd_data_retention_space_left_action + - grub2_audit_backlog_limit_argument + - package_aide_installed + - package_audit-libs_installed + - package_audit_installed + - package_systemd-journal-remote_installed + - service_auditd_enabled + - service_systemd-journald_enabled + - socket_systemd-journal-remote_disabled + - var_audit_backlog_limit=8192 + - var_auditd_action_mail_acct=root + - var_auditd_admin_space_left_action=cis_rhel9 + - var_auditd_space_left_action=cis_rhel9 + status: automated + - id: au-2.1 + title: Compilation of Audit Records from Multiple Sources + rules: [] + status: pending + - id: au-2.2 + title: Selection of Audit Events by Component + rules: [] + status: pending + - id: au-2.3 + title: Reviews and Updates + rules: [] + status: pending + - id: au-2.4 + title: Privileged Functions + rules: [] + status: pending + - id: au-3 + title: Content of Audit Records + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_mac_modification + - audit_rules_mac_modification_usr_share + - audit_rules_networkconfig_modification + - audit_rules_networkconfig_modification_hostname_file + - audit_rules_networkconfig_modification_network_scripts + - audit_rules_networkconfig_modification_networkmanager + - audit_rules_privileged_commands + - audit_rules_privileged_commands_kmod + - audit_rules_session_events_btmp + - audit_rules_session_events_utmp + - audit_rules_session_events_wtmp + - audit_rules_suid_auid_privilege_function + - audit_rules_sysadmin_actions + - audit_rules_time_adjtimex + - audit_rules_time_clock_settime + - audit_rules_time_settimeofday + - audit_rules_time_watch_localtime + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - chronyd_run_as_chrony_user + - chronyd_specify_remote_server + - directory_permissions_var_log_audit + - file_groupownership_audit_binaries + - file_ownership_var_log_audit_stig + - file_permissions_audit_binaries + - journald_storage + - package_chrony_installed + - sshd_set_loglevel_verbose + - sshd_set_max_auth_tries + - sudo_custom_logfile + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_default_log_martians + - sshd_max_auth_tries_value=4 + - var_multiple_time_servers=rhel + status: automated + - id: au-3.1 + title: Additional Audit Information + levels: + - moderate + rules: [] + status: pending + - id: au-3.2 + title: Centralized Management of Planned Audit Record Content + rules: [] + status: pending + - id: au-3.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: au-4 + title: Audit Log Storage Capacity + levels: + - low + rules: + - journald_compress + status: automated + - id: au-4.1 + title: Transfer to Alternate Storage + rules: [] + status: pending + - id: au-5 + title: Response to Audit Logging Process Failures + levels: + - low + rules: + - auditd_data_disk_error_action + - auditd_data_disk_full_action + - var_auditd_disk_error_action=cis_rhel9 + - var_auditd_disk_full_action=cis_rhel9 + status: automated + - id: au-5.1 + title: Storage Capacity Warning + levels: + - high + rules: [] + status: pending + - id: au-5.2 + title: Real-time Alerts + levels: + - high + rules: [] + status: pending + - id: au-5.3 + title: Configurable Traffic Volume Thresholds + rules: [] + status: pending + - id: au-5.4 + title: Shutdown on Failure + rules: [] + status: pending + - id: au-5.5 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-6 + title: Audit Record Review, Analysis, and Reporting + levels: + - low + rules: [] + status: pending + - id: au-6.1 + title: Automated Process Integration + levels: + - moderate + rules: [] + status: pending + - id: au-6.2 + title: Automated Security Alerts + rules: [] + status: pending + - id: au-6.3 + title: Correlate Audit Record Repositories + levels: + - moderate + rules: [] + status: pending + - id: au-6.4 + title: Central Review and Analysis + rules: [] + status: pending + - id: au-6.5 + title: Integrated Analysis of Audit Records + levels: + - high + rules: [] + status: pending + - id: au-6.6 + title: Correlation with Physical Monitoring + levels: + - high + rules: [] + status: pending + - id: au-6.7 + title: Permitted Actions + rules: [] + status: pending + - id: au-6.8 + title: Full Text Analysis of Privileged Commands + rules: [] + status: pending + - id: au-6.9 + title: Correlation with Information from Nontechnical Sources + rules: [] + status: pending + - id: au-6.10 + title: Audit Level Adjustment + rules: [] + status: pending + - id: au-7 + title: Audit Record Reduction and Report Generation + levels: + - moderate + rules: [] + status: pending + - id: au-7.1 + title: Automatic Processing + levels: + - moderate + rules: [] + status: pending + - id: au-7.2 + title: Automatic Sort and Search + rules: [] + status: pending + - id: au-8 + title: Time Stamps + levels: + - low + rules: + - auditd_data_retention_max_log_file + - auditd_data_retention_max_log_file_action + - var_auditd_max_log_file=6 + - var_auditd_max_log_file_action=keep_logs + status: automated + - id: au-8.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: au-8.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: au-9 + title: Protection of Audit Information + levels: + - low + rules: + - audit_rules_immutable + - file_groupownership_audit_configuration + - file_ownership_audit_binaries + - file_ownership_audit_configuration + status: automated + - id: au-9.1 + title: Hardware Write-once Media + rules: [] + status: pending + - id: au-9.2 + title: Store on Separate Physical Systems or Components + levels: + - high + rules: [] + status: pending + - id: au-9.3 + title: Cryptographic Protection + levels: + - high + rules: + - aide_check_audit_tools + status: automated + - id: au-9.4 + title: Access by Subset of Privileged Users + levels: + - moderate + rules: + - file_group_ownership_var_log_audit + - file_permissions_var_log_audit + status: automated + - id: au-9.5 + title: Dual Authorization + rules: [] + status: pending + - id: au-9.6 + title: Read-only Access + rules: [] + status: pending + - id: au-9.7 + title: Store on Component with Different Operating System + rules: [] + status: pending + - id: au-10 + title: Non-repudiation + levels: + - high + rules: [] + status: pending + - id: au-10.1 + title: Association of Identities + rules: [] + status: pending + - id: au-10.2 + title: Validate Binding of Information Producer Identity + rules: [] + status: pending + - id: au-10.3 + title: Chain of Custody + rules: [] + status: pending + - id: au-10.4 + title: Validate Binding of Information Reviewer Identity + rules: [] + status: pending + - id: au-10.5 + title: Digital Signatures + rules: [] + status: pending + - id: au-11 + title: Audit Record Retention + levels: + - low + rules: [] + status: pending + - id: au-11.1 + title: Long-term Retrieval Capability + rules: [] + status: pending + - id: au-12 + title: Audit Record Generation + levels: + - low + rules: + - audit_rules_dac_modification_chmod + - audit_rules_dac_modification_chown + - audit_rules_dac_modification_fchmod + - audit_rules_dac_modification_fchmodat + - audit_rules_dac_modification_fchown + - audit_rules_dac_modification_fchownat + - audit_rules_dac_modification_fremovexattr + - audit_rules_dac_modification_fsetxattr + - audit_rules_dac_modification_lchown + - audit_rules_dac_modification_lremovexattr + - audit_rules_dac_modification_lsetxattr + - audit_rules_dac_modification_removexattr + - audit_rules_dac_modification_setxattr + - audit_rules_execution_chcon + - audit_rules_file_deletion_events_rename + - audit_rules_file_deletion_events_renameat + - audit_rules_file_deletion_events_unlink + - audit_rules_file_deletion_events_unlinkat + - audit_rules_kernel_module_loading_create + - audit_rules_kernel_module_loading_delete + - audit_rules_kernel_module_loading_finit + - audit_rules_kernel_module_loading_init + - audit_rules_kernel_module_loading_query + - audit_rules_login_events_faillock + - audit_rules_login_events_lastlog + - audit_rules_media_export + - audit_rules_privileged_commands_kmod + - audit_rules_privileged_commands_usermod + - audit_rules_sysadmin_actions + - audit_rules_unsuccessful_file_modification_creat + - audit_rules_unsuccessful_file_modification_ftruncate + - audit_rules_unsuccessful_file_modification_open + - audit_rules_unsuccessful_file_modification_openat + - audit_rules_unsuccessful_file_modification_truncate + - audit_rules_usergroup_modification_group + - audit_rules_usergroup_modification_gshadow + - audit_rules_usergroup_modification_nsswitch_conf + - audit_rules_usergroup_modification_opasswd + - audit_rules_usergroup_modification_pam_conf + - audit_rules_usergroup_modification_pamd + - audit_rules_usergroup_modification_passwd + - audit_rules_usergroup_modification_shadow + - audit_sudo_log_events + - file_permissions_audit_configuration + - grub2_audit_argument + - service_auditd_enabled + status: automated + - id: au-12.1 + title: System-wide and Time-correlated Audit Trail + levels: + - high + rules: [] + status: pending + - id: au-12.2 + title: Standardized Formats + rules: [] + status: pending + - id: au-12.3 + title: Changes by Authorized Individuals + levels: + - high + rules: [] + status: pending + - id: au-12.4 + title: Query Parameter Audits of Personally Identifiable Information + rules: [] + status: pending + - id: au-13 + title: Monitoring for Information Disclosure + rules: [] + status: pending + - id: au-13.1 + title: Use of Automated Tools + rules: [] + status: pending + - id: au-13.2 + title: Review of Monitored Sites + rules: [] + status: pending + - id: au-13.3 + title: Unauthorized Replication of Information + rules: [] + status: pending + - id: au-14 + title: Session Audit + rules: [] + status: pending + - id: au-14.1 + title: System Start-up + rules: [] + status: pending + - id: au-14.2 + title: Capture and Record Content + rules: [] + status: pending + - id: au-14.3 + title: Remote Viewing and Listening + rules: [] + status: pending + - id: au-15 + title: Alternate Audit Logging Capability + rules: [] + status: pending + - id: au-16 + title: Cross-organizational Audit Logging + rules: [] + status: pending + - id: au-16.1 + title: Identity Preservation + rules: [] + status: pending + - id: au-16.2 + title: Sharing of Audit Information + rules: [] + status: pending + - id: au-16.3 + title: Disassociability + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ca.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ca.yml new file mode 100644 index 000000000000..f0d2ab912085 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ca.yml @@ -0,0 +1,162 @@ +# NIST 800-53 CA Family: Assessment, Authorization, and Monitoring +controls: + - id: ca-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ca-2 + title: Control Assessments + levels: + - low + rules: [] + status: pending + - id: ca-2.1 + title: Independent Assessors + levels: + - moderate + rules: [] + status: pending + - id: ca-2.2 + title: Specialized Assessments + levels: + - high + rules: [] + status: pending + - id: ca-2.3 + title: Leveraging Results from External Organizations + rules: [] + status: pending + - id: ca-3 + title: Information Exchange + levels: + - low + rules: [] + status: pending + - id: ca-3.1 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: ca-3.2 + title: Classified National Security System Connections + rules: [] + status: pending + - id: ca-3.3 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: ca-3.4 + title: Connections to Public Networks + rules: [] + status: pending + - id: ca-3.5 + title: Restrictions on External System Connections + rules: [] + status: pending + - id: ca-3.6 + title: Transfer Authorizations + levels: + - high + rules: [] + status: pending + - id: ca-3.7 + title: Transitive Information Exchanges + rules: [] + status: pending + - id: ca-4 + title: Security Certification + rules: [] + status: pending + - id: ca-5 + title: Plan of Action and Milestones + levels: + - low + rules: [] + status: pending + - id: ca-5.1 + title: Automation Support for Accuracy and Currency + rules: [] + status: pending + - id: ca-6 + title: Authorization + levels: + - low + rules: [] + status: pending + - id: ca-6.1 + title: Joint Authorization — Intra-organization + rules: [] + status: pending + - id: ca-6.2 + title: Joint Authorization — Inter-organization + rules: [] + status: pending + - id: ca-7 + title: Continuous Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.1 + title: Independent Assessment + levels: + - moderate + rules: [] + status: pending + - id: ca-7.2 + title: Types of Assessments + rules: [] + status: pending + - id: ca-7.3 + title: Trend Analyses + rules: [] + status: pending + - id: ca-7.4 + title: Risk Monitoring + levels: + - low + rules: [] + status: pending + - id: ca-7.5 + title: Consistency Analysis + rules: [] + status: pending + - id: ca-7.6 + title: Automation Support for Monitoring + rules: [] + status: pending + - id: ca-8 + title: Penetration Testing + levels: + - high + rules: [] + status: pending + - id: ca-8.1 + title: Independent Penetration Testing Agent or Team + levels: + - high + rules: [] + status: pending + - id: ca-8.2 + title: Red Team Exercises + rules: [] + status: pending + - id: ca-8.3 + title: Facility Penetration Testing + rules: [] + status: pending + - id: ca-9 + title: Internal System Connections + levels: + - low + rules: + - firewalld_loopback_traffic_restricted + - firewalld_loopback_traffic_trusted + - package_firewalld_installed + - package_nftables_installed + status: automated + - id: ca-9.1 + title: Compliance Checks + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/cm.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/cm.yml new file mode 100644 index 000000000000..3ccb12b8cd20 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/cm.yml @@ -0,0 +1,537 @@ +# NIST 800-53 CM Family: Configuration Management +controls: + - id: cm-1 + title: Policy and Procedures + levels: + - low + rules: + - account_password_pam_faillock_password_auth + - account_password_pam_faillock_system_auth + - account_unique_id + - account_unique_name + - accounts_maximum_age_login_defs + - accounts_no_uid_except_zero + - accounts_password_set_max_life_existing + - accounts_root_gid_zero + - accounts_root_path_dirs_no_write + - accounts_user_dot_group_ownership + - accounts_user_dot_user_ownership + - configure_custom_crypto_policy_cis + - disable_host_auth + - file_permission_user_init_files + - gid_passwd_group_same + - group_unique_id + - group_unique_name + - groups_no_zero_gid_except_root + - no_dirs_unowned_by_root + - no_forward_files + - no_netrc_files + - no_rsh_trust_files + - package_cron_installed + - root_path_all_dirs + - root_path_no_dot + - service_crond_enabled + - sshd_disable_empty_passwords + - sshd_disable_gssapi_auth + - sshd_disable_rhosts + - sshd_do_not_permit_user_env + - sshd_enable_pam + - sshd_enable_warning_banner_net + - sshd_set_idle_timeout + - sshd_set_keepalive + - sshd_set_max_sessions + - sshd_set_maxstartups + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv4_tcp_syncookies + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - sshd_idle_timeout_value=5_minutes + - sysctl_net_ipv4_tcp_syncookies_value=enabled + - var_accounts_maximum_age_login_defs=365 + - var_sshd_max_sessions=10 + - var_sshd_set_keepalive=1 + - var_sshd_set_maxstartups=10:30:60 + - var_user_initialization_files_regex=all_dotfiles + status: automated + - id: cm-2 + title: Baseline Configuration + levels: + - low + rules: [] + status: pending + - id: cm-2.1 + title: Reviews and Updates + rules: [] + status: pending + - id: cm-2.2 + title: Automation Support for Accuracy and Currency + levels: + - moderate + rules: [] + status: pending + - id: cm-2.3 + title: Retention of Previous Configurations + levels: + - moderate + rules: [] + status: pending + - id: cm-2.4 + title: Unauthorized Software + rules: [] + status: pending + - id: cm-2.5 + title: Authorized Software + rules: [] + status: pending + - id: cm-2.6 + title: Development and Test Environments + rules: [] + status: pending + - id: cm-2.7 + title: Configure Systems and Components for High-risk Areas + levels: + - moderate + rules: [] + status: pending + - id: cm-3 + title: Configuration Change Control + levels: + - moderate + rules: [] + status: pending + - id: cm-3.1 + title: Automated Documentation, Notification, and Prohibition of Changes + levels: + - high + rules: [] + status: pending + - id: cm-3.2 + title: Testing, Validation, and Documentation of Changes + levels: + - moderate + rules: [] + status: pending + - id: cm-3.3 + title: Automated Change Implementation + rules: [] + status: pending + - id: cm-3.4 + title: Security and Privacy Representatives + levels: + - moderate + rules: [] + status: pending + - id: cm-3.5 + title: Automated Security Response + rules: [] + status: pending + - id: cm-3.6 + title: Cryptography Management + levels: + - high + rules: [] + status: pending + - id: cm-3.7 + title: Review System Changes + rules: [] + status: pending + - id: cm-3.8 + title: Prevent or Restrict Configuration Changes + rules: [] + status: pending + - id: cm-4 + title: Impact Analyses + levels: + - low + rules: [] + status: pending + - id: cm-4.1 + title: Separate Test Environments + levels: + - high + rules: [] + status: pending + - id: cm-4.2 + title: Verification of Controls + levels: + - moderate + rules: [] + status: pending + - id: cm-5 + title: Access Restrictions for Change + levels: + - low + rules: [] + status: pending + - id: cm-5.1 + title: Automated Access Enforcement and Audit Records + levels: + - high + rules: [] + status: pending + - id: cm-5.2 + title: Review System Changes + rules: [] + status: pending + - id: cm-5.3 + title: Signed Components + rules: [] + status: pending + - id: cm-5.4 + title: Dual Authorization + rules: [] + status: pending + - id: cm-5.5 + title: Privilege Limitation for Production and Operation + rules: [] + status: pending + - id: cm-5.6 + title: Limit Library Privileges + rules: [] + status: pending + - id: cm-5.7 + title: Automatic Implementation of Security Safeguards + rules: [] + status: pending + - id: cm-6 + title: Configuration Settings + levels: + - low + rules: + - accounts_umask_etc_bashrc + - accounts_umask_etc_login_defs + - accounts_umask_etc_profile + - accounts_user_interactive_home_directory_exists + - audit_rules_media_export + - banner_etc_issue_cis + - banner_etc_issue_net_cis + - banner_etc_motd_cis + - coredump_disable_backtraces + - coredump_disable_storage + - dconf_db_up_to_date + - dconf_gnome_disable_user_list + - disable_host_auth + - enable_authselect + - file_groupowner_grub2_cfg + - file_groupowner_user_cfg + - file_groupownership_sshd_private_key + - file_groupownership_sshd_pub_key + - file_owner_grub2_cfg + - file_owner_user_cfg + - file_ownership_home_directories + - file_ownership_sshd_private_key + - file_ownership_sshd_pub_key + - file_permissions_grub2_cfg + - file_permissions_home_directories + - file_permissions_sshd_private_key + - file_permissions_sshd_pub_key + - file_permissions_user_cfg + - no_empty_passwords + - no_empty_passwords_etc_shadow + - package_pam_pwquality_installed + - package_rsync_removed + - package_samba_removed + - package_squid_removed + - partition_for_tmp + - partition_for_var_log + - service_nfs_disabled + - service_rpcbind_disabled + - sshd_disable_gssapi_auth + - sshd_set_login_grace_time + - sysctl_kernel_randomize_va_space + - sysctl_kernel_yama_ptrace_scope + - sysctl_net_ipv4_conf_all_accept_redirects + - sysctl_net_ipv4_conf_all_accept_source_route + - sysctl_net_ipv4_conf_all_log_martians + - sysctl_net_ipv4_conf_all_rp_filter + - sysctl_net_ipv4_conf_all_secure_redirects + - sysctl_net_ipv4_conf_all_send_redirects + - sysctl_net_ipv4_conf_default_accept_redirects + - sysctl_net_ipv4_conf_default_accept_source_route + - sysctl_net_ipv4_conf_default_log_martians + - sysctl_net_ipv4_conf_default_rp_filter + - sysctl_net_ipv4_conf_default_secure_redirects + - sysctl_net_ipv4_conf_default_send_redirects + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses + - sysctl_net_ipv4_ip_forward + - sysctl_net_ipv6_conf_all_accept_ra + - sysctl_net_ipv6_conf_all_accept_redirects + - sysctl_net_ipv6_conf_all_accept_source_route + - sysctl_net_ipv6_conf_all_forwarding + - sysctl_net_ipv6_conf_default_accept_ra + - sysctl_net_ipv6_conf_default_accept_redirects + - sysctl_net_ipv6_conf_default_accept_source_route + - cis_banner_text=cis + - dconf_login_banner_contents=cis_default + - dconf_login_banner_text=cis_banners + - sysctl_net_ipv4_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_all_log_martians_value=enabled + - sysctl_net_ipv4_conf_all_rp_filter_value=enabled + - sysctl_net_ipv4_conf_all_secure_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv4_conf_default_accept_source_route_value=disabled + - sysctl_net_ipv4_conf_default_log_martians_value=enabled + - sysctl_net_ipv4_conf_default_rp_filter_value=enabled + - sysctl_net_ipv4_conf_default_secure_redirects_value=disabled + - sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled + - sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled + - sysctl_net_ipv6_conf_all_accept_ra_value=disabled + - sysctl_net_ipv6_conf_all_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_all_accept_source_route_value=disabled + - sysctl_net_ipv6_conf_all_forwarding_value=disabled + - sysctl_net_ipv6_conf_default_accept_ra_value=disabled + - sysctl_net_ipv6_conf_default_accept_redirects_value=disabled + - sysctl_net_ipv6_conf_default_accept_source_route_value=disabled + - var_accounts_user_umask=027 + - var_authselect_profile=sssd + - var_sshd_set_login_grace_time=60 + status: automated + - id: cm-6.1 + title: Automated Management, Application, and Verification + levels: + - high + rules: [] + status: pending + - id: cm-6.2 + title: Respond to Unauthorized Changes + levels: + - high + rules: [] + status: pending + - id: cm-6.3 + title: Unauthorized Change Detection + rules: [] + status: pending + - id: cm-6.4 + title: Conformance Demonstration + rules: [] + status: pending + - id: cm-7 + title: Least Functionality + levels: + - low + rules: + - dconf_gnome_disable_autorun + - file_ownership_var_log_audit_stig + - gnome_gdm_disable_xdmcp + - has_nonlocal_mta + - kernel_module_cramfs_disabled + - kernel_module_dccp_disabled + - kernel_module_freevxfs_disabled + - kernel_module_hfs_disabled + - kernel_module_hfsplus_disabled + - kernel_module_jffs2_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_squashfs_disabled + - kernel_module_tipc_disabled + - kernel_module_udf_disabled + - mount_option_dev_shm_nodev + - mount_option_dev_shm_noexec + - mount_option_dev_shm_nosuid + - mount_option_tmp_nodev + - mount_option_tmp_noexec + - mount_option_tmp_nosuid + - package_bind_removed + - package_cyrus-imapd_removed + - package_dhcp_removed + - package_dovecot_removed + - package_ftp_removed + - package_gdm_removed + - package_httpd_removed + - package_net-snmp_removed + - package_nginx_removed + - package_openldap-clients_removed + - package_postfix_installed + - package_telnet-server_removed + - package_telnet_removed + - package_tftp-server_removed + - package_tftp_removed + - package_vsftpd_removed + - partition_for_dev_shm + - partition_for_home + - partition_for_tmp + - partition_for_var + - partition_for_var_log + - partition_for_var_log_audit + - partition_for_var_tmp + - postfix_network_listening_disabled + - service_bluetooth_disabled + - service_cups_disabled + - service_dnsmasq_disabled + - service_nftables_disabled + - sshd_disable_forwarding + - wireless_disable_interfaces + - var_postfix_inet_interfaces=loopback-only + status: automated + - id: cm-7.1 + title: Periodic Review + levels: + - moderate + rules: [] + status: pending + - id: cm-7.2 + title: Prevent Program Execution + levels: + - moderate + rules: [] + status: pending + - id: cm-7.3 + title: Registration Compliance + rules: [] + status: pending + - id: cm-7.4 + title: Unauthorized Software — Deny-by-exception + rules: [] + status: pending + - id: cm-7.5 + title: Authorized Software — Allow-by-exception + levels: + - moderate + rules: [] + status: pending + - id: cm-7.6 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: cm-7.7 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: cm-7.8 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: cm-7.9 + title: Prohibiting The Use of Unauthorized Hardware + rules: [] + status: pending + - id: cm-8 + title: System Component Inventory + levels: + - low + rules: [] + status: pending + - id: cm-8.1 + title: Updates During Installation and Removal + levels: + - moderate + rules: [] + status: pending + - id: cm-8.2 + title: Automated Maintenance + levels: + - high + rules: [] + status: pending + - id: cm-8.3 + title: Automated Unauthorized Component Detection + levels: + - moderate + rules: [] + status: pending + - id: cm-8.4 + title: Accountability Information + levels: + - high + rules: [] + status: pending + - id: cm-8.5 + title: No Duplicate Accounting of Components + rules: [] + status: pending + - id: cm-8.6 + title: Assessed Configurations and Approved Deviations + rules: [] + status: pending + - id: cm-8.7 + title: Centralized Repository + rules: [] + status: pending + - id: cm-8.8 + title: Automated Location Tracking + rules: [] + status: pending + - id: cm-8.9 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: cm-9 + title: Configuration Management Plan + levels: + - moderate + rules: [] + status: pending + - id: cm-9.1 + title: Assignment of Responsibility + rules: [] + status: pending + - id: cm-10 + title: Software Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: cm-10.1 + title: Open-source Software + rules: [] + status: pending + - id: cm-11 + title: User-installed Software + levels: + - low + rules: + - package_xorg-x11-server-common_removed + - xwindows_runlevel_target + status: automated + - id: cm-11.1 + title: Alerts for Unauthorized Installations + rules: [] + status: pending + - id: cm-11.2 + title: Software Installation with Privileged Status + rules: [] + status: pending + - id: cm-11.3 + title: Automated Enforcement and Monitoring + rules: [] + status: pending + - id: cm-12 + title: Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-12.1 + title: Automated Tools to Support Information Location + levels: + - moderate + rules: [] + status: pending + - id: cm-13 + title: Data Action Mapping + rules: [] + status: pending + - id: cm-14 + title: Signed Components + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/cp.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/cp.yml new file mode 100644 index 000000000000..53d97fb34990 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/cp.yml @@ -0,0 +1,296 @@ +# NIST 800-53 CP Family: Contingency Planning +controls: + - id: cp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: cp-2 + title: Contingency Plan + levels: + - low + rules: [] + status: pending + - id: cp-2.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-2.2 + title: Capacity Planning + levels: + - high + rules: [] + status: pending + - id: cp-2.3 + title: Resume Mission and Business Functions + levels: + - moderate + rules: [] + status: pending + - id: cp-2.4 + title: Resume All Mission and Business Functions + rules: [] + status: pending + - id: cp-2.5 + title: Continue Mission and Business Functions + levels: + - high + rules: [] + status: pending + - id: cp-2.6 + title: Alternate Processing and Storage Sites + rules: [] + status: pending + - id: cp-2.7 + title: Coordinate with External Service Providers + rules: [] + status: pending + - id: cp-2.8 + title: Identify Critical Assets + levels: + - moderate + rules: [] + status: pending + - id: cp-3 + title: Contingency Training + levels: + - low + rules: [] + status: pending + - id: cp-3.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: cp-3.2 + title: Mechanisms Used in Training Environments + rules: [] + status: pending + - id: cp-4 + title: Contingency Plan Testing + levels: + - low + rules: [] + status: pending + - id: cp-4.1 + title: Coordinate with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: cp-4.2 + title: Alternate Processing Site + levels: + - high + rules: [] + status: pending + - id: cp-4.3 + title: Automated Testing + rules: [] + status: pending + - id: cp-4.4 + title: Full Recovery and Reconstitution + rules: [] + status: pending + - id: cp-4.5 + title: Self-challenge + rules: [] + status: pending + - id: cp-5 + title: Contingency Plan Update + rules: [] + status: pending + - id: cp-6 + title: Alternate Storage Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-6.2 + title: Recovery Time and Recovery Point Objectives + levels: + - high + rules: [] + status: pending + - id: cp-6.3 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7 + title: Alternate Processing Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.1 + title: Separation from Primary Site + levels: + - moderate + rules: [] + status: pending + - id: cp-7.2 + title: Accessibility + levels: + - moderate + rules: [] + status: pending + - id: cp-7.3 + title: Priority of Service + levels: + - moderate + rules: [] + status: pending + - id: cp-7.4 + title: Preparation for Use + levels: + - high + rules: [] + status: pending + - id: cp-7.5 + title: Equivalent Information Security Safeguards + rules: [] + status: pending + - id: cp-7.6 + title: Inability to Return to Primary Site + rules: [] + status: pending + - id: cp-8 + title: Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: cp-8.1 + title: Priority of Service Provisions + levels: + - moderate + rules: [] + status: pending + - id: cp-8.2 + title: Single Points of Failure + levels: + - moderate + rules: [] + status: pending + - id: cp-8.3 + title: Separation of Primary and Alternate Providers + levels: + - high + rules: [] + status: pending + - id: cp-8.4 + title: Provider Contingency Plan + levels: + - high + rules: [] + status: pending + - id: cp-8.5 + title: Alternate Telecommunication Service Testing + rules: [] + status: pending + - id: cp-9 + title: System Backup + levels: + - low + rules: [] + status: pending + - id: cp-9.1 + title: Testing for Reliability and Integrity + levels: + - moderate + rules: [] + status: pending + - id: cp-9.2 + title: Test Restoration Using Sampling + levels: + - high + rules: [] + status: pending + - id: cp-9.3 + title: Separate Storage for Critical Information + levels: + - high + rules: [] + status: pending + - id: cp-9.4 + title: Protection from Unauthorized Modification + rules: [] + status: pending + - id: cp-9.5 + title: Transfer to Alternate Storage Site + levels: + - high + rules: [] + status: pending + - id: cp-9.6 + title: Redundant Secondary System + rules: [] + status: pending + - id: cp-9.7 + title: Dual Authorization for Deletion or Destruction + rules: [] + status: pending + - id: cp-9.8 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: cp-10 + title: System Recovery and Reconstitution + levels: + - low + rules: [] + status: pending + - id: cp-10.1 + title: Contingency Plan Testing + rules: [] + status: pending + - id: cp-10.2 + title: Transaction Recovery + levels: + - moderate + rules: [] + status: pending + - id: cp-10.3 + title: Compensating Security Controls + rules: [] + status: pending + - id: cp-10.4 + title: Restore Within Time Period + levels: + - high + rules: [] + status: pending + - id: cp-10.5 + title: Failover Capability + rules: [] + status: pending + - id: cp-10.6 + title: Component Protection + rules: [] + status: pending + - id: cp-11 + title: Alternate Communications Protocols + rules: [] + status: pending + - id: cp-12 + title: Safe Mode + rules: [] + status: pending + - id: cp-13 + title: Alternative Security Mechanisms + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ia.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ia.yml new file mode 100644 index 000000000000..79e8a0420c12 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ia.yml @@ -0,0 +1,395 @@ +# NIST 800-53 IA Family: Identification and Authentication +controls: + - id: ia-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ia-2 + title: Identification and Authentication (Organizational Users) + levels: + - low + rules: + - account_unique_id + status: automated + - id: ia-2.1 + title: Multi-factor Authentication to Privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.2 + title: Multi-factor Authentication to Non-privileged Accounts + levels: + - low + rules: [] + status: pending + - id: ia-2.3 + title: Local Access to Privileged Accounts + rules: [] + status: pending + - id: ia-2.4 + title: Local Access to Non-privileged Accounts + rules: [] + status: pending + - id: ia-2.5 + title: Individual Authentication with Group Authentication + levels: + - high + rules: [] + status: pending + - id: ia-2.6 + title: Access to Accounts —separate Device + rules: [] + status: pending + - id: ia-2.7 + title: Network Access to Non-privileged Accounts — Separate Device + rules: [] + status: pending + - id: ia-2.8 + title: Access to Accounts — Replay Resistant + levels: + - low + rules: [] + status: pending + - id: ia-2.9 + title: Network Access to Non-privileged Accounts — Replay Resistant + rules: [] + status: pending + - id: ia-2.10 + title: Single Sign-on + rules: [] + status: pending + - id: ia-2.11 + title: Remote Access — Separate Device + rules: [] + status: pending + - id: ia-2.12 + title: Acceptance of PIV Credentials + levels: + - low + rules: [] + status: pending + - id: ia-2.13 + title: Out-of-band Authentication + rules: [] + status: pending + - id: ia-3 + title: Device Identification and Authentication + levels: + - moderate + rules: + - dconf_gnome_disable_automount + - dconf_gnome_disable_automount_open + - kernel_module_usb-storage_disabled + status: automated + - id: ia-3.1 + title: Cryptographic Bidirectional Authentication + rules: [] + status: pending + - id: ia-3.2 + title: Cryptographic Bidirectional Network Authentication + rules: [] + status: pending + - id: ia-3.3 + title: Dynamic Address Allocation + rules: [] + status: pending + - id: ia-3.4 + title: Device Attestation + rules: [] + status: pending + - id: ia-4 + title: Identifier Management + levels: + - low + rules: + - account_disable_post_pw_expiration + - accounts_set_post_pw_existing + - var_account_disable_post_pw_expiration=45 + status: automated + - id: ia-4.1 + title: Prohibit Account Identifiers as Public Identifiers + rules: [] + status: pending + - id: ia-4.2 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-4.3 + title: Multiple Forms of Certification + rules: [] + status: pending + - id: ia-4.4 + title: Identify User Status + levels: + - moderate + rules: [] + status: pending + - id: ia-4.5 + title: Dynamic Management + rules: [] + status: pending + - id: ia-4.6 + title: Cross-organization Management + rules: [] + status: pending + - id: ia-4.7 + title: In-person Registration + rules: [] + status: pending + - id: ia-4.8 + title: Pairwise Pseudonymous Identifiers + rules: [] + status: pending + - id: ia-4.9 + title: Attribute Maintenance and Protection + rules: [] + status: pending + - id: ia-5 + title: Authenticator Management + levels: + - low + rules: + - accounts_minimum_age_login_defs + - accounts_password_all_shadowed + - accounts_password_last_change_is_in_past + - accounts_password_pam_dictcheck + - accounts_password_pam_difok + - accounts_password_pam_enforce_root + - accounts_password_pam_maxrepeat + - accounts_password_pam_maxsequence + - accounts_password_pam_minclass + - accounts_password_pam_minlen + - accounts_password_pam_modules_in_authselect_profile + - accounts_password_pam_pwhistory_enforce_for_root + - accounts_password_set_min_life_existing + - accounts_password_set_warn_age_existing + - accounts_password_warn_age_login_defs + - ensure_root_password_configured + - no_empty_passwords_etc_shadow + - set_password_hashing_algorithm_libuserconf + - set_password_hashing_algorithm_logindefs + - set_password_hashing_algorithm_passwordauth + - set_password_hashing_algorithm_systemauth + - var_accounts_minimum_age_login_defs=1 + - var_accounts_password_warn_age_login_defs=7 + - var_password_hashing_algorithm=SHA512 + - var_password_hashing_algorithm_pam=sha512 + - var_password_pam_dictcheck=1 + - var_password_pam_difok=2 + - var_password_pam_maxrepeat=3 + - var_password_pam_maxsequence=3 + - var_password_pam_minclass=4 + - var_password_pam_minlen=14 + status: automated + - id: ia-5.1 + title: Password-based Authentication + levels: + - low + rules: + - accounts_password_pam_pwhistory_remember_password_auth + - accounts_password_pam_pwhistory_remember_system_auth + - accounts_password_pam_unix_no_remember + - var_password_pam_remember=24 + - var_password_pam_remember_control_flag=requisite_or_required + status: automated + - id: ia-5.2 + title: Public Key-based Authentication + levels: + - moderate + rules: [] + status: pending + - id: ia-5.3 + title: In-person or Trusted External Party Registration + rules: [] + status: pending + - id: ia-5.4 + title: Automated Support for Password Strength Determination + rules: [] + status: pending + - id: ia-5.5 + title: Change Authenticators Prior to Delivery + rules: [] + status: pending + - id: ia-5.6 + title: Protection of Authenticators + levels: + - moderate + rules: [] + status: pending + - id: ia-5.7 + title: No Embedded Unencrypted Static Authenticators + rules: [] + status: pending + - id: ia-5.8 + title: Multiple System Accounts + rules: [] + status: pending + - id: ia-5.9 + title: Federated Credential Management + rules: [] + status: pending + - id: ia-5.10 + title: Dynamic Credential Binding + rules: [] + status: pending + - id: ia-5.11 + title: Hardware Token-based Authentication + rules: [] + status: pending + - id: ia-5.12 + title: Biometric Authentication Performance + rules: [] + status: pending + - id: ia-5.13 + title: Expiration of Cached Authenticators + rules: [] + status: pending + - id: ia-5.14 + title: Managing Content of PKI Trust Stores + rules: [] + status: pending + - id: ia-5.15 + title: GSA-approved Products and Services + rules: [] + status: pending + - id: ia-5.16 + title: In-person or Trusted External Party Authenticator Issuance + rules: [] + status: pending + - id: ia-5.17 + title: Presentation Attack Detection for Biometric Authenticators + rules: [] + status: pending + - id: ia-5.18 + title: Password Managers + rules: [] + status: pending + - id: ia-6 + title: Authentication Feedback + levels: + - low + rules: [] + status: pending + - id: ia-7 + title: Cryptographic Module Authentication + levels: + - low + rules: [] + status: pending + - id: ia-8 + title: Identification and Authentication (Non-organizational Users) + levels: + - low + rules: [] + status: pending + - id: ia-8.1 + title: Acceptance of PIV Credentials from Other Agencies + levels: + - low + rules: [] + status: pending + - id: ia-8.2 + title: Acceptance of External Authenticators + levels: + - low + rules: [] + status: pending + - id: ia-8.3 + title: Use of FICAM-approved Products + rules: [] + status: pending + - id: ia-8.4 + title: Use of Defined Profiles + levels: + - low + rules: [] + status: pending + - id: ia-8.5 + title: Acceptance of PIV-I Credentials + rules: [] + status: pending + - id: ia-8.6 + title: Disassociability + rules: [] + status: pending + - id: ia-9 + title: Service Identification and Authentication + rules: [] + status: pending + - id: ia-9.1 + title: Information Exchange + rules: [] + status: pending + - id: ia-9.2 + title: Transmission of Decisions + rules: [] + status: pending + - id: ia-10 + title: Adaptive Authentication + rules: [] + status: pending + - id: ia-11 + title: Re-authentication + levels: + - low + rules: + - sudo_require_reauthentication + - var_sudo_timestamp_timeout=15_minutes + status: automated + - id: ia-12 + title: Identity Proofing + levels: + - moderate + rules: [] + status: pending + - id: ia-12.1 + title: Supervisor Authorization + rules: [] + status: pending + - id: ia-12.2 + title: Identity Evidence + levels: + - moderate + rules: [] + status: pending + - id: ia-12.3 + title: Identity Evidence Validation and Verification + levels: + - moderate + rules: [] + status: pending + - id: ia-12.4 + title: In-person Validation and Verification + levels: + - high + rules: [] + status: pending + - id: ia-12.5 + title: Address Confirmation + levels: + - moderate + rules: [] + status: pending + - id: ia-12.6 + title: Accept Externally-proofed Identities + rules: [] + status: pending + - id: ia-13 + title: Identity Providers and Authorization Servers + rules: [] + status: pending + - id: ia-13.1 + title: Protection of Cryptographic Keys + rules: [] + status: pending + - id: ia-13.2 + title: Verification of Identity Assertions and Access Tokens + rules: [] + status: pending + - id: ia-13.3 + title: Token Management + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ir.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ir.yml new file mode 100644 index 000000000000..2d443099c957 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ir.yml @@ -0,0 +1,206 @@ +# NIST 800-53 IR Family: Incident Response +controls: + - id: ir-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ir-2 + title: Incident Response Training + levels: + - low + rules: [] + status: pending + - id: ir-2.1 + title: Simulated Events + levels: + - high + rules: [] + status: pending + - id: ir-2.2 + title: Automated Training Environments + levels: + - high + rules: [] + status: pending + - id: ir-2.3 + title: Breach + rules: [] + status: pending + - id: ir-3 + title: Incident Response Testing + levels: + - moderate + rules: [] + status: pending + - id: ir-3.1 + title: Automated Testing + rules: [] + status: pending + - id: ir-3.2 + title: Coordination with Related Plans + levels: + - moderate + rules: [] + status: pending + - id: ir-3.3 + title: Continuous Improvement + rules: [] + status: pending + - id: ir-4 + title: Incident Handling + levels: + - low + rules: [] + status: pending + - id: ir-4.1 + title: Automated Incident Handling Processes + levels: + - moderate + rules: [] + status: pending + - id: ir-4.2 + title: Dynamic Reconfiguration + rules: [] + status: pending + - id: ir-4.3 + title: Continuity of Operations + rules: [] + status: pending + - id: ir-4.4 + title: Information Correlation + levels: + - high + rules: [] + status: pending + - id: ir-4.5 + title: Automatic Disabling of System + rules: [] + status: pending + - id: ir-4.6 + title: Insider Threats + rules: [] + status: pending + - id: ir-4.7 + title: Insider Threats — Intra-organization Coordination + rules: [] + status: pending + - id: ir-4.8 + title: Correlation with External Organizations + rules: [] + status: pending + - id: ir-4.9 + title: Dynamic Response Capability + rules: [] + status: pending + - id: ir-4.10 + title: Supply Chain Coordination + rules: [] + status: pending + - id: ir-4.11 + title: Integrated Incident Response Team + levels: + - high + rules: [] + status: pending + - id: ir-4.12 + title: Malicious Code and Forensic Analysis + rules: [] + status: pending + - id: ir-4.13 + title: Behavior Analysis + rules: [] + status: pending + - id: ir-4.14 + title: Security Operations Center + rules: [] + status: pending + - id: ir-4.15 + title: Public Relations and Reputation Repair + rules: [] + status: pending + - id: ir-5 + title: Incident Monitoring + levels: + - low + rules: [] + status: pending + - id: ir-5.1 + title: Automated Tracking, Data Collection, and Analysis + levels: + - high + rules: [] + status: pending + - id: ir-6 + title: Incident Reporting + levels: + - low + rules: [] + status: pending + - id: ir-6.1 + title: Automated Reporting + levels: + - moderate + rules: [] + status: pending + - id: ir-6.2 + title: Vulnerabilities Related to Incidents + rules: [] + status: pending + - id: ir-6.3 + title: Supply Chain Coordination + levels: + - moderate + rules: [] + status: pending + - id: ir-7 + title: Incident Response Assistance + levels: + - low + rules: [] + status: pending + - id: ir-7.1 + title: Automation Support for Availability of Information and Support + levels: + - moderate + rules: [] + status: pending + - id: ir-7.2 + title: Coordination with External Providers + rules: [] + status: pending + - id: ir-8 + title: Incident Response Plan + levels: + - low + rules: [] + status: pending + - id: ir-8.1 + title: Breaches + rules: [] + status: pending + - id: ir-9 + title: Information Spillage Response + rules: [] + status: pending + - id: ir-9.1 + title: Responsible Personnel + rules: [] + status: pending + - id: ir-9.2 + title: Training + rules: [] + status: pending + - id: ir-9.3 + title: Post-spill Operations + rules: [] + status: pending + - id: ir-9.4 + title: Exposure to Unauthorized Personnel + rules: [] + status: pending + - id: ir-10 + title: Integrated Information Security Analysis Team + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ma.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ma.yml new file mode 100644 index 000000000000..77bd02932613 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ma.yml @@ -0,0 +1,146 @@ +# NIST 800-53 MA Family: Maintenance +controls: + - id: ma-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ma-2 + title: Controlled Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-2.1 + title: Record Content + rules: [] + status: pending + - id: ma-2.2 + title: Automated Maintenance Activities + levels: + - high + rules: [] + status: pending + - id: ma-3 + title: Maintenance Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.1 + title: Inspect Tools + levels: + - moderate + rules: [] + status: pending + - id: ma-3.2 + title: Inspect Media + levels: + - moderate + rules: [] + status: pending + - id: ma-3.3 + title: Prevent Unauthorized Removal + levels: + - moderate + rules: [] + status: pending + - id: ma-3.4 + title: Restricted Tool Use + rules: [] + status: pending + - id: ma-3.5 + title: Execution with Privilege + rules: [] + status: pending + - id: ma-3.6 + title: Software Updates and Patches + rules: [] + status: pending + - id: ma-4 + title: Nonlocal Maintenance + levels: + - low + rules: [] + status: pending + - id: ma-4.1 + title: Logging and Review + rules: [] + status: pending + - id: ma-4.2 + title: Document Nonlocal Maintenance + rules: [] + status: pending + - id: ma-4.3 + title: Comparable Security and Sanitization + levels: + - high + rules: [] + status: pending + - id: ma-4.4 + title: Authentication and Separation of Maintenance Sessions + rules: [] + status: pending + - id: ma-4.5 + title: Approvals and Notifications + rules: [] + status: pending + - id: ma-4.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: ma-4.7 + title: Disconnect Verification + rules: [] + status: pending + - id: ma-5 + title: Maintenance Personnel + levels: + - low + rules: [] + status: pending + - id: ma-5.1 + title: Individuals Without Appropriate Access + levels: + - high + rules: [] + status: pending + - id: ma-5.2 + title: Security Clearances for Classified Systems + rules: [] + status: pending + - id: ma-5.3 + title: Citizenship Requirements for Classified Systems + rules: [] + status: pending + - id: ma-5.4 + title: Foreign Nationals + rules: [] + status: pending + - id: ma-5.5 + title: Non-system Maintenance + rules: [] + status: pending + - id: ma-6 + title: Timely Maintenance + levels: + - moderate + rules: [] + status: pending + - id: ma-6.1 + title: Preventive Maintenance + rules: [] + status: pending + - id: ma-6.2 + title: Predictive Maintenance + rules: [] + status: pending + - id: ma-6.3 + title: Automated Support for Predictive Maintenance + rules: [] + status: pending + - id: ma-7 + title: Field Maintenance + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/mp.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/mp.yml new file mode 100644 index 000000000000..6c8e8f46e4e4 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/mp.yml @@ -0,0 +1,142 @@ +# NIST 800-53 MP Family: Media Protection +controls: + - id: mp-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: mp-2 + title: Media Access + levels: + - low + rules: [] + status: pending + - id: mp-2.1 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-2.2 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-3 + title: Media Marking + levels: + - moderate + rules: [] + status: pending + - id: mp-4 + title: Media Storage + levels: + - moderate + rules: [] + status: pending + - id: mp-4.1 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-4.2 + title: Automated Restricted Access + rules: [] + status: pending + - id: mp-5 + title: Media Transport + levels: + - moderate + rules: [] + status: pending + - id: mp-5.1 + title: Protection Outside of Controlled Areas + rules: [] + status: pending + - id: mp-5.2 + title: Documentation of Activities + rules: [] + status: pending + - id: mp-5.3 + title: Custodians + rules: [] + status: pending + - id: mp-5.4 + title: Cryptographic Protection + rules: [] + status: pending + - id: mp-6 + title: Media Sanitization + levels: + - low + rules: [] + status: pending + - id: mp-6.1 + title: Review, Approve, Track, Document, and Verify + levels: + - high + rules: [] + status: pending + - id: mp-6.2 + title: Equipment Testing + levels: + - high + rules: [] + status: pending + - id: mp-6.3 + title: Nondestructive Techniques + levels: + - high + rules: [] + status: pending + - id: mp-6.4 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-6.5 + title: Classified Information + rules: [] + status: pending + - id: mp-6.6 + title: Media Destruction + rules: [] + status: pending + - id: mp-6.7 + title: Dual Authorization + rules: [] + status: pending + - id: mp-6.8 + title: Remote Purging or Wiping of Information + rules: [] + status: pending + - id: mp-7 + title: Media Use + levels: + - low + rules: [] + status: pending + - id: mp-7.1 + title: Prohibit Use Without Owner + rules: [] + status: pending + - id: mp-7.2 + title: Prohibit Use of Sanitization-resistant Media + rules: [] + status: pending + - id: mp-8 + title: Media Downgrading + rules: [] + status: pending + - id: mp-8.1 + title: Documentation of Process + rules: [] + status: pending + - id: mp-8.2 + title: Equipment Testing + rules: [] + status: pending + - id: mp-8.3 + title: Controlled Unclassified Information + rules: [] + status: pending + - id: mp-8.4 + title: Classified Information + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/pe.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/pe.yml new file mode 100644 index 000000000000..b6728c7d49d5 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/pe.yml @@ -0,0 +1,288 @@ +# NIST 800-53 PE Family: Physical and Environmental Protection +controls: + - id: pe-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pe-2 + title: Physical Access Authorizations + levels: + - low + rules: [] + status: pending + - id: pe-2.1 + title: Access by Position or Role + rules: [] + status: pending + - id: pe-2.2 + title: Two Forms of Identification + rules: [] + status: pending + - id: pe-2.3 + title: Restrict Unescorted Access + rules: [] + status: pending + - id: pe-3 + title: Physical Access Control + levels: + - low + rules: [] + status: pending + - id: pe-3.1 + title: System Access + levels: + - high + rules: [] + status: pending + - id: pe-3.2 + title: Facility and Systems + rules: [] + status: pending + - id: pe-3.3 + title: Continuous Guards + rules: [] + status: pending + - id: pe-3.4 + title: Lockable Casings + rules: [] + status: pending + - id: pe-3.5 + title: Tamper Protection + rules: [] + status: pending + - id: pe-3.6 + title: Facility Penetration Testing + rules: [] + status: pending + - id: pe-3.7 + title: Physical Barriers + rules: [] + status: pending + - id: pe-3.8 + title: Access Control Vestibules + rules: [] + status: pending + - id: pe-4 + title: Access Control for Transmission + levels: + - moderate + rules: [] + status: pending + - id: pe-5 + title: Access Control for Output Devices + levels: + - moderate + rules: [] + status: pending + - id: pe-5.1 + title: Access to Output by Authorized Individuals + rules: [] + status: pending + - id: pe-5.2 + title: Link to Individual Identity + rules: [] + status: pending + - id: pe-5.3 + title: Marking Output Devices + rules: [] + status: pending + - id: pe-6 + title: Monitoring Physical Access + levels: + - low + rules: [] + status: pending + - id: pe-6.1 + title: Intrusion Alarms and Surveillance Equipment + levels: + - moderate + rules: [] + status: pending + - id: pe-6.2 + title: Automated Intrusion Recognition and Responses + rules: [] + status: pending + - id: pe-6.3 + title: Video Surveillance + rules: [] + status: pending + - id: pe-6.4 + title: Monitoring Physical Access to Systems + levels: + - high + rules: [] + status: pending + - id: pe-7 + title: Visitor Control + rules: [] + status: pending + - id: pe-8 + title: Visitor Access Records + levels: + - low + rules: [] + status: pending + - id: pe-8.1 + title: Automated Records Maintenance and Review + levels: + - high + rules: [] + status: pending + - id: pe-8.2 + title: Physical Access Records + rules: [] + status: pending + - id: pe-8.3 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: pe-9 + title: Power Equipment and Cabling + levels: + - moderate + rules: [] + status: pending + - id: pe-9.1 + title: Redundant Cabling + rules: [] + status: pending + - id: pe-9.2 + title: Automatic Voltage Controls + rules: [] + status: pending + - id: pe-10 + title: Emergency Shutoff + levels: + - moderate + rules: [] + status: pending + - id: pe-10.1 + title: Accidental and Unauthorized Activation + rules: [] + status: pending + - id: pe-11 + title: Emergency Power + levels: + - moderate + rules: [] + status: pending + - id: pe-11.1 + title: Alternate Power Supply — Minimal Operational Capability + levels: + - high + rules: [] + status: pending + - id: pe-11.2 + title: Alternate Power Supply — Self-contained + rules: [] + status: pending + - id: pe-12 + title: Emergency Lighting + levels: + - low + rules: [] + status: pending + - id: pe-12.1 + title: Essential Mission and Business Functions + rules: [] + status: pending + - id: pe-13 + title: Fire Protection + levels: + - low + rules: [] + status: pending + - id: pe-13.1 + title: Detection Systems — Automatic Activation and Notification + levels: + - moderate + rules: [] + status: pending + - id: pe-13.2 + title: Suppression Systems — Automatic Activation and Notification + levels: + - high + rules: [] + status: pending + - id: pe-13.3 + title: Automatic Fire Suppression + rules: [] + status: pending + - id: pe-13.4 + title: Inspections + rules: [] + status: pending + - id: pe-14 + title: Environmental Controls + levels: + - low + rules: [] + status: pending + - id: pe-14.1 + title: Automatic Controls + rules: [] + status: pending + - id: pe-14.2 + title: Monitoring with Alarms and Notifications + rules: [] + status: pending + - id: pe-15 + title: Water Damage Protection + levels: + - low + rules: [] + status: pending + - id: pe-15.1 + title: Automation Support + levels: + - high + rules: [] + status: pending + - id: pe-16 + title: Delivery and Removal + levels: + - low + rules: [] + status: pending + - id: pe-17 + title: Alternate Work Site + levels: + - moderate + rules: [] + status: pending + - id: pe-18 + title: Location of System Components + levels: + - high + rules: [] + status: pending + - id: pe-18.1 + title: Facility Site + rules: [] + status: pending + - id: pe-19 + title: Information Leakage + rules: [] + status: pending + - id: pe-19.1 + title: National Emissions Policies and Procedures + rules: [] + status: pending + - id: pe-20 + title: Asset Monitoring and Tracking + rules: [] + status: pending + - id: pe-21 + title: Electromagnetic Pulse Protection + rules: [] + status: pending + - id: pe-22 + title: Component Marking + rules: [] + status: pending + - id: pe-23 + title: Facility Location + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/pl.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/pl.yml new file mode 100644 index 000000000000..d670e154e380 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/pl.yml @@ -0,0 +1,84 @@ +# NIST 800-53 PL Family: Planning +controls: + - id: pl-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: pl-2 + title: System Security and Privacy Plans + levels: + - low + rules: [] + status: pending + - id: pl-2.1 + title: Concept of Operations + rules: [] + status: pending + - id: pl-2.2 + title: Functional Architecture + rules: [] + status: pending + - id: pl-2.3 + title: Plan and Coordinate with Other Organizational Entities + rules: [] + status: pending + - id: pl-3 + title: System Security Plan Update + rules: [] + status: pending + - id: pl-4 + title: Rules of Behavior + levels: + - low + rules: [] + status: pending + - id: pl-4.1 + title: Social Media and External Site/Application Usage Restrictions + levels: + - low + rules: [] + status: pending + - id: pl-5 + title: Privacy Impact Assessment + rules: [] + status: pending + - id: pl-6 + title: Security-related Activity Planning + rules: [] + status: pending + - id: pl-7 + title: Concept of Operations + rules: [] + status: pending + - id: pl-8 + title: Security and Privacy Architectures + levels: + - moderate + rules: [] + status: pending + - id: pl-8.1 + title: Defense in Depth + rules: [] + status: pending + - id: pl-8.2 + title: Supplier Diversity + rules: [] + status: pending + - id: pl-9 + title: Central Management + rules: [] + status: pending + - id: pl-10 + title: Baseline Selection + levels: + - low + rules: [] + status: pending + - id: pl-11 + title: Baseline Tailoring + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/pm.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/pm.yml new file mode 100644 index 000000000000..97a32be05deb --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/pm.yml @@ -0,0 +1,151 @@ +# NIST 800-53 PM Family: Program Management +controls: + - id: pm-1 + title: Information Security Program Plan + rules: [] + status: pending + - id: pm-2 + title: Information Security Program Leadership Role + rules: [] + status: pending + - id: pm-3 + title: Information Security and Privacy Resources + rules: [] + status: pending + - id: pm-4 + title: Plan of Action and Milestones Process + rules: [] + status: pending + - id: pm-5 + title: System Inventory + rules: [] + status: pending + - id: pm-5.1 + title: Inventory of Personally Identifiable Information + rules: [] + status: pending + - id: pm-6 + title: Measures of Performance + rules: [] + status: pending + - id: pm-7 + title: Enterprise Architecture + rules: [] + status: pending + - id: pm-7.1 + title: Offloading + rules: [] + status: pending + - id: pm-8 + title: Critical Infrastructure Plan + rules: [] + status: pending + - id: pm-9 + title: Risk Management Strategy + rules: [] + status: pending + - id: pm-10 + title: Authorization Process + rules: [] + status: pending + - id: pm-11 + title: Mission and Business Process Definition + rules: [] + status: pending + - id: pm-12 + title: Insider Threat Program + rules: [] + status: pending + - id: pm-13 + title: Security and Privacy Workforce + rules: [] + status: pending + - id: pm-14 + title: Testing, Training, and Monitoring + rules: [] + status: pending + - id: pm-15 + title: Security and Privacy Groups and Associations + rules: [] + status: pending + - id: pm-16 + title: Threat Awareness Program + rules: [] + status: pending + - id: pm-16.1 + title: Automated Means for Sharing Threat Intelligence + rules: [] + status: pending + - id: pm-17 + title: Protecting Controlled Unclassified Information on External Systems + rules: [] + status: pending + - id: pm-18 + title: Privacy Program Plan + rules: [] + status: pending + - id: pm-19 + title: Privacy Program Leadership Role + rules: [] + status: pending + - id: pm-20 + title: Dissemination of Privacy Program Information + rules: [] + status: pending + - id: pm-20.1 + title: Privacy Policies on Websites, Applications, and Digital Services + rules: [] + status: pending + - id: pm-21 + title: Accounting of Disclosures + rules: [] + status: pending + - id: pm-22 + title: Personally Identifiable Information Quality Management + rules: [] + status: pending + - id: pm-23 + title: Data Governance Body + rules: [] + status: pending + - id: pm-24 + title: Data Integrity Board + rules: [] + status: pending + - id: pm-25 + title: Minimization of Personally Identifiable Information Used in Testing, Training, and + Research + rules: [] + status: pending + - id: pm-26 + title: Complaint Management + rules: [] + status: pending + - id: pm-27 + title: Privacy Reporting + rules: [] + status: pending + - id: pm-28 + title: Risk Framing + rules: [] + status: pending + - id: pm-29 + title: Risk Management Program Leadership Roles + rules: [] + status: pending + - id: pm-30 + title: Supply Chain Risk Management Strategy + rules: [] + status: pending + - id: pm-30.1 + title: Suppliers of Critical or Mission-essential Items + rules: [] + status: pending + - id: pm-31 + title: Continuous Monitoring Strategy + rules: [] + status: pending + - id: pm-32 + title: Purposing + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ps.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ps.yml new file mode 100644 index 000000000000..ad7d70333c17 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ps.yml @@ -0,0 +1,94 @@ +# NIST 800-53 PS Family: Personnel Security +controls: + - id: ps-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ps-2 + title: Position Risk Designation + levels: + - low + rules: [] + status: pending + - id: ps-3 + title: Personnel Screening + levels: + - low + rules: [] + status: pending + - id: ps-3.1 + title: Classified Information + rules: [] + status: pending + - id: ps-3.2 + title: Formal Indoctrination + rules: [] + status: pending + - id: ps-3.3 + title: Information Requiring Special Protective Measures + rules: [] + status: pending + - id: ps-3.4 + title: Citizenship Requirements + rules: [] + status: pending + - id: ps-4 + title: Personnel Termination + levels: + - low + rules: [] + status: pending + - id: ps-4.1 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-4.2 + title: Automated Actions + levels: + - high + rules: [] + status: pending + - id: ps-5 + title: Personnel Transfer + levels: + - low + rules: [] + status: pending + - id: ps-6 + title: Access Agreements + levels: + - low + rules: [] + status: pending + - id: ps-6.1 + title: Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.2 + title: Classified Information Requiring Special Protection + rules: [] + status: pending + - id: ps-6.3 + title: Post-employment Requirements + rules: [] + status: pending + - id: ps-7 + title: External Personnel Security + levels: + - low + rules: [] + status: pending + - id: ps-8 + title: Personnel Sanctions + levels: + - low + rules: [] + status: pending + - id: ps-9 + title: Position Descriptions + levels: + - low + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/pt.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/pt.yml new file mode 100644 index 000000000000..fe3d1ee54437 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/pt.yml @@ -0,0 +1,86 @@ +# NIST 800-53 PT Family: PII Processing and Transparency +controls: + - id: pt-1 + title: Policy and Procedures + rules: [] + status: pending + - id: pt-2 + title: Authority to Process Personally Identifiable Information + rules: [] + status: pending + - id: pt-2.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-2.2 + title: Automation + rules: [] + status: pending + - id: pt-3 + title: Personally Identifiable Information Processing Purposes + rules: [] + status: pending + - id: pt-3.1 + title: Data Tagging + rules: [] + status: pending + - id: pt-3.2 + title: Automation + rules: [] + status: pending + - id: pt-4 + title: Consent + rules: [] + status: pending + - id: pt-4.1 + title: Tailored Consent + rules: [] + status: pending + - id: pt-4.2 + title: Just-in-time Consent + rules: [] + status: pending + - id: pt-4.3 + title: Revocation + rules: [] + status: pending + - id: pt-5 + title: Privacy Notice + rules: [] + status: pending + - id: pt-5.1 + title: Just-in-time Notice + rules: [] + status: pending + - id: pt-5.2 + title: Privacy Act Statements + rules: [] + status: pending + - id: pt-6 + title: System of Records Notice + rules: [] + status: pending + - id: pt-6.1 + title: Routine Uses + rules: [] + status: pending + - id: pt-6.2 + title: Exemption Rules + rules: [] + status: pending + - id: pt-7 + title: Specific Categories of Personally Identifiable Information + rules: [] + status: pending + - id: pt-7.1 + title: Social Security Numbers + rules: [] + status: pending + - id: pt-7.2 + title: First Amendment Information + rules: [] + status: pending + - id: pt-8 + title: Computer Matching Requirements + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/ra.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/ra.yml new file mode 100644 index 000000000000..ca44e21f4e67 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/ra.yml @@ -0,0 +1,128 @@ +# NIST 800-53 RA Family: Risk Assessment +controls: + - id: ra-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: ra-2 + title: Security Categorization + levels: + - low + rules: [] + status: pending + - id: ra-2.1 + title: Impact-level Prioritization + rules: [] + status: pending + - id: ra-3 + title: Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.1 + title: Supply Chain Risk Assessment + levels: + - low + rules: [] + status: pending + - id: ra-3.2 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: ra-3.3 + title: Dynamic Threat Awareness + rules: [] + status: pending + - id: ra-3.4 + title: Predictive Cyber Analytics + rules: [] + status: pending + - id: ra-4 + title: Risk Assessment Update + rules: [] + status: pending + - id: ra-5 + title: Vulnerability Monitoring and Scanning + levels: + - low + rules: [] + status: pending + - id: ra-5.1 + title: Update Tool Capability + rules: [] + status: pending + - id: ra-5.2 + title: Update Vulnerabilities to Be Scanned + levels: + - low + rules: [] + status: pending + - id: ra-5.3 + title: Breadth and Depth of Coverage + rules: [] + status: pending + - id: ra-5.4 + title: Discoverable Information + levels: + - high + rules: [] + status: pending + - id: ra-5.5 + title: Privileged Access + levels: + - moderate + rules: [] + status: pending + - id: ra-5.6 + title: Automated Trend Analyses + rules: [] + status: pending + - id: ra-5.7 + title: Automated Detection and Notification of Unauthorized Components + rules: [] + status: pending + - id: ra-5.8 + title: Review Historic Audit Logs + rules: [] + status: pending + - id: ra-5.9 + title: Penetration Testing and Analyses + rules: [] + status: pending + - id: ra-5.10 + title: Correlate Scanning Information + rules: [] + status: pending + - id: ra-5.11 + title: Public Disclosure Program + levels: + - low + rules: [] + status: pending + - id: ra-6 + title: Technical Surveillance Countermeasures Survey + rules: [] + status: pending + - id: ra-7 + title: Risk Response + levels: + - low + rules: [] + status: pending + - id: ra-8 + title: Privacy Impact Assessments + rules: [] + status: pending + - id: ra-9 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: ra-10 + title: Threat Hunting + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/sa.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/sa.yml new file mode 100644 index 000000000000..89a619dd4589 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/sa.yml @@ -0,0 +1,632 @@ +# NIST 800-53 SA Family: System and Services Acquisition +controls: + - id: sa-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sa-2 + title: Allocation of Resources + levels: + - low + rules: [] + status: pending + - id: sa-3 + title: System Development Life Cycle + levels: + - low + rules: [] + status: pending + - id: sa-3.1 + title: Manage Preproduction Environment + rules: [] + status: pending + - id: sa-3.2 + title: Use of Live or Operational Data + rules: [] + status: pending + - id: sa-3.3 + title: Technology Refresh + rules: [] + status: pending + - id: sa-4 + title: Acquisition Process + levels: + - low + rules: [] + status: pending + - id: sa-4.1 + title: Functional Properties of Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.2 + title: Design and Implementation Information for Controls + levels: + - moderate + rules: [] + status: pending + - id: sa-4.3 + title: Development Methods, Techniques, and Practices + rules: [] + status: pending + - id: sa-4.4 + title: Assignment of Components to Systems + rules: [] + status: pending + - id: sa-4.5 + title: System, Component, and Service Configurations + levels: + - high + rules: [] + status: pending + - id: sa-4.6 + title: Use of Information Assurance Products + rules: [] + status: pending + - id: sa-4.7 + title: 'NIAP-approved Protection Profiles ' + rules: [] + status: pending + - id: sa-4.8 + title: Continuous Monitoring Plan for Controls + rules: [] + status: pending + - id: sa-4.9 + title: Functions, Ports, Protocols, and Services in Use + levels: + - moderate + rules: [] + status: pending + - id: sa-4.10 + title: Use of Approved PIV Products + levels: + - low + rules: [] + status: pending + - id: sa-4.11 + title: System of Records + rules: [] + status: pending + - id: sa-4.12 + title: Data Ownership + rules: [] + status: pending + - id: sa-5 + title: System Documentation + levels: + - low + rules: [] + status: pending + - id: sa-5.1 + title: Functional Properties of Security Controls + rules: [] + status: pending + - id: sa-5.2 + title: Security-relevant External System Interfaces + rules: [] + status: pending + - id: sa-5.3 + title: High-level Design + rules: [] + status: pending + - id: sa-5.4 + title: Low-level Design + rules: [] + status: pending + - id: sa-5.5 + title: Source Code + rules: [] + status: pending + - id: sa-6 + title: Software Usage Restrictions + rules: [] + status: pending + - id: sa-7 + title: User-installed Software + rules: [] + status: pending + - id: sa-8 + title: Security and Privacy Engineering Principles + levels: + - low + rules: [] + status: pending + - id: sa-8.1 + title: Clear Abstractions + rules: [] + status: pending + - id: sa-8.2 + title: Least Common Mechanism + rules: [] + status: pending + - id: sa-8.3 + title: Modularity and Layering + rules: [] + status: pending + - id: sa-8.4 + title: Partially Ordered Dependencies + rules: [] + status: pending + - id: sa-8.5 + title: Efficiently Mediated Access + rules: [] + status: pending + - id: sa-8.6 + title: Minimized Sharing + rules: [] + status: pending + - id: sa-8.7 + title: Reduced Complexity + rules: [] + status: pending + - id: sa-8.8 + title: Secure Evolvability + rules: [] + status: pending + - id: sa-8.9 + title: Trusted Components + rules: [] + status: pending + - id: sa-8.10 + title: Hierarchical Trust + rules: [] + status: pending + - id: sa-8.11 + title: Inverse Modification Threshold + rules: [] + status: pending + - id: sa-8.12 + title: Hierarchical Protection + rules: [] + status: pending + - id: sa-8.13 + title: Minimized Security Elements + rules: [] + status: pending + - id: sa-8.14 + title: Least Privilege + rules: [] + status: pending + - id: sa-8.15 + title: Predicate Permission + rules: [] + status: pending + - id: sa-8.16 + title: Self-reliant Trustworthiness + rules: [] + status: pending + - id: sa-8.17 + title: Secure Distributed Composition + rules: [] + status: pending + - id: sa-8.18 + title: Trusted Communications Channels + rules: [] + status: pending + - id: sa-8.19 + title: Continuous Protection + rules: [] + status: pending + - id: sa-8.20 + title: Secure Metadata Management + rules: [] + status: pending + - id: sa-8.21 + title: Self-analysis + rules: [] + status: pending + - id: sa-8.22 + title: Accountability and Traceability + rules: [] + status: pending + - id: sa-8.23 + title: Secure Defaults + rules: [] + status: pending + - id: sa-8.24 + title: Secure Failure and Recovery + rules: [] + status: pending + - id: sa-8.25 + title: Economic Security + rules: [] + status: pending + - id: sa-8.26 + title: Performance Security + rules: [] + status: pending + - id: sa-8.27 + title: Human Factored Security + rules: [] + status: pending + - id: sa-8.28 + title: Acceptable Security + rules: [] + status: pending + - id: sa-8.29 + title: Repeatable and Documented Procedures + rules: [] + status: pending + - id: sa-8.30 + title: Procedural Rigor + rules: [] + status: pending + - id: sa-8.31 + title: Secure System Modification + rules: [] + status: pending + - id: sa-8.32 + title: Sufficient Documentation + rules: [] + status: pending + - id: sa-8.33 + title: Minimization + rules: [] + status: pending + - id: sa-9 + title: External System Services + levels: + - low + rules: [] + status: pending + - id: sa-9.1 + title: Risk Assessments and Organizational Approvals + rules: [] + status: pending + - id: sa-9.2 + title: Identification of Functions, Ports, Protocols, and Services + levels: + - moderate + rules: [] + status: pending + - id: sa-9.3 + title: Establish and Maintain Trust Relationship with Providers + rules: [] + status: pending + - id: sa-9.4 + title: Consistent Interests of Consumers and Providers + rules: [] + status: pending + - id: sa-9.5 + title: Processing, Storage, and Service Location + rules: [] + status: pending + - id: sa-9.6 + title: Organization-controlled Cryptographic Keys + rules: [] + status: pending + - id: sa-9.7 + title: Organization-controlled Integrity Checking + rules: [] + status: pending + - id: sa-9.8 + title: Processing and Storage Location — U.S. Jurisdiction + rules: [] + status: pending + - id: sa-10 + title: Developer Configuration Management + levels: + - moderate + rules: [] + status: pending + - id: sa-10.1 + title: Software and Firmware Integrity Verification + rules: [] + status: pending + - id: sa-10.2 + title: Alternative Configuration Management Processes + rules: [] + status: pending + - id: sa-10.3 + title: Hardware Integrity Verification + rules: [] + status: pending + - id: sa-10.4 + title: Trusted Generation + rules: [] + status: pending + - id: sa-10.5 + title: Mapping Integrity for Version Control + rules: [] + status: pending + - id: sa-10.6 + title: Trusted Distribution + rules: [] + status: pending + - id: sa-10.7 + title: Security and Privacy Representatives + rules: [] + status: pending + - id: sa-11 + title: Developer Testing and Evaluation + levels: + - moderate + rules: [] + status: pending + - id: sa-11.1 + title: Static Code Analysis + rules: [] + status: pending + - id: sa-11.2 + title: Threat Modeling and Vulnerability Analyses + rules: [] + status: pending + - id: sa-11.3 + title: Independent Verification of Assessment Plans and Evidence + rules: [] + status: pending + - id: sa-11.4 + title: Manual Code Reviews + rules: [] + status: pending + - id: sa-11.5 + title: Penetration Testing + rules: [] + status: pending + - id: sa-11.6 + title: Attack Surface Reviews + rules: [] + status: pending + - id: sa-11.7 + title: Verify Scope of Testing and Evaluation + rules: [] + status: pending + - id: sa-11.8 + title: Dynamic Code Analysis + rules: [] + status: pending + - id: sa-11.9 + title: Interactive Application Security Testing + rules: [] + status: pending + - id: sa-12 + title: Supply Chain Protection + rules: [] + status: pending + - id: sa-12.1 + title: Acquisition Strategies / Tools / Methods + rules: [] + status: pending + - id: sa-12.2 + title: Supplier Reviews + rules: [] + status: pending + - id: sa-12.3 + title: Trusted Shipping and Warehousing + rules: [] + status: pending + - id: sa-12.4 + title: Diversity of Suppliers + rules: [] + status: pending + - id: sa-12.5 + title: Limitation of Harm + rules: [] + status: pending + - id: sa-12.6 + title: Minimizing Procurement Time + rules: [] + status: pending + - id: sa-12.7 + title: Assessments Prior to Selection / Acceptance / Update + rules: [] + status: pending + - id: sa-12.8 + title: Use of All-source Intelligence + rules: [] + status: pending + - id: sa-12.9 + title: Operations Security + rules: [] + status: pending + - id: sa-12.10 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sa-12.11 + title: Penetration Testing / Analysis of Elements, Processes, and Actors + rules: [] + status: pending + - id: sa-12.12 + title: Inter-organizational Agreements + rules: [] + status: pending + - id: sa-12.13 + title: Critical Information System Components + rules: [] + status: pending + - id: sa-12.14 + title: Identity and Traceability + rules: [] + status: pending + - id: sa-12.15 + title: Processes to Address Weaknesses or Deficiencies + rules: [] + status: pending + - id: sa-13 + title: Trustworthiness + rules: [] + status: pending + - id: sa-14 + title: Criticality Analysis + rules: [] + status: pending + - id: sa-14.1 + title: Critical Components with No Viable Alternative Sourcing + rules: [] + status: pending + - id: sa-15 + title: Development Process, Standards, and Tools + levels: + - moderate + rules: [] + status: pending + - id: sa-15.1 + title: Quality Metrics + rules: [] + status: pending + - id: sa-15.2 + title: Security and Privacy Tracking Tools + rules: [] + status: pending + - id: sa-15.3 + title: Criticality Analysis + levels: + - moderate + rules: [] + status: pending + - id: sa-15.4 + title: Threat Modeling and Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.5 + title: Attack Surface Reduction + rules: [] + status: pending + - id: sa-15.6 + title: Continuous Improvement + rules: [] + status: pending + - id: sa-15.7 + title: Automated Vulnerability Analysis + rules: [] + status: pending + - id: sa-15.8 + title: Reuse of Threat and Vulnerability Information + rules: [] + status: pending + - id: sa-15.9 + title: Use of Live Data + rules: [] + status: pending + - id: sa-15.10 + title: Incident Response Plan + rules: [] + status: pending + - id: sa-15.11 + title: Archive System or Component + rules: [] + status: pending + - id: sa-15.12 + title: Minimize Personally Identifiable Information + rules: [] + status: pending + - id: sa-15.13 + title: Logging Syntax + rules: [] + status: pending + - id: sa-16 + title: Developer-provided Training + levels: + - high + rules: [] + status: pending + - id: sa-17 + title: Developer Security and Privacy Architecture and Design + levels: + - high + rules: [] + status: pending + - id: sa-17.1 + title: Formal Policy Model + rules: [] + status: pending + - id: sa-17.2 + title: Security-relevant Components + rules: [] + status: pending + - id: sa-17.3 + title: Formal Correspondence + rules: [] + status: pending + - id: sa-17.4 + title: Informal Correspondence + rules: [] + status: pending + - id: sa-17.5 + title: Conceptually Simple Design + rules: [] + status: pending + - id: sa-17.6 + title: Structure for Testing + rules: [] + status: pending + - id: sa-17.7 + title: Structure for Least Privilege + rules: [] + status: pending + - id: sa-17.8 + title: Orchestration + rules: [] + status: pending + - id: sa-17.9 + title: Design Diversity + rules: [] + status: pending + - id: sa-18 + title: Tamper Resistance and Detection + rules: [] + status: pending + - id: sa-18.1 + title: Multiple Phases of System Development Life Cycle + rules: [] + status: pending + - id: sa-18.2 + title: Inspection of Systems or Components + rules: [] + status: pending + - id: sa-19 + title: Component Authenticity + rules: [] + status: pending + - id: sa-19.1 + title: Anti-counterfeit Training + rules: [] + status: pending + - id: sa-19.2 + title: Configuration Control for Component Service and Repair + rules: [] + status: pending + - id: sa-19.3 + title: Component Disposal + rules: [] + status: pending + - id: sa-19.4 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sa-20 + title: Customized Development of Critical Components + rules: [] + status: pending + - id: sa-21 + title: Developer Screening + levels: + - high + rules: [] + status: pending + - id: sa-21.1 + title: Validation of Screening + rules: [] + status: pending + - id: sa-22 + title: Unsupported System Components + levels: + - low + rules: [] + status: pending + - id: sa-22.1 + title: Alternative Sources for Continued Support + rules: [] + status: pending + - id: sa-23 + title: Specialization + rules: [] + status: pending + - id: sa-24 + title: Design For Cyber Resiliency + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/sc.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/sc.yml new file mode 100644 index 000000000000..293932de0927 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/sc.yml @@ -0,0 +1,719 @@ +# NIST 800-53 SC Family: System and Communications Protection +controls: + - id: sc-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sc-2 + title: Separation of System and User Functionality + levels: + - moderate + rules: [] + status: pending + - id: sc-2.1 + title: Interfaces for Non-privileged Users + rules: [] + status: pending + - id: sc-2.2 + title: Disassociability + rules: [] + status: pending + - id: sc-3 + title: Security Function Isolation + levels: + - high + rules: + - selinux_not_disabled + - selinux_state + - var_selinux_state=enforcing + status: automated + - id: sc-3.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-3.2 + title: Access and Flow Control Functions + rules: [] + status: pending + - id: sc-3.3 + title: Minimize Nonsecurity Functionality + rules: [] + status: pending + - id: sc-3.4 + title: Module Coupling and Cohesiveness + rules: [] + status: pending + - id: sc-3.5 + title: Layered Structures + rules: [] + status: pending + - id: sc-4 + title: Information in Shared System Resources + levels: + - moderate + rules: + - dir_perms_world_writable_sticky_bits + - file_permissions_unauthorized_world_writable + status: automated + - id: sc-4.1 + title: Security Levels + rules: [] + status: pending + - id: sc-4.2 + title: Multilevel or Periods Processing + rules: [] + status: pending + - id: sc-5 + title: Denial-of-service Protection + levels: + - low + rules: + - sysctl_net_ipv4_tcp_syncookies + status: automated + - id: sc-5.1 + title: Restrict Ability to Attack Other Systems + rules: [] + status: pending + - id: sc-5.2 + title: Capacity, Bandwidth, and Redundancy + rules: [] + status: pending + - id: sc-5.3 + title: Detection and Monitoring + rules: [] + status: pending + - id: sc-6 + title: Resource Availability + rules: [] + status: pending + - id: sc-7 + title: Boundary Protection + levels: + - low + rules: + - service_firewalld_enabled + status: automated + - id: sc-7.1 + title: Physically Separated Subnetworks + rules: [] + status: pending + - id: sc-7.2 + title: Public Access + rules: [] + status: pending + - id: sc-7.3 + title: Access Points + levels: + - moderate + rules: [] + status: pending + - id: sc-7.4 + title: External Telecommunications Services + levels: + - moderate + rules: [] + status: pending + - id: sc-7.5 + title: Deny by Default — Allow by Exception + levels: + - moderate + rules: [] + status: pending + - id: sc-7.6 + title: Response to Recognized Failures + rules: [] + status: pending + - id: sc-7.7 + title: Split Tunneling for Remote Devices + levels: + - moderate + rules: [] + status: pending + - id: sc-7.8 + title: Route Traffic to Authenticated Proxy Servers + levels: + - moderate + rules: [] + status: pending + - id: sc-7.9 + title: Restrict Threatening Outgoing Communications Traffic + rules: [] + status: pending + - id: sc-7.10 + title: Prevent Exfiltration + rules: [] + status: pending + - id: sc-7.11 + title: Restrict Incoming Communications Traffic + rules: [] + status: pending + - id: sc-7.12 + title: Host-based Protection + rules: [] + status: pending + - id: sc-7.13 + title: Isolation of Security Tools, Mechanisms, and Support Components + rules: [] + status: pending + - id: sc-7.14 + title: Protect Against Unauthorized Physical Connections + rules: [] + status: pending + - id: sc-7.15 + title: Networked Privileged Accesses + rules: [] + status: pending + - id: sc-7.16 + title: Prevent Discovery of System Components + rules: [] + status: pending + - id: sc-7.17 + title: Automated Enforcement of Protocol Formats + rules: [] + status: pending + - id: sc-7.18 + title: Fail Secure + levels: + - high + rules: [] + status: pending + - id: sc-7.19 + title: Block Communication from Non-organizationally Configured Hosts + rules: [] + status: pending + - id: sc-7.20 + title: Dynamic Isolation and Segregation + rules: [] + status: pending + - id: sc-7.21 + title: Isolation of System Components + levels: + - high + rules: [] + status: pending + - id: sc-7.22 + title: Separate Subnets for Connecting to Different Security Domains + rules: [] + status: pending + - id: sc-7.23 + title: Disable Sender Feedback on Protocol Validation Failure + rules: [] + status: pending + - id: sc-7.24 + title: Personally Identifiable Information + rules: [] + status: pending + - id: sc-7.25 + title: Unclassified National Security System Connections + rules: [] + status: pending + - id: sc-7.26 + title: Classified National Security System Connections + rules: [] + status: pending + - id: sc-7.27 + title: Unclassified Non-national Security System Connections + rules: [] + status: pending + - id: sc-7.28 + title: Connections to Public Networks + rules: [] + status: pending + - id: sc-7.29 + title: Separate Subnets to Isolate Functions + rules: [] + status: pending + - id: sc-8 + title: Transmission Confidentiality and Integrity + levels: + - moderate + rules: + - configure_custom_crypto_policy_cis + status: automated + - id: sc-8.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-8.2 + title: Pre- and Post-transmission Handling + rules: [] + status: pending + - id: sc-8.3 + title: Cryptographic Protection for Message Externals + rules: [] + status: pending + - id: sc-8.4 + title: Conceal or Randomize Communications + rules: [] + status: pending + - id: sc-8.5 + title: Protected Distribution System + rules: [] + status: pending + - id: sc-9 + title: Transmission Confidentiality + rules: [] + status: pending + - id: sc-10 + title: Network Disconnect + levels: + - moderate + rules: [] + status: pending + - id: sc-11 + title: Trusted Path + rules: [] + status: pending + - id: sc-11.1 + title: Irrefutable Communications Path + rules: [] + status: pending + - id: sc-12 + title: Cryptographic Key Establishment and Management + levels: + - low + rules: [] + status: pending + - id: sc-12.1 + title: Availability + levels: + - high + rules: [] + status: pending + - id: sc-12.2 + title: Symmetric Keys + rules: [] + status: pending + - id: sc-12.3 + title: Asymmetric Keys + rules: [] + status: pending + - id: sc-12.4 + title: PKI Certificates + rules: [] + status: pending + - id: sc-12.5 + title: PKI Certificates / Hardware Tokens + rules: [] + status: pending + - id: sc-12.6 + title: Physical Control of Keys + rules: [] + status: pending + - id: sc-13 + title: Cryptographic Protection + levels: + - low + rules: [] + status: pending + - id: sc-13.1 + title: FIPS-validated Cryptography + rules: [] + status: pending + - id: sc-13.2 + title: NSA-approved Cryptography + rules: [] + status: pending + - id: sc-13.3 + title: Individuals Without Formal Access Approvals + rules: [] + status: pending + - id: sc-13.4 + title: Digital Signatures + rules: [] + status: pending + - id: sc-14 + title: Public Access Protections + rules: [] + status: pending + - id: sc-15 + title: Collaborative Computing Devices and Applications + levels: + - low + rules: [] + status: pending + - id: sc-15.1 + title: Physical or Logical Disconnect + rules: [] + status: pending + - id: sc-15.2 + title: Blocking Inbound and Outbound Communications Traffic + rules: [] + status: pending + - id: sc-15.3 + title: Disabling and Removal in Secure Work Areas + rules: [] + status: pending + - id: sc-15.4 + title: Explicitly Indicate Current Participants + rules: [] + status: pending + - id: sc-16 + title: Transmission of Security and Privacy Attributes + rules: [] + status: pending + - id: sc-16.1 + title: Integrity Verification + rules: [] + status: pending + - id: sc-16.2 + title: Anti-spoofing Mechanisms + rules: [] + status: pending + - id: sc-16.3 + title: Cryptographic Binding + rules: [] + status: pending + - id: sc-17 + title: Public Key Infrastructure Certificates + levels: + - moderate + rules: [] + status: pending + - id: sc-18 + title: Mobile Code + levels: + - moderate + rules: [] + status: pending + - id: sc-18.1 + title: Identify Unacceptable Code and Take Corrective Actions + rules: [] + status: pending + - id: sc-18.2 + title: Acquisition, Development, and Use + rules: [] + status: pending + - id: sc-18.3 + title: Prevent Downloading and Execution + rules: [] + status: pending + - id: sc-18.4 + title: Prevent Automatic Execution + rules: [] + status: pending + - id: sc-18.5 + title: Allow Execution Only in Confined Environments + rules: [] + status: pending + - id: sc-19 + title: Voice Over Internet Protocol + rules: [] + status: pending + - id: sc-20 + title: Secure Name/Address Resolution Service (Authoritative Source) + levels: + - low + rules: [] + status: pending + - id: sc-20.1 + title: Child Subspaces + rules: [] + status: pending + - id: sc-20.2 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-21 + title: Secure Name/Address Resolution Service (Recursive or Caching Resolver) + levels: + - low + rules: [] + status: pending + - id: sc-21.1 + title: Data Origin and Integrity + rules: [] + status: pending + - id: sc-22 + title: Architecture and Provisioning for Name/Address Resolution Service + levels: + - low + rules: [] + status: pending + - id: sc-23 + title: Session Authenticity + levels: + - moderate + rules: [] + status: pending + - id: sc-23.1 + title: Invalidate Session Identifiers at Logout + rules: [] + status: pending + - id: sc-23.2 + title: User-initiated Logouts and Message Displays + rules: [] + status: pending + - id: sc-23.3 + title: Unique System-generated Session Identifiers + rules: [] + status: pending + - id: sc-23.4 + title: Unique Session Identifiers with Randomization + rules: [] + status: pending + - id: sc-23.5 + title: Allowed Certificate Authorities + rules: [] + status: pending + - id: sc-24 + title: Fail in Known State + levels: + - high + rules: + - service_systemd-journald_enabled + status: automated + - id: sc-25 + title: Thin Nodes + rules: [] + status: pending + - id: sc-26 + title: Decoys + rules: [] + status: pending + - id: sc-26.1 + title: Detection of Malicious Code + rules: [] + status: pending + - id: sc-27 + title: Platform-independent Applications + rules: [] + status: pending + - id: sc-28 + title: Protection of Information at Rest + levels: + - moderate + rules: [] + status: pending + - id: sc-28.1 + title: Cryptographic Protection + levels: + - moderate + rules: [] + status: pending + - id: sc-28.2 + title: Offline Storage + rules: [] + status: pending + - id: sc-28.3 + title: Cryptographic Keys + rules: [] + status: pending + - id: sc-29 + title: Heterogeneity + rules: [] + status: pending + - id: sc-29.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30 + title: Concealment and Misdirection + rules: [] + status: pending + - id: sc-30.1 + title: Virtualization Techniques + rules: [] + status: pending + - id: sc-30.2 + title: Randomness + rules: [] + status: pending + - id: sc-30.3 + title: Change Processing and Storage Locations + rules: [] + status: pending + - id: sc-30.4 + title: Misleading Information + rules: [] + status: pending + - id: sc-30.5 + title: Concealment of System Components + rules: [] + status: pending + - id: sc-31 + title: Covert Channel Analysis + rules: [] + status: pending + - id: sc-31.1 + title: Test Covert Channels for Exploitability + rules: [] + status: pending + - id: sc-31.2 + title: Maximum Bandwidth + rules: [] + status: pending + - id: sc-31.3 + title: Measure Bandwidth in Operational Environments + rules: [] + status: pending + - id: sc-32 + title: System Partitioning + rules: [] + status: pending + - id: sc-32.1 + title: Separate Physical Domains for Privileged Functions + rules: [] + status: pending + - id: sc-33 + title: Transmission Preparation Integrity + rules: [] + status: pending + - id: sc-34 + title: Non-modifiable Executable Programs + rules: [] + status: pending + - id: sc-34.1 + title: No Writable Storage + rules: [] + status: pending + - id: sc-34.2 + title: Integrity Protection on Read-only Media + rules: [] + status: pending + - id: sc-34.3 + title: Hardware-based Protection + rules: [] + status: pending + - id: sc-35 + title: External Malicious Code Identification + rules: [] + status: pending + - id: sc-36 + title: Distributed Processing and Storage + rules: [] + status: pending + - id: sc-36.1 + title: Polling Techniques + rules: [] + status: pending + - id: sc-36.2 + title: Synchronization + rules: [] + status: pending + - id: sc-37 + title: Out-of-band Channels + rules: [] + status: pending + - id: sc-37.1 + title: Ensure Delivery and Transmission + rules: [] + status: pending + - id: sc-38 + title: Operations Security + rules: [] + status: pending + - id: sc-39 + title: Process Isolation + levels: + - low + rules: [] + status: pending + - id: sc-39.1 + title: Hardware Separation + rules: [] + status: pending + - id: sc-39.2 + title: Separate Execution Domain Per Thread + rules: [] + status: pending + - id: sc-40 + title: Wireless Link Protection + rules: [] + status: pending + - id: sc-40.1 + title: Electromagnetic Interference + rules: [] + status: pending + - id: sc-40.2 + title: Reduce Detection Potential + rules: [] + status: pending + - id: sc-40.3 + title: Imitative or Manipulative Communications Deception + rules: [] + status: pending + - id: sc-40.4 + title: Signal Parameter Identification + rules: [] + status: pending + - id: sc-41 + title: Port and I/O Device Access + rules: [] + status: pending + - id: sc-42 + title: Sensor Capability and Data + rules: [] + status: pending + - id: sc-42.1 + title: Reporting to Authorized Individuals or Roles + rules: [] + status: pending + - id: sc-42.2 + title: Authorized Use + rules: [] + status: pending + - id: sc-42.3 + title: Prohibit Use of Devices + rules: [] + status: pending + - id: sc-42.4 + title: Notice of Collection + rules: [] + status: pending + - id: sc-42.5 + title: Collection Minimization + rules: [] + status: pending + - id: sc-43 + title: Usage Restrictions + rules: [] + status: pending + - id: sc-44 + title: Detonation Chambers + rules: [] + status: pending + - id: sc-45 + title: System Time Synchronization + rules: [] + status: pending + - id: sc-45.1 + title: Synchronization with Authoritative Time Source + rules: [] + status: pending + - id: sc-45.2 + title: Secondary Authoritative Time Source + rules: [] + status: pending + - id: sc-46 + title: Cross Domain Policy Enforcement + rules: [] + status: pending + - id: sc-47 + title: Alternate Communications Paths + rules: [] + status: pending + - id: sc-48 + title: Sensor Relocation + rules: [] + status: pending + - id: sc-48.1 + title: Dynamic Relocation of Sensors or Monitoring Capabilities + rules: [] + status: pending + - id: sc-49 + title: Hardware-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-50 + title: Software-enforced Separation and Policy Enforcement + rules: [] + status: pending + - id: sc-51 + title: Hardware-based Protection + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/si.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/si.yml new file mode 100644 index 000000000000..4cabcafda2db --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/si.yml @@ -0,0 +1,545 @@ +# NIST 800-53 SI Family: System and Information Integrity +controls: + - id: si-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: si-2 + title: Flaw Remediation + levels: + - low + rules: + - ensure_gpgcheck_globally_activated + - ensure_gpgcheck_never_disabled + - ensure_redhat_gpgkey_installed + status: automated + - id: si-2.1 + title: Central Management + rules: [] + status: pending + - id: si-2.2 + title: Automated Flaw Remediation Status + levels: + - moderate + rules: [] + status: pending + - id: si-2.3 + title: Time to Remediate Flaws and Benchmarks for Corrective Actions + rules: [] + status: pending + - id: si-2.4 + title: Automated Patch Management Tools + rules: [] + status: pending + - id: si-2.5 + title: Automatic Software and Firmware Updates + rules: [] + status: pending + - id: si-2.6 + title: Removal of Previous Versions of Software and Firmware + rules: [] + status: pending + - id: si-2.7 + title: Root Cause Analysis + rules: [] + status: pending + - id: si-3 + title: Malicious Code Protection + levels: + - low + rules: + - kernel_module_usb-storage_disabled + - service_autofs_disabled + status: automated + - id: si-3.1 + title: Central Management + rules: [] + status: pending + - id: si-3.2 + title: Automatic Updates + rules: [] + status: pending + - id: si-3.3 + title: Non-privileged Users + rules: [] + status: pending + - id: si-3.4 + title: Updates Only by Privileged Users + rules: [] + status: pending + - id: si-3.5 + title: Portable Storage Devices + rules: [] + status: pending + - id: si-3.6 + title: Testing and Verification + rules: [] + status: pending + - id: si-3.7 + title: Nonsignature-based Detection + rules: [] + status: pending + - id: si-3.8 + title: Detect Unauthorized Commands + rules: [] + status: pending + - id: si-3.9 + title: Authenticate Remote Commands + rules: [] + status: pending + - id: si-3.10 + title: Malicious Code Analysis + rules: [] + status: pending + - id: si-4 + title: System Monitoring + levels: + - low + rules: + - kernel_module_dccp_disabled + - kernel_module_rds_disabled + - kernel_module_sctp_disabled + - kernel_module_tipc_disabled + - service_avahi-daemon_disabled + status: automated + - id: si-4.1 + title: System-wide Intrusion Detection System + rules: [] + status: pending + - id: si-4.2 + title: Automated Tools and Mechanisms for Real-time Analysis + levels: + - moderate + rules: [] + status: pending + - id: si-4.3 + title: Automated Tool and Mechanism Integration + rules: [] + status: pending + - id: si-4.4 + title: Inbound and Outbound Communications Traffic + levels: + - moderate + rules: [] + status: pending + - id: si-4.5 + title: System-generated Alerts + levels: + - moderate + rules: [] + status: pending + - id: si-4.6 + title: Restrict Non-privileged Users + rules: [] + status: pending + - id: si-4.7 + title: Automated Response to Suspicious Events + rules: [] + status: pending + - id: si-4.8 + title: Protection of Monitoring Information + rules: [] + status: pending + - id: si-4.9 + title: Testing of Monitoring Tools and Mechanisms + rules: [] + status: pending + - id: si-4.10 + title: Visibility of Encrypted Communications + levels: + - high + rules: [] + status: pending + - id: si-4.11 + title: Analyze Communications Traffic Anomalies + rules: [] + status: pending + - id: si-4.12 + title: Automated Organization-generated Alerts + levels: + - high + rules: [] + status: pending + - id: si-4.13 + title: Analyze Traffic and Event Patterns + rules: [] + status: pending + - id: si-4.14 + title: Wireless Intrusion Detection + levels: + - high + rules: [] + status: pending + - id: si-4.15 + title: Wireless to Wireline Communications + rules: [] + status: pending + - id: si-4.16 + title: Correlate Monitoring Information + rules: [] + status: pending + - id: si-4.17 + title: Integrated Situational Awareness + rules: [] + status: pending + - id: si-4.18 + title: Analyze Traffic and Covert Exfiltration + rules: [] + status: pending + - id: si-4.19 + title: Risk for Individuals + rules: [] + status: pending + - id: si-4.20 + title: Privileged Users + levels: + - high + rules: [] + status: pending + - id: si-4.21 + title: Probationary Periods + rules: [] + status: pending + - id: si-4.22 + title: Unauthorized Network Services + levels: + - high + rules: [] + status: pending + - id: si-4.23 + title: Host-based Devices + rules: [] + status: pending + - id: si-4.24 + title: Indicators of Compromise + rules: [] + status: pending + - id: si-4.25 + title: Optimize Network Traffic Analysis + rules: [] + status: pending + - id: si-5 + title: Security Alerts, Advisories, and Directives + levels: + - low + rules: [] + status: pending + - id: si-5.1 + title: Automated Alerts and Advisories + levels: + - high + rules: [] + status: pending + - id: si-6 + title: Security and Privacy Function Verification + levels: + - high + rules: [] + status: pending + - id: si-6.1 + title: Notification of Failed Security Tests + rules: [] + status: pending + - id: si-6.2 + title: Automation Support for Distributed Testing + rules: [] + status: pending + - id: si-6.3 + title: Report Verification Results + rules: [] + status: pending + - id: si-7 + title: Software, Firmware, and Information Integrity + levels: + - moderate + rules: [] + status: pending + - id: si-7.1 + title: Integrity Checks + levels: + - moderate + rules: [] + status: pending + - id: si-7.2 + title: Automated Notifications of Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.3 + title: Centrally Managed Integrity Tools + rules: [] + status: pending + - id: si-7.4 + title: Tamper-evident Packaging + rules: [] + status: pending + - id: si-7.5 + title: Automated Response to Integrity Violations + levels: + - high + rules: [] + status: pending + - id: si-7.6 + title: Cryptographic Protection + rules: [] + status: pending + - id: si-7.7 + title: Integration of Detection and Response + levels: + - moderate + rules: [] + status: pending + - id: si-7.8 + title: Auditing Capability for Significant Events + rules: [] + status: pending + - id: si-7.9 + title: Verify Boot Process + rules: [] + status: pending + - id: si-7.10 + title: Protection of Boot Firmware + rules: [] + status: pending + - id: si-7.11 + title: Confined Environments with Limited Privileges + rules: [] + status: pending + - id: si-7.12 + title: Integrity Verification + rules: [] + status: pending + - id: si-7.13 + title: Code Execution in Protected Environments + rules: [] + status: pending + - id: si-7.14 + title: Binary or Machine Executable Code + rules: [] + status: pending + - id: si-7.15 + title: Code Authentication + levels: + - high + rules: [] + status: pending + - id: si-7.16 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-7.17 + title: Runtime Application Self-protection + rules: [] + status: pending + - id: si-8 + title: Spam Protection + levels: + - moderate + rules: [] + status: pending + - id: si-8.1 + title: Central Management + rules: [] + status: pending + - id: si-8.2 + title: Automatic Updates + levels: + - moderate + rules: [] + status: pending + - id: si-8.3 + title: Continuous Learning Capability + rules: [] + status: pending + - id: si-9 + title: Information Input Restrictions + rules: [] + status: pending + - id: si-10 + title: Information Input Validation + levels: + - moderate + rules: [] + status: pending + - id: si-10.1 + title: Manual Override Capability + rules: [] + status: pending + - id: si-10.2 + title: Review and Resolve Errors + rules: [] + status: pending + - id: si-10.3 + title: Predictable Behavior + rules: [] + status: pending + - id: si-10.4 + title: Timing Interactions + rules: [] + status: pending + - id: si-10.5 + title: Restrict Inputs to Trusted Sources and Approved Formats + rules: [] + status: pending + - id: si-10.6 + title: Injection Prevention + rules: [] + status: pending + - id: si-11 + title: Error Handling + levels: + - moderate + rules: [] + status: pending + - id: si-12 + title: Information Management and Retention + levels: + - low + rules: [] + status: pending + - id: si-12.1 + title: Limit Personally Identifiable Information Elements + rules: [] + status: pending + - id: si-12.2 + title: Minimize Personally Identifiable Information in Testing, Training, and Research + rules: [] + status: pending + - id: si-12.3 + title: Information Disposal + rules: [] + status: pending + - id: si-13 + title: Predictable Failure Prevention + rules: [] + status: pending + - id: si-13.1 + title: Transferring Component Responsibilities + rules: [] + status: pending + - id: si-13.2 + title: Time Limit on Process Execution Without Supervision + rules: [] + status: pending + - id: si-13.3 + title: Manual Transfer Between Components + rules: [] + status: pending + - id: si-13.4 + title: Standby Component Installation and Notification + rules: [] + status: pending + - id: si-13.5 + title: Failover Capability + rules: [] + status: pending + - id: si-14 + title: Non-persistence + rules: [] + status: pending + - id: si-14.1 + title: Refresh from Trusted Sources + rules: [] + status: pending + - id: si-14.2 + title: Non-persistent Information + rules: [] + status: pending + - id: si-14.3 + title: Non-persistent Connectivity + rules: [] + status: pending + - id: si-15 + title: Information Output Filtering + rules: [] + status: pending + - id: si-16 + title: Memory Protection + levels: + - moderate + rules: + - sysctl_kernel_randomize_va_space + status: automated + - id: si-17 + title: Fail-safe Procedures + rules: [] + status: pending + - id: si-18 + title: Personally Identifiable Information Quality Operations + rules: [] + status: pending + - id: si-18.1 + title: Automation Support + rules: [] + status: pending + - id: si-18.2 + title: Data Tags + rules: [] + status: pending + - id: si-18.3 + title: Collection + rules: [] + status: pending + - id: si-18.4 + title: Individual Requests + rules: [] + status: pending + - id: si-18.5 + title: Notice of Correction or Deletion + rules: [] + status: pending + - id: si-19 + title: De-identification + rules: [] + status: pending + - id: si-19.1 + title: Collection + rules: [] + status: pending + - id: si-19.2 + title: Archiving + rules: [] + status: pending + - id: si-19.3 + title: Release + rules: [] + status: pending + - id: si-19.4 + title: Removal, Masking, Encryption, Hashing, or Replacement of Direct Identifiers + rules: [] + status: pending + - id: si-19.5 + title: Statistical Disclosure Control + rules: [] + status: pending + - id: si-19.6 + title: Differential Privacy + rules: [] + status: pending + - id: si-19.7 + title: Validated Algorithms and Software + rules: [] + status: pending + - id: si-19.8 + title: Motivated Intruder + rules: [] + status: pending + - id: si-20 + title: Tainting + rules: [] + status: pending + - id: si-21 + title: Information Refresh + rules: [] + status: pending + - id: si-22 + title: Information Diversity + rules: [] + status: pending + - id: si-23 + title: Information Fragmentation + rules: [] + status: pending diff --git a/shared/references/controls/nist_800_53_cis_reference_rhel9/sr.yml b/shared/references/controls/nist_800_53_cis_reference_rhel9/sr.yml new file mode 100644 index 000000000000..1e130f32cd89 --- /dev/null +++ b/shared/references/controls/nist_800_53_cis_reference_rhel9/sr.yml @@ -0,0 +1,138 @@ +# NIST 800-53 SR Family: Supply Chain Risk Management +controls: + - id: sr-1 + title: Policy and Procedures + levels: + - low + rules: [] + status: pending + - id: sr-2 + title: Supply Chain Risk Management Plan + levels: + - low + rules: [] + status: pending + - id: sr-2.1 + title: Establish SCRM Team + levels: + - low + rules: [] + status: pending + - id: sr-3 + title: Supply Chain Controls and Processes + levels: + - low + rules: [] + status: pending + - id: sr-3.1 + title: Diverse Supply Base + rules: [] + status: pending + - id: sr-3.2 + title: Limitation of Harm + rules: [] + status: pending + - id: sr-3.3 + title: Sub-tier Flow Down + rules: [] + status: pending + - id: sr-4 + title: Provenance + rules: [] + status: pending + - id: sr-4.1 + title: Identity + rules: [] + status: pending + - id: sr-4.2 + title: Track and Trace + rules: [] + status: pending + - id: sr-4.3 + title: Validate as Genuine and Not Altered + rules: [] + status: pending + - id: sr-4.4 + title: Supply Chain Integrity — Pedigree + rules: [] + status: pending + - id: sr-5 + title: Acquisition Strategies, Tools, and Methods + levels: + - low + rules: [] + status: pending + - id: sr-5.1 + title: Adequate Supply + rules: [] + status: pending + - id: sr-5.2 + title: Assessments Prior to Selection, Acceptance, Modification, or Update + rules: [] + status: pending + - id: sr-6 + title: Supplier Assessments and Reviews + levels: + - moderate + rules: [] + status: pending + - id: sr-6.1 + title: Testing and Analysis + rules: [] + status: pending + - id: sr-7 + title: Supply Chain Operations Security + rules: [] + status: pending + - id: sr-8 + title: Notification Agreements + levels: + - low + rules: [] + status: pending + - id: sr-9 + title: Tamper Resistance and Detection + levels: + - high + rules: [] + status: pending + - id: sr-9.1 + title: Multiple Stages of System Development Life Cycle + levels: + - high + rules: [] + status: pending + - id: sr-10 + title: Inspection of Systems or Components + levels: + - low + rules: [] + status: pending + - id: sr-11 + title: Component Authenticity + levels: + - low + rules: [] + status: pending + - id: sr-11.1 + title: Anti-counterfeit Training + levels: + - low + rules: [] + status: pending + - id: sr-11.2 + title: Configuration Control for Component Service and Repair + levels: + - low + rules: [] + status: pending + - id: sr-11.3 + title: Anti-counterfeit Scanning + rules: [] + status: pending + - id: sr-12 + title: Component Disposal + levels: + - low + rules: [] + status: pending diff --git a/shared/references/disa-stig-al2023-v1r1-xccdf-manual.xml b/shared/references/disa-stig-al2023-v1r1-xccdf-manual.xml new file mode 100755 index 000000000000..d27b118c8335 --- /dev/null +++ b/shared/references/disa-stig-al2023-v1r1-xccdf-manual.xml @@ -0,0 +1,2972 @@ +acceptedAmazon Linux 2023 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 1 Benchmark Date: 14 Jul 20253.5.11.10.01I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000185-GPOS-00079<GroupDescription></GroupDescription>AZLX-23-000100Amazon Linux 2023 local disk partitions must implement cryptographic mechanisms to prevent unauthorized disclosure or modification of all information that requires at rest protection.<VulnDiscussion>Information at rest refers to the state of information when it is located on a secondary storage device (e.g., disk drive and tape drive, when used for backups) within an operating system. + +This requirement addresses protection of user-generated data, as well as operating system-specific configuration data. Organizations may choose to employ different mechanisms to achieve confidentiality and integrity protections, as appropriate, in accordance with the security category and/or classification of the information. + +Satisfies: SRG-OS-000185-GPOS-00079, SRG-OS-000404-GPOS-00183, SRG-OS-000405-GPOS-00184</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001199CCI-002475CCI-002476Configure Amazon Linux 2023 to protect the confidentiality and integrity of all information at rest. + +Encrypting a partition in an already installed system is more difficult, because existing partitions will need to be resized and changed. + +To encrypt an entire partition, dedicate a partition for encryption in the partition layout.Verify Amazon Linux 2023 is configured so that all partitions are encrypted with the following command: + +$ sudo blkid +/dev/xvda1: UUID="ed0acbe9-bd05-495e-a9ac-cb615b29327d" TYPE="crypto_LUKS" + +Every persistent disk partition present must be of "Type" "crypto_LUKS". + +If any partitions other than the boot partition, bios partition or pseudo file systems (such as /proc or /sys) are not type "crypto_LUKS", this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>AZLX-23-000110Amazon Linux 2023 must ensure cryptographic verification of vendor software packages.<VulnDiscussion>Cryptographic verification of vendor software packages ensures that all software packages are obtained from a valid source and protects against spoofing that could lead to installation of malware on the system. Amazon Linux cryptographically signs all software packages, which includes updates, with a GPG key to Verify they are valid.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-003992Configure Amazon Linux 2023 to have the public key for verifying RPM packages to be installed with the "system-release" package. + +Install the system-release installation with the following command: +$ sudo dnf install -y system-release + +Ensure cryptographic verification of software packages is enabled by editing /etc/dnf/dnf.conf and under '[main]' in the configuration file add: + +gpgcheck=1Verify Amazon Linux 2023 package-signing keys are installed on the system and verify their fingerprints match vendor values. + +Note: For Amazon Linux 2023 software packages, AWS uses GPG keys defined in key file "/etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2023" by default. + +List Amazon Linux GPG keys installed on the system: + +$ sudo rpm -q gpg-pubkey --qf "%{NAME}-%{VERSION}-%{RELEASE} %{SUMMARY}\n" +gpg-pubkey-d832c631-6515c85e Amazon Linux <amazon-linux@amazon.com> public key + +If there is no Amazon Linux GPG key installed, this is a finding. + +Extract the fingerprint from the key with this command: + +$ sudo gpg -q --keyid-format short --with-fingerprint /etc/pki/rpm-gpg/RPM-GPG-KEY-amazon-linux-2023 +pub rsa4096/D832C631 2022-12-08 [SC] + Key fingerprint = B21C 50FA 44A9 9720 EAA7 2F7F E951 904A D832 C631 +uid Amazon Linux <amazon-linux@amazon.com> + +Compare the Key fingerprint with the key fingerprint from Amazon Documentation and instructions at https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/verify-keys.html + +If key fingerprints do not match, or the key file is missing, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>AZLX-23-000115Amazon Linux 2023 must check the GPG signature of locally installed software packages before installation.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of Amazon Linux 2023. This requirement ensures the software has not been tampered with and that it has been provided by a trusted vendor. + +All software packages must be signed with a cryptographic key recognized and approved by the organization. + +Verifying the authenticity of software prior to installation validates the integrity of the software package received from a vendor. This verifies the software has not been tampered with and that it has been provided by a trusted vendor.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-003992Configure Amazon Linux 2023 to always check the GPG signature of local software packages before installation. + +Add or update the following line in the [main] section of the /etc/dnf/dnf.conf file: + +localpkg_gpgcheck=1Verify Amazon Linux 2023 is configured so that dnf always checks the GPG signature of locally installed software packages before installation: + +$ grep localpkg_gpgcheck /etc/dnf/dnf.conf +localpkg_gpgcheck=1 + +If "localpkg_gpgcheck" is not set to "1" or "True", or if the option is missing or commented out, ask the system administrator how the GPG signatures of local software packages are being verified. + +If there is no process to verify GPG signatures approved by the organization, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>AZLX-23-000120Amazon Linux 2023 must check the GPG signature of software packages originating from external software repositories before installation.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of Amazon Linux 2023. This requirement ensures the software has not been tampered with and that it has been provided by a trusted vendor. + +All software packages must be signed with a cryptographic key recognized and approved by the organization. + +Verifying the authenticity of software prior to installation validates the integrity of the software package received from a vendor. This verifies the software has not been tampered with and that it has been provided by a trusted vendor.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-003992Configure Amazon Linux 2023 to always check the GPG signature of software packages originating from external software repositories before installation. + +Add or update the following line in the [main] section of the /etc/dnf/dnf.conf file: + +gpgcheck=1Verify Amazon Linux 2023 is configured so that dnf always checks the GPG signature of software packages originating from external software repositories before installation: + +$ grep -w gpgcheck /etc/dnf/dnf.conf +gpgcheck=1 + +If "gpgcheck" is not set to "1" or "True", or if the option is missing or commented out, ask the system administrator how the GPG signatures of software packages are being verified. + +If there is no process to verify GPG signatures approved by the organization, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>AZLX-23-000125Amazon Linux 2023 must have GPG signature verification enabled for all software repositories.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of Amazon Linux 2023. This requirement ensures the software has not been tampered with and that it has been provided by a trusted vendor. + +All software packages must be signed with a cryptographic key recognized and approved by the organization. + +Verifying the authenticity of software prior to installation validates the integrity of the software package received from a vendor. This verifies the software has not been tampered with and that it has been provided by a trusted vendor.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-003992Configure Amazon Linux 2023 to verify the signature of packages from a repository prior to installation by setting the following option in the "/etc/yum.repos.d/[your_repo_name].repo" file: + +gpgcheck=1Verify Amazon Linux 2023 software repositories enforce a signature check on the packages prior to allowing installation with the following command: + +$ grep -w gpgcheck /etc/yum.repos.d/*.repo | more +/etc/yum.repos.d/amazonlinux.repo:gpgcheck=1 +/etc/yum.repos.d/amazonlinux.repo:gpgcheck=1 +/etc/yum.repos.d/amazonlinux.repo:gpgcheck=1 +/etc/yum.repos.d/kernel-livepatch.repo:gpgcheck=1 +/etc/yum.repos.d/kernel-livepatch.repo:gpgcheck=1 + +If any repository has "gpgcheck=0" or "False", or if the option is commented out, this is a finding.SRG-OS-000439-GPOS-00195<GroupDescription></GroupDescription>AZLX-23-000130Amazon Linux 2023 must be a vendor-supported release.<VulnDiscussion>An operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002605Configure Amazon Linux 2023 to be a vendor supported release. + +Upgrade to a supported version of Amazon Linux 2023.Verify Amazon Linux 2023 is a vendor-supported version with the following command: + +$ cat /etc/amazon-linux-release +Amazon Linux release 2023.6.20250203 (Amazon Linux) + +If the installed version of Amazon Linux 2023 is not supported, this is a finding.SRG-OS-000269-GPOS-00103<GroupDescription></GroupDescription>AZLX-23-000135Amazon Linux 2023 systemd-journald service must be enabled.<VulnDiscussion>Failure to a known state can address safety or security in accordance with the mission/business needs of the organization. Failure to a known secure state helps prevent a loss of confidentiality, integrity, or availability in the event of a failure of the information system or a component of the system. + +Preserving operating system state information helps to facilitate operating system restart and return to the operational mode of the organization with least disruption to mission/business processes.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001665Configure Amazon Linux 2023 to enable the systemd-journald service with the following command: + +$ sudo systemctl enable --now systemd-journaldVerify Amazon Linux 2023 is configured so that "systemd-journald" is active with the following command: + +$ systemctl is-active systemd-journald +active + +If the systemd-journald service is not active, this is a finding.SRG-OS-000132-GPOS-00067<GroupDescription></GroupDescription>AZLX-23-000200Amazon Linux 2023 must restrict access to the kernel message buffer.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. + +This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DOD or other government agencies. + +There may be shared resources with configurable protections (e.g., files in storage) that may be assessed on specific information system components. + +Restricting access to the kernel message buffer limits access to only root. This prevents attackers from gaining additional system information as a nonprivileged user. + +Satisfies: SRG-OS-000132-GPOS-00067, SRG-OS-000138-GPOS-00069</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001082CCI-001090Configure Amazon Linux 2023 to restrict access to the kernel message buffer. + +Add or edit the following line in a system configuration file, in the "/etc/sysctl.d/" directory: + +kernel.dmesg_restrict = 1 + +Load settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 is configured to restrict access to the kernel message buffer with the following commands: + +Check the status of the kernel.dmesg_restrict kernel parameter. + +$ sudo sysctl kernel.dmesg_restrict +kernel.dmesg_restrict = 1 + +If "kernel.dmesg_restrict" is not set to "1" or is missing, this is a finding.SRG-OS-000132-GPOS-00067<GroupDescription></GroupDescription>AZLX-23-000205Amazon Linux 2023 must prevent kernel profiling by nonprivileged users.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. + +This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DOD or other government agencies. + +There may be shared resources with configurable protections (e.g., files in storage) that may be assessed on specific information system components. + +Setting the kernel.perf_event_paranoid kernel parameter to "2" prevents attackers from gaining additional system information as a nonprivileged user. + +Satisfies: SRG-OS-000132-GPOS-00067, SRG-OS-000138-GPOS-00069</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001082CCI-001090Configure Amazon Linux 2023 to prevent kernel profiling by nonprivileged users. + +Add or edit the following line in a system configuration file, in the "/etc/sysctl.d/" directory: + +kernel.perf_event_paranoid = 2 + +Load settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 is configured to prevent kernel profiling by nonprivileged users with the following commands: + +Check the status of the kernel.perf_event_paranoid kernel parameter. + +$ sudo sysctl kernel.perf_event_paranoid +kernel.perf_event_paranoid = 2 + +If "kernel.perf_event_paranoid" is not set to "2" or is missing, this is a finding.SRG-OS-000132-GPOS-00067<GroupDescription></GroupDescription>AZLX-23-000210Amazon Linux 2023 must restrict exposed kernel pointer addresses access.<VulnDiscussion>Exposing kernel pointers (through procfs or "seq_printf()") exposes kernel writeable structures, which may contain functions pointers. If a write vulnerability occurs in the kernel, allowing write access to any of this structure, the kernel can be compromised. This option disallows any program without the CAP_SYSLOG capability to get the addresses of kernel pointers by replacing them with "0". + +Satisfies: SRG-OS-000132-GPOS-00067, SRG-OS-000433-GPOS-00192</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001082CCI-002824Configure Amazon Linux 2023 to restrict exposed kernel pointer addresses access. + +Add or edit the following line in a system configuration file in the "/etc/sysctl.d/" directory: + +kernel.kptr_restrict = 1 + +Reload settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 restricts exposed kernel pointer addresses access by validating the runtime status of the Amazon Linux 2023 kernel.kptr_restrict kernel parameter with the following command: + +$ sudo sysctl kernel.kptr_restrict +kernel.kptr_restrict = 1 + +If "kernel.kptr_restrict" is not set to "1" or is missing, this is a finding.SRG-OS-000132-GPOS-00067<GroupDescription></GroupDescription>AZLX-23-000215Amazon Linux 2023 must disable access to network bpf system call from nonprivileged processes.<VulnDiscussion>Loading and accessing the packet filters programs and maps using the bpf() system call has the potential of revealing sensitive information about the kernel state.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001082Configure Amazon Linux 2023 to prevent privilege escalation through the kernel by disabling access to the bpf syscall by adding the following line to a file, in the "/etc/sysctl.d" directory: + +kernel.unprivileged_bpf_disabled = 1 + +The system configuration files must be reloaded for the changes to take effect. To reload the contents of the files, run the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 prevents privilege escalation through the kernel by disabling access to the bpf system call with the following commands: + +$ sudo sysctl kernel.unprivileged_bpf_disabled +kernel.unprivileged_bpf_disabled = 1 + +If the returned line does not have a value of "1", or a line is not returned, this is a finding.SRG-OS-000132-GPOS-00067<GroupDescription></GroupDescription>AZLX-23-000220Amazon Linux 2023 must restrict usage of ptrace to descendant processes.<VulnDiscussion>Unrestricted usage of ptrace allows compromised binaries to run ptrace on other processes of the user. Like this, the attacker can steal sensitive information from the target processes (e.g., SSH sessions, web browser, etc.) without any additional assistance from the user (i.e., without resorting to phishing).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001082Configure Amazon Linux 2023 to restrict usage of ptrace to descendant processes by adding the following line to a file, in the "/etc/sysctl.d" directory: + +kernel.yama.ptrace_scope = 1 + +The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 restricts usage of ptrace to descendant processes with the following commands: + +$ sudo sysctl kernel.yama.ptrace_scope +kernel.yama.ptrace_scope = 1 + +If the returned line does not have a value of "1", or a line is not returned, this is a finding.SRG-OS-000433-GPOS-00193<GroupDescription></GroupDescription>AZLX-23-000225Amazon Linux 2023 must implement address space layout randomization (ASLR) to protect its memory from unauthorized code execution.<VulnDiscussion>ASLR makes it more difficult for an attacker to predict the location of attack code they have introduced into a process' address space during an attempt at exploitation. Additionally, ASLR makes it more difficult for an attacker to know the location of existing code to repurpose it using return oriented programming (ROP) techniques.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002824Configure Amazon Linux 2023 to enable ASLR to enhance memory protection. + +Enable ASLR by setting the kernel parameter with the following command: +echo 2 | sudo tee /proc/sys/kernel/randomize_va_space + +Add or edit the following line in a system configuration file in the "/etc/sysctl.d/" directory: + +kernel.randomize_va_space = 2 + +Reload settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 is implementing ASLR with the following command: + +$ sysctl kernel.randomize_va_space +kernel.randomize_va_space = 2 + +Check that the configuration files are present to enable this kernel parameter. +Verify the configuration of the kernel.kptr_restrict kernel parameter with the following command: + +$ sudo /usr/lib/systemd/systemd-sysctl --cat-config | egrep -v '^(#|;)' | grep -F kernel.randomize_va_space | tail -1 + +kernel.randomize_va_space = 2 + +If "kernel.randomize_va_space" is not set to "2" or is missing, this is a finding.SRG-OS-000074-GPOS-00042<GroupDescription></GroupDescription>AZLX-23-000300Amazon Linux 2023 must not have the vsftpd package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). + +Examples of nonessential capabilities include, but are not limited to, games, software packages, tools, and demonstration software, not related to requirements or providing a wide array of functionality not required for every mission, but which cannot be disabled. + +Satisfies: SRG-OS-000074-GPOS-00042, SRG-OS-000095-GPOS-00049</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000197CCI-000381Configure Amazon Linux 2023 to not have the vsftpd package installed with the following command: + +$ sudo dnf -y remove vsftpdVerify Amazon Linux 2023 does not have the vsftpd package installed with the following command: + +$ dnf list --installed vsftpd +Error: No matching Packages to list + +If the "vsftpd" package is installed, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>AZLX-23-000305Amazon Linux 2023 must not have the sendmail package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). + +Examples of nonessential capabilities include, but are not limited to, games, software packages, tools, and demonstration software, not related to requirements or providing a wide array of functionality not required for every mission, but which cannot be disabled.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000381Configure Amazon Linux 2023 to not have the sendmail package installed with the following command: + +$ sudo dnf -y remove sendmailVerify Amazon Linux 2023 does not have the sendmail package installed with the following command: + +$ dnf list --installed sendmail +Error: No matching Packages to list + +If the "sendmail" package is installed, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>AZLX-23-000310Amazon Linux 2023 must not have the nfs-utils package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). + +Examples of nonessential capabilities include, but are not limited to, games, software packages, tools, and demonstration software, not related to requirements or providing a wide array of functionality not required for every mission, but which cannot be disabled.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000381Configure Amazon Linux 2023 to not have the nfs-utils package installed with the following command: + +$ sudo dnf -y remove nfs-utilsVerify Amazon Linux 2023 does not have the nfs-utils package installed with the following command: + +$ dnf list --installed nfs-utils +Error: No matching Packages to list + +If the "nfs-utils" package is installed, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>AZLX-23-000315Amazon Linux 2023 must not have the telnet-server package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). + +Examples of nonessential capabilities include, but are not limited to, games, software packages, tools, and demonstration software, not related to requirements or providing a wide array of functionality not required for every mission, but which cannot be disabled.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000381Configure Amazon Linux 2023 to not have the telnet-server package installed with the following command: + +$ sudo dnf -y remove telnet-serverVerify Amazon Linux 2023 does not have the telnet-server package installed with the following command: + +$ dnf list --installed telnet-server +Error: No matching Packages to list + +If the "telnet-server" package is installed, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>AZLX-23-000320Amazon Linux 2023 must not have the gssproxy package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). + +Examples of nonessential capabilities include, but are not limited to, games, software packages, tools, and demonstration software, not related to requirements or providing a wide array of functionality not required for every mission, but which cannot be disabled.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000381Configure Amazon Linux 2023 to not have the gssproxy package installed. + +The gssproxy package can be removed with the following command: + +$ sudo dnf -y remove gssproxyVerify Amazon Linux 2023 does not have the gssproxy package installed with the following command: + +$ dnf list --installed gssproxy +Error: No matching Packages to list + +If the "gssproxy" package is installed, this is a finding.SRG-OS-000324-GPOS-00125<GroupDescription></GroupDescription>AZLX-23-001000Amazon Linux 2023 must have the sudo package installed.<VulnDiscussion>The "sudo" program is designed to allow a system administrator to give limited root privileges to users and log root activity. The basic philosophy is to give as few privileges as possible but still allow system users to get their work done.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002235Configure Amazon Linux 2023 to have the sudo package installed with the following command: + +$ sudo dnf install -y sudoVerify Amazon Linux 2023 has the sudo package installed with the following command: + +$ dnf list --installed sudo +Installed Packages +sudo.x86_64 1.9.15-1.p5.amzn2023.0.1 @System + +If the "sudo" package is not installed, this is a finding.SRG-OS-000312-GPOS-00123<GroupDescription></GroupDescription>AZLX-23-001005Amazon Linux 2023 must not be configured to bypass password requirements for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. When operating systems provide the capability to escalate a functional capability, it is critical the user reauthenticate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002165Configure Amazon Linux 2023 to require users to supply a password for privilege escalation. + +Remove any occurrences of "pam_succeed_if " in the "/etc/pam.d/sudo" file.Verify Amazon Linux 2023 is not configured to bypass password requirements for privilege escalation with the following command: + +$ sudo grep pam_succeed_if /etc/pam.d/sudo + +If any occurrences of "pam_succeed_if" are returned, this is a finding.SRG-OS-000373-GPOS-00157<GroupDescription></GroupDescription>AZLX-23-001010Amazon Linux 2023 must require reauthentication when using the "sudo" command.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002038Configure Amazon Linux 2023 to reauthenticate "sudo" commands after the specified timeout: + +Add the following line to "/etc/sudoers" or a file in "/etc/sudoers.d": + +Defaults timestamp_timeout=0Verify Amazon Linux 2023 requires reauthentication when using the "sudo" command to elevate privileges with the following command: + +$ sudo grep -ir 'timestamp_timeout' /etc/sudoers /etc/sudoers.d/ +/etc/sudoers:Defaults timestamp_timeout=0 + +If results are returned from more than one file location, this is a finding. + +If "timestamp_timeout" is set to a negative number, is commented out, or no results are returned, this is a finding.SRG-OS-000373-GPOS-00156<GroupDescription></GroupDescription>AZLX-23-001015Amazon Linux 2023 must require users to reauthenticate for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002038Configure Amazon Linux 2023 to not allow users to execute privileged actions without authenticating. + +Remove any occurrence of "!authenticate" found in "/etc/sudoers" file or files in the "/etc/sudoers.d" directory. + +$ sudo sed -i '/\!authenticate/ s/^/# /g' /etc/sudoers /etc/sudoers.d/*Verify Amazon Linux 2023 requires users to reauthenticate for privilege escalation. + +Ensure that "/etc/sudoers" has no occurrences of "!authenticate" with the following command: + +$ sudo grep -ir '!authenticate' /etc/sudoers /etc/sudoers.d/ + +If any occurrences of "!authenticate" are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>AZLX-23-001020Amazon Linux 2023 must require users to provide a password for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000366Configure Amazon Linux 2023 to not allow users to execute privileged actions without authenticating with a password. + +Remove any occurrence of "NOPASSWD" found in "/etc/sudoers" file or files in the "/etc/sudoers.d" directory. + +$ sudo sed -i '/NOPASSWD/ s/^/# /g' /etc/sudoers /etc/sudoers.d/*Verify Amazon Linux 2023 requires users to provide a password for privilege escalation. + +Ensure that "/etc/sudoers" has no occurrences of "NOPASSWD" with the following command: + +$ sudo grep -ri nopasswd /etc/sudoers /etc/sudoers.d/ + +If any occurrences of "NOPASSWD" are returned, this is a finding.SRG-OS-000062-GPOS-00031<GroupDescription></GroupDescription>AZLX-23-001025Amazon Linux 2023 must have the audit package installed.<VulnDiscussion>Successful incident response and auditing relies on timely, accurate system information and analysis to allow the organization to identify and respond to potential incidents in a proficient manner. If Amazon Linux 2023 does not provide the ability to centrally review Amazon Linux 2023 logs, forensic analysis is negatively impacted. + +Segregation of logging data to multiple disparate computer systems is counterproductive and makes log analysis and log event alarming difficult to implement and manage, particularly when the system has multiple logging components writing to different locations or systems. + +To support the centralized capability, Amazon Linux 2023 must be able to provide the information in a format that can be extracted and used, allowing the application performing the centralization of the log records to meet this requirement. + +Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000042-GPOS-00021, SRG-OS-000037-GPOS-00015, SRG-OS-000038-GPOS-00016, SRG-OS-000039-GPOS-00017, SRG-OS-000040-GPOS-00018, SRG-OS-000041-GPOS-00019, SRG-OS-000051-GPOS-00024, SRG-OS-000054-GPOS-00025, SRG-OS-000122-GPOS-00063, SRG-OS-000254-GPOS-00095, SRG-OS-000255-GPOS-00096, SRG-OS-000337-GPOS-00129, SRG-OS-000348-GPOS-00136, SRG-OS-000349-GPOS-00137, SRG-OS-000350-GPOS-00138, SRG-OS-000351-GPOS-00139, SRG-OS-000352-GPOS-00140, SRG-OS-000353-GPOS-00141, SRG-OS-000354-GPOS-00142, SRG-OS-000358-GPOS-00145, SRG-OS-000365-GPOS-00152, SRG-OS-000392-GPOS-00172, SRG-OS-000475-GPOS-00220, SRG-OS-000055-GPOS-00026</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000169CCI-000135CCI-000130CCI-000131CCI-000132CCI-000133CCI-000134CCI-000154CCI-000158CCI-001876CCI-001464CCI-001487CCI-001914CCI-001875CCI-001877CCI-001878CCI-001879CCI-001880CCI-001881CCI-001882CCI-001889CCI-003938CCI-002884CCI-000172CCI-000159Configure Amazon Linux 2023 so that the audit service to produce audit records containing the information needed to establish when (date and time) an event occurred. + +Install the audit service (if the audit service is not already installed) with the following command: + +$ sudo dnf install -y auditVerify Amazon Linux 2023 has the audit package installed with the following command: + +$ dnf list --installed audit +Installed Packages +audit.x86_64 3.0.6-1.amzn2023.0.2 @System + +If the "audit" package is not installed, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-001030Amazon Linux 2023 must produce audit records containing information to establish what type of events occurred.<VulnDiscussion>Without establishing what type of events occurred, it would be difficult to establish, correlate, and investigate the events leading up to an outage or attack. + +Audit record content that may be necessary to satisfy this requirement includes, for example, time stamps, source and destination addresses, user/process identifiers, event descriptions, success/fail indications, filenames involved, and access control or flow control rules invoked. + +Associating event types with detected events in Amazon Linux 2023 audit logs provides a means of investigating an attack; recognizing resource utilization or capacity thresholds; or identifying an improperly configured operating system. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000038-GPOS-00016, SRG-OS-000039-GPOS-00017, SRG-OS-000040-GPOS-00018, SRG-OS-000041-GPOS-00019, SRG-OS-000062-GPOS-00031, SRG-OS-000042-GPOS-00021, SRG-OS-000051-GPOS-00024, SRG-OS-000054-GPOS-00025, SRG-OS-000122-GPOS-00063, SRG-OS-000254-GPOS-00095, SRG-OS-000255-GPOS-00096, SRG-OS-000337-GPOS-00129, SRG-OS-000348-GPOS-00136, SRG-OS-000349-GPOS-00137, SRG-OS-000350-GPOS-00138, SRG-OS-000351-GPOS-00139, SRG-OS-000352-GPOS-00140, SRG-OS-000353-GPOS-00141, SRG-OS-000354-GPOS-00142, SRG-OS-000358-GPOS-00145, SRG-OS-000365-GPOS-00152, SRG-OS-000392-GPOS-00172, SRG-OS-000475-GPOS-00220, SRG-OS-000755-GPOS-00220</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000131CCI-000132CCI-000133CCI-000134CCI-000169CCI-000135CCI-000154CCI-000158CCI-001876CCI-001464CCI-001487CCI-001914CCI-001875CCI-001877CCI-001878CCI-001879CCI-001880CCI-001881CCI-001882CCI-001889CCI-003938CCI-002884CCI-000172CCI-004188Configure Amazon Linux 2023 so that the audit service to produce audit records containing the information needed to establish when an event occurred with the following commands: + +$ sudo systemctl enable auditd.service + +$ sudo systemctl start auditd.serviceVerify Amazon Linux 2023 is configured to produce audit records with the following command: + +$ sudo systemctl status auditd.service +auditd.service - Security Auditing Service + Loaded:loaded (/usr/lib/systemd/system/auditd.service; enabled; preset: enabled) + Active: active (running) since Wed 2024-01-131 12:56:56 EST; 1 weeks 0 days ago + +If the audit service is not "active" and "running", this is a finding.SRG-OS-000342-GPOS-00133<GroupDescription></GroupDescription>AZLX-23-001035Amazon Linux 2023 audispd-plugins package must be installed.<VulnDiscussion>The "audispd-plugins" package provides plugins for the real-time interface to the audit subsystem, "audispd". These plugins can, for example, relay events to remote machines or analyze events for suspicious behavior.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to have the audispd-plugins package installed. + +Install the audispd-plugins package with the following command: + +$ sudo dnf install -y audispd-pluginsVerify Amazon Linux 2023 has the audispd-plugins package installed with the following command: + +$ sudo dnf list --installed audispd-plugins +Installed Packages +audispd-plugins.x86_64 3.0.6-1.amzn2023.0.2 @amazonlinux + +If the "audispd-plugins" package is not installed, this is a finding.SRG-OS-000051-GPOS-00024<GroupDescription></GroupDescription>AZLX-23-001040Amazon Linux 2023 must have the rsyslog package installed.<VulnDiscussion>Successful incident response and auditing relies on timely, accurate system information and analysis allow the organization to identify and respond to potential incidents in a proficient manner. If Amazon Linux 2023 does not provide the ability to centrally review Amazon Linux 2023 logs, forensic analysis is negatively impacted. + +Segregation of logging data to multiple disparate computer systems is counterproductive and makes log analysis and log event alarming difficult to implement and manage, particularly when the system has multiple logging components writing to different locations or systems. + +To support the centralized capability, Amazon Linux 2023 must be able to provide the information in a format that can be extracted and used, allowing the application performing the centralization of the log records to meet this requirement. + +Satisfies: SRG-OS-000051-GPOS-00024, SRG-OS-000479-GPOS-00224</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000154CCI-001851Configure Amazon Linux 2023 to monitor all remote access methods by installing rsyslog with the following command: + +$ sudo dnf install -y rsyslog + +Enable the log service with the following command: + +$ sudo systemctl enable --now rsyslogVerify Amazon Linux 2023 is configured to collect system failure events with the following command: + +$ dnf list --installed rsyslog +Installed Packages +rsyslog.x86_64 8.2204.0-3.amzn2023.0.4 @amazonlinux + +If the "rsyslog" package is not installed, this is a finding. + +Check that the log service is enabled with the following command: + +$ dnf list --installed vsftpd +Error: No matching Packages to list + +If the command above returns "disabled", this is a finding.SRG-OS-000032-GPOS-00013<GroupDescription></GroupDescription>AZLX-23-001045Amazon Linux 2023 must monitor remote access methods.<VulnDiscussion>Remote access services, such as those providing remote access to network devices and information systems, which lack automated monitoring capabilities, increase risk and make remote user access management difficult at best.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000067Configure Amazon Linux 2023 to monitor all remote access methods by installing rsyslog with the following command: + +$ sudo yum install rsyslog + +Then add or update the following lines to the "/etc/rsyslog.conf" file: + +auth.*;authpriv.*;daemon.* /var/log/secure + +The "rsyslog" service must be restarted for the changes to take effect. To restart the "rsyslog" service, run the following command: + +$ sudo systemctl restart rsyslog.serviceVerify Amazon Linux 2023 monitors all remote access methods. + +Check that remote access methods are being logged by running the following command: + +$ sudo grep -E '(auth.*|authpriv.*|daemon.*)' /etc/rsyslog.conf +auth.*;authpriv.*;daemon.* /var/log/secure + +If "auth.*", "authpriv.*", or "daemon.*" are not configured to be logged, this is a finding.SRG-OS-000355-GPOS-00143<GroupDescription></GroupDescription>AZLX-23-001050Amazon Linux 2023 must have the chrony package installed.<VulnDiscussion>Inaccurate time stamps make it more difficult to correlate events and can lead to an inaccurate analysis. Determining the correct time a particular event occurred on a system is critical when conducting forensic analysis and investigating system events. Sources outside the configured acceptable allowance (drift) may be inaccurate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004923Configure Amazon Linux 2023 to have the chrony package installed. + +The chrony package can be installed with the following command: + +$ sudo dnf install -y chronyVerify Amazon Linux 2023 has the chrony package installed with the following command: + +$ sudo dnf list --installed chrony +Installed Packages +chrony.x86_64 4.3-1.amzn2023.0.5 @System + +If the "chrony" package is not installed, this is a finding.SRG-OS-000355-GPOS-00143<GroupDescription></GroupDescription>AZLX-23-001055Amazon Linux 2023 chronyd service must be enabled.<VulnDiscussion>Inaccurate time stamps make it more difficult to correlate events and can lead to an inaccurate analysis. Determining the correct time a particular event occurred on a system is critical when conducting forensic analysis and investigating system events. Sources outside the configured acceptable allowance (drift) may be inaccurate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004923Configure Amazon Linux 2023 to have the chronyd service set to active with the following command: + +$ sudo systemctl enable --now chronydVerify Amazon Linux 2023 has the chronyd service set to active with the following command: + +$ systemctl is-active chronyd +active + +If the chronyd service is not active, this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>AZLX-23-001060Amazon Linux 2023 must have the Advanced Intrusion Detection Environment (AIDE) package installed.<VulnDiscussion>Without verification of the security functions, security functions may not operate correctly, and the failure may go unnoticed. Security function is defined as the hardware, software, and/or firmware of the information system responsible for enforcing the system security policy and supporting the isolation of code and data on which the protection is based. Security functionality includes, but is not limited to, establishing system accounts, configuring access authorizations (i.e., permissions, privileges), setting events to be audited, and setting intrusion detection parameters. + +Satisfies: SRG-OS-000363-GPOS-00150, SRG-OS-000445-GPOS-00199, SRG-OS-000358-GPOS-00145</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001744CCI-002696CCI-001889Configure Amazon Linux 2023 to have the AIDE package installed. + +Install AIDE with the following commands: + +Install AIDE: + +$ sudo dnf install -y aide + +Initialize AIDE: + +$ sudo /usr/sbin/aide --init + +sudo mv /var/lib/aide/aide.db.new.gz /var/lib/aide/aide.db.gz + +Perform a manual check: + +$ sudo /usr/sbin/aide --check +Example output: + +2023-06-05 10:16:08 -0600 (AIDE 0.16) +AIDE found NO differences between database and filesystem. Looks okay!!Verify Amazon Linux 2023 has the AIDE package installed with the following command: + +$ dnf list --installed aide +Installed Packages +aide.x86_64 0.18.6-1.amzn2023.0.1 @amazonlinux + +If AIDE is not installed, ask the system administrator (SA) how file integrity checks are performed on the system. + +If there is no application installed to perform integrity checks, this is a finding. + +If AIDE is installed, check if it has been initialized with the following command: + +$ sudo /usr/sbin/aide --check + +If the output is "Couldn't open file /var/lib/aide/aide.db.gz for reading", this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>AZLX-23-001065Amazon Linux 2023 must routinely check the baseline configuration for unauthorized changes and notify the system administrator when anomalies in the operation of any security functions are discovered.<VulnDiscussion>Unauthorized changes to the baseline configuration could make the system vulnerable to various attacks or allow unauthorized access to Amazon Linux 2023. Changes to operating system configurations can have unintended side effects, some of which may be relevant to security. + +Detecting such changes and providing an automated response can help avoid unintended, negative consequences that could ultimately affect the security state of Amazon Linux 2023. Amazon Linux 2023's information management officer (IMO)/information system security officer (ISSO) and system administrators (SAs) must be notified via email and/or monitoring system trap when there is an unauthorized modification of a configuration item. + +Notifications provided by information systems include messages to local computer consoles, and/or hardware indications, such as lights. + +This capability must take into account operational requirements for availability for selecting an appropriate response. The organization may choose to shut down or restart the information system upon security function anomaly detection. + +Satisfies: SRG-OS-000363-GPOS-00150, SRG-OS-000446-GPOS-00200, SRG-OS-000447-GPOS-00201</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001744CCI-002699CCI-002702Configure Amazon Linux 2023 so that the file integrity tool runs automatically on the system at least weekly and notifies designated personnel if baseline configurations are changed in an unauthorized manner. The AIDE tool can be configured to email designated personnel with the use of the cron system. + +The following example output is generic. It will set cron to run AIDE daily and to send email at the completion of the analysis. + +$ sudo more /etc/cron.daily/aide + +#!/bin/bash +/usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily aide integrity check run" root@sysname.milVerify Amazon Linux 2023 routinely executes a file integrity scan for changes to the system baseline. The commands used in the example will use a daily occurrence. + +Check the cron directories for scripts controlling the execution and notification of results of the file integrity application. For example, if Advanced Intrusion Detection Environment (AIDE) is installed on the system, use the following commands: + +$ ls -al /etc/cron.daily | grep aide +-rwxr-xr-x 1 root root 29 Nov 22 2015 aide + +$ sudo grep aide /etc/crontab /var/spool/cron/root + +/etc/crontab: 30 04 * * * root usr/sbin/aide +/var/spool/cron/root: 30 04 * * * root usr/sbin/aide + +$ sudo more /etc/cron.daily/aide + +#!/bin/bash +/usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily aide integrity check run" root@sysname.mil + +If the file integrity application does not exist, or a script file controlling the execution of the file integrity application does not exist, or the file integrity application does not notify designated personnel of changes, this is a finding.SRG-OS-000256-GPOS-00097<GroupDescription></GroupDescription>AZLX-23-001070Amazon Linux 2023 must use cryptographic mechanisms to protect the integrity of audit tools.<VulnDiscussion>Protecting the integrity of the tools used for auditing purposes is a critical step toward ensuring the integrity of audit information. Audit information includes all information (e.g., audit records, audit settings, and audit reports) needed to successfully audit information system activity. + +Audit tools include, but are not limited to, vendor-provided and open-source audit tools needed to successfully view and manipulate audit information system activity and records. Audit tools include custom queries and report generators. + +It is not uncommon for attackers to replace the audit tools or inject code into the existing tools to provide the capability to hide or erase system activity from the audit logs. + +To address this risk, audit tools must be cryptographically signed to provide the capability to identify when the audit tools have been modified, manipulated, or replaced. An example is a checksum hash of the file or files. + +Satisfies: SRG-OS-000256-GPOS-00097, SRG-OS-000257-GPOS-00098, SRG-OS-000258-GPOS-00099, SRG-OS-000278-GPOS-00108</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001493CCI-001494CCI-001495CCI-001496Configure Amazon Linux 2023 to protect the integrity of the AIDE audit tools. + +Add or update the following lines to "/etc/aide.conf", to protect the integrity of the audit tools. + +/usr/sbin/auditctl p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/auditd p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/ausearch p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/aureport p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/autrace p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/augenrules p+i+n+u+g+s+b+acl+xattrs+sha512Verify Amazon Linux 2023 is properly configured to protect the integrity of the Advanced Intrusion Detection Environment (AIDE) audit tools with the following command: + +$ sudo grep /usr/sbin/au /etc/aide.conf +/usr/sbin/auditctl p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/auditd p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/ausearch p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/aureport p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/autrace p+i+n+u+g+s+b+acl+xattrs+sha512 +/usr/sbin/augenrules p+i+n+u+g+s+b+acl+xattrs+sha512 + +If AIDE is not installed, ask the system administrator (SA) how file integrity checks are performed on the system. + +If any of the audit tools listed above do not have a corresponding line, ask the SA to indicate what cryptographic mechanisms are being used to protect the integrity of the audit tools. + +If there is no evidence of integrity protection, this is a finding.SRG-OS-000096-GPOS-00050<GroupDescription></GroupDescription>AZLX-23-001075Amazon Linux 2023 must have the firewalld package installed.<VulnDiscussion>To prevent unauthorized connection of devices, unauthorized transfer of information, or unauthorized tunneling (i.e., embedding of data types within data types), organizations must disable or restrict unused or unnecessary physical and logical ports/protocols on information systems. + +Operating systems are capable of providing a wide variety of functions and services. Some of the functions and services provided by default may not be necessary to support essential organizational operations. Additionally, it is sometimes convenient to provide multiple services from a single component (e.g., VPN and IPS); however, doing so increases risk over limiting the services provided by any one component. + +To support the requirements and principles of least functionality, Amazon Linux 2023 must support the organizational requirements, providing only essential capabilities and limiting the use of ports, protocols, and/or services to only those required, authorized, and approved to conduct official business or to address authorized quality of life issues. + +Satisfies: SRG-OS-000096-GPOS-00050, SRG-OS-000297-GPOS-00115, SRG-OS-000298-GPOS-00116, SRG-OS-000480-GPOS-00232, SRG-OS-000304-GPOS-00121</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000382CCI-002314CCI-002322CCI-000366CCI-000015Configure Amazon Linux 2023 to have the firewalld package installed with the following command: + +$ sudo dnf install -y firewalldVerify Amazon Linux 2023 has the firewalld package installed with the following command: + +$ dnf list --installed firewalld +Installed Packages +firewalld.noarch 1.2.3-1.amzn2023 @amazonlinux + +If the "firewalld" package is not installed, this is a finding.SRG-OS-000096-GPOS-00050<GroupDescription></GroupDescription>AZLX-23-001080Amazon Linux 2023 must have the firewalld servicew active.<VulnDiscussion>To prevent unauthorized connection of devices, unauthorized transfer of information, or unauthorized tunneling (i.e., embedding of data types within data types), organizations must disable or restrict unused or unnecessary physical and logical ports/protocols on information systems. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services provided by default may not be necessary to support essential organizational operations. Additionally, it is sometimes convenient to provide multiple services from a single component (e.g., VPN and IPS); however, doing so increases risk over limiting the services provided by any one component. + +To support the requirements and principles of least functionality, Amazon Linux 2023 must support the organizational requirements, providing only essential capabilities and limiting the use of ports, protocols, and/or services to only those required, authorized, and approved to conduct official business or to address authorized quality of life issues. + +Satisfies: SRG-OS-000096-GPOS-00050, SRG-OS-000297-GPOS-00115, SRG-OS-000298-GPOS-00116, SRG-OS-000480-GPOS-00232, SRG-OS-000304-GPOS-00121</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000382CCI-002314CCI-002322CCI-000366CCI-000015Configure Amazon Linux 2023 to enable the firewalld service with the following command: + +$ sudo systemctl enable --now firewalldVerify Amazon Linux 2023 firewalld service is active with the following command: + +$ systemctl is-active firewalld +active + +If the "firewalld" service is not active, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>AZLX-23-001085Amazon Linux 2023 must be configured to disable nonessential capabilities.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). + +Examples of nonessential capabilities include, but are not limited to, games, software packages, tools, and demonstration software, not related to requirements or providing a wide array of functionality not required for every mission, but which cannot be disabled.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000381Configure Amazon Linux 2023 to allow approved settings and/or running services to comply with the PPSM CLSA for the site or program and the PPSM CAL. + +To open a port for a service, configure firewalld using the following command: + +$ sudo firewall-cmd --permanent --add-port=port_number/tcp +or +$ sudo firewall-cmd --permanent --add-service=service_nameVerify Amazon Linux 2023 is configured to disable nonessential capabilities. + +Inspect the list of enabled firewall ports and verify they are configured correctly by running the following command: + +$ sudo firewall-cmd --list-all + +Ask the system administrator for the site or program Ports, Protocols, and Services Management Component Local Service Assessment (PPSM CLSA). Verify the services allowed by the firewall match the PPSM CLSA. + +If there are additional ports, protocols, or services that are not in the PPSM CLSA, or there are ports, protocols, or services that are prohibited by the PPSM Category Assurance List (CAL), or there are no firewall rules configured, this is a finding.SRG-OS-000142-GPOS-00071<GroupDescription></GroupDescription>AZLX-23-001090Amazon Linux 2023 must manage excess capacity, bandwidth, or other redundancy to limit the effects of information flooding types of denial-of-service (DoS) attacks.<VulnDiscussion>DoS is a condition when a resource is not available for legitimate users. When this occurs, the organization either cannot accomplish its mission or must operate at degraded capacity. + +Managing excess capacity ensures that sufficient capacity is available to counter flooding attacks. Employing increased capacity and service redundancy may reduce the susceptibility to some DoS attacks. Managing excess capacity may include, for example, establishing selected usage priorities, quotas, or partitioning.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001095Configure Amazon Linux 2023 to manage excess capacity, bandwidth, or other redundancy to limit the effects of information flooding types of DoS attacks. + +Configure "nftables" to be the default "firewallbackend" for "firewalld" by adding or editing the following line in "etc/firewalld/firewalld.conf": + +FirewallBackend=nftables + +Establish rate-limiting rules based on organization-defined types of DoS attacks on impacted network interfaces.Verify Amazon Linux 2023 manages excess capacity, bandwidth, or other redundancy to limit the effects of information flooding types of DoS attacks. + +Verify nftables is configured to allow rate limits on any connection to the system with the following command: + +$ sudo grep -i firewallbackend /etc/firewalld/firewalld.conf +FirewallBackend=nftablesSRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>AZLX-23-001095Amazon Linux 2023 must have the s-nail package installed.<VulnDiscussion>The "s-nail" package provides the mail command required to allow sending email notifications of unauthorized configuration changes to designated personnel.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001744Configure Amazon Linux 2023 to have the s-nail package installed with the following command: + +$ sudo dnf install -y s-nailVerify Amazon Linux 2023 has the "s-nail" package is installed on the system with the following command: + +$ dnf list --installed s-nail +Installed Packages +s-nail.x86_64 14.9.24-6.amzn2023 @amazonlinux + +If the "s-nail" package is not installed, this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>AZLX-23-001105Amazon Linux 2023 must have the libreswan package installed.<VulnDiscussion>Unapproved mechanisms that are used for authentication to the cryptographic module are not verified and therefore, cannot be relied upon to provide confidentiality or integrity, and DOD data may be compromised. + +Operating systems utilizing encryption are required to use FIPS-compliant mechanisms for authenticating to cryptographic modules. + +FIPS 140-2/140-3 is the current standard for validating that mechanisms used to access cryptographic modules utilize authentication that meets DOD requirements. This allows for Security Levels 1, 2, 3, or 4 for use on a general purpose computing system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000803Configure Amazon Linux 2023 to have the libreswan package installed with the following command: + +$ sudo dnf install -y libreswanVerify Amazon Linux 2023 has the libreswan package installed with the following command: + +$ dnf list --installed libreswan +Installed Packages +libreswan.x86_64 4.12-3.amzn2023.0.2 @amazonlinux + +If the "libreswan" package is not installed, this is a finding.SRG-OS-000134-GPOS-00068<GroupDescription></GroupDescription>AZLX-23-001110Amazon Linux 2023 must have the policycoreutils package installed.<VulnDiscussion>An isolation boundary provides access control and protects the integrity of the hardware, software, and firmware that perform security functions. + +Security functions are the hardware, software, and/or firmware of the information system responsible for enforcing the system security policy and supporting the isolation of code and data on which the protection is based. Operating systems implement code separation (i.e., separation of security functions from nonsecurity functions) in a number of ways, including through the provision of security kernels via processor rings or processor modes. For nonkernel code, security function isolation is often achieved through file system protections that serve to protect the code on disk and address space protections that protect executing code. + +Developers and implementers can increase the assurance in security functions by employing well-defined security policy models; structured, disciplined, and rigorous hardware and software development techniques; and sound system/security engineering principles. Implementation may include isolation of memory space and libraries. Operating systems restrict access to security functions through the use of access control mechanisms and by implementing least privilege capabilities.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001084Configure Amazon Linux 2023 to have the policycoreutils package installed with the following command: + +$ sudo dnf install -y policycoreutilsVerify Amazon Linux 2023 has the policycoreutils package installed with the following command: + +$ dnf list --installed policycoreutils +Installed Packages +policycoreutils.x86_64 3.4-6.amzn2023.0.2 @System + +If the "policycoreutils" package is not installed, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>AZLX-23-001115Amazon Linux 2023 must have the pcsc-lite package installed.<VulnDiscussion>The pcsc-lite package must be installed if it is to be available for multifactor authentication using smart cards.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004046Configure Amazon Linux 2023 to have the pcsc-lite package installed with the following command: + +$ sudo dnf install -y pcsc-liteVerify Amazon Linux 2023 has the pcsc-lite package installed with the following command: + +$ dnf list --installed pcsc-lite +Installed Packages +pcsc-lite.x86_64 1.9.1-1.amzn2023.0.4 @amazonlinux + +If the "pcsc-lite" package is not installed, this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>AZLX-23-001120Amazon Linux 2023 must have the packages required for encrypting off-loaded audit logs installed.<VulnDiscussion>Unapproved mechanisms used for authentication to the cryptographic module are not verified and therefore, cannot be relied upon to provide confidentiality or integrity, and DOD data may be compromised. + +Operating systems utilizing encryption are required to use FIPS-compliant mechanisms for authenticating to cryptographic modules. + +FIPS 140-2/140-3 is the current standard for validating that mechanisms used to access cryptographic modules utilize authentication that meets DOD requirements. This allows for Security Levels 1, 2, 3, or 4 for use on a general purpose computing system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000803Configure Amazon Linux 2023 to have the rsyslog-openssl package installed with the following command: + +$ sudo dnf install -y rsyslog-opensslVerify Amazon Linux 2023 has the rsyslog-openssl package installed with the following command: + +$ dnf list --installed rsyslog-openssl +Installed Packages +rsyslog-openssl.x86_64 8.2204.0-3.amzn2023.0.4 @amazonlinux + +If the "rsyslog-openssl" package is not installed, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>AZLX-23-001125Amazon Linux 2023 must have the opensc package installed.<VulnDiscussion>The use of PIV credentials facilitates standardization and reduces the risk of unauthorized access. + +The DOD has mandated the use of the Common Access Card (CAC) to support identity management and personal authentication for systems covered under Homeland Security Presidential Directive (HSPD) 12, as well as making the CAC a primary component of layered protection for national security systems. + +Satisfies: SRG-OS-000375-GPOS-00160, SRG-OS-000376-GPOS-00161</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004046CCI-001953Configure Amazon Linux 2023 to have the opensc package installed with the following command: + +$ sudo dnf install -y openscVerify Amazon Linux 2023 has the opensc package installed with the following command: + +$ sudo dnf list --installed opensc +Installed Packages +opensc.x86_64 0.24.0-1.amzn2023.0.4 @amazonlinux + +If the "opensc" package is not installed, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>AZLX-23-001130Amazon Linux 2023 must have the openssl-pkcs11 package installed.<VulnDiscussion>Without the use of multifactor authentication, the ease of access to privileged functions is greatly increased. Multifactor authentication requires using two or more factors to achieve authentication. A privileged account is defined as an information system account with authorizations of a privileged user. The DOD Common Access Card (CAC) with DOD-approved PKI is an example of multifactor authentication. + +Satisfies: SRG-OS-000375-GPOS-00160, SRG-OS-000376-GPOS-00161, SRG-OS-000377-GPOS-00162</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004046CCI-001953CCI-001954Configure Amazon Linux 2023 to have the openssl-pkcs11 package installed with the following command: + +$ sudo dnf install -y openssl-pkcs11Verify Amazon Linux 2023 has the openssl-pkcs11 package installed with the following command: + +$ dnf list --installed openssl-pkcs11 +Installed Packages +openssl-pkcs11.x86_64 0.4.12-3.amzn2023.0.1 @System + +If the "openssl-pkcs11" package is not installed, this is a finding.SRG-OS-000112-GPOS-00057<GroupDescription></GroupDescription>AZLX-23-001180Amazon Linux 2023 must have SSH installed.<VulnDiscussion>Without protection of the transmitted information, confidentiality and integrity may be compromised because unprotected communications can be intercepted and either read or altered. + +Satisfies: SRG-OS-000112-GPOS-00057, SRG-OS-000113-GPOS-00058, SRG-OS-000423-GPOS-00187, SRG-OS-000424-GPOS-00188, SRG-OS-000425-GPOS-00189, SRG-OS-000426-GPOS-00190</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001941CCI-002418CCI-002421CCI-002420CCI-002422Configure Amazon Linux 2023 to have the openssh-server package installed with the following command: + +$ sudo dnf install -y openssh-serverVerify Amazon Linux 2023 has the openssh-server package installed with the following command: + +$ dnf list --installed openssh-server +Installed Packages +openssh-server.x86_64 8.7p1-8.amzn2023.0.13 @amazonlinux + +If the "openssh-server" package is not installed, this is a finding.SRG-OS-000112-GPOS-00057<GroupDescription></GroupDescription>AZLX-23-001185Amazon Linux 2023 must implement SSH to protect the confidentiality and integrity of transmitted and received information, as well as information during preparation for transmission.<VulnDiscussion>Encrypting information for transmission protects information from unauthorized disclosure and modification. Cryptographic mechanisms implemented to protect information integrity include, for example, cryptographic hash functions that have common application in digital signatures, checksums, and message authentication codes. + +Use of this requirement will be limited to situations where the data owner has a strict requirement for ensuring data integrity and confidentiality is maintained at every step of the data transfer and handling process. When transmitting data, operating systems need to leverage transmission protection mechanisms such as TLS, SSL VPNs, or IPSec. + +Satisfies: SRG-OS-000112-GPOS-00057, SRG-OS-000113-GPOS-00058, SRG-OS-000423-GPOS-00187, SRG-OS-000424-GPOS-00188, SRG-OS-000425-GPOS-00189, SRG-OS-000426-GPOS-00190</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001941CCI-002418CCI-002421CCI-002420CCI-002422Configure Amazon Linux 2023 to enable the sshd service run the following command: + +$ sudo systemctl enable --now sshdVerify Amazon Linux 2023 has "sshd" set to active with the following command: + +$ systemctl is-active sshd +active + +If the "sshd" service is not active, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>AZLX-23-001195Amazon Linux 2023 must have the crypto-policies package installed.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of utilizing encryption to protect data. + +Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000424-GPOS-00188</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002450CCI-002890CCI-003123CCI-002421Configure Amazon Linux 2023 to have the crypto-policies package installed with the following command: + +$ sudo dnf install -y crypto-policiesVerify Amazon Linux 2023 crypto-policies package is installed with the following command: + +$ dnf list --installed crypto-policies +Installed Packages +crypto-policies.noarch 20240828-2.git626aa59.amzn2023.0.1 @System + +If the "crypto-policies" package is not installed, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>AZLX-23-001200Amazon Linux 2023 SSH server must be configured to use systemwide crypto policies.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001453Configure Amazon Linux 2023 so that the SSH daemon uses systemwide crypto policies by running the following commands: + +$ sudo dnf reinstall -y openssh-serverVerify Amazon Linux 2023 employs systemwide crypto policies for SSH with the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*include' +/etc/ssh/sshd_config:Include /etc/ssh/sshd_config.d/*.conf +/etc/ssh/sshd_config.d/50-redhat.conf:Include /etc/crypto-policies/back-ends/opensshserver.config + +If "Include /etc/ssh/sshd_config.d/*.conf" or "Include /etc/crypto-policies/back-ends/opensshserver.config" are not included in the system sshd config or the file /etc/ssh/sshd_config.d/50-redhat.conf is missing, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>AZLX-23-001205Amazon Linux 2023 server must be configured to use only DOD-approved encryption ciphers employing FIPS 140-2/140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + +Amazon Server 2023 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001453Configure Amazon Linux 2023 so that the SSH server uses only ciphers employing FIPS 140-2/140-3 approved algorithms. + +Reinstall crypto-policies with the following command: + +$ sudo dnf -y reinstall crypto-policies + +Set the crypto-policy to FIPS with the following command: + +$ sudo update-crypto-policies --set FIPS +Setting system policy to FIPS + +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify Amazon Linux 2023 SSH server is configured to use only ciphers employing FIPS 140-2/140-3 approved algorithms with the following command: + +$ sudo grep -i Ciphers /etc/crypto-policies/back-ends/opensshserver.config +Ciphers aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr + +If the cipher entries in the "opensshserver.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>AZLX-23-001210Amazon Linux 2023 SSH server must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-2/140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + +Amazon Linux 2023 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001453Configure Amazon Linux 2023 so that the SSH server uses only MACs employing FIPS 140-2/140-3 approved algorithms. + +Reinstall crypto-policies with the following command: + +$ sudo dnf -y reinstall crypto-policies + +Set the crypto-policy to FIPS with the following command: + +$ sudo update-crypto-policies --set FIPS +Setting system policy to FIPS + +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify Amazon Linux 2023 SSH server is configured to use only MACs employing FIPS 140-2/140-3 approved algorithms. + +To verify the MACs in the systemwide SSH configuration file, use the following command: + +$ sudo grep -i MACs /etc/crypto-policies/back-ends/opensshserver.config +MACs hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha2-256,hmac-sha2-512 + +If the MACs entries in the "opensshserver.config" file have any hashes other than "hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha2-256,hmac-sha2-512", or they are missing or commented out, this is a finding.SRG-OS-000364-GPOS-00151<GroupDescription></GroupDescription>AZLX-23-001215Amazon Linux 2023 SSH daemon must not allow Generic Security Service Application Program Interface (GSSAPI) authentication.<VulnDiscussion>GSSAPI authentication is used to provide additional authentication mechanisms to applications. Allowing GSSAPI authentication through SSH exposes the system's GSSAPI to remote hosts, increasing the attack surface of the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001813Configure Amazon Linux 2023 so that the SSH daemon does not allow GSSAPI authentication. + +Add or uncomment the following line to "/etc/ssh/sshd_config" or to a file in "/etc/ssh/sshd_config.d" and set the value to "no": + +GSSAPIAuthentication no + +The SSH service must be restarted for changes to take effect: + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 is configured so that the SSH daemon does not allow GSSAPI authentication with the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*gssapiauthentication' +/etc/ssh/sshd_config.d/50-redhat.conf:GSSAPIAuthentication no + +If the value is returned as "yes", the returned line is commented out, no output is returned, and the use of GSSAPI authentication has not been documented with the information system security officer (ISSO), this is a finding. + +If the required value is not set, this is a finding.SRG-OS-000364-GPOS-00151<GroupDescription></GroupDescription>AZLX-23-001220Amazon Linux 2023 SSH daemon must not allow Kerberos authentication.<VulnDiscussion>Kerberos authentication for SSH is often implemented using Generic Security Service Application Program Interface (GSSAPI). If Kerberos is enabled through SSH, the SSH daemon provides a means of access to the system's Kerberos implementation. Vulnerabilities in the system's Kerberos implementations may be subject to exploitation.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001813Configure Amazon Linux 2023 so that the SSH daemon does not allow Kerberos authentication. + +Add the following line in "/etc/ssh/sshd_config" or to a file in "/etc/ssh/sshd_config.d" or uncomment the line and set the value to "no": + +KerberosAuthentication no + +The SSH service must be restarted for changes to take effect: + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 is configured so that the SSH daemon does not allow Kerberos authentication with the following command: + +$ [ec2-user@ip-172-31-12-63 ~]$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*kerberosauthentication' +/etc/ssh/sshd_config.d/93-KerberosAuthentication.conf:KerberosAuthentication no + +If the value is returned as "yes", the returned line is commented out, no output is returned, and the use of Kerberos authentication has not been documented with the information system security officer (ISSO), this is a finding.SRG-OS-000423-GPOS-00187<GroupDescription></GroupDescription>AZLX-23-001225Amazon Linux 2023 must force a frequent session key renegotiation for SSH connections to the server.<VulnDiscussion>Without protection of the transmitted information, confidentiality and integrity may be compromised because unprotected communications can be intercepted and either read or altered. + +This requirement applies to both internal and external networks and all types of information system components from which information can be transmitted (e.g., servers, mobile devices, notebook computers, printers, copiers, scanners, and facsimile machines). Communication paths outside the physical protection of a controlled boundary are exposed to the possibility of interception and modification. + +Protecting the confidentiality and integrity of organizational information can be accomplished by physical means (e.g., employing physical distribution systems) or by logical means (e.g., employing cryptographic techniques). If physical means of protection are employed, then logical means (cryptography) do not have to be employed, and vice versa. + +Session key regeneration limits the chances of a session key becoming compromised. + +Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000033-GPOS-00014, SRG-OS-000424-GPOS-00188</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002418CCI-000068CCI-002421Configure Amazon Linux 2023 to force a frequent session key renegotiation for SSH connections to the server by adding or modifying the following line in the "/etc/ssh/sshd_config" file or in a file in "/etc/ssh/sshd_config.d": + +RekeyLimit 1G 1h + +Restart the SSH daemon for the settings to take effect. + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 is configured so that the SSH forces frequent session key renegotiation with the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*rekeylimit' +RekeyLimit 1G 1h + +If "RekeyLimit" does not have a maximum data amount and maximum time defined, is missing, or is commented out, this is a finding.SRG-OS-000105-GPOS-00052<GroupDescription></GroupDescription>AZLX-23-001230Amazon Linux 2023 SSHD must accept public key authentication.<VulnDiscussion>Without the use of multifactor authentication, the ease of access to privileged functions is greatly increased. + +Multifactor authentication requires using two or more factors to achieve authentication. + +Factors include: +1. Something a user knows (e.g., password/PIN); +2. Something a user has (e.g., cryptographic identification device, token); and +3. Something a user is (e.g., biometric). + +A privileged account is defined as an information system account with authorizations of a privileged user. + +Network access is defined as access to an information system by a user (or a process acting on behalf of a user) communicating through a network (e.g., local area network, wide area network, or the internet). + +The DOD Common Access Card (CAC) with DOD-approved PKI is an example of multifactor authentication. + +Satisfies: SRG-OS-000105-GPOS-00052, SRG-OS-000106-GPOS-00053, SRG-OS-000107-GPOS-00054, SRG-OS-000108-GPOS-00055</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000765CCI-000766Configure Amazon Linux 2023 to use public key authentication for SSHD by adding or modifying the following line in "/etc/ssh/sshd_config" or in a file in "/etc/ssh/sshd_config.d". + +PubkeyAuthentication yes + +Restart the SSH daemon for the settings to take effect: + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 is configured so that the SSH daemon accepts public key encryption with the following command: + +$ sudo grep -ir PubkeyAuthentication /etc/ssh/sshd_config /etc/ssh/sshd_config.d/ +/etc/ssh/sshd_config:#PubkeyAuthentication yes +/etc/ssh/sshd_config.d/90-PubkeyAuth:PubkeyAuthentication yes + +If "PubkeyAuthentication" is set to no, the line is commented out, or the line is missing, this is a finding.SRG-OS-000106-GPOS-00053<GroupDescription></GroupDescription>AZLX-23-001235Amazon Linux 2023 SSHD must not allow blank passwords.<VulnDiscussion>If an account has an empty password, anyone could log on and run commands with the privileges of that account. Accounts with empty passwords must never be used in operational environments. + +Satisfies: SRG-OS-000106-GPOS-00053, SRG-OS-000480-GPOS-00229</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000766CCI-000366Configure Amazon Linux 2023 to prevent SSH users from logging on with blank passwords. + +Edit the following line in "etc/ssh/sshd_config" or in a file in "/etc/ssh/sshd_config.d": + +PermitEmptyPasswords no + +Restart the SSH daemon for the settings to take effect: + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 remote access using SSH prevents logging on with a blank password with the following command: + +$ sudo grep -ir PermitEmptyPasswords /etc/ssh/sshd_config /etc/ssh/sshd_config.d/ +/etc/ssh/sshd_config:PermitEmptyPasswords no + +If the "PermitEmptyPassword" keyword is set to "yes", is missing, or is commented out, this is a finding.SRG-OS-000109-GPOS-00056<GroupDescription></GroupDescription>AZLX-23-001240Amazon Linux 2023 must not permit direct logons to the root account using remote access via SSH.<VulnDiscussion>To ensure individual accountability and prevent unauthorized access, organizational users must be individually identified and authenticated. Additionally, an additional layer of security is gained by extending the policy of not logging directly on as root, even though the communications channel may be encrypted. + +A group authenticator is a generic account used by multiple individuals. Use of a group authenticator alone does not uniquely identify individual users. Examples of the group authenticator is the Unix OS "root" user account, the Windows "Administrator" account, the "sa" account, or a "helpdesk" account. + +For example, the Unix and Windows operating systems offer a "switch user" capability allowing users to authenticate with their individual credentials and, when needed, switch" to the administrator role. This method provides for unique individual authentication prior to using a group authenticator. + +Users (and any processes acting on behalf of users) need to be uniquely identified and authenticated for all accesses other than those accesses explicitly identified and documented by the organization, which outlines specific user actions that can be performed on Amazon Linux 2023 without identification or authentication. + +Requiring individuals to be authenticated with an individual authenticator prior to using a group authenticator allows for traceability of actions, as well as adding an additional level of protection of the actions that can be taken with group account knowledge.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004045Configure Amazon Linux 2023 to prevent SSH users from logging on directly as root add or modify the following line in "/etc/ssh/sshd_config" or in a file in "/etc/ssh/sshd_config.d". + +PermitRootLogin no + +Restart the SSH daemon for the settings to take effect: + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 remote access using SSH prevents users from logging on directly as "root" with the following command: + +$ sudo grep -ir PermitRootLogin /etc/ssh/sshd_config /etc/ssh/sshd_config.d/ +/etc/ssh/sshd_config:PermitRootLogin no + +If the "PermitRootLogin" keyword is set to "yes", is missing, or is commented out, this is a finding.SRG-OS-000163-GPOS-00072<GroupDescription></GroupDescription>AZLX-23-001245Amazon Linux 2023 must be configured so that all network connections associated with SSH traffic are terminated after 10 minutes of becoming unresponsive.<VulnDiscussion>Terminating an idle session within a short time period reduces the window of opportunity for unauthorized personnel to take control of a management session enabled on the console or console port that has been left unattended. In addition, quickly terminating an idle session will also free up resources committed by the managed network element. + +Terminating network connections associated with communications sessions includes, for example, de-allocating associated TCP/IP address/port pairs at Amazon Linux 2023 level, and de-allocating networking assignments at the application level if multiple application sessions are using a single operating system-level network connection. This does not mean that Amazon Linux 2023 terminates all sessions or network access; it only ends the inactive session and releases the resources associated with that session. + +Satisfies: SRG-OS-000163-GPOS-00072, SRG-OS-000279-GPOS-00109, SRG-OS-000395-GPOS-00175</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001133CCI-002361CCI-002891Configure Amazon Linux 2023 SSH server to terminate a user session automatically after the SSH client has been unresponsive for 10 minutes. + +Note: This setting must be applied in conjunction with "ClientAliveCountMax 1" to function correctly. + +Modify or append the following lines in the "/etc/ssh/sshd_config" or a dropfile in "/etc/ssh/sshd_config.d" file: + +ClientAliveInterval 600 + +For the changes to take effect, the SSH daemon must be restarted. + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 has the "ClientAliveInterval" variable set to a value of "600" or less by performing the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*clientaliveinterval' +/etc/ssh/sshd_config.d/91-ClientAliveInterval.conf:ClientAliveInterval 600 + +If "ClientAliveInterval" does not exist, does not have a value of "600" or less in "/etc/ssh/sshd_config" or a dropfile in "/etc/ssh/sshd_config.d", or is commented out, this is a finding.SRG-OS-000163-GPOS-00072<GroupDescription></GroupDescription>AZLX-23-001250Amazon Linux 2023 must be configured so that all network connections associated with SSH traffic terminate after becoming unresponsive.<VulnDiscussion>Terminating an idle session within a short time period reduces the window of opportunity for unauthorized personnel to take control of a management session enabled on the console or console port that has been left unattended. In addition, quickly terminating an idle session will also free up resources committed by the managed network element. + +Terminating network connections associated with communications sessions includes, for example, de-allocating associated TCP/IP address/port pairs at Amazon Linux 2023 level, and de-allocating networking assignments at the application level if multiple application sessions are using a single operating system-level network connection. This does not mean that Amazon Linux 2023 terminates all sessions or network access; it only ends the inactive session and releases the resources associated with that session. + +Satisfies: SRG-OS-000163-GPOS-00072, SRG-OS-000279-GPOS-00109</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001133CCI-002361Configure Amazon Linux 2023 SSHD to terminate a user session automatically after the SSH client has become unresponsive. + +Note: This setting must be applied in conjunction with AZLX-23-000820 to function correctly. + +Modify or append the following lines in the "/etc/ssh/sshd_config" file or a dropfile in "/etc/ssh/sshd_config.d": + +ClientAliveCountMax 1 + +For the changes to take effect, the SSH daemon must be restarted. + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 SSHD has the "ClientAliveCountMax" set to "1" by performing the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*clientalivecountmax' +/etc/ssh/sshd_config.d/92-ClientAliveCountMax.conf:ClientAliveCountMax 1 + +If "ClientAliveCountMax" do not exist, is not set to a value of "1" in "/etc/ssh/sshd_config" or a dropfile in "/etc/ssh/sshd_config.d" , or is commented out, this is a finding.SRG-OS-000125-GPOS-00065<GroupDescription></GroupDescription>AZLX-23-001255Amazon Linux 2023 must enable the Pluggable Authentication Module (PAM) interface for SSHD.<VulnDiscussion>If maintenance tools are used by unauthorized personnel, they may accidentally or intentionally damage or compromise the system. The act of managing systems and applications includes the ability to access sensitive application information, such as system configuration details, diagnostic information, user information, and potentially sensitive application data. + +Some maintenance and test tools are either standalone devices with their own operating systems or are applications bundled with an operating system. + +Nonlocal maintenance and diagnostic activities are those activities conducted by individuals communicating through a network, either an external network (e.g., the internet) or an internal network. Local maintenance and diagnostic activities are those activities carried out by individuals physically present at the information system or information system component and not communicating across a network connection. Typically, strong authentication requires authenticators that are resistant to replay attacks and employ multifactor authentication. Strong authenticators include, for example, PKI where certificates are stored on a token protected by a password, passphrase, or biometric.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000877Configure Amazon Linux 2023 SSHD to use the UsePAM interface. + +Add or modify the following line in "/etc/ssh/sshd_config": + +UsePAM yes + +Restart the SSH daemon for the settings to take effect: + +$ sudo systemctl restart sshd.serviceVerify Amazon Linux 2023 SSHD is configured to allow for the UsePAM interface with the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*usepam' +/etc/ssh/sshd_config.d/50-redhat.conf:UsePAM yes + +If the "UsePAM" keyword is set to "no", is missing, or is commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>AZLX-23-001260Amazon Linux 2023 must implement DOD-approved encryption in the OpenSSL package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001453Configure Amazon Linux 2023 OpenSSL library to use the system wide cryptographic policy. + +Edit the "/etc/pki/tls/openssl.cnf" and add or modify the following line: + +.include = /etc/crypto-policies/back-ends/opensslcnf.configVerify Amazon Linux 2023 is configured so that the OpenSSL library uses only ciphers employing FIPS 140-2/140-3 approved algorithms with the following command: + +$ sudo grep -i opensslcnf.config /etc/pki/tls/openssl.cnf +.include = /etc/crypto-policies/back-ends/opensslcnf.config + +If the "opensslcnf.config" is not defined in the "/etc/pki/tls/openssl.cnf" file, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>AZLX-23-001265Amazon Linux 2023 must implement DOD-approved TLS encryption in the OpenSSL package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001453Configure Amazon Linux 2023 OpenSSL library to use only DOD-approved TLS encryption by editing the following line in the "/etc/crypto-policies/back-ends/opensslcnf.config" file: + +TLS.MinProtocol = TLSv1.2 +DTLS.MinProtocol = DTLSv1.2 + +A reboot is required for the changes to take effect.Verify Amazon Linux 2023 is configured so that the OpenSSL library uses TLS 1.2 encryption or stronger with following command: + +$ grep -i minprotocol /etc/crypto-policies/back-ends/opensslcnf.config +TLS.MinProtocol = TLSv1.2 +DTLS.MinProtocol = DTLSv1.2 + +If the "TLS.MinProtocol" is set to anything older than "TLSv1.2" or the "DTLS.MinProtocol" is set to anything older than "DTLSv1.2", this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>AZLX-23-001270Amazon Linux 2023 must implement a FIPS 140-2/140-3 compliant systemwide cryptographic policy.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of utilizing encryption to protect data. + +Satisfies: SRG-OS-000120-GPOS-00061, SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000424-GPOS-00188</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000803CCI-002450CCI-002890CCI-003123CCI-002421Configure Amazon Linux 2023 to use a FIPS 140-2/140-3 compliant systemwide cryptographic policy. + +Create subpolicies for enhancements to the systemwide crypto-policy with the following commands: + +Create or edit the SCOPES-AND-WILDCARDS policy module in a text editor and insert options that modify the systemwide cryptographic policy as follows: +$ sudo vi /etc/crypto-policies/policies/modules/SCOPES-AND-WILDCARDS.pmod + +Add the following lines to the policy: +# Disable CHACHA20-POLY1305 for the TLS protocol (OpenSSL, GnuTLS, NSS, and OpenJDK) +cipher@TLS = -CHACHA20-POLY1305 + +# Disable all CBC mode ciphers for the SSH protocol (libssh and OpenSSH) +cipher@SSH = -*-CBC + +Create or edit the OPENSSH-SUBPOLICY module in a text editor and insert options that modify the systemwide crypto-policy as follows: +$ sudo vi /etc/crypto-policies/policies/modules/OPENSSH-SUBPOLICY.pmod + +Add the following lines to the policy: +# Define ciphers for OpenSSH +cipher@SSH=AES-256-GCM AES-128-GCM AES-256-CTR AES-128-CTR + +# Define MACs for OpenSSH +mac@SSH=HMAC-SHA2-512 HMAC-SHA2-256 + +Create or edit the REQUIRE.pmod file and add the following lines to include the subpolicies in the FIPS configuration with the following command: + +$ sudo vi /etc/crypto-policies/policies/modules/REQUIRE.pmod + +Add the following lines to REQUIRE.pmod: +@OPENSSH-SUBPOLICY +@SCOPES-AND-WILDCARDS + +Apply the policy enhancements to the FIPS systemwide cryptographic policy level with the following command: + +$ sudo update-crypto-policies --set FIPS + +Note: If additional subpolicies are being employed, they should be added to the REQUIRE.pmod as well. REQUIRE.pmod is included in the systemwide crypto-policy when it is set. + +To make the cryptographic settings effective for already running services and applications, restart the system: +$ sudo rebootVerify Amazon Linux 2023 is set to use a FIPS 140-2/140-3 compliant systemwide cryptographic policy. + +$ update-crypto-policies --show +FIPS + +If the systemwide crypto policy is not set to "FIPS", this is a finding. + +Inspect the contents of the REQUIRE.pmod file (if it exists) to verify only authorized modifications to the current policy are included with the following command: + +$ cat /etc/crypto-policies/policies/modules/REQUIRE.pmod + +Note: If subpolicies have been configured, they could be listed in a colon-separated list starting with FIPS as follows FIPS:<SUBPOLICY-NAME>:<SUBPOLICY-NAME>. This is not a finding. + +If the AD-SUPPORT subpolicy module is included (e.g., "FIPS:AD-SUPPORT"), and Active Directory support is not documented as an operational requirement with the information system security officer (ISSO), this is a finding. + +If the NO-ENFORCE-EMS subpolicy module is included (e.g., "FIPS:NO-ENFORCE-EMS"), and not enforcing EMS is not documented as an operational requirement with the ISSO, this is a finding. + +Verify the current minimum crypto-policy configuration with the following commands: + +$ grep -E 'rsa_size|hash' /etc/crypto-policies/state/CURRENT.pol +hash = SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512 SHAKE-256 +min_rsa_size = 2048 + +If the "hash" values do not include at least the following FIPS 140-2/140-3 compliant algorithms "SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512 SHAKE-256", this is a finding. + +If there are algorithms that include "SHA1" or a hash value less than "256" this is a finding. + +If the "min_rsa_size" is not set to a value of at least 2048, this is a finding. + +If these commands do not return any output, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>AZLX-23-001275Amazon Linux 2023 must implement DOD-approved encryption to protect the confidentiality of remote access sessions.<VulnDiscussion>Without confidentiality protection mechanisms, unauthorized individuals may gain access to sensitive information via a remote access session. + +Remote access is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Encryption provides a means to secure the remote connection to prevent unauthorized access to the data traversing the remote access connection (e.g., RDP), thereby providing a degree of confidentiality. The encryption strength of a mechanism is selected based on the security categorization of the information.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000068Configure Amazon Linux 2023 SSH server to use only ciphers employing FIPS 140-2/140-3 approved algorithms by updating the "/etc/crypto-policies/back-ends/opensshserver.config" file with the following line: + +Ciphers aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr + +A reboot is required for the changes to take effect.Verify Amazon Linux 2023 is configured so that the SSH server uses only ciphers employing FIPS 140-2/140-3 approved algorithms with the following command: + +$ sudo grep -i ciphers /etc/crypto-policies/back-ends/opensshserver.config +Ciphers aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr + +If the cipher entries in the "opensshserver.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", they are missing, or commented out, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>AZLX-23-001280Amazon Linux 2023 must enable FIPS mode.<VulnDiscussion>Use of weak or untested encryption algorithms undermines the purposes of utilizing encryption to protect data. Amazon Linux 2023 must implement cryptographic modules adhering to the higher standards approved by the federal government since this provides assurance they have been tested and validated. + +Satisfies: SRG-OS-000033-GPOS-00014, SRG-OS-000125-GPOS-00065, SRG-OS-000396-GPOS-00176, SRG-OS-000423-GPOS-00187, SRG-OS-000478-GPOS-00223</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000068CCI-000877CCI-002450CCI-002418Configure Amazon Linux 2023 to implement FIPS mode with the following commands: + +$ sudo fips-mode-setup --enable + +Reboot the system for the changes to take effect.Verify Amazon Linux 2023 is in FIPS mode with the following command: + +$ sudo fips-mode-setup --check +FIPS mode is enabled. + +If FIPS mode is not enabled, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>AZLX-23-001285Amazon Linux 2023 crypto policy must not be overridden.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of utilizing encryption to protect data. + +Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000424-GPOS-00188, SRG-OS-000073-GPOS-00041, SRG-OS-000120-GPOS-00061</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002450CCI-002890CCI-003123CCI-002421CCI-004062CCI-000803Configure Amazon Linux 2023 to correctly implement the systemwide cryptographic policies by reinstalling the crypto-policies package contents. + +Reinstall crypto-policies with the following command: + +$ sudo dnf -y reinstall crypto-policies + +Set the crypto-policy to FIPS with the following command: + +$ sudo update-crypto-policies --set FIPS +Setting system policy to FIPS + +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify Amazon Linux 2023 custom crypto policies are loaded correctly with the following command: + +$ ls -l /etc/crypto-policies/back-ends/ +lrwxrwxrwx. 1 root root 40 Mar 7 19:22 bind.config -> /usr/share/crypto-policies/FIPS/bind.txt +lrwxrwxrwx. 1 root root 42 Mar 7 19:22 gnutls.config -> /usr/share/crypto-policies/FIPS/gnutls.txt +lrwxrwxrwx. 1 root root 40 Mar 7 19:22 java.config -> /usr/share/crypto-policies/FIPS/java.txt +lrwxrwxrwx. 1 root root 46 Mar 7 19:22 javasystem.config -> /usr/share/crypto-policies/FIPS/javasystem.txt +lrwxrwxrwx. 1 root root 40 Mar 7 19:22 krb5.config -> /usr/share/crypto-policies/FIPS/krb5.txt +lrwxrwxrwx. 1 root root 45 Mar 7 19:22 libreswan.config -> /usr/share/crypto-policies/FIPS/libreswan.txt +lrwxrwxrwx. 1 root root 42 Mar 7 19:22 libssh.config -> /usr/share/crypto-policies/FIPS/libssh.txt +-rw-r--r--. 1 root root 398 Mar 7 19:22 nss.config +lrwxrwxrwx. 1 root root 43 Mar 7 19:22 openssh.config -> /usr/share/crypto-policies/FIPS/openssh.txt +lrwxrwxrwx. 1 root root 49 Mar 7 19:22 opensshserver.config -> /usr/share/crypto-policies/FIPS/opensshserver.txt +lrwxrwxrwx. 1 root root 43 Mar 7 19:22 openssl.config -> /usr/share/crypto-policies/FIPS/openssl.txt +lrwxrwxrwx. 1 root root 48 Mar 7 19:22 openssl_fips.config -> /usr/share/crypto-policies/FIPS/openssl_fips.txt +lrwxrwxrwx. 1 root root 46 Mar 7 19:22 opensslcnf.config -> /usr/share/crypto-policies/FIPS/opensslcnf.txt + +If the paths do not point to the respective files under /usr/share/crypto-policies/FIPS path, this is a finding. +Note: nss.config must not be hyperlinked.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>AZLX-23-001290Amazon Linux 2023 must enable certificate-based smart card authentication.<VulnDiscussion>Without the use of multifactor authentication, the ease of access to privileged functions is greatly increased. Multifactor authentication requires using two or more factors to achieve authentication. A privileged account is defined as an information system account with authorizations of a privileged user. The DOD Common Access Card (CAC) with DOD-approved PKI is an example of multifactor authentication. + +Satisfies: SRG-OS-000375-GPOS-00160, SRG-OS-000705-GPOS-00150</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004046CCI-004047Configure Amazon Linux 2023 to have smart cards enabled in SSSD. + +Edit the file "/etc/sssd/sssd.conf" or a configuration file in "/etc/sssd/conf.d" and add or edit the following line: + +pam_cert_auth = TrueNote: If the system administrator demonstrates the use of an approved alternate multifactor authentication method, this requirement is not applicable. + +Verify Amazon Linux 2023 has smart cards enabled in System Security Services Daemon (SSSD), run the following command: + +$ sudo grep -ir pam_cert_auth /etc/sssd/sssd.conf /etc/sssd/conf.d/ +/etc/sssd/sssd.conf:pam_cert_auth = True + +If "pam_cert_auth" is not set to "True", the line is commented out, or the line is missing, this is a finding.SRG-OS-000068-GPOS-00036<GroupDescription></GroupDescription>AZLX-23-001295Amazon Linux 2023 must map the authenticated identity to the user or group account for PKI-based authentication.<VulnDiscussion>Without mapping the certificate used to authenticate to the user account, the ability to determine the identity of the individual user or group will not be available for forensic analysis.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000187Configure Amazon Linux 2023 to map the authenticated identity to the user or group account by adding or modifying the certmap section of the "/etc/sssd/sssd.conf file based on the following example: + +[certmap/testing.test/rule_name] +matchrule =<SAN>.*EDIPI@mil +maprule = (userCertificate;binary={cert!bin}) +domains = testing.test + +The "sssd" service must be restarted for the changes to take effect. To restart the "sssd" service, run the following command: + +$ sudo systemctl restart sssd.serviceNote: If the system administrator (SA) demonstrates the use of an approved alternate multifactor authentication method, this requirement is not applicable. + +Verify the certificate of the user or group is mapped to the corresponding user or group in the "sssd.conf" file with the following command: + +$ sudo find /etc/sssd/sssd.conf /etc/sssd/conf.d/ -type f -exec cat {} \; +[sssd] +config_file_version = 2 +services = pam, sudo, ssh +domains = testing.test + +[pam] +pam_cert_auth = True +offline_credentials_expiration = 1 + +[domain/testing.test] +id_provider = ldap + +[certmap/testing.test/rule_name] +matchrule =<SAN>.*EDIPI@mil +maprule = (userCertificate;binary={cert!bin}) +domains = testing.test + +If the certmap section does not exist, ask the SA to indicate how certificates are mapped to accounts. If there is no evidence of certificate mapping, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>AZLX-23-001300Amazon Linux 2023 must implement certificate status checking for multifactor authentication.<VulnDiscussion>Using an authentication device, such as a DOD Common Access Card (CAC) or token that is separate from the information system, ensures that even if the information system is compromised, credentials stored on the authentication device will not be affected. + +Multifactor solutions that require devices separate from information systems gaining access include, for example, hardware tokens providing time-based or challenge-response authenticators and smart cards such as the U.S. Government Personal Identity Verification (PIV) card and the DOD CAC. + +Amazon Linux 2023 includes multiple options for configuring certificate status checking, but for this requirement focuses on the System Security Services Daemon (SSSD). By default, SSSD performs Online Certificate Status Protocol (OCSP) checking and certificate verification using a sha256 digest function. + +Satisfies: SRG-OS-000375-GPOS-00160, SRG-OS-000377-GPOS-00162</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004046CCI-001954Configure Amazon Linux 2023 to implement certificate status checking for multifactor authentication. + +Review the "/etc/sssd/conf.d/certificate_verification.conf" file to determine if the system is configured to prevent OCSP or certificate verification. + +Add the following line to the "/etc/sssd/conf.d/certificate_verification.conf" file: + +certificate_verification = ocsp_dgst=sha512 + +Set the correct ownership and permissions on the "/etc/sssd/conf.d/certificate_verification.conf" file by running these commands: + +$ sudo chown root:root "/etc/sssd/conf.d/certificate_verification.conf" +$ sudo chmod 600 "/etc/sssd/conf.d/certificate_verification.conf" + +The "sssd" service must be restarted for the changes to take effect. To restart the "sssd" service, run the following command: + +$ sudo systemctl restart sssd.serviceNote: If the system administrator (SA) demonstrates the use of an approved alternate multifactor authentication method, this requirement is not applicable. + +Verify Amazon Linux 2023 implements Online Certificate Status Protocol (OCSP) and is using the proper digest value on the system with the following command: + +$ sudo grep -ir certificate_verification /etc/sssd/sssd.conf /etc/sssd/conf.d/ | grep -v "^#" +certificate_verification = ocsp_dgst=sha512 + +If the certificate_verification line is missing from the [sssd] section, or is missing "ocsp_dgst=sha512", ask the administrator to indicate what type of multifactor authentication is being utilized and how the system implements certificate status checking. + +If there is no evidence of certificate status checking being used, this is a finding.SRG-OS-000383-GPOS-00166<GroupDescription></GroupDescription>AZLX-23-001305Amazon Linux 2023 must prohibit the use of cached authenticators after one day.<VulnDiscussion>If cached authentication information is out-of-date, the validity of the authentication information may be questionable.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002007Configure Amazon Linux 2023 SSSD service to prohibit the use of cached authentications after one day. + +Add or change the following line in "/etc/sssd/sssd.conf" just below the line [pam]: + +offline_credentials_expiration = 1Verify Amazon Linux 2023 is configured so that the System Security Services Daemon (SSSD) prohibits the use of cached authentications after one day. + +Note: Cached authentication settings should be configured even if smart card authentication is not used on the system. + +Check that SSSD allows cached authentications with the following command: + +$ sudo grep -ir cache_credentials /etc/sssd/sssd.conf /etc/sssd/conf.d/ +/etc/sssd/sssd.conf:cache_credentials = true + +If "cache_credentials" is set to "false" or missing from the configuration file, this is not a finding and no further checks are required. + +If "cache_credentials" is set to "true", check that SSSD prohibits the use of cached authentications after one day with the following command: + +$ sudo grep -ir offline_credentials_expiration /etc/sssd/sssd.conf /etc/sssd/conf.d/ +/etc/sssd/sssd.conf:offline_credentials_expiration = 1 + +If "offline_credentials_expiration" is not set to a value of "1", this is a finding.SRG-OS-000066-GPOS-00034<GroupDescription></GroupDescription>AZLX-23-001310Amazon Linux 2023, for PKI-based authentication, must validate certificates by constructing a certification path (which includes status information) to an accepted trust anchor.<VulnDiscussion>Without path validation, an informed trust decision by the relying party cannot be made when presented with any certificate not already explicitly trusted. + +A trust anchor is an authoritative entity represented via a public key and associated data. It is used in the context of public key infrastructures, X.509 digital certificates, and DNSSEC. + +When there is a chain of trust, usually the top entity to be trusted becomes the trust anchor; it can be, for example, a Certification Authority (CA). A certification path starts with the subject certificate and proceeds through a number of intermediate certificates up to a trusted root certificate, typically issued by a trusted CA. + +This requirement verifies that a certification path to an accepted trust anchor is used for certificate validation and that the path includes status information. Path validation is necessary for a relying party to make an informed trust decision when presented with any certificate not already explicitly trusted. Status information for certification paths includes certificate revocation lists or online certificate status protocol responses. Validation of the certificate status information is out of scope for this requirement. + +Satisfies: SRG-OS-000066-GPOS-00034, SRG-OS-000775-GPOS-00230, SRG-OS-000384-GPOS-00167, SRG-OS-000403-GPOS-00182</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000185CCI-004909CCI-004068CCI-002470Configure Amazon Linux 2023 to have valid certificates by using AWS Certificate Manager (ACM) or another certificate manager to manage SSL/TLS certificates. + +In the AWS Management Console, request or import the necessary SSL/TLS certificates into ACM. + +ACM will handle the certificate lifecycle management, including validation and trust chain establishment.Note: If the system administrator (SA) demonstrates the use of an approved alternate multifactor authentication method, this requirement is not applicable. + +Verify Amazon Linux 2023 for PKI-based authentication has valid certificates by constructing a certification path (which includes status information) to an accepted trust anchor. + +Check that the system has a valid DOD root CA installed with the following command: + +$ sudo openssl x509 -text -in /etc/sssd/pki/sssd_auth_ca_db.pem +Certificate: + Data: + Version: 3 (0x2) + Serial Number: 1 (0x1) + Signature Algorithm: sha256WithRSAEncryption + Issuer: C = US, O = U.S. Government, OU = DOD, OU = PKI, CN = DOD Root CA 3 + Validity + Not Before: Mar 20 18:46:41 2012 GMT + Not After : Dec 30 18:46:41 2029 GMT + Subject: C = US, O = U.S. Government, OU = DOD, OU = PKI, CN = DOD Root CA 3 + Subject Public Key Info: + Public Key Algorithm: rsaEncryption + +If the root ca file is not a DOD-issued certificate with a valid date and installed in the /etc/sssd/pki/sssd_auth_ca_db.pem location, this is a finding.SRG-OS-000067-GPOS-00035<GroupDescription></GroupDescription>AZLX-23-001315Amazon Linux 2023, for PKI-based authentication, must enforce authorized access to the corresponding private key.<VulnDiscussion>If the private key is discovered, an attacker can use the key to authenticate as an authorized user and gain access to the network infrastructure. + +The cornerstone of the PKI is the private key used to encrypt or digitally sign information. + +If the private key is stolen, this will lead to the compromise of the authentication and nonrepudiation gained through PKI because the attacker can use the private key to digitally sign documents and pretend to be the authorized user. + +Both the holders of a digital certificate and the issuing authority must protect the computers, storage devices, or whatever they use to keep the private keys.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000186Configure Amazon Linux 2023 SSH private key files to have a passcode. + +Create a new private and public key pair that utilizes a passcode with the following command: + +$ sudo ssh-keygen -n [passphrase]Verify Amazon Linux 2023 SSH private key files have a passcode. + +For each private key stored on the system, use the following command: + +$ sudo ssh-keygen -y -f /path/to/file + +If the contents of the key are displayed, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>AZLX-23-002000Amazon Linux 2023 must display the Standard Mandatory DOD Notice and Consent Banner before granting local or remote access to the system.<VulnDiscussion>Display of a standardized and approved use notification before granting access to Amazon Linux 2023 ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. + +System use notifications are required only for access via logon interfaces with human users and are not required when such human interfaces do not exist. + +The banner must be formatted in accordance with applicable DOD policy. Use the following verbiage for operating systems that can accommodate banners of 1300 characters: + +"You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. + +By using this IS (which includes any device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details." + +Use the following verbiage for operating systems that have severe limitations on the number of characters that can be displayed in the banner: + +"I've read & consent to terms in IS user agreem't."</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000048Configure Amazon Linux 2023 to display the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via the ssh. + +Edit the "/etc/issue" file to replace the default text with the Standard Mandatory DOD Notice and Consent Banner. The DOD-required text is: + +"You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. + +By using this IS (which includes any device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) to protect USG interests -- not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details."Verify Amazon Linux 2023 displays the Standard Mandatory DOD Notice and Consent Banner before granting access to the system over any publicly accessible connection. + +View the file specified by the banner keyword to check that it matches the text of the Standard Mandatory DOD Notice and Consent Banner with the following command: + +$ more /etc/issue + +"You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. By using this IS (which includes any device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details." + +If the system does not display a logon banner or the banner text does not match the Standard Mandatory DOD Notice and Consent Banner, this is a finding.SRG-OS-000228-GPOS-00088<GroupDescription></GroupDescription>AZLX-23-002005Amazon Linux 2023 must display the Standard Mandatory DOD Notice and Consent Banner before granting local or remote access to the system via a SSH logon.<VulnDiscussion>Display of a standardized and approved use notification before granting access to the publicly accessible operating system ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. + +System use notifications are required only for access via logon interfaces with human users and are not required when such human interfaces do not exist. + +The banner must be formatted in accordance with applicable DOD policy. Use the following verbiage for operating systems that can accommodate banners of 1300 characters: + +"You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. + +By using this IS (which includes any device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details." + +Use the following verbiage for operating systems that have severe limitations on the number of characters that can be displayed in the banner: + +"I've read & consent to terms in IS user agreem't."</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001384CCI-001385CCI-001386CCI-001387CCI-001388Configure Amazon Linux 2023 to display the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via ssh. + +Edit the "etc/ssh/sshd_config" file or a file in "/etc/ssh/sshd_config.d" to uncomment the banner keyword and configure it to point to a file that will contain the logon banner (this file may be named differently or be in a different location if using a version of SSH that is provided by a third-party vendor). + +An example configuration line is: + +Banner /etc/issueVerify Amazon Linux 2023 displays the Standard Mandatory DOD Notice and Consent Banner before granting access to the system from any SSH connection. + +Check for the location of the banner file being used with the following command: + +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*banner' +/etc/ssh/sshd_config.d/80-bannerPointer.conf:Banner /etc/issue + +This command will return the banner keyword and the name of the file that contains the SSH banner (in this case "/etc/issue"). + +If the line is commented out, this is a finding.SRG-OS-000341-GPOS-00132<GroupDescription></GroupDescription>AZLX-23-002015Amazon Linux 2023 must allocate audit record storage capacity to store at least one week's worth of audit records, when audit records are not immediately sent to a central audit record storage facility.<VulnDiscussion>To ensure operating systems have a sufficient storage capacity in which to write the audit logs, operating systems must be able to allocate audit record storage capacity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001849Configure Amazon Linux 2023 to provide adequate storage for at least one-week of audit logs when audit records are not immediately sent to a central audit record storage facility. + +If the storage partition is not large enough for at least one week of audit logs, then either: + +1. Resize the partition to ensure there is enough storage capacity. +2. Create a new partition for the audit logs.Verify Amazon Linux 2023 allocates audit record storage capacity to store at least one week of audit records when audit records are not immediately sent to a central audit record storage facility. + +Note: The partition size needed to capture a week of audit records is based on the activity level of the system and the total storage capacity available. Typically 10.0 GB of storage space for audit records should be sufficient. + +Determine which partition the audit records are being written to with the following command: + +$ sudo grep log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Check the size of the partition that audit records are written to with the following command and verify whether it is sufficiently large: + + # df -h /var/log/audit/ +/dev/sda2 24G 10.4G 13.6G 43% /var/log/audit + +If the audit record partition is not allocated for sufficient storage capacity, this is a finding.SRG-OS-000341-GPOS-00132<GroupDescription></GroupDescription>AZLX-23-002020Amazon Linux 2023 must use a separate file system for the system audit data path.<VulnDiscussion>Placing "/var/log/audit" in its own partition enables better separation between audit files and other system files and helps ensure that auditing cannot be halted due to the partition running out of space.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001849Configure Amazon Linux 2023 to have a separate file system/partition for the system audit data path. + +Migrate the system audit data path onto a separate partition.Verify Amazon Linux 2023 has a separate file system/partition created for the system audit data path with the following command: + +Note: /var/log/audit is used as the example as it is a common location. + +$ mount | grep /var/log/audit +UUID=2efb2979-45ac-82d7-0ae632d11f51 on /var/log/home type xfs (rw,realtime,seclabel,attr2,inode64)SRG-OS-000342-GPOS-00133<GroupDescription></GroupDescription>AZLX-23-002025Amazon Linux 2023 must label all off-loaded audit logs before sending them to the central log server.<VulnDiscussion>Enriched logging is needed to determine who, what, and when events occur on a system. Without this, determining root cause of an event will be much more difficult.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to be configured so that the Audit Daemon labels all off-loaded audit logs. + +Edit the /etc/audit/auditd.conf file and add or update the "name_format" option: + +name_format = hostname + +The audit daemon must be restarted for changes to take effect.Verify Amazon Linux 2023 is configured so that the Audit Daemon labels all off-loaded audit logs with the following command: + +$ sudo grep name_format /etc/audit/auditd.conf +name_format = hostname + +If the "name_format" option is not "hostname", "fqd", or "numeric", or the line is commented out, this is a finding.SRG-OS-000342-GPOS-00133<GroupDescription></GroupDescription>AZLX-23-002030Amazon Linux 2023 must take appropriate action when the internal event queue is full.<VulnDiscussion>The audit system should have an action setup in the event the internal event queue becomes full so that no data is lost. Information stored in one location is vulnerable to accidental or incidental deletion or alteration.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 so that the audit system takes an appropriate action when the internal event queue is full. + +Edit the /etc/audit/auditd.conf file and add or update the "overflow_action" option: + +overflow_action = syslog + +The audit daemon must be restarted for changes to take effect.Verify Amazon Linux 2023 audit system is configured to take an appropriate action when the internal event queue is full: + +$ sudo grep -i overflow_action /etc/audit/auditd.conf +overflow_action = syslog + +If the value of the "overflow_action" option is not set to "syslog", "single", "halt" or the line is commented out, ask the system administrator (SA) to indicate how the audit logs are off-loaded to a different system or media. + +If there is no evidence that the transfer of the audit logs being off-loaded to another system or media takes appropriate action if the internal event queue becomes full, this is a finding.SRG-OS-000343-GPOS-00134<GroupDescription></GroupDescription>AZLX-23-002035Amazon Linux 2023 must take action when allocated audit record storage volume reaches 75 percent of the repository maximum audit record storage capacity.<VulnDiscussion>If security personnel are not notified immediately when storage volume reaches 75 percent utilization, they are unable to plan for audit record storage capacity expansion.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001855Configure Amazon Linux 2023 to take action when the audit log storage volume reaches 75 percent of the maximum storage capacity. + +Edit /etc/audit/auditd.conf and ensure the parameter "space_left = 25" is configured.Verify Amazon Linux 2023 takes action when allocated audit record storage volume reaches 75 percent of the repository maximum audit record storage capacity with the following command: + +$ sudo grep -w space_left /etc/audit/auditd.conf +space_left = 25% + +If the value of the "space_left" keyword is not set to 25 percent of the storage volume allocated to audit logs, or if the line is commented out, ask the system administrator (SA) to indicate how the system is providing real-time alerts to the SA and information system security officer (ISSO). If the "space_left" value is not configured to the correct value, this is a finding.SRG-OS-000343-GPOS-00134<GroupDescription></GroupDescription>AZLX-23-002040Amazon Linux 2023 must notify the system administrator (SA) and information system security officer (ISSO) (at a minimum) when allocated audit record storage volume 75 percent utilization.<VulnDiscussion>If security personnel are not notified immediately when storage volume reaches 75 percent utilization, they are unable to plan for audit record storage capacity expansion.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001855Configure Amazon Linux 2023 to initiate an action to notify the SA and ISSO (at a minimum) when allocated audit record storage volume reaches 75 percent of the repository maximum audit record storage capacity by adding/modifying the following line in the /etc/audit/auditd.conf file. + +space_left_action = emailVerify Amazon Linux 2023 notifies the SA and ISSO (at a minimum) when allocated audit record storage volume reaches 75 percent of the repository maximum audit record storage capacity with the following command: + +$ sudo grep -w space_left_action /etc/audit/auditd.conf +space_left_action = email + +If the value of the "space_left_action" is not set to "email", or if the line is commented out, ask the SA to indicate how the system is providing real-time alerts to the SA and ISSO. + +If there is no evidence that real-time alerts are configured on the system, this is a finding.SRG-OS-000343-GPOS-00134<GroupDescription></GroupDescription>AZLX-23-002045Amazon Linux 2023 must take action when allocated audit record storage volume reaches 95 percent of the audit record storage capacity.<VulnDiscussion>If action is not taken when storage volume reaches 95 percent utilization, the auditing system may fail when the storage volume reaches capacity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001855Configure Amazon Linux 2023 to initiate an action when allocated audit record storage volume reaches 95 percent of the repository maximum audit record storage capacity by adding/modifying the following line in the /etc/audit/auditd.conf file. + +admin_space_left = 5%Verify Amazon Linux 2023 takes action when allocated audit record storage volume reaches 95 percent of the repository maximum audit record storage capacity with the following command: + +$ sudo grep -w admin_space_left /etc/audit/auditd.conf +admin_space_left = 5% + +If the value of the "admin_space_left" keyword is not set to 5 percent of the storage volume allocated to audit logs, or if the line is commented out, ask the system administrator (SA) to indicate how the system is taking action if the allocated storage is about to reach capacity. If the "space_left" value is not configured to the correct value, this is a finding.SRG-OS-000343-GPOS-00134<GroupDescription></GroupDescription>AZLX-23-002050Amazon Linux 2023 must take action when allocated audit record storage volume reaches 95 percent of the repository maximum audit record storage capacity.<VulnDiscussion>If action is not taken when storage volume reaches 95 percent utilization, the auditing system may fail when the storage volume reaches capacity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001855Configure Amazon Linux 2023 so that the auditd service takes action in the event of allocated audit record storage volume reaching 95 percent of the repository maximum audit record storage capacity. + +Edit the following line in "/etc/audit/auditd.conf" to ensure that the system is forced into single user mode in the event the audit record storage volume is about to reach maximum capacity: + +admin_space_left_action = single + +The audit daemon must be restarted for changes to take effect.Verify Amazon Linux 2023 is configured to take action in the event of allocated audit record storage volume reaches 95 percent of the repository maximum audit record storage capacity with the following command: + +$ sudo grep admin_space_left_action /etc/audit/auditd.conf +admin_space_left_action = single + +If the value of the "admin_space_left_action" is not set to "single", or if the line is commented out, ask the system administrator (SA) to indicate how the system is providing real-time alerts to the SA and information system security officer (ISSO). + +If there is no evidence that real-time alerts are configured on the system, this is a finding.SRG-OS-000343-GPOS-00134<GroupDescription></GroupDescription>AZLX-23-002055Amazon Linux 2023 must immediately notify the system administrator (SA) and information system security officer (ISSO), at a minimum, of an audit processing failure event.<VulnDiscussion>It is critical for the appropriate personnel to be aware if a system is at risk of failing to process audit logs as required. Without this notification, the security personnel may be unaware of an impending failure of the audit capability, and system operation may be adversely affected. + +Audit processing failures include software/hardware errors, failures in the audit capturing mechanisms, and audit storage capacity being reached or exceeded. + +This requirement applies to each audit data storage repository (i.e., distinct information system component where audit records are stored), the centralized audit storage capacity of organizations (i.e., all audit data storage repositories combined), or both.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001855Configure Amazon Linux 2023 to that the auditd service notifies the SA and ISSO in the event of an audit processing failure. + +Edit the following line in "/etc/audit/auditd.conf" to ensure that administrators are notified via email for those situations: + +action_mail_acct = root + +The audit daemon must be restarted for changes to take effect.Verify Amazon Linux 2023 is configured to notify the SA and/or ISSO (at a minimum) in the event of an audit processing failure with the following command: + +$ sudo grep action_mail_acct /etc/audit/auditd.conf +action_mail_acct = root + +If the value of the "action_mail_acct" keyword is not set to "root" and/or other accounts for security personnel, the "action_mail_acct" keyword is missing, or the retuned line is commented out, ask the SA to indicate how they and the ISSO are notified of an audit process failure. If there is no evidence of the proper personnel being notified of an audit processing failure, this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>AZLX-23-002060Amazon Linux 2023 must be configured to off-load audit records onto a different system from the system being audited via syslog.<VulnDiscussion>The auditd service does not include the ability to send audit records to a centralized server for management directly. However, it can use a plug-in for audit event multiplexor (audispd) to pass audit records to the local syslog server.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to use the audisp-remote syslog service. + +Edit the /etc/audit/plugins.d/syslog.conf file and add or update the "active" option: + +active = yes + +The audit daemon must be restarted for changes to take effect.Verify Amazon Linux 2023 is configured use the audisp-remote syslog service with the following command: + +$ sudo grep active /etc/audit/plugins.d/syslog.conf +active = yes + +If the "active" keyword does not have a value of "yes", the line is commented out, or the line is missing, this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>AZLX-23-002065Amazon Linux 2023 must authenticate the remote logging server for off-loading audit logs via rsyslog.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to authenticate the remote logging server for off-loading audit logs by setting the following option in "/etc/rsyslog.conf" or "/etc/rsyslog.d/[customfile].conf": + +$ActionSendStreamDriverAuthMode x509/nameVerify Amazon Linux 2023 authenticates the remote logging server for off-loading audit logs with the following command: + +$ sudo grep -i '$ActionSendStreamDriverAuthMode' /etc/rsyslog.conf /etc/rsyslog.d/*.conf +/etc/rsyslog.conf:$ActionSendStreamDriverAuthMode x509/name + +If the value of the "$ActionSendStreamDriverAuthMode" option is not set to "x509/name" or the line is commented out, ask the system administrator (SA) to indicate how the audit logs are off-loaded to a different system or media. + +If there is no evidence that the transfer of the audit logs being off-loaded to another system or media is encrypted, this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>AZLX-23-002070Amazon Linux 2023 must encrypt the transfer of audit records off-loaded onto a different system or media from the system being audited via rsyslog.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to encrypt off-loaded audit records via rsyslog by setting the following options in "/etc/rsyslog.conf" or "/etc/rsyslog.d/[customfile].conf": + +$ActionSendStreamDriverMode 1Verify Amazon Linux 2023 encrypts audit records off-loaded onto a different system or media from the system being audited via rsyslog with the following command: + +$ sudo grep -i '$ActionSendStreamDriverMode' /etc/rsyslog.conf /etc/rsyslog.d/*.conf +/etc/rsyslog.conf:$ActionSendStreamDriverMode 1 + +If the value of the "$ActionSendStreamDriverMode" option is not set to "1" or the line is commented out, this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>AZLX-23-002075Amazon Linux 2023 must encrypt via the gtls driver the transfer of audit records off-loaded onto a different system or media from the system being audited via rsyslog.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration. + +Off-loading is a common process in information systems with limited audit storage capacity. + +Support for both internet and Unix domain sockets enables this utility to support both local and remote logging. Coupling this utility with "gnutls" (a secure communications library implementing the SSL, TLS, and DTLS protocols) creates a method to securely encrypt and off-load auditing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to use the ossl driver to encrypt offloaded audit records by setting the following options in "/etc/rsyslog.conf" or "/etc/rsyslog.d/[customfile].conf": + +$DefaultNetstreamDriver osslVerify Amazon Linux 2023 uses the gtls driver to encrypt audit records off-loaded onto a different system or media from the system being audited with the following command: + +$ sudo grep -i '$DefaultNetstreamDriver' /etc/rsyslog.conf /etc/rsyslog.d/*.conf +/etc/rsyslog.conf:$DefaultNetstreamDriver ossl + +If the value of the "$DefaultNetstreamDriver" option is not set to "ossl" or the line is commented out, this is a finding.SRG-OS-000342-GPOS-00133<GroupDescription></GroupDescription>AZLX-23-002080Amazon Linux 2023 must be configured to off-load audit records onto a different system from the system being audited via syslog.<VulnDiscussion>The auditd service does not include the ability to send audit records to a centralized server for management directly. However, it can use a plug-in for audit event multiplexor (audispd) to pass audit records to the local syslog server. + +Satisfies: SRG-OS-000342-GPOS-00133, SRG-OS-000479-GPOS-00224</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to off-load audit records onto a different system or media from the system being audited. + +If using systemd-journal-upload: +Edit "/etc/systemd/journal-upload.conf" with the appropriate configuration: + +[Upload] +URL=https://[server.domain]:[port]Verify Amazon Linux 2023 off-loads audit records onto a different system with the following command: + +$ more /etc/systemd/journal-upload.conf +[Upload] +URL=192.168.21.2 +ServerKeyFile=/etc/ssl/private/journal-upload.pem +ServerCertificateFile=/etc/ssl/certs/journal-upload.pem +TrustedCertificateFile=/etc/ssl/ca/trusted.pem + +If all of the entries do not have values, are commented out, or are missing, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002085Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/sudoers.<VulnDiscussion>The actions taken by system administrators must be audited to keep a record of what was executed on the system, as well as for accountability purposes. Editing the sudoers file may be sign of an attacker trying to establish persistent methods to a system, auditing the editing of the sudoers files mitigates this risk. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/sudoers". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/sudoers -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/sudoers" with the following command: + +$ sudo auditctl -l | grep '/etc/sudoers[^.]' +-w /etc/sudoers -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002090Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/sudoers.d/ directory.<VulnDiscussion>The actions taken by system administrators must be audited to keep a record of what was executed on the system, as well as for accountability purposes. Editing the sudoers file may be sign of an attacker trying to establish persistent methods to a system, auditing the editing of the sudoers files mitigates this risk. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/sudoers.d/". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/sudoers.d/ -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/sudoers.d/" with the following command: + +$ sudo auditctl -l | grep /etc/sudoers.d +-w /etc/sudoers.d/ -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002095Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/group.<VulnDiscussion>In addition to auditing new user and group accounts, these watches will alert the system administrator(s) to any modifications. Any unexpected users, groups, or modifications must be investigated for legitimacy. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/group". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/group -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/group" with the following command: + +$ sudo auditctl -l | egrep '(/etc/group)' +-w /etc/group -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002100Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/gshadow.<VulnDiscussion>In addition to auditing new user and group accounts, these watches will alert the system administrator(s) to any modifications. Any unexpected users, groups, or modifications must be investigated for legitimacy. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/gshadow". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/gshadow -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/gshadow" with the following command: + +$ sudo auditctl -l | egrep '(/etc/gshadow)' +-w /etc/gshadow -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002105Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/opasswd.<VulnDiscussion>In addition to auditing new user and group accounts, these watches will alert the system administrator(s) to any modifications. Any unexpected users, groups, or modifications must be investigated for legitimacy. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/security/opasswd". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/security/opasswd -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/security/opasswd" with the following command: + +$ sudo auditctl -l | egrep '(/etc/security/opasswd)' +-w /etc/security/opasswd -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000326-GPOS-00126<GroupDescription></GroupDescription>AZLX-23-002110Amazon Linux 2023 must audit uses of the "execve" system call.<VulnDiscussion>Misuse of privileged functions, either intentionally or unintentionally by authorized users, or by unauthorized external entities that have compromised information system accounts, is a serious and ongoing concern and can have significant adverse impacts on organizations. Auditing the use of privileged functions is one way to detect such misuse and identify the risk from insider threats and the advanced persistent threat. + +Satisfies: SRG-OS-000326-GPOS-00126, SRG-OS-000327-GPOS-00127</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002233CCI-002234Configure Amazon Linux 2023 to audit the execution of the "execve" system call. + +Add or update the following file system rules to "/etc/audit/rules.d/audit.rules": + +-a always,exit -F arch=b64 -S execve -C uid!=euid -F euid=0 -k execpriv +-a always,exit -F arch=b64 -S execve -C gid!=egid -F egid=0 -k execpriv + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "execve" system call with the following command: + +$ sudo auditctl -l | grep execve +-a always,exit -F arch=b64 -S execve -C uid!=euid -F euid=0 -k execpriv +-a always,exit -F arch=b64 -S execve -C gid!=egid -F egid=0 -k execpriv + +If the command does not return all lines, or the lines are commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002115Amazon Linux 2023 must audit all uses of the chmod, fchmod, and fchmodat system calls.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records upon successful/unsuccessful attempts to use the "chmod", "fchmod", and "fchmodat" syscalls. + +Add or update the following rule in "/etc/audit/rules.d/audit.rules": + +-a always,exit -F arch=b64 -S chmod,fchmod,fchmodat -F auid>=1000 -F auid!=unset -k perm_mod + +To load the rule to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "chmod", "fchmod", and "fchmodat" system calls with the following command: + +$ sudo auditctl -l | grep chmod +-a always,exit -F arch=b64 -S chmod,fchmod,fchmodat -F auid>=1000 -F auid!=unset -k perm_mod + +If the command does not return the expected line, or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002120Amazon Linux 2023 must audit all uses of the chown, fchown, fchownat, and lchown system calls.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records upon successful/unsuccessful attempts to use the "chown", "fchown", "fchownat", and "lchown" system calls. + +Add or update the following rule in "/etc/audit/rules.d/audit.rules": + +-a always,exit -F arch=b64 -S chown,fchown,fchownat,lchown -F auid>=1000 -F auid!=unset -k perm_mod + +To load the rule to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "chown", "fchown", "fchownat", and "lchown" system calls with the following command: + +$ sudo auditctl -l | grep chown +-a always,exit -F arch=b64 -S chown,fchown,fchownat,lchown -F auid>=1000 -F auid!=unset -k perm_mod + +If the command does not return the expected line, or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002125Amazon Linux 2023 must audit all uses of the setxattr, fsetxattr, lsetxattr, removexattr, fremovexattr, and lremovexattr system calls.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000471-GPOS-00216, SRG-OS-000458-GPOS-00203, SRG-OS-000474-GPOS-00219</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to audit the execution of the "setxattr", "fsetxattr", "lsetxattr", "removexattr", "fremovexattr", and "lremovexattr" system calls by adding or updating the following lines to "/etc/audit/rules.d/audit.rules": + +-a always,exit -F arch=b64 -S setxattr,fsetxattr,lsetxattr,removexattr,fremovexattr,lremovexattr -F auid>=1000 -F auid!=unset -k perm_mod + +-a always,exit -F arch=b64 -S setxattr,fsetxattr,lsetxattr,removexattr,fremovexattr,lremovexattr -F auid=0 -k perm_mod + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "setxattr", "fsetxattr", "lsetxattr", "removexattr", "fremovexattr", and "lremovexattr" system calls with the following command: + +$ sudo auditctl -l | grep xattr +-a always,exit -F arch=b64 -S setxattr,fsetxattr,lsetxattr,removexattr,fremovexattr,lremovexattr -F auid>=1000 -F auid!=unset -k perm_mod + +-a always,exit -F arch=b64 -S setxattr,fsetxattr,lsetxattr,removexattr,fremovexattr,lremovexattr -F auid=0 -k perm_mod + +If the audit rules are not defined for the "setxattr", "fsetxattr", "lsetxattr", "removexattr", "fremovexattr", and "lremovexattr" system calls, or any of the lines returned are commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002130Amazon Linux 2023 must audit all uses of the truncate, ftruncate, creat, open, openat, and open_by_handle_at system calls.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate an audit event for any successful/unsuccessful use of the "truncate", "ftruncate", "creat", "open", "openat", and "open_by_handle_at" system calls by adding or updating the following rules in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F arch=b64 -S truncate,ftruncate,creat,open,openat,open_by_handle_at -F exit=-EPERM -F auid>=1000 -F auid!=unset -k perm_access + +-a always,exit -F arch=b64 -S truncate,ftruncate,creat,open,openat,open_by_handle_at -F exit=-EACCES -F auid>=1000 -F auid!=unset -k perm_access + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit successful/unsuccessful attempts to use the "truncate", "ftruncate", "creat", "open", "openat", and "open_by_handle_at" system calls with the following command: + +$ sudo auditctl -l | grep 'open\|truncate\|creat' +-a always,exit -F arch=b64 -S truncate,ftruncate,creat,open,openat,open_by_handle_at -F exit=-EPERM -F auid>=1000 -F auid!=unset -k perm_access + +-a always,exit -F arch=b64 -S truncate,ftruncate,creat,open,openat,open_by_handle_at -F exit=-EACCES -F auid>=1000 -F auid!=unset -k perm_access + +If the output does not produce rules containing "-F exit=-EPERM", this is a finding. + +If the output does not produce rules containing "-F exit=-EACCES", this is a finding. + +If the command does not return an audit rule for "truncate", "ftruncate", "creat", "open", "openat", and "open_by_handle_at" or any of the lines returned are commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002135Amazon Linux 2023 must audit all uses of the init_module and finit_module system calls.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate an audit event for any successful/unsuccessful use of the "init_module" and "finit_module" system calls by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F arch=b64 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng + +To load the rule to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "init_module" and "finit_module" system calls with the following command: + +$ sudo auditctl -l | grep init_module +-a always,exit -F arch=b64 -S init_module,finit_module -F auid>=1000 -F auid!=unset -k module_chng + +If audit rule is not defined for the "delete_module" system call, or the line returned is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002140Amazon Linux 2023 must audit all uses of the create_module system call.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records when successful/unsuccessful attempts to use the "create_module" syscall occur. + +Add or update the following rule in "/etc/audit/rules.d/audit.rules": + +-a always,exit -F arch=b64 -S create_module -F auid>=1000 -F auid!=unset -k module-change + +To load the rule to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records when successful/unsuccessful attempts to use the "create_module" syscall occur with the following command: + +$ sudo auditctl -l | grep "create_module" +-a always,exit -F arch=b64 -S create_module -F auid>=1000 -F auid!=-1 -F key=module-change + +If audit rule is not defined for the "create_module" syscall, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002145Amazon Linux 2023 must audit all uses of the kmod command.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records upon successful/unsuccessful attempts to use the "kmod" command by adding or updating the following rule in "/etc/audit/rules.d/audit.rules": + +-a always,exit -F path=/usr/bin/kmod -F perm=x -F auid>=1000 -F auid!=unset -k modules + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records when successful/unsuccessful attempts to use the "kmod" command occur. + +Check the auditing rules in "/etc/audit/audit.rules" with the following command: + +$ sudo auditctl -l | grep kmod +-a always,exit -F path=/usr/bin/kmod -F perm=x -F auid>=1000 -F auid!=unset -k modules + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002150Amazon Linux 2023 must audit all uses of the rename, unlink, rmdir, renameat, and unlinkat system calls.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000466-GPOS-00210, SRG-OS-000467-GPOS-00211, SRG-OS-000468-GPOS-00212</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate an audit event for any successful/unsuccessful use of the "rename", "unlink", "rmdir", "renameat", and "unlinkat" system calls by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F arch=b64 -S rename,unlink,rmdir,renameat,unlinkat -F auid>=1000 -F auid!=unset -k delete + +To load the rule to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit successful/unsuccessful attempts to use the "rename", "unlink", "rmdir", "renameat", and "unlinkat" system calls with the following command: + +$ sudo auditctl -l | grep 'rename\|unlink\|rmdir' +-a always,exit -F arch=b64 -S rename,unlink,rmdir,renameat,unlinkat -F auid>=1000 -F auid!=unset -k delete + +If the command does not return an audit rule for "rename", "unlink", "rmdir", "renameat", and "unlinkat" or any of the lines returned are commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002155Amazon Linux 2023 must audit all uses of the chcon command.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +When a user logs on, the auid is set to the uid of the account being authenticated. Daemons are not user sessions and have the loginuid set to -1. The auid representation is an unsigned 32-bit integer, which equals 4294967295. The audit system interprets -1, 4294967295, and "unset" in the same way. + +The system call rules are loaded into a matching engine that intercepts each system call made by all programs on the system. Therefore, it is very important to use system call rules only when absolutely necessary since these affect performance. The more rules, the bigger the performance hit. The performance can be helped, however, by combining system calls into one rule whenever possible. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000468-GPOS-00212, SRG-OS-000471-GPOS-00215, SRG-OS-000463-GPOS-00207, SRG-OS-000465-GPOS-00209</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records upon successful/unsuccessful attempts to use the "chcon" command by adding or updating the following rule in "/etc/audit/rules.d/audit.rules": + +-a always,exit -F path=/usr/bin/chcon -F perm=x -F auid>=1000 -F auid!=unset -k perm_mod + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "chcon" command with the following command: + +$ sudo auditctl -l | grep chcon +-a always,exit -F path=/usr/bin/chcon -F perm=x -F auid>=1000 -F auid!=unset -k perm_mod + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000392-GPOS-00172<GroupDescription></GroupDescription>AZLX-23-002160Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /var/log/faillock.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Satisfies: SRG-OS-000392-GPOS-00172, SRG-OS-000470-GPOS-00214, SRG-OS-000473-GPOS-00218</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/var/log/faillock". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /var/log/faillock -p wa -k logins + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/var/log/faillock" with the following command: + +$ sudo auditctl -l | grep /var/log/faillock +-w /var/log/faillock -p wa -k logins + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002165Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /var/log/lastlog.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000473-GPOS-00218, SRG-OS-000470-GPOS-00214</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/var/log/lastlog". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /var/log/lastlog -p wa -k logins + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/var/log/lastlog" with the following command: + +$ sudo auditctl -l | grep /var/log/lastlog +-w /var/log/lastlog -p wa -k logins + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000477-GPOS-00222<GroupDescription></GroupDescription>AZLX-23-002175Amazon Linux 2023 must audit all uses of the init command.<VulnDiscussion>Misuse of the init command may cause availability issues for the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000172Configure Amazon Linux 2023 so that the audit system generates an audit event for any successful/unsuccessful uses of the "init" command by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F path=/usr/sbin/init -F perm=x -F auid>=1000 -F auid!=unset -k privileged-init + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "init" command with the following command: + +$ sudo auditctl -l | grep init +-a always,exit -F path=/usr/sbin/init -F perm=x -F auid>=1000 -F auid!=unset -k privileged-init + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000477-GPOS-00222<GroupDescription></GroupDescription>AZLX-23-002180Amazon Linux 2023 must audit all uses of the reboot command.<VulnDiscussion>Misuse of the reboot command may cause availability issues for the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000172Configure Amazon Linux 2023 so that the audit system generates an audit event for any successful/unsuccessful uses of the "reboot" command by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F path=/usr/sbin/reboot -F perm=x -F auid>=1000 -F auid!=unset -k privileged-reboot + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "reboot" command with the following command: + +$ sudo auditctl -l | grep reboot +-a always,exit -F path=/usr/sbin/reboot -F perm=x -F auid>=1000 -F auid!=unset -k privileged-reboot + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000477-GPOS-00222<GroupDescription></GroupDescription>AZLX-23-002185Amazon Linux 2023 must audit all uses of the shutdown command.<VulnDiscussion>Misuse of the shutdown command may cause availability issues for the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000172Configure Amazon Linux 2023 so that the audit system generates an audit event for any successful/unsuccessful uses of the "shutdown" command by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F path=/usr/sbin/shutdown -F perm=x -F auid>=1000 -F auid!=unset -k privileged-shutdown + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "shutdown" command with the following command: + +$ sudo auditctl -l | grep shutdown +-a always,exit -F path=/usr/sbin/shutdown -F perm=x -F auid>=1000 -F auid!=unset -k privileged-shutdown + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000256-GPOS-00097<GroupDescription></GroupDescription>AZLX-23-002190Amazon Linux 2023 audit tools must have a mode of "0755" or less permissive.<VulnDiscussion>Protecting audit information also includes identifying and protecting the tools used to view and manipulate log data. Therefore, protecting audit tools is necessary to prevent unauthorized operation on audit information. + +Operating systems providing tools to interface with audit information will leverage user permissions and roles identifying the user accessing the tools and the corresponding rights the user enjoys to make access decisions regarding the access to audit tools. + +Audit tools include, but are not limited to, vendor-provided and open source audit tools needed to successfully view and manipulate audit information system activity and records. Audit tools include custom queries and report generators.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001493Configure Amazon Linux 2023 audit tools to have a mode of "0755" by running the following command: + +$ sudo chmod 0755 [audit_tool] + +Replace "[audit_tool]" with each audit tool that has a more permissive mode than "0755".Verify Amazon Linux 2023 audit tools have a mode of "0755" or less with the following command: + +$ stat -c "%a %n" /sbin/auditctl /sbin/aureport /sbin/ausearch /sbin/autrace /sbin/auditd /sbin/rsyslogd /sbin/augenrules +755 /sbin/auditctl +755 /sbin/aureport +755 /sbin/ausearch +750 /sbin/autrace +755 /sbin/auditd +755 /sbin/rsyslogd +755 /sbin/augenrules + +If any of the audit tool files have a mode more permissive than "0755", this is a finding.SRG-OS-000256-GPOS-00097<GroupDescription></GroupDescription>AZLX-23-002195Amazon Linux 2023 audit tools must be owned by root.<VulnDiscussion>Protecting audit information also includes identifying and protecting the tools used to view and manipulate log data. Therefore, protecting audit tools is necessary to prevent unauthorized operation on audit information. + +Operating systems providing tools to interface with audit information will leverage user permissions and roles identifying the user accessing the tools and the corresponding rights the user enjoys to make access decisions regarding the access to audit tools. + +Audit tools include, but are not limited to, vendor-provided and open source audit tools needed to successfully view and manipulate audit information system activity and records. Audit tools include custom queries and report generators.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001493Configure Amazon Linux 2023 audit tools to be owned by "root" by running the following command: + +$ sudo chown root [audit_tool] + +Replace "[audit_tool]" with each audit tool not owned by "root".Verify Amazon Linux 2023 audit tools are owned by "root" with the following command: + +$ sudo stat -c "%U %n" /sbin/auditctl /sbin/aureport /sbin/ausearch /sbin/autrace /sbin/auditd /sbin/rsyslogd /sbin/augenrules +root /sbin/auditctl +root /sbin/aureport +root /sbin/ausearch +root /sbin/autrace +root /sbin/auditd +root /sbin/rsyslogd +root /sbin/augenrules + +If any audit tools do not have an owner of "root", this is a finding.SRG-OS-000256-GPOS-00097<GroupDescription></GroupDescription>AZLX-23-002200Amazon Linux 2023 audit tools must be group-owned by root.<VulnDiscussion>Protecting audit information also includes identifying and protecting the tools used to view and manipulate log data. Therefore, protecting audit tools is necessary to prevent unauthorized operation on audit information. + +Operating systems providing tools to interface with audit information will leverage user permissions and roles identifying the user accessing the tools and the corresponding rights the user enjoys to make access decisions regarding the access to audit tools. + +Audit tools include, but are not limited to, vendor-provided and open source audit tools needed to successfully view and manipulate audit information system activity and records. Audit tools include custom queries and report generators.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001493Configure Amazon Linux 2023 audit tools to be group-owned by "root" by running the following command: + +$ sudo chgrp root [audit_tool] + +Replace "[audit_tool]" with each audit tool not group-owned by "root".Verify Amazon Linux 2023 audit tools are group owned by "root" with the following command: + +$ sudo stat -c "%G %n" /sbin/auditctl /sbin/aureport /sbin/ausearch /sbin/autrace /sbin/auditd /sbin/rsyslogd /sbin/augenrules +root /sbin/auditctl +root /sbin/aureport +root /sbin/ausearch +root /sbin/autrace +root /sbin/auditd +root /sbin/rsyslogd +root /sbin/augenrules + +If any audit tools do not have a group owner of "root", this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002205Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/passwd.<VulnDiscussion>Once an attacker establishes access to a system, the attacker often attempts to create a persistent method of reestablishing access. One way to accomplish this is for the attacker to create an account. Auditing account creation actions provides logging that can be used for forensic purposes. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221, SRG-OS-000274-GPOS-00104, SRG-OS-000275-GPOS-00105, SRG-OS-000276-GPOS-00106, SRG-OS-000277-GPOS-00107</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/passwd". + +Enable the auditd daemon so that it can start at boot time: + +$ sudo systemctl enable auditd + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": +-w /etc/passwd -p wa -k identity + +Then, restart the auditd service for the changes to take effect: + +$ sudo service auditd restartVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/passwd" with the following command: + +$ sudo auditctl -l | egrep '(/etc/passwd)' +-w /etc/passwd -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002210Amazon Linux 2023 must audit all successful/unsuccessful uses of the chage command.<VulnDiscussion>Reconstruction of harmful events or forensic analysis is not possible if audit records do not contain enough information. + +At a minimum, the organization must audit the full-text recording of privileged commands. The organization must maintain audit trails in sufficient detail to reconstruct events to determine the cause and impact of compromise. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000064-GPOS-00033, SRG-OS-000466-GPOS-00210, SRG-OS-000458-GPOS-00203</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172Configure Amazon Linux 2023 so that the audit service generates an audit event for any successful/unsuccessful uses of the "chage" command by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F path=/usr/bin/chage -F perm=x -F auid>=1000 -F auid!=unset -k privileged-chage + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured so that an audit event is generated for any successful/unsuccessful use of the "chage" command by performing the following command to check the file system rules in "/etc/audit/audit.rules": + +$ sudo grep -w chage /etc/audit/audit.rules +-a always,exit -F path=/usr/bin/chage -F perm=x -F auid>=1000 -F auid!=unset -k privileged-chage + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000046-GPOS-00022<GroupDescription></GroupDescription>AZLX-23-002215Amazon Linux 2023 must alert the information system security officer (ISSO) and system administrator (SA), at a minimum, in the event of an audit processing failure.<VulnDiscussion>It is critical for the appropriate personnel to be aware if a system is at risk of failing to process audit logs as required. Without this notification, the security personnel may be unaware of an impending failure of the audit capability, and system operation may be adversely affected. + +Audit processing failures include software/hardware errors, failures in the audit capturing mechanisms, and audit storage capacity being reached or exceeded. + +This requirement applies to each audit data storage repository (i.e., distinct information system component where audit records are stored), the centralized audit storage capacity of organizations (i.e., all audit data storage repositories combined), or both.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000139Configure Amazon Linux 2023 so that the "auditd" service notifies the SA and ISSO in the event of an audit processing failure. + +Edit the following line in "/etc/audit/auditd.conf" to ensure administrators are notified via email for those situations: + +action_mail_acct = rootVerify Amazon Linux 2023 is configured to notify the SA and ISSO, at a minimum, in the event of an audit processing failure with the following command: + +$ sudo grep action_mail_acct /etc/audit/auditd.conf +action_mail_acct = root + +If the value of the "action_mail_acct" keyword is not set to "root" and/or other accounts for security personnel, the "action_mail_acct" keyword is missing, or the retuned line is commented out, ask the SA to indicate how they and the ISSO are notified of an audit process failure. If there is no evidence of the proper personnel being notified of an audit processing failure, this is a finding.SRG-OS-000342-GPOS-00133<GroupDescription></GroupDescription>AZLX-23-002220Amazon Linux 2023 must off-load audit records onto a different system in the event the audit storage volume is full.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration. + +Off-loading is a common process in information systems with limited audit storage capacity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001851Configure Amazon Linux 2023 to off-load audit logs in the event the audit storage volume becomes full. + +Add or update the following line (depending on configuration "disk_full_action" can be set to "SYSLOG" or "SINGLE" depending on configuration) in "/etc/audit/auditd.conf" file: + +disk_full_action = SYSLOGVerify Amazon Linux 2023 takes the appropriate action when the audit storage volume is full using the following command: + +$ sudo grep disk_full_action /etc/audit/auditd.conf +disk_full_action = SYSLOG + +If the value of the "disk_full_action" option is not "SYSLOG", "SINGLE", or "HALT", or the line is commented out, ask the system administrator to indicate how the system takes appropriate action when an audit storage volume is full. If there is no evidence of appropriate action, this is a finding.SRG-OS-000057-GPOS-00027<GroupDescription></GroupDescription>AZLX-23-002225Amazon Linux 2023 audit logs must be group-owned by root or by a restricted logging group to prevent unauthorized read access.<VulnDiscussion>Unauthorized disclosure of audit records can reveal system and configuration data to attackers, thus compromising its confidentiality. + +Audit information includes all information (e.g., audit records, audit settings, audit reports) needed to successfully audit operating system activity. + +Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPOS-00029, SRG-OS-000206-GPOS-00084</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000162CCI-000163CCI-000164CCI-001314Configure Amazon Linux 2023 so that audit logs are group-owned by "root" or a restricted logging group. + +Change the group of the directory of "/var/log/audit" to be owned by a correct group. + +Identify the group that is configured to own audit log: + +$ sudo grep -P '^[ ]*log_group[ ]+=.*$' /etc/audit/auditd.conf + +Change the ownership to that group: + +$ sudo chgrp ${GROUP} /var/log/auditVerify Amazon Linux 2023 audit logs are group-owned by "root" or a restricted logging group. + +First determine if a group other than "root" has been assigned to the audit logs with the following command: + +$ sudo grep log_group /etc/audit/auditd.conf +log_group = root + +Then determine where the audit logs are stored with the following command: + +$ sudo grep -iw log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Then using the location of the audit log file, determine if the audit log is group-owned by "root" using the following command: + +$ sudo stat -c "%G %n" /var/log/audit/audit.log +root /var/log/audit/audit.log + +If the audit log is not group-owned by "root" or the configured alternative logging group, this is a finding.SRG-OS-000057-GPOS-00027<GroupDescription></GroupDescription>AZLX-23-002230Amazon Linux 2023 audit log directory must be owned by root to prevent unauthorized read access.<VulnDiscussion>Unauthorized disclosure of audit records can reveal system and configuration data to attackers, thus compromising its confidentiality. + +Audit information includes all information (e.g., audit records, audit settings, audit reports) needed to successfully audit operating system activity. + +Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPOS-00029, SRG-OS-000206-GPOS-00084</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000162CCI-000163CCI-000164CCI-001314Configure Amazon Linux 2023 so that the audit logs directory is protected from unauthorized read access by setting the correct owner as "root" with the following command: + +$ sudo chown root /var/log/auditVerify Amazon Linux 2023 audit logs directory is owned by "root". + +First determine where the audit logs are stored with the following command: + +$ sudo grep -iw log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Then using the location of the audit log file, determine if the audit log directory is owned by "root" using the following command: + +$ sudo ls -ld /var/log/audit +drwx------ 2 root root 23 Jun 11 11:56 /var/log/audit + +If the audit log directory is not owned by "root", this is a finding.SRG-OS-000057-GPOS-00027<GroupDescription></GroupDescription>AZLX-23-002235Amazon Linux 2023 audit logs file must have mode "0600" or less permissive to prevent unauthorized access to the audit log.<VulnDiscussion>Unauthorized disclosure of audit records can reveal system and configuration data to attackers, thus compromising its confidentiality. + +Audit information includes all information (e.g., audit records, audit settings, audit reports) needed to successfully audit operating system activity. + +Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPOS-00029, SRG-OS-000206-GPOS-00084</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000162CCI-000163CCI-000164CCI-001314Configure Amazon Linux 2023 so that the audit logs have a mode of "0600". + +Replace "[audit_log_file]" to the correct audit log path, by default this location is "/var/log/audit/audit.log". + +$ sudo chmod 0600 /var/log/audit/[audit_log_file] + +Check the group that owns the system audit logs: + +$ sudo grep -iw log_group /etc/audit/auditd.conf + +If the log_group is not defined or it is set to root, configure the permissions as follows: + +$ sudo chmod 0640 $log_file +$ sudo chmod 0440 $log_file.* + +Otherwise, configure the permissions as follows: + +$ sudo chmod 0600 $log_file +$ sudo chmod 0400 $log_file.*Verify Amazon Linux 2023 audit logs have a mode of "0600". + +First determine where the audit logs are stored with the following command: + +$ sudo grep -iw log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Then using the location of the audit log file, determine if the audit log files as a mode of "0640" with the following command: + +$ sudo find /var/log/audit/ -type f -exec stat -c '%a %n' {} \; +600 /var/log/audit/audit.log + +If the audit logs have a mode more permissive than "0600", this is a finding.SRG-OS-000063-GPOS-00032<GroupDescription></GroupDescription>AZLX-23-002240Amazon Linux 2023 must allow only the information system security manager (ISSM) (or individuals or roles appointed by the ISSM) to select which auditable events are to be audited.<VulnDiscussion>Without the capability to restrict which roles and individuals can select which events are audited, unauthorized personnel may be able to prevent the auditing of critical events. Misconfigured audits may degrade the system's performance by overwhelming the audit log. Misconfigured audits may also make it more difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000171Configure Amazon Linux 2023 so that files in "/etc/audit/rules.d/" and the "/etc/audit/auditd.conf" file have a mode of "0640" or less permissive with the following commands: + +$ sudo chmod 0640 /etc/audit/rules.d/audit.rules +$ sudo chmod 0640 /etc/audit/rules.d/[customrulesfile].rules +$ sudo chmod 0640 /etc/audit/auditd.confVerify Amazon Linux 2023 is configured so that files in "/etc/audit/rules.d/" and the "/etc/audit/auditd.conf" file have a mode of "0640" or less permissive by using the following commands: + +$ sudo find /etc/audit/rules.d/ /etc/audit/audit.rules /etc/audit/auditd.conf -type f -exec stat -c "%a %n" {} \; +600 /etc/audit/rules.d/audit.rules +640 /etc/audit/audit.rules +640 /etc/audit/auditd.conf + +If the files in the "/etc/audit/rules.d/" directory or the "/etc/audit/auditd.conf" file have a mode more permissive than "0640", this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002245Amazon Linux 2023 must audit all uses of the sudo command.<VulnDiscussion>Without generating audit records specific to the security and mission needs of the organization, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000064-GPOS-00033, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000466-GPOS-00210, SRG-OS-000471-GPOS-00215</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-000172CCI-002884Configure Amazon Linux 2023 so that the audit system generates an audit event for any successful/unsuccessful use of the "sudo" command by adding or updating the following rule in the "/etc/audit/rules.d/audit.rules" file: + +-a always,exit -F path=/usr/bin/sudo -F perm=x -F auid>=1000 -F auid!=unset -k priv_cmd + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured to audit the execution of the "sudo" command with the following command: + +$ sudo auditctl -l | grep '/usr/bin/sudo\b' +-a always,exit -S all -F path=/usr/bin/sudo -F perm=x -F auid>=1000 -F auid!=-1 -F key=priv_cmd + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002250Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/passwd.<VulnDiscussion>In addition to auditing new user and group accounts, these watches will alert the system administrator(s) (SAs) to any modifications. Any unexpected users, groups, or modifications should be investigated for legitimacy. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221, SRG-OS-000274-GPOS-00104, SRG-OS-000275-GPOS-00105, SRG-OS-000276-GPOS-00106, SRG-OS-000277-GPOS-00107</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/passwd". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/passwd -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/passwd" with the following command: + +$ sudo auditctl -l | egrep '(/etc/passwd)' +-w /etc/passwd -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000004-GPOS-00004<GroupDescription></GroupDescription>AZLX-23-002255Amazon Linux 2023 must generate audit records for all account creations, modifications, disabling, and termination events that affect /etc/shadow.<VulnDiscussion>In addition to auditing new user and group accounts, these watches will alert the system administrator(s) (SAs) to any modifications. Any unexpected users, groups, or modifications should be investigated for legitimacy. + +Satisfies: SRG-OS-000004-GPOS-00004, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000304-GPOS-00121, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000470-GPOS-00214, SRG-OS-000471-GPOS-00215, SRG-OS-000239-GPOS-00089, SRG-OS-000240-GPOS-00090, SRG-OS-000241-GPOS-00091, SRG-OS-000303-GPOS-00120, SRG-OS-000466-GPOS-00210, SRG-OS-000476-GPOS-00221, SRG-OS-000275-GPOS-00105</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000018CCI-000130CCI-000135CCI-000169CCI-000015CCI-002884CCI-000172CCI-001403CCI-001404CCI-001405CCI-002130Configure Amazon Linux 2023 to generate audit records for all account creations, modifications, disabling, and termination events that affect "/etc/shadow". + +Add or update the following file system rule to "/etc/audit/rules.d/audit.rules": + +-w /etc/shadow -p wa -k identity + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 generates audit records for all account creations, modifications, disabling, and termination events that affect "/etc/shadow with the following command: + +$ sudo auditctl -l | egrep '(/etc/shadow)' +-w /etc/shadow -p wa -k identity + +If the command does not return a line, or the line is commented out, this is a finding.SRG-OS-000255-GPOS-00096<GroupDescription></GroupDescription>AZLX-23-002260Amazon Linux 2023 must produce audit records containing information to establish the identity of any individual or process associated with the event.<VulnDiscussion>Without information that establishes the identity of the subjects (i.e., users or processes acting on behalf of users) associated with the events, security personnel cannot determine responsibility for the potentially harmful event.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001487Configure Amazon Linux 2023 so that the audit system resolves audit information before writing to disk. + +Edit the /etc/audit/auditd.conf file and add or update the "log_format" option: + +log_format = ENRICHED + +The audit daemon must be restarted for changes to take effect.Verify Amazon Linux 2023 is configured so that the audit system resolves audit information before writing to disk, with the following command: + +$ sudo grep log_format /etc/audit/auditd.conf +log_format = ENRICHED + +If the "log_format" option is not "ENRICHED", or the line is commented out, this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002265Amazon Linux 2023 audit logs must be group-owned by root or by a restricted logging group to prevent unauthorized read access.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 to change the group of the directory of "/var/log/audit" to be owned by a correct group. + +Identify the group that is configured to own audit log: + +$ sudo grep -P '^[ ]*log_group[ ]+=.*$' /etc/audit/auditd.conf + +Change the ownership to that group: + +$ sudo chgrp ${GROUP} /var/log/auditVerify Amazon Linux 2023 is configured so that the audit logs are group-owned by "root" or a restricted logging group. + +First determine if a group other than "root" has been assigned to the audit logs with the following command: + +$ sudo grep log_group /etc/audit/auditd.conf + +Then determine where the audit logs are stored with the following command: + +$ sudo grep -iw log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Then using the location of the audit log file, determine if the audit log is group-owned by "root" using the following command: + +$ sudo stat -c "%G %n" /var/log/audit/audit.log +root /var/log/audit/audit.log + +If the audit log is not group-owned by "root" or the configured alternative logging group, this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002270Amazon Linux 2023 must ensure the audit log directory be owned by root to prevent unauthorized read access.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 audit logs to be protected from unauthorized read access by setting the correct owner as "root" with the following command: + +$ sudo chown root /var/log/auditVerify Amazon Linux 2023 is configured so that the audit logs directory is owned by "root". + +First determine where the audit logs are stored with the following command: + +$ sudo grep -iw log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Then using the location of the audit log file, determine if the audit log directory is owned by "root" using the following command: + +sudo stat -c '%U %n' /var/log/audit +root /var/log/audit + +If the audit log directory is not owned by "root", this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002275Amazon Linux 2023 audit logs file must have mode "0600" or less permissive to prevent unauthorized access to the audit log.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 audit logs to have a mode of "0600" with the following command: + +Replace "[audit_log_file]" to the correct audit log path, by default this location is "/var/log/audit/audit.log". + +$ sudo chmod 0600 /var/log/audit/[audit_log_file] + +Check the group that owns the system audit logs: + +$ sudo grep -m 1 -q ^log_group /etc/audit/auditd.conf + +If the log_group is not defined or it is set to root, configure the permissions as follows: + +$ sudo chmod 0640 $log_file +$ sudo chmod 0440 $log_file.* + +Otherwise, configure the permissions as follows: + +$ sudo chmod 0600 $log_file +$ sudo chmod 0400 $log_file.*Verify Amazon Linux 2023 is configured so that the audit logs have a mode of "0600". + +First determine where the audit logs are stored with the following command: + +$ sudo grep -iw log_file /etc/audit/auditd.conf +log_file = /var/log/audit/audit.log + +Then using the location of the audit log file, determine if the audit log files as a mode of "0640" with the following command: + +$ sudo find /var/log/audit/ -type f -exec stat -c '%a %n' {} \; +600 /var/log/audit/audit.log + +If the audit logs have a mode more permissive than "0600", this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002280Amazon Linux 2023 library directories must be group-owned by root or a system account.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 systemwide shared library directories (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. + +Run the following command, replacing "[DIRECTORY]" with any library directory not group-owned by "root". + +$ sudo chgrp root [DIRECTORY]Verify Amazon Linux 2023 systemwide shared library directories are group-owned by "root" with the following command: + +$ sudo find /lib /lib64 /usr/lib /usr/lib64 ! -group root -type d -exec stat -c "%n %G" '{}' \; + +If any systemwide shared library directory is returned and is not group-owned by a required system account, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002285Amazon Linux 2023 library directories must have mode "755" or less permissive.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 systemwide shared library directories (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. + +Run the following command, replacing "[DIRECTORY]" with any library directory with a mode more permissive than "755". + +$ sudo chmod 755 [DIRECTORY]Verify Amazon Linux 2023 systemwide shared library directories have mode "755" or less permissive with the following command: + +$ sudo find -L /lib /lib64 /usr/lib /usr/lib64 -perm /022 -type d -exec ls -l {} \; + +If any systemwide shared library file is found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002290Amazon Linux 2023 library files must have mode "755" or less permissive.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges. Only qualified and authorized individuals will be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 library files to be protected from unauthorized access. Run the following command, replacing "[FILE]" with any library file with a mode more permissive than "755". + +$ sudo chmod 755 [FILE]Verify Amazon Linux 2023 systemwide shared library files contained in the following directories have mode "755" or less permissive with the following command: + +$ sudo find -L /lib /lib64 /usr/lib /usr/lib64 -perm /022 -type f -exec ls -l {} \; + +If any systemwide shared library file is found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002295Amazon Linux 2023 library files must be owned by root.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 systemwide shared library files (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. + +Run the following command, replacing "[FILE]" with any library file not owned by "root". + +$ sudo chown root [FILE]Verify Amazon Linux 2023 systemwide shared library files are owned by "root" with the following command: + +$ sudo find -L /lib /lib64 /usr/lib /usr/lib64 ! -user root -exec ls -l {} \; + +If any systemwide shared library file is not owned by root, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002300Amazon Linux 2023 library files must be group-owned by root or a system account.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 systemwide shared library files (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. + +Run the following command, replacing "[FILE]" with any library file not group-owned by "root". + +$ sudo chgrp root [FILE]Verify Amazon Linux 2023 systemwide shared library files are group-owned by "root" with the following command: + +$ sudo find -L /lib /lib64 /usr/lib /usr/lib64 ! -group root -exec ls -l {} \; + +If any systemwide shared library file is returned and is not group-owned by a required system account, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002305Amazon Linux 2023 library directories must be owned by root.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 systemwide shared library directories within (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. + +Run the following command, replacing "[DIRECTORY]" with any library directory not owned by "root". + +$ sudo chown root [DIRECTORY]Verify Amazon Linux 2023 systemwide shared library directories are owned by "root" with the following command: + +$ sudo find /lib /lib64 /usr/lib /usr/lib64 ! -user root -type d -exec stat -c "%n %U" '{}' \; + +If any systemwide shared library directory is not owned by root, this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002315Amazon Linux 2023 must ensure the /var/log directory have mode "0755" or less permissive.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 so that the "/var/log" directory has a mode of "0755" by running the following command: + +$ sudo chmod 0755 /var/logVerify Amazon Linux 2023 is configured so that the "/var/log" directory has a mode of "0755" or less permissive with the following command: + +$ stat -c '%a %n' /var/log +755 /var/log + +If "/var/log" does not have a mode of "0755" or less permissive, this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002320Amazon Linux 2023 must ensure the /var/log directory be owned by root.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 so that the directory "/var/log" is owned by "root" with the following command: + +$ sudo chown root /var/logVerify Amazon Linux 2023 is configured so that the "/var/log" directory is owned by root with the following command: + +$ stat -c "%U %n" /var/log +root /var/log + +If "/var/log" does not have an owner of "root", this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002325Amazon Linux 2023 must ensure the /var/log directory be group-owned by root.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 so that the "/var/log" is group-owned "root" with the following command: + +$ sudo chgrp root /var/logVerify Amazon Linux 2023 is configured so the "/var/log" directory is group-owned by root with the following command: + +$ stat -c "%G %n" /var/log +root /var/log + +If "/var/log" does not have a group owner of "root", this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002330Amazon Linux 2023 must ensure the /var/log/messages file have mode "0640" or less permissive.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 so that the "/var/log/messages" file has a mode of "0640" with the following command: + +$ sudo chmod 0640 /var/log/messagesVerify Amazon Linux 2023 is configured so that the "/var/log/messages" file has a mode of "0640" or less permissive with the following command: + +$ stat -c '%a %n' /var/log/messages +600 /var/log/messages + +If "/var/log/messages" does not have a mode of "0640" or less permissive, this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002335Amazon Linux 2023 must ensure the /var/log/messages file be group-owned by root.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 so that the "/var/log/messages" file is group-owned "root" with the following command: + +$ sudo chgrp root /var/log/messagesVerify Amazon Linux 2023 is configured so that the "/var/log/messages" file is group-owned by root with the following command: + +$ stat -c "%G %n" /var/log/messages +root /var/log/messages + +If "/var/log/messages" does not have a group owner of "root", this is a finding.SRG-OS-000206-GPOS-00084<GroupDescription></GroupDescription>AZLX-23-002340Amazon Linux 2023 must ensure the /var/log/messages file be owned by root.<VulnDiscussion>Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify Amazon Linux 2023 or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. + +The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001314Configure Amazon Linux 2023 so that the "/var/log/messages" file is owned by "root" with the following command: + +$ sudo chown root /var/log/messagesVerify Amazon Linux 2023 is configured so that the "/var/log/messages" file is owned by root with the following command: + +$ stat -c "%U %n" /var/log/messages +root /var/log/messages + +If "/var/log/messages" does not have an owner of "root", this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002345Amazon Linux 2023 system commands must be owned by root.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 so that system commands are protected from unauthorized access. + +Run the following command, replacing "[FILE]" with any system command file not owned by "root". + +$ sudo chown root [FILE]Verify Amazon Linux 2023 system commands contained in the following directories are owned by "root" with the following command: + +$ sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/libexec /usr/local/bin /usr/local/sbin ! -user root -exec ls -l {} \; + +If any system commands are found to not be owned by root, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>AZLX-23-002350Amazon Linux 2023 system commands must be group-owned by root or a system account.<VulnDiscussion>If Amazon Linux 2023 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. + +This requirement applies to operating systems with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals shall be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001499Configure Amazon Linux 2023 so that system commands are protected from unauthorized access. + +Run the following command, replacing "[FILE]" with any system command file not group-owned by "root" or a required system account. + +$ sudo chgrp root [FILE]Verify Amazon Linux 2023 system commands contained in the following directories are group-owned by "root", or a required system account, with the following command: + +$ sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -group root -exec ls -l {} \; + +If any system commands are returned and is not group-owned by a required system account, this is a finding.SRG-OS-000069-GPOS-00037<GroupDescription></GroupDescription>AZLX-23-002355Amazon Linux 2023 must enforce password complexity by requiring that at least one uppercase character be used.<VulnDiscussion>Use of a complex password helps to increase the time and resources required to compromise the password. Password complexity, or strength, is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. + +Password complexity is one factor of several that determines how long it takes to crack a password. The more complex the password, the greater the number of possible combinations that need to be tested before the password is compromised. + +Satisfies: SRG-OS-000069-GPOS-00037, SRG-OS-000725-GPOS-00180</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-004064Configure Amazon Linux 2023 to enforce password complexity by requiring that at least one uppercase character be used by setting the "ucredit" option. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "ucredit" parameter: + +ucredit = -1 + +Remove any configurations that conflict with the above value.Verify Amazon Linux 2023 enforces password complexity by requiring that at least one uppercase character with the following command: + +$ sudo grep ucredit /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +ucredit = -1 + +If the value of "ucredit" is a positive number or is commented out, this is a finding.SRG-OS-000070-GPOS-00038<GroupDescription></GroupDescription>AZLX-23-002360Amazon Linux 2023 must enforce password complexity by requiring that at least one lowercase character be used.<VulnDiscussion>Use of a complex password helps to increase the time and resources required to compromise the password. Password complexity, or strength, is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. + +Password complexity is one factor of several that determines how long it takes to crack a password. The more complex the password, the greater the number of possible combinations that need to be tested before the password is compromised. + +Satisfies: SRG-OS-000070-GPOS-00038, SRG-OS-000725-GPOS-00180</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-004064Configure Amazon Linux 2023 to enforce password complexity by requiring that at least one lowercase character be used by setting the "lcredit" option. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "lcredit" parameter: + +lcredit = -1 + +Remove any configurations that conflict with the above value.Verify Amazon Linux 2023 enforces password complexity by requiring that at least one lowercase character with the following command: + +$ sudo grep lcredit /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +lcredit = -1 + +If the value of "lcredit" is a positive number or is commented out, this is a finding.SRG-OS-000071-GPOS-00039<GroupDescription></GroupDescription>AZLX-23-002365Amazon Linux 2023 must enforce password complexity by requiring that at least one numeric character be used.<VulnDiscussion>Use of a complex password helps to increase the time and resources required to compromise the password. Password complexity, or strength, is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. + +Password complexity is one factor of several that determines how long it takes to crack a password. The more complex the password, the greater the number of possible combinations that need to be tested before the password is compromised. + +Satisfies: SRG-OS-000071-GPOS-00039, SRG-OS-000725-GPOS-00180</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-004064Configure Amazon Linux 2023 to enforce password complexity by requiring that at least one numeric character be used by setting the "dcredit" option. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "dcredit" parameter: + +dcredit = -1 + +Remove any configurations that conflict with the above value.Verify Amazon Linux 2023 enforces password complexity by requiring that at least one numeric character with the following command: + +$ sudo grep dcredit /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +dcredit = -1 + +If the value of "dcredit" is a positive number or is commented out, this is a finding.SRG-OS-000072-GPOS-00040<GroupDescription></GroupDescription>AZLX-23-002370Amazon Linux 2023 must require the change of at least 50 percent of the total number of characters when passwords are changed.<VulnDiscussion>If Amazon Linux 2023 allows the user to consecutively reuse extensive portions of passwords, this increases the chances of password compromise by increasing the window of opportunity for attempts at guessing and brute-force attacks. + +The number of changed characters refers to the number of changes required with respect to the total number of positions in the current password. In other words, characters may be the same within the two passwords; however, the positions of the like characters must be different. + +If the password length is an odd number then number of changed characters must be rounded up. For example, a password length of 15 characters must require the change of at least 8 characters. + +Satisfies: SRG-OS-000072-GPOS-00040, SRG-OS-000725-GPOS-00180</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-004064Configure Amazon Linux 2023 to require the change of at least eight (with a 15 character password) of the total number of characters when passwords are changed by setting the "difok" option. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "difok" parameter: + +difok = 8 + +Remove any configurations that conflict with the above value. This value can be customized based on desired password length.Verify Amazon Linux 2023 enforces password complexity by requiring that at least a change of at least eight characters when passwords are changed with the following command: + +$ sudo grep difok /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +difok = 8 + +If the value of "difok" is set to less than "8", or is commented out, this is a finding.SRG-OS-000078-GPOS-00046<GroupDescription></GroupDescription>AZLX-23-002375Amazon Linux 2023 must enforce a minimum 15-character password length.<VulnDiscussion>The shorter the password, the lower the number of possible combinations that need to be tested before the password is compromised. + +Password complexity, or strength, is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. Password length is one factor of several that helps to determine strength and how long it takes to crack a password. Use of more characters in a password helps to exponentially increase the time and/or resources required to compromise the password. + +Satisfies: SRG-OS-000078-GPOS-00046, SRG-OS-000725-GPOS-00180</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-004064Configure Amazon Linux 2023 to enforce a minimum 15-character password length. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "minlen" parameter: + +minlen = 15 + +Remove any configurations that conflict with the above value.Verify Amazon Linux 2023 enforces a minimum 15-character password length with the following command: + +$ sudo grep -rs minlen /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +/etc/security/pwquality.conf: minlen = 15 + +If the command does not return a "minlen" value of 15 or greater, or the line is commented out, this is a finding. + +If conflicting results are returned, this is a finding.SRG-OS-000266-GPOS-00101<GroupDescription></GroupDescription>AZLX-23-002380Amazon Linux 2023 must enforce password complexity by requiring that at least one special character be used.<VulnDiscussion>Use of a complex password helps to increase the time and resources required to compromise the password. Password complexity or strength is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. + +Password complexity is one factor in determining how long it takes to crack a password. The more complex the password, the greater the number of possible combinations that need to be tested before the password is compromised. + +Special characters are those characters that are not alphanumeric. Examples include: ~ ! @ # $ % ^ *. + +Satisfies: SRG-OS-000266-GPOS-00101, SRG-OS-000725-GPOS-00180</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-004064Configure Amazon Linux 2023 to enforce password complexity by requiring at least one special character be used by setting the "ocredit" option. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "ocredit" parameter: + +ocredit = -1Verify Amazon Linux 2023 enforces password complexity by requiring at least one special character with the following command: + +$ sudo grep -rs ocredit /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +/etc/security/pwquality.conf: ocredit = -1 + +If the value of "ocredit" is a positive number or is commented out, this is a finding.SRG-OS-000072-GPOS-00040<GroupDescription></GroupDescription>AZLX-23-002385Amazon Linux 2023 must enforce password complexity rules for the root account.<VulnDiscussion>Use of a complex password helps to increase the time and resources required to compromise the password. Password complexity, or strength, is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. + +Password complexity is one factor of several that determines how long it takes to crack a password. The more complex the password, the greater the number of possible combinations that need to be tested before the password is compromised. + +Satisfies: SRG-OS-000072-GPOS-00040, SRG-OS-000071-GPOS-00039, SRG-OS-000070-GPOS-00038, SRG-OS-000266-GPOS-00101, SRG-OS-000078-GPOS-00046, SRG-OS-000069-GPOS-00037</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066Configure Amazon Linux 2023 to enforce password complexity on the root account. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the "/etc/security/pwquality.conf.d/" directory to contain the "enforce_for_root" parameter: + +enforce_for_rootVerify Amazon Linux 2023 enforces password complexity rules for the root account with the following command: + +$ sudo grep -rs enforce_for_root /etc/security/pwquality.conf /etc/security/pwquality.conf.d/*.conf +/etc/security/pwquality.conf:enforce_for_root + +If "enforce_for_root" is commented or missing, this is a finding.SRG-OS-000480-GPOS-00225<GroupDescription></GroupDescription>AZLX-23-002390Amazon Linux 2023 must prevent the use of dictionary words for passwords.<VulnDiscussion>Use of a complex password helps to increase the time and resources required to compromise the password. Password complexity, or strength, is a measure of the effectiveness of a password in resisting attempts at guessing and brute-force attacks. If Amazon Linux 2023 allows the user to select passwords based on dictionary words, this increases the chances of password compromise by increasing the opportunity for successful guesses, and brute-force attacks. + +Satisfies: SRG-OS-000480-GPOS-00225, SRG-OS-000710-GPOS-00160</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000366CCI-004061Configure Amazon Linux 2023 to prevent the use of dictionary words for passwords. + +Add or update the following line in the "/etc/security/pwquality.conf" file or a configuration file in the /etc/pwquality.conf.d/ directory to contain the "dictcheck" parameter: + +dictcheck=1Verify Amazon Linux 2023 prevents the use of dictionary words for passwords with the following command: + +$ sudo grep -rs dictcheck /etc/security/pwquality.conf /etc/pwquality.conf.d/*.conf +/etc/security/pwquality.conf:dictcheck=1 + +If the "dictcheck" parameter is not set to "1", is commented out, or is missing, this is a finding.SRG-OS-000027-GPOS-00008<GroupDescription></GroupDescription>AZLX-23-002395Amazon Linux 2023 must limit the number of concurrent sessions to ten for all accounts and/or account types.<VulnDiscussion>Operating system management includes the ability to control the number of users and user sessions that utilize an operating system. Limiting the number of allowed users and sessions per user is helpful in reducing the risks related to denial-of-service (DoS) attacks. + +This requirement addresses concurrent sessions for information system accounts and does not address concurrent sessions by single users via multiple system accounts. The maximum number of concurrent sessions should be defined based on mission needs and the operational environment for each system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000054Configure Amazon Linux 2023 to limit the number of concurrent sessions to "10" for all accounts and/or account types. + +Add the following line to the top of the /etc/security/limits.conf or in a ".conf" file defined in /etc/security/limits.d/: + +* hard maxlogins 10Verify Amazon Linux 2023 limits the number of concurrent sessions to "10" for all accounts and/or account types with the following command: + +$ sudo grep -r -s '^[^#].*maxlogins' /etc/security/limits.conf /etc/security/limits.d/*.conf +* hard maxlogins 10 + +This can be set as a global domain (with the * wildcard) but may be set differently for multiple domains. + +If the "maxlogins" item is missing, commented out, or the value is set greater than "10" and is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "maxlogins" item assigned, this is a finding.SRG-OS-000163-GPOS-00072<GroupDescription></GroupDescription>AZLX-23-002396Amazon Linux 2023 must automatically exit interactive command shell user sessions after 15 minutes of inactivity.<VulnDiscussion>Terminating an idle interactive command shell user session within a short time period reduces the window of opportunity for unauthorized personnel to take control of it when left unattended in a virtual terminal or physical console.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000057CCI-001133Configure Amazon Linux 2023 to exit interactive command shell user sessions after 10 minutes of inactivity. + +Add or edit the following line in "/etc/profile.d/tmout.sh": + +#!/bin/bash + +declare -xr TMOUT=600Verify Amazon Linux 2023 is configured to exit interactive command shell user sessions after 10 minutes of inactivity or less with the following command: + +$ sudo grep -i tmout /etc/profile /etc/profile.d/*.sh +/etc/profile.d/tmout.sh:declare -xr TMOUT=600 + +If "TMOUT" is not set to "600" or less in a script located in the "/etc/'profile.d/ directory, is missing or is commented out, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>AZLX-23-002400Amazon Linux 2023 must enforce 24 hours/1 day as the minimum password lifetime.<VulnDiscussion>Enforcing a minimum password lifetime helps to prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, then the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066Configure Amazon Linux 2023 to enforce 24 hours as the minimum password lifetime for new user accounts. + +Add the following line in "/etc/login.defs" (or modify the line to have the required value): + +PASS_MIN_DAYS 1Verify Amazon Linux 2023 enforces 24 hours as the minimum password lifetime for new user accounts with the following command: + +$ sudo grep -i pass_min_days /etc/login.defs +PASS_MIN_DAYS 1 + +If the "PASS_MIN_DAYS" parameter value is not "1" or greater, or is commented out, this is a finding.SRG-OS-000480-GPOS-00226<GroupDescription></GroupDescription>AZLX-23-002405Amazon Linux 2023 must enforce a delay of at least four seconds between logon prompts following a failed logon attempt.<VulnDiscussion>Increasing the time between a failed authentication attempt and re-prompting to enter credentials helps to slow a single-threaded brute force attack.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000366Configure Amazon Linux 2023 to enforce a delay of at least four seconds between logon prompts following a failed console logon attempt. + +Modify the "/etc/login.defs" file to set the "FAIL_DELAY" parameter to "4" or greater: + +FAIL_DELAY 4Verify Amazon Linux 2023 enforces a delay of at least four seconds between console logon prompts following a failed logon attempt with the following command: + +$ sudo grep -i fail_delay /etc/login.defs +FAIL_DELAY 4 + +If the value of "FAIL_DELAY" is not set to "4" or greater, the line is commented out, or the line is missing, this is a finding.SRG-OS-000480-GPOS-00228<GroupDescription></GroupDescription>AZLX-23-002410Amazon Linux 2023 must define default permissions for all authenticated users in such a way that the user can only read and modify their own files.<VulnDiscussion>Setting the most restrictive default permissions ensures that when new accounts are created, they do not have unnecessary access. + +Satisfies: SRG-OS-000480-GPOS-00228, SRG-OS-000480-GPOS-00230</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000366Configure Amazon Linux 2023 to define default permissions for all authenticated users in such a way that the user can only read and modify their own files. + +Add or edit the lines for the "UMASK" parameter in the "/etc/login.defs" file to "077": + +UMASK 077Verify Amazon Linux 2023 defines default permissions for all authenticated users in such a way that the user can only read and modify their own files with the following command: + +Note: If the value of the "UMASK" parameter is set to "000" in "/etc/login.defs" file, the Severity is raised to a CAT I. + +# grep -i umask /etc/login.defs +UMASK 077 + +If the value for the "UMASK" parameter is not "077", or the "UMASK" parameter is missing or is commented out, this is a finding.SRG-OS-000002-GPOS-00002<GroupDescription></GroupDescription>AZLX-23-002415Amazon Linux 2023 must automatically remove or disable temporary user accounts after 72 hours.<VulnDiscussion>If temporary user accounts remain active when no longer needed or for an excessive period, these accounts may be used to gain unauthorized access. To mitigate this risk, automated termination of all temporary accounts must be set upon account creation.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000016Configure Amazon Linux 2023 temporary accounts to have an expiration date of 72 hours. + +If a temporary account must be created configure the system to terminate the account after a 72 hour time period with the following command to set an expiration date on it. Substitute "system_account_name" with the account to be created. + +$ sudo chage -E $(date -d +3days +%Y-%m-%d) system_account_nameVerify Amazon Linux 2023 temporary accounts have been provisioned with an expiration date of 72 hours. + +For every existing temporary account, run the following command to obtain its account expiration information. + +$ sudo chage -l system_account_name + +Verify each of these accounts has an expiration date set within 72 hours. + +If any temporary accounts have no expiration date set or do not expire within 72 hours, this is a finding.SRG-OS-000021-GPOS-00005<GroupDescription></GroupDescription>AZLX-23-002420Amazon Linux 2023 must automatically lock an account when three unsuccessful logon attempts occur.<VulnDiscussion>By limiting the number of failed logon attempts, the risk of unauthorized system access via user password guessing, otherwise known as brute-force attacks, is reduced. Limits are imposed by locking the account. + +Amazon Linux 2023 can utilize the "pam_faillock.so" for this purpose. Note that manual changes to the listed files may be overwritten by the "authselect" program. + +From "Pam_Faillock" man pages: Note that the default directory that "pam_faillock" uses is usually cleared on system boot so the access will be re-enabled after system reboot. If that is undesirable, a different tally directory must be set with the "dir" option.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000044Configure Amazon Linux 2023 to lock an account when three unsuccessful logon attempts occur. + +Add/Modify the appropriate sections of the "/etc/pam.d/system-auth" and "/etc/pam.d/password-auth" files to match the following lines: + +auth required pam_faillock.so preauth dir=/var/log/faillock silent audit deny=3 even_deny_root fail_interval=900 unlock_time=0 +auth required pam_faillock.so authfail dir=/var/log/faillock unlock_time=0 +account required pam_faillock.so + +The "sssd" service must be restarted for the changes to take effect. To restart the "sssd" service, run the following command: + +$ sudo systemctl restart sssd.serviceVerify Amazon Linux 2023 locks an account after three unsuccessful logon attempts with the following commands: + +Note: If the system administrator demonstrates the use of an approved centralized account management method that locks an account after three unsuccessful logon attempts within a period of 15 minutes, this requirement is met by that method. + +$ sudo grep pam_faillock.so /etc/pam.d/password-auth +auth required pam_faillock.so preauth dir=/var/log/faillock silent audit deny=3 even_deny_root fail_interval=900 unlock_time=0 +auth required pam_faillock.so authfail dir=/var/log/faillock unlock_time=0 +account required pam_faillock.so + +If the "deny" option is not set to "3" or less (but not "0") on the "preauth" line with the "pam_faillock.so" module, or is missing from this line, if any of the lines are commented out, or are missing, this is a finding.SRG-OS-000076-GPOS-00044<GroupDescription></GroupDescription>AZLX-23-002425Amazon Linux 2023 must be able to enforce a 60-day maximum password lifetime restriction.<VulnDiscussion>Any password, no matter how complex, can eventually be cracked. Therefore, passwords need to be changed periodically. If Amazon Linux 2023 does not limit the lifetime of passwords and force users to change their passwords, there is the risk that Amazon Linux 2023 passwords could be compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066Configure Amazon Linux 2023 to set noncompliant accounts to enforce a 60-day maximum password lifetime restriction. + +$ sudo chage -M 60 [user]Verify Amazon Linux 2023 enforces the maximum time period for existing passwords is restricted to 60 days with the following commands: + +$ sudo awk -F: '$5 > 60 {print $1 " " $5}' /etc/shadow + +$ sudo awk -F: '$5 <= 0 {print $1 " " $5}' /etc/shadow + +If any results are returned that are not associated with a system account, this is a finding.SRG-OS-000118-GPOS-00060<GroupDescription></GroupDescription>AZLX-23-002430Amazon Linux 2023 must disable account identifiers (individuals, groups, roles, and devices) after 35 days of inactivity.<VulnDiscussion>Inactive identifiers pose a risk to systems and applications because attackers may exploit an inactive identifier and potentially obtain undetected access to the system. Owners of inactive accounts will not notice if unauthorized access to their user account has been obtained. + +Operating systems need to track periods of inactivity and disable application identifiers after 35 days of inactivity. + +Satisfies: SRG-OS-000118-GPOS-00060, SRG-OS-000590-GPOS-00110</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-003627CCI-003628Configure Amazon Linux 2023 to disable account identifiers after 35 days of inactivity after the password expiration. + +Run the following command to change the configuration for useradd: + +$ sudo useradd -D -f 35 + +The recommendation is 35 days, but a lower value is acceptable.Verify Amazon Linux 2023 account identifiers (individuals, groups, roles, and devices) are disabled after 35 days of inactivity with the following command: + +Check the account inactivity value by performing the following command: + +$ sudo grep -i inactive /etc/default/useradd +INACTIVE=35 + +If "INACTIVE" is set to "-1", a value greater than "35", or is commented out, this is a finding.SRG-OS-000123-GPOS-00064<GroupDescription></GroupDescription>AZLX-23-002435Amazon Linux 2023 must automatically expire temporary accounts within 72 hours.<VulnDiscussion>Temporary accounts are privileged or nonprivileged accounts that are established during pressing circumstances, such as new software or hardware configuration or an incident response, where the need for prompt account activation requires bypassing normal account authorization procedures. If any inactive temporary accounts are left enabled on the system and are not either manually removed or automatically expired within 72 hours, the security posture of the system will be degraded and exposed to exploitation by unauthorized users or insider threat actors. + +Temporary accounts are different from emergency accounts. Emergency accounts, also known as "last resort" or "break glass" accounts, are local logon accounts enabled on the system for emergency use by authorized system administrators to manage a system when standard logon methods are failing or not available. Emergency accounts are not subject to manual removal or scheduled expiration requirements. + +The automatic expiration of temporary accounts may be extended as needed by the circumstances but it must not be extended indefinitely. A documented permanent account must be established for privileged users who need long-term maintenance accounts.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001682Configure Amazon Linux 2023 to expire temporary accounts after 72 hours with the following command: + +$ sudo chage -E $(date -d +3days +%Y-%m-%d) <temporary_account_name> +Verify Amazon Linux 2023 temporary accounts have been provisioned with an expiration date of 72 hours. + +For every existing temporary account, run the following command to obtain its account expiration information: + +$ sudo chage -l <temporary_account_name> | grep -i "account expires" + +Verify each of these accounts has an expiration date set within 72 hours. + +If any temporary accounts have no expiration date set or do not expire within 72 hours, this is a finding.SRG-OS-000312-GPOS-00123<GroupDescription></GroupDescription>AZLX-23-002440Amazon Linux 2023 must restrict the use of the "su" command.<VulnDiscussion>The "su" program allows to run commands with a substitute user and group ID. It is commonly used to run commands as the root user. Limiting access to such commands is considered a good security practice.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002165Configure Amazon Linux 2023 to require users to be in the "wheel" group to run "su" command. + +In file "/etc/pam.d/su", uncomment the following line: + +"#auth required pam_wheel.so use_uid" + +$ sudo sed '/^[[:space:]]*#[[:space:]]*auth[[:space:]]\+required[[:space:]]\+pam_wheel\.so[[:space:]]\+use_uid$/s/^[[:space:]]*#//' -i /etc/pam.d/su + +If necessary, create a "wheel" group and add administrative users to the group.Verify Amazon Linux 2023 requires uses to be members of the "wheel" group with the following command: + +$ grep pam_wheel /etc/pam.d/su +auth required pam_wheel.so use_uid + +If a line for "pam_wheel.so" does not exist, or is commented out, this is a finding.SRG-OS-000445-GPOS-00199<GroupDescription></GroupDescription>AZLX-23-002445Amazon Linux 2023 must enable the SELinux targeted policy.<VulnDiscussion>Setting the SELinux policy to "targeted" or a more specialized policy ensures the system will confine processes that are likely to be targeted for exploitation, such as network or system services. + +Note: During the development or debugging of SELinux modules, it is common to temporarily place nonproduction systems in "permissive" mode. In such temporary cases, SELinux policies should be developed, and once work is completed, the system should be reconfigured to "targeted".</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002696Configure Amazon Linux 2023 to use the targeted SELINUX policy. + +Edit the file "/etc/selinux/config" and add or modify the following line: + + SELINUXTYPE=targeted + +A reboot is required for the changes to take effect.Verify Amazon Linux 2023 SELINUX is using the targeted policy with the following command: + +$ sestatus | grep policy +Loaded policy name: targeted + +If the loaded policy name is not "targeted", this is a finding.SRG-OS-000134-GPOS-00068<GroupDescription></GroupDescription>AZLX-23-002450Amazon Linux 2023 must use a Linux Security Module configured to enforce limits on system services.<VulnDiscussion>An isolation boundary provides access control and protects the integrity of the hardware, software, and firmware that perform security functions. + +Security functions are the hardware, software, and/or firmware of the information system responsible for enforcing the system security policy and supporting the isolation of code and data on which the protection is based. Operating systems implement code separation (i.e., separation of security functions from nonsecurity functions) in a number of ways, including through the provision of security kernels via processor rings or processor modes. For nonkernel code, security function isolation is often achieved through file system protections that serve to protect the code on disk and address space protections that protect executing code. + +Developers and implementers can increase the assurance in security functions by employing well-defined security policy models; structured, disciplined, and rigorous hardware and software development techniques; and sound system/security engineering principles. Implementation may include isolation of memory space and libraries. Operating systems restrict access to security functions through the use of access control mechanisms and by implementing least privilege capabilities. + +Satisfies: SRG-OS-000134-GPOS-00068, SRG-OS-000445-GPOS-00199</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001084CCI-002696Configure Amazon Linux 2023 to verify correct operation of security functions. + +Edit the file "/etc/selinux/config" and add or modify the following line: + +SELINUX=enforcing + +A reboot is required for the changes to take effect.Verify Amazon Linux 2023 verifies the correct operation of security functions through the use of SELinux with the following command: + +$ getenforce +Enforcing + +If SELINUX is not set to "Enforcing", this is a finding.SRG-OS-000329-GPOS-00128<GroupDescription></GroupDescription>AZLX-23-002455Amazon Linux 2023 must automatically lock an account when three unsuccessful logon attempts occur.<VulnDiscussion>By limiting the number of failed logon attempts, the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002238Configure Amazon Linux 2023 to lock an account when three unsuccessful logon attempts occur. + +Add/modify the "/etc/security/faillock.conf" file to match the following line: + +deny = 3Verify Amazon Linux 2023 is configured to lock an account after three unsuccessful logon attempts with the command: + +$ grep 'deny =' /etc/security/faillock.conf +deny = 3 + +If the "deny" option is not set to "3" or less (but not "0"), is missing or commented out, this is a finding.SRG-OS-000329-GPOS-00128<GroupDescription></GroupDescription>AZLX-23-002460Amazon Linux 2023 must automatically lock the root account until the root account is released by an administrator when three unsuccessful logon attempts occur during a 15-minute time period.<VulnDiscussion>By limiting the number of failed logon attempts, the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002238Configure Amazon Linux 2023 to lock out the "root" account after a number of incorrect login attempts using "pam_faillock.so", first enable the feature using the following command: + +$ sudo authselect enable-feature with-faillock + +Then edit the "/etc/security/faillock.conf" file as follows: + +add or uncomment the following line: +even_deny_rootVerify Amazon Linux 2023 is configured to lock the root account after three unsuccessful logon attempts with the command: + +$ grep even_deny_root /etc/security/faillock.conf +even_deny_root + +If the "even_deny_root" option is not set, is missing or commented out, this is a finding.SRG-OS-000329-GPOS-00128<GroupDescription></GroupDescription>AZLX-23-002465Amazon Linux 2023 must automatically lock an account until the locked account is released by an administrator when three unsuccessful logon attempts in 15 minutes occur.<VulnDiscussion>By limiting the number of failed logon attempts, the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002238Configure Amazon Linux 2023 to automatically lock an account after three unsuccessful logon attempts in 15-minutes. + +First, ensure that the system is configured with authselect, i.e., using sssd profiles: + +$ sudo authselect select sssd [--force] + +Then, enable the faillock feature: + +$ sudo authselect enable-feature with-faillock + +Then edit the "/etc/security/faillock.conf" file as follows: + +fail_interval = 900Note: If the system administrator demonstrates the use of an approved centralized account management method that locks an account after three unsuccessful logon attempts within a period of 15 minutes, this requirement is not applicable. + +Verify Amazon Linux 2023 locks an account after three unsuccessful logon attempts within a period of 15 minutes with the following command: + +$ grep fail_interval /etc/security/faillock.conf +fail_interval = 900 + +If the "fail_interval" option is not set to "900" or less (but not "0"), the line is commented out, or the line is missing, this is a finding.SRG-OS-000329-GPOS-00128<GroupDescription></GroupDescription>AZLX-23-002470Amazon Linux 2023 must maintain an account lock until the locked account is released by an administrator.<VulnDiscussion>By limiting the number of failed logon attempts, the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002238Configure Amazon Linux 2023 to lock an account until released by an administrator after three unsuccessful logon attempts with the command: + +$ authselect enable-feature with-faillock + +Then edit the "/etc/security/faillock.conf" file as follows: + +unlock_time = 0Verify Amazon Linux 2023 is configured to lock an account until released by an administrator after three unsuccessful logon attempts with the command: + +$ grep 'unlock_time =' /etc/security/faillock.conf +unlock_time = 0 + +If the "unlock_time" option is not set to "0", the line is missing, or commented out, this is a finding.SRG-OS-000096-GPOS-00050<GroupDescription></GroupDescription>AZLX-23-002475Amazon Linux 2023 must be configured to prohibit or restrict the use of functions, ports, protocols, and/or services, as defined in the Ports, Protocols, and Services Management Category Assurance List (PPSM CAL) and vulnerability assessments.<VulnDiscussion>To prevent unauthorized connection of devices, unauthorized transfer of information, or unauthorized tunneling (i.e., embedding of data types within data types), organizations must disable or restrict unused or unnecessary physical and logical ports/protocols on information systems. + +Operating systems are capable of providing a variety of functions and services. Some of the functions and services provided by default may not be necessary to support essential organizational operations. Additionally, it is sometimes convenient to provide multiple services from a single component (e.g., VPN and IPS); however, doing so increases risk over limiting the services provided by any one component. + +To support the requirements and principles of least functionality, Amazon Linux 2023 must support the organizational requirements, providing only essential capabilities and limiting the use of ports, protocols, and/or services to only those required, authorized, and approved to conduct official business or to address authorized quality of life issues. + +Satisfies: SRG-OS-000096-GPOS-00050, SRG-OS-000297-GPOS-00115</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000382CCI-002314Configure Amazon Linux 2023 to Prohibit/Restrict Functions, Ports, Protocols, Services. Use firewall-cmd to manage firewalld. + +For example, to block a specific port (8080), use: +sudo firewall-cmd --permanent --remove-port=8080/tcpVerify Amazon Linux 2023 firewall is configured to block unregistered ports, protocols, and services. + +Inspect the list of enabled firewall ports and verify they are configured correctly by running the following command: + +$ sudo firewall-cmd --list-all + +Ask the system administrator for the site or program PPSM Component Local Service Assessment (CLSA). Verify the services allowed by the firewall match the PPSM CLSA. + +If there are additional ports, protocols, or services that are not in the PPSM CLSA, or there are ports, protocols, or services that are prohibited by the PPSM CAL, or there are no firewall rules configured, this is a finding.SRG-OS-000104-GPOS-00051<GroupDescription></GroupDescription>AZLX-23-002480Amazon Linux 2023 must insure all interactive users have a primary group that exists.<VulnDiscussion>If a user is assigned the group identifier (GID) of a group that does not exist on the system, and a group with the GID is subsequently created, the user may have unintended rights to any files associated with the group. + +Satisfies: SRG-OS-000104-GPOS-00051, SRG-OS-000121-GPOS-00062, SRG-OS-000042-GPOS-00020</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000764CCI-000804CCI-000135Configure Amazon Linux 2023 so that all GIDs are referenced in "/etc/passwd" are defined in "/etc/group". + +Edit the file "/etc/passwd" and ensure that every user's GID is a valid GID.Verify Amazon Linux 2023 interactive users have a valid GID with the following command: + +$ sudo pwck -qr + +If the system has any interactive users with duplicate GIDs, this is a finding.SRG-OS-000104-GPOS-00051<GroupDescription></GroupDescription>AZLX-23-002485Amazon Linux 2023 must ensure all interactive users have unique User IDs (UIDs).<VulnDiscussion>To ensure accountability and prevent unauthenticated access, interactive users must be identified and authenticated to prevent potential misuse and compromise of the system. + +Satisfies: SRG-OS-000104-GPOS-00051, SRG-OS-000121-GPOS-00062, SRG-OS-000042-GPOS-00020</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000764CCI-000804CCI-000135Configure Amazon Linux 2023 to contain no duplicate UIDs for interactive users. + +Edit the file "/etc/passwd" and provide each interactive user account that has a duplicate UID with a unique UID.Verify Amazon Linux 2023 contains no duplicate UIDs for interactive users with the following command: + +$ sudo awk -F ":" 'list[$3]++{print $1, $3}' /etc/passwd + +If output is produced and the accounts listed are interactive user accounts, this is a finding.SRG-OS-000069-GPOS-00037<GroupDescription></GroupDescription>AZLX-23-002489Amazon Linux 2023 must ensure the password complexity module is enabled in the password-auth file.<VulnDiscussion>Enabling PAM password complexity permits enforcement of strong passwords and consequently makes the system less prone to dictionary attacks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004066CCI-000192CCI-000193Configure Amazon Linux 2023 to use "pwquality" to enforce password complexity rules. + +Add the following line to the "/etc/pam.d/password-auth" file (or modify the line to have the required value): + +password required pam_pwquality.soVerify Amazon Linux 2023 uses "pwquality" to enforce the password complexity rules in the password-auth file with the following command: + +$ grep pam_pwquality /etc/pam.d/password-auth +password required pam_pwquality.so + +If the command does not return a line containing the value "pam_pwquality.so", or the line is commented out, this is a finding. + +If the system administrator can demonstrate that the required configuration is contained in a PAM configuration file included or substacked from the system-auth file, this is not a finding.SRG-OS-000073-GPOS-00041<GroupDescription></GroupDescription>AZLX-23-002490Amazon Linux 2023 password-auth must be configured to use a sufficient number of hashing rounds.<VulnDiscussion>Unapproved mechanisms, used for authentication to the cryptographic module are not verified and therefore, cannot be relied upon to provide confidentiality or integrity, and DOD data may be compromised. + +Operating systems utilizing encryption are required to use FIPS-compliant mechanisms for authenticating to cryptographic modules. + +FIPS 140-2/140-3 is the current standard for validating that mechanisms used to access cryptographic modules utilize authentication that meets DOD requirements. This allows for Security Levels 1, 2, 3, or 4 for use on a general purpose computing system. + +Satisfies: SRG-OS-000073-GPOS-00041, SRG-OS-000120-GPOS-00061</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004062CCI-000803Configure Amazon Linux 2023 to use 100000 hashing rounds for hashing passwords. + +Add or modify the following line in "/etc/pam.d/password-auth" and set "rounds" to "100000". + +password sufficient pam_unix.so sha512 rounds=100000Verify Amazon Linux 2023 has the required number of rounds for the password hashing algorithm is configured in password-auth with the following command: + +$ sudo grep rounds /etc/pam.d/password-auth +password sufficient pam_unix.so sha512 rounds=100000 + +If a matching line is not returned or "rounds" is less than "100000", this a finding.SRG-OS-000073-GPOS-00041<GroupDescription></GroupDescription>AZLX-23-002495Amazon Linux 2023 system-auth must be configured to use a sufficient number of hashing rounds.<VulnDiscussion>Unapproved mechanisms used for authentication to the cryptographic module are not verified and therefore, cannot be relied upon to provide confidentiality or integrity, and DOD data may be compromised. + +Operating systems utilizing encryption are required to use FIPS-compliant mechanisms for authenticating to cryptographic modules. + +FIPS 140-2/140-3 is the current standard for validating that mechanisms used to access cryptographic modules utilize authentication that meets DOD requirements. This allows for Security Levels 1, 2, 3, or 4 for use on a general purpose computing system. + +Satisfies: SRG-OS-000073-GPOS-00041, SRG-OS-000120-GPOS-00061</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004062CCI-000803Configure Amazon Linux 2023 to use 100000 hashing rounds for hashing passwords. + +Add or modify the following line in "/etc/pam.d/system-auth" and set "rounds" to "100000". + +password sufficient pam_unix.so sha512 rounds=100000Verify Amazon Linux 2023 has the required number of rounds for the password hashing algorithm is configured in system-auth with the following command: + +$ sudo grep rounds /etc/pam.d/system-auth +password sufficient pam_unix.so sha512 rounds=100000 + +If a matching line is not returned or "rounds" is less than "100000", this a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>AZLX-23-002500Amazon Linux 2023 must ensure a sticky bit be set on all public directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. + +This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DOD or other government agencies. + +There may be shared resources with configurable protections (e.g., files in storage) that may be assessed on specific information system components.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001090Configure Amazon Linux 2023 world-writable directories to have the sticky bit set to prevent unauthorized and unintended information transferred via shared system resources. + +Set the sticky bit on all world-writable directories using the following command: + +$ sudo find / -type d -perm -0002 ! -perm -1000 -exec chmod +t {} +Verify Amazon Linux 2023 world-writable directories have the sticky bit set. + +Determine if all world-writable directories have the sticky bit set by running the following command: + +$ sudo find / -type d -perm -0002 ! -perm -1000 -exec ls -ld {} + + +If any output is returned, these directories are world-writable and do not have the sticky bit set, and this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>AZLX-23-002505Amazon Linux 2023 must ensure all world-writable directories be owned by root, sys, bin, or an application user.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. + +This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DOD or other government agencies. + +There may be shared resources with configurable protections (e.g., files in storage) that may be assessed on specific information system components.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001090Configure Amazon Linux 2023 public directories to be owned by root or a system account to prevent unauthorized and unintended information transferred via shared system resources. + +Set the owner of all public directories as root or a system account using the following command: + +$ sudo find / -xdev -type d -perm -0002 ! -user root ! -uid +999 -exec chown root:root {} +Verify Amazon Linux 2023 world writable directories are owned by root, a system account, or an application account with the following command: + +$ sudo find / -xdev -type d -perm -0002 ! -user root ! -uid +999 -exec ls -ld {} + + +If there is output, this is a finding.SRG-OS-000163-GPOS-00072<GroupDescription></GroupDescription>AZLX-23-002510Amazon Linux 2023 must terminate idle user sessions.<VulnDiscussion>Terminating an idle session within a short time period reduces the window of opportunity for unauthorized personnel to take control of a management session enabled on the console or console port that has been left unattended. In addition, quickly terminating an idle session will also free up resources committed by the managed network element. + +Terminating network connections associated with communications sessions includes, for example, de-allocating associated TCP/IP address/port pairs at Amazon Linux 2023 level, and de-allocating networking assignments at the application level if multiple application sessions are using a single operating system-level network connection. This does not mean that Amazon Linux 2023 terminates all sessions or network access; it only ends the inactive session and releases the resources associated with that session.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001133Configure Amazon Linux 2023 to log out idle sessions by editing the /etc/systemd/logind.conf file with the following line: + +StopIdleSessionSec=900 + +The "logind" service must be restarted for the changes to take effect. To restart the "logind" service, run the following command: + +$ sudo systemctl restart systemd-logindVerify Amazon Linux 2023 logs out sessions that are idle for 15 minutes with the following command: + +$ sudo grep -i ^StopIdleSessionSec /etc/systemd/logind.conf +StopIdleSessionSec=900 + +If "StopIdleSessionSec" is not configured to "900" seconds, is commented out, or is missing, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>AZLX-23-002515Amazon Linux 2023 must enable auditing of processes that start prior to the audit daemon.<VulnDiscussion>Without the capability to generate audit records, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +If auditing is enabled late in the startup process, the actions of some startup processes may not be audited. Some audit systems also maintain state information only available if auditing is enabled before a given process is created. + +Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPOS-00020, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215, SRG-OS-000473-GPOS-00218, SRG-OS-000254-GPOS-00095</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000130CCI-000135CCI-000169CCI-002884CCI-000172CCI-001464Configure Amazon Linux 2023 so that GRUB 2 enables auditing of processes that start prior to the audit daemon with the following command: + +$ sudo grubby --update-kernel=ALL --args="audit=1" + +Add or modify the following line in "/etc/default/grub" to ensure the configuration survives kernel updates: + +GRUB_CMDLINE_LINUX="audit=1"Verify Amazon Linux 2023 is configured so that GRUB 2 enables auditing of processes that start prior to the audit daemon with the following commands: + +Check that the current GRUB 2 configuration enables auditing: + +$ sudo grubby --info=ALL | grep args | grep -v 'audit=1' + +If any output is returned, this is a finding. + +Check that auditing is enabled by default to persist in kernel updates: + +$ grep audit /etc/default/grub +GRUB_CMDLINE_LINUX="audit=1" + +If "audit" is not set to "1", is missing, or is commented out, this is a finding.SRG-OS-000254-GPOS-00095<GroupDescription></GroupDescription>AZLX-23-002520Amazon Linux 2023 must allocate an audit_backlog_limit of sufficient size to capture processes that start prior to the audit daemon.<VulnDiscussion>Without the capability to generate audit records, it would be difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. + +If auditing is enabled late in the startup process, the actions of some startup processes may not be audited. Some audit systems also maintain state information only available if auditing is enabled before a given process is created. + +Audit records can be generated from various components within the information system (e.g., module or policy filter). + +Allocating an audit_backlog_limit of sufficient size is critical in maintaining a stable boot process. With an insufficient limit allocated, the system is susceptible to boot failures and crashes. + +Satisfies: SRG-OS-000254-GPOS-00095, SRG-OS-000341-GPOS-00132</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001464CCI-001849Configure Amazon Linux 2023 to allocate sufficient audit_backlog_limit to capture processes that start prior to the audit daemon with the following command: + +$ sudo grubby --update-kernel=ALL --args=audit_backlog_limit=8192Verify Amazon Linux 2023 allocates a sufficient audit_backlog_limit to capture processes that start prior to the audit daemon with the following command: + +$ sudo grubby --info=ALL | grep args | grep -v 'audit_backlog_limit=8192' + +If the command returns any outputs, and audit_backlog_limit is less than "8192", this is a finding.SRG-OS-000312-GPOS-00123<GroupDescription></GroupDescription>AZLX-23-002535Amazon Linux 2023 must enable discretionary access control on hardlinks.<VulnDiscussion>By enabling the fs.protected_hardlinks kernel parameter, users can no longer create soft or hard links to files they do not own. Disallowing such hardlinks mitigates vulnerabilities based on insecure file system accessed by privileged programs, avoiding an exploitation vector exploiting unsafe use of open() or creat(). + +Satisfies: SRG-OS-000312-GPOS-00123, SRG-OS-000324-GPOS-00125</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002165CCI-002235Configure Amazon Linux 2023 to enable DAC on hardlinks with the following: + +Add or edit the following line in a system configuration file in the "/etc/sysctl.d/" directory: + +fs.protected_hardlinks = 1 + +Load settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 is configured to enable DAC on hardlinks. + +Check the status of the fs.protected_hardlinks kernel parameter with the following command: + +$ sudo sysctl fs.protected_hardlinks +fs.protected_hardlinks = 1 + +If "fs.protected_hardlinks" is not set to "1" or is missing, this is a finding.SRG-OS-000312-GPOS-00123<GroupDescription></GroupDescription>AZLX-23-002540Amazon Linux 2023 must enable kernel parameters to enforce discretionary access control on symlinks.<VulnDiscussion>By enabling the fs.protected_symlinks kernel parameter, symbolic links are permitted to be followed only when outside a sticky world-writable directory, or when the user identifier (UID) of the link and follower match, or when the directory owner matches the symlink's owner. Disallowing such symlinks helps mitigate vulnerabilities based on insecure file system accessed by privileged programs, avoiding an exploitation vector exploiting unsafe use of open() or creat(). + +Satisfies: SRG-OS-000312-GPOS-00123, SRG-OS-000324-GPOS-00125</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002165CCI-002235Configure Amazon Linux 2023 to enable DAC on symlinks with the following: + +Add or edit the following line in a system configuration file in the "/etc/sysctl.d/" directory: + +fs.protected_symlinks = 1 + +Load settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 is configured to enable DAC on symlinks. + +Check the status of the fs.protected_symlinks kernel parameter with the following command: + +$ sudo sysctl fs.protected_symlinks +fs.protected_symlinks = 1 + +If "fs.protected_symlinks " is not set to "1" or is missing, this is a finding.SRG-OS-000324-GPOS-00125<GroupDescription></GroupDescription>AZLX-23-002555Amazon Linux 2023 debug-shell systemd service must be disabled.<VulnDiscussion>The debug-shell requires no authentication and provides root privileges to anyone who has physical access to the machine. While this feature is disabled by default, masking it adds an additional layer of assurance that it will not be enabled via a dependency in systemd. This also prevents attackers with physical access from trivially bypassing security on the machine through valid troubleshooting configurations and gaining root access when the system is rebooted.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002235Configure Amazon Linux 2023 to mask the debug-shell systemd service with the following command: + +$ sudo systemctl disable --now debug-shell.service +$ sudo systemctl mask --now debug-shell.serviceVerify Amazon Linux 2023 is configured to mask the debug-shell systemd service with the following command: + +$ sudo systemctl status debug-shell.service +O debug-shell.service + Loaded: masked (Reason: Unit debug-shell.service is masked.) + Active: inactive (dead) + +If the "debug-shell.service" is loaded and not masked, this is a finding.SRG-OS-000355-GPOS-00143<GroupDescription></GroupDescription>AZLX-23-002560Amazon Linux 2023 chrony must be configured with a maximum interval of 24 hours between requests sent to a USNO server or a time server designated for the appropriate DOD network.<VulnDiscussion>Inaccurate time stamps make it more difficult to correlate events and can lead to an inaccurate analysis. Determining the correct time a particular event occurred on a system is critical when conducting forensic analysis and investigating system events. Sources outside the configured acceptable allowance (drift) may be inaccurate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004923Configure Amazon Linux 2023 to compare internal information system clocks at least every 24 hours with an NTP server. Ensure the following line is added or updated in /etc/chrony.conf: + +server DOD.ntp.server iburst maxpoll 16Verify Amazon Linux 2023 chrony service specifies a maximum interval of 24 hours between requests sent to a USNO server with the following command: + +Note: <USNO/DOD Server> is used in place of a time source IP address. + +$ sudo grep maxpoll /etc/chrony.conf +server <USNO/DOD Server> iburst maxpoll 16 + +If the "maxpoll" option is not configured, commented out, or set to a number greater than 16 or the line is commented out then this is a finding. + +Verify Amazon Linux 2023 chrony service is configured to use authoritative USNO or appropriate DOD time source with the following command: + +$ sudo grep -i server /etc/chrony.conf +server <USNO/DOD Server> + +If the parameter "server" is not set, or is not set to an authoritative USNO/DOD time source, then this is a finding.SRG-OS-000356-GPOS-00144<GroupDescription></GroupDescription>AZLX-23-002565Amazon Linux 2023 must synchronize internal information system clocks to the authoritative time source at least every 24 hours.<VulnDiscussion>Inaccurate time stamps make it more difficult to correlate events and can lead to an inaccurate analysis. Determining the correct time a particular event occurred on a system is critical when conducting forensic analysis and investigating system events. Sources outside the configured acceptable allowance (drift) may be inaccurate. + +Synchronizing internal information system clocks provides uniformity of time stamps for information systems with multiple system clocks and systems connected over a network. + +Depending on the infrastructure being used the "pool" directive may not be supported. + +Satisfies: SRG-OS-000356-GPOS-00144, SRG-OS-000785-GPOS-00250, SRG-OS-000359-GPOS-00146</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004926CCI-004922CCI-001890Configure Amazon Linux 2023 chrony service to securely compare internal information system clocks at least every 24 hours with an NTP server by adding/modifying the following line in the /etc/chrony.conf file. + +server [ntp.server.name] iburst maxpoll 16Verify Amazon Linux 2023 is securely comparing internal information system clocks at least every 24 hours with an NTP server with the following commands: + +$ sudo grep maxpoll /etc/chrony.conf +server 0.us.pool.ntp.mil iburst maxpoll 16 + +If the "maxpoll" option is set to a number greater than 16 or the line is commented out, this is a finding. + +Verify the "chrony.conf" file is configured to an authoritative DOD time source by running the following command: + +$ sudo grep -i server /etc/chrony.conf +server 0.us.pool.ntp.mil + +If the parameter "server" is not set, or is not set to an authoritative DOD time source, this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>AZLX-23-002570Amazon Linux 2023 must routinely check the baseline configuration for unauthorized changes and notify the system administrator when anomalies in the operation of any security functions are discovered.<VulnDiscussion>Unauthorized changes to the baseline configuration could make the system vulnerable to various attacks or allow unauthorized access to Amazon Linux 2023. Changes to operating system configurations can have unintended side effects, some of which may be relevant to security. + +Detecting such changes and providing an automated response can help avoid unintended, negative consequences that could ultimately affect the security state of Amazon Linux 2023. Amazon Linux 2023's information management officer (IMO)/information system security officer (ISSO) and system administrators (SAs) must be notified via email and/or monitoring system trap when there is an unauthorized modification of a configuration item. + +Notifications provided by information systems include messages to local computer consoles, and/or hardware indications, such as lights. + +This capability must take into account operational requirements for availability for selecting an appropriate response. The organization may choose to shut down or restart the information system upon security function anomaly detection.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001744Configure Amazon Linux 2023 so that the file integrity tool runs automatically on the system at least weekly and notifies designated personnel if baseline configurations are changed in an unauthorized manner. The AIDE tool can be configured to email designated personnel with the use of the cron system. + +The following example output is generic. It will set cron to run AIDE daily and to send email at the completion of the analysis. + +$ sudo more /etc/cron.daily/aide +#!/bin/bash +/usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily aide integrity check run" root@sysname.milVerify Amazon Linux 2023 routinely executes a file integrity scan for changes to the system baseline. The command used in the example will use a daily occurrence. + +Check the cron directories for scripts controlling the execution and notification of results of the file integrity application. For example, if AIDE is installed on the system, use the following commands: + +$ sudo ls -al /etc/cron.* | grep aide +-rwxr-xr-x 1 root root 29 Nov 22 2015 aide + +$ grep aide /etc/crontab /var/spool/cron/root +/etc/crontab: 30 04 * * * root usr/sbin/aide +/var/spool/cron/root: 30 04 * * * root usr/sbin/aide + +$ sudo more /etc/cron.daily/aide +#!/bin/bash +/usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily aide integrity check run" root@sysname.mil + +If the file integrity application does not exist, or a script file controlling the execution of the file integrity application does not exist, or the file integrity application does not notify designated personnel of changes, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>AZLX-23-002575Amazon Linux 2023 must prevent the loading of a new kernel for later execution.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of Amazon Linux 2023. This requirement ensures the software has not been tampered with and that it has been provided by a trusted vendor. + +All software packages must be signed with a cryptographic key recognized and approved by the organization. + +Verifying the authenticity of software prior to installation validates the integrity of the software package received from a vendor. This verifies the software has not been tampered with and that it has been provided by a trusted vendor.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-003992Configure Amazon Linux 2023 to disable kernel image loading. + +Add or edit the following line in a system configuration file in the "/etc/sysctl.d/" directory: + +kernel.kexec_load_disabled = 1 + +Load settings from all system configuration files with the following command: + +$ sudo sysctl --systemVerify Amazon Linux 2023 is configured to disable kernel image loading. + +Check the status of the kernel.kexec_load_disabled kernel parameter with the following command: + +$ sudo sysctl kernel.kexec_load_disabled +kernel.kexec_load_disabled = 1 + +If "kernel.kexec_load_disabled" is not set to "1" or is missing, this is a finding.SRG-OS-000368-GPOS-00154<GroupDescription></GroupDescription>AZLX-23-002580Amazon Linux 2023 must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory.<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001764Configure Amazon Linux 2023 so that the /boot/efi directory is mounted with the "nosuid" option. + +Modify "/etc/fstab" to use the "nosuid" option on the "/boot/efi" directory.Verify Amazon Linux 2023 is configured so that the /boot/efi directory is mounted with the "nosuid" option with the following command: + +$ mount | grep '\s/boot/efi\s' + +/dev/sda1 on /boot/efi type vfat (rw,nosuid,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=winnt,errors=remount-ro) + +If the /boot/efi file system does not have the "nosuid" option set, this is a finding.SRG-OS-000368-GPOS-00154<GroupDescription></GroupDescription>AZLX-23-002585Amazon Linux 2023 must mount /dev/shm with the nodev option.<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001764Configure Amazon Linux 2023 so that "/dev/shm" is mounted with the "nodev" option. + +Modify "/etc/fstab" to use the "nodev" option on the "/dev/shm" file system.Verify Amazon Linux 2023 is configured so that "/dev/shm" is mounted with the "nodev" option with the following command: + +$ mount | grep /dev/shm +tmpfs on /dev/shm type tmpfs (rw,nodev,nosuid,noexec,seclabel) + +If the /dev/shm file system is mounted without the "nodev" option, this is a finding.SRG-OS-000368-GPOS-00154<GroupDescription></GroupDescription>AZLX-23-002590Amazon Linux 2023 must mount /dev/shm with the nosuid option.<VulnDiscussion>The "nosuid" mount option causes the system to not execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001764Configure Amazon Linux 2023 so that "/dev/shm" is mounted with the "nosuid" option. + +Modify "/etc/fstab" to use the "nosuid" option on the "/dev/shm" file system.Verify Amazon Linux 2023 is configured so that "/dev/shm" is mounted with the "nosuid" option with the following command: + +$ mount | grep /dev/shm +tmpfs on /dev/shm type tmpfs (rw,nodev,nosuid,noexec,seclabel) + +If the /dev/shm file system is mounted without the "noexec" option, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>AZLX-23-002595Amazon Linux 2023 must ensure the pcscd service is active.<VulnDiscussion>The information system ensures that even if the information system is compromised, that compromise will not affect credentials stored on the authentication device. + +The daemon program for pcsc-lite and the MuscleCard framework is pcscd. It is a resource manager that coordinates communications with smart card readers and smart cards and cryptographic tokens connected to the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-004046Configure Amazon Linux 2023 so that the "pcscd" service is active with the following command: + +$ sudo systemctl enable --now pcscdVerify Amazon Linux 2023 is configured so that the "pcscd" service is active with the following command: + +$ systemctl is-active pcscd +active + +If the pcscdservice is not active, this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>AZLX-23-002600Amazon Linux 2023 file system automount function must be disabled unless required.<VulnDiscussion>Without authenticating devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. + +Peripherals include, but are not limited to, such devices as flash drives, external storage, and printers.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-001958Configure Amazon Linux 2023 to disable the ability to automount devices. + +The autofs service can be disabled with the following command: + +$ sudo systemctl mask --now autofs.serviceVerify Amazon Linux 2023 disables the file system automount function with the following command: + +$ sudo systemctl is-enabled autofs +masked + +If the returned value is not "masked", "disabled", "Failed to get unit file state for autofs.service for autofs", or "enabled", and is not documented as operational requirement with the information system security officer (ISSO), this is a finding.SRG-OS-000420-GPOS-00186<GroupDescription></GroupDescription>AZLX-23-002605Amazon Linux 2023 must protect against or limit the effects of denial-of-service (DoS) attacks by ensuring rate-limiting measures are configured on impacted network interfaces.<VulnDiscussion>DoS is a condition when a resource is not available for legitimate users. When this occurs, the organization either cannot accomplish its mission or must operate at degraded capacity. + +This requirement addresses the configuration of Amazon Linux 2023 to mitigate the impact of DoS attacks that have occurred or are ongoing on system availability. For each system, known and potential DoS attacks must be identified and solutions for each type implemented. A variety of technologies exist to limit or, in some cases, eliminate the effects of DoS attacks (e.g., limiting processes or establishing memory partitions). Employing increased capacity and bandwidth, combined with service redundancy, may reduce the susceptibility to some DoS attacks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002385Configure Amazon Linux 2023 to use the AWS ALB rate limiting feature using its built-in rate limiting capabilities. This allows the user to set rate limits at the ALB level, which will apply to all traffic passing through the load balancer.Verify Amazon Linux 2023 is implementing rate-limiting measures on network interfaces to protect against DoS attacks. + +Access the AWS Management Console: + +Sign in to the AWS Management Console and navigate to the EC2 service. + +To locate the Application Load Balancer (ALB) in the EC2 dashboard, go to the "Load Balancers" section and find the ALB. + +Check the ALB configuration: Click on the ALB to view its details. The listener configuration for the ALB is located in the "Listener" tab. + +Look for the rate limiting settings: Scroll down to the "Rules" section. If rate limiting is enabled, a rule with the "Rate Limit" action will be displayed.SRG-OS-000433-GPOS-00192<GroupDescription></GroupDescription>AZLX-23-002610Amazon Linux 2023 must implement nonexecutable data to protect its memory from unauthorized code execution.<VulnDiscussion>The no-execute (NX) feature uses the segmentation feature on all x86 systems to prevent execution in memory higher than a certain address. It writes an address as a limit in the code segment descriptor, to control where code can be executed, on a per-process basis. When the kernel places a process's memory regions such as the stack and heap higher than this address, the hardware prevents execution in that address range. This is enabled by default on the latest Red Hat and Fedora systems if supported by the hardware.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002824Configure Amazon Linux 2023 NX support to be enabled by opening a support case via the AWS Console to investigate why NX support is not detected.Verify Amazon Linux 2023 NX support is enabled with the following command: + +$ sudo dmesg | grep '[NX|DX]*protection' +[ 0.000000] NX (Execute Disable) protection: active + +If "dmesg" does not show "NX (Execute Disable) protection" active, this is a finding.SRG-OS-000437-GPOS-00194<GroupDescription></GroupDescription>AZLX-23-002615Amazon Linux 2023 must remove all software components after updated versions have been installed.<VulnDiscussion>Previous versions of software components that are not removed from the information system after updates have been installed may be exploited by some adversaries.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-002617Configure Amazon Linux 2023 to remove all software components after updated versions have been installed. + +Set the "clean_requirements_on_remove" option to "1" in the "/etc/dnf/dnf.conf" file: + +clean_requirements_on_remove=1Verify Amazon Linux 2023 removes all software components after updated versions have been installed with the following command: + +$ grep clean /etc/dnf/dnf.conf +clean_requirements_on_remove=1 + +If "clean_requirements_on_remove" is not set to "1", "True", or "yes", this is a finding.SRG-OS-000021-GPOS-00005<GroupDescription></GroupDescription>AZLX-23-002620Amazon Linux 2023 must configure the use of the pam_faillock.so module in the /etc/pam.d/system-auth file.<VulnDiscussion>If the pam_faillock.so module is not loaded, the system will not correctly lockout accounts to prevent password guessing attacks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000044Configure Amazon Linux 2023 to include the use of the pam_faillock.so module in the /etc/pam.d/system-auth file. + +Add/modify the appropriate sections of the "/etc/pam.d/system-auth" file to match the following lines: +Note: The "preauth" line must be listed before pam_unix.so. + +auth required pam_faillock.so preauth +auth required pam_faillock.so authfail +account required pam_faillock.soVerify Amazon Linux 2023 is configured so that the pam_faillock.so module is present in the "/etc/pam.d/system-auth" file: + +$ grep pam_faillock.so /etc/pam.d/system-auth +auth required pam_faillock.so preauth +auth required pam_faillock.so authfail +account required pam_faillock.so + +If the pam_faillock.so module is not present in the "/etc/pam.d/system-auth" file with the "preauth" line listed before pam_unix.so, this is a finding.SRG-OS-000462-GPOS-00206<GroupDescription></GroupDescription>AZLX-23-005000Amazon Linux 2023 audit system must protect logon user identifiers (UIDs) from unauthorized change.<VulnDiscussion>If modification of login UIDs is not prevented, they can be changed by nonprivileged users and make auditing complicated or impossible. + +Satisfies: SRG-OS-000462-GPOS-00206, SRG-OS-000475-GPOS-00220, SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPOS-00029</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Amazon Linux 2023DISADPMS TargetAmazon Linux 20235700CCI-000172CCI-000162CCI-000163CCI-000164Configure Amazon Linux 2023 auditing to prevent modification of login UIDs once they are set by adding the following line to /etc/audit/rules.d/audit.rules: + +--loginuid-immutable + +To load the rules to the kernel immediately, use the following command: + +$ sudo augenrules --loadVerify Amazon Linux 2023 is configured so that the audit system prevents unauthorized changes to login UIDs with the following command: + +$ sudo grep -i immutable /etc/audit/audit.rules +--loginuid-immutable + +If the "--loginuid-immutable" option is not returned in the "/etc/audit/audit.rules", or the line is commented out, this is a finding. \ No newline at end of file diff --git a/shared/references/disa-stig-ol8-v2r6-xccdf-manual.xml b/shared/references/disa-stig-ol8-v2r8-xccdf-manual.xml similarity index 79% rename from shared/references/disa-stig-ol8-v2r6-xccdf-manual.xml rename to shared/references/disa-stig-ol8-v2r8-xccdf-manual.xml index 00942589bb06..0c51b379d13f 100644 --- a/shared/references/disa-stig-ol8-v2r6-xccdf-manual.xml +++ b/shared/references/disa-stig-ol8-v2r8-xccdf-manual.xml @@ -1,4 +1,4 @@ -acceptedOracle Linux 8 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 6 Benchmark Date: 01 Oct 20253.5.11.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>OL08-00-030180The OL 8 audit package must be installed.<VulnDiscussion>Without establishing what type of events occurred and their source, location, and outcome, it would be difficult to establish, correlate, and investigate the events leading up to an outage or attack. +acceptedOracle Linux 8 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 8 Benchmark Date: 01 Apr 20263.5.21.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>SRG-OS-000780-GPOS-00240<GroupDescription></GroupDescription>OL09-00-000001The OL 9 operating system must implement cryptographic mechanisms to prevent unauthorized modification of all information at rest.<VulnDiscussion>Operating systems handling data requiring "data at rest" protections must employ cryptographic mechanisms to prevent unauthorized disclosure and modification of the information at rest. +acceptedOracle Linux 9 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 5 Benchmark Date: 01 Apr 20263.5.21.10.01I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000780-GPOS-00240<GroupDescription></GroupDescription>OL09-00-000001The OL 9 operating system must implement cryptographic mechanisms to prevent unauthorized modification of all information at rest.<VulnDiscussion>Operating systems handling data requiring "data at rest" protections must employ cryptographic mechanisms to prevent unauthorized disclosure and modification of the information at rest. Selection of a cryptographic mechanism is based on the need to protect the integrity of organizational information. The strength of the mechanism is commensurate with the security category and/or classification of the information. Organizations have the flexibility to either encrypt all information on storage devices (i.e., full disk encryption) or encrypt specific data structures (e.g., files, records, or fields).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-004910Configure the OL 9 operating system to implement cryptographic mechanisms to prevent unauthorized modification of all information at rest. @@ -63,12 +63,16 @@ If a separate entry for "/var/log" is not in use, this is a finding.SRG-OS-000439-GPOS-00195<GroupDescription></GroupDescription>OL09-00-000010OL 9 must be a vendor supported release.<VulnDiscussion>An operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software. +If a separate entry for "/var/tmp" is not in use, this is a finding.SRG-OS-000439-GPOS-00195<GroupDescription></GroupDescription>OL09-00-000010OL 9 must be a vendor supported release.<VulnDiscussion>An operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software. -Oracle offers Oracle Linux Premier Support, for a fee, for those customers who wish to standardize on a specific minor release for an extended period.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002605Upgrade OL 9 to a supported version.Verify that OL 9 is vendor supported with the following command: +End Of Life dates for Oracle Linux 9 releases are as follows: +Current end of Premier Support for Oracle Linux 9 is June 2032. +Current end of Extended Support for Oracle Linux 9 is June 2035. + +Each minor version reaches end of life when the new version is released.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002605Upgrade OL 9 to a supported version.Verify OL 9 is vendor supported with the following command: $ cat /etc/oracle-release -Oracle Linux Server release 9.5 +Oracle Linux Server release 9.6 If the installed version of OL 9 is not supported, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-000015OL 9 vendor packaged system security patches and updates must be installed and up to date.<VulnDiscussion>Installing software updates is a fundamental mitigation against the exploitation of publicly known vulnerabilities. If the most recent security patches and updates are not installed, unauthorized users may take advantage of weaknesses in the unpatched software. The lack of prompt attention to patching could result in a system compromise.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Install OL 9 security patches and updates at the organizationally defined frequency. If system updates are installed via a centralized repository that is configured on the system, all updates can be installed with the following command: @@ -99,7 +103,7 @@ If there is an operational requirement for a graphical user interface, document $ systemctl get-default multi-user.target -If the system default target is not set to "multi-user.target" and the information system security officer (ISSO) lacks a documented requirement for a graphical user interface, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-000025OL 9 must require authentication to access emergency mode.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. +If the system default target is not set to "multi-user.target" and the information system security officer (ISSO) lacks a documented requirement for a graphical user interface, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-000025OL 9 must require authentication to access emergency mode.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. This requirement prevents attackers with physical access from trivially bypassing security on the machine and gaining root access. Such accesses are further prevented by configuring the bootloader password.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000213Configure OL 9 to require authentication for emergency mode. @@ -110,7 +114,7 @@ ExecStart=-/usr/lib/systemd/systemd-sulogin-shell emergencySRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-000030OL 9 must require authentication to access single-user mode.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. +If this line is not returned, or is commented out, this is a finding. If the output is different, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-000030OL 9 must require authentication to access single-user mode.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. This requirement prevents attackers with physical access from trivially bypassing security on the machine and gaining root access. Such accesses are further prevented by configuring the bootloader password.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000213Configure OL 9 to require authentication for single-user mode. @@ -154,21 +158,22 @@ $ grep -r firewire-core /etc/modprobe.conf /etc/modprobe.d/* install firewire-core /bin/true blacklist firewire-core -If the command does not return any output, or the line is commented out, and use of firewire-core is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000043OL 9 must disable the Stream Control Transmission Protocol (SCTP) kernel module.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the command does not return any output, or the line is commented out, and use of firewire-core is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000043OL 9 must disable the Stream Control Transmission Protocol (SCTP) kernel module.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. Failing to disconnect unused protocols can result in a system compromise. -The SCTP is a transport layer protocol, designed to support the idea of message-oriented communication, with several streams of messages within one connection. Disabling SCTP protects the system against exploitation of any flaws in its implementation.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000381Configure OL 9 to prevent the sctp kernel module from being loaded. +The SCTP is a transport layer protocol, designed to support the idea of message-oriented communication, with several streams of messages within one connection. Disabling SCTP protects the system against exploitation of any flaws in its implementation.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000381Configure OL 9 to prevent the sctp kernel module from being loaded. Add the following line to the file /etc/modprobe.d/sctp.conf (or create sctp.conf if it does not exist): -install sctp/bin/false -blacklist sctpVerify that OL 9 disables the ability to load the sctp kernel module with the following command: +install sctp /bin/false +blacklist sctpVerify OL 9 disables the ability to load the sctp kernel module with the following command: -$ grep -r sctp /etc/modprobe.conf /etc/modprobe.d/* -blacklist sctp +$ grep -irs sctp /etc/modprobe.conf /etc/modprobe.d/* +/etc/modprobe.d/sctp.conf:install sctp /bin/false +/etc/modprobe.d/sctp.conf:blacklist sctp -If the command does not return any output, or the line is commented out, and use of sctp is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000044OL 9 must disable the Transparent Inter Process Communication (TIPC) kernel module.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the command does not return any output, or the line is commented out, and use of sctp is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000044OL 9 must disable the Transparent Inter Process Communication (TIPC) kernel module.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. Failing to disconnect unused protocols can result in a system compromise. @@ -177,12 +182,13 @@ The TIPC is a protocol that is specially designed for intra-cluster communicatio Add the following line to the file /etc/modprobe.d/tipc.conf (or create tipc.conf if it does not exist): install tipc /bin/false -blacklist tipcVerify that OL 9 disables the ability to load the tipc kernel module with the following command: +blacklist tipcVerify OL 9 disables the ability to load the tipc kernel module with the following command: -$ grep -r tipc /etc/modprobe.conf /etc/modprobe.d/* -blacklist tipc +$ grep -irs tipc /etc/modprobe.conf /etc/modprobe.d/* +/etc/modprobe.d/tipc.conf:install tipc /bin/false +/etc/modprobe.d/tipc.conf:blacklist tipc -If the command does not return any output, or the line is commented out, and use of TIPC is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000045OL 9 must disable mounting of cramfs.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the command does not return any output, or the line is commented out, and use of TIPC is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000045OL 9 must disable mounting of cramfs.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. Removing support for unneeded filesystem types reduces the local attack surface of the server. @@ -193,21 +199,13 @@ Add the following line to the file /etc/modprobe.d/cramfs.conf (or create blackl install cramfs /bin/false blacklist cramfs -Reboot the system for the settings to take effect.Verify that OL 9 disables the ability to load the cramfs kernel module with the following command: - -$ grep -ri cramfs /etc/modprobe.d/* | grep -i "/bin/false" -install cramfs /bin/false - -If the command does not return any output, or the line is commented out, and use of the cramfs protocol is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding. +Reboot the system for the settings to take effect.Verify OL 9 disables the ability to load the cramfs kernel module with the following command: -Verify the operating system disables the ability to use the cramfs kernel module. - -Determine if the cramfs kernel module is disabled with the following command: - -$ grep -ri cramfs /etc/modprobe.d/* | grep -i "blacklist" -blacklist cramfs +$ grep -irs cramfs /etc/modprobe.conf /etc/modprobe.d/* +/etc/modprobe.d/blacklist.conf:install cramfs /bin/false +/etc/modprobe.d/blacklist.conf:blacklist cramfs -If the command does not return any output or the output is not "blacklist cramfs", and use of the cramfs kernel module is not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000046OL 9 Bluetooth must be disabled.<VulnDiscussion>This requirement applies to wireless peripheral technologies (e.g., wireless mice, keyboards, displays, etc.) used with OL 9 systems. Wireless peripherals (e.g., Wi-Fi/Bluetooth/IR keyboards, mice and pointing devices, and near field communications [NFC]) present a unique challenge by creating an open, unsecured port on a computer. Wireless peripherals must meet DOD requirements for wireless data transmission and be approved for use by the authorizing official (AO). Even though some wireless peripherals, such as mice and pointing devices, do not ordinarily carry information that need to be protected, modification of communications with these wireless peripherals may be used to compromise the OL 9 operating system. +If the command does not return any output, or the line is commented out, and use of the cramfs protocol is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000046OL 9 Bluetooth must be disabled.<VulnDiscussion>This requirement applies to wireless peripheral technologies (e.g., wireless mice, keyboards, displays, etc.) used with OL 9 systems. Wireless peripherals (e.g., Wi-Fi/Bluetooth/IR keyboards, mice and pointing devices, and near field communications [NFC]) present a unique challenge by creating an open, unsecured port on a computer. Wireless peripherals must meet DOD requirements for wireless data transmission and be approved for use by the authorizing official (AO). Even though some wireless peripherals, such as mice and pointing devices, do not ordinarily carry information that need to be protected, modification of communications with these wireless peripherals may be used to compromise the OL 9 operating system. Satisfies: SRG-OS-000095-GPOS-00049, SRG-OS-000300-GPOS-00118</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000381CCI-001443Configure OL 9 to disable the Bluetooth adapter when not in use. @@ -235,7 +233,7 @@ $ grep -r usb-storage /etc/modprobe.conf /etc/modprobe.d/* install usb-storage /bin/false blacklist usb-storage -If the command does not return any output, or the line is commented out, and use of USB Storage is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-000050OL 9 must require a unique superuser's name upon booting into single-user and maintenance modes.<VulnDiscussion>Having a nondefault grub superuser username makes password-guessing attacks less effective.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000213Configure OL 9 to have a unique username for the grub superuser account. +If the command does not return any output, or the line is commented out, and use of USB Storage is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-000050OL 9 must require a unique superuser's name upon booting into single-user and maintenance modes.<VulnDiscussion>Having a nondefault grub superuser username makes password-guessing attacks less effective.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000213Configure OL 9 to have a unique username for the grub superuser account. Edit the "/etc/grub.d/01_users" file and add or modify the following lines in the "### BEGIN /etc/grub.d/01_users ###" section: @@ -378,13 +376,15 @@ $ sudo dnf remove telnet-serverSRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000115OL 9 must not have the gssproxy package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the "telnet-server" package is installed, this is a finding.SRG-OS-000095-GPOS-00049<GroupDescription></GroupDescription>OL09-00-000115OL 9 must not have the gssproxy package installed.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. Operating systems are capable of providing a wide variety of functions and services. Some of the functions and services provided by default may not be necessary to support essential organizational operations (e.g., key missions, functions). The gssproxy package is a proxy for GSS API credential handling and could expose secrets on some networks. It is not needed for normal function of the OS.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000381Remove the gssproxy package with the following command: -$ sudo dnf remove gssproxyVerify that OL 9 does not have the gssproxy package installed with the following command: +$ sudo dnf remove gssproxyNote: If NFS mounts are authorized and in use on the system, this is not applicable. + +Verify OL 9 does not have the gssproxy package installed with the following command: $ dnf list --installed gssproxy Error: No matching Packages to list @@ -411,34 +411,25 @@ $ sudo dnf remove tunedSRG-OS-000074-GPOS-00042<GroupDescription></GroupDescription>OL09-00-000130OL 9 must not have a File Transfer Protocol (FTP) server package installed.<VulnDiscussion>The FTP service provides an unencrypted remote access that does not provide for the confidentiality and integrity of user passwords or the remote session. If a privileged user were to log on using this service, the privileged user password could be compromised. SSH or other encrypted file transfer methods must be used in place of this service. +If the "tuned" package is installed and is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000074-GPOS-00042<GroupDescription></GroupDescription>OL09-00-000130OL 9 must not have a File Transfer Protocol (FTP) server package installed.<VulnDiscussion>The FTP service provides an unencrypted remote access that does not provide for the confidentiality and integrity of user passwords or the remote session. If a privileged user were to log on using this service, the privileged user password could be compromised. SSH or other encrypted file transfer methods must be used in place of this service. Removing the "vsftpd" package decreases the risk of accidental activation. -Satisfies: SRG-OS-000074-GPOS-00042, SRG-OS-000095-GPOS-00049</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000197CCI-000381Remove the ftp package can be removed with the following command (using vsftpd as an example): - -$ sudo dnf remove vsftpdVerify that OL 9 does not have an FTP server package installed with the following command: +Satisfies: SRG-OS-000074-GPOS-00042, SRG-OS-000095-GPOS-00049</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000197CCI-000381Remove the vsftpd package with the following command: -$ dnf list --installed | grep ftp +$ sudo dnf remove vsftpdVerify OL 9 does not have an FTP server package installed with the following command: -If the "ftp" package is installed, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-000135OL 9 must not have a Trivial File Transfer Protocol (TFTP) server package installed.<VulnDiscussion>Removing the "tftp-server" package decreases the risk of the accidental (or intentional) activation of tftp services. +$ dnf list --installed | grep vsftpd -If TFTP is required for operational support (such as transmission of router configurations), its use must be documented with the information systems security manager (ISSM), restricted to only authorized personnel, and have access control rules established.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Remove the tftp package can be removed with the following command: +If the "vsftpd" package is installed, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-000135OL 9 must not have a Trivial File Transfer Protocol (TFTP) server package installed.<VulnDiscussion>Removing the "tftp-server" package decreases the risk of the accidental (or intentional) activation of tftp services. -$ sudo dnf remove tftpVerify that OL 9 does not have a tftp server package installed with the following command: +If TFTP is required for operational support (such as transmission of router configurations), its use must be documented with the information systems security manager (ISSM), restricted to only authorized personnel, and have access control rules established.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Remove the tftp-server package with the following command: -$ dnf list --installed | grep tftp +$ sudo dnf remove tftp-serverVerify OL 9 does not have a tftp server package installed with the following command: -If the "tftp" package is installed, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-000140OL 9 must not have the quagga package installed.<VulnDiscussion>Quagga is a network routing software suite providing implementations of Open Shortest Path First (OSPF), Routing Information Protocol (RIP), Border Gateway Protocol (BGP) for Unix and Linux platforms. +$ dnf list --installed | grep tftp-server -If there is no need to make the router software available, removing it provides a safeguard against its activation.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Remove the quagga package with the following command: - -$ sudo dnf remove quaggaVerify that OL 9 does not have the quagga package installed with the following command: - -$ dnf list --installed quagga -Error: No matching Packages to list - -If the quagga package is installed and is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-000145OL 9 must not have a graphical display manager installed unless approved.<VulnDiscussion>Unnecessary service packages must not be installed to decrease the attack surface of the system. Graphical display managers have a long history of security vulnerabilities and must not be used, unless approved and documented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000382Remove all xorg packages with the following command: +If the "tftp-server" package is installed, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-000145OL 9 must not have a graphical display manager installed unless approved.<VulnDiscussion>Unnecessary service packages must not be installed to decrease the attack surface of the system. Graphical display managers have a long history of security vulnerabilities and must not be used, unless approved and documented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000382Remove all xorg packages with the following command: Warning: If accessing the system through the graphical user interface, change to the multi-user.target with the following command: @@ -627,23 +618,23 @@ $ sudo sh -c 'grep -iw ALL /etc/sudoers /etc/sudoers.d/*' If the either of the following entries are returned, this is a finding: ALL ALL=(ALL) ALL -ALL ALL=(ALL:ALL) ALLSRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>OL09-00-000240OL 9 must have the crypto-policies package installed.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. +ALL ALL=(ALL:ALL) ALLSRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>OL09-00-000240OL 9 must have the crypto-policies package installed.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002450CCI-002890CCI-003123Install the crypto-policies package (if not already installed) with the following command: -$ sudo dnf install -y crypto-policiesVerify that OL 9 crypto-policies package is installed with the following command: +$ sudo dnf install -y crypto-policiesVerify the OL 9 crypto-policies package is installed with the following command: $ dnf list --installed crypto-policies Installed Packages crypto-policies.noarch 20240202-1.git283706d.el9 @ol9_baseos_latest -If the crypto-policies package is not installed, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>OL09-00-000241OL 9 must implement a FIPS 140-3 compliant system-wide cryptographic policy.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. +If the crypto-policies package is not installed, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>OL09-00-000241OL 9 must implement a FIPS 140-3 compliant systemwide cryptographic policy.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. -Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002450CCI-002890CCI-003123Configure OL 9 to use a modified FIPS compliant systemwide crypto-policy. +Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002450CCI-002890CCI-003123Configure OL 9 to use a modified FIPS-compliant systemwide crypto-policy. Create subpolicies for enhancements to the systemwide crypto-policy with the following commands: -Create or edit the SCOPES-AND-WILDCARDS policy module in a text editor and insert options that modify the system-wide cryptographic policy as follows: +Create or edit the SCOPES-AND-WILDCARDS policy module in a text editor and insert options that modify the systemwide cryptographic policy as follows: $ sudo vi /etc/crypto-policies/policies/modules/SCOPES-AND-WILDCARDS.pmod @@ -656,7 +647,7 @@ cipher@TLS = -CHACHA20-POLY1305 cipher@SSH = -*-CBC -Create or edit the OPENSSH-SUBPOLICY module in a text editor and insert options that modify the system-wide crypto-policy as follows: +Create or edit the OPENSSH-SUBPOLICY module in a text editor and insert options that modify the systemwide crypto-policy as follows: $ sudo vi /etc/crypto-policies/policies/modules/OPENSSH-SUBPOLICY.pmod @@ -677,7 +668,7 @@ Add the following lines to REQUIRE.pmod: @OPENSSH-SUBPOLICY @SCOPES-AND-WILDCARDS -Apply the policy enhancements to the FIPS system-wide cryptographic policy level with the following command: +Apply the policy enhancements to the FIPS systemwide cryptographic policy level with the following command: $ sudo update-crypto-policies --set FIPS @@ -685,12 +676,12 @@ Note: If additional subpolicies are being employed, they must be added to the RE To make the cryptographic settings effective for already running services and applications, restart the system: -$ sudo rebootVerify that OL 9 is set to use a modified FIPS compliant systemwide crypto-policy. +$ sudo rebootVerify OL 9 is set to use a modified FIPS compliant systemwide crypto-policy. $ update-crypto-policies --show FIPS -If the system wide crypto policy is not set to "FIPS", this is a finding. +If the systemwide crypto-policy is not set to "FIPS", this is a finding. Note: If subpolicies have been configured, they will be listed in a colon-separated list starting with FIPS as follows: @@ -702,13 +693,13 @@ $ grep -E 'rsa_size|hash' /etc/crypto-policies/state/CURRENT.pol hash = SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512 SHAKE-256 min_rsa_size = 2048 -If the "hash" values do not include at least the following FIPS 140-3 compliant algorithms "SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512 SHAKE-256", this is a finding. +If the "hash" values do not include at least the following FIPS 140-3-compliant algorithms, "SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512 SHAKE-256", this is a finding. -If there are algorithms that include "SHA1" or a hash value less than "256" this is a finding. +If there are algorithms that include "SHA1" or a hash value less than "256", this is a finding. If the "min_rsa_size" is not set to a value of at least 2048, this is a finding. -If these commands do not return any output, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>OL09-00-000242OL 9 must not allow the cryptographic policy to be overridden.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. +If these commands do not return any output, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>OL09-00-000242OL 9 must not allow the cryptographic policy to be overridden.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002450CCI-002890CCI-003123Configure OL 9 to correctly implement the systemwide cryptographic policies by reinstalling the crypto-policies package contents. @@ -722,9 +713,9 @@ $ sudo update-crypto-policies --set FIPS Setting system policy to FIPS -Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify that OL 9 cryptographic policies are not overridden. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify OL 9 cryptographic policies are not overridden. -Verify that the configured policy matches the generated policy with the following command: +Verify the configured policy matches the generated policy with the following command: $ sudo update-crypto-policies --check && echo PASS The configured policy matches the generated policy @@ -773,17 +764,7 @@ List files on the system that have file hashes different from what is expected b $ sudo rpm -Va --noconfig | awk '$1 ~ /..5/ && $2 != "c"' -If there is output, this is a finding.SRG-OS-000478-GPOS-00223<GroupDescription></GroupDescription>OL09-00-000244OL 9 cryptographic policy files must match files shipped with the operating system.<VulnDiscussion>The OL 9 package crypto-policies defines the cryptography policies for the system. - -If the files are changed from those shipped with the operating system, it may be possible for OL 9 to use cryptographic functions that are not FIPS 140-3 approved. - -Satisfies: SRG-OS-000478-GPOS-00223, SRG-OS-000396-GPOS-00176</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002450Reinstall the crypto-policies package to remove any modifications. - -$ sudo dnf reinstall -y crypto-policiesVerify that OL 9 crypto-policies package has not been modified with the following command: - -$ rpm -V crypto-policies - -If the command has any output, this is a finding.SRG-OS-000423-GPOS-00187<GroupDescription></GroupDescription>OL09-00-000250OL 9 networked systems must have SSH installed.<VulnDiscussion>Without protection of the transmitted information, confidentiality and integrity may be compromised because unprotected communications can be intercepted and either read or altered. +If there is output, this is a finding.SRG-OS-000423-GPOS-00187<GroupDescription></GroupDescription>OL09-00-000250OL 9 networked systems must have SSH installed.<VulnDiscussion>Without protection of the transmitted information, confidentiality and integrity may be compromised because unprotected communications can be intercepted and either read or altered. This requirement applies to both internal and external networks and all types of information system components from which information can be transmitted (e.g., servers, mobile devices, notebook computers, printers, copiers, scanners, and facsimile machines). Communication paths outside the physical protection of a controlled boundary are exposed to the possibility of interception and modification. @@ -812,25 +793,7 @@ Verify that "sshd" is active with the following command: $ systemctl is-active sshd active -If the "sshd" service is not active, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000252The OL 9 SSH daemon must be configured to use systemwide cryptographic policies.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -OL 9 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/ directory.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001453Configure the OL 9 SSH daemon to use systemwide cryptographic policies by running the following commands: - -$ sudo dnf reinstall -y openssh-serverVerify that OL 9 is configured to implement systemwide cryptographic policies when the SSH daemon is invoked. - -Verify that systemwide cryptographic policies are in effect with the following command: - -$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*include' -/etc/ssh/sshd_config:Include /etc/ssh/sshd_config.d/*.conf -/etc/ssh/sshd_config.d/50-redhat.conf:Include /etc/crypto-policies/back-ends/opensshserver.config - -If "Include /etc/ssh/sshd_config.d/*.conf" or "Include /etc/crypto-policies/back-ends/opensshserver.config" are not included in the system sshd config this is a finding. - -Additionally, if the file /etc/ssh/sshd_config.d/50-redhat.conf is missing, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000254OL 9 SSH server must be configured to use only ciphers employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If the "sshd" service is not active, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000254OL 9 SSH server must be configured to use only ciphers employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. @@ -848,14 +811,14 @@ $ sudo update-crypto-policies --set FIPS Setting system policy to FIPS -Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify that OL 9 SSH server is configured to use only ciphers employing FIPS 140-3 approved algorithms. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify OL 9 SSH server is configured to use only ciphers employing FIPS 140-3 approved algorithms. To verify the ciphers in the systemwide SSH configuration file, use the following command: $ sudo grep -i Ciphers /etc/crypto-policies/back-ends/opensshserver.config Ciphers aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr -If the cipher entries in the "opensshserver.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000255OL 9 SSH server must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If the cipher entries in the "opensshserver.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000255OL 9 SSH server must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. @@ -873,7 +836,7 @@ $ sudo update-crypto-policies --set FIPS Setting system policy to FIPS -Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify that OL 9 SSH server is configured to use only MACs employing FIPS 140-3 approved algorithms. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify OL 9 SSH server is configured to use only MACs employing FIPS 140-3 approved algorithms. To verify the MACs in the systemwide SSH configuration file, use the following command: @@ -903,7 +866,7 @@ $ dnf list --installed openssh-clients Installed Packages openssh-clients.x86_64 8.7p1-38.0.2.el9_4.4 @ol9_baseos_latest -If the openssh-clients package is not installed, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000261OL 9 SSH client must be configured to use only DOD-approved encryption ciphers employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH client connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If the openssh-clients package is not installed, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000261OL 9 SSH client must be configured to use only DOD-approved encryption ciphers employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH client connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. @@ -921,14 +884,14 @@ $ sudo update-crypto-policies --set FIPS Setting system policy to FIPS -Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify that OL 9 is configured so that the SSH client uses only ciphers employing FIPS 140-3 approved algorithms. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify OL 9 is configured so that the SSH client uses only ciphers employing FIPS 140-3 approved algorithms. To verify the ciphers in the systemwide SSH configuration file, use the following command: $ grep -i Ciphers /etc/crypto-policies/back-ends/openssh.config Ciphers aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr -If the cipher entries in the "openssh.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000262OL 9 SSH client must be configured to use only DOD-approved Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH client connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If the cipher entries in the "openssh.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>OL09-00-000262OL 9 SSH client must be configured to use only DOD-approved Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms to protect the confidentiality of SSH client connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. @@ -946,7 +909,7 @@ $ sudo update-crypto-policies --set FIPS Setting system policy to FIPS -Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify that OL 9 is configured so that the SSH client uses only MACs employing FIPS 140-3 approved algorithms. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify OL 9 is configured so that the SSH client uses only MACs employing FIPS 140-3 approved algorithms. To verify the MACs in the systemwide SSH configuration file, use the following command: @@ -963,25 +926,7 @@ $ dnf list --installed openssl-pkcs11 Installed Packages openssl-pkcs11.x86_64 0.4.11-9.el9 @ol9_baseos_latest -If the "openssl-pkcs11" package is not installed, this is a finding.SRG-OS-000705-GPOS-00150<GroupDescription></GroupDescription>OL09-00-000280OL 9 must implement multifactor authentication for remote access to privileged accounts in such a way that one of the factors is provided by a device separate from the system gaining access.<VulnDiscussion>Using an authentication device, such as a CAC or token that is separate from the information system, ensures that even if the information system is compromised, that compromise will not affect credentials stored on the authentication device. - -Multifactor solutions that require devices separate from information systems gaining access include, for example, hardware tokens providing time-based or challenge-response authenticators and smart cards such as the U.S. Government Personal Identity Verification card and the DOD Common Access Card. - -A privileged account is defined as an information system account with authorizations of a privileged user. - -Remote access is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -This requirement only applies to components where this is specific to the function of the device or has the concept of an organizational user (e.g., VPN, proxy capability). This does not apply to authentication for the purpose of configuring the device itself (management).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-004047Configure OL 9 to implement multifactor authentication by installing the required packages. - -Install the "libpam-pkcs11" package on the system with the following command: - -$ sudo dnf install -y libpam-pkcs11Verify that OL 9 has the packages required for multifactor authentication installed with the following command: - -$ dnf list --installed libpam-pkcs11 - -ii libpam-pkcs11 0.6.12-2build3 amd64 Fully featured PAM module for using PKCS#11 smart cards - -If the "libpam-pkcs11" package is not installed, this is a finding.SRG-OS-000705-GPOS-00150<GroupDescription></GroupDescription>OL09-00-000285OL 9 must have the SSSD package installed.<VulnDiscussion>Using an authentication device, such as a CAC or token that is separate from the information system, ensures that even if the information system is compromised, that compromise will not affect credentials stored on the authentication device. +If the "openssl-pkcs11" package is not installed, this is a finding.SRG-OS-000705-GPOS-00150<GroupDescription></GroupDescription>OL09-00-000285OL 9 must have the SSSD package installed.<VulnDiscussion>Using an authentication device, such as a CAC or token that is separate from the information system, ensures that even if the information system is compromised, that compromise will not affect credentials stored on the authentication device. Multifactor solutions that require devices separate from information systems gaining access include, for example, hardware tokens providing time-based or challenge-response authenticators and smart cards such as the U.S. Government Personal Identity Verification card and the DOD Common Access Card. @@ -1205,15 +1150,7 @@ active If usbguard is not active, ask the SA to indicate how unauthorized peripherals are being blocked. -If there is no evidence that unauthorized peripherals are being blocked before establishing a connection, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>OL09-00-000330OL 9 must have the subscription-manager package installed.<VulnDiscussion>Oracle Linux Manager, based on the Spacewalk open source software, helps automate Oracle Linux systems management. This enables users to control the system software life cycle from initial installation through maintenance, software configuration, upgrades, and eventual decommissioning. Oracle Linux Manager also helps automate a kickstart installation, system configuration, and maintenance tasks, which enables rapid deployment of proven and consistent software configurations for Oracle Linux systems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-003992Install the oracle-linux-manager package with the following command: - -$ sudo dnf install -y oracle-linux-manager-client-release-el9Verify that OL 9 oracle-linux-manager package is installed with the following command: - -$ dnf list installed oracle-linux-manager-client-release-el9 -Installed Packages -oracle-linux-manager-client-release-el9.noarch 1.0-2.el9 @ol9_baseos_latest - -If the "oracle-linux-manager" package is not installed, this is a finding.SRG-OS-000370-GPOS-00155<GroupDescription></GroupDescription>OL09-00-000340OL 9 must have the fapolicy module installed.<VulnDiscussion>The organization must identify authorized software programs and permit execution of authorized software. The process used to identify software programs that are authorized to execute on organizational information systems is commonly referred to as allowlisting. +If there is no evidence that unauthorized peripherals are being blocked before establishing a connection, this is a finding.SRG-OS-000370-GPOS-00155<GroupDescription></GroupDescription>OL09-00-000340OL 9 must have the fapolicy module installed.<VulnDiscussion>The organization must identify authorized software programs and permit execution of authorized software. The process used to identify software programs that are authorized to execute on organizational information systems is commonly referred to as allowlisting. Using an allowlist provides a configuration management method for allowing the execution of only authorized software. Using only authorized software decreases risk by limiting the number of potential vulnerabilities. Verification of allowlisted software occurs prior to execution or at system startup. @@ -2352,7 +2289,7 @@ $ sudo service auditd restartSRG-OS-000256-GPOS-00097<GroupDescription></GroupDescription>OL09-00-000710OL 9 must use cryptographic mechanisms to protect the integrity of audit tools.<VulnDiscussion>Protecting the integrity of the tools used for auditing purposes is a critical step toward ensuring the integrity of audit information. Audit information includes all information (e.g., audit records, audit settings, and audit reports) needed to successfully audit information system activity. +If the command does not return an audit rule for umount or any of the lines returned are commented out, this is a finding.SRG-OS-000256-GPOS-00097<GroupDescription></GroupDescription>OL09-00-000710OL 9 must use cryptographic mechanisms to protect the integrity of audit tools.<VulnDiscussion>Protecting the integrity of the tools used for auditing purposes is a critical step toward ensuring the integrity of audit information. Audit information includes all information (e.g., audit records, audit settings, and audit reports) needed to successfully audit information system activity. Audit tools include, but are not limited to, vendor-provided and open-source audit tools needed to successfully view and manipulate audit information system activity and records. Audit tools include custom queries and report generators. @@ -2360,7 +2297,7 @@ It is not uncommon for attackers to replace the audit tools or inject code into To address this risk, audit tools must be cryptographically signed to provide the capability to identify when the audit tools have been modified, manipulated, or replaced. An example is a checksum hash of the file or files. -Satisfies: SRG-OS-000256-GPOS-00097, SRG-OS-000257-GPOS-00098, SRG-OS-000258-GPOS-00099, SRG-OS-000278-GPOS-00108</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001493CCI-001494CCI-001495CCI-001496Configure OL 9 to protect the integrity of the audit tools. +Satisfies: SRG-OS-000256-GPOS-00097, SRG-OS-000257-GPOS-00098, SRG-OS-000258-GPOS-00099, SRG-OS-000278-GPOS-00108</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001493CCI-001494CCI-001495CCI-001496Configure OL 9 to protect the integrity of the audit tools. Add or update the following lines to /etc/aide.conf: @@ -2369,8 +2306,7 @@ Add or update the following lines to /etc/aide.conf: /usr/sbin/ausearch p+i+n+u+g+s+b+acl+xattrs+sha512 /usr/sbin/aureport p+i+n+u+g+s+b+acl+xattrs+sha512 /usr/sbin/autrace p+i+n+u+g+s+b+acl+xattrs+sha512 -/usr/sbin/autrace p+i+n+u+g+s+b+acl+xattrs+sha512 -/usr/sbin/augenrules p+i+n+u+g+s+b+acl+xattrs+sha512Verify that OL 9 uses cryptographic mechanisms to protect the integrity of the audit tools with the following command: +/usr/sbin/augenrules p+i+n+u+g+s+b+acl+xattrs+sha512Verify OL 9 uses cryptographic mechanisms to protect the integrity of the audit tools with the following command: $ sudo cat /etc/aide.conf | grep /usr/sbin/au /usr/sbin/auditctl p+i+n+u+g+s+b+acl+xattrs+sha512 @@ -2378,7 +2314,6 @@ $ sudo cat /etc/aide.conf | grep /usr/sbin/au /usr/sbin/ausearch p+i+n+u+g+s+b+acl+xattrs+sha512 /usr/sbin/aureport p+i+n+u+g+s+b+acl+xattrs+sha512 /usr/sbin/autrace p+i+n+u+g+s+b+acl+xattrs+sha512 -/usr/sbin/autrace p+i+n+u+g+s+b+acl+xattrs+sha512 /usr/sbin/augenrules p+i+n+u+g+s+b+acl+xattrs+sha512 If AIDE is not installed, ask the system administrator (SA) how file integrity checks are performed on the system. @@ -2768,7 +2703,7 @@ $ sudo service auditd restartSRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>OL09-00-000840OL 9 must be configured so that successful/unsuccessful uses of the umount system call generate an audit record.<VulnDiscussion>The changing of file permissions could indicate that a user is attempting to gain access to information that would otherwise be disallowed. Auditing DAC modifications can facilitate the identification of patterns of abuse among both authorized and unauthorized users. +If the "log_format" option is not "ENRICHED", or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>OL09-00-000840OL 9 must be configured so that successful/unsuccessful uses of the umount system call generate an audit record.<VulnDiscussion>The changing of file permissions could indicate that a user is attempting to gain access to information that would otherwise be disallowed. Auditing DAC modifications can facilitate the identification of patterns of abuse among both authorized and unauthorized users. Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000130CCI-000169CCI-002884CCI-000172Configure the audit system to generate an audit event for any successful/unsuccessful use of the umount system call by adding or updating the following rules in "/etc/audit/audit.rules" and adding the following rules to "/etc/audit/rules.d/perm_mod.rules" or updating the existing rules in files in the "/etc/audit/rules.d/" directory: @@ -2777,17 +2712,13 @@ Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPO The audit daemon must be restarted for the changes to take effect. Restart auditd: -$ sudo service auditd restartVerify that OL 9 generates an audit record for all uses of the umount system call with the following commands: - -$ sudo grep "umount" /etc/audit/audit.* +$ sudo service auditd restartVerify OL 9 is configured to audit the execution of the "umount" command with the following command: -$ sudo grep umount /etc/audit/audit.rules - -If the system is configured to audit this activity, it will return a line like the following: +$ sudo auditctl -l | grep umount --a always,exit -F arch=b32 -S umount -F auid>=1000 -F auid!=unset -k privileged-umount +-a always,exit -F arch=b32 -S umount -F auid>=1000 -F auid!=-1 -F key=privileged-umount -If the command does not return a line or the line is commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>OL09-00-000845OL 9 must be configured so that successful/unsuccessful uses of the umount2 system call generate an audit record.<VulnDiscussion>The changing of file permissions could indicate that a user is attempting to gain access to information that would otherwise be disallowed. Auditing discretionary access control (DAC) modifications can facilitate the identification of patterns of abuse among both authorized and unauthorized users. +If the command does not return an audit rule for "umount" or any of the lines returned are commented out, this is a finding.SRG-OS-000037-GPOS-00015<GroupDescription></GroupDescription>OL09-00-000845OL 9 must be configured so that successful/unsuccessful uses of the umount2 system call generate an audit record.<VulnDiscussion>The changing of file permissions could indicate that a user is attempting to gain access to information that would otherwise be disallowed. Auditing discretionary access control (DAC) modifications can facilitate the identification of patterns of abuse among both authorized and unauthorized users. Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPOS-00172, SRG-OS-000462-GPOS-00206, SRG-OS-000471-GPOS-00215</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000130CCI-000169CCI-002884CCI-000172Configure the audit system to generate an audit event for any successful/unsuccessful use of the umount2 system call by adding the following rules to a rules file in /etc/audit/rules.d/ directory: (Example /etc/audit/rules.d/audit.rules) @@ -2797,15 +2728,14 @@ Satisfies: SRG-OS-000037-GPOS-00015, SRG-OS-000062-GPOS-00031, SRG-OS-000392-GPO The audit daemon must be restarted for the changes to take effect. Restart auditd: -$ sudo service auditd restartVerify that OL 9 generates an audit record for all uses of the umount2 system call with the following commands: - -$ sudo grep "umount2" /etc/audit/audit.rules +$ sudo service auditd restartVerify OL 9 generates an audit record for all uses of the umount2 system call with the following commands: -$ sudo sh -c 'grep "umount2" /etc/audit/audit.rules' +$ sudo auditctl -l | grep umount2 -If the system is configured to audit this activity, it will return a line. +-a always,exit -F arch=b32 -S umount2 -F auid>=1000 -F auid!=-1 -F key=privileged-umount +-a always,exit -F arch=b64 -S umount2 -F auid>=1000 -F auid!=-1 -F key=privileged-umount -If no line is returned, this is a finding.SRG-OS-000341-GPOS-00132<GroupDescription></GroupDescription>OL09-00-000850OL 9 must allocate audit record storage capacity to store at least one week's worth of audit records.<VulnDiscussion>To ensure OL 9 systems have a sufficient storage capacity in which to write the audit logs, OL 9 needs to be able to allocate audit record storage capacity. +If the command does not return an audit rule for "umount2" or any of the lines returned are commented out, this is a finding.SRG-OS-000341-GPOS-00132<GroupDescription></GroupDescription>OL09-00-000850OL 9 must allocate audit record storage capacity to store at least one week's worth of audit records.<VulnDiscussion>To ensure OL 9 systems have a sufficient storage capacity in which to write the audit logs, OL 9 needs to be able to allocate audit record storage capacity. The task of allocating audit record storage capacity is usually performed during initial installation of OL 9. @@ -3342,7 +3272,7 @@ Note: Manual changes to the listed file may be overwritten by the "authselect" p $ grep -i nullok /etc/pam.d/system-auth /etc/pam.d/password-auth -If output is produced, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-001115OL 9 must require a boot loader superuser password.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. +If output is produced, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>OL09-00-001115OL 9 must require a boot loader superuser password.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. Password protection on the boot loader configuration ensures users with physical access cannot trivially alter important bootloader settings. These include which kernel to use, and whether to enter single-user mode.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000213Configure OL 9 to require a grub bootloader password for the grub superuser account. @@ -3404,16 +3334,7 @@ $ sudo systemctl mask --now autofs.serviceSRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002010OL 9 must be configured so that the Network File System (NFS) is configured to use RPCSEC_GSS.<VulnDiscussion>When an NFS server is configured to use RPCSEC_SYS, a selected userid and groupid are used to handle requests from the remote user. The userid and groupid could mistakenly or maliciously be set incorrectly. The RPCSEC_GSS method of authentication uses certificates on the server and client systems to authenticate the remote mount request more securely.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Update the "/etc/fstab" file so the option "sec" is defined for each NFS mounted file system and the "sec" option does not have the "sys" setting. - -Ensure the "sec" option is defined as "krb5p:krb5i:krb5".If no NFS mounts are configured, this requirement is Not Applicable. - -Verify that OL 9 has the "sec" option configured for all NFS mounts with the following command: - -$ cat /etc/fstab | grep nfs -192.168.22.2:/mnt/export /data nfs4 rw,nosuid,nodev,noexec,sync,soft,sec=krb5p:krb5i:krb5 - -If the system is mounting file systems via NFS and has the sec option without the "krb5:krb5i:krb5p" settings, the "sec" option has the "sys" setting, or the "sec" option is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002011OL 9 must prevent special devices on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Update each NFS mounted file system to use the "nodev" option on file systems that are being imported via NFS.If no NFS mounts are configured, this requirement is Not Applicable. +If the returned value is not "masked" and is not documented as operational requirement with the information system security officer (ISSO), this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002011OL 9 must prevent special devices on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Update each NFS mounted file system to use the "nodev" option on file systems that are being imported via NFS.If no NFS mounts are configured, this requirement is Not Applicable. Verify that OL 9 has the "nodev" option configured for all NFS mounts with the following command: @@ -3467,11 +3388,9 @@ Verify that the /boot directory is mounted with the "nosuid" option with the fol $ mount | grep '\s/boot\s' /dev/sda1 on /boot type xfs (rw,nosuid,relatime,seclabe,attr2,inode64,noquota) -If the /boot file system does not have the "nosuid" option set, this is a finding.SRG-OS-000368-GPOS-00154<GroupDescription></GroupDescription>OL09-00-002032OL 9 must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory.<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001764Configure OL 9 to prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory. - -Modify "/etc/fstab" to use the "nosuid" option on the "/boot/efi" directory.For systems that use BIOS, this requirement is Not Applicable. +If the /boot file system does not have the "nosuid" option set, this is a finding.SRG-OS-000368-GPOS-00154<GroupDescription></GroupDescription>OL09-00-002032OL 9 must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory.<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001764Configure OL 9 to prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory. -Verify that OL 9 /boot/efi directory is mounted with the "nosuid" option with the following command: +Modify "/etc/fstab" to use the "nosuid" option on the "/boot/efi" directory.Verify OL 9 /boot/efi directory is mounted with the "nosuid" option with the following command: $ mount | grep '\s/boot/efi\s' /dev/sda1 on /boot/efi type vfat (rw,nosuid,relatime,fmask=0077,dmask=0077,codepage=437,iocharset=ascii,shortname=winnt,errors=remount-ro) @@ -3667,9 +3586,9 @@ Note: If a separate file system has not been created for the user home directori $ mount | grep /home tmpfs on /home type xfs (rw,nodev,nosuid,noexec,seclabel) -If the "/home" file system is mounted without the "noexec" option, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002080OL 9 must prevent special devices on nonroot local partitions.<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access. +If the "/home" file system is mounted without the "noexec" option, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002080OL 9 must prevent special devices on nonroot local partitions.<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access. -The only legitimate location for device files is the "/dev" directory located on the root partition, with the exception of chroot jails if implemented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the "/etc/fstab" to use the "nodev" option on all nonroot local partitions.Verify that OL 9 prevents special devices on nonroot local partitions. +The only legitimate location for device files is the "/dev" directory located on the root partition, with the exception of chroot jails if implemented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the "/etc/fstab" to use the "nodev" option on all nonroot local partitions.Verify OL 9 prevents special devices on nonroot local partitions. Verify all nonroot local partitions are mounted with the "nodev" option with the following command: @@ -3755,30 +3674,30 @@ Verify that OL 9 initiates a session lock for graphical user interfaces when the $ gsettings get org.gnome.desktop.screensaver lock-delay uint32 5 -If the "uint32" setting is not set to "5" or less, or is missing, this is a finding.SRG-OS-000029-GPOS-00010<GroupDescription></GroupDescription>OL09-00-002104OL 9 must automatically lock graphical user sessions after 15 minutes of inactivity.<VulnDiscussion>A session time-out lock is a temporary action taken when a user stops work and moves away from the immediate physical vicinity of the information system but does not logout because of the temporary nature of the absence. Rather than relying on the user to manually lock their operating system session prior to vacating the vicinity, the GNOME desktop can be configured to identify when a user's session has idled and take action to initiate a session lock. +If the "uint32" setting is not set to "5" or less, or is missing, this is a finding.SRG-OS-000029-GPOS-00010<GroupDescription></GroupDescription>OL09-00-002104OL 9 must automatically lock graphical user sessions after 15 minutes of inactivity.<VulnDiscussion>A session time-out lock is a temporary action taken when a user stops work and moves away from the immediate physical vicinity of the information system but does not logout because of the temporary nature of the absence. Rather than relying on the user to manually lock their operating system session prior to vacating the vicinity, the GNOME desktop can be configured to identify when a user's session has idled and take action to initiate a session lock. -Satisfies: SRG-OS-000029-GPOS-00010, SRG-OS-000031-GPOS-00012</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000057CCI-000060Configure OL 9 to initiate a screensaver after a 15-minute period of inactivity for graphical user interfaces. +Satisfies: SRG-OS-000029-GPOS-00010, SRG-OS-000031-GPOS-00012</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000057CCI-000060Configure OL 9 to initiate a screensaver after a 10-minute period of inactivity for graphical user interfaces. -Create a database to contain the system-wide screensaver settings (if it does not already exist) with the following command: +Create a database to contain the systemwide screensaver settings (if it does not already exist) with the following command: $ sudo touch /etc/dconf/db/local.d/00-screensaver Edit /etc/dconf/db/local.d/00-screensaver and add or update the following lines: [org/gnome/desktop/session] -# Set the lock time out to 900 seconds before the session is considered idle -idle-delay=uint32 900 +# Set the lock time out to 600 seconds before the session is considered idle +idle-delay=uint32 600 Update the system databases: -$ sudo dconf updateThis requirement assumes the use of the OL 9 default graphical user interface—the GNOME desktop environment. If the system does not have any graphical user interface installed, this requirement is Not Applicable. +$ sudo dconf updateThis requirement assumes the use of the OL 9 default graphical user interface—the GNOME desktop environment. If the system does not have any graphical user interface installed, this requirement is Not Applicable. -Verify that OL 9 initiates a session lock after a 15-minute period of inactivity for graphical user interfaces with the following command: +Verify OL 9 initiates a session lock after a 10-minute period of inactivity for graphical user interfaces with the following command: $ gsettings get org.gnome.desktop.session idle-delay -uint32 900 +uint32 600 -If "idle-delay" is set to "0" or a value greater than "900", this is a finding.SRG-OS-000031-GPOS-00012<GroupDescription></GroupDescription>OL09-00-002106OL 9 must conceal, via the session lock, information previously visible on the display with a publicly viewable image.<VulnDiscussion>Setting the screensaver mode to blank-only conceals the contents of the display from passersby.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000060Configure OL 9 to conceal, via the session lock, information previously visible on the display with a publicly viewable image. +If "idle-delay" is set to "0" or a value greater than "600", this is a finding.SRG-OS-000031-GPOS-00012<GroupDescription></GroupDescription>OL09-00-002106OL 9 must conceal, via the session lock, information previously visible on the display with a publicly viewable image.<VulnDiscussion>Setting the screensaver mode to blank-only conceals the contents of the display from passersby.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000060Configure OL 9 to conceal, via the session lock, information previously visible on the display with a publicly viewable image. The dconf settings can be edited in the /etc/dconf/db/* location. @@ -4263,11 +4182,13 @@ Note: If the value of the "UMASK" parameter is set to "000" in "/etc/login.defs" $ grep -i umask /etc/login.defs UMASK 077 -If the value for the "UMASK" parameter is not "077", or the "UMASK" parameter is missing or is commented out, this is a finding.SRG-OS-000096-GPOS-00050<GroupDescription></GroupDescription>OL09-00-002320OL 9 must disable the chrony daemon from acting as a server.<VulnDiscussion>Minimizing the exposure of the server functionality of the chrony daemon diminishes the attack surface. +If the value for the "UMASK" parameter is not "077", or the "UMASK" parameter is missing or is commented out, this is a finding.SRG-OS-000096-GPOS-00050<GroupDescription></GroupDescription>OL09-00-002320OL 9 must disable the chrony daemon from acting as a server.<VulnDiscussion>Minimizing the exposure of the server functionality of the chrony daemon diminishes the attack surface. Satisfies: SRG-OS-000096-GPOS-00050, SRG-OS-000095-GPOS-00049</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000382CCI-000381Configure OL 9 to disable the chrony daemon from acting as a server by adding/modifying the following line in the /etc/chrony.conf file: -port 0Verify that OL 9 disables the chrony daemon from acting as a server with the following command: +port 0Note: If the server is serving as an NTP server, this is not applicable. + +Verify OL 9 disables the chrony daemon from acting as a server with the following command: $ grep -w port /etc/chrony.conf port 0 @@ -4656,19 +4577,19 @@ Verify that "/etc/sudoers" has no occurrences of "!authenticate" with the follow $ sudo grep -ri '!authenticate' /etc/sudoers /etc/sudoers.d/* -If any occurrences of "!authenticate" are returned, this is a finding.SRG-OS-000327-GPOS-00127<GroupDescription></GroupDescription>OL09-00-002363OL 9 must require users to provide a password for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. +If any occurrences of "!authenticate" are returned, this is a finding.SRG-OS-000327-GPOS-00127<GroupDescription></GroupDescription>OL09-00-002363OL 9 must require users to provide a password for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. When operating systems provide the capability to escalate a functional capability, it is critical that the user reauthenticate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002234Configure OL 9 to not allow users to execute privileged actions without authenticating with a password. Remove any occurrence of "NOPASSWD" found in "/etc/sudoers" file or files in the "/etc/sudoers.d" directory. -$ sudo sed -i '/NOPASSWD/ s/^/# /g' /etc/sudoers /etc/sudoers.d/*Verify that OL 9 requires users to provide a password for privilege escalation. +$ sudo sed -i '/NOPASSWD/ s/^/# /g' /etc/sudoers /etc/sudoers.d/*Verify OL 9 requires users to provide a password for privilege escalation. -Verify that "/etc/sudoers" has no occurrences of "NOPASSWD" with the following command: +Verify "/etc/sudoers" has no occurrences of "NOPASSWD" with the following command: -$ sudo grep -ri nopasswd /etc/sudoers /etc/sudoers.d/* +$ sudo grep -iR nopasswd /etc/sudoers /etc/sudoers.d/ -If any occurrences of "NOPASSWD" are returned, this is a finding.SRG-OS-000327-GPOS-00127<GroupDescription></GroupDescription>OL09-00-002364OL 9 must not be configured to bypass password requirements for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. When operating systems provide the capability to escalate a functional capability, it is critical the user reauthenticate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002234Configure the operating system to require users to supply a password for privilege escalation. +If any occurrences of "NOPASSWD" are returned from the command and have not been documented with the information system security officer (ISSO) as an organizationally defined administrative group using multifactor authentication (MFA), this is a finding.SRG-OS-000327-GPOS-00127<GroupDescription></GroupDescription>OL09-00-002364OL 9 must not be configured to bypass password requirements for privilege escalation.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. When operating systems provide the capability to escalate a functional capability, it is critical the user reauthenticate.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002234Configure the operating system to require users to supply a password for privilege escalation. Remove any occurrences of " pam_succeed_if " in the "/etc/pam.d/sudo" file.Verify that OL 9 is not configured to bypass password requirements for privilege escalation with the following command: @@ -4702,38 +4623,49 @@ $ sudo sysctl --systemSRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002381OL 9 must disable core dump backtraces.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers or system operators trying to debug problems. +If the returned line does not have a value of "|/bin/false", or a line is not returned and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002381OL 9 must disable core dump backtraces.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers or system operators trying to debug problems. Enabling core dumps on production systems is not recommended; however, there may be overriding operational requirements to enable advanced debugging. Permitting temporary enablement of core dumps during such situations must be reviewed through local needs and policy.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the operating system to disable core dump backtraces. Add or modify the following line in /etc/systemd/coredump.conf: -ProcessSizeMax=0Verify that OL 9 disables core dump backtraces by issuing the following command: +ProcessSizeMax=0Note: If kernel dumps are disabled in accordance with OL09-00-002380, this requirement is not applicable. + +Verify OL 9 disables core dump backtraces by issuing the following command: $ grep -i process /etc/systemd/coredump.conf ProcessSizeMax=0 -If the "ProcessSizeMax" item is missing, commented out, or the value is anything other than "0" and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002382OL 9 must disable storing core dumps.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers or system operators trying to debug problems. Enabling core dumps on production systems is not recommended; however, there may be overriding operational requirements to enable advanced debugging. Permitting temporary enablement of core dumps during such situations must be reviewed through local needs and policy.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the operating system to disable storing core dumps for all users. +If the "ProcessSizeMax" item is missing, commented out, or the value is anything other than "0" and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002382OL 9 must disable storing core dumps.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers or system operators trying to debug problems. Enabling core dumps on production systems is not recommended; however, there may be overriding operational requirements to enable advanced debugging. Permitting temporary enablement of core dumps during such situations must be reviewed through local needs and policy.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the operating system to disable storing core dumps for all users. Add or modify the following line in /etc/systemd/coredump.conf: -Storage=noneVerify that OL 9 disables storing core dumps for all users by issuing the following command: +Storage=noneNote: If kernel dumps are disabled in accordance with OL09-00-002380, this requirement is not applicable. + +Verify OL 9 disables storing core dumps for all users by issuing the following command: $ grep -i storage /etc/systemd/coredump.conf Storage=none -If the "Storage" item is missing, commented out, or the value is anything other than "none" and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002383OL 9 must disable core dumps for all users.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the operating system to disable core dumps for all users. +If the "Storage" item is missing, commented out, or the value is anything other than "none" and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002383OL 9 must disable core dumps for all users.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to disable core dumps for all users. Add the following line to the top of the /etc/security/limits.conf or in a single ".conf" file defined in /etc/security/limits.d/: -* hard core 0Verify that OL 9 disables core dumps for all users by issuing the following command: +* hard core 0 + +Remove or comment out any entries for users or groups with a value set to anything other than "0".Note: If kernel dumps are disabled in accordance with OL09-00-002380, this requirement is not applicable. + +Verify OL 9 disables core dumps for all users by issuing the following command: $ grep -r -s core /etc/security/limits.conf /etc/security/limits.d/*.conf + /etc/security/limits.conf:* hard core 0 This can be set as a global domain (with the * wildcard) but may be set differently for multiple domains. -If the "core" item is missing, commented out, or the value is anything other than "0" and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002384OL 9 must disable acquiring, saving, and processing core dumps.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the system to disable the systemd-coredump.socket with the following command: +If the "core" item is missing or commented out, or the value is anything other than "0", and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding. + +If entries exist for users or groups with a value set to anything other than "0", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002384OL 9 must disable acquiring, saving, and processing core dumps.<VulnDiscussion>A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure the system to disable the systemd-coredump.socket with the following command: $ sudo systemctl mask --now systemd-coredump.socket @@ -4741,7 +4673,9 @@ Created symlink /etc/systemd/system/systemd-coredump.socket -> /dev/null Reload the daemon for this change to take effect. -$ sudo systemctl daemon-reloadVerify that OL 9 is not configured to acquire, save, or process core dumps with the following command: +$ sudo systemctl daemon-reloadNote: If kernel dumps are disabled in accordance with OL09-00-002380, this requirement is not applicable. + +Verify OL 9 is not configured to acquire, save, or process core dumps with the following command: $ systemctl status systemd-coredump.socket systemd-coredump.socket @@ -4917,13 +4851,13 @@ debug-shell.service Loaded: masked (Reason: Unit debug-shell.service is masked.) Active: inactive (dead) -If the "debug-shell.service" is loaded and not masked, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>OL09-00-002404OL 9 IP tunnels must use 140-3 approved cryptographic algorithms.<VulnDiscussion>Overriding the system crypto policy makes the behavior of the Libreswan service violate expectations and makes system configuration more fragmented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000068Configure IPsec to use the systemwide cryptographic policy. +If the "debug-shell.service" is loaded and not masked, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>OL09-00-002404OL 9 IP tunnels must use 140-3 approved cryptographic algorithms.<VulnDiscussion>Overriding the system crypto policy makes the behavior of the Libreswan service violate expectations and makes system configuration more fragmented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000068Configure IPsec to use the systemwide cryptographic policy. Add the following line to "/etc/ipsec.conf": -include /etc/crypto-policies/back-ends/libreswan.configNote: If the IPsec service is not installed, this requirement is Not Applicable. +include /etc/crypto-policies/back-ends/libreswan.configNote: If the IPsec service is not installed, this requirement is Not Applicable. -Verify that the IPsec service uses the systemwide cryptographic policy with the following command: +Verify the IPsec service uses the systemwide cryptographic policy with the following command: $ grep include /etc/ipsec.conf /etc/ipsec.d/*.conf /etc/ipsec.conf:include /etc/crypto-policies/back-ends/libreswan.config @@ -5046,16 +4980,22 @@ declare -xr TMOUT=900SRG-OS-000324-GPOS-00125<GroupDescription></GroupDescription>OL09-00-002412OL 9 must be configured so that the systemd Ctrl-Alt-Delete burst key sequence is disabled.<VulnDiscussion>A locally logged-on user who presses Ctrl-Alt-Delete when at the console can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In a graphical user environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002235Configure the system to disable the CtrlAltDelBurstAction by added or modifying the following line in the "/etc/systemd/system.conf" configuration file: +If "TMOUT" is not set to "900" or less in a script located in the "/etc/'profile.d/ directory, is missing or is commented out, this is a finding.SRG-OS-000324-GPOS-00125<GroupDescription></GroupDescription>OL09-00-002412OL 9 must be configured so that the systemd Ctrl-Alt-Delete burst key sequence is disabled.<VulnDiscussion>A locally logged-on user who presses Ctrl-Alt-Delete when at the console can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In a graphical user environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002235Configure OL 9 to disable the CtrlAltDelBurstAction by adding it to a drop file in a "/etc/systemd/system.conf.d/" configuration file: + +If no drop file exists, create one with the following command: + +$ sudo mkdir -p /etc/systemd/system.conf.d && sudo vi /etc/systemd/system.conf.d/55-CtrlAltDel-BurstAction.conf + +Edit the file to contain the setting by adding the following text: CtrlAltDelBurstAction=none Reload the daemon for this change to take effect. -$ sudo systemctl daemon-reloadVerify that OL 9 is configured to not reboot the system when Ctrl-Alt-Delete is pressed seven times within two seconds with the following command: +$ sudo systemctl daemon-reloadVerify OL 9 is configured to not reboot the system when Ctrl-Alt-Delete is pressed seven times within two seconds with the following command: -$ grep -i ctrl /etc/systemd/system.conf -CtrlAltDelBurstAction=none +$ sudo grep -iR CtrlAltDelBurstAction /etc/systemd/system* +/etc/systemd/system.conf.d/55-CtrlAltDel-BurstAction:CtrlAltDelBurstAction=none If the "CtrlAltDelBurstAction" is not set to "none", commented out, or is missing, this is a finding.SRG-OS-000324-GPOS-00125<GroupDescription></GroupDescription>OL09-00-002413OL 9 must be configured so that the x86 Ctrl-Alt-Delete key sequence is disabled.<VulnDiscussion>A locally logged-on user who presses Ctrl-Alt-Delete when at the console can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In a graphical user environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002235Configure OL 9 to disable the ctrl-alt-del.target with the following command: @@ -5080,7 +5020,7 @@ $ grep -r -s maxlogins /etc/security/limits.conf /etc/security/limits.d/*.conf This can be set as a global domain (with the * wildcard) but may be set differently for multiple domains. -If the "maxlogins" item is missing, commented out, or the value is set greater than "10" and is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "maxlogins" item assigned, this is a finding.SRG-OS-000329-GPOS-00128<GroupDescription></GroupDescription>OL09-00-002416OL 9 must automatically lock an account when three unsuccessful logon attempts occur during a 15-minute time period.<VulnDiscussion>By limiting the number of failed logon attempts the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account. +If the "maxlogins" item is missing, commented out, or the value is set greater than "10" and is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "maxlogins" item assigned, this is a finding.SRG-OS-000329-GPOS-00128<GroupDescription></GroupDescription>OL09-00-002416OL 9 must automatically lock an account when three unsuccessful logon attempts occur during a 15-minute time period.<VulnDiscussion>By limiting the number of failed logon attempts the risk of unauthorized system access via user password guessing, otherwise known as brute-forcing, is reduced. Limits are imposed by locking the account. Satisfies: SRG-OS-000329-GPOS-00128, SRG-OS-000021-GPOS-00005</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002238CCI-000044Configure OL 9 to lock out the "root" account after a number of incorrect login attempts within 15 minutes using "pam_faillock.so" by enabling the feature using the following command: @@ -5088,9 +5028,7 @@ $ sudo authselect enable-feature with-faillock Then edit the "/etc/security/faillock.conf" file as follows: -fail_interval = 900Note: If the system administrator demonstrates the use of an approved centralized account management method that locks an account after three unsuccessful logon attempts within a period of 15 minutes, this requirement is Not Applicable. - -Verify that OL 9 locks an account after three unsuccessful logon attempts within a period of 15 minutes with the following command: +fail_interval = 900Verify OL 9 locks an account after three unsuccessful logon attempts within a period of 15 minutes with the following command: $ grep fail_interval /etc/security/faillock.conf fail_interval = 900 @@ -5137,7 +5075,7 @@ $ sudo rm /[path]/[to]/[file]/.shosts< $ sudo find / -name .shosts -If a ".shosts" file is found, this is a finding.SRG-OS-000423-GPOS-00187<GroupDescription></GroupDescription>OL09-00-002421OL 9 must implement DOD-approved encryption in the bind package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If a ".shosts" file is found, this is a finding.SRG-OS-000423-GPOS-00187<GroupDescription></GroupDescription>OL09-00-002421OL 9 must implement DOD-approved encryption in the bind package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. @@ -5147,9 +5085,9 @@ Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000426-GPOS-00190</VulnDiscussion Add the following line to the "options" section in "/etc/named.conf": -include "/etc/crypto-policies/back-ends/bind.config";Note: If the "bind" package is not installed, this requirement is Not Applicable. +include "/etc/crypto-policies/back-ends/bind.config";Note: If the "bind" package is not installed, this requirement is Not Applicable. -Verify that OL 9 BIND uses the system crypto policy with the following command: +Verify OL 9 BIND uses the system crypto policy with the following command: $ sudo grep include /etc/named.conf include "/etc/crypto-policies/back-ends/bind.config";' @@ -5176,20 +5114,7 @@ $ sudo sysctl --systemSRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>OL09-00-002424OL 9 must use mechanisms meeting the requirements of applicable federal laws, executive orders, directives, policies, regulations, standards, and guidance for authentication to a cryptographic module.<VulnDiscussion>Overriding the system crypto policy makes the behavior of Kerberos violate expectations and makes system configuration more fragmented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000803Configure Kerberos to use system crypto policy. - -Remove incorrect symlink if it exists using the following command: - -$ sudo rm /etc/crypto-policies/back-ends/krb5.config - -Create a symlink pointing to system crypto policy in the Kerberos configuration using the following command: - -$ sudo ln -s /usr/share/crypto-policies/FIPS/krb5.txt /etc/crypto-policies/back-ends/krb5.configVerify that OL 9 configures Kerberos to use the systemwide crypto policy with the following command: - -$ file /etc/crypto-policies/back-ends/krb5.config -/etc/crypto-policies/back-ends/krb5.config: symbolic link to /usr/share/crypto-policies/FIPS/krb5.txt - -If the symlink does not exist or points to a different target, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002425OL 9 must be configured to prevent unrestricted mail relaying.<VulnDiscussion>If unrestricted mail relaying is permitted, unauthorized senders could use this host as a mail relay for the purpose of sending spam or other unauthorized activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Modify the postfix configuration file to restrict client connections to the local network with the following command: +If "kernel.randomize_va_space" is not set to "2" or is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002425OL 9 must be configured to prevent unrestricted mail relaying.<VulnDiscussion>If unrestricted mail relaying is permitted, unauthorized senders could use this host as a mail relay for the purpose of sending spam or other unauthorized activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Modify the postfix configuration file to restrict client connections to the local network with the following command: $ sudo postconf -e 'smtpd_client_restrictions = permit_mynetworks,reject'Note: If postfix is not installed, this requirement is Not Applicable. @@ -5222,17 +5147,7 @@ If a TFTP server is installed, check for the server arguments with the following $ systemctl cat tftp | grep ExecStart ExecStart=/usr/sbin/in.tftpd -s /var/lib/tftpboot -If the "ExecStart" line does not have a "-s" option, and a subdirectory is not assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002427OL 9 must be configured so that local initialization files do not execute world-writable programs.<VulnDiscussion>If user start-up files execute world-writable programs, especially in unprotected directories, they could be maliciously modified to destroy user files or otherwise compromise the system at the user level. If the system is compromised at the user level, it is easier to elevate privileges to eventually compromise the system at the root and network level.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 so that local initialization files do not execute world-writable programs. - -Set the mode on files being executed by the local initialization files with the following command: - -$ sudo chmod 0755 <file>Verify that OL 9 is configured so that local initialization files do not execute world-writable programs with the following command: - -Note: The example will be for a system that is configured to create user home directories in the "/home" directory. - -$ sudo find /home -perm -002 -type f -name ".[^.]*" -exec ls -ld {} \; - -If any local initialization files are found to reference world-writable files, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>OL09-00-002428OL 9 must prevent the loading of a new kernel for later execution.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of the operating system. This requirement ensures the software has not been tampered with and that it has been provided by a trusted vendor. +If the "ExecStart" line does not have a "-s" option, and a subdirectory is not assigned, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>OL09-00-002428OL 9 must prevent the loading of a new kernel for later execution.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of the operating system. This requirement ensures the software has not been tampered with and that it has been provided by a trusted vendor. Disabling kexec_load prevents an unsigned kernel image (that could be a windows kernel or modified vulnerable kernel) from being loaded. Kexec can be used subvert the entire secureboot process and should be avoided at all costs especially since it can load unsigned kernel images.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-003992Configure OL 9 to prevent the loading of a new kernel for later execution. @@ -5327,15 +5242,15 @@ $ sudo stat -c "%a %n" /etc/ssh/*.pub 644 /etc/ssh/ssh_host_ed25519_key.pub 644 /etc/ssh/ssh_host_rsa_key.pub -If any key.pub file has a mode more permissive than "0644", this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002504OL 9 system commands must be group-owned by root or a system account.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any key.pub file has a mode more permissive than "0644", this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002504OL 9 system commands must be group-owned by root or a system account.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. This requirement applies to OL 9 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command, replacing "[FILE]" with any system command file not group-owned by "root" or a required system account. -$ sudo chgrp root [FILE]Verify that OL 9 system commands contained in the following directories are group-owned by "root", or a required system account, with the following command: +$ sudo chgrp root [FILE]Verify OL 9 system commands contained in the following directories are group-owned by "root", or a required system account, with the following command: -$ sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -group root -exec ls -l {} \; +$ sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/libexec /usr/local/bin /usr/local/sbin ! -group root -exec ls -l {} \; If any system commands are returned and is not group-owned by a required system account, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002505OL 9 system commands must be owned by root.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. @@ -5378,7 +5293,7 @@ $ sudo chmod 0600 /etc/ssh/sshd_config $ ls -al /etc/ssh/sshd_config rw-------. 1 root root 3669 Feb 22 11:34 /etc/ssh/sshd_config -If the "/etc/ssh/sshd_config" permissions are not "0600", this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>OL09-00-002510OL 9 must be configured so that a sticky bit must be set on all public directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If the "/etc/ssh/sshd_config" permissions are not "0600", this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>OL09-00-002510OL 9 must be configured so that a sticky bit must be set on all public directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DOD or other government agencies.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001090Configure all world-writable directories to have the sticky bit set to prevent unauthorized and unintended information transferred via shared system resources. @@ -5407,57 +5322,57 @@ $ sudo chown <user> <file> $ df --local -P | awk {'if (NR!=1) print $6'} | sudo xargs -I '{}' find '{}' -xdev -nouser -If any files on the system do not have an assigned owner, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002513OL 9 local initialization files must have mode 0740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Set the mode of the local initialization files to "0740" with the following command: +If any files on the system do not have an assigned owner, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002513OL 9 local initialization files must have mode 0740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Set the mode of the local initialization files to "0740" with the following command: -Note: The example will be for the wadea user, who has a home directory of "/home/wadea". +Note: The example will be for the disauser user who has a home directory of "/home/disauser". -$ sudo chmod 0740 /home/wadea/.<INIT_FILE>Verify that OL 9 configures all local initialization files to have a mode of "0740" or less permissive with the following command: +$ sudo chmod 0740 /home/disauser/.<INIT_FILE>Verify OL 9 configures all local initialization files to have a mode of "0740" or less permissive with the following command: -Note: The example will be for the "wadea" user, who has a home directory of "/home/wadea". +Note: The example will be for the "disauser" user, who has a home directory of "/home/disauser". -$ sudo ls -al /home/wadea/.[^.]* | more --rwxr-xr-x 1 wadea users 896 Mar 10 2011 .profile --rwxr-xr-x 1 wadea users 497 Jan 6 2007 .login --rwxr-xr-x 1 wadea users 886 Jan 6 2007 .something +$ sudo ls -al /home/disauser/.[^.]* | more +-rwxr-xr-x 1 disauser users 896 Mar 10 2011 .profile +-rwxr-xr-x 1 disauser users 497 Jan 6 2007 .login +-rwxr-xr-x 1 disauser users 886 Jan 6 2007 .something -If any local initialization files have a mode more permissive than "0740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002514OL 9 local interactive user home directories must be group-owned by the home directory owner's primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user's home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user's files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Change the group owner of a local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: +If any local initialization files have a mode more permissive than "0740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002514OL 9 local interactive user home directories must be group-owned by the home directory owner's primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user's home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user's files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Change the group owner of a local interactive user's home directory to the group found in "/etc/passwd" using the following command: -Note: The example will be for the user "wadea", who has a home directory of "/home/wadea", and has a primary group of users. +Note: The example will be for the user "disauser", who has a home directory of "/home/disauser", and has a primary group of users. -$ sudo chgrp users /home/wadeaVerify that OL 9 configures assigned home directories of all local interactive users to be group-owned by that user's primary GID with the following command: +$ sudo chgrp users /home/disauserVerify OL 9 configures assigned home directories of all local interactive users to be group-owned by that user's primary GID with the following command: -Note: This may miss local interactive users that have been assigned a privileged user identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/wadea" is used as an example. +Note: This may miss local interactive users that have been assigned a privileged user identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/disauser" is used as an example. $ sudo ls -ld $(awk -F: '($3>=1000)&&($7 !~ /nologin/){print $6}' /etc/passwd) -drwxr-x--- 2 wadea admin 4096 Jun 5 12:41 wadea +drwxr-x--- 2 disauser admin 4096 Jun 5 12:41 disauser Check the user's primary group with the following command: -$ sudo grep $(grep wadea /etc/passwd | awk -F: '{print $4}') /etc/group -admin:x:250:wadea,jonesj,jacksons +$ sudo grep $(grep disauser /etc/passwd | awk -F: '{print $4}') /etc/group +admin:x:250:disauser,doduser,nsauser -If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002515OL 9 local interactive user home directories must have mode 0750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Change the mode of interactive user's home directories to "0750". To change the mode of a local interactive user's home directory, use the following command: +If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-002515OL 9 local interactive user home directories must have mode 0750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Change the mode of interactive user's home directories to "0750" using the following command: -Note: The example will be for the user "wadea". +Note: The example will be for the user "disauser". -$ sudo chmod 0750 /home/wadeaVerify that OL 9 configures assigned home directories of all local interactive users to have a mode of "0750" or less permissive with the following command: +$ sudo chmod 0750 /home/disauserVerify OL 9 configures assigned home directories of all local interactive users to have a mode of "0750" or less permissive with the following command: Note: This may miss interactive users that have been assigned a privileged user identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. $ sudo ls -ld $(awk -F: '($3>=1000)&&($7 !~ /nologin/){print $6}' /etc/passwd) -drwxr-x--- 2 wadea admin 4096 Jun 5 12:41 wadea +drwxr-x--- 2 disauser admin 4096 Jun 5 12:41 disauser -If home directories referenced in "/etc/passwd" do not have a mode of "0750" or less permissive, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>OL09-00-002516OL 9 world-writable directories must be owned by root, sys, bin, or an application user.<VulnDiscussion>If a world-writable directory is not owned by root, sys, bin, or an application user identifier (UID), unauthorized users may be able to modify files created by others. +If home directories referenced in "/etc/passwd" do not have a mode of "0750" or less permissive, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>OL09-00-002516OL 9 world-writable directories must be owned by root, sys, bin, or an application user.<VulnDiscussion>If a world-writable directory is not owned by root, sys, bin, or an application user identifier (UID), unauthorized users may be able to modify files created by others. -The only authorized public directories are those temporary directories supplied with the system or those designed to be temporary file repositories. The setting is normally reserved for directories used by the system and by users for temporary file storage, (e.g., /tmp), and for directories requiring global read/write access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001090Configure all public directories to be owned by root or a system account to prevent unauthorized and unintended information transferred via shared system resources. +The only authorized public directories are those temporary directories supplied with the system or those designed to be temporary file repositories. The setting is normally reserved for directories used by the system and by users for temporary file storage, (e.g., /tmp), and for directories requiring global read/write access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001090Configure all OL 9 public directories to be owned by root or a system account to prevent unauthorized and unintended information transferred via shared system resources. -Set the owner of all public directories as root or a system account using the command, replace "[Public Directory]" with any directory path not owned by root or a system account: +Use the following command template to set ownership of public directories to root or a system account: -$ sudo chown root [Public Directory]Verify that OL 9 configures world writable directories to be owned by root, a system account, or an application account with the following command. It will discover and print world-writable directories that are not owned by root. Run it once for each local partition [PART]: +$ sudo chown [root or system account] [Public Directory]Verify OL 9 world writable directories are owned by root, a system account, or an application account with the following command: -$ sudo find [PART] -xdev -type d -perm -0002 -uid +0 -print +$ sudo find / -xdev -type d -perm -0002 -uid +999 -exec stat -c "%U, %u, %A, %n" {} \; 2>/dev/null -If there is output, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002520OL 9 library directories must be group-owned by root or a system account.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If there is output that indicates world-writable directories are owned by any account other than root or an approved system account, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002520OL 9 library directories must be group-owned by root or a system account.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. This requirement applies to OL 9 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001499Configure the system-wide shared library directories (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. @@ -5477,17 +5392,17 @@ $ sudo chown root [DIRECTORY]SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002522OL 9 library directories must have mode 755 or less permissive.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any system-wide shared library directory is not owned by root, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002522OL 9 library directories must have mode 755 or less permissive.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to OL 9 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001499Configure the system-wide shared library directories (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. +This requirement applies to OL 9 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001499Configure the systemwide shared library directories (/lib, /lib64, /usr/lib and /usr/lib64) to be protected from unauthorized access. Run the following command, replacing "[DIRECTORY]" with any library directory with a mode more permissive than 755. -$ sudo chmod 755 [DIRECTORY]Verify that OL 9 system-wide shared library directories have mode "755" or less permissive with the following command: +$ sudo chmod 755 [DIRECTORY]Verify OL 9 systemwide shared library directories have mode "755" or less permissive with the following command: $ sudo find -L /lib /lib64 /usr/lib /usr/lib64 -perm /022 -type d -exec ls -l {} \; -If any system-wide shared library file is found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002523OL 9 library files must be group owned by root or a system account.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any systemwide shared library directory is found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>OL09-00-002523OL 9 library files must be group owned by root or a system account.<VulnDiscussion>If OL 9 allowed any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. This requirement applies to OL 9 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001499Configure the OL 9 systemwide shared library files contained in the directories "/lib", "/lib64", "/usr/lib", and "/usr/lib64" to be group owned by root with the following command: @@ -6001,14 +5916,14 @@ $ chage -l <temporary_account_name> | grep -i "account expires" Verify each of these accounts has an expiration date set within 72 hours. -If any temporary accounts have no expiration date set or do not expire within 72 hours, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-003050OL 9 local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a denial of service because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Create home directories to all local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": +If any temporary accounts have no expiration date set or do not expire within 72 hours, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-003050OL 9 local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a denial of service because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Create home directories to all local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": -Note: The example will be for the user wadea, who has a home directory of "/home/wadea", a user identifier (UID) of "wadea", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". +Note: The example will be for the user disauser, who has a home directory of "/home/disauser", a user identifier (UID) of "disauser", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". -$ sudo mkdir /home/wadea -$ sudo chown wadea /home/wadea -$ sudo chgrp users /home/wadea -$ sudo chmod 0750 /home/wadeaVerify that OL 9 assigned home directories of all interactive users on the system exist with the following command: +$ sudo mkdir /home/disauser +$ sudo chown disauser /home/disauser +$ sudo chgrp users /home/disauser +$ sudo chmod 0750 /home/disauserVerify OL 9 assigned home directories of all interactive users on the system exist with the following command: $ sudo pwck -r @@ -6051,9 +5966,9 @@ If a local interactive user requires path variables to reference a directory own $ sudo grep -i path= /home/*/.* /home/[localinteractiveuser]/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin -If any local interactive user initialization files have executable search path statements that include directories outside of their home directory and is not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-003060OL 9 must set the umask value to 077 for all local interactive user accounts.<VulnDiscussion>The umask controls the default access mode assigned to newly created files. A umask of 077 limits new files to mode 600 or less permissive. Although umask can be represented as a four-digit number, the first digit representing special access modes is typically ignored or required to be "0". This requirement applies to the globally configured system defaults and the local interactive user defaults for each account on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Remove the umask statement from all local interactive user's initialization files. +If any local interactive user initialization files have executable search path statements that include directories outside of their home directory and is not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-003060OL 9 must set the umask value to 077 for all local interactive user accounts.<VulnDiscussion>The umask controls the default access mode assigned to newly created files. A umask of 077 limits new files to mode 600 or less permissive. Although umask can be represented as a four-digit number, the first digit representing special access modes is typically ignored or required to be "0". This requirement applies to the globally configured system defaults and the local interactive user defaults for each account on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Remove the umask statement from all local interactive user's initialization files. -If the account is for an application, the requirement for a umask less restrictive than "077" can be documented with the information system security officer, but the user agreement for access to the account must specify that the local interactive user must log on to their account first and then switch the user to the application account with the correct option to gain the account's environment variables.Verify that OL 9 configures the default umask for all local interactive users to be "077". +If the account is for an application, the requirement for a umask less restrictive than "077" can be documented with the information system security officer, but the user agreement for access to the account must specify that the local interactive user must log on to their account first and then switch the user to the application account with the correct option to gain the account's environment variables.Verify OL 9 configures the default umask for all local interactive users to be "077". Identify the locations of all local interactive user home directories by looking at the "/etc/passwd" file. @@ -6062,8 +5977,8 @@ Check all local interactive user initialization files for interactive users with Note: The example is for a system that is configured to create users home directories in the "/home" directory. $ grep -ri umask /home/ -/home/wadea/.bash_history:grep -i umask /etc/bashrc /etc/csh.cshrc /etc/profile -/home/wadea/.bash_history:grep -i umask /etc/login.defs +/home/disauser/.bash_history:grep -i umask /etc/bashrc /etc/csh.cshrc /etc/profile +/home/disauser/.bash_history:grep -i umask /etc/login.defs If any local interactive user initialization files are found to have a umask statement that sets a value less restrictive than "077", this is a finding.SRG-OS-000118-GPOS-00060<GroupDescription></GroupDescription>OL09-00-003065OL 9 must disable account identifiers (individuals, groups, roles, and devices) after 35 days of inactivity.<VulnDiscussion>Inactive identifiers pose a risk to systems and applications because attackers may exploit an inactive identifier and potentially obtain undetected access to the system. @@ -6108,7 +6023,7 @@ Check that remote access methods are being logged by running the following comma $ grep -rE '(auth.\*|authpriv.\*|daemon.\*)' /etc/rsyslog.conf authpriv.* /var/log/secure -If "auth.*", "authpriv.*" or "daemon.*" are not configured to be logged, this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>OL09-00-005005OL 9 must be configured to forward audit records via TCP to a different system or media from the system being audited via rsyslog.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration. +If "auth.*", "authpriv.*" or "daemon.*" are not configured to be logged, this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>OL09-00-005005OL 9 must be configured to forward audit records via TCP to a different system or media from the system being audited via rsyslog.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration. Offloading is a common process in information systems with limited audit storage capacity. @@ -6122,12 +6037,29 @@ TCP *.* @@remotesystemname RELP *.* :omrelp:remotesystemname:2514 Note that a port number was given as there is no standard port for RELP. -Satisfies: SRG-OS-000479-GPOS-00224, SRG-OS-000342-GPOS-00133</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001851Configure OL 9 to offload audit records onto a different system or media from the system being audited via TCP using rsyslog by specifying the remote logging server in "/etc/rsyslog.conf"" or "/etc/rsyslog.d/[customfile].conf" with the name or IP address of the log aggregation server. +Satisfies: SRG-OS-000479-GPOS-00224, SRG-OS-000342-GPOS-00133</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001851Configure OL 9 to offload audit records onto a different system or media from the system being audited via TCP using rsyslog by specifying the remote logging server in "/etc/rsyslog.conf" or "/etc/rsyslog.d/[customfile].conf" with the name or IP address of the log aggregation server. Following are examples of the configuration for the legacy syntax and for the newer Rainer script. Only one should be used. + +Using legacy '@host:port" syntax example: +*.* @@[remoteloggingserver]:[port] + +Using Rainer script example: +action( + type="omfwd" + target="logserver.example.com" + port="514" + protocol="tcp" + action.resumeRetryCount="-1" + queue.type="linkedList" + que.size="10000" +) + +Note: The Rainer Script above does not contain the required encryption settings.Verify OL 9 audit system offloads audit records onto a different system or media from the system being audited via rsyslog using TCP with the following commands: -*.* @@[remoteloggingserver]:[port]"Verify that OL 9 audit system offloads audit records onto a different system or media from the system being audited via rsyslog using TCP with the following command: +To check for legacy configuration syntax, perform the following: +$ sudo grep -ir '@@' /etc/rsyslog.conf /etc/rsyslog.d/ -$ grep @@ /etc/rsyslog.conf /etc/rsyslog.d/*.conf -/etc/rsyslog.conf:*.* @@[remoteloggingserver]:[port] +To check for Rainer script syntax, perform the following: +$ sudo grep -rq 'type="omfwd"' /etc/rsyslog.conf /etc/rsyslog.d/ If a remote server is not configured, or the line is commented out, ask the system administrator (SA) to indicate how the audit logs are offloaded to a different system or media. @@ -6203,34 +6135,38 @@ $DefaultNetstreamDriver gtlsSRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-005030OL 9 must be configured so that the rsyslog daemon does not accept log messages from other servers unless the server is being used for log aggregation.<VulnDiscussion>Unintentionally running a rsyslog server accepting remote messages puts the system at increased risk. Malicious rsyslog messages sent to the server could exploit vulnerabilities in the server software itself, could introduce misleading information into the system's logs, or could fill the system's storage leading to a denial of service. +If the value of the "$DefaultNetstreamDriver" option is not set to "gtls" or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-005030OL 9 must be configured so that the rsyslog daemon does not accept log messages from other servers unless the server is being used for log aggregation.<VulnDiscussion>Unintentionally running a rsyslog server accepting remote messages puts the system at increased risk. Malicious rsyslog messages sent to the server could exploit vulnerabilities in the server software itself, could introduce misleading information into the system's logs, or could fill the system's storage leading to a denial of service. -If the system is intended to be a log aggregation server, its use must be documented with the information system security officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to not receive remote logs using rsyslog. +If the system is intended to be a log aggregation server, its use must be documented with the information system security officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to not receive remote logs using rsyslog. Remove the lines in /etc/rsyslog.conf and any files in the /etc/rsyslog.d directory that match any of the following: - -$ModLoad imtcp -$ModLoad imudp -$ModLoad imrelp -$InputTCPServerRun [0-9]* -$UDPServerRun [0-9]* -$InputRELPServerRun [0-9]* +InputTCPServerRun +UDPServerRun +RELPServerRun +module(load="imtcp") +module(load="imudp") +module(load="imrelp") +input(type="imudp" port="514") +input(type="imtcp" port="514") +input(type="imrelp" port="514") The rsyslog daemon must be restarted for the changes to take effect: -$ sudo systemctl restart rsyslog.serviceVerify that OL 9 is not configured to receive remote logs using rsyslog with the following commands: +$ sudo systemctl restart rsyslog.serviceNote: If the system administrator can demonstrate that another tool (e.g., SPLUNK) is being used to manage log offload and aggregation in lieu of rsyslog, this is not applicable. + +Verify OL 9 is not configured to receive remote logs using rsyslog with the following commands: + +$ ss -tulnp | grep rsyslog -$ grep -i modload /etc/rsyslog.conf /etc/rsyslog.d/* -$ModLoad imtcp -$ModLoad imrelp +If no output is returned, rsyslog is not listening for remote messages and is compliant. -$ grep -i serverrun /etc/rsyslog.conf /etc/rsyslog.d/* -$InputTCPServerRun 514 -$InputRELPServerRun 514 +If output appears, check for configured ports (514 is the default for syslog). -Note: An error about no files or directories may be returned. This is not a finding. +Check for remote logging configuration in rsyslog by examining the rsyslog configuration files: -If any lines are returned by the command, then rsyslog is configured to receive remote messages, and this is a finding.SRG-OS-000420-GPOS-00186<GroupDescription></GroupDescription>OL09-00-006000OL 9 must protect against or limit the effects of denial-of-service (DoS) attacks by ensuring rate-limiting measures on impacted network interfaces are implemented.<VulnDiscussion>DoS is a condition when a resource is not available for legitimate users. When this occurs, the organization either cannot accomplish its mission or must operate at degraded capacity. +$ sudo grep -E 'InputTCPServerRun|UDPServerRun|RELPServerRun|imtcp|imudp|imrelp' /etc/rsyslog.conf /etc/rsyslog.d/* + +If this command returns uncommented lines enabling network listeners, the system is accepting remote logs. If this system is not documented and authorized as a log aggregation server, this is a finding.SRG-OS-000420-GPOS-00186<GroupDescription></GroupDescription>OL09-00-006000OL 9 must protect against or limit the effects of denial-of-service (DoS) attacks by ensuring rate-limiting measures on impacted network interfaces are implemented.<VulnDiscussion>DoS is a condition when a resource is not available for legitimate users. When this occurs, the organization either cannot accomplish its mission or must operate at degraded capacity. This requirement addresses the configuration of OL 9 to mitigate the impact of DoS attacks that have occurred or are ongoing on system availability. For each system, known and potential DoS attacks must be identified and solutions for each type implemented. A variety of technologies exists to limit or, in some cases, eliminate the effects of DoS attacks (e.g., limiting processes or establishing memory partitions). Employing increased capacity and bandwidth, combined with service redundancy, may reduce the susceptibility to some DoS attacks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-002385Configure "nftables" to be the default "firewallbackend" for "firewalld" by adding or editing the following line in "/etc/firewalld/firewalld.conf": @@ -6382,7 +6318,7 @@ Check the value of the accept source route variable with the following command: $ sysctl net.ipv4.conf.default.log_martians net.ipv4.conf.default.log_martians = 1 -If the returned line does not have a value of "1", a line is not returned, or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-006024OL 9 must use reverse path filtering on all IPv4 interfaces.<VulnDiscussion>Enabling reverse path filtering drops packets with source addresses that should not have been able to be received on the interface on which they were received. It must not be used on systems that are routers for complicated networks but is helpful for end hosts and routers serving small networks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to use reverse path filtering on all IPv4 interfaces. +If the returned line does not have a value of "1", a line is not returned, or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-006024OL 9 must use reverse path filtering on all IPv4 interfaces.<VulnDiscussion>Enabling reverse path filtering drops packets with source addresses that should not have been able to be received on the interface on which they were received. It must not be used on systems that are routers for complicated networks but is helpful for end hosts and routers serving small networks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to use reverse path filtering on all IPv4 interfaces. Add or edit the following line in a single system configuration file in the "/etc/sysctl.d/" directory: @@ -6390,11 +6326,11 @@ net.ipv4.conf.all.rp_filter = 1 The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: -$ sudo sysctl --systemVerify that OL 9 uses reverse path filtering on all IPv4 interfaces with the following commands: - -$ sysctl net.ipv4.conf.all.rp_filter -net.ipv4.conf.all.rp_filter = 1 - +$ sudo sysctl --systemVerify OL 9 uses reverse path filtering on all IPv4 interfaces with the following commands: + +$ sysctl net.ipv4.conf.all.rp_filter +net.ipv4.conf.all.rp_filter = 1 + If the returned line does not have a value of "1", or a line is not returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-006025OL 9 must prevent IPv4 Internet Control Message Protocol (ICMP) redirect messages from being accepted.<VulnDiscussion>ICMP redirect messages are used by routers to inform hosts that a more direct route exists for a particular destination. These messages modify the host's route table and are unauthenticated. An illicit ICMP redirect message could result in a man-in-the-middle attack. This feature of the IPv4 protocol has few legitimate uses. It must be disabled unless absolutely required.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to prevent IPv4 ICMP redirect messages from being accepted. @@ -6429,7 +6365,7 @@ Check the value of the accept source route variable with the following command: $ sysctl net.ipv4.conf.default.accept_source_route net.ipv4.conf.default.accept_source_route = 0 -If the returned line does not have a value of "0", a line is not returned, or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-006027OL 9 must use a reverse-path filter for IPv4 network traffic, when possible, by default.<VulnDiscussion>Enabling reverse path filtering drops packets with source addresses that should not have been able to be received on the interface on which they were received. It must not be used on systems that are routers for complicated networks but is helpful for end hosts and routers serving small networks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to use reverse path filtering on IPv4 interfaces by default. +If the returned line does not have a value of "0", a line is not returned, or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-006027OL 9 must use a reverse-path filter for IPv4 network traffic, when possible, by default.<VulnDiscussion>Enabling reverse path filtering drops packets with source addresses that should not have been able to be received on the interface on which they were received. It must not be used on systems that are routers for complicated networks but is helpful for end hosts and routers serving small networks.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to use reverse path filtering on IPv4 interfaces by default. Add or edit the following line in a single system configuration file in the "/etc/sysctl.d/" directory: @@ -6437,11 +6373,11 @@ net.ipv4.conf.default.rp_filter = 1 Load settings from all system configuration files with the following command: -$ sudo sysctl --systemVerify that OL 9 uses reverse path filtering on IPv4 interfaces with the following commands: - -$ sysctl net.ipv4.conf.default.rp_filter -net.ipv4.conf.default.rp_filter = 1 - +$ sudo sysctl --systemVerify OL 9 uses reverse path filtering on IPv4 interfaces with the following commands: + +$ sysctl net.ipv4.conf.default.rp_filter +net.ipv4.conf.default.rp_filter = 1 + If the returned line does not have a value of "1", or a line is not returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>OL09-00-006028OL 9 must not enable IPv4 packet forwarding unless the system is a router.<VulnDiscussion>Routing protocol daemons are typically used on routers to exchange network topology information with other routers. If this capability is used when not required, system network information may be unnecessarily transmitted across the network.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000366Configure OL 9 to not allow IPv4 packet forwarding unless the system is a router. Add or edit the following line in a single system configuration file in the "/etc/sysctl.d/" directory: @@ -6644,7 +6580,7 @@ Check the value of the accept source route variable with the following command: $ sysctl net.ipv6.conf.default.accept_source_route net.ipv6.conf.default.accept_source_route = 0 -If the returned line does not have a value of "0", a line is not returned, or the line is commented out, this is a finding.SRG-OS-000420-GPOS-00186<GroupDescription></GroupDescription>OL09-00-006050OL 9 must be configured to use TCP syncookies.<VulnDiscussion>Denial of service (DoS) is a condition when a resource is not available for legitimate users. When this occurs, the organization either cannot accomplish its mission or must operate at degraded capacity. +If the returned line does not have a value of "0", a line is not returned, or the line is commented out, this is a finding.SRG-OS-000420-GPOS-00186<GroupDescription></GroupDescription>OL09-00-006050OL 9 must be configured to use TCP syncookies.<VulnDiscussion>Denial of service (DoS) is a condition when a resource is not available for legitimate users. When this occurs, the organization either cannot accomplish its mission or must operate at degraded capacity. Managing excess capacity ensures that sufficient capacity is available to counter flooding attacks. Employing increased capacity and service redundancy may reduce the susceptibility to some DoS attacks. Managing excess capacity may include, for example, establishing selected usage priorities, quotas, or partitioning. @@ -6656,16 +6592,14 @@ Add or edit the following line in a system configuration file in the "/etc/sysct Load settings from all system configuration files with the following command: -$ sudo sysctl --systemVerify that OL 9 is configured to use IPv4 TCP syncookies. +$ sudo sysctl --systemVerify OL 9 is configured to use IPv4 TCP syncookies. Determine if syncookies are used with the following command: -Check the status of the kernel.perf_event_paranoid kernel parameter. - $ sysctl net.ipv4.tcp_syncookies net.ipv4.tcp_syncookies = 1 -Check that the configuration files are present to enable this kernel parameter.SRG-OS-000462-GPOS-00206<GroupDescription></GroupDescription>OL09-00-008000OL 9 audit system must protect logon UIDs from unauthorized change.<VulnDiscussion>If modification of login user identifiers (UIDs) is not prevented, they can be changed by nonprivileged users and make auditing complicated or impossible. +Verify the configuration files are present to enable this kernel parameter.SRG-OS-000462-GPOS-00206<GroupDescription></GroupDescription>OL09-00-008000OL 9 audit system must protect logon UIDs from unauthorized change.<VulnDiscussion>If modification of login user identifiers (UIDs) is not prevented, they can be changed by nonprivileged users and make auditing complicated or impossible. Satisfies: SRG-OS-000462-GPOS-00206, SRG-OS-000475-GPOS-00220, SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPOS-00029</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-000172CCI-000162CCI-000163CCI-000164Configure OL 9 auditing to prevent modification of login UIDs once they are set by adding the following line to /etc/audit/rules.d/audit.rules: @@ -6746,4 +6680,16 @@ $ sudo auditctl -l | grep /etc/cron.d $ sudo auditctl -l | grep /var/spool/cron -w /var/spool/cron -p wa -k cronjobs -If either of these commands do not return the expected output, or the lines are commented out, this is a finding. \ No newline at end of file +If either of these commands do not return the expected output, or the lines are commented out, this is a finding.SRG-OS-000163-GPOS-00072<GroupDescription></GroupDescription>OL09-00-002376OL 9 must terminate idle user sessions.<VulnDiscussion>Terminating an idle session within a short time period reduces the window of opportunity for unauthorized personnel to take control of a management session enabled on the console or console port that has been left unattended.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Oracle Linux 9DISADPMS TargetOracle Linux 95680CCI-001134Configure OL 9 to log out idle sessions by editing the /etc/systemd/logind.conf file with the following line: + +StopIdleSessionSec=600 + +The "logind" service must be restarted for the changes to take effect. To restart the "logind" service, run the following command: + +$ sudo systemctl restart systemd-logindVerify that OL 9 logs out sessions that are idle for 10 minutes with the following command: + +$ sudo grep -i ^StopIdleSessionSec /etc/systemd/logind.conf + +StopIdleSessionSec=600 + +If "StopIdleSessionSec" is not configured to "600" seconds, this is a finding. \ No newline at end of file diff --git a/shared/references/disa-stig-rhel8-v2r5-xccdf-manual.xml b/shared/references/disa-stig-rhel8-v2r6-xccdf-manual.xml similarity index 85% rename from shared/references/disa-stig-rhel8-v2r5-xccdf-manual.xml rename to shared/references/disa-stig-rhel8-v2r6-xccdf-manual.xml index 18f982203062..a12c07ca4b8a 100644 --- a/shared/references/disa-stig-rhel8-v2r5-xccdf-manual.xml +++ b/shared/references/disa-stig-rhel8-v2r6-xccdf-manual.xml @@ -1,4 +1,4 @@ -acceptedRed Hat Enterprise Linux 8 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 5 Benchmark Date: 01 Oct 20253.5.11.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010000RHEL 8 must be a vendor-supported release.<VulnDiscussion>An operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software. +acceptedRed Hat Enterprise Linux 8 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 6 Benchmark Date: 05 Jan 20263.5.21.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010000RHEL 8 must be a vendor-supported release.<VulnDiscussion>An operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software. Red Hat offers the Extended Update Support (EUS) add-on to a Red Hat Enterprise Linux subscription, for a fee, for those customers who wish to standardize on a specific minor release for an extended period. The RHEL 8 minor releases eligible for EUS are 8.1, 8.2, 8.4, 8.6, and 8.8. Each RHEL 8 EUS stream is available for 24 months from the availability of the minor release. RHEL 8.10 will be the final minor release overall. For more details on the Red Hat Enterprise Linux Life Cycle visit https://access.redhat.com/support/policy/updates/errata/. Note: The life-cycle time spans and dates are subject to adjustment.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Upgrade to a supported version of RHEL 8.Verify the version of the operating system is vendor supported. @@ -49,34 +49,50 @@ If package updates have not been performed on the system within the timeframe th Typical update frequency may be overridden by Information Assurance Vulnerability Alert (IAVA) notifications from CYBERCOM. -If the operating system is in non-compliance with the Information Assurance Vulnerability Management (IAVM) process, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>RHEL-08-010020RHEL 8 must implement NIST FIPS-validated cryptography for the following: To provision digital signatures, to generate cryptographic hashes, and to protect data requiring data-at-rest protections in accordance with applicable federal laws, Executive Orders, directives, policies, regulations, and standards.<VulnDiscussion>Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. The operating system must implement cryptographic modules adhering to the higher standards approved by the federal government since this provides assurance they have been tested and validated. +If the operating system is in non-compliance with the Information Assurance Vulnerability Management (IAVM) process, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>RHEL-08-010020RHEL 8 must implement a FIPS 140-3-compliant systemwide cryptographic policy.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. -RHEL 8 utilizes GRUB 2 as the default bootloader. Note that GRUB 2 command-line parameters are defined in the "kernelopts" variable of the /boot/grub2/grubenv file for all kernel boot entries. The command "fips-mode-setup" modifies the "kernelopts" variable, which in turn updates all kernel boot entries. +Satisfies: SRG-OS-000033-GPOS-00014, SRG-OS-000125-GPOS-00065, SRG-OS-000396-GPOS-00176, SRG-OS-000423-GPOS-00187, SRG-OS-000478-GPOS-00223, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000068Configure RHEL 8 to use a FIPS 140-3-compliant systemwide cryptographic policy. -The fips=1 kernel option needs to be added to the kernel command line during system installation so that key generation is done with FIPS-approved algorithms and continuous monitoring tests in place. Users must also ensure the system has plenty of entropy during the installation process by moving the mouse around, or if no mouse is available, ensuring that many keystrokes are typed. The recommended amount of keystrokes is 256 and more. Less than 256 keystrokes may generate a nonunique key. +Create a subpolicy for enhancements to the base systemwide crypto-policy by creating the file /etc/crypto-policies/policies/modules/STIG.pmod with the following content: -Satisfies: SRG-OS-000033-GPOS-00014, SRG-OS-000125-GPOS-00065, SRG-OS-000396-GPOS-00176, SRG-OS-000423-GPOS-00187, SRG-OS-000478-GPOS-00223</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000068Configure the operating system to implement DOD-approved encryption by following the steps below: +# Define ciphers and MACs for OpenSSH and libssh +cipher@SSH=AES-256-GCM AES-256-CTR AES-128-GCM AES-128-CTR +mac@SSH=HMAC-SHA2-512 HMAC-SHA2-256 -To enable strict FIPS compliance, the fips=1 kernel option needs to be added to the kernel boot parameters during system installation so key generation is done with FIPS-approved algorithms and continuous monitoring tests in place. +Apply the policy enhancements to the FIPS systemwide cryptographic policy level with the following command: -Enable FIPS mode after installation (not strict FIPS-compliant) with the following command: +$ sudo update-crypto-policies --set FIPS:STIG - $ sudo fips-mode-setup --enable +Note: If additional subpolicies are being employed, they must be added to the update-crypto-policies command. -Reboot the system for the changes to take effect.Verify the operating system implements DOD-approved encryption to protect the confidentiality of remote access sessions. +To make the cryptographic settings effective for already running services and applications, restart the system: -Show the configured systemwide cryptographic policy by running the following command: +$ sudo rebootVerify RHEL 8 is set to use a FIPS 140-3-compliant systemwide cryptographic policy with the following command: $ sudo update-crypto-policies --show -FIPS -If the main policy name is not "FIPS", this is a finding. +FIPS:STIG -If the AD-SUPPORT subpolicy module is included (e.g., "FIPS:AD-SUPPORT"), and Active Directory support is not documented as an operational requirement with the information system security officer (ISSO), this is a finding. +If the systemwide crypto policy is not set to "FIPS", this is a finding. -If the NO-ENFORCE-EMS subpolicy module is included (e.g., "FIPS:NO-ENFORCE-EMS"), and not enforcing EMS is not documented as an operational requirement with the ISSO, this is a finding. +Note: If subpolicies have been configured, they could be listed in a colon-separated list starting with "FIPS" as follows FIPS:<SUBPOLICY-NAME>. This is not a finding. -If any other subpolicy module is included, this is a finding.SRG-OS-000185-GPOS-00079<GroupDescription></GroupDescription>RHEL-08-010030All RHEL 8 local disk partitions must implement cryptographic mechanisms to prevent unauthorized disclosure or modification of all information that requires at rest protection.<VulnDiscussion>RHEL 8 systems handling data requiring "data at rest" protections must employ cryptographic mechanisms to prevent unauthorized disclosure and modification of the information at rest. +Note: Subpolicies like AD-SUPPORT must be configured according to the latest guidance from the operating system vendor. + +Verify the current minimum crypto-policy configuration with the following commands: + +$ sudo grep -E 'rsa_size|hash' /etc/crypto-policies/state/CURRENT.pol + +hash = SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512 +min_rsa_size = 2048 + +If the "hash" values do not include at least the following FIPS 140-3-compliant algorithms "SHA2-256 SHA2-384 SHA2-512 SHA2-224 SHA3-256 SHA3-384 SHA3-512", this is a finding. + +If there are algorithms that include "SHA1" or a hash value less than "224" this is a finding. + +If the "min_rsa_size" is not set to a value of at least "2048", this is a finding. + +If these commands do not return any output, this is a finding.SRG-OS-000185-GPOS-00079<GroupDescription></GroupDescription>RHEL-08-010030All RHEL 8 local disk partitions must implement cryptographic mechanisms to prevent unauthorized disclosure or modification of all information that requires at rest protection.<VulnDiscussion>RHEL 8 systems handling data requiring "data at rest" protections must employ cryptographic mechanisms to prevent unauthorized disclosure and modification of the information at rest. Selection of a cryptographic mechanism is based on the need to protect the integrity of organizational information. The strength of the mechanism is commensurate with the security category and/or classification of the information. Organizations have the flexibility to either encrypt all information on storage devices (i.e., full disk encryption) or encrypt specific data structures (e.g., files, records, or fields). @@ -370,7 +386,7 @@ SHA_CRYPT_MIN_ROUNDS 100000SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010140RHEL 8 operating systems booted with United Extensible Firmware Interface (UEFI) must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require a grub bootloader password for the grub superusers account with the grub2-setpassword command, which creates/overwrites the /boot/efi/EFI/redhat/user.cfg file. +If both "SHA_CRYPT_MIN_ROUNDS" and "SHA_CRYPT_MAX_ROUNDS" are set, and the highest value for either is below "100000", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010140RHEL 8 operating systems booted with United Extensible Firmware Interface (UEFI) must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require a grub bootloader password for the grub superusers account with the grub2-setpassword command, which creates/overwrites the /boot/efi/EFI/redhat/user.cfg file. Generate an encrypted grub2 password for the grub superusers account with the following command: @@ -384,7 +400,7 @@ $ sudo grep -iw grub2_password /boot/efi/EFI/redhat/user.cfg GRUB2_PASSWORD=grub.pbkdf2.sha512.[password_hash] -If the grub superusers password does not begin with "grub.pbkdf2.sha512", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010150RHEL 8 operating systems booted with a BIOS must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require a grub bootloader password for the grub superusers account with the grub2-setpassword command, which creates/overwrites the /boot/grub2/user.cfg file. +If the grub superusers password does not begin with "grub.pbkdf2.sha512", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010150RHEL 8 operating systems booted with a BIOS must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require a grub bootloader password for the grub superusers account with the grub2-setpassword command, which creates/overwrites the /boot/grub2/user.cfg file. Generate an encrypted grub2 password for the grub superusers account with the following command: @@ -398,7 +414,7 @@ $ sudo grep -iw grub2_password /boot/grub2/user.cfg GRUB2_PASSWORD=grub.pbkdf2.sha512.[password_hash] -If the grub superusers password does not begin with "grub.pbkdf2.sha512", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010151RHEL 8 operating systems must require authentication upon booting into rescue mode.<VulnDiscussion>If the system does not require valid root authentication before it boots into emergency or rescue mode, anyone who invokes emergency or rescue mode is granted privileged access to all files on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require authentication upon booting into rescue mode by adding the following line to the "/usr/lib/systemd/system/rescue.service" file. +If the grub superusers password does not begin with "grub.pbkdf2.sha512", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010151RHEL 8 operating systems must require authentication upon booting into rescue mode.<VulnDiscussion>If the system does not require valid root authentication before it boots into emergency or rescue mode, anyone who invokes emergency or rescue mode is granted privileged access to all files on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require authentication upon booting into rescue mode by adding the following line to the "/usr/lib/systemd/system/rescue.service" file. ExecStart=-/usr/lib/systemd/systemd-sulogin-shell rescueCheck to see if the system requires authentication for rescue mode with the following command: @@ -480,7 +496,7 @@ $ sudo yum list installed policycoreutils policycoreutils.x86_64 2.9-3.el8 @anaconda -If the policycoreutils package is not installed, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>RHEL-08-010190A sticky bit must be set on all RHEL 8 public directories to prevent unauthorized and unintended information transferred via shared system resources.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If the policycoreutils package is not installed, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>RHEL-08-010190A sticky bit must be set on all RHEL 8 public directories to prevent unauthorized and unintended information transferred via shared system resources.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DoD or other government agencies. @@ -582,152 +598,82 @@ $ sudo stat -c "%G" /var/log root -If "root" is not returned as a result, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010290The RHEL 8 SSH server must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file. - -The system will attempt to use the first hash presented by the client that matches the server list. Listing the values "strongest to weakest" is a method to ensure the use of the strongest hash available to secure the SSH connection. - -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH server to use only MACs employing FIPS 140-3 approved algorithms by updating the "/etc/crypto-policies/back-ends/opensshserver.config" file with the following commands. - -To manually update the MACs in the systemwide SSH configuration, use the following command: - -$ sudo sed -i -E 's/(-oMACs=)[^ ]*/\1hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256/' "$(readlink -f /etc/crypto-policies/back-ends/opensshserver.config)" - -A reboot is required for the changes to take effect.Verify the RHEL 8 SSH server is configured to use only MACs employing FIPS 140-3 approved algorithms. - -To verify the MACs in the systemwide SSH configuration file, use the following command: - -$ sudo grep -i macs /etc/crypto-policies/back-ends/opensshserver.config --oMACs=hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 - -If the MACs entries in the "opensshserver.config" file have any hashes other than "hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256", the order differs from the example above, or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010291The RHEL 8 operating system must implement DOD-approved encryption to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file. - -The system will attempt to use the first hash presented by the client that matches the server list. Listing the values "strongest to weakest" is a method to ensure the use of the strongest hash available to secure the SSH connection. - -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH server to use only ciphers employing FIPS 140-3 approved algorithms by updating the "/etc/crypto-policies/back-ends/opensshserver.config" file with the following commands. - -To manually update the ciphers in the systemwide SSH configuration, use the following command: - -$ sudo sed -i -E 's/(-oCiphers=)[^ ]*/\1aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr/' "$(readlink -f /etc/crypto-policies/back-ends/opensshserver.config)" - -A reboot is required for the changes to take effect.Verify the SSH server is configured to use only ciphers employing FIPS 140-3 approved algorithms. - -To verify the ciphers in the systemwide SSH configuration file, use the following command: - -$ sudo grep -i ciphers /etc/crypto-policies/back-ends/opensshserver.config --oCiphers=aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr - -If the ciphers entries in the "opensshserver.config" file have any hashes other than "aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr", the order differs from the example above, or they are missing or commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010292RHEL 8 must ensure the SSH server uses strong entropy.<VulnDiscussion>The most important characteristic of a random number generator is its randomness, namely its ability to deliver random numbers that are impossible to predict. Entropy in computer security is associated with the unpredictability of a source of randomness. The random source with high entropy tends to achieve a uniform distribution of random values. Random number generators are one of the most important building blocks of cryptosystems. - -The SSH implementation in RHEL 8 uses the OPENSSL library, which does not use high-entropy sources by default. By using the SSH_USE_STRONG_RNG environment variable the OPENSSL random generator is reseeded from /dev/random. This setting is not recommended on computers without the hardware random generator because insufficient entropy causes the connection to be blocked until enough entropy is available.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the operating system SSH server to use strong entropy. - -Add or modify the following line in the "/etc/sysconfig/sshd" file. - -SSH_USE_STRONG_RNG=32 - -The SSH service must be restarted for changes to take effect. - -Restart the SSH Daemon with the following command: - -$ sudo systemctl restart sshd.serviceNote: If the operating system is RHEL versions 8.0 or 8.1, this requirement is not applicable. - -Verify the operating system SSH server uses strong entropy with the following command: - -$ sudo grep -i ssh_use_strong_rng /etc/sysconfig/sshd - -SSH_USE_STRONG_RNG=32 - -If the "SSH_USE_STRONG_RNG" line does not equal "32", is commented out, or is missing, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010293The RHEL 8 operating system must implement DoD-approved encryption in the OpenSSL package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If "root" is not returned as a result, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010290The RHEL 8 SSH server must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3-validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. -Remote access (e.g., RDP) is access to DoD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. -RHEL 8 incorporates system-wide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssl.config file. +RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file. -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 OpenSSL library to use only ciphers employing FIPS 140-2-approved algorithms with the following command: +Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH server to use only MACs employing FIPS 140-3-approved algorithms. -$ sudo fips-mode-setup --enable +Reinstall crypto-policies with the following command: -A reboot is required for the changes to take effect.Verify the OpenSSL library is configured to use only ciphers employing FIPS 140-2-approved algorithms: +$ sudo dnf -y reinstall crypto-policies -Verify that system-wide crypto policies are in effect: +Set the crypto-policy to FIPS with the following command: -$ sudo grep -i opensslcnf.config /etc/pki/tls/openssl.cnf +$ sudo update-crypto-policies --set FIPS -.include /etc/crypto-policies/back-ends/opensslcnf.config +Setting system policy to FIPS -If the "opensslcnf.config" is not defined in the "/etc/pki/tls/openssl.cnf" file, this is a finding. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify the RHEL 8 SSH server is configured to use only MACs employing FIPS 140-3-approved algorithms. -Verify which system-wide crypto policy is in use: +To verify the MACs in the systemwide SSH configuration file, use the following command: -$ sudo update-crypto-policies --show +$ sudo grep -i MACs /etc/crypto-policies/back-ends/opensshserver.config -FIPS +-oMACs=hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 -If the system-wide crypto policy is set to anything other than "FIPS", this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010294The RHEL 8 operating system must implement DoD-approved TLS encryption in the OpenSSL package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +If the MACs entries in the "opensshserver.config" file have any hashes other than "hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010291The RHEL 8 SSH server must be configured to use only DOD-approved encryption ciphers employing FIPS 140-3-validated cryptographic hash algorithms to protect the confidentiality of SSH server connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. -Remote access (e.g., RDP) is access to DoD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. -RHEL 8 incorporates system-wide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssl.config file. +RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file. -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 OpenSSL library to use only DoD-approved TLS encryption by editing the following line in the "/etc/crypto-policies/back-ends/opensslcnf.config" file: +Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH server to use only ciphers employing FIPS 140-3-approved algorithms. -For versions prior to crypto-policies-20210617-1.gitc776d3e.el8.noarch: -MinProtocol = TLSv1.2 +Reinstall crypto-policies with the following command: -For version crypto-policies-20210617-1.gitc776d3e.el8.noarch and newer: -TLS.MinProtocol = TLSv1.2 -DTLS.MinProtocol = DTLSv1.2 -A reboot is required for the changes to take effect.Verify the OpenSSL library is configured to use only DoD-approved TLS encryption: +$ sudo dnf -y reinstall crypto-policies -For versions prior to crypto-policies-20210617-1.gitc776d3e.el8.noarch: +Set the crypto-policy to FIPS with the following command: -$ sudo grep -i MinProtocol /etc/crypto-policies/back-ends/opensslcnf.config +$ sudo update-crypto-policies --set FIPS -MinProtocol = TLSv1.2 +Setting system policy to FIPS -If the "MinProtocol" is set to anything older than "TLSv1.2", this is a finding. +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify the RHEL 8 SSH server is configured to use only ciphers employing FIPS 140-3-approved algorithms. -For version crypto-policies-20210617-1.gitc776d3e.el8.noarch and newer: +To verify the ciphers in the systemwide SSH configuration file, use the following command: -$ sudo grep -i MinProtocol /etc/crypto-policies/back-ends/opensslcnf.config +$ sudo grep -i Ciphers /etc/crypto-policies/back-ends/opensshserver.config +CRYPTO_POLICY='-oCiphers=aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr -TLS.MinProtocol = TLSv1.2 -DTLS.MinProtocol = DTLSv1.2 +If the cipher entries in the "opensshserver.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010292RHEL 8 must ensure the SSH server uses strong entropy.<VulnDiscussion>The most important characteristic of a random number generator is its randomness, namely its ability to deliver random numbers that are impossible to predict. Entropy in computer security is associated with the unpredictability of a source of randomness. The random source with high entropy tends to achieve a uniform distribution of random values. Random number generators are one of the most important building blocks of cryptosystems. -If the "TLS.MinProtocol" is set to anything older than "TLSv1.2" or the "DTLS.MinProtocol" is set to anything older than DTLSv1.2, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010295The RHEL 8 operating system must implement DoD-approved TLS encryption in the GnuTLS package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. +The SSH implementation in RHEL 8 uses the OPENSSL library, which does not use high-entropy sources by default. By using the SSH_USE_STRONG_RNG environment variable the OPENSSL random generator is reseeded from /dev/random. This setting is not recommended on computers without the hardware random generator because insufficient entropy causes the connection to be blocked until enough entropy is available.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the operating system SSH server to use strong entropy. -Transport Layer Security (TLS) encryption is a required security setting as a number of known vulnerabilities have been reported against Secure Sockets Layer (SSL) and earlier versions of TLS. Encryption of private information is essential to ensuring data confidentiality. If private information is not encrypted, it can be intercepted and easily read by an unauthorized party. SQL Server must use a minimum of FIPS 140-2-approved TLS version 1.2, and all non-FIPS-approved SSL and TLS versions must be disabled. NIST SP 800-52 specifies the preferred configurations for government systems. +Add or modify the following line in the "/etc/sysconfig/sshd" file. -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. +SSH_USE_STRONG_RNG=32 -The GnuTLS library offers an API to access secure communications protocols. SSLv2 is not available in the GnuTLS library. The RHEL 8 system-wide crypto policy defines employed algorithms in the /etc/crypto-policies/back-ends/gnutls.config file. +The SSH service must be restarted for changes to take effect. -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000423-GPOS-00187</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 GnuTLS library to use only DoD-approved encryption by adding the following line to "/etc/crypto-policies/back-ends/gnutls.config": +Restart the SSH Daemon with the following command: -+VERS-ALL:-VERS-DTLS0.9:-VERS-SSL3.0:-VERS-TLS1.0:-VERS-TLS1.1:-VERS-DTLS1.0 +$ sudo systemctl restart sshd.serviceNote: If the operating system is RHEL versions 8.0 or 8.1, this requirement is not applicable. -A reboot is required for the changes to take effect.Verify the GnuTLS library is configured to only allow DoD-approved SSL/TLS Versions: +Verify the operating system SSH server uses strong entropy with the following command: -$ sudo grep -io +vers.* /etc/crypto-policies/back-ends/gnutls.config +$ sudo grep -i ssh_use_strong_rng /etc/sysconfig/sshd -+VERS-ALL:-VERS-DTLS0.9:-VERS-SSL3.0:-VERS-TLS1.0:-VERS-TLS1.1:-VERS-DTLS1.0:+COMP-NULL:%PROFILE_MEDIUM +SSH_USE_STRONG_RNG=32 -If the "gnutls.config" does not list "-VERS-DTLS0.9:-VERS-SSL3.0:-VERS-TLS1.0:-VERS-TLS1.1:-VERS-DTLS1.0" to disable unapproved SSL/TLS versions, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>RHEL-08-010300RHEL 8 system commands must have mode 755 or less permissive.<VulnDiscussion>If RHEL 8 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If the "SSH_USE_STRONG_RNG" line does not equal "32", is commented out, or is missing, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>RHEL-08-010300RHEL 8 system commands must have mode 755 or less permissive.<VulnDiscussion>If RHEL 8 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. This requirement applies to RHEL 8 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges. Only qualified and authorized individuals will be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001499Configure the system commands to be protected from unauthorized access. @@ -775,7 +721,7 @@ $ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' ! -user root - $ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' ! -user root -exec stat -c "%n %U" {} + -If any output is returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>RHEL-08-010350RHEL 8 library files must be group-owned by root or a system account.<VulnDiscussion>If RHEL 8 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any output is returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>RHEL-08-010350RHEL 8 library files must be group-owned by root.<VulnDiscussion>If RHEL 8 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. This requirement applies to RHEL 8 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges. Only qualified and authorized individuals will be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001499Configure the systemwide shared library files contained in the directories "/lib", "/lib64", "/usr/lib", and "/usr/lib64" are group owned by root with the following command: @@ -998,7 +944,7 @@ $ sudo grep -r fs.protected_hardlinks /run/sysctl.d/*.conf /usr/local/lib/sysctl If "fs.protected_hardlinks" is not set to "1", is missing or commented out, this is a finding. -If conflicting results are returned, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>RHEL-08-010375RHEL 8 must restrict access to the kernel message buffer.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If conflicting results are returned, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>RHEL-08-010375RHEL 8 must restrict access to the kernel message buffer.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DoD or other government agencies. @@ -1046,7 +992,7 @@ $ sudo grep -r kernel.dmesg_restrict /run/sysctl.d/*.conf /usr/local/lib/sysctl. If "kernel.dmesg_restrict" is not set to "1", is missing or commented out, this is a finding. -If conflicting results are returned, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>RHEL-08-010376RHEL 8 must prevent kernel profiling by unprivileged users.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If conflicting results are returned, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>RHEL-08-010376RHEL 8 must prevent kernel profiling by unprivileged users.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DoD or other government agencies. @@ -1552,7 +1498,9 @@ $ sudo mount | grep '\s/boot\s' /dev/sda1 on /boot type xfs (rw,nosuid,relatime,seclabe,attr2,inode64,noquota) -If the /boot file system does not have the "nosuid" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010580RHEL 8 must prevent special devices on non-root local partitions.<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access. The only legitimate location for device files is the /dev directory located on the root partition.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nodev" option on all non-root local partitions.Verify all non-root local partitions are mounted with the "nodev" option with the following command: +If the /boot file system does not have the "nosuid" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010580RHEL 8 must prevent special devices on non-root local partitions.<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access. The only legitimate location for device files is the /dev directory located on the root partition.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nodev" option on all non-root local partitions.Note: This control is not applicable to vfat file systems. + +Verify all non-root local partitions are mounted with the "nodev" option with the following command: $ sudo mount | grep '^/dev\S* on /\S' | grep --invert-match 'nodev' @@ -1591,98 +1539,71 @@ $ sudo more /etc/fstab UUID=2bc871e4-e2a3-4f29-9ece-3be60c835222 /mnt/usbflash vfat noauto,owner,ro,nosuid,nodev,noexec 0 0 -If a file system found in "/etc/fstab" refers to removable media and it does not have the "nosuid" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010630RHEL 8 must prevent code from being executed on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "noexec" mount option causes the system not to execute binary files. This option must be used for mounting any file system not containing approved binary as they may be incompatible. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "noexec" option on file systems that are being imported via NFS.Verify that file systems being imported via NFS are mounted with the "noexec" option with the following command: +If a file system found in "/etc/fstab" refers to removable media and it does not have the "nosuid" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010630RHEL 8 must prevent code from being executed on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "noexec" mount option causes the system not to execute binary files. This option must be used for mounting any file system not containing approved binary as they may be incompatible. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "noexec" option on file systems that are being imported via NFS.Note: If no NFS mounts are configured, this requirement is Not Applicable. + +Verify file systems being imported via NFS are mounted with the "noexec" option with the following command: $ sudo grep nfs /etc/fstab | grep noexec UUID=e06097bb-cfcd-437b-9e4d-a691f5662a7d /store nfs rw,nosuid,nodev,noexec 0 0 -If a file system found in "/etc/fstab" refers to NFS and it does not have the "noexec" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010640RHEL 8 must prevent special devices on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nodev" option on file systems that are being imported via NFS.Verify file systems that are being NFS-imported are mounted with the "nodev" option with the following command: +If a file system found in "/etc/fstab" refers to NFS and it does not have the "noexec" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010640RHEL 8 must prevent special devices on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nodev" option on file systems that are being imported via NFS.Note: If no NFS mounts are configured, this requirement is Not Applicable. + +Verify file systems that are being NFS-imported are mounted with the "nodev" option with the following command: $ sudo grep nfs /etc/fstab | grep nodev UUID=e06097bb-cfcd-437b-9e4d-a691f5662a7d /store nfs rw,nosuid,nodev,noexec 0 0 -If a file system found in "/etc/fstab" refers to NFS and it does not have the "nodev" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010650RHEL 8 must prevent files with the setuid and setgid bit set from being executed on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nosuid" option on file systems that are being imported via NFS.Verify that file systems being imported via NFS are mounted with the "nosuid" option with the following command: +If a file system found in "/etc/fstab" refers to NFS and it does not have the "nodev" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010650RHEL 8 must prevent files with the setuid and setgid bit set from being executed on file systems that are imported via Network File System (NFS).<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nosuid" option on file systems that are being imported via NFS.Note: If no NFS mounts are configured, this requirement is Not Applicable. + +Verify file systems being imported via NFS are mounted with the "nosuid" option with the following command: $ sudo grep nfs /etc/fstab | grep nosuid UUID=e06097bb-cfcd-437b-9e4d-a691f5662a7d /store nfs rw,nosuid,nodev,noexec 0 0 -If a file system found in "/etc/fstab" refers to NFS and it does not have the "nosuid" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010660Local RHEL 8 initialization files must not execute world-writable programs.<VulnDiscussion>If user start-up files execute world-writable programs, especially in unprotected directories, they could be maliciously modified to destroy user files or otherwise compromise the system at the user level. If the system is compromised at the user level, it is easier to elevate privileges to eventually compromise the system at the root and network level.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Set the mode on files being executed by the local initialization files with the following command: - -$ sudo chmod 0755 <file>Verify that local initialization files do not execute world-writable programs. - -Check the system for world-writable files. - -The following command will discover and print world-writable files. Run it once for each local partition [PART]: - -$ sudo find [PART] -xdev -type f -perm -0002 -print - -For all files listed, check for their presence in the local initialization files with the following commands: - -Note: The example will be for a system that is configured to create user home directories in the "/home" directory. - -$ sudo grep <file> /home/*/.* - -If any local initialization files are found to reference world-writable files, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010670RHEL 8 must disable kernel dumps unless needed.<VulnDiscussion>Kernel core dumps may contain the full contents of system memory at the time of the crash. Kernel core dumps may consume a considerable amount of disk space and may result in denial of service by exhausting the available space on the target file system partition. +If a file system found in "/etc/fstab" refers to NFS and it does not have the "nosuid" option set, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010670RHEL 8 must disable kernel dumps unless needed.<VulnDiscussion>Kernel core dumps may contain the full contents of system memory at the time of the crash. Kernel core dumps may consume a considerable amount of disk space and may result in denial of service by exhausting the available space on the target file system partition. RHEL 8 installation media presents the option to enable or disable the kdump service at the time of system installation.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366If kernel core dumps are not required, disable the "kdump" service with the following command: # systemctl disable kdump.service -If kernel core dumps are required, document the need with the ISSO.Verify that kernel core dumps are disabled unless needed with the following command: +If kernel core dumps are required, document the need with the ISSO.Verify RHEL 8 kernel core dumps are disabled unless needed with the following command: $ sudo systemctl status kdump.service -kdump.service - Crash recovery kernel arming -Loaded: loaded (/usr/lib/systemd/system/kdump.service; enabled; vendor preset: enabled) -Active: active (exited) since Mon 2020-05-04 16:08:09 EDT; 3min ago -Main PID: 1130 (code=exited, status=0/SUCCESS) +o kdump.service - Crash recovery kernel arming + Loaded: loaded (/usr/lib/systemd/system/kdump.service; disabled; vendor preset: enabled) + Active: inactive (dead) -If the "kdump" service is active, ask the System Administrator if the use of the service is required and documented with the Information System Security Officer (ISSO). +If the "kdump" service is active, ask the system administrator if the use of the service is required and documented with the information system security officer (ISSO). -If the service is active and is not documented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010671RHEL 8 must disable the kernel.core_pattern.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the service is active and is not documented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010671RHEL 8 must disable the kernel.core_pattern.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. +The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographical order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf /usr/lib/sysctl.d/*.conf /lib/sysctl.d/*.conf -/etc/sysctl.conf</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to disable storing core dumps. +/etc/sysctl.conf</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to restrict usage of ptrace to descendant processes by adding the following line to a dropfile in the "/etc/sysctl.d" directory: -Add or edit the following line in a system configuration file, in the "/etc/sysctl.d/" directory: +Create a dropfile if it does not already exist: +$ sudo vi /etc/sysctl.d/99-disable-coredump.conf +Add the following to the file: kernel.core_pattern = |/bin/false -Remove any configurations that conflict with the above from the following locations: -/run/sysctl.d/*.conf -/usr/local/lib/sysctl.d/*.conf -/usr/lib/sysctl.d/*.conf -/lib/sysctl.d/*.conf -/etc/sysctl.conf -/etc/sysctl.d/*.conf - The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: -$ sudo sysctl --systemVerify RHEL 8 disables storing core dumps with the following commands: +$ sudo sysctl --systemVerify RHEL 8 disables storing core dumps with the following commands: $ sudo sysctl kernel.core_pattern kernel.core_pattern = |/bin/false -If the returned line does not have a value of "|/bin/false", or a line is not returned and the need for core dumps is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding. - -Check that the configuration files are present to enable this kernel parameter. - -$ sudo grep -r kernel.core_pattern /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf /usr/lib/sysctl.d/*.conf /lib/sysctl.d/*.conf /etc/sysctl.conf /etc/sysctl.d/*.conf - -/etc/sysctl.d/99-sysctl.conf:kernel.core_pattern = |/bin/false - -If "kernel.core_pattern" is not set to "|/bin/false", is missing or commented out, this is a finding. - -If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010672RHEL 8 must disable acquiring, saving, and processing core dumps.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the returned line does not have a value of "|/bin/false", or a line is not returned and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010672RHEL 8 must disable acquiring, saving, and processing core dumps.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems. @@ -1706,23 +1627,27 @@ systemd-coredump.socket Loaded: masked (Reason: Unit systemd-coredump.socket is masked.) Active: inactive (dead) -If the "systemd-coredump.socket" is loaded and not masked and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010673RHEL 8 must disable core dumps for all users.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the "systemd-coredump.socket" is loaded and not masked and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010673RHEL 8 must disable core dumps for all users.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the operating system to disable core dumps for all users. +A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the operating system to disable core dumps for all users. -Add the following line to the top of the /etc/security/limits.conf or in a ".conf" file defined in /etc/security/limits.d/: +Add the following line to the top of the /etc/security/limits.conf or in a single ".conf" file defined in /etc/security/limits.d/: + +* hard core 0 -* hard core 0Note: If kernel dumps are disabled in accordance with RHEL-08-010671, this requirement is not applicable. +Remove or comment out any entries for users or groups with a value set to anything other than "0".Note: If kernel dumps are disabled in accordance with RHEL-08-010671, this requirement is not applicable. -Verify the operating system disables core dumps for all users by issuing the following command: +Verify RHEL 8 disables core dumps for all users by issuing the following command: -$ sudo grep -r -s '^[^#].*core' /etc/security/limits.conf /etc/security/limits.d/*.conf +$ grep -r -s core /etc/security/limits.conf /etc/security/limits.d/*.conf -/etc/security/limits.d/core_dumps.conf:* hard core 0 +/etc/security/limits.conf:* hard core 0 This can be set as a global domain (with the * wildcard) but may be set differently for multiple domains. -If the "core" item is missing or commented out, or the value is anything other than "0", and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010674RHEL 8 must disable storing core dumps.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the "core" item is missing or commented out, or the value is anything other than "0", and the need for core dumps is not documented with the information system security officer (ISSO) as an operational requirement for all domains that have the "core" item assigned, this is a finding. + +If entries exist for users or groups with a value set to anything other than "0", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010674RHEL 8 must disable storing core dumps.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the operating system to disable storing core dumps for all users. @@ -1791,13 +1716,17 @@ $ sudo grep -irw path= /home/*/.* /home/[localinteractiveuser]/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin -If any local interactive user initialization files have executable search path statements that include directories outside of their home directory and is not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010700All RHEL 8 world-writable directories must be owned by root, sys, bin, or an application user.<VulnDiscussion>If a world-writable directory is not owned by root, sys, bin, or an application User Identifier (UID), unauthorized users may be able to modify files created by others. +If any local interactive user initialization files have executable search path statements that include directories outside of their home directory and is not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010700All RHEL 8 world-writable directories must be owned by root, sys, bin, or an application user.<VulnDiscussion>If a world-writable directory is not owned by root, sys, bin, or an application User Identifier (UID), unauthorized users may be able to modify files created by others. + +The only authorized public directories are those temporary directories supplied with the system or those designed to be temporary file repositories. The setting is normally reserved for directories used by the system and by users for temporary file storage, (e.g., /tmp), and for directories requiring global read/write access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure all RHEL 8 public directories to be owned by root or a system account to prevent unauthorized and unintended information transferred via shared system resources. + +Use the following command template to set ownership of public directories to root or a system account: -The only authorized public directories are those temporary directories supplied with the system or those designed to be temporary file repositories. The setting is normally reserved for directories used by the system and by users for temporary file storage, (e.g., /tmp), and for directories requiring global read/write access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366All directories in local partitions which are world-writable should be owned by root or another system account. If any world-writable directories are not owned by a system account, this should be investigated. Following this, the files should be deleted or assigned to an appropriate group.The following command will discover and print world-writable directories that are not owned by a system account, given the assumption that only system accounts have a uid lower than 1000. Run it once for each local partition [PART]: +$ sudo chown [root or system account] [Public Directory]Verify RHEL 8 world writable directories are owned by root, a system account, or an application account with the following command: -$ sudo find [PART] -xdev -type d -perm -0002 -uid +999 -print +$ sudo find / -xdev -type d -perm -0002 -uid +999 -exec stat -c "%U, %u, %A, %n" {} \; 2>/dev/null -If there is output, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010710All RHEL 8 world-writable directories must be group-owned by root, sys, bin, or an application group.<VulnDiscussion>If a world-writable directory is not group-owned by root, sys, bin, or an application Group Identifier (GID), unauthorized users may be able to modify files created by others. +If there is output that indicates world-writable directories are owned by any account other than root or an approved system account, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010710All RHEL 8 world-writable directories must be group-owned by root, sys, bin, or an application group.<VulnDiscussion>If a world-writable directory is not group-owned by root, sys, bin, or an application Group Identifier (GID), unauthorized users may be able to modify files created by others. The only authorized public directories are those temporary directories supplied with the system or those designed to be temporary file repositories. The setting is normally reserved for directories used by the system and by users for temporary file storage, (e.g., /tmp), and for directories requiring global read/write access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366All directories in local partitions which are world-writable must be group-owned by root or another system account. If any world-writable directories are not group-owned by a system account, this must be investigated. Following this, the directories must be deleted or assigned to an appropriate group.The following command will discover and print world-writable directories that are not group-owned by a system account, given the assumption that only system accounts have a gid lower than 1000. Run it once for each local partition [PART]: @@ -1901,25 +1830,24 @@ $ sudo chgrp <group> <file> $ df --local -P | awk {'if (NR!=1) print $6'} | sudo xargs -I '{}' find '{}' -xdev -nogroup -If any files on the system do not have an assigned group, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010800A separate RHEL 8 filesystem must be used for user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Migrate the "/home" directory onto a separate file system.Verify that a separate file system has been created for non-privileged local interactive user home directories. +If any files on the system do not have an assigned group, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010800A separate RHEL 8 filesystem must be used for user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Migrate the "/home" directory onto a separate file system.Verify a separate file system has been created for nonprivileged local interactive user home directories. -Check the home directory assignment for all non-privileged users, users with a User Identifier (UID) greater than 1000, on the system with the following command: +Check the home directory assignment for all nonprivileged users, users with a User Identifier (UID) greater than 1000, on the system with the following command: - $ sudo awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1,$3,$6}' /etc/passwd +$ sudo awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1,$3,$6,$7}' /etc/passwd +pdosadmin 1000 /home/pdosadmin /bin/bash +systemuser 1001 /home/systemuser /bin/bash +acas 1002 /home/acas /bin/bash - doej 1001 /home/doej - publicj 1002 /home/publicj - smithj 1003 /home/smithj - -The output of the command will give the directory/partition that contains the home directories for the non-privileged users on the system (in this example, "/home") and users’ shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. +The output of the command will give the directory/partition that contains the home directories for the nonprivileged users on the system (in this example, "/home") and users’ shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. Check that a file system/partition has been created for the nonprivileged interactive users with the following command: Note: The partition of "/home" is used in the example. - $ sudo grep /home /etc/fstab +$ sudo grep /home /etc/fstab - /dev/mapper/... /home xfs defaults,noexec,nosuid,nodev 0 0 +/dev/mapper/... /home xfs defaults,noexec,nosuid,nodev 0 0 If a separate entry for the file system/partition containing the nonprivileged interactive user home directories does not exist, this is a finding.SRG-OS-000480-GPOS-00229<GroupDescription></GroupDescription>RHEL-08-010820Unattended or automatic logon via the RHEL 8 graphical user interface must not be allowed.<VulnDiscussion>Failure to restrict system access to authenticated users negatively impacts operating system security.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the operating system to not allow an unattended or automatic logon to the system via a graphical user interface. @@ -2405,13 +2333,13 @@ $ sudo grep -R removal-action /etc/dconf/db/* /etc/dconf/db/distro.d/20-authselect:removal-action='lock-screen' -If the "removal-action='lock-screen'" setting is missing or commented out from the dconf database files, this is a finding.SRG-OS-000029-GPOS-00010<GroupDescription></GroupDescription>RHEL-08-020060RHEL 8 must automatically lock graphical user sessions after 15 minutes of inactivity.<VulnDiscussion>A session lock is a temporary action taken when a user stops work and moves away from the immediate physical vicinity of the information system but does not want to log out because of the temporary nature of the absence. +If the "removal-action='lock-screen'" setting is missing or commented out from the dconf database files, this is a finding.SRG-OS-000029-GPOS-00010<GroupDescription></GroupDescription>RHEL-08-020060RHEL 8 must automatically lock graphical user sessions after 15 minutes of inactivity.<VulnDiscussion>A session lock is a temporary action taken when a user stops work and moves away from the immediate physical vicinity of the information system but does not want to log out because of the temporary nature of the absence. The session lock is implemented at the point where session activity can be determined. Rather than be forced to wait for a period of time to expire before the user session can be locked, RHEL 8 needs to provide users with the ability to manually invoke a session lock so users can secure their session if it is necessary to temporarily vacate the immediate physical vicinity. -Satisfies: SRG-OS-000029-GPOS-00010, SRG-OS-000031-GPOS-00012</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000057Configure the operating system to initiate a screensaver after a 15-minute period of inactivity for graphical user interfaces. +Satisfies: SRG-OS-000029-GPOS-00010, SRG-OS-000031-GPOS-00012</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000057Configure RHEL 8 to initiate a screensaver after a 15-minute period of inactivity for graphical user interfaces. -Create a database to contain the system-wide screensaver settings (if it does not already exist) with the following command: +Create a database to contain the systemwide screensaver settings (if it does not already exist) with the following command: $ sudo touch /etc/dconf/db/local.d/00-screensaver @@ -2423,9 +2351,9 @@ idle-delay=uint32 900 Update the system databases: -$ sudo dconf updateVerify the operating system initiates a session lock after a 15-minute period of inactivity for graphical user interfaces with the following commands: +$ sudo dconf updateVerify RHEL 8 initiates a session lock after a 15-minute period of inactivity for graphical user interfaces with the following command: -This requirement assumes the use of the RHEL 8 default graphical user interface, Gnome Shell. If the system does not have any graphical user interface installed, this requirement is Not Applicable. +Note: This requirement assumes the use of the RHEL 8 default graphical user interface, the GNOME desktop environment. If the system does not have any graphical user interface installed, this requirement is Not Applicable. $ sudo gsettings get org.gnome.desktop.session idle-delay @@ -2887,17 +2815,7 @@ $ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' If "PermitEmptyPasswords" is set to "yes", this is a finding. -If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-020340RHEL 8 must display the date and time of the last successful account logon upon logon.<VulnDiscussion>Providing users with feedback on when account accesses last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000052Configure the operating system to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/postlogin". - -Add the following line to the top of "/etc/pam.d/postlogin": - -session required pam_lastlog.so showfailedVerify users are provided with feedback on when account accesses last occurred with the following command: - -$ sudo grep pam_lastlog /etc/pam.d/postlogin - -session required pam_lastlog.so showfailed - -If "pam_lastlog.so" is missing from "/etc/pam.d/postlogin" file, or the silent option is present, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-020350RHEL 8 must display the date and time of the last successful account logon upon an SSH logon.<VulnDiscussion>Providing users with feedback on when account accesses via SSH last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000052Configure SSH to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/sshd" or in the "sshd_config" file used by the system ("/etc/ssh/sshd_config" will be used in the example) (this file may be named differently or be in a different location if using a version of SSH that is provided by a third-party vendor). +If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-020350RHEL 8 must display the date and time of the last successful account logon upon an SSH logon.<VulnDiscussion>Providing users with feedback on when account accesses via SSH last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000052Configure SSH to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/sshd" or in the "sshd_config" file used by the system ("/etc/ssh/sshd_config" will be used in the example) (this file may be named differently or be in a different location if using a version of SSH that is provided by a third-party vendor). Modify the "PrintLastLog" line in "/etc/ssh/sshd_config" to match the following: @@ -4778,14 +4696,12 @@ rich rules: Ask the system administrator (SA) for the site or program Ports, Protocols, and Services Management Component Local Service Assessment (PPSM CLSA). Verify the services allowed by the firewall match the PPSM CLSA. -If there are additional ports, protocols, or services that are not in the PPSM CLSA, or there are ports, protocols, or services that are prohibited by the PPSM Category Assurance List (CAL), this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>RHEL-08-040070The RHEL 8 file system automounter must be disabled unless required.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000778Configure the operating system to disable the ability to automount devices. +If there are additional ports, protocols, or services that are not in the PPSM CLSA, or there are ports, protocols, or services that are prohibited by the PPSM Category Assurance List (CAL), this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>RHEL-08-040070The RHEL 8 file system automounter must be disabled.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000778Configure RHEL 8 to disable the ability to automount devices. Turn off the automount service with the following commands: $ sudo systemctl stop autofs -$ sudo systemctl disable autofs - -If "autofs" is required for Network File System (NFS), it must be documented with the ISSO.Verify the operating system disables the ability to automount devices. +$ sudo systemctl disable autofsVerify RHEL 8 disables the ability to automount devices. Check to see if automounter service is active with the following command: @@ -4793,11 +4709,11 @@ Note: If the autofs service is not installed, this requirement is not applicable $ sudo systemctl status autofs -autofs.service - Automounts filesystems on demand -Loaded: loaded (/usr/lib/systemd/system/autofs.service; disabled) -Active: inactive (dead) +o autofs.service - Automounts filesystems on demand + Loaded: loaded (/usr/lib/systemd/system/autofs.service; disabled) + Active: inactive (dead) -If the "autofs" status is set to "active" and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>RHEL-08-040080RHEL 8 must be configured to disable USB mass storage.<VulnDiscussion>USB mass storage permits easy introduction of unknown devices, thereby facilitating malicious activity. +If the "autofs" status is set to "active", this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>RHEL-08-040080RHEL 8 must be configured to disable USB mass storage.<VulnDiscussion>USB mass storage permits easy introduction of unknown devices, thereby facilitating malicious activity. Satisfies: SRG-OS-000114-GPOS-00059, SRG-OS-000378-GPOS-00163</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000778Configure the operating system to disable the ability to use the USB Storage kernel module and the ability to use USB mass storage devices. @@ -5241,18 +5157,22 @@ $ sudo yum list installed fapolicyd Installed Packages fapolicyd.x86_64 -If fapolicyd is not installed, this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>RHEL-08-040140RHEL 8 must block unauthorized peripherals before establishing a connection.<VulnDiscussion>Without authenticating devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. +If fapolicyd is not installed, this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>RHEL-08-040140RHEL 8 must block unauthorized peripherals before establishing a connection.<VulnDiscussion>Without authenticating devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. Peripherals include, but are not limited to, such devices as flash drives, external storage, and printers. A new feature that RHEL 8 provides is the USBGuard software framework. The USBguard-daemon is the main component of the USBGuard software framework. It runs as a service in the background and enforces the USB device authorization policy for all USB devices. The policy is defined by a set of rules using a rule language described in the usbguard-rules.conf file. The policy and the authorization state of USB devices can be modified during runtime using the usbguard tool. -The System Administrator (SA) must work with the site Information System Security Officer (ISSO) to determine a list of authorized peripherals and establish rules within the USBGuard software framework to allow only authorized devices.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001958Configure the operating system to enable the blocking of unauthorized peripherals with the following command: +The system administrator (SA) must work with the site information system security officer (ISSO) to determine a list of authorized peripherals and establish rules within the USBGuard software framework to allow only authorized devices.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001958Configure the operating system to enable the blocking of unauthorized peripherals with the following command: This command must be run from a root shell and will create an allow list for any usb devices currently connect to the system. # usbguard generate-policy > /etc/usbguard/rules.conf -Note: Enabling and starting usbguard without properly configuring it for an individual system will immediately prevent any access over a usb device such as a keyboard or mouseVerify the USBGuard has a policy configured with the following command: +Note: Enabling and starting usbguard without properly configuring it for an individual system will immediately prevent any access over a usb device such as a keyboard or mouse. + +Restart usbguard service after creation or update of rules with the following command: + +$ sudo systemctl restart usbguardVerify the USBGuard has a policy configured with the following command: $ sudo usbguard list-rules @@ -5357,19 +5277,24 @@ $ sudo grep -r logout /etc/dconf/db/local.d/* /etc/dconf/db/local.d/00-disable-CAD:logout='' -If the "logout" key is bound to an action, is commented out, or is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040172The systemd Ctrl-Alt-Delete burst key sequence in RHEL 8 must be disabled.<VulnDiscussion>A locally logged-on user who presses Ctrl-Alt-Delete when at the console can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In a graphical user environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the system to disable the CtrlAltDelBurstAction by added or modifying the following line in the "/etc/systemd/system.conf" configuration file: +If the "logout" key is bound to an action, is commented out, or is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040172The systemd Ctrl-Alt-Delete burst key sequence in RHEL 8 must be disabled.<VulnDiscussion>A locally logged-on user who presses Ctrl-Alt-Delete when at the console can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In a graphical user environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to disable the CtrlAltDelBurstAction by adding it to a drop file in a "/etc/systemd/system.conf.d/" configuration file: + +If no drop file exists, create one with the following command: + +$ sudo mkdir -p /etc/systemd/system.conf.d && sudo vi /etc/systemd/system.conf.d/55-CtrlAltDel-BurstAction + +Edit the file to contain the setting by adding the following text: CtrlAltDelBurstAction=none Reload the daemon for this change to take effect. -$ sudo systemctl daemon-reloadVerify RHEL 8 is not configured to reboot the system when Ctrl-Alt-Delete is pressed seven times within two seconds with the following command: - -$ sudo grep -i ctrl /etc/systemd/system.conf +$ sudo systemctl daemon-reloadVerify RHEL 8 is configured to not reboot the system when Ctrl-Alt-Delete is pressed seven times within two seconds with the following command: -CtrlAltDelBurstAction=none +$ sudo grep -iR CtrlAltDelBurstAction /etc/systemd/system* +/etc/systemd/system.conf.d/55-CtrlAltDel-BurstAction:CtrlAltDelBurstAction=none -If the "CtrlAltDelBurstAction" is not set to "none", is commented out, or is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040180The debug-shell systemd service must be disabled on RHEL 8.<VulnDiscussion>The debug-shell requires no authentication and provides root privileges to anyone who has physical access to the machine. While this feature is disabled by default, masking it adds an additional layer of assurance that it will not be enabled via a dependency in systemd. This also prevents attackers with physical access from trivially bypassing security on the machine through valid troubleshooting configurations and gaining root access when the system is rebooted.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the system to mask the debug-shell systemd service with the following command: +If the "CtrlAltDelBurstAction" is not set to "none", commented out, or is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040180The debug-shell systemd service must be disabled on RHEL 8.<VulnDiscussion>The debug-shell requires no authentication and provides root privileges to anyone who has physical access to the machine. While this feature is disabled by default, masking it adds an additional layer of assurance that it will not be enabled via a dependency in systemd. This also prevents attackers with physical access from trivially bypassing security on the machine through valid troubleshooting configurations and gaining root access when the system is rebooted.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the system to mask the debug-shell systemd service with the following command: $ sudo systemctl mask debug-shell.service @@ -5880,45 +5805,31 @@ $ sudo grep -r kernel.unprivileged_bpf_disabled /run/sysctl.d/*.conf /usr/local/ If "kernel.unprivileged_bpf_disabled" is not set to "1", is missing or commented out, this is a finding. -If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040282RHEL 8 must restrict usage of ptrace to descendant processes.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040282RHEL 8 must restrict usage of ptrace to descendant processes.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. +The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographical order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf /usr/lib/sysctl.d/*.conf /lib/sysctl.d/*.conf -/etc/sysctl.conf</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to restrict usage of ptrace to descendant processes by adding the following line to a file, in the "/etc/sysctl.d" directory: +/etc/sysctl.conf</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to restrict usage of ptrace to descendant processes by adding the following line in a dropfile, in the "/etc/sysctl.d" directory with the following commands: -kernel.yama.ptrace_scope = 1 +Create the dropfile if it doesn't already exist: +$ sudo vi /etc/sysctl.d/99-ptrace-restrict.conf -Remove any configurations that conflict with the above from the following locations: -/run/sysctl.d/*.conf -/usr/local/lib/sysctl.d/*.conf -/usr/lib/sysctl.d/*.conf -/lib/sysctl.d/*.conf -/etc/sysctl.conf -/etc/sysctl.d/*.conf +Add the following line to the file: +kernel.yama.ptrace_scope = 1 The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: -$ sudo sysctl --systemVerify RHEL 8 restricts usage of ptrace to descendant processes with the following commands: +$ sudo sysctl --systemVerify RHEL 8 restricts usage of ptrace to descendant processes with the following commands: $ sudo sysctl kernel.yama.ptrace_scope kernel.yama.ptrace_scope = 1 -If the returned line does not have a value of "1", or a line is not returned, this is a finding. - -Check that the configuration files are present to enable this network parameter. - -$ sudo grep -r kernel.yama.ptrace_scope /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf /usr/lib/sysctl.d/*.conf /lib/sysctl.d/*.conf /etc/sysctl.conf /etc/sysctl.d/*.conf - -/etc/sysctl.d/99-sysctl.conf: kernel.yama.ptrace_scope = 1 - -If "kernel.yama.ptrace_scope" is not set to "1", is missing or commented out, this is a finding. - -If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040283RHEL 8 must restrict exposed kernel pointer addresses access.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If "kernel.yama.ptrace_scope" is not set to "1", is missing, or commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040283RHEL 8 must restrict exposed kernel pointer addresses access.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf @@ -5996,45 +5907,33 @@ If "user.max_user_namespaces" is not set to "0", is missing or commented out, th If conflicting results are returned, this is a finding. -If the use of namespaces is operationally required and documented with the ISSM, it is not a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040285RHEL 8 must use reverse path filtering on all IPv4 interfaces.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the use of namespaces is operationally required and documented with the ISSM, it is not a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040285RHEL 8 must use reverse path filtering on all IPv4 interfaces.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. +The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographical order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf /usr/lib/sysctl.d/*.conf /lib/sysctl.d/*.conf -/etc/sysctl.conf</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to use reverse path filtering on all IPv4 interfaces by adding the following line to a file, in the "/etc/sysctl.d" directory: - -net.ipv4.conf.all.rp_filter = 1 - -Remove any configurations that conflict with the above from the following locations: -/run/sysctl.d/*.conf -/usr/local/lib/sysctl.d/*.conf -/usr/lib/sysctl.d/*.conf -/lib/sysctl.d/*.conf -/etc/sysctl.conf -/etc/sysctl.d/*.conf - -The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: +/etc/sysctl.conf</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure RHEL 8 to use reverse path filtering on IPv4 interfaces by default. -$ sudo sysctl --systemVerify RHEL 8 uses reverse path filtering on all IPv4 interfaces with the following commands: +Add or edit the following line in a single system configuration file in the "/etc/sysctl.d/" directory: -$ sudo sysctl net.ipv4.conf.all.rp_filter +Create a configuration file if it does not already exist: -net.ipv4.conf.all.rp_filter = 1 +$ sudo vi /etc/sysctl.d/ipv4_rp_filter.conf -If the returned line does not have a value of "1" or "2", or a line is not returned, this is a finding. +net.ipv4.conf.default.rp_filter = 1 -Check that the configuration files are present to enable this network parameter. +Load settings from all system configuration files with the following command: -$ sudo grep -r net.ipv4.conf.all.rp_filter /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf /usr/lib/sysctl.d/*.conf /lib/sysctl.d/*.conf /etc/sysctl.conf /etc/sysctl.d/*.conf +$ sudo sysctl --systemVerify RHEL 8 uses reverse path filtering on IPv4 interfaces with the following commands: -/etc/sysctl.d/99-sysctl.conf: net.ipv4.conf.all.rp_filter = 1 +$ sudo sysctl net.ipv4.conf.default.rp_filter -If "net.ipv4.conf.all.rp_filter" is not set to "1" or "2", is missing or commented out, this is a finding. +net.ipv4.conf.default.rp_filter = 1 -If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040290RHEL 8 must be configured to prevent unrestricted mail relaying.<VulnDiscussion>If unrestricted mail relaying is permitted, unauthorized senders could use this host as a mail relay for the purpose of sending spam or other unauthorized activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366If "postfix" is installed, modify the "/etc/postfix/main.cf" file to restrict client connections to the local network with the following command: +If "net.ipv4.conf.default.rp_filter" is not set to "1" or is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040290RHEL 8 must be configured to prevent unrestricted mail relaying.<VulnDiscussion>If unrestricted mail relaying is permitted, unauthorized senders could use this host as a mail relay for the purpose of sending spam or other unauthorized activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366If "postfix" is installed, modify the "/etc/postfix/main.cf" file to restrict client connections to the local network with the following command: $ sudo postconf -e 'smtpd_client_restrictions = permit_mynetworks,reject'Verify the system is configured to prevent unrestricted mail relaying. @@ -6186,21 +6085,21 @@ $ sudo yum list installed *ftpd* vsftpd.x86_64 3.0.3-28.el8 appstream -If an FTP server is installed and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040370The gssproxy package must not be installed unless mission essential on RHEL 8.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If an FTP server is installed and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040370The gssproxy package must not be installed unless mission essential on RHEL 8.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. Operating systems are capable of providing a wide variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). The gssproxy package is a proxy for GSS API credential handling and could expose secrets on some networks. It is not needed for normal function of the OS.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000381Document the gssproxy package with the ISSO as an operational requirement or remove it from the system with the following command: -$ sudo yum remove gssproxyVerify the gssproxy package has not been installed on the system with the following commands: +$ sudo yum remove gssproxyNote: If NFS mounts are authorized and in use on the system, this control is not applicable. -$ sudo yum list installed gssproxy +Verify the gssproxy package is not installed with the following command: -gssproxy.x86_64 0.8.0-14.el8 @anaconda +$ dnf list --installed gssproxy -If the gssproxy package is installed and is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding. +Error: No matching Packages to list -If NFS mounts are being used, this is not a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040380The iprutils package must not be installed unless mission essential on RHEL 8.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. +If the "gssproxy" package is installed and is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-040380The iprutils package must not be installed unless mission essential on RHEL 8.<VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. Operating systems are capable of providing a wide variety of functions and services. Some of the functions and services, provided by default, may not be necessary to support essential organizational operations (e.g., key missions, functions). @@ -6316,7 +6215,7 @@ $ sudo grep banner-message-enable /etc/dconf/db/local.d/* banner-message-enable=true -If "banner-message-enable" is set to "false" or is missing, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010141RHEL 8 operating systems booted with United Extensible Firmware Interface (UEFI) must require a unique superusers name upon booting into single-user mode and maintenance.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu. +If "banner-message-enable" is set to "false" or is missing, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010141RHEL 8 operating systems booted with United Extensible Firmware Interface (UEFI) must require a unique superusers name upon booting into single-user mode and maintenance.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu. The GRUB 2 superuser account is an account of last resort. Establishing a unique username for this account hardens the boot loader against brute force attacks. Due to the nature of the superuser account database being distinct from the OS account database, this allows the use of a username that is not among those within the OS account database. Examples of non-unique superusers names are root, superuser, unlock, etc.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to have a unique name for the grub superusers account. @@ -6336,7 +6235,7 @@ $ sudo grep -iw "superusers" /boot/efi/EFI/redhat/grub.cfg set superusers="[someuniquestringhere]" export superusers -If "superusers" is identical to any OS account name or is missing a name, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010149RHEL 8 operating systems booted with a BIOS must require a unique superusers name upon booting into single-user and maintenance modes.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu. +If "superusers" is identical to any OS account name or is missing a name, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010149RHEL 8 operating systems booted with a BIOS must require a unique superusers name upon booting into single-user and maintenance modes.<VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu. The GRUB 2 superuser account is an account of last resort. Establishing a unique username for this account hardens the boot loader against brute force attacks. Due to the nature of the superuser account database being distinct from the OS account database, this allows the use of a username that is not among those within the OS account database. Examples of non-unique superusers names are root, superuser, unlock, etc.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to have a unique name for the grub superusers account. @@ -6356,7 +6255,7 @@ $ sudo grep -iw "superusers" /boot/grub2/grub.cfg set superusers="[someuniquestringhere]" export superusers -If "superusers" is identical to any OS account name or is missing a name, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010152RHEL 8 operating systems must require authentication upon booting into emergency mode.<VulnDiscussion>If the system does not require valid root authentication before it boots into emergency or rescue mode, anyone who invokes emergency or rescue mode is granted privileged access to all files on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require authentication upon booting into emergency mode by adding the following line to the "/usr/lib/systemd/system/emergency.service" file. +If "superusers" is identical to any OS account name or is missing a name, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>RHEL-08-010152RHEL 8 operating systems must require authentication upon booting into emergency mode.<VulnDiscussion>If the system does not require valid root authentication before it boots into emergency or rescue mode, anyone who invokes emergency or rescue mode is granted privileged access to all files on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000213Configure the system to require authentication upon booting into emergency mode by adding the following line to the "/usr/lib/systemd/system/emergency.service" file. ExecStart=-/usr/lib/systemd/systemd-sulogin-shell emergencyCheck to see if the system requires authentication for emergency mode with the following command: @@ -6406,25 +6305,7 @@ ClientAliveInterval 600 If "ClientAliveInterval" does not exist, does not have a value of "600" or less in "/etc/ssh/sshd_config", or is commented out, this is a finding. -If conflicting results are returned, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010287The RHEL 8 SSH daemon must be configured to use system-wide crypto policies.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DoD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8 incorporates system-wide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/ directory. - -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH daemon to use system-wide crypto policies by adding the following line to /etc/sysconfig/sshd: - -# CRYPTO_POLICY= - -A reboot is required for the changes to take effect.Verify that system-wide crypto policies are in effect: - -$ sudo grep CRYPTO_POLICY /etc/sysconfig/sshd - -# CRYPTO_POLICY= - -If the "CRYPTO_POLICY " is uncommented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010472RHEL 8 must have the packages required to use the hardware random number generator entropy gatherer service.<VulnDiscussion>The most important characteristic of a random number generator is its randomness, namely its ability to deliver random numbers that are impossible to predict. Entropy in computer security is associated with the unpredictability of a source of randomness. The random source with high entropy tends to achieve a uniform distribution of random values. Random number generators are one of the most important building blocks of cryptosystems. +If conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010472RHEL 8 must have the packages required to use the hardware random number generator entropy gatherer service.<VulnDiscussion>The most important characteristic of a random number generator is its randomness, namely its ability to deliver random numbers that are impossible to predict. Entropy in computer security is associated with the unpredictability of a source of randomness. The random source with high entropy tends to achieve a uniform distribution of random values. Random number generators are one of the most important building blocks of cryptosystems. The rngd service feeds random data from hardware device to kernel random device. Quality (non-predictable) random number generation is important for several security functions (i.e., ciphers).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Install the packages required to enabled the hardware random number generator entropy gatherer service with the following command: @@ -6460,7 +6341,7 @@ Check that a file system has been created for "/var/tmp" with the following comm /dev/mapper/... /var/tmp xfs defaults,nodev,noexec,nosuid 0 0 -If a separate entry for "/var/tmp" is not in use, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010572RHEL 8 must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory.<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nosuid" option on the /boot/efi directory.For systems that use BIOS, this is Not Applicable. +If a separate entry for "/var/tmp" is not in use, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>RHEL-08-010572RHEL 8 must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory.<VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000366Configure the "/etc/fstab" to use the "nosuid" option on the /boot/efi directory.Note: For vfat file systems and for systems that use BIOS, this is Not Applicable. Verify the /boot/efi directory is mounted with the "nosuid" option with the following command: @@ -7386,21 +7267,7 @@ All administrators must be mapped to the "sysadm_u", "staff_u", or an appropriat All authorized nonadministrative users must be mapped to the "user_u" role. -If they are not mapped in this way, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-040342RHEL 8 SSH server must be configured to use only FIPS-validated key exchange algorithms.<VulnDiscussion>Without cryptographic integrity protections provided by FIPS-validated cryptographic algorithms, information can be viewed and altered by unauthorized users without detection. - -RHEL 8 incorporates system-wide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file. - -The system will attempt to use the first algorithm presented by the client that matches the server list. Listing the values "strongest to weakest" is a method to ensure the use of the strongest algorithm available to secure the SSH connection.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the SSH server to use only FIPS-validated key exchange algorithms by adding or modifying the following line in "/etc/crypto-policies/back-ends/opensshserver.config": - --oKexAlgorithms=ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512 - -A reboot is required for the changes to take effect.Verify that the SSH server is configured to use only FIPS-validated key exchange algorithms: - - $ sudo grep -i kexalgorithms /etc/crypto-policies/back-ends/opensshserver.config - - CRYPTO_POLICY='-oKexAlgorithms=ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512' - -If the entries following "KexAlgorithms" have any algorithms defined other than "ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group14-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512", appear in different order than shown, or are missing or commented out, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>RHEL-08-010019RHEL 8 must ensure cryptographic verification of vendor software packages.<VulnDiscussion>Cryptographic verification of vendor software packages ensures that all software packages are obtained from a valid source and protects against spoofing that could lead to installation of malware on the system. Red Hat cryptographically signs all software packages, which includes updates, with a GPG key to verify that they are valid.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001749CCI-003992Install Red Hat package-signing keys on the system and verify their fingerprints match vendor values. +If they are not mapped in this way, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>RHEL-08-010019RHEL 8 must ensure cryptographic verification of vendor software packages.<VulnDiscussion>Cryptographic verification of vendor software packages ensures that all software packages are obtained from a valid source and protects against spoofing that could lead to installation of malware on the system. Red Hat cryptographically signs all software packages, which includes updates, with a GPG key to verify that they are valid.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001749CCI-003992Install Red Hat package-signing keys on the system and verify their fingerprints match vendor values. Insert RHEL 8 installation disc or attach RHEL 8 installation image to the system. Mount the disc or image to make the contents accessible inside the system. @@ -7481,47 +7348,61 @@ Note: Manual changes to the listed file may be overwritten by the "authselect" p $ sudo grep -i nullok /etc/pam.d/system-auth -If output is produced, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010296RHEL 8 SSH client must be configured to use only Message Authentication Codes (MACs) employing FIPS 140-3 validated cryptographic hash algorithms.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organizationally controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8.4 and newer releases incorporate system-wide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssh.config file.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH client to use only MACs employing FIPS 140-3 approved algorithms. - -For RHEL 8.4 and newer, update the "/etc/crypto-policies/back-ends/openssh.config" file with the following command: -sudo sed -i -E 's/(-oMACs=)[^ ]*/\1hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256/' "$(readlink -f /etc/crypto-policies/back-ends/openssh.config)" - -A reboot is required for the changes to take effect.Verify the SSH client is configured to use only MACs employing FIPS 140-3 approved algorithms with the following command: - -$ grep -i macs /etc/crypto-policies/back-ends/openssh.config - --oMACs hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 - -If the MACs entries in the "openssh.config" file have any hashes other than "MACs hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,hmac-sha2-256,hmac-sha2-512", they are missing, or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010297RHEL 8 SSH client must be configured to use only ciphers employing FIPS 140-3 validated cryptographic hash algorithms.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/opensshserver.config file. - -The system will attempt to use the first hash presented by the client that matches the server list. Listing the values "strongest to weakest" is a method to ensure the use of the strongest hash available to secure the SSH connection. - -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00066</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH client to use only ciphers employing FIPS 140-3 approved algorithms by updating the "/etc/crypto-policies/back-ends/openssh.config" file with the following commands. - -To manually update the ciphers in the systemwide SSH configuration, use the following command: - -$ sudo sed -i -E 's/(-oCiphers=)[^ ]*/\1aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr/' "$(readlink -f /etc/crypto-policies/back-ends/openssh.config)" - -A reboot is required for the changes to take effect.Verify the SSH client is configured to use only ciphers employing FIPS 140-3 approved algorithms. - -To verify the Ciphers in the systemwide SSH configuration file, use the following command: - -$ sudo grep -i ciphers /etc/crypto-policies/back-ends/openssh.config --oCiphers=aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr - -If the ciphers entries in the "openssh.config" file have any hashes other than "aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr", or they are missing, or commented out, this is a finding.SRG-OS-000445-GPOS-00199<GroupDescription></GroupDescription>RHEL-08-010455RHEL 8 must elevate the SELinux context when an administrator calls the sudo command.<VulnDiscussion>Preventing nonprivileged users from executing privileged functions mitigates the risk that unauthorized individuals or processes may gain unnecessary access to information or privileges. +If output is produced, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010296The RHEL 8 SSH client must be configured to use only DOD-approved Message Authentication Codes (MACs) employing FIPS 140-3-validated cryptographic hash algorithms to protect the confidentiality of SSH client connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography, enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + +RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssh.config file.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH client to use only MACs employing FIPS 140-3-approved algorithms. + +Reinstall crypto-policies with the following command: + +$ sudo dnf -y reinstall crypto-policies + +Set the crypto-policy to FIPS with the following command: + +$ sudo update-crypto-policies --set FIPS + +Setting system policy to FIPS + +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify the RHEL 8 SSH client is configured to use only MACs employing FIPS 140-3-approved algorithms. + +To verify the MACs in the systemwide SSH configuration file, use the following command: + +$ grep -i MACs /etc/crypto-policies/back-ends/openssh.config + +MACs hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-256 + +If the MACs entries in the "openssh.config" file have any hashes other than "hmac-sha2-512-etm@openssh.com,hmac-sha2-256-etm@openssh.com,hmac-sha2-512,hmac-sha2-2562", or they are missing or commented out, this is a finding.SRG-OS-000250-GPOS-00093<GroupDescription></GroupDescription>RHEL-08-010297The RHEL 8 SSH client must be configured to use only DOD-approved encryption ciphers employing FIPS 140-3-validated cryptographic hash algorithms to protect the confidentiality of SSH client connections.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Remote access (e.g., RDP) is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography, enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + +RHEL 8 incorporates systemwide crypto policies by default. The SSH configuration file has no effect on the ciphers, MACs, or algorithms unless specifically defined in the /etc/sysconfig/sshd file. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssh.config file. + +Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00066</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001453Configure the RHEL 8 SSH client to use only ciphers employing FIPS 140-3-approved algorithms. + +Reinstall crypto-policies with the following command: + +$ sudo dnf -y reinstall crypto-policies + +Set the crypto-policy to FIPS with the following command: + +$ sudo update-crypto-policies --set FIPS + +Setting system policy to FIPS + +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify the RHEL 8 SSH client is configured to use only ciphers employing FIPS 140-3-approved algorithms. + +To verify the ciphers in the systemwide SSH configuration file, use the following command: + +$ grep -i Ciphers /etc/crypto-policies/back-ends/openssh.config + +Ciphers aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr + +If the cipher entries in the "openssh.config" file have any ciphers other than "aes256-gcm@openssh.com,aes256-ctr,aes128-gcm@openssh.com,aes128-ctr", or they are missing or commented out, this is a finding.SRG-OS-000445-GPOS-00199<GroupDescription></GroupDescription>RHEL-08-010455RHEL 8 must elevate the SELinux context when an administrator calls the sudo command.<VulnDiscussion>Preventing nonprivileged users from executing privileged functions mitigates the risk that unauthorized individuals or processes may gain unnecessary access to information or privileges. Privileged functions include, for example, establishing accounts, performing system integrity checks, or administering cryptographic key management activities. Nonprivileged users are individuals who do not possess appropriate authorizations. Circumventing intrusion detection and prevention mechanisms or malicious code protection mechanisms are examples of privileged functions that require protection from nonprivileged users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-002235Configure the operating system to elevate the SELinux context when an administrator calls the sudo command. @@ -7545,15 +7426,15 @@ This command must be run as root: If conflicting results are returned, this is a finding. -If a designated sudoers administrator group or account(s) is not configured to elevate the SELinux type and role to "sysadm_t" and "sysadm_r" with the use of the sudo command, this is a finding.SRG-OS-000471-GPOS-00215<GroupDescription></GroupDescription>RHEL-08-030655RHEL 8 must audit any script or executable called by cron as root or by any privileged user.<VulnDiscussion>Any script or executable called by cron as root or by any privileged user must be owned by that user, must have the permissions set to 755 or more restrictive, and have no extended rights that allow a nonprivileged user to modify the script or executable.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000172Configure RHEL 8 to audit the execution of any system call made by cron as root or as any privileged user. +If a designated sudoers administrator group or account(s) is not configured to elevate the SELinux type and role to "sysadm_t" and "sysadm_r" with the use of the sudo command, this is a finding.SRG-OS-000471-GPOS-00215<GroupDescription></GroupDescription>RHEL-08-030655RHEL 8 must audit any script or executable called by cron as root or by any privileged user.<VulnDiscussion>Any script or executable called by cron as root or by any privileged user must be owned by that user, must have the permissions set to 755 or more restrictive, and have no extended rights that allow a nonprivileged user to modify the script or executable.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000172Configure RHEL 8 to audit the execution of any system call made by cron as root or as any privileged user. Add or update the following file system rules to "/etc/audit/rules.d/audit.rules": -auditctl -w /etc/cron.d/ -p wa -k cronjobs -auditctl -w /var/spool/cron/ -p wa -k cronjobs +-w /etc/cron.d/ -p wa -k cronjobs +-w /var/spool/cron/ -p wa -k cronjobs To load the rules to the kernel immediately, use the following command: -$ sudo augenrules --loadVerify RHEL 8 is configured to audit the execution of any system call made by cron as root or as any privileged user. +$ sudo augenrules --loadVerify RHEL 8 is configured to audit the execution of any system call made by cron as root or as any privileged user. $ sudo auditctl -l | grep /etc/cron.d -w /etc/cron.d -p wa -k cronjobs @@ -7561,4 +7442,83 @@ $ sudo auditctl -l | grep /etc/cron.d $ sudo auditctl -l | grep /var/spool/cron -w /var/spool/cron -p wa -k cronjobs -If either of these commands do not return the expected output, or the lines are commented out, this is a finding. \ No newline at end of file +If either of these commands do not return the expected output, or the lines are commented out, this is a finding.SRG-OS-000163-GPOS-00072<GroupDescription></GroupDescription>RHEL-08-020360RHEL 8 must automatically exit interactive command shell user sessions after 10 minutes of inactivity.<VulnDiscussion>Terminating an idle interactive command shell user session within a short time period reduces the window of opportunity for unauthorized personnel to take control of it when left unattended in a virtual terminal or physical console. + +Satisfies: SRG-OS-000163-GPOS-00072, SRG-OS-000029-GPOS-00010</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-001133Configure RHEL 8 to exit interactive command shell user sessions after 10 minutes of inactivity. + +Add or edit the following line in "/etc/profile.d/tmout.sh": + +#!/bin/bash + +declare -xr TMOUT=600Verify RHEL 8 is configured to exit interactive command shell user sessions after 10 minutes of inactivity or less with the following command: + +$ sudo grep -i tmout /etc/profile /etc/profile.d/*.sh + +/etc/profile.d/tmout.sh:declare -xr TMOUT=600 + +If "TMOUT" is not set to "600" or less in a script located in the "/etc/'profile.d/ directory, is missing or is commented out, this is a finding.SRG-OS-000033-GPOS-00014<GroupDescription></GroupDescription>RHEL-08-010280RHEL 8 IP tunnels must use FIPS 140-3-approved cryptographic algorithms.<VulnDiscussion>Overriding the system crypto policy makes the behavior of the Libreswan service violate expectations and makes system configuration more fragmented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-000068Configure Libreswan to use the system cryptographic policy. + +Add the following line to "/etc/ipsec.conf": + +include /etc/crypto-policies/back-ends/libreswan.configNote: If the ipsec service is not installed, this requirement is Not Applicable. + +Verify the IPsec service uses the system crypto policy with the following command: + +$ sudo grep include /etc/ipsec.conf /etc/ipsec.d/*.conf + +/etc/ipsec.conf:include /etc/crypto-policies/back-ends/libreswan.config +/etc/ipsec.conf:include /etc/ipsec.d/*.conf + +If the ipsec configuration file does not contain "include /etc/crypto-policies/back-ends/libreswan.config", this is a finding.SRG-OS-000423-GPOS-00187<GroupDescription></GroupDescription>RHEL-08-010275RHEL 8 must implement DOD-approved encryption in the bind package.<VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + +RHEL 8 incorporates systemwide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/ directory. + +Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000426-GPOS-00190</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-002418Configure BIND to use the system crypto policy. + +Add the following line to the "options" section in "/etc/named.conf": + +include "/etc/crypto-policies/back-ends/bind.config";Note: If the "bind" package is not installed, this requirement is Not Applicable. + +Verify BIND uses the system crypto policy with the following command: + +$ sudo grep include /etc/named.conf + +include "/etc/crypto-policies/back-ends/bind.config";' + +If BIND is installed and the BIND config file does not contain the include "/etc/crypto-policies/back-ends/bind.config" directive, or the line is commented out, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>RHEL-08-010270RHEL 8 cryptographic policy must not be overridden.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. + +Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-002450Configure RHEL 8 to correctly implement the systemwide cryptographic policies by reinstalling the crypto-policies package contents. + +Reinstall crypto-policies with the following command: + +$ sudo dnf -y reinstall crypto-policies + +Set the crypto-policy to FIPS with the following command: + +$ sudo update-crypto-policies --set FIPS + +Setting system policy to FIPS + +Note: Systemwide crypto policies are applied on application startup. It is recommended to restart the system for the change of policies to fully take place.Verify RHEL 8 cryptographic policies are not overridden. + +Verify the configured policy matches the generated policy with the following command: + +$ sudo update-crypto-policies --is-applied + +The configured policy is applied + +If the returned message does not match the above, this is a finding.SRG-OS-000396-GPOS-00176<GroupDescription></GroupDescription>RHEL-08-010015RHEL 8 must have the crypto-policies package installed.<VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. + +Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target Red Hat Enterprise Linux 8DISADPMS TargetRed Hat Enterprise Linux 82921CCI-002450Install the crypto-policies package (if the package is not already installed) with the following command: + +$ sudo dnf -y install crypto-policiesVerify the RHEL 8 crypto-policies package is installed with the following command: + +$ sudo dnf list --installed crypto-policies + +Updating Subscription Management repositories. +Installed Packages +crypto-policies.noarch 20230731-1.git3177e06.el8 @rhel-8-for-x86_64-baseos-rpms + +If the crypto-policies package is not installed, this is a finding. \ No newline at end of file diff --git a/shared/references/disa-stig-rhel8-v2r5-xccdf-scap.xml b/shared/references/disa-stig-rhel8-v2r6-xccdf-scap.xml similarity index 97% rename from shared/references/disa-stig-rhel8-v2r5-xccdf-scap.xml rename to shared/references/disa-stig-rhel8-v2r6-xccdf-scap.xml index c1a92634af36..5121706257da 100644 --- a/shared/references/disa-stig-rhel8-v2r5-xccdf-scap.xml +++ b/shared/references/disa-stig-rhel8-v2r6-xccdf-scap.xml @@ -1,36 +1,36 @@ - - + + - + - + - + - + - - + + - + Red Hat Enterprise Linux 8 - oval:mil.disa.stig.rhel8os:def:1 + oval:mil.disa.stig.rhel8os:def:1 - + - accepted + accepted Red Hat Enterprise Linux 8 STIG SCAP Benchmark This Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil. @@ -40,97 +40,121 @@ DISA STIG.DOD.MIL - Benchmark Date: 01 Oct 2025 - 3.5.1 + Benchmark Date: 05 Jan 2026 + 3.5.2 1.10.0 Linux krb5 workstation 1.17 or higher is not installed - + + + + + Linux with BIND installed + + Linux krb5 server 1.17 or higher is not installed - + + + + + Linux with NFS mounts configured + + Linux IPv6 Enabled - + + + + + Linux with Libreswan installed + + Linux BIOS Boot - + RHEL 8.2 or Higher - + Gnome-shell Package - + + + + + Linux with no NFS mounts configured + + RHEL 8.1 or Lower - + Linux UEFI Boot - + Linux with TFTP installed - + Kernel dumps are enabled - + Linux UEFI system with boot partition file type other than VFAT - + Linux with postfix installed - + Linux with autofs installed - + RHEL 8.7 or Higher - + - 002.005 + 002.006 DISA DISA @@ -161,7 +185,6 @@ - @@ -249,7 +272,6 @@ - @@ -420,6 +442,10 @@ + + + + I - Mission Critical Public @@ -445,7 +471,6 @@ - @@ -533,7 +558,6 @@ - @@ -704,6 +728,10 @@ + + + + I - Mission Critical Sensitive @@ -729,7 +757,6 @@ - @@ -817,7 +844,6 @@ - @@ -988,6 +1014,10 @@ + + + + II - Mission Support Classified @@ -1013,7 +1043,6 @@ - @@ -1101,7 +1130,6 @@ - @@ -1272,6 +1300,10 @@ + + + + II - Mission Support Public @@ -1297,7 +1329,6 @@ - @@ -1385,7 +1416,6 @@ - @@ -1556,6 +1586,10 @@ + + + + II - Mission Support Sensitive @@ -1581,7 +1615,6 @@ - @@ -1669,7 +1702,6 @@ - @@ -1840,6 +1872,10 @@ + + + + III - Administrative Classified @@ -1865,7 +1901,6 @@ - @@ -1953,7 +1988,6 @@ - @@ -2124,6 +2158,10 @@ + + + + III - Administrative Public @@ -2149,7 +2187,6 @@ - @@ -2237,7 +2274,6 @@ - @@ -2408,6 +2444,10 @@ + + + + III - Administrative Sensitive @@ -2433,7 +2473,6 @@ - @@ -2521,7 +2560,6 @@ - @@ -2692,14 +2730,18 @@ + + + + Disable Slow Rules This profile disables rules known to have poor performance in some environments, such as systems with large numbers of user accounts. + - @@ -2722,8 +2764,9 @@ - + + @@ -2732,7 +2775,6 @@ - @@ -2744,30 +2786,27 @@ - + - - - - + @@ -2810,12 +2849,14 @@ + + - + @@ -2832,12 +2873,12 @@ + + - - @@ -2862,9 +2903,11 @@ + + @@ -2872,19 +2915,20 @@ + - + - + + - @@ -2893,6 +2937,7 @@ + @@ -2900,7 +2945,6 @@ - @@ -2932,32 +2976,31 @@ + - - + + - + - - @@ -2991,7 +3034,7 @@ Note: The life-cycle time spans and dates are subject to adjustment.</VulnDis Upgrade to a supported version of RHEL 8. - + @@ -3027,7 +3070,7 @@ The "rsyslog" service must be restarted for the changes to take effect. To resta $ sudo systemctl restart rsyslog.service - + @@ -3058,7 +3101,7 @@ Edit/Modify the following line in the "/etc/login.defs" file and set "[ENCRYPT_M ENCRYPT_METHOD SHA512 - + @@ -3083,7 +3126,7 @@ Passwords need to be protected at all times, and encryption is the standard meth Lock all interactive user accounts not using SHA-512 hashing until the passwords can be regenerated with SHA-512. - + @@ -3112,14 +3155,14 @@ Edit/modify the following line in the "/etc/login.defs" file and set "SHA_CRYPT_ SHA_CRYPT_MIN_ROUNDS 100000 - + SRG-OS-000080-GPOS-00048 <GroupDescription></GroupDescription> - + RHEL-08-010140 RHEL 8 operating systems booted with United Extensible Firmware Interface (UEFI) must require authentication upon booting into single-user mode and maintenance. <VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -3141,14 +3184,14 @@ Enter password: Confirm password: - + SRG-OS-000080-GPOS-00048 <GroupDescription></GroupDescription> - + RHEL-08-010150 RHEL 8 operating systems booted with a BIOS must require authentication upon booting into single-user and maintenance modes. <VulnDiscussion>If the system does not require valid authentication before it boots into single-user or maintenance mode, anyone who invokes single-user or maintenance mode is granted privileged access to all files on the system. GRUB 2 is the default boot loader for RHEL 8 and is designed to require a password to boot into single-user mode or make modifications to the boot menu.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -3170,14 +3213,14 @@ Enter password: Confirm password: - + SRG-OS-000080-GPOS-00048 <GroupDescription></GroupDescription> - + RHEL-08-010151 RHEL 8 operating systems must require authentication upon booting into rescue mode. <VulnDiscussion>If the system does not require valid root authentication before it boots into emergency or rescue mode, anyone who invokes emergency or rescue mode is granted privileged access to all files on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -3194,7 +3237,7 @@ Confirm password: ExecStart=-/usr/lib/systemd/systemd-sulogin-shell rescue - + @@ -3224,7 +3267,7 @@ Edit/modify the following line in the "/etc/pam.d/password-auth" file to include password sufficient pam_unix.so sha512 - + @@ -3256,7 +3299,7 @@ FIPS 140-2 is the current standard for validating that mechanisms used to access Remove any files with the .keytab extension from the operating system. - + @@ -3287,7 +3330,7 @@ FIPS 140-2 is the current standard for validating that mechanisms used to access $ sudo yum remove krb5-workstation - + @@ -3317,7 +3360,7 @@ SELINUX=enforcing A reboot is required for the changes to take effect. - + @@ -3343,7 +3386,7 @@ Policycoreutils contains the policy core utilities that are required for basic o $ sudo yum install policycoreutils - + @@ -3381,7 +3424,7 @@ For the changes to take effect, the SSH daemon must be restarted: $ sudo systemctl restart sshd.service - + @@ -3407,7 +3450,7 @@ The structure and content of error messages must be carefully considered by the $ sudo chmod 0640 /var/log/messages - + @@ -3433,7 +3476,7 @@ The structure and content of error messages must be carefully considered by the $ sudo chown root /var/log/messages - + @@ -3459,7 +3502,7 @@ The structure and content of error messages must be carefully considered by the $ sudo chgrp root /var/log/messages - + @@ -3485,7 +3528,7 @@ The structure and content of error messages must be carefully considered by the $ sudo chmod 0755 /var/log - + @@ -3511,7 +3554,7 @@ The structure and content of error messages must be carefully considered by the $ sudo chown root /var/log - + @@ -3537,7 +3580,7 @@ The structure and content of error messages must be carefully considered by the $ sudo chgrp root /var/log - + @@ -3572,45 +3615,7 @@ Restart the SSH Daemon with the following command: $ sudo systemctl restart sshd.service - - - - - - SRG-OS-000250-GPOS-00093 - <GroupDescription></GroupDescription> - - RHEL-08-010294 - The RHEL 8 operating system must implement DoD-approved TLS encryption in the OpenSSL package. - <VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DoD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8 incorporates system-wide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssl.config file. - -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> - - DPMS Target Red Hat Enterprise Linux 8 - DISA - DPMS Target - Red Hat Enterprise Linux 8 - 2921 - - CCI-001453 - Configure the RHEL 8 OpenSSL library to use only DoD-approved TLS encryption by editing the following line in the "/etc/crypto-policies/back-ends/opensslcnf.config" file: - -For versions prior to crypto-policies-20210617-1.gitc776d3e.el8.noarch: -MinProtocol = TLSv1.2 - -For version crypto-policies-20210617-1.gitc776d3e.el8.noarch and newer: -TLS.MinProtocol = TLSv1.2 -DTLS.MinProtocol = DTLSv1.2 -A reboot is required for the changes to take effect. - - - + @@ -3638,7 +3643,7 @@ Run the following command, replacing "[FILE]" with any system command with a mod $ sudo chmod 755 [FILE] - + @@ -3666,7 +3671,7 @@ Run the following command, replacing "[FILE]" with any system command file not o $ sudo chown root [FILE] - + @@ -3694,7 +3699,7 @@ Run the following command, replacing "[FILE]" with any system command file not g $ sudo chgrp root [FILE] - + @@ -3720,7 +3725,7 @@ This requirement applies to RHEL 8 with software libraries that are accessible a $ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' -perm /022 -exec chmod go-w {} + - + @@ -3746,16 +3751,16 @@ This requirement applies to RHEL 8 with software libraries that are accessible a $ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' ! -user root -exec chown root {} + - + SRG-OS-000259-GPOS-00100 <GroupDescription></GroupDescription> - + RHEL-08-010350 - RHEL 8 library files must be group-owned by root or a system account. + RHEL 8 library files must be group-owned by root. <VulnDiscussion>If RHEL 8 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. This requirement applies to RHEL 8 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs that execute with escalated privileges. Only qualified and authorized individuals will be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -3772,7 +3777,7 @@ This requirement applies to RHEL 8 with software libraries that are accessible a $ sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' ! -group root -exec chown :root {} + - + @@ -3801,7 +3806,7 @@ Verifying the authenticity of the software prior to installation validates the i gpgcheck=1 - + @@ -3832,7 +3837,7 @@ Set the "localpkg_gpgcheck" option to "True" in the "/etc/dnf/dnf.conf" file: localpkg_gpgcheck=True - + @@ -3881,7 +3886,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -3933,7 +3938,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -3985,14 +3990,14 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + SRG-OS-000138-GPOS-00069 <GroupDescription></GroupDescription> - + RHEL-08-010375 RHEL 8 must restrict access to the kernel message buffer. <VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. @@ -4037,14 +4042,14 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + SRG-OS-000138-GPOS-00069 <GroupDescription></GroupDescription> - + RHEL-08-010376 RHEL 8 must prevent kernel profiling by unprivileged users. <VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. @@ -4089,7 +4094,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -4116,7 +4121,7 @@ Satisfies: SRG-OS-000373-GPOS-00156, SRG-OS-000373-GPOS-00157, SRG-OS-000373-GPO Remove any occurrence of "NOPASSWD" found in "/etc/sudoers" file or files in the "/etc/sudoers.d" directory. - + @@ -4143,7 +4148,7 @@ Satisfies: SRG-OS-000373-GPOS-00156, SRG-OS-000373-GPOS-00157, SRG-OS-000373-GPO Remove any occurrence of "!authenticate" found in "/etc/sudoers" file or files in the "/etc/sudoers.d" directory. - + @@ -4176,7 +4181,7 @@ This requirement only applies to components where this is specific to the functi $ sudo yum install openssl-pkcs11 - + @@ -4224,7 +4229,7 @@ Issue the following command to make the changes take effect: $ sudo sysctl --system - + @@ -4250,7 +4255,7 @@ Set the "clean_requirements_on_remove" option to "True" in the "/etc/dnf/dnf.con clean_requirements_on_remove=True - + @@ -4280,7 +4285,7 @@ SELINUXTYPE=targeted A reboot is required for the changes to take effect. - + @@ -4304,7 +4309,7 @@ A reboot is required for the changes to take effect. $ sudo rm /etc/ssh/shosts.equiv - + @@ -4328,7 +4333,7 @@ $ sudo rm /etc/ssh/shosts.equiv $ sudo rm /[path]/[to]/[file]/.shosts - + @@ -4356,7 +4361,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -4384,7 +4389,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -4412,7 +4417,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -4421,7 +4426,7 @@ $ sudo systemctl restart sshd.service <GroupDescription></GroupDescription> RHEL-08-010520 - The RHEL 8 SSH daemon must not allow authentication using known host’s authentication. + The RHEL 8 SSH daemon must not allow authentication using known host's authentication. <VulnDiscussion>Configuring this setting for the SSH daemon provides additional assurance that remote logon via SSH will require a password, even in the event of misconfiguration elsewhere.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> DPMS Target Red Hat Enterprise Linux 8 @@ -4431,7 +4436,7 @@ $ sudo systemctl restart sshd.service 2921 CCI-000366 - Configure the SSH daemon to not allow authentication using known host’s authentication. + Configure the SSH daemon to not allow authentication using known host's authentication. Add the following line in "/etc/ssh/sshd_config", or uncomment the line and set the value to "yes": @@ -4442,7 +4447,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -4472,7 +4477,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -4494,7 +4499,7 @@ $ sudo systemctl restart sshd.service Migrate the "/var" path onto a separate file system. - + @@ -4516,7 +4521,7 @@ $ sudo systemctl restart sshd.service Migrate the "/var/log" path onto a separate file system. - + @@ -4538,7 +4543,7 @@ $ sudo systemctl restart sshd.service Migrate the system audit data path onto a separate file system. - + @@ -4560,7 +4565,7 @@ $ sudo systemctl restart sshd.service Migrate the "/tmp" directory onto a separate file system/partition. - + @@ -4591,7 +4596,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -4619,7 +4624,7 @@ $ sudo systemctl start rsyslog.service $ sudo systemctl enable rsyslog.service - + @@ -4641,7 +4646,7 @@ $ sudo systemctl enable rsyslog.service Configure the "/etc/fstab" to use the "nosuid" option on file systems that contain user home directories for interactive users. - + @@ -4664,17 +4669,17 @@ $ sudo systemctl enable rsyslog.service Configure the "/etc/fstab" to use the "nosuid" option on the /boot directory. - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010580 RHEL 8 must prevent special devices on non-root local partitions. - <VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access. The only legitimate location for device files is the /dev directory located on the root partition.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> + <VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for nonprivileged users to attain unauthorized administrative access. The only legitimate location for device files is the /dev directory located on the root partition.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> DPMS Target Red Hat Enterprise Linux 8 DISA @@ -4686,14 +4691,14 @@ $ sudo systemctl enable rsyslog.service Configure the "/etc/fstab" to use the "nodev" option on all non-root local partitions. - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010630 RHEL 8 must prevent code from being executed on file systems that are imported via Network File System (NFS). <VulnDiscussion>The "noexec" mount option causes the system not to execute binary files. This option must be used for mounting any file system not containing approved binary as they may be incompatible. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -4704,18 +4709,19 @@ $ sudo systemctl enable rsyslog.service Red Hat Enterprise Linux 8 2921 + CCI-000366 Configure the "/etc/fstab" to use the "noexec" option on file systems that are being imported via NFS. - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010640 RHEL 8 must prevent special devices on file systems that are imported via Network File System (NFS). <VulnDiscussion>The "nodev" mount option causes the system to not interpret character or block special devices. Executing character or block special devices from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -4726,18 +4732,19 @@ $ sudo systemctl enable rsyslog.service Red Hat Enterprise Linux 8 2921 + CCI-000366 Configure the "/etc/fstab" to use the "nodev" option on file systems that are being imported via NFS. - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010650 RHEL 8 must prevent files with the setuid and setgid bit set from being executed on file systems that are imported via Network File System (NFS). <VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -4748,23 +4755,24 @@ $ sudo systemctl enable rsyslog.service Red Hat Enterprise Linux 8 2921 + CCI-000366 Configure the "/etc/fstab" to use the "nosuid" option on file systems that are being imported via NFS. - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010671 RHEL 8 must disable the kernel.core_pattern. - <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. +The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographical order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf @@ -4779,26 +4787,20 @@ The sysctl --system command will load settings from all system configuration fil 2921 CCI-000366 - Configure RHEL 8 to disable storing core dumps. + Configure RHEL 8 to restrict usage of ptrace to descendant processes by adding the following line to a dropfile in the "/etc/sysctl.d" directory: -Add or edit the following line in a system configuration file, in the "/etc/sysctl.d/" directory: +Create a dropfile if it does not already exist: +$ sudo vi /etc/sysctl.d/99-disable-coredump.conf +Add the following to the file: kernel.core_pattern = |/bin/false -Remove any configurations that conflict with the above from the following locations: -/run/sysctl.d/*.conf -/usr/local/lib/sysctl.d/*.conf -/usr/lib/sysctl.d/*.conf -/lib/sysctl.d/*.conf -/etc/sysctl.conf -/etc/sysctl.d/*.conf - The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: $ sudo sysctl --system - + - + @@ -4835,17 +4837,17 @@ Reload the daemon for this change to take effect. $ sudo systemctl daemon-reload - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010673 RHEL 8 must disable core dumps for all users. - <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. A core dump includes a memory image taken at the time the operating system terminates an application. The memory image could contain sensitive data and is generally useful only for developers trying to debug problems.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -4857,14 +4859,16 @@ A core dump includes a memory image taken at the time the operating system termi CCI-000366 - Configure the operating system to disable core dumps for all users. + Configure the operating system to disable core dumps for all users. -Add the following line to the top of the /etc/security/limits.conf or in a ".conf" file defined in /etc/security/limits.d/: +Add the following line to the top of the /etc/security/limits.conf or in a single ".conf" file defined in /etc/security/limits.d/: -* hard core 0 - +* hard core 0 + +Remove or comment out any entries for users or groups with a value set to anything other than "0". + - + @@ -4893,7 +4897,7 @@ Add or modify the following line in /etc/systemd/coredump.conf: Storage=none - + @@ -4922,7 +4926,7 @@ Add or modify the following line in /etc/systemd/coredump.conf: ProcessSizeMax=0 - + @@ -4950,7 +4954,7 @@ If manually configuring DNS, edit the "/etc/resolv.conf" file to uncomment or ad $ sudo echo -n > /etc/resolv.conf - + @@ -4972,7 +4976,7 @@ $ sudo echo -n > /etc/resolv.conf Assign home directories to all local interactive users on RHEL 8 that currently do not have a home directory assigned. - + @@ -4991,14 +4995,14 @@ $ sudo echo -n > /etc/resolv.conf 2921 CCI-000366 - Change the mode of interactive user’s home directories to "0750". To change the mode of a local interactive user’s home directory, use the following command: + Change the mode of interactive user's home directories to "0750". To change the mode of a local interactive user's home directory, use the following command: Note: The example will be for the user "smithj". $ sudo chmod 0750 /home/smithj - + @@ -5022,7 +5026,7 @@ $ sudo chmod 0750 /home/smithj CREATE_HOME yes - + @@ -5048,14 +5052,14 @@ Note: The example will be for the smithj user, who has a home directory of "/hom $ sudo chmod 0740 /home/smithj/.<INIT_FILE> - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010800 A separate RHEL 8 filesystem must be used for user home directories (such as /home or an equivalent). <VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -5070,7 +5074,7 @@ Note: The example will be for the smithj user, who has a home directory of "/hom Migrate the "/home" directory onto a separate file system. - + @@ -5098,7 +5102,7 @@ Add or edit the line for the "AutomaticLoginEnable" parameter in the [daemon] se AutomaticLoginEnable=false - + @@ -5128,7 +5132,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -5167,7 +5171,7 @@ The "sssd" service must be restarted for the changes to take effect. To restart $ sudo systemctl restart sssd.service - + @@ -5200,7 +5204,7 @@ Add/Modify the "/etc/security/faillock.conf" file to match the following line: deny = 3 - + @@ -5239,7 +5243,7 @@ The "sssd" service must be restarted for the changes to take effect. To restart $ sudo systemctl restart sssd.service - + @@ -5272,7 +5276,7 @@ Add/Modify the "/etc/security/faillock.conf" file to match the following line: fail_interval = 900 - + @@ -5311,7 +5315,7 @@ The "sssd" service must be restarted for the changes to take effect. To restart $ sudo systemctl restart sssd.service - + @@ -5343,7 +5347,7 @@ Add/Modify the "/etc/security/faillock.conf" file to match the following line: unlock_time = 0 - + @@ -5382,7 +5386,7 @@ The "sssd" service must be restarted for the changes to take effect. To restart $ sudo systemctl restart sssd.service - + @@ -5415,7 +5419,7 @@ Add/Modify the "/etc/security/faillock.conf" file to match the following line: silent - + @@ -5456,7 +5460,7 @@ The "sssd" service must be restarted for the changes to take effect. To restart $ sudo systemctl restart sssd.service - + @@ -5489,7 +5493,7 @@ Add/Modify the "/etc/security/faillock.conf" file to match the following line: audit - + @@ -5530,7 +5534,7 @@ The "sssd" service must be restarted for the changes to take effect. To restart $ sudo systemctl restart sssd.service - + @@ -5563,7 +5567,7 @@ Add/Modify the "/etc/security/faillock.conf" file to match the following line: even_deny_root - + @@ -5591,7 +5595,7 @@ Add the following line to the top of the /etc/security/limits.conf or in a ".con * hard maxlogins 10 - + @@ -5632,7 +5636,7 @@ Update the system databases: $ sudo dconf update - + @@ -5677,7 +5681,7 @@ Run the following command to update the database: $ sudo dconf update - + @@ -5707,7 +5711,7 @@ Add the following line to the "/etc/pam.d/password-auth" file (or modify the lin password requisite pam_pwquality.so - + @@ -5740,7 +5744,7 @@ ucredit = -1 Remove any configurations that conflict with the above value. - + @@ -5773,7 +5777,7 @@ lcredit = -1 Remove any configurations that conflict with the above value. - + @@ -5806,7 +5810,7 @@ dcredit = -1 Remove any configurations that conflict with the above value. - + @@ -5839,7 +5843,7 @@ maxclassrepeat = 4 Remove any configurations that conflict with the above value. - + @@ -5872,7 +5876,7 @@ maxrepeat = 3 Remove any configurations that conflict with the above value. - + @@ -5905,7 +5909,7 @@ minclass = 4 Remove any configurations that conflict with the above value. - + @@ -5938,7 +5942,7 @@ difok = 8 Remove any configurations that conflict with the above value. - + @@ -5963,7 +5967,7 @@ Remove any configurations that conflict with the above value. $ sudo chage -m 1 [user] - + @@ -5990,7 +5994,7 @@ Add the following line in "/etc/login.defs" (or modify the line to have the requ PASS_MIN_DAYS 1 - + @@ -6017,7 +6021,7 @@ Add, or modify the following line in the "/etc/login.defs" file: PASS_MAX_DAYS 60 - + @@ -6042,7 +6046,7 @@ PASS_MAX_DAYS 60 $ sudo chage -M 60 [user] - + @@ -6079,7 +6083,7 @@ minlen = 15 Remove any configurations that conflict with the above value. - + @@ -6110,7 +6114,7 @@ Add, or modify the following line in the "/etc/login.defs" file: PASS_MIN_LEN 15 - + @@ -6140,7 +6144,7 @@ Satisfies: SRG-OS-000104-GPOS-00051, SRG-OS-000121-GPOS-00062, SRG-OS-000042-GPO Edit the file "/etc/passwd" and provide each interactive user account that has a duplicate User ID (UID) with a unique UID. - + @@ -6171,7 +6175,7 @@ $ sudo useradd -D -f 35 DoD recommendation is 35 days, but a lower value is acceptable. The value "-1" will disable this feature, and "0" will disable the account immediately after the password expires. - + @@ -6204,7 +6208,7 @@ ocredit = -1 Remove any configurations that conflict with the above value. - + @@ -6232,7 +6236,7 @@ Add or change the following line in "/etc/sssd/sssd.conf" just below the line "[ offline_credentials_expiration = 1 - + @@ -6260,7 +6264,7 @@ dictcheck=1 Remove any configurations that conflict with the above value. - + @@ -6288,7 +6292,7 @@ Modify the "/etc/login.defs" file to set the "FAIL_DELAY" parameter to "4" or gr FAIL_DELAY 4 - + @@ -6316,33 +6320,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - - - - - - SRG-OS-000480-GPOS-00227 - <GroupDescription></GroupDescription> - - RHEL-08-020340 - RHEL 8 must display the date and time of the last successful account logon upon logon. - <VulnDiscussion>Providing users with feedback on when account accesses last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> - - DPMS Target Red Hat Enterprise Linux 8 - DISA - DPMS Target - Red Hat Enterprise Linux 8 - 2921 - - CCI-000052 - Configure the operating system to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/postlogin". - -Add the following line to the top of "/etc/pam.d/postlogin": - -session required pam_lastlog.so showfailed - - - + @@ -6370,7 +6348,7 @@ PrintLastLog yes The SSH service must be restarted for changes to "sshd_config" to take effect. - + @@ -6396,7 +6374,7 @@ Add or edit the line for the "UMASK" parameter in "/etc/login.defs" file to "077 UMASK 077 - + @@ -6430,7 +6408,7 @@ Add or update the following file system rules to "/etc/audit/rules.d/audit.rules The audit daemon must be restarted for the changes to take effect. - + @@ -6460,7 +6438,7 @@ Edit the following line in "/etc/audit/auditd.conf" to ensure that administrator action_mail_acct = root - + @@ -6490,7 +6468,7 @@ Add/update the following line in "/etc/aliases": postmaster: root - + @@ -6522,7 +6500,7 @@ disk_error_action = HALT If availability has been determined to be more important, and this decision is documented with the ISSO, configure the operating system to notify system administration staff and ISSO staff in the event of an audit processing failure by setting the "disk_error_action" to "SYSLOG". - + @@ -6556,7 +6534,7 @@ disk_full_action = HALT If availability has been determined to be more important, and this decision is documented with the ISSO, configure the operating system to notify system administration staff and ISSO staff in the event of an audit processing failure by setting the "disk_full_action" to "SYSLOG". - + @@ -6584,7 +6562,7 @@ Add or update the following line in "/etc/audit/auditd.conf" file: local_events = yes - + @@ -6616,7 +6594,7 @@ name_format = hostname The audit daemon must be restarted for changes to take effect. - + @@ -6646,7 +6624,7 @@ log_format = ENRICHED The audit daemon must be restarted for changes to take effect. - + @@ -6674,7 +6652,7 @@ Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPO $ sudo chmod 0600 /var/log/audit/audit.log - + @@ -6704,7 +6682,7 @@ $ sudo chown root [audit_log_file] Replace "[audit_log_file]" to the correct audit log path, by default this location is "/var/log/audit/audit.log". - + @@ -6732,7 +6710,7 @@ Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPO log_group = root - + @@ -6762,7 +6740,7 @@ $ sudo chown root [audit_log_directory] Replace "[audit_log_directory]" with the correct audit log directory path, by default this location is usually "/var/log/audit". - + @@ -6792,7 +6770,7 @@ $ sudo chgrp root [audit_log_directory] Replace "[audit_log_directory]" with the correct audit log directory path, by default this location is usually "/var/log/audit". - + @@ -6822,7 +6800,7 @@ $ sudo chmod 0700 [audit_log_directory] Replace "[audit_log_directory]" to the correct audit log directory path, by default this location is "/var/log/audit". - + @@ -6854,7 +6832,7 @@ Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPO Note: Once set, the system must be rebooted for auditing to be changed. It is recommended to add this option as the last step in securing the system. - + @@ -6884,7 +6862,7 @@ Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000058-GPOS-00028, SRG-OS-000059-GPO --loginuid-immutable - + @@ -6916,7 +6894,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -6948,7 +6926,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -6980,7 +6958,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -7012,7 +6990,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -7044,7 +7022,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -7076,7 +7054,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -7108,7 +7086,7 @@ Add or update the following file system rule to "/etc/audit/rules.d/audit.rules" The audit daemon must be restarted for the changes to take effect. - + @@ -7140,7 +7118,7 @@ Install the audit service (if the audit service is not already installed) with t $ sudo yum install audit - + @@ -7172,7 +7150,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7217,7 +7195,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7249,7 +7227,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7281,7 +7259,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7313,7 +7291,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7345,7 +7323,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7377,7 +7355,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7409,7 +7387,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7442,7 +7420,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7474,7 +7452,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7506,7 +7484,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7538,7 +7516,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7570,7 +7548,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7602,7 +7580,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7634,7 +7612,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7666,7 +7644,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7698,7 +7676,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7730,7 +7708,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7762,7 +7740,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7794,7 +7772,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7826,7 +7804,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7861,7 +7839,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7901,7 +7879,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7933,7 +7911,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7966,7 +7944,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -7998,7 +7976,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8030,7 +8008,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8073,7 +8051,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8112,7 +8090,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8150,7 +8128,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8182,7 +8160,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8214,7 +8192,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8246,7 +8224,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8288,7 +8266,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8330,7 +8308,7 @@ Satisfies: SRG-OS-000062-GPOS-00031, SRG-OS-000037-GPOS-00015, SRG-OS-000042-GPO The audit daemon must be restarted for the changes to take effect. - + @@ -8356,7 +8334,7 @@ $ sudo chmod 0640 /etc/audit/rules.d/[customrulesfile].rules $ sudo chmod 0640 /etc/audit/auditd.conf - + @@ -8386,7 +8364,7 @@ $ sudo chmod 0755 [audit_tool] Replace "[audit_tool]" with the audit tool that does not have the correct permissive mode. - + @@ -8418,7 +8396,7 @@ $ sudo chown root [audit_tool] Replace "[audit_tool]" with each audit tool not owned by "root". - + @@ -8450,7 +8428,7 @@ $ sudo chgrp root [audit_tool] Replace "[audit_tool]" with each audit tool not group-owned by "root". - + @@ -8485,7 +8463,7 @@ Note that a port number was given as there is no standard port for RELP.</Vul $ sudo yum install rsyslog - + @@ -8520,7 +8498,7 @@ Note that a port number was given as there is no standard port for RELP.</Vul $ sudo yum install rsyslog-gnutls - + @@ -8552,7 +8530,7 @@ overflow_action = syslog The audit daemon must be restarted for changes to take effect. - + @@ -8588,7 +8566,7 @@ Satisfies: SRG-OS-000342-GPOS-00133, SRG-OS-000479-GPOS-00224</VulnDiscussion $ActionSendStreamDriverAuthMode x509/name - + @@ -8614,7 +8592,7 @@ space_left = 25% Note: Option names and values in the auditd.conf file are case insensitive. - + @@ -8644,7 +8622,7 @@ Note that USNO offers authenticated NTP service to DOD and U.S. Government agenc port 0 - + @@ -8674,7 +8652,7 @@ Note that USNO offers authenticated NTP service to DOD and U.S. Government agenc cmdport 0 - + @@ -8708,7 +8686,7 @@ If a privileged user were to log on using this service, the privileged user pass $ sudo yum remove telnet-server - + @@ -8738,7 +8716,7 @@ Verify the operating system is configured to disable non-essential capabilities. $ sudo yum remove abrt* - + @@ -8768,7 +8746,7 @@ Verify the operating system is configured to disable non-essential capabilities. $ sudo yum remove sendmail - + @@ -8801,7 +8779,7 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + @@ -8834,7 +8812,7 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + @@ -8867,7 +8845,7 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + @@ -8900,7 +8878,7 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + @@ -8933,7 +8911,7 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + @@ -8964,16 +8942,16 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + SRG-OS-000114-GPOS-00059 <GroupDescription></GroupDescription> - + RHEL-08-040070 - The RHEL 8 file system automounter must be disabled unless required. + The RHEL 8 file system automounter must be disabled. <VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> DPMS Target Red Hat Enterprise Linux 8 @@ -8984,17 +8962,15 @@ Reboot the system for the settings to take effect. CCI-000778 - Configure the operating system to disable the ability to automount devices. + Configure RHEL 8 to disable the ability to automount devices. Turn off the automount service with the following commands: $ sudo systemctl stop autofs -$ sudo systemctl disable autofs - -If "autofs" is required for Network File System (NFS), it must be documented with the ISSO. - +$ sudo systemctl disable autofs + - + @@ -9025,7 +9001,7 @@ Add or update the following lines in the file "/etc/modprobe.d/blacklist.conf": Reboot the system for the settings to take effect. - + @@ -9055,7 +9031,7 @@ RHEL 8 functionality (e.g., RDP) must be capable of taking enforcement action if $ sudo yum install firewalld.noarch - + @@ -9095,7 +9071,7 @@ Add or update the line: Reboot the system for the settings to take effect. - + @@ -9125,7 +9101,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" tmpfs /dev/shm tmpfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9153,7 +9129,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" tmpfs /dev/shm tmpfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9183,7 +9159,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" tmpfs /dev/shm tmpfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9213,7 +9189,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-tmp /tmp xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9241,7 +9217,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-tmp /tmp xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9271,7 +9247,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-tmp /tmp xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9301,7 +9277,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-log /var/log xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9331,7 +9307,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-log /var/log xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9361,7 +9337,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-log /var/log xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9391,7 +9367,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-log-audit /var/log/audit xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9421,7 +9397,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-log-audit /var/log/audit xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9451,7 +9427,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-log-audit /var/log/audit xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9481,7 +9457,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-tmp /var/tmp xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9511,7 +9487,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-tmp /var/tmp xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9541,7 +9517,7 @@ The "nosuid" mount option causes the system to not execute "setuid" and "setgid" /dev/mapper/rhel-var-tmp /var/tmp xfs defaults,nodev,nosuid,noexec 0 0 - + @@ -9575,7 +9551,7 @@ Satisfies: SRG-OS-000368-GPOS-00154, SRG-OS-000370-GPOS-00155, SRG-OS-000480-GPO $ sudo yum install fapolicyd.x86_64 - + @@ -9605,7 +9581,7 @@ FirewallBackend=nftables Establish rate-limiting rules based on organization-defined types of DoS attacks on impacted network interfaces. - + @@ -9635,7 +9611,7 @@ Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000424-GPOS-00188, SRG-OS-000425-GPO $ sudo systemctl enable sshd.service - + @@ -9671,7 +9647,7 @@ Restart the SSH daemon for the settings to take effect. $ sudo systemctl restart sshd.service - + @@ -9703,7 +9679,7 @@ Reload the daemon for this change to take effect. $ sudo systemctl daemon-reload - + @@ -9737,14 +9713,14 @@ Then update the dconf settings: $ sudo dconf update - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-040172 The systemd Ctrl-Alt-Delete burst key sequence in RHEL 8 must be disabled. <VulnDiscussion>A locally logged-on user who presses Ctrl-Alt-Delete when at the console can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In a graphical user environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -9756,16 +9732,22 @@ $ sudo dconf update 2921 CCI-000366 - Configure the system to disable the CtrlAltDelBurstAction by added or modifying the following line in the "/etc/systemd/system.conf" configuration file: + Configure RHEL 8 to disable the CtrlAltDelBurstAction by adding it to a drop file in a "/etc/systemd/system.conf.d/" configuration file: + +If no drop file exists, create one with the following command: + +$ sudo mkdir -p /etc/systemd/system.conf.d && sudo vi /etc/systemd/system.conf.d/55-CtrlAltDel-BurstAction + +Edit the file to contain the setting by adding the following text: CtrlAltDelBurstAction=none Reload the daemon for this change to take effect. $ sudo systemctl daemon-reload - + - + @@ -9795,7 +9777,7 @@ Reload the daemon to take effect. $ sudo systemctl daemon-reload - + @@ -9819,7 +9801,7 @@ $ sudo systemctl daemon-reload $ sudo yum remove tftp-server - + @@ -9843,7 +9825,7 @@ $ sudo yum remove tftp-server If the account is associated with system commands or applications, the UID should be changed to one greater than "0" but less than "1000". Otherwise, assign a UID of greater than "1000" that has not already been assigned. - + @@ -9890,7 +9872,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -9938,7 +9920,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -9985,7 +9967,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10032,7 +10014,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10079,7 +10061,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10126,7 +10108,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10175,7 +10157,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10224,7 +10206,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10272,7 +10254,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10319,7 +10301,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -10363,19 +10345,19 @@ The system configuration files need to be reloaded for the changes to take effec $ sudo sysctl --system - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-040282 RHEL 8 must restrict usage of ptrace to descendant processes. - <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. +The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographical order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf @@ -10390,24 +10372,20 @@ The sysctl --system command will load settings from all system configuration fil 2921 CCI-000366 - Configure RHEL 8 to restrict usage of ptrace to descendant processes by adding the following line to a file, in the "/etc/sysctl.d" directory: + Configure RHEL 8 to restrict usage of ptrace to descendant processes by adding the following line in a dropfile, in the "/etc/sysctl.d" directory with the following commands: -kernel.yama.ptrace_scope = 1 +Create the dropfile if it doesn't already exist: +$ sudo vi /etc/sysctl.d/99-ptrace-restrict.conf -Remove any configurations that conflict with the above from the following locations: -/run/sysctl.d/*.conf -/usr/local/lib/sysctl.d/*.conf -/usr/lib/sysctl.d/*.conf -/lib/sysctl.d/*.conf -/etc/sysctl.conf -/etc/sysctl.d/*.conf +Add the following line to the file: +kernel.yama.ptrace_scope = 1 The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: $ sudo sysctl --system - + - + @@ -10451,7 +10429,7 @@ The system configuration files need to be reloaded for the changes to take effec $ sudo sysctl --system - + @@ -10495,19 +10473,19 @@ The system configuration files need to be reloaded for the changes to take effec $ sudo sysctl --system - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-040285 RHEL 8 must use reverse path filtering on all IPv4 interfaces. - <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. + <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore, may remain unsecured. They increase the risk to the platform by providing additional attack vectors. -The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographic order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. +The sysctl --system command will load settings from all system configuration files. All configuration files are sorted by their filename in lexicographical order, regardless of which of the directories they reside in. If multiple files specify the same option, the entry in the file with the lexicographically latest name will take precedence. Files are read from directories in the following list from top to bottom. Once a file of a given filename is loaded, any file of the same name in subsequent directories is ignored. /etc/sysctl.d/*.conf /run/sysctl.d/*.conf /usr/local/lib/sysctl.d/*.conf @@ -10522,24 +10500,22 @@ The sysctl --system command will load settings from all system configuration fil 2921 CCI-000366 - Configure RHEL 8 to use reverse path filtering on all IPv4 interfaces by adding the following line to a file, in the "/etc/sysctl.d" directory: + Configure RHEL 8 to use reverse path filtering on IPv4 interfaces by default. -net.ipv4.conf.all.rp_filter = 1 +Add or edit the following line in a single system configuration file in the "/etc/sysctl.d/" directory: -Remove any configurations that conflict with the above from the following locations: -/run/sysctl.d/*.conf -/usr/local/lib/sysctl.d/*.conf -/usr/lib/sysctl.d/*.conf -/lib/sysctl.d/*.conf -/etc/sysctl.conf -/etc/sysctl.d/*.conf +Create a configuration file if it does not already exist: -The system configuration files need to be reloaded for the changes to take effect. To reload the contents of the files, run the following command: +$ sudo vi /etc/sysctl.d/ipv4_rp_filter.conf + +net.ipv4.conf.default.rp_filter = 1 + +Load settings from all system configuration files with the following command: $ sudo sysctl --system - + - + @@ -10564,7 +10540,7 @@ $ sudo sysctl --system $ sudo postconf -e 'smtpd_client_restrictions = permit_mynetworks,reject' - + @@ -10592,7 +10568,7 @@ $ sudo yum remove xorg-x11-server-Xorg xorg-x11-server-common xorg-x11-server-ut A reboot is required for the changes to take effect. - + @@ -10620,7 +10596,7 @@ Set the promiscuous mode of an interface to off with the following command: $ sudo ip link set dev <devicename> multicast off promisc off - + @@ -10634,7 +10610,7 @@ $ sudo ip link set dev <devicename> multicast off promisc off +If X11 services are not required for the system's intended function, they should be disabled or restricted as appropriate to the system's needs.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> DPMS Target Red Hat Enterprise Linux 8 DISA @@ -10652,7 +10628,7 @@ The SSH service must be restarted for changes to take effect: $ sudo systemctl restart sshd - + @@ -10678,7 +10654,7 @@ Edit the "/etc/ssh/sshd_config" file to uncomment or add the line for the "X11Us X11UseLocalhost yes - + @@ -10710,7 +10686,7 @@ $ sudo systemctl daemon-reload $ sudo systemctl restart tftp.service - + @@ -10734,14 +10710,14 @@ $ sudo systemctl restart tftp.service $ sudo yum remove vsftpd - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-040370 The gssproxy package must not be installed unless mission essential on RHEL 8. <VulnDiscussion>It is detrimental for operating systems to provide, or install by default, functionality exceeding requirements or mission objectives. These unnecessary capabilities or services are often overlooked and therefore may remain unsecured. They increase the risk to the platform by providing additional attack vectors. @@ -10756,13 +10732,14 @@ The gssproxy package is a proxy for GSS API credential handling and could expose Red Hat Enterprise Linux 8 2921 + CCI-000381 Document the gssproxy package with the ISSO as an operational requirement or remove it from the system with the following command: $ sudo yum remove gssproxy - + @@ -10790,7 +10767,7 @@ The iprutils package provides a suite of utilities to manage and configure SCSI $ sudo yum remove iprutils - + @@ -10818,7 +10795,7 @@ The tuned package contains a daemon that tunes the system settings dynamically. $ sudo yum remove tuned - + @@ -10849,7 +10826,7 @@ FIPS 140-2 is the current standard for validating that mechanisms used to access $ sudo yum remove krb5-server - + @@ -10873,7 +10850,7 @@ ALL ALL=(ALL) ALL ALL ALL=(ALL:ALL) ALL - + @@ -10903,7 +10880,7 @@ Remove any configurations that conflict with the above from the following locati /etc/sudoers.d/ - + @@ -10938,7 +10915,7 @@ Note: The "[value]" must be a number that is greater than or equal to "0". Remove any duplicate or conflicting lines from /etc/sudoers and /etc/sudoers.d/ files. - + @@ -10981,14 +10958,14 @@ Run the following command to update the database: $ sudo dconf update - + SRG-OS-000080-GPOS-00048 <GroupDescription></GroupDescription> - + RHEL-08-010152 RHEL 8 operating systems must require authentication upon booting into emergency mode. <VulnDiscussion>If the system does not require valid root authentication before it boots into emergency or rescue mode, anyone who invokes emergency or rescue mode is granted privileged access to all files on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -11005,7 +10982,7 @@ $ sudo dconf update ExecStart=-/usr/lib/systemd/systemd-sulogin-shell emergency - + @@ -11035,7 +11012,7 @@ Edit/modify the following line in the "/etc/pam.d/system-auth" file to include t password sufficient pam_unix.so sha512 - + @@ -11073,7 +11050,7 @@ For the changes to take effect, the SSH daemon must be restarted. $ sudo systemctl restart sshd.service - + @@ -11099,7 +11076,7 @@ The rngd service feeds random data from hardware device to kernel random device. $ sudo yum install rng-tools - + @@ -11129,7 +11106,7 @@ The SSH daemon must be restarted for the changes to take effect. To restart the $ sudo systemctl restart sshd.service - + @@ -11151,14 +11128,14 @@ $ sudo systemctl restart sshd.service Migrate the "/var/tmp" path onto a separate file system. - + SRG-OS-000480-GPOS-00227 <GroupDescription></GroupDescription> - + RHEL-08-010572 RHEL 8 must prevent files with the setuid and setgid bit set from being executed on the /boot/efi directory. <VulnDiscussion>The "nosuid" mount option causes the system not to execute "setuid" and "setgid" files with owner privileges. This option must be used for mounting any file system not containing approved "setuid" and "setguid" files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> @@ -11174,7 +11151,7 @@ $ sudo systemctl restart sshd.service Configure the "/etc/fstab" to use the "nosuid" option on the /boot/efi directory. - + @@ -11208,7 +11185,7 @@ Update the system databases: $ sudo dconf update - + @@ -11253,7 +11230,7 @@ Run the following command to update the database: $ sudo dconf update - + @@ -11277,7 +11254,7 @@ $ sudo dconf update Note: Manual changes to the listed file may be overwritten by the "authselect" program. - + @@ -11309,7 +11286,7 @@ $ sudo systemctl enable auditd.service $ sudo systemctl start auditd.service - + @@ -11335,7 +11312,7 @@ space_left_action = email Note: Option names and values in the auditd.conf file are case insensitive. - + @@ -11364,7 +11341,7 @@ RHEL 8 functionality (e.g., RDP) must be capable of taking enforcement action if $ sudo systemctl enable firewalld - + @@ -11398,7 +11375,7 @@ Satisfies: SRG-OS-000368-GPOS-00154, SRG-OS-000370-GPOS-00155, SRG-OS-000480-GPO $ sudo systemctl enable --now fapolicyd - + @@ -11426,7 +11403,7 @@ The System Administrator (SA) must work with the site Information System Securit $ sudo yum install usbguard.x86_64 - + @@ -11460,7 +11437,7 @@ $ sudo systemctl start usbguard.service Note: Enabling and starting usbguard without properly configuring it for an individual system will immediately prevent any access over a usb device such as a keyboard or mouse - + @@ -11490,7 +11467,7 @@ Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000424-GPOS-00188, SRG-OS-000425-GPO $ sudo yum install openssh-server.x86_64 - + @@ -11536,7 +11513,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -11582,7 +11559,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -11628,7 +11605,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -11674,7 +11651,7 @@ Load settings from all system configuration files with the following command: $ sudo sysctl --system - + @@ -11720,7 +11697,7 @@ The system configuration files need to be reloaded for the changes to take effec $ sudo sysctl --system - + @@ -11747,7 +11724,7 @@ Lock an account: $ sudo passwd -l [username] - + @@ -11773,7 +11750,7 @@ This requirement applies to RHEL 8 with software libraries that are accessible a $ sudo chmod 755 [DIRECTORY] - + @@ -11801,7 +11778,7 @@ Run the following command, replacing "[DIRECTORY]" with any library directory no $ sudo chown root [DIRECTORY] - + @@ -11829,7 +11806,7 @@ Run the following command, replacing "[DIRECTORY]" with any library directory no $ sudo chgrp root [DIRECTORY] - + @@ -11861,7 +11838,7 @@ $ sudo vi /etc/pam.d/sudo Remove any occurrences of "pam_succeed_if" in the file. - + @@ -11891,7 +11868,7 @@ Add the following line to the "/etc/pam.d/system-auth" file (or modify the line password requisite pam_pwquality.so - + @@ -11919,7 +11896,7 @@ $ sudo systemctl set-default multi-user.target A reboot is required for the changes to take effect. - + @@ -11948,18 +11925,134 @@ The "logind" service must be restarted for the changes to take effect. To restar $ sudo systemctl restart systemd-logind - + + + + + + SRG-OS-000163-GPOS-00072 + <GroupDescription></GroupDescription> + + RHEL-08-020360 + RHEL 8 must automatically exit interactive command shell user sessions after 10 minutes of inactivity. + <VulnDiscussion>Terminating an idle interactive command shell user session within a short time period reduces the window of opportunity for unauthorized personnel to take control of it when left unattended in a virtual terminal or physical console. + +Satisfies: SRG-OS-000163-GPOS-00072, SRG-OS-000029-GPOS-00010</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> + + DPMS Target Red Hat Enterprise Linux 8 + DISA + DPMS Target + Red Hat Enterprise Linux 8 + 2921 + + CCI-001133 + Configure RHEL 8 to exit interactive command shell user sessions after 10 minutes of inactivity. + +Add or edit the following line in "/etc/profile.d/tmout.sh": + +#!/bin/bash + +declare -xr TMOUT=600 + + + + + + + + SRG-OS-000033-GPOS-00014 + <GroupDescription></GroupDescription> + + RHEL-08-010280 + RHEL 8 IP tunnels must use FIPS 140-3-approved cryptographic algorithms. + <VulnDiscussion>Overriding the system crypto policy makes the behavior of the Libreswan service violate expectations and makes system configuration more fragmented.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> + + DPMS Target Red Hat Enterprise Linux 8 + DISA + DPMS Target + Red Hat Enterprise Linux 8 + 2921 + + + CCI-000068 + Configure Libreswan to use the system cryptographic policy. + +Add the following line to "/etc/ipsec.conf": + +include /etc/crypto-policies/back-ends/libreswan.config + + + + + + + + SRG-OS-000423-GPOS-00187 + <GroupDescription></GroupDescription> + + RHEL-08-010275 + RHEL 8 must implement DOD-approved encryption in the bind package. + <VulnDiscussion>Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + +Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + +RHEL 8 incorporates systemwide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/ directory. + +Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000426-GPOS-00190</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> + + DPMS Target Red Hat Enterprise Linux 8 + DISA + DPMS Target + Red Hat Enterprise Linux 8 + 2921 + + + CCI-002418 + Configure BIND to use the system crypto policy. + +Add the following line to the "options" section in "/etc/named.conf": + +include "/etc/crypto-policies/back-ends/bind.config"; + + + + + + + + SRG-OS-000396-GPOS-00176 + <GroupDescription></GroupDescription> + + RHEL-08-010015 + RHEL 8 must have the crypto-policies package installed. + <VulnDiscussion>Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. + +Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls> + + DPMS Target Red Hat Enterprise Linux 8 + DISA + DPMS Target + Red Hat Enterprise Linux 8 + 2921 + + CCI-002450 + Install the crypto-policies package (if the package is not already installed) with the following command: + +$ sudo dnf -y install crypto-policies + + + - + - Security Content Tool 1.6.0 + Security Content Tool 1.7.0 5.11 - 2025-09-25T11:54:30 + 2026-01-05T02:27:46 @@ -12172,23 +12265,6 @@ $ sudo systemctl restart systemd-logind - - - The operating system operating system must implement DoD-approved TLS encryption in the OpenSSL package. - - - - - - - - - - - - - - The operating system system commands must have mode 755 or less permissive. @@ -12396,9 +12472,9 @@ $ sudo systemctl restart systemd-logind - + - The operating system SSH daemon must not allow authentication using known host’s authentication. + The operating system SSH daemon must not allow authentication using known host's authentication. @@ -12512,14 +12588,13 @@ $ sudo systemctl restart systemd-logind - + The operating system must disable the kernel.core_pattern. - @@ -12929,16 +13004,6 @@ $ sudo systemctl restart systemd-logind - - - The operating system must display the date and time of the last successful account logon upon logon. - - - - - - - The operating system must display the date and time of the last successful account logon upon an SSH logon. @@ -14088,14 +14153,13 @@ $ sudo systemctl restart systemd-logind - + - The operating system must restrict usage of ptrace to descendant processes. + The operating system must restrict usage of ptrace to descendant processes. - + - @@ -14118,16 +14182,6 @@ $ sudo systemctl restart systemd-logind - - - The operating system must use reverse path filtering on all IPv4 interfaces. - - - - - - - The operating system must be configured to prevent unrestricted mail relaying. @@ -14182,16 +14236,6 @@ $ sudo systemctl restart systemd-logind - - - The gssproxy package must not be installed unless mission essential on the operating system. - - - - - - - The iprutils package must not be installed unless mission essential on the operating system. @@ -14633,6 +14677,15 @@ $ sudo systemctl restart systemd-logind + + + The gssproxy package must not be installed unless mission essential on the operating system. + + + + + + The operating system must mount /tmp with the noexec option. @@ -14725,6 +14778,15 @@ $ sudo systemctl restart systemd-logind + + + The operating system must automatically exit interactive command shell user sessions after 15 minutes of inactivity. + + + + + + The operating system must require users to reauthenticate for privilege escalation. @@ -14786,6 +14848,37 @@ $ sudo systemctl restart systemd-logind + + + The operating system IP tunnels must use FIPS 140-2/140-3 approved cryptographic algorithms. + + + + + + + + + + + + + The operating system must have the crypto-policies package installed. + + + + + + + + + The operating system must implement DOD-approved encryption in the bind package. + + + + + + The operating system library directories must have mode 0755 or less permissive. @@ -14808,6 +14901,15 @@ $ sudo systemctl restart systemd-logind + + + The operating system must use reverse path filtering on all IPv4 interfaces. + + + + + + The autofs package is installed. @@ -14844,6 +14946,24 @@ $ sudo systemctl restart systemd-logind + + + The libreswan package is installed. + + + + + + + + + The system has BIND installed. + + + + + + The system is RHEL 8.1 or lower @@ -15304,26 +15424,6 @@ The SSH implementation in RHEL8 uses the OPENSSL library, which does not use hig - - - RHEL-08-010294 - The RHEL 8 operating system must implement DoD-approved TLS encryption in the OpenSSL package. - - Red Hat Enterprise Linux 8 - - Without cryptographic integrity protections, information can be altered by unauthorized users without detection. - -Remote access (e.g., RDP) is access to DoD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. - -Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. - -RHEL 8 incorporates system-wide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/openssl.config file. - -Satisfies: SRG-OS-000250-GPOS-00093, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174, SRG-OS-000125-GPOS-00065 - - - - - RHEL-08-010300 - RHEL 8 system commands must have mode 755 or less permissive. @@ -15726,9 +15826,9 @@ This requirement applies to operating systems performing security function verif - + - RHEL-08-010520 - The RHEL 8 SSH daemon must not allow authentication using known host’s authentication. + RHEL-08-010520 - The RHEL 8 SSH daemon must not allow authentication using known host's authentication. Red Hat Enterprise Linux 8 @@ -16654,18 +16754,6 @@ Configuration settings are the set of parameters that can be changed in hardware - - - RHEL-08-020340 - RHEL 8 must display the date and time of the last successful account logon upon logon. - - Red Hat Enterprise Linux 8 - - Providing users with feedback on when account accesses last occurred facilitates user recognition and reporting of unauthorized account use. - - - - - RHEL-08-020350 - RHEL 8 must display the date and time of the last successful account logon upon an SSH logon. @@ -18821,9 +18909,9 @@ The sysctl --system command will load settings from all system configuration fil - + - RHEL-08-040282 - RHEL 8 must restrict usage of ptrace to descendant processes. + RHEL-08-040282 - RHEL 8 must restrict usage of ptrace to descendant processes. Red Hat Enterprise Linux 8 @@ -18881,7 +18969,7 @@ The sysctl --system command will load settings from all system configuration fil - + RHEL-08-040285 - RHEL 8 must use reverse path filtering on all IPv4 interfaces. @@ -18898,7 +18986,7 @@ The sysctl --system command will load settings from all system configuration fil /etc/sysctl.conf - + @@ -18939,7 +19027,7 @@ If the system is being used to perform a network troubleshooting function, the u - + RHEL-08-040340 - RHEL 8 remote X connections for interactive users must be disabled unless to fulfill documented and validated mission requirements. @@ -18949,7 +19037,7 @@ If the system is being used to perform a network troubleshooting function, the u X11 forwarding should be enabled with caution. Users with the ability to bypass file permissions on the remote host (for the user's X11 authorization database) can access the local X11 display through the forwarded connection. An attacker may then be able to perform activities such as keystroke monitoring if the ForwardX11Trusted option is also enabled. -If X11 services are not required for the system's intended function, they should be disabled or restricted as appropriate to the system’s needs. +If X11 services are not required for the system's intended function, they should be disabled or restricted as appropriate to the system's needs. @@ -18991,7 +19079,7 @@ If X11 services are not required for the system's intended function, they should - + RHEL-08-040370 - The gssproxy package must not be installed unless mission essential on RHEL 8. @@ -19004,7 +19092,7 @@ Operating systems are capable of providing a wide variety of functions and servi The gssproxy package is a proxy for GSS API credential handling and could expose secrets on some networks. It is not needed for normal function of the OS. - + @@ -19587,6 +19675,64 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + + RHEL-08-020360 - RHEL 8 must automatically exit interactive command shell user sessions after 10 minutes of inactivity. + + Red Hat Enterprise Linux 8 + + Terminating an idle interactive command shell user session within a short time period reduces the window of opportunity for unauthorized personnel to take control of it when left unattended in a virtual terminal or physical console. + + Satisfies: SRG-OS-000163-GPOS-00072, SRG-OS-000029-GPOS-00010 + + + + + + + + RHEL-08-010280 - RHEL 8 IP tunnels must use FIPS 140-3-approved cryptographic algorithms. + + Red Hat Enterprise Linux 8 + + Overriding the system crypto policy makes the behavior of the Libreswan service violate expectations and makes system configuration more fragmented. + + + + + + + + RHEL-08-010275 - RHEL 8 must implement DOD-approved encryption in the bind package. + + Red Hat Enterprise Linux 8 + + Without cryptographic integrity protections, information can be altered by unauthorized users without detection. + + Cryptographic mechanisms used for protecting the integrity of information include, for example, signed hash functions using asymmetric cryptography enabling distribution of the public key to verify the hash information while maintaining the confidentiality of the secret key used to generate the hash. + + RHEL 8 incorporates systemwide crypto policies by default. The employed algorithms can be viewed in the /etc/crypto-policies/back-ends/ directory. + + Satisfies: SRG-OS-000423-GPOS-00187, SRG-OS-000426-GPOS-00190 + + + + + + + + RHEL-08-010015 - RHEL 8 must have the crypto-policies package installed. + + Red Hat Enterprise Linux 8 + + Centralized cryptographic policies simplify applying secure ciphers across an operating system and the applications that run on that operating system. Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. + + Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000393-GPOS-00173, SRG-OS-000394-GPOS-00174 + + + + + @@ -19683,18 +19829,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - - - - - - - - - @@ -19776,7 +19910,7 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - + @@ -19788,10 +19922,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - @@ -19994,12 +20124,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - - - @@ -20509,10 +20633,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - @@ -20522,11 +20642,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - - @@ -20778,6 +20893,10 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + + + @@ -20806,6 +20925,22 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + + + + + + + + + + + + + + + @@ -20860,10 +20995,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - @@ -20887,7 +21018,7 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - + @@ -21067,6 +21198,15 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + + + + + + + + @@ -21297,11 +21437,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - - - - - @@ -21373,6 +21508,10 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + + + @@ -21596,21 +21735,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s ^[ \t]*SSH_USE_STRONG_RNG[ \t]*=[ \t]*32[ \t]*$ 1 - - /etc/crypto-policies/back-ends/opensslcnf.config - ^\s*MinProtocol\s*=\s*([\.\w]+)\s*(?:#.*)?$ - 1 - - - /etc/crypto-policies/back-ends/opensslcnf.config - ^\s*TLS\.MinProtocol\s*=\s*([\.\w]+)\s*(?:#.*)?$ - 1 - - - /etc/crypto-policies/back-ends/opensslcnf.config - ^\s*DTLS\.MinProtocol\s*=\s*([\.\w]+)\s*(?:#.*)?$ - 1 - /etc/yum.repos.d \.repo$ @@ -21823,9 +21947,9 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s ^\s*[^#\s]+\s+/boot\s+\S+\s+(\S+)\s+\S+\s+\S+\s*$ 1 - + /etc/fstab - ^\s*/dev\S*\s+/\S+\s+\S+\s+(\S+)\s+\S+\s+\S+\s*$ + ^\s*/dev\S*\s+/\S+\s+(?!vfat\s+)\S+\s+(\S+)\s+\S+\s+\S+\s*$ 1 @@ -21838,23 +21962,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s ^\s*\[?[\.\w:-]+\]?:[/\w-]+\s+[/\w-]+\s+nfs[4]?\s+(.*)$ 0 - - /etc/sysctl.conf - ^\s*kernel\.core_pattern\s*=\s*(.+)\s*$ - 1 - - - - ^.*\.conf$ - ^\s*kernel\.core_pattern\s*=\s*(.+)\s*$ - 1 - - - - oval:mil.disa.stig.ind:obj:23031100 - oval:mil.disa.stig.ind:obj:23031101 - - oval:mil.disa.stig.ind:obj:23031302 @@ -22323,16 +22430,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s ^(?i)\s*PermitEmptyPasswords\s+(\w+)$ 1 - - /etc/pam.d/postlogin - ^\s*session\s+.+\s+pam_lastlog\.so\s+(?:\w+\s+)*showfailed\b\s*(?:\w+\b\s*)*\s*(?:#.*)?$ - 1 - - - /etc/pam.d/postlogin - ^\s*session\s+.+\s+pam_lastlog\.so\s+(?:\w+\s+)*silent\b\s*(?:\w+\b\s*)*\s*(?:#.*)?$ - 1 - /etc/ssh/sshd_config ^\s*(?i)PrintLastLog(?-i)[ \t]+([\w\"]+)[\s]*(?:|(?:#.*))?$ @@ -23225,23 +23322,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s (?:^|\.*\n)\s*kernel\.unprivileged_bpf_disabled\s*=\s*(\d+)\s*$ 1 - - /etc/sysctl.conf - ^\s*kernel\.yama\.ptrace_scope\s*=\s*(\d+)\s*$ - 1 - - - - \.conf$ - (?:^|\.*\n)\s*kernel\.yama\.ptrace_scope\s*=\s*(\d+)\s*$ - 1 - - - - oval:mil.disa.stig.ind:obj:23054601 - oval:mil.disa.stig.ind:obj:23054602 - - \.conf$ @@ -23276,23 +23356,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s oval:mil.disa.stig.ind:obj:23054802 - - - oval:mil.disa.stig.ind:obj:23054901 - oval:mil.disa.stig.ind:obj:23054902 - - - - - ^.*\.conf$ - ^\s*net\.ipv4\.conf\.all\.rp_filter\s*=\s*(\d+)\s*$ - 1 - - - /etc/sysctl.conf - ^\s*net\.ipv4\.conf\.all\.rp_filter\s*=\s*(\d+)\s*$ - 1 - /etc/postfix/main.cf ^smtpd_client_restrictions[ \t]*=[ \t]*permit_mynetworks[, \t]+reject[ \t]*$ @@ -23781,6 +23844,24 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s oval:mil.disa.stig.defs:var:25804500 + + + oval:mil.disa.stig.ind:obj:25806801 + oval:mil.disa.stig.ind:obj:25806802 + + + + /etc/profile + ^[^#]*\s*TMOUT=(\d+)\s*$ + 1 + + + + /etc/profile.d + ^.+\.sh$ + ^[^#]*\s*TMOUT=(\d+)\s*$ + 1 + /etc/sudoers @@ -23831,6 +23912,22 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s ^\$ActionSendStreamDriverAuthMode\s+(\S+)\s*$ 1 + + /etc/ipsec.conf + ^\s*include\s+(.*)\s*$ + 1 + + + /etc/ipsec.d + ^.*\.conf$ + ^\s*include\s+(.*)\s*$ + 1 + + + /etc/named.conf + ^\s*include\s+"(.*)"\s*;\s*$ + 1 + oval:mil.disa.stig.ind:obj:27172001 @@ -23873,9 +23970,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s policycoreutils - - crypto-policies - openssl-pkcs11 @@ -23894,8 +23988,9 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s /boot - + ^/\S+$ + oval:mil.disa.stig.linux:ste:23030103 oval:mil.disa.stig.linux:ste:23030102 @@ -24040,6 +24135,15 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s auditd.service SubState + + crypto-policies + + + bind + + + libreswan + /sys/firmware/efi @@ -24110,17 +24214,17 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s oval:mil.disa.stig.unix:ste:23025800 - - + + - \.so(\.\d+)*$ + \.so(\S+)*$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:20000005 - + - \.so(\.\d+)*$ + (\.so\S*)$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:20000006 @@ -24337,38 +24441,38 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s .* oval:mil.disa.stig.unix:ste:25804500 - + - \.so + \.so\S*$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:26048700 - + - \.so + \.so\S*$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:26048701 - + - \.so + \.so\S*$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:26048702 - + - \.so + \.so\S*$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:26048703 - + - \.so + \.so\S*$ oval:mil.disa.stig.unix:ste:20000015 oval:mil.disa.stig.unix:ste:26048704 @@ -24431,6 +24535,9 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s 0 + + 600 + (?i)(?:^|\n)[^#]*\btype\s*=\s*"omfwd" @@ -24458,12 +24565,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s enforcing - - TLSv1\.[2|3] - - - DTLSv1\.[2|3] - \n\s*gpgcheck\s*=\s*(True|1|yes)\s*(\n|$) @@ -24482,9 +24583,6 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s ^.*noexec.*$ - - |/bin/false - 0 @@ -24665,6 +24763,15 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s (?i)(?:^|\n)[^#]*\bStreamDriver\.?AuthMode\b + + /etc/crypto-policies/back-ends/libreswan.config + + + /etc/ipsec.d/*.conf + + + /etc/crypto-policies/back-ends/bind.config + 8\.[0-1]$ @@ -24717,12 +24824,12 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s selinuxfs - - 20210617 - ^/dev\S*$ + + vfat + nosuid @@ -25200,15 +25307,15 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s - + - Security Content Tool 1.6.0 + Security Content Tool 1.7.0 5.11 - 2025-09-25T11:54:34 + 2026-01-05T02:27:51 - + RHEL 8 is installed @@ -25219,6 +25326,8 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + @@ -25227,8 +25336,20 @@ RHEL 8 uses "pwquality" as a mechanism to enforce password complexity. This is s + + + + + + + + toss-release + + + oraclelinux-release + redhat-release diff --git a/shared/references/disa-stig-rhel9-v2r6-xccdf-manual.xml b/shared/references/disa-stig-rhel9-v2r8-xccdf-manual.xml similarity index 82% rename from shared/references/disa-stig-rhel9-v2r6-xccdf-manual.xml rename to shared/references/disa-stig-rhel9-v2r8-xccdf-manual.xml index 8381fa5bfa40..39ccc3b6eec1 100644 --- a/shared/references/disa-stig-rhel9-v2r6-xccdf-manual.xml +++ b/shared/references/disa-stig-rhel9-v2r8-xccdf-manual.xml @@ -1,10 +1,13 @@ -acceptedRed Hat Enterprise Linux 9 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 6 Benchmark Date: 01 Oct 20253.5.11.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010000The SUSE operating system must be a vendor-supported release.<VulnDiscussion>A SUSE operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77045SV-91741CCI-001230Upgrade the SUSE operating system to a version supported by the vendor. If the system is not registered with the SUSE Customer Center, register the system against the correct subscription. +deprecatedSUSE Linux Enterprise Server 12 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 5 Benchmark Date: 01 Apr 20263.5.21.10.03I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010000The SUSE operating system must be a vendor-supported release.<VulnDiscussion>A SUSE operating system release is considered supported if the vendor continues to provide security patches for the product. With an unsupported release, it is not possible to resolve security issues discovered in the system software. -If the system requires Long-Term Service Pack Support (LTSS), obtain the correct LTSS subscription for the system.Verify the SUSE operating system is a vendor-supported release. +Release Released General Support Long Term Support +12.1 15 Dec 2015 31 May 2017 31 May 2020 +12.2 08 Nov 2016 31 Mar 2018 31 Mar 2021 +12.3 07 Sep 2017 30 Jun 2019 30 Jun 2022 +12.4 12 Dec 2018 30 Jun 2020 30 Jun 2023 +12.5 09 Dec 2019 31 Oct 2024 31 Oct 2027</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77045SV-91741CCI-001230Upgrade the SUSE operating system to a version supported by the vendor. If the system is not registered with the SUSE Customer Center, register the system against the correct subscription. + +If the system requires Long-Term Service Pack Support (LTSS), obtain the correct LTSS subscription for the system.Verify the SUSE operating system is a vendor-supported release. Use the following command to verify the SUSE operating system is a vendor-supported release: @@ -10,10 +17,9 @@ NAME="SLES" VERSION="12" -Current End of Life for SLES 12 General Support is 31 Oct 2024 and Long-term Support is until 31 Oct 2027. +Current End of Life for SLES 12 General Support was 31 Oct 2024 and Long-term Support ends 31 Oct 2027. -If the release is not supported by the vendor, this is a finding. -SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010010Vendor-packaged SUSE operating system security patches and updates must be installed and up to date.<VulnDiscussion>Timely patching is critical for maintaining the operational availability, confidentiality, and integrity of information technology (IT) systems. However, failure to keep SUSE operating system and application software patched is a common mistake made by IT professionals. New patches are released frequently, and it is often difficult for even experienced System Administrators (SAs) to keep abreast of all the new patches. When new weaknesses in a SUSE operating system exist, patches are usually made available by the vendor to resolve the problems. If the most recent security patches and updates are not installed, unauthorized users may take advantage of weaknesses in the unpatched software. The lack of prompt attention to patching could result in a system compromise.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77047SV-91743CCI-001227Install the applicable SUSE operating system patches available from SUSE by running the following command: +If the release is not supported by the vendor, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010010Vendor-packaged SUSE operating system security patches and updates must be installed and up to date.<VulnDiscussion>Timely patching is critical for maintaining the operational availability, confidentiality, and integrity of information technology (IT) systems. However, failure to keep SUSE operating system and application software patched is a common mistake made by IT professionals. New patches are released frequently, and it is often difficult for even experienced System Administrators (SAs) to keep abreast of all the new patches. When new weaknesses in a SUSE operating system exist, patches are usually made available by the vendor to resolve the problems. If the most recent security patches and updates are not installed, unauthorized users may take advantage of weaknesses in the unpatched software. The lack of prompt attention to patching could result in a system compromise.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77047SV-91743CCI-001227Install the applicable SUSE operating system patches available from SUSE by running the following command: # sudo zypper patchVerify the SUSE operating system security patches and updates are installed and up to date. @@ -556,17 +562,17 @@ Check that the SUSE operating system enforces 24 hours/one day as the minimum pa PASS_MIN_DAYS 1 -If no output is produced, or if "PASS_MIN_DAYS" does not have a value of "1" or greater, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>SLES-12-010270The SUSE operating system must employ user passwords with a minimum lifetime of 24 hours (one day).<VulnDiscussion>Enforcing a minimum password lifetime helps prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91809V-77113CCI-000198CCI-004066Configure the SUSE operating system to enforce 24 hours/one day or greater as the minimum password age for user accounts. +If no output is produced, or if "PASS_MIN_DAYS" does not have a value of "1" or greater, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>SLES-12-010270The SUSE operating system must employ user passwords with a minimum lifetime of 24 hours (one day).<VulnDiscussion>Enforcing a minimum password lifetime helps prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91809V-77113CCI-000198CCI-004066Configure the SUSE operating system to enforce 24 hours/one day or greater as the minimum password age for user accounts. Change the minimum time period between password changes for each [USER] account to "1" day with the command, replacing [USER] with the user account that must be changed: -> sudo passwd -n 1 [USER]Verify the SUSE operating system enforces a minimum time period between password changes for each user account of one day or greater. +> sudo passwd -n 1 [USER]Verify the SUSE operating system enforces a minimum time period between password changes for each user account of one day or greater. Check the minimum time period between password changes for each user account with the following command: > sudo awk -F: '$4 < 1 {print $1 ":" $4}' /etc/shadow -smithj:1 +dosuser:1 If any results are returned that are not associated with a system account, this is a finding.SRG-OS-000076-GPOS-00044<GroupDescription></GroupDescription>SLES-12-010280The SUSE operating system must be configured to create or update passwords with a maximum lifetime of 60 days.<VulnDiscussion>Any password, no matter how complex, can eventually be cracked. Therefore, passwords need to be changed periodically. If the SUSE operating system does not limit the lifetime of passwords and force users to change their passwords, there is the risk that the SUSE operating system passwords could be compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91811V-77115CCI-000199CCI-004066Configure the SUSE operating system to enforce a maximum password age of 60 days or less. @@ -674,19 +680,7 @@ DISPLAYMANAGER_PASSWORD_LESS_LOGIN="no" If the "DISPLAYMANAGER_AUTOLOGIN" parameter includes a username or the "DISPLAYMANAGER_PASSWORD_LESS_LOGIN" parameter is not set to "no", this is a -finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010390The SUSE operating system must display the date and time of the last successful account logon upon logon.<VulnDiscussion>Providing users with feedback on when account accesses last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91831V-77135CCI-000052Configure the SUSE operating system to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/login". - -Add the following line to the top of "/etc/pam.d/login": - -session required pam_lastlog.so showfailedVerify the SUSE operating system users are provided with feedback on when account accesses last occurred. - -Check that "pam_lastlog" is used and not silent with the following command: - -> grep pam_lastlog /etc/pam.d/login - -session required pam_lastlog.so showfailed - -If "pam_lastlog" is missing from "/etc/pam.d/login" file, the "silent" option is present, or the returned line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010400There must be no .shosts files on the SUSE operating system.<VulnDiscussion>The .shosts files are used to configure host-based authentication for individual users or the system via SSH. Host-based authentication is not sufficient for preventing unauthorized access to the system, as it does not require interactive identification and authentication of a connection request, or for the use of two-factor authentication.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77137SV-91833CCI-000366Remove any ".shosts" files found on the SUSE operating system. +finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010400There must be no .shosts files on the SUSE operating system.<VulnDiscussion>The .shosts files are used to configure host-based authentication for individual users or the system via SSH. Host-based authentication is not sufficient for preventing unauthorized access to the system, as it does not require interactive identification and authentication of a connection request, or for the use of two-factor authentication.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77137SV-91833CCI-000366Remove any ".shosts" files found on the SUSE operating system. # rm /[path]/[to]/[file]/.shostsVerify there are no ".shosts" files on the SUSE operating system. @@ -702,7 +696,7 @@ Check the system for the existence of these files with the following command: # find /etc -name shosts.equiv -If any "shosts.equiv" files are found on the system, this is a finding.SRG-OS-000478-GPOS-00223<GroupDescription></GroupDescription>SLES-12-010420FIPS 140-2 mode must be enabled on the SUSE operating system.<VulnDiscussion>Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. The SUSE operating system must implement cryptographic modules adhering to the higher standards approved by the federal government since this provides assurance they have been tested and validated. +If any "shosts.equiv" files are found on the system, this is a finding.SRG-OS-000478-GPOS-00223<GroupDescription></GroupDescription>SLES-12-010420FIPS 140-2 mode must be enabled on the SUSE operating system.<VulnDiscussion>Use of weak or untested encryption algorithms undermines the purposes of using encryption to protect data. The SUSE operating system must implement cryptographic modules adhering to the higher standards approved by the federal government since this provides assurance they have been tested and validated. Satisfies: SRG-OS-000396-GPOS-00176, SRG-OS-000478-GPOS-00223</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91837V-77141CCI-002450To configure the SUSE operating system to run in FIPS mode, add "fips=1" to the kernel parameter during the SUSE operating system install. @@ -714,7 +708,7 @@ http://csrc.nist.gov/groups/STM/cmvp/documents/140-1/140sp/140sp2435.pdfSRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-12-010430SUSE operating systems with a basic input/output system (BIOS) must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DoD-approved PKIs, all DoD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. +If nothing is returned, the file does not exist, or the value returned is "0", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-12-010430SUSE operating systems with a basic input/output system (BIOS) must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DoD-approved PKIs, all DoD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. Access control policies include identity-based policies, role-based policies, and attribute-based policies. Access enforcement mechanisms include access control lists, access control matrices, and cryptography. These policies and mechanisms must be employed by the application to control access between users (or processes acting on behalf of users) and objects (e.g., devices, files, records, processes, programs, and domains) in the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77143SV-91839CCI-000213Note: If the system does not use a basic input/output system (BIOS) this requirement is Not Applicable. @@ -747,7 +741,7 @@ Check that the encrypted password is set for a boot user with the following comm password_pbkdf2 boot grub.pbkdf2.sha512.10000.VeryLongString -If the boot user password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-12-010440SUSE operating systems with Unified Extensible Firmware Interface (UEFI) implemented must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system allows a user to boot into single-user or maintenance mode without authentication, any user that invokes single-user or maintenance mode is granted privileged access to all system information. +If the boot user password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-12-010440SUSE operating systems with Unified Extensible Firmware Interface (UEFI) implemented must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system allows a user to boot into single-user or maintenance mode without authentication, any user that invokes single-user or maintenance mode is granted privileged access to all system information. If the system is running in EFI mode, SLES 12 by default will use GRUB 2 EFI as the boot loader.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91841V-77145CCI-000213Note: If the system does not use UEFI, this requirement is Not Applicable. @@ -812,7 +806,7 @@ truecrypt /dev/sda3 /etc/container_password tcrypt Every persistent disk partition present on the system must have an entry in the file. -If any partitions other than pseudo file systems (such as /proc or /sys) are not listed or "/etc/crypttab" does not exist, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-12-010460The sticky bit must be set on all SUSE operating system world-writable directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, and hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If any partitions other than pseudo file systems (such as /proc or /sys) are not listed or "/etc/crypttab" does not exist, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-12-010460The sticky bit must be set on all SUSE operating system world-writable directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, and hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DoD or other government agencies. @@ -939,21 +933,21 @@ Check that AIDE is properly configured to protect the integrity of the audit too If AIDE is configured properly to protect the integrity of the audit tools, all lines listed above will be returned from the command. -If one or more lines are missing, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>SLES-12-010550The SUSE operating system tool zypper must have gpgcheck enabled.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of the SUSE operating system. This requirement ensures the software has not been tampered with and has been provided by a trusted vendor. +If one or more lines are missing, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>SLES-12-010550The SUSE operating system tool zypper must have gpgcheck enabled.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of SLES 12. This requirement ensures the software has not been tampered with and has been provided by a trusted vendor. -Accordingly, patches, service packs, device drivers, or SUSE operating system components must be signed with a certificate recognized and approved by the organization. +Accordingly, patches, service packs, device drivers, or SLES 12 components must be signed with a certificate recognized and approved by the organization. -Verifying the authenticity of the software prior to installation validates the integrity of the patch or upgrade received from a vendor. This ensures the software has not been tampered with and that it has been provided by a trusted vendor. Self-signed certificates are disallowed by this requirement. The SUSE operating system should not have to verify the software again. This requirement does not mandate DoD certificates for this purpose; however, the certificate used to verify the software must be from an approved Certification Authority (CA).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77161SV-91857CCI-001749CCI-003992Configure that the SUSE operating system tool zypper to enable gpgcheck by editing or adding the following line to "/etc/zypp/zypp.conf": +Verifying the authenticity of the software prior to installation validates the integrity of the patch or upgrade received from a vendor. This ensures the software has not been tampered with and that it has been provided by a trusted vendor. Self-signed certificates are disallowed by this requirement. SLES 12 should not have to verify the software again. This requirement does not mandate DOD certificates for this purpose; however, the certificate used to verify the software must be from an approved certification authority (CA). -gpgcheck = 1Verify that the SUSE operating system tool zypper has gpgcheck enabled. +For zypper on SUSE Linux Enterprise systems, GPG signature checking is enabled by default for all repositories, even if it is not explicitly set in /etc/zypp/zypp.conf or individual .repo files. The presence of the gpgcheck setting in repository files (like gpgcheck=1) or a global zypp.conf entry would override this default behavior if you wanted to disable it (e.g., gpgcheck=0), but its absence simply means the default is in effect.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77161SV-91857CCI-001749CCI-003992Configure the SLES 12 zypper tool to enable gpgcheck. -Check that zypper has gpgcheck enabled with the following command: +Add or modify the following line in the "/etc/zypp/zypp.conf" file or remove the line completely ensuring that the default zypper setting is enabled: -> grep -i '^gpgcheck' /etc/zypp/zypp.conf +gpgcheck = onVerify the SLES 12 zypper tool has gpgcheck enabled with the following command: -gpgcheck = 1 + > grep -i '^gpgcheck' /etc/zypp/zypp.conf -If "gpgcheck" is set to "0", "off", "no", or "false", this is a finding.SRG-OS-000437-GPOS-00194<GroupDescription></GroupDescription>SLES-12-010570The SUSE operating system must remove all outdated software components after updated versions have been installed.<VulnDiscussion>Previous versions of software components that are not removed from the information system after updates have been installed may be exploited by adversaries. Some information technology products may remove older versions of software automatically from the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77163SV-91859CCI-002617Configure the SUSE operating system to remove all outdated software components after an update by editing the following line in "/etc/zypp/zypp.conf" to match the one provided below: +If "gpgcheck" is set to "off", this is a finding.SRG-OS-000437-GPOS-00194<GroupDescription></GroupDescription>SLES-12-010570The SUSE operating system must remove all outdated software components after updated versions have been installed.<VulnDiscussion>Previous versions of software components that are not removed from the information system after updates have been installed may be exploited by adversaries. Some information technology products may remove older versions of software automatically from the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77163SV-91859CCI-002617Configure the SUSE operating system to remove all outdated software components after an update by editing the following line in "/etc/zypp/zypp.conf" to match the one provided below: solver.upgradeRemoveDroppedPackages = trueVerify the SUSE operating system removes all outdated software components after updated version have been installed by running the following command: @@ -974,16 +968,14 @@ Check that "usb-storage" is blacklisted in the "/etc/modprobe.d/50-blacklist.con # grep usb-storage /etc/modprobe.d/50-blacklist.conf blacklist usb-storage -If nothing is output from the command, this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>SLES-12-010590The SUSE operating system must disable the file system automounter unless required.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity. +If nothing is output from the command, this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>SLES-12-010590The SUSE operating system must disable the file system automounter.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity. -Satisfies: SRG-OS-000114-GPOS-00059, SRG-OS-000378-GPOS-00163, SRG-OS-000480-GPOS-00227</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77167SV-91863CCI-000366CCI-000778CCI-001958Configure the SUSE operating system to disable the ability to automount devices. +Satisfies: SRG-OS-000114-GPOS-00059, SRG-OS-000378-GPOS-00163, SRG-OS-000480-GPOS-00227</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77167SV-91863CCI-000366CCI-000778CCI-001958Configure the SUSE operating system to disable the ability to automount devices. -Turn off the automount service with the following command: +Turn off the automount service with the following commands: # systemctl stop autofs -# systemctl disable autofs - -If "autofs" is required for Network File System (NFS), it must be documented with the ISSO.Verify the SUSE operating system disables the ability to automount devices. +# systemctl disable autofsVerify the SUSE operating system disables the ability to automount devices. Check to see if automounter service is active with the following command: @@ -992,7 +984,7 @@ autofs.service - Automounts filesystems on demand Loaded: loaded (/usr/lib/systemd/system/autofs.service; disabled) Active: inactive (dead) -If the "autofs" status is set to "active" and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000312-GPOS-00122<GroupDescription></GroupDescription>SLES-12-010600The SUSE operating system Apparmor tool must be configured to control whitelisted applications and user home directory access control.<VulnDiscussion>Using a whitelist provides a configuration management method for allowing the execution of only authorized software. Using only authorized software decreases risk by limiting the number of potential vulnerabilities. +If the "autofs" status is set to "active" this is a finding.SRG-OS-000312-GPOS-00122<GroupDescription></GroupDescription>SLES-12-010600The SUSE operating system Apparmor tool must be configured to control whitelisted applications and user home directory access control.<VulnDiscussion>Using a whitelist provides a configuration management method for allowing the execution of only authorized software. Using only authorized software decreases risk by limiting the number of potential vulnerabilities. The organization must identify authorized software programs and permit execution of authorized software by adding each authorized program to the "pam_apparmor" exception policy. The process used to identify software programs that are authorized to execute on organizational information systems is commonly referred to as whitelisting. @@ -1196,18 +1188,18 @@ Note: The value after -fstype must be replaced with the filesystem type. XFS is # find / -fstype xfs -nogroup -If any files on the system do not have an assigned group, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010710All SUSE operating system local interactive users must have a home directory assigned in the /etc/passwd file.<VulnDiscussion>If local interactive users are not assigned a valid home directory, there is no place for the storage and control of files they should own.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91893V-77197CCI-000366Assign home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. +If any files on the system do not have an assigned group, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010710All SUSE operating system local interactive users must have a home directory assigned in the /etc/passwd file.<VulnDiscussion>If local interactive users are not assigned a valid home directory, there is no place for the storage and control of files they should own.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91893V-77197CCI-000366Assign home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. Assign a home directory to users via the usermod command: -> sudo usermod -d /home/smithj smithjVerify SUSE operating system local interactive users on the system have a home directory assigned. +> sudo usermod -d /home/dosuser dosuserVerify SUSE operating system local interactive users on the system have a home directory assigned. Check for missing local interactive user home directories with the following command: > sudo pwck -r -user 'smithj': directory '/home/smithj' does not exist +user 'dosuser': directory '/home/dosuser' does not exist -Ask the System Administrator (SA) if any users found without home directories are local interactive users. If the SA is unable to provide a response, check for users with a User Identifier (UID) of 1000 or greater with the following command: +Ask the system administrator (SA) if any users found without home directories are local interactive users. If the SA is unable to provide a response, check for users with a User Identifier (UID) of 1000 or greater with the following command: > sudo awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $3, $6}' /etc/passwd @@ -1220,20 +1212,20 @@ Check to see if the system is configured to create home directories for local in # grep -i create_home /etc/login.defs CREATE_HOME yes -If the value for "CREATE_HOME" parameter is not set to "yes", the line is missing, or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010730All SUSE operating system local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a Denial of Service because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91899V-77203CCI-000366Create home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": +If the value for "CREATE_HOME" parameter is not set to "yes", the line is missing, or the line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010730All SUSE operating system local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a Denial of Service because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91899V-77203CCI-000366Create home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": -Note: The example will be for the user smithj, who has a home directory of "/home/smithj", a UID of "smithj", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". +Note: The example will be for the user dosuser, who has a home directory of "/home/dosuser", a UID of "dosuser", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". -# mkdir /home/smithj -# chown smithj /home/smithj -# chgrp users /home/smithj -# chmod 0750 /home/smithjVerify the assigned home directory of all SUSE operating system local interactive users on the system exists. +# mkdir /home/dosuser +# chown dosuser /home/dosuser +# chgrp users /home/dosuser +# chmod 0750 /home/dosuserVerify the assigned home directory of all SUSE operating system local interactive users on the system exists. Check the home directory assignment for all local interactive non-privileged users on the system with the following command: # awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $6}' /etc/passwd -smithj /home/smithj +dosuser /home/dosuser Note: This may miss interactive users that have been assigned a privileged UID. Evidence of interactive use may be obtained from a number of log files containing system logon information. @@ -1241,64 +1233,64 @@ Check that all referenced home directories exist with the following command: # pwck -r -user 'smithj': directory '/home/smithj' does not exist +user 'dosuser': directory '/home/dosuser' does not exist -If any home directories referenced in "/etc/passwd" are returned as not defined, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010740All SUSE operating system local interactive user home directories must have mode 0750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91903V-77207CCI-000366Change the mode of SUSE operating system local interactive user's home directories to "0750". To change the mode of a local interactive user's home directory, use the following command: +If any home directories referenced in "/etc/passwd" are returned as not defined, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010740All SUSE operating system local interactive user home directories must have mode 0750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91903V-77207CCI-000366Change the mode of SUSE operating system local interactive user's home directories to "0750". To change the mode of a local interactive user's home directory, use the following command: -Note: The example will be for the user "smithj". +Note: The example will be for the user "dosuser". -# chmod 0750 /home/smithjVerify the assigned home directory of all SUSE operating system local interactive users has a mode of "0750" or less permissive. +# chmod 0750 /home/dosuserVerify the assigned home directory of all SUSE operating system local interactive users has a mode of "0750" or less permissive. Check the home directory assignment for all non-privileged users on the system with the following command: Note: This may miss interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. # ls -ld $(awk -F: '($3>=1000)&&($7 !~ /nologin/){print $6}' /etc/passwd) --rwxr-x--- 1 smithj users 18 Mar 5 17:06 /home/smithj +-rwxr-x--- 1 dosuser users 18 Mar 5 17:06 /home/dosuser -If home directories referenced in "/etc/passwd" do not have a mode of "0750" or less permissive, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010750All SUSE operating system local interactive user home directories must be group-owned by the home directory owners primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user’s home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user’s files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91907V-77211CCI-000366Change the group owner of a SUSE operating system local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: +If home directories referenced in "/etc/passwd" do not have a mode of "0750" or less permissive, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010750All SUSE operating system local interactive user home directories must be group-owned by the home directory owners primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user’s home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user’s files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91907V-77211CCI-000366Change the group owner of a SUSE operating system local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj", and has a primary group of users. +Note: The example will be for the user "dosuser", who has a home directory of "/home/dosuser", and has a primary group of users. -# chgrp users /home/smithjVerify the assigned home directory of all SUSE operating system local interactive users is group-owned by that user's primary GID. +# chgrp users /home/dosuserVerify the assigned home directory of all SUSE operating system local interactive users is group-owned by that user's primary GID. -Check the home directory assignment for all non-privileged users on the system with the following command: +Check the home directory assignment for all nonprivileged users on the system with the following command: -Note: This may miss local interactive users that have been assigned a privileged UID. Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/smithj" is used as an example. +Note: This may miss local interactive users that have been assigned a privileged UID. Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/dosuser" is used as an example. # awk -F: '($3>=1000)&&($7 !~ /nologin/){print $4, $6}' /etc/passwd -250 /home/smithj +250 /home/dosuser Check the user's primary group with the following command: # grep users /etc/group -users:x:250:smithj,jonesj,jacksons +users:x:250:dosuser,doduser,nsauser -If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010760All SUSE operating system local initialization files must have mode 0740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91911V-77215CCI-000366Set the mode of SUSE operating system local initialization files to "0740" with the following command: +If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010760All SUSE operating system local initialization files must have mode 0740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91911V-77215CCI-000366Set the mode of SUSE operating system local initialization files to "0740" with the following command: -Note: The example will be for the smithj user, who has a home directory of "/home/smithj". +Note: The example will be for the dosuser user, who has a home directory of "/home/dosuser". -# chmod 0740 /home/smithj/.<INIT_FILE>Verify that all SUSE operating system local initialization files have a mode of "0740" or less permissive. +# chmod 0740 /home/dosuser/.<INIT_FILE>Verify that all SUSE operating system local initialization files have a mode of "0740" or less permissive. Check the mode on all SUSE operating system local initialization files with the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj". +Note: The example will be for the user "dosuser", who has a home directory of "/home/dosuser". -# ls -al /home/smithj/.* | more --rwxr-xr-x 1 smithj users 896 Mar 10 2011 .profile --rwxr-xr-x 1 smithj users 497 Jan 6 2007 .login --rwxr-xr-x 1 smithj users 886 Jan 6 2007 .something +# ls -al /home/dosuser/.* | more +-rwxr-xr-x 1 dosuser users 896 Mar 10 2011 .profile +-rwxr-xr-x 1 dosuser users 497 Jan 6 2007 .login +-rwxr-xr-x 1 dosuser users 886 Jan 6 2007 .something -If any local initialization files have a mode more permissive than "0740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010770All SUSE operating system local interactive user initialization files executable search paths must contain only paths that resolve to the users home directory.<VulnDiscussion>The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory (other than the user's home directory), executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. If deviations from the default system search path for the local interactive user are required, they must be documented with the Information System Security Officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91915V-77219CCI-000366Edit the SUSE operating system local interactive user initialization files to change any PATH variable statements for executables that reference directories other than their home directory. If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.Verify that all SUSE operating system local interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the user's home directory. +If any local initialization files have a mode more permissive than "0740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010770All SUSE operating system local interactive user initialization files executable search paths must contain only paths that resolve to the users home directory.<VulnDiscussion>The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory (other than the user's home directory), executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. If deviations from the default system search path for the local interactive user are required, they must be documented with the information system security officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91915V-77219CCI-000366Edit the SUSE operating system local interactive user initialization files to change any PATH variable statements for executables that reference directories other than their home directory. If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.Verify that all SUSE operating system local interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the user's home directory. Check the executable search path statement for all operating system local interactive user initialization files in the user's home directory with the following commands: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj". +Note: The example will be for the user "dosuser", who has a home directory of "/home/dosuser". -# sudo grep -i path= /home/smithj/.* -/home/smithj/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin +# sudo grep -i path= /home/dosuser/.* +/home/dosuser/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin -If any local interactive user initialization files have executable search path statements that include directories outside of their home directory, and the additional path statements are not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010780All SUSE operating system local initialization files must not execute world-writable programs.<VulnDiscussion>If user start-up files execute world-writable programs, especially in unprotected directories, they could be maliciously modified to destroy user files or otherwise compromise the system at the user level. If the system is compromised at the user level, it is easier to elevate privileges to eventually compromise the system at the root and network level.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91921V-77225CCI-000366Remove the references to these files in the local initialization scripts or remove the world-writable permission of files referenced by SUSE operating system local initialization scripts with the following command: +If any local interactive user initialization files have executable search path statements that include directories outside of their home directory, and the additional path statements are not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010780All SUSE operating system local initialization files must not execute world-writable programs.<VulnDiscussion>If user start-up files execute world-writable programs, especially in unprotected directories, they could be maliciously modified to destroy user files or otherwise compromise the system at the user level. If the system is compromised at the user level, it is easier to elevate privileges to eventually compromise the system at the root and network level.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91921V-77225CCI-000366Remove the references to these files in the local initialization scripts or remove the world-writable permission of files referenced by SUSE operating system local initialization scripts with the following command: > sudo chmod 0755 <file>Verify that SUSE operating system local initialization files do not execute world-writable programs. @@ -1381,28 +1373,28 @@ Check the status of the "kdump" service with the following command: If the "kdump" service is active, ask the System Administrator if the use of the service is required and documented with the Information System Security Officer (ISSO). -If the service is active and is not documented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010850A separate file system must be used for SUSE operating system user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91957V-77261CCI-000366Create a separate file system/partition for SUSE operating system non-privileged local interactive user home directories. +If the service is active and is not documented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010850A separate file system must be used for SUSE operating system user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033SV-91957V-77261CCI-000366Create a separate file system/partition for SUSE operating system nonprivileged local interactive user home directories. -Migrate the non-privileged local interactive user home directories onto the separate file system/partition.Verify that a separate file system/partition has been created for SUSE operating system non-privileged local interactive user home directories. +Migrate the non-privileged local interactive user home directories onto the separate file system/partition.Verify that a separate file system/partition has been created for SUSE operating system nonprivileged local interactive user home directories. -Check the home directory assignment for all non-privileged users (those with a UID greater than 1000) on the system with the following command: +Check the home directory assignment for all nonprivileged users (those with a UID greater than 1000) on the system with the following command: # awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $3, $6, $7}' /etc/passwd -adamsj 1002 /home/adamsj /bin/bash -jacksonm 1003 /home/jacksonm /bin/bash -smithj 1001 /home/smithj /bin/bash +disauser 1002 /home/disauser /bin/bash +doduser 1003 /home/doduser /bin/bash +dosuser 1001 /home/dosuser /bin/bash -The output of the command will give the directory/partition that contains the home directories for the non-privileged users on the system (in this example, /home) and user's shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. +The output of the command will give the directory/partition that contains the home directories for the nonprivileged users on the system (in this example, /home) and user's shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. -Check that a file system/partition has been created for the non-privileged interactive users with the following command: +Check that a file system/partition has been created for the nonprivileged interactive users with the following command: Note: The partition of /home is used in the example. # grep /home /etc/fstab UUID=333ada18 /home ext4 noatime,nobarrier,nodev 1 2 -If a separate entry for the file system/partition that contains the non-privileged interactive users' home directories does not exist, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010860The SUSE operating system must use a separate file system for /var.<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77265SV-91961CCI-000366Create a separate file system/partition on the SUSE operating system for "/var". +If a separate entry for the file system/partition that contains the nonprivileged interactive users' home directories does not exist, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-12-010860The SUSE operating system must use a separate file system for /var.<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033V-77265SV-91961CCI-000366Create a separate file system/partition on the SUSE operating system for "/var". Migrate "/var" onto the separate file system/partition.Verify that the SUSE operating system has a separate file system/partition for "/var". @@ -3900,7 +3892,7 @@ Restart the "sshd" service for changes to take effect: $ sudo grep -i kexalgorithms /etc/ssh/sshd_config KexAlgorithms ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256 -If "KexAlgorithms" is not configured, is commented out, or does not contain only the algorithms "ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256" in exact order, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-12-010375The SUSE operating system must restrict access to the kernel message buffer.<VulnDiscussion>Restricting access to the kernel message buffer limits access only to root. This prevents attackers from gaining additional system information as a nonprivileged user.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033CCI-001090Configure the operating system to restrict access to the kernel message buffer. +If "KexAlgorithms" is not configured, is commented out, or does not contain only the algorithms "ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256" in exact order, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-12-010375The SUSE operating system must restrict access to the kernel message buffer.<VulnDiscussion>Restricting access to the kernel message buffer limits access only to root. This prevents attackers from gaining additional system information as a nonprivileged user.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 12DISADPMS TargetSUSE Linux Enterprise Server 124033CCI-001090Configure the operating system to restrict access to the kernel message buffer. Set the system to the required kernel parameter by adding or modifying the following line in /etc/sysctl.conf or a config file in the /etc/sysctl.d/ directory: diff --git a/shared/references/disa-stig-sle15-v2r5-xccdf-manual.xml b/shared/references/disa-stig-sle15-v2r7-xccdf-manual.xml similarity index 86% rename from shared/references/disa-stig-sle15-v2r5-xccdf-manual.xml rename to shared/references/disa-stig-sle15-v2r7-xccdf-manual.xml index 293ad43f48ee..d92e30783f67 100644 --- a/shared/references/disa-stig-sle15-v2r5-xccdf-manual.xml +++ b/shared/references/disa-stig-sle15-v2r7-xccdf-manual.xml @@ -1,4 +1,13 @@ -acceptedSUSE Linux Enterprise Server 15 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 5 Benchmark Date: 02 Jul 20253.51.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-010000The SUSE operating system must be a vendor-supported release.<VulnDiscussion>A SUSE operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001230Upgrade the SUSE operating system to a version supported by the vendor. If the system is not registered with the SUSE Customer Center, register the system against the correct subscription. +acceptedSUSE Linux Enterprise Server 15 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 7 Benchmark Date: 01 Apr 20263.5.21.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-010000The SUSE operating system must be a vendor-supported release.<VulnDiscussion>A SUSE operating system release is considered "supported" if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software. + +Release Released General Support Long Term Support +15.1 24 Jun 2019 31 Jan 2021 31 Jan 2024 +15.2 21 Jul 2020 31 Dec 2021 31 Dec 2024 +15.3 22 Jun 2021 31 Dec 2022 31 Dec 2025 +15.4 21 Jun 2022 31 Dec 2023 31 Dec 2026 +15.5 20 Jun 2023 31 Dec 2024 31 Dec 2027 +15.6 26 Jun 2024 31 Dec 2025 31 Dec 2028 +15.7 17 Jun 2025 31 Jul 2031 31 Jul 2034</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001230Upgrade the SUSE operating system to a version supported by the vendor. If the system is not registered with the SUSE Customer Center, register the system against the correct subscription. If the system requires Long-Term Service Pack Support (LTSS), obtain the correct LTSS subscription for the system.Verify the SUSE operating system is a vendor-supported release. @@ -108,7 +117,7 @@ Check that the vsftpd package is not installed on the SUSE operating system by r > zypper info vsftpd | grep Installed -If "vsftpd" is installed and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLES-15-010040The SUSE operating system must display the Standard Mandatory DOD Notice and Consent Banner before granting access via SSH.<VulnDiscussion>Display of a standardized and approved use notification before granting access to the SUSE operating system ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. +If "vsftpd" is installed and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLES-15-010040The SUSE operating system must display the Standard Mandatory DOD Notice and Consent Banner before granting access via SSH.<VulnDiscussion>Display of a standardized and approved use notification before granting access to the SUSE operating system ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. System use notifications are required only for access via logon interfaces with human users and are not required when such human interfaces do not exist. @@ -128,11 +137,13 @@ By using this IS (which includes any device attached to this IS), you consent to -Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details." -Satisfies: SRG-OS-000023-GPOS-00006, SRG-OS-000228-GPOS-00088</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000048CCI-001384CCI-001385CCI-001386CCI-001387CCI-001388Configure the SUSE operating system to display the Standard Mandatory DOD Notice and Consent Banner before granting access to the system by running the following commands: +Satisfies: SRG-OS-000023-GPOS-00006, SRG-OS-000228-GPOS-00088</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000048CCI-001384CCI-001385CCI-001386CCI-001387CCI-001388Configure the SUSE operating system to display the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via ssh. + +Edit the "etc/ssh/sshd_config" file or a file in "/etc/ssh/sshd_config.d" to uncomment the banner keyword and configure it to point to a file that will contain the logon banner (this file may be named differently or be in a different location if using a version of SSH that is provided by a third-party vendor). -Edit the "sshd_config" file and edit the Banner flag to be the following: +An example configuration line is: -Banner /etc/issue/ +Banner /etc/issue Restart the sshd daemon: @@ -152,7 +163,7 @@ By using this IS (which includes any device attached to this IS), you consent to -This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy. --Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details."Verify the SUSE operating system displays the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via SSH. +-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details."Verify the SUSE operating system displays the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via SSH. Check the issue file to verify it contains one of the DOD required banners. If it does not, this is a finding. @@ -176,11 +187,12 @@ By using this IS (which includes any device attached to this IS), you consent to If the output does not display the banner text, this is a finding. -Check the banner setting for sshd_config: +Check for the location of the banner file being used with the following command: -> sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*banner' +$ sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*banner' +/etc/ssh/sshd_config.d/80-bannerPointer.conf:Banner /etc/issue -Banner /etc/issue +This command will return the banner keyword and the name of the file that contains the SSH banner (in this case "/etc/issue"). If "Banner" is not set to "/etc/issue", this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLES-15-010050The SUSE operating system must display the Standard Mandatory DoD Notice and Consent Banner until users acknowledge the usage conditions and take explicit actions to log on for further access to the local graphical user interface (GUI).<VulnDiscussion>The SUSE operating system must display the Standard Mandatory DoD Notice and Consent Banner until users acknowledge the usage conditions and take explicit actions to log on for further access to the local graphical user interface (GUI). @@ -539,7 +551,7 @@ Check that the telnet-server package is not installed on the SUSE operating syst > zypper info telnet-server | grep Installed -If the telnet-server package is installed, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-15-010190SUSE operating systems with a basic input/output system (BIOS) must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DoD-approved PKIs, all DoD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. +If the telnet-server package is installed, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-15-010190SUSE operating systems with a basic input/output system (BIOS) must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DoD-approved PKIs, all DoD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. Access control policies include identity-based policies, role-based policies, and attribute-based policies. Access enforcement mechanisms include access control lists, access control matrices, and cryptography. These policies and mechanisms must be employed by the application to control access between users (or processes acting on behalf of users) and objects (e.g., devices, files, records, processes, programs, and domains) in the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000213Note: If the system does not use a BIOS this requirement is Not Applicable. @@ -570,7 +582,7 @@ Check that the encrypted password is set for root with the following command: password_pbkdf2 root grub.pbkdf2.sha512.10000.VeryLongString -If the root password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-15-010200SUSE operating systems with Unified Extensible Firmware Interface (UEFI) implemented must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system allows a user to boot into single-user or maintenance mode without authentication, any user that invokes single-user or maintenance mode is granted privileged access to all system information.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000213Note: If the system does not use UEFI, this requirement is Not Applicable. +If the root password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLES-15-010200SUSE operating systems with Unified Extensible Firmware Interface (UEFI) implemented must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system allows a user to boot into single-user or maintenance mode without authentication, any user that invokes single-user or maintenance mode is granted privileged access to all system information.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000213Note: If the system does not use UEFI, this requirement is Not Applicable. Configure the SUSE operating system to encrypt the boot password. @@ -657,16 +669,14 @@ Check that the SUSE operating system contains no duplicate UIDs for interactive > awk -F ":" 'list[$3]++{print $1, $3}' /etc/passwd -If output is produced, this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>SLES-15-010240The SUSE operating system must disable the file system automounter unless required.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity. +If output is produced, this is a finding.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>SLES-15-010240The SUSE operating system must disable the file system automounter.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity. -Satisfies: SRG-OS-000114-GPOS-00059, SRG-OS-000378-GPOS-00163</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000778CCI-001958Configure the SUSE operating system to disable the ability to automount devices. +Satisfies: SRG-OS-000114-GPOS-00059, SRG-OS-000378-GPOS-00163</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000778CCI-001958Configure the SUSE operating system to disable the ability to automount devices. -Turn off the automount service with the following command: +Turn off the automount service with the following commands: > systemctl stop autofs -> systemctl disable autofs - -If "autofs" is required for Network File System (NFS), it must be documented with the ISSO.Verify the SUSE operating system disables the ability to automount devices. +> systemctl disable autofsVerify the SUSE operating system disables the ability to automount devices. Check to see if automounter service is active with the following command: @@ -675,7 +685,7 @@ autofs.service - Automounts filesystems on demand Loaded: loaded (/usr/lib/systemd/system/autofs.service; disabled) Active: inactive (dead) -If the "autofs" status is set to "active" and is not documented with the Information System Security Officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>SLES-15-010260The SUSE operating system must employ FIPS 140-2 approved cryptographic hashing algorithm for system authentication (login.defs).<VulnDiscussion>Unapproved mechanisms that are used for authentication to the cryptographic module are not verified and therefore cannot be relied on to provide confidentiality or integrity, and DoD data may be compromised. +If the "autofs" status is set to "active" this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>SLES-15-010260The SUSE operating system must employ FIPS 140-2 approved cryptographic hashing algorithm for system authentication (login.defs).<VulnDiscussion>Unapproved mechanisms that are used for authentication to the cryptographic module are not verified and therefore cannot be relied on to provide confidentiality or integrity, and DoD data may be compromised. SUSE operating systems using encryption are required to use FIPS-compliant mechanisms for authenticating to cryptographic modules. @@ -729,7 +739,7 @@ Check that the "ClientAliveInterval" parameter is set to a value of "600" with t ClientAliveInterval 600 -If "ClientAliveInterval" is not set to "600" in "/etc/ssh/sshd_config", this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-15-010300The sticky bit must be set on all SUSE operating system world-writable directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, and hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If "ClientAliveInterval" is not set to "600" in "/etc/ssh/sshd_config", this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-15-010300The sticky bit must be set on all SUSE operating system world-writable directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, and hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DoD or other government agencies. @@ -1188,11 +1198,11 @@ Check that the SUSE operating system is configured to use UTC or GMT with the fo > timedatectl status | grep -i "time zone" Time zone: UTC (UTC, +0000) -If "Time zone" is not set to "UTC" or "GMT", this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>SLES-15-010420Advanced Intrusion Detection Environment (AIDE) must verify the baseline SUSE operating system configuration at least weekly.<VulnDiscussion>Unauthorized changes to the baseline configuration could make the system vulnerable to various attacks or allow unauthorized access to the SUSE operating system. Changes to SUSE operating system configurations can have unintended side effects, some of which may be relevant to security. +If "Time zone" is not set to "UTC" or "GMT", this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>SLES-15-010420Advanced Intrusion Detection Environment (AIDE) must verify the baseline SUSE operating system configuration at least weekly.<VulnDiscussion>Unauthorized changes to the baseline configuration could make the system vulnerable to various attacks or allow unauthorized access to the SUSE operating system. Changes to SUSE operating system configurations can have unintended side effects, some of which may be relevant to security. Detecting such changes and providing an automated response can help avoid unintended, negative consequences that could ultimately affect the security state of the SUSE operating system. The SUSE operating system's Information System Security Manager (ISSM)/Information System Security Officer (ISSO) and System Administrator (SAs) must be notified via email and/or monitoring system trap when there is an unauthorized modification of a configuration item. -Satisfies: SRG-OS-000363-GPOS-00150, SRG-OS-000445-GPOS-00199, SRG-OS-000446-GPOS-00200</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001744CCI-002696CCI-002699Configure the SUSE operating system to check the baseline configuration for unauthorized changes at least once weekly. +Satisfies: SRG-OS-000363-GPOS-00150, SRG-OS-000445-GPOS-00199, SRG-OS-000446-GPOS-00200</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001744CCI-002696CCI-002699Configure the SUSE operating system to check the baseline configuration for unauthorized changes at least once weekly. If the "aide" package is not installed, install it with the following command: @@ -1201,9 +1211,9 @@ If the "aide" package is not installed, install it with the following command: Configure the file integrity tool to automatically run on the system at least weekly. The following example output is generic. It will set cron to run AIDE weekly, but other file integrity tools may be used: > cat /etc/cron.weekly/aide - 0 0 * * * /usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily AIDE integrity check run" root@example_server_name.mil + 0 0 * * * /usr/bin/aide --check | /bin/mail -s "$HOSTNAME - Daily AIDE integrity check run" root@example_server_name.mil -Note: Per requirement SLES-15-010418, the "mailx" package must be installed on the system to enable email functionality.Verify the SUSE operating system checks the baseline configuration for unauthorized changes at least once weekly. +Note: Per requirement SLES-15-010418, the "mailx" package must be installed on the system to enable email functionality.Verify the SUSE operating system checks the baseline configuration for unauthorized changes at least once weekly. Note: A file integrity tool other than AIDE may be used, but the tool must be executed at least once per week. @@ -1214,21 +1224,21 @@ Check the "/etc/cron" subdirectories for a "crontab" file controlling the execut > sudo grep -R aide /etc/crontab /etc/cron.* /etc/crontab: 30 04 * * * /etc/aide -If the file integrity application does not exist, or a "crontab" file does not exist in "/etc/crontab", the "/etc/cron.daily" subdirectory, or "/etc/cron.weekly" subdirectory, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>SLES-15-010430The SUSE operating system tool zypper must have gpgcheck enabled.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of the SUSE operating system. This requirement ensures the software has not been tampered with and has been provided by a trusted vendor. +If the file integrity application does not exist, or a "crontab" file does not exist in "/etc/crontab", the "/etc/cron.daily" subdirectory, or "/etc/cron.weekly" subdirectory, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>SLES-15-010430The SUSE operating system tool zypper must have gpgcheck enabled.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of SLES 12. This requirement ensures the software has not been tampered with and has been provided by a trusted vendor. -Accordingly, patches, service packs, device drivers, or SUSE operating system components must be signed with a certificate recognized and approved by the organization. +Accordingly, patches, service packs, device drivers, or SLES 12 components must be signed with a certificate recognized and approved by the organization. -Verifying the authenticity of the software prior to installation validates the integrity of the patch or upgrade received from a vendor. This ensures the software has not been tampered with and that it has been provided by a trusted vendor. Self-signed certificates are disallowed by this requirement. The SUSE operating system should not have to verify the software again. This requirement does not mandate DOD certificates for this purpose; however, the certificate used to verify the software must be from an approved Certification Authority (CA).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-003992CCI-001749Configure that the SUSE operating system tool zypper to enable gpgcheck by editing or adding the following line to "/etc/zypp/zypp.conf": +Verifying the authenticity of the software prior to installation validates the integrity of the patch or upgrade received from a vendor. This ensures the software has not been tampered with and that it has been provided by a trusted vendor. Self-signed certificates are disallowed by this requirement. SLES 12 should not have to verify the software again. This requirement does not mandate DOD certificates for this purpose; however, the certificate used to verify the software must be from an approved Certification Authority (CA). -gpgcheck = 1Verify that the SUSE operating system tool zypper has gpgcheck enabled. +For zypper on SUSE Linux Enterprise systems, GPG signature checking is enabled by default for all repositories, even if it is not explicitly set in /etc/zypp/zypp.conf or individual .repo files. The presence of the gpgcheck setting in repository files (like gpgcheck=1) or a global zypp.conf entry would override this default behavior if a user wanted to disable it (e.g., gpgcheck=0), but its absence simply means the default is in effect.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-003992CCI-001749Configure the SLES 12 zypper tool to enable gpgcheck. -Check that zypper has gpgcheck enabled with the following command: +Add or modify the following line in the "/etc/zypp/zypp.conf" file or remove the line completely ensuring that the default zypper setting is enabled: -> grep -i '^gpgcheck' /etc/zypp/zypp.conf +gpgcheck = onVerify the SLES 12 zypper tool has gpgcheck enabled with the following command: -gpgcheck = 1 + > grep -i '^gpgcheck' /etc/zypp/zypp.conf -If "gpgcheck" is set to "0", "off", "no", or "false", this is a finding.SRG-OS-000373-GPOS-00156<GroupDescription></GroupDescription>SLES-15-010450The SUSE operating system must reauthenticate users when changing authenticators, roles, or escalating privileges.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. +If "gpgcheck" is set to "off", this is a finding.SRG-OS-000373-GPOS-00156<GroupDescription></GroupDescription>SLES-15-010450The SUSE operating system must reauthenticate users when changing authenticators, roles, or escalating privileges.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. When the SUSE operating system provides the capability to change user authenticators, change security roles, or escalate a functional capability, it is critical the user reauthenticate. @@ -1288,13 +1298,13 @@ Check for the presence of the packages required to support multifactor authentic > zypper info coolkey | grep -i installed -If any of the packages required for multifactor authentication are not installed, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>SLES-15-010470The SUSE operating system must implement certificate status checking for multifactor authentication.<VulnDiscussion>Using an authentication device, such as a Common Access Card (CAC) or token separate from the information system, ensures credentials stored on the authentication device will not be affected if the information system is compromised. +If any of the packages required for multifactor authentication are not installed, this is a finding.SRG-OS-000375-GPOS-00160<GroupDescription></GroupDescription>SLES-15-010470The SUSE operating system must implement certificate status checking for multifactor authentication.<VulnDiscussion>Using an authentication device, such as a common access card (CAC) or token separate from the information system, ensures credentials stored on the authentication device will not be affected if the information system is compromised. Multifactor solutions that require devices separate from information systems to gain access include hardware tokens providing time-based or challenge-response authenticators, and smart cards such as the U.S. Government Personal Identity Verification (PIV) card and the DOD CAC. A privileged account is defined as an information system account with authorizations of a privileged user. -Remote access is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, non-organization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. +Remote access is access to DOD nonpublic information systems by an authorized user (or an information system) communicating through an external, nonorganization-controlled network. Remote access methods include, for example, dial-up, broadband, and wireless. This requirement only applies to components with device-specific functions, or for organizational users (e.g., VPN, proxy capability). This does not apply to authentication for the purpose of configuring the device itself (management). @@ -1304,7 +1314,7 @@ Modify all of the cert_policy lines in "/etc/pam_pkcs11/pam_pkcs11.conf" to incl Note: OCSP allows sending request for certificate status information. Additional certificate validation polices are permitted. -Additional information on the configuration of multifactor authentication on the SUSE operating system can be found at https://www.suse.com/communities/blog/configuring-smart-card-authentication-suse-linux-enterprise/.Verify the SUSE operating system implements certificate status checking for multifactor authentication. +Additional information on the configuration of multifactor authentication on the SUSE operating system can be found at https://www.suse.com/communities/blog/configuring-smart-card-authentication-suse-linux-enterprise/.Verify the SUSE operating system implements certificate status checking for multifactor authentication. Check that certificate status checking for multifactor authentication is implemented with the following command: @@ -1312,7 +1322,7 @@ Check that certificate status checking for multifactor authentication is impleme cert_policy = ca,ocsp_on,signature,crl_auto; -If "cert_policy" is not set to include "ocsp", this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>SLES-15-010480The SUSE operating system must disable the USB mass storage kernel module.<VulnDiscussion>Without identifying devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. +If "cert_policy" is not set to include "ocsp_on", this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>SLES-15-010480The SUSE operating system must disable the USB mass storage kernel module.<VulnDiscussion>Without identifying devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. Peripherals include but are not limited to such devices as flash drives, external storage, and printers.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001958Configure the SUSE operating system to prevent USB mass storage devices from automounting when connected to the host. @@ -1443,24 +1453,24 @@ solver.upgradeRemoveDroppedPackages = trueSRG-OS-000447-GPOS-00201<GroupDescription></GroupDescription>SLES-15-010570The SUSE operating system must notify the System Administrator (SA) when Advanced Intrusion Detection Environment (AIDE) discovers anomalies in the operation of any security functions.<VulnDiscussion>If anomalies are not acted on, security functions may fail to secure the system. +If "solver.upgradeRemoveDroppedPackages" is commented out, is set to "false", or is missing completely, this is a finding.SRG-OS-000447-GPOS-00201<GroupDescription></GroupDescription>SLES-15-010570The SUSE operating system must notify the System Administrator (SA) when Advanced Intrusion Detection Environment (AIDE) discovers anomalies in the operation of any security functions.<VulnDiscussion>If anomalies are not acted on, security functions may fail to secure the system. Security function is defined as the hardware, software, and/or firmware of the information system responsible for enforcing the system security policy and supporting the isolation of code and data on which the protection is based. Security functionality includes, but is not limited to, establishing system accounts, configuring access authorizations (i.e., permissions, privileges), setting events to be audited, and setting intrusion detection parameters. Notifications provided by information systems include messages to local computer consoles and/or hardware indications, such as lights. -This capability must take into account operational requirements for availability for selecting an appropriate response. The organization may choose to shut down or restart the information system upon security function anomaly detection.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-002702Configure the SUSE operating system to notify the SA when AIDE discovers anomalies in the operation of any security functions. +This capability must take into account operational requirements for availability for selecting an appropriate response. The organization may choose to shut down or restart the information system upon security function anomaly detection.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-002702Configure the SUSE operating system to notify the SA when AIDE discovers anomalies in the operation of any security functions. Create the aide crontab file in "/etc/cron.daily" and add following command replacing the "[E-MAIL]" parameter with a proper email address for the SA: - 0 0 * * * /usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily AIDE integrity check run" root@example_server_name.mil + 0 0 * * * /usr/bin/aide --check | /bin/mail -s "$HOSTNAME - Daily AIDE integrity check run" root@example_server_name.mil -Note: Per requirement SLES-15-010418, the "mailx" package must be installed on the system to enable email functionality.Verify the SUSE operating system notifies the SA when AIDE discovers anomalies in the operation of any security functions. +Note: Per requirement SLES-15-010418, the "mailx" package must be installed on the system to enable email functionality.Verify the SUSE operating system notifies the SA when AIDE discovers anomalies in the operation of any security functions. -Check to see if the aide cron job sends an email when executed with the following command: +Verify the aide cron job sends an email when executed with the following command: > grep -i "aide" /etc/cron.*/aide - 0 0 * * * /usr/sbin/aide --check | /bin/mail -s "$HOSTNAME - Daily AIDE integrity check run" root@example_server_name.mil + 0 0 * * * /usr/bin/aide --check | /bin/mail -s "$HOSTNAME - Daily AIDE integrity check run" root@example_server_name.mil If the "aide" file does not exist under the "/etc/cron" directory structure or the cron job is not configured to execute a binary to send an email (such as "/bin/mail"), this is a finding.SRG-OS-000479-GPOS-00224<GroupDescription></GroupDescription>SLES-15-010580The SUSE operating system must off-load rsyslog messages for networked systems in real time and off-load standalone systems at least weekly.<VulnDiscussion>Information stored in one location is vulnerable to accidental or incidental deletion or alteration. @@ -1624,19 +1634,7 @@ Check to see if the root account password or account expires with the following Password expires:never -If "Password expires" or "Account expires" is set to anything other than "never", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-020080The SUSE operating system must display the date and time of the last successful account logon upon logon.<VulnDiscussion>Providing users with feedback on when account accesses last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000052Configure the SUSE operating system to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/login". - -Add the following line to the top of "/etc/pam.d/login": - -session required pam_lastlog.so showfailedVerify the SUSE operating system users are provided with feedback on when account accesses last occurred. - -Check that "pam_lastlog" is used and not silent with the following command: - -> grep pam_lastlog /etc/pam.d/login - -session required pam_lastlog.so showfailed - -If "pam_lastlog" is missing from "/etc/pam.d/login" file, the "silent" option is present, or the returned line is commented out, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-020090The SUSE operating system must not have unnecessary accounts.<VulnDiscussion>Accounts providing no operational purpose provide additional opportunities for system compromise. Unnecessary accounts include user accounts for individuals not requiring access to the system and application accounts for applications not installed on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Configure the SUSE operating system so all accounts on the system are assigned to an active system, application, or user account. +If "Password expires" or "Account expires" is set to anything other than "never", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-020090The SUSE operating system must not have unnecessary accounts.<VulnDiscussion>Accounts providing no operational purpose provide additional opportunities for system compromise. Unnecessary accounts include user accounts for individuals not requiring access to the system and application accounts for applications not installed on the system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Configure the SUSE operating system so all accounts on the system are assigned to an active system, application, or user account. Remove accounts that do not support approved system activities or that allow for a normal user to perform administrative-level actions. @@ -1842,17 +1840,17 @@ To check that the SUSE operating system enforces 24 hours/one day as the minimum PASS_MIN_DAYS 1 -If no output is produced, or if "PASS_MIN_DAYS" does not have a value of "1" or greater, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>SLES-15-020210The SUSE operating system must employ user passwords with a minimum lifetime of 24 hours (one day).<VulnDiscussion>Enforcing a minimum password lifetime helps prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-004066CCI-000198Configure the SUSE operating system to enforce 24 hours/one day or greater as the minimum password age for user accounts. +If no output is produced, or if "PASS_MIN_DAYS" does not have a value of "1" or greater, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>SLES-15-020210The SUSE operating system must employ user passwords with a minimum lifetime of 24 hours (one day).<VulnDiscussion>Enforcing a minimum password lifetime helps prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-004066CCI-000198Configure the SUSE operating system to enforce 24 hours/one day or greater as the minimum password age for user accounts. Change the minimum time period between password changes for each [USER] account to "1" day with the command, replacing [USER] with the user account that must be changed: -> sudo passwd -n 1 [USER]Verify the SUSE operating system enforces a minimum time period between password changes for each user account of one day or greater. +> sudo passwd -n 1 [USER]Verify the SUSE operating system enforces a minimum time period between password changes for each user account of one day or greater. Check the minimum time period between password changes for each user account with the following command: > sudo awk -F: '$4 < 1 {print $1 ":" $4}' /etc/shadow -smithj:1 +doduser:1 If any results are returned that are not associated with a system account, this is a finding.SRG-OS-000076-GPOS-00044<GroupDescription></GroupDescription>SLES-15-020220The SUSE operating system must be configured to create or update passwords with a maximum lifetime of 60 days.<VulnDiscussion>Any password, no matter how complex, can eventually be cracked. Therefore, passwords need to be changed periodically. If the SUSE operating system does not limit the lifetime of passwords and force users to change their passwords, there is the risk that the SUSE operating system passwords could be compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-004066CCI-000199Configure the SUSE operating system to enforce a maximum password age of 60 days or less. @@ -3663,11 +3661,9 @@ ctrl-alt-del.target Loaded: masked (/dev/null; maksed) Active: inactive (dead) -If the ctrl-alt-del.target is not masked, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040061The SUSE operating system must disable the x86 Ctrl-Alt-Delete key sequence for Graphical User Interfaces.<VulnDiscussion>A locally logged-on user, who presses Ctrl-Alt-Delete when at the console, can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In the graphical user interface environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Configure the system to disable the Ctrl-Alt-Delete sequence for the -graphical user interface. +If the ctrl-alt-del.target is not masked, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040061The SUSE operating system must disable the x86 Ctrl-Alt-Delete key sequence for Graphical User Interfaces.<VulnDiscussion>A locally logged-on user, who presses Ctrl-Alt-Delete when at the console, can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In the graphical user interface environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Configure the system to disable the Ctrl-Alt-Delete sequence for the graphical user interface. -Create a database to contain the system-wide setting (if it does not -already exist) with the following steps: +Create a database to contain the systemwide setting (if it does not already exist) with the following steps: 1. Create a user profile and with the listed content: @@ -3684,33 +3680,30 @@ system-db:local /etc/dconf/db/local.d/01-fips-settings [org/gnome/settings-daemon/plugins/media-keys] -logout=[''] +logout='' /etc/dconf/db/local.d/locks/01-fips-locks /org/gnome/settings-daemon/plugins/media-keys/logout 4. Update the dconf database: -> sudo dconf updateNote: If a graphical user interface is not installed, this requirement is Not Applicable. +> sudo dconf updateNote: If a graphical user interface is not installed, this requirement is Not Applicable. -Verify the SUSE operating system is not configured to reboot the system -when Ctrl-Alt-Delete is pressed in the graphical user interface. +Verify the SUSE operating system is not configured to reboot the system when Ctrl-Alt-Delete is pressed in the graphical user interface. -Check that the dconf setting was disabled to allow the Ctrl-Alt-Delete -sequence in the graphical user interface with the following command: +Check that the dconf setting was disabled to allow the Ctrl-Alt-Delete sequence in the graphical user interface with the following command: Check the default logout key sequence: > sudo gsettings get org.gnome.settings-daemon.plugins.media-keys logout -[''] +'' Check that the value is not writable and cannot be changed by the user: > sudo gsettings writable org.gnome.settings-daemon.plugins.media-keys logout false -If the logout value is not [''] and the writable status is not false, this -is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040062The SUSE operating system must disable the systemd Ctrl-Alt-Delete burst key sequence.<VulnDiscussion>A locally logged-on user, who presses Ctrl-Alt-Delete when at the console, can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In the graphical user interface environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Configure the system to disable the CtrlAltDelBurstAction by adding it to a drop file in a "/etc/systemd/system.conf.d/" configuration file: +If the logout value is not [''] and the writable status is not false, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040062The SUSE operating system must disable the systemd Ctrl-Alt-Delete burst key sequence.<VulnDiscussion>A locally logged-on user, who presses Ctrl-Alt-Delete when at the console, can reboot the system. If accidentally pressed, as could happen in the case of a mixed OS environment, this can create the risk of short-term loss of availability of systems due to unintentional reboot. In the graphical user interface environment, risk of unintentional reboot from the Ctrl-Alt-Delete sequence is reduced because the user will be prompted before any action is taken.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Configure the system to disable the CtrlAltDelBurstAction by adding it to a drop file in a "/etc/systemd/system.conf.d/" configuration file: If no drop file exists, create one with the following command: @@ -3730,35 +3723,35 @@ Reload the daemon for this change to take effect: CtrlAltDelBurstAction=none If the "CtrlAltDelBurstAction" is not set to "none", commented out, or is missing, this is a finding. -If the setting is not configured in a drop in file, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040070All SUSE operating system local interactive users must have a home directory assigned in the /etc/passwd file.<VulnDiscussion>If local interactive users are not assigned a valid home directory, there is no place for the storage and control of files they should own.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Assign home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. +If the setting is not configured in a drop in file, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040070All SUSE operating system local interactive users must have a home directory assigned in the /etc/passwd file.<VulnDiscussion>If local interactive users are not assigned a valid home directory, there is no place for the storage and control of files they should own.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Assign home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. Assign a home directory to users via the usermod command: -> sudo usermod -d /home/smithj smithjVerify SUSE operating system local interactive users on the system have a home directory assigned. +> sudo usermod -d /home/doduser doduserVerify SUSE operating system local interactive users on the system have a home directory assigned. Check for missing local interactive user home directories with the following command: > sudo pwck -r -user 'smithj': directory '/home/smithj' does not exist +user 'doduser': directory '/home/doduser' does not exist -Ask the System Administrator (SA) if any users found without home directories are local interactive users. If the SA is unable to provide a response, check for users with a User Identifier (UID) of 1000 or greater with the following command: +Ask the system administrator (SA) if any users found without home directories are local interactive users. If the SA is unable to provide a response, check for users with a User Identifier (UID) of 1000 or greater with the following command: > awk -F: '($3>=1000)&&($1!="nobody"){print $1 ":" $3}' /etc/passwd -If any interactive users do not have a home directory assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040080All SUSE operating system local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a Denial of Service because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Create home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": +If any interactive users do not have a home directory assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040080All SUSE operating system local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a Denial of Service because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Create home directories to all SUSE operating system local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": -Note: The example will be for the user smithj, who has a home directory of "/home/smithj", a UID of "smithj", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". +Note: The example will be for the user doduser, who has a home directory of "/home/doduser", a UID of "doduser", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". -> sudo mkdir /home/smithj -> sudo chown smithj /home/smithj -> sudo chgrp users /home/smithj -> sudo chmod 0750 /home/smithjVerify the assigned home directory of all SUSE operating system local interactive users on the system exists. +> sudo mkdir /home/doduser +> sudo chown doduser /home/doduser +> sudo chgrp users /home/doduser +> sudo chmod 0750 /home/doduserVerify the assigned home directory of all SUSE operating system local interactive users on the system exists. -Check the home directory assignment for all local interactive non-privileged users on the system with the following command: +Check the home directory assignment for all local interactive nonprivileged users on the system with the following command: > awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $6}' /etc/passwd -smithj /home/smithj +doduser /home/doduser Note: This may miss interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. @@ -3766,62 +3759,62 @@ Check that all referenced home directories exist with the following command: > sudo pwck -r -user 'smithj': directory '/home/smithj' does not exist +user 'doduser': directory '/home/doduser' does not exist -If any home directories referenced in "/etc/passwd" are returned as not defined, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040090All SUSE operating system local interactive user home directories must have mode 0750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Change the mode of SUSE operating system local interactive user's home directories to "0750". To change the mode of a local interactive user's home directory, use the following command: +If any home directories referenced in "/etc/passwd" are returned as not defined, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040090All SUSE operating system local interactive user home directories must have mode 0750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Change the mode of SUSE operating system local interactive user's home directories to "0750". To change the mode of a local interactive user's home directory, use the following command: -Note: The example will be for the user "smithj". +Note: The example will be for the user "doduser". -> sudo chmod 0750 /home/smithjVerify the assigned home directory of all SUSE operating system local interactive users has a mode of "0750" or less permissive. +> sudo chmod 0750 /home/doduserVerify the assigned home directory of all SUSE operating system local interactive users has a mode of "0750" or less permissive. -Check the home directory assignment for all non-privileged users on the system with the following command: +Check the home directory assignment for all nonprivileged users on the system with the following command: Note: This may miss interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. > ls -ld $(awk -F: '($3>=1000)&&($7 !~ /nologin/){print $6}' /etc/passwd) --rwxr-x--- 1 smithj users 18 Mar 5 17:06 /home/smithj +-rwxr-x--- 1 doduser users 18 Mar 5 17:06 /home/doduser -If home directories referenced in "/etc/passwd" do not have a mode of "0750" or less permissive, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040100All SUSE operating system local interactive user home directories must be group-owned by the home directory owner's primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user’s home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user’s files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Change the group owner of a SUSE operating system local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: +If home directories referenced in "/etc/passwd" do not have a mode of "0750" or less permissive, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040100All SUSE operating system local interactive user home directories must be group-owned by the home directory owner's primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user’s home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user’s files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Change the group owner of a SUSE operating system local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj", and has a primary group of users. +Note: The example will be for the user "doduser", who has a home directory of "/home/doduser", and has a primary group of users. -> sudo chgrp users /home/smithjVerify the assigned home directory of all SUSE operating system local interactive users is group-owned by that user's primary GID. +> sudo chgrp users /home/doduserVerify the assigned home directory of all SUSE operating system local interactive users is group-owned by that user's primary GID. -Check the home directory assignment for all non-privileged users on the system with the following command: +Check the home directory assignment for all nonprivileged users on the system with the following command: -Note: This may miss local interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/smithj" is used as an example. +Note: This may miss local interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/doduser" is used as an example. > awk -F: '($3>=1000)&&($7 !~ /nologin/){print $4, $6}' /etc/passwd) -250:/home/smithj +250:/home/doduser Check the user's primary group with the following command: > grep users /etc/group -users:x:250:smithj,jonesj,jacksons +users:x:250:doduser,doduser,nsauser -If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040110All SUSE operating system local initialization files must have mode 0740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Set the mode of SUSE operating system local initialization files to "0740" with the following command: +If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040110All SUSE operating system local initialization files must have mode 0740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Set the mode of SUSE operating system local initialization files to "0740" with the following command: -Note: The example will be for the smithj user, who has a home directory of "/home/smithj". +Note: The example will be for the doduser user, who has a home directory of "/home/doduser". -> sudo chmod 0740 /home/smithj/.<INIT_FILE>Verify that all SUSE operating system local initialization files have a mode of "0740" or less permissive. +> sudo chmod 0740 /home/doduser/.<INIT_FILE>Verify that all SUSE operating system local initialization files have a mode of "0740" or less permissive. Check the mode on all SUSE operating system local initialization files with the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj". +Note: The example will be for the user "doduser", who has a home directory of "/home/doduser". -> sudo ls -al /home/smithj/.* | more --rwxr-xr-x 1 smithj users 896 Mar 10 2011 .profile --rwxr-xr-x 1 smithj users 497 Jan 6 2007 .login --rwxr-xr-x 1 smithj users 886 Jan 6 2007 .something +> sudo ls -al /home/doduser/.* | more +-rwxr-xr-x 1 doduser users 896 Mar 10 2011 .profile +-rwxr-xr-x 1 doduser users 497 Jan 6 2007 .login +-rwxr-xr-x 1 doduser users 886 Jan 6 2007 .something -If any local initialization files have a mode more permissive than "0740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040120All SUSE operating system local interactive user initialization files executable search paths must contain only paths that resolve to the users home directory.<VulnDiscussion>The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory (other than the user's home directory), executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. If deviations from the default system search path for the local interactive user are required, they must be documented with the Information System Security Officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Edit the SUSE operating system local interactive user initialization files to change any PATH variable statements for executables that reference directories other than their home directory. If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.Verify that all SUSE operating system local interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the user's home directory. +If any local initialization files have a mode more permissive than "0740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040120All SUSE operating system local interactive user initialization files executable search paths must contain only paths that resolve to the users home directory.<VulnDiscussion>The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory (other than the user's home directory), executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. If deviations from the default system search path for the local interactive user are required, they must be documented with the information system security officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Edit the SUSE operating system local interactive user initialization files to change any PATH variable statements for executables that reference directories other than their home directory. If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.Verify that all SUSE operating system local interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the user's home directory. Check the executable search path statement for all operating system local interactive user initialization files in the user's home directory with the following commands: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj". +Note: The example will be for the user "doduser", who has a home directory of "/home/doduser". -> sudo grep -i path= /home/smithj/.* -/home/smithj/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin +> sudo grep -i path= /home/doduser/.* +/home/doduser/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin If any local interactive user initialization files have executable search path statements that include directories outside of their home directory, and the additional path statements are not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040130All SUSE operating system local initialization files must not execute world-writable programs.<VulnDiscussion>If user start-up files execute world-writable programs, especially in unprotected directories, they could be maliciously modified to destroy user files or otherwise compromise the system at the user level. If the system is compromised at the user level, it is easier to elevate privileges to eventually compromise the system at the root and network level.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Remove the references to these files in the local initialization scripts or remove the world-writable permission of files referenced by SUSE operating system local initialization scripts with the following command: @@ -3907,28 +3900,28 @@ Active: inactive (dead) If the "kdump" service is active, ask the System Administrator if the use of the service is required and documented with the Information System Security Officer (ISSO). -If the service is active and is not documented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040200A separate file system must be used for SUSE operating system user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Create a separate file system/partition for SUSE operating system non-privileged local interactive user home directories. +If the service is active and is not documented, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040200A separate file system must be used for SUSE operating system user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Create a separate file system/partition for SUSE operating system nonprivileged local interactive user home directories. -Migrate the non-privileged local interactive user home directories onto the separate file system/partition.Verify that a separate file system/partition has been created for SUSE operating system non-privileged local interactive user home directories. +Migrate the nonprivileged local interactive user home directories onto the separate file system/partition.Verify that a separate file system/partition has been created for SUSE operating system nonprivileged local interactive user home directories. -Check the home directory assignment for all non-privileged users (those with a UID greater than 1000) on the system with the following command: +Check the home directory assignment for all nonprivileged users (those with a UID greater than 1000) on the system with the following command: > awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $3, $6, $7}' /etc/passwd -adamsj 1002 /home/adamsj /bin/bash -jacksonm 1003 /home/jacksonm /bin/bash -smithj 1001 /home/smithj /bin/bash +disauser 1002 /home/disauser /bin/bash +doduser 1003 /home/doduser /bin/bash +doduser 1001 /home/doduser /bin/bash -The output of the command will give the directory/partition that contains the home directories for the non-privileged users on the system (in this example, /home) and user's shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. +The output of the command will give the directory/partition that contains the home directories for the nonprivileged users on the system (in this example, /home) and user's shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. -Check that a file system/partition has been created for the non-privileged interactive users with the following command: +Check that a file system/partition has been created for the nonprivileged interactive users with the following command: Note: The partition of /home is used in the example. > grep /home /etc/fstab UUID=333ada18 /home ext4 noatime,nobarrier,nodev 1 2 -If a separate entry for the file system/partition that contains the non-privileged interactive users' home directories does not exist, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040210The SUSE operating system must use a separate file system for /var.<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Create a separate file system/partition on the SUSE operating system for "/var". +If a separate entry for the file system/partition that contains the nonprivileged interactive users' home directories does not exist, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLES-15-040210The SUSE operating system must use a separate file system for /var.<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-000366Create a separate file system/partition on the SUSE operating system for "/var". Migrate "/var" onto the separate file system/partition.Verify that the SUSE operating system has a separate file system/partition for "/var". @@ -4364,7 +4357,7 @@ Restart the "sshd" service for changes to take effect: KexAlgorithms ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256 -If "KexAlgorithms" is not configured, is commented out, or does not contain only the algorithms "ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256" in exact order, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-15-010375The SUSE operating system must restrict access to the kernel message buffer.<VulnDiscussion>Restricting access to the kernel message buffer limits access only to root. This prevents attackers from gaining additional system information as a nonprivileged user.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001090Configure the operating system to restrict access to the kernel message buffer. +If "KexAlgorithms" is not configured, is commented out, or does not contain only the algorithms "ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256" in exact order, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLES-15-010375The SUSE operating system must restrict access to the kernel message buffer.<VulnDiscussion>Restricting access to the kernel message buffer limits access only to root. This prevents attackers from gaining additional system information as a nonprivileged user.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001090Configure the operating system to restrict access to the kernel message buffer. Set the system to the required kernel parameter by adding or modifying the following line in /etc/sysctl.conf or a config file in the /etc/sysctl.d/ directory: @@ -4431,20 +4424,7 @@ If there is no application installed to perform integrity checks, this is a find If AIDE is installed, check if it has been initialized with the following command: $ sudo aide --check -If the output is "Couldn't open file /var/lib/aide/aide.db for reading", this is a finding.SRG-OS-000123-GPOS-00064<GroupDescription></GroupDescription>SLES-15-020061The SUSE operating system must automatically expire temporary accounts within 72 hours.<VulnDiscussion>Temporary accounts are privileged or nonprivileged accounts that are established during pressing circumstances, such as new software or hardware configuration or an incident response, where the need for prompt account activation requires bypassing normal account authorization procedures. If any inactive temporary accounts are left enabled on the system and are not either manually removed or automatically expired within 72 hours, the security posture of the system will be degraded and exposed to exploitation by unauthorized users or insider threat actors. - -Temporary accounts are different from emergency accounts. Emergency accounts, also known as "last resort" or "break glass" accounts, are local logon accounts enabled on the system for emergency use by authorized system administrators to manage a system when standard logon methods are failing or not available. Emergency accounts are not subject to manual removal or scheduled expiration requirements. - -The automatic expiration of temporary accounts may be extended as needed by the circumstances but it must not be extended indefinitely. A documented permanent account should be established for privileged users who need long-term maintenance accounts.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001682Configure the operating system to expire temporary accounts after 72 hours with the following command: - - > sudo chage -E $(date -d +3days +%Y-%m-%d) <temporary_account_name>Verify temporary accounts have been provisioned with an expiration date of 72 hours. - -For every existing temporary account, run the following command to obtain its account expiration information: - - > sudo chage -l <temporary_account_name> | grep -i "account expires" - -Verify each of these accounts has an expiration date set within 72 hours. -If any temporary accounts have no expiration date set or do not expire within 72 hours, this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>SLES-15-010418The SUSE operating system must be configured to allow sending email notifications of unauthorized configuration changes to designated personnel.<VulnDiscussion>Unauthorized changes to the baseline configuration could make the system vulnerable to various attacks or allow unauthorized access to the operating system. Changes to operating system configurations can have unintended side effects, some of which may be relevant to security. +If the output is "Couldn't open file /var/lib/aide/aide.db for reading", this is a finding.SRG-OS-000363-GPOS-00150<GroupDescription></GroupDescription>SLES-15-010418The SUSE operating system must be configured to allow sending email notifications of unauthorized configuration changes to designated personnel.<VulnDiscussion>Unauthorized changes to the baseline configuration could make the system vulnerable to various attacks or allow unauthorized access to the operating system. Changes to operating system configurations can have unintended side effects, some of which may be relevant to security. Detecting such changes and providing an automated response can help avoid unintended, negative consequences that could ultimately affect the security state of the operating system. The operating system's IMO/ISSO and SAs must be notified via email and/or monitoring system trap when there is an unauthorized modification of a configuration item.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Server 15DISADPMS TargetSUSE Linux Enterprise Server 155274CCI-001744Install the "mailx" package on the system: diff --git a/shared/references/disa-stig-slmicro5-v1r2-xccdf-manual.xml b/shared/references/disa-stig-slmicro5-v1r4-xccdf-manual.xml similarity index 82% rename from shared/references/disa-stig-slmicro5-v1r2-xccdf-manual.xml rename to shared/references/disa-stig-slmicro5-v1r4-xccdf-manual.xml index 5d041d34d222..c9a0f7b34df2 100644 --- a/shared/references/disa-stig-slmicro5-v1r2-xccdf-manual.xml +++ b/shared/references/disa-stig-slmicro5-v1r4-xccdf-manual.xml @@ -1,15 +1,24 @@ -acceptedSUSE Linux Enterprise Micro (SLEM) 5 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 2 Benchmark Date: 02 Jul 20253.51.10.01I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-211010SLEM 5 must be a vendor-supported release.<VulnDiscussion>A SLEM 5 release is considered supported if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Upgrade SLEM 5 to a version supported by the vendor. If the system is not registered with the SUSE Customer Center, register the system against the correct subscription. +acceptedSUSE Linux Enterprise Micro (SLEM) 5 Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 4 Benchmark Date: 01 Apr 20263.5.21.10.01I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Public<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Classified<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>II - Mission Support Sensitive<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Public<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-211010SLEM 5 must be a vendor-supported release.<VulnDiscussion>A SLEM 5 release is considered supported if the vendor continues to provide security patches for the product. With an unsupported release, it will not be possible to resolve security issues discovered in the system software. -If the system requires Long-Term Service Pack Support (LTSS), obtain the correct LTSS subscription for the system.Verify that the version of SLEM 5 is vendor supported with the following command: +End Of Life dates for SUSE Linux Micro releases are as follows: +Service Pack Release Release Date General Support Ends +SUSE Linux Micro 5.0 30 Mar 2021 31 Mar 2022 +SUSE Linux Micro 5.1 26 Oct 2021 31 Oct 2025 +SUSE Linux Micro 5.2 14 Apr 2022 30 Apr 2026 +SUSE Linux Micro 5.3 25 Oct 2022 30 Oct 2026 +SUSE Linux Micro 5.4 20 Apr 2023 30 Apr 2027 +SUSE Linux Micro 5.5 12 Oct 2023 31 Oct 2027 +SUSE Linux Micro 6.0 06 Jun 2024 30 Jun 2028 +SUSE Linux Micro 6.1 26 Nov 2024 30 Nov 2028</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Upgrade SLEM 5 to a version supported by the vendor. If the system is not registered with the SUSE Customer Center, register the system against the correct subscription. + +If the system requires Long-Term Service Pack Support (LTSS), obtain the correct LTSS subscription for the system.Verify the version of SLEM 5 is vendor supported with the following command: > cat /etc/os-release NAME="SLE Micro" - VERSION="5.2" + VERSION="5.5" ... -If the installed version of SLEM 5 is not supported, this is a finding.SRG-OS-000191-GPOS-00080<GroupDescription></GroupDescription>SLEM-05-211015SLEM 5 must implement an endpoint security tool.<VulnDiscussion>Adding endpoint security tools can provide the capability to automatically take actions in response to malicious behavior, which can provide additional agility in reacting to network threats. These tools also often include a reporting capability to provide network awareness of the system, which may not otherwise exist in an organization's systems management regime.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001233Install and enable an endpoint security tool.Verify that SLEM 5 has implemented an endpoint security tool. - -If no endpoint security tool is present and enabled on the system, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLEM-05-211020SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner before granting any local or remote connection to the system.<VulnDiscussion>Display of a standardized and approved use notification before granting access to SLEM 5 ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. +If the installed version of SLEM 5 is not supported, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLEM-05-211020SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner before granting any local or remote connection to the system.<VulnDiscussion>Display of a standardized and approved use notification before granting access to SLEM 5 ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. System use notifications are required only for access via logon interfaces with human users and are not required when such human interfaces do not exist. @@ -79,7 +88,7 @@ Then, reload the daemon to take effect: Loaded: masked (Reason: Unit ctrl-alt-del.target is masked.) Active: inactive (dead) -If ctrl-alt-del.target is not masked, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLEM-05-212010SLEM 5 with a basic input/output system (BIOS) must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. +If ctrl-alt-del.target is not masked, this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLEM-05-212010SLEM 5 with a basic input/output system (BIOS) must require authentication upon booting into single-user and maintenance modes.<VulnDiscussion>To mitigate the risk of unauthorized access to sensitive information by entities that have been issued certificates by DOD-approved PKIs, all DOD systems (e.g., web servers and web portals) must be properly configured to incorporate access control methods that do not rely solely on the possession of a certificate for access. Successful authentication must not automatically give an entity access to an asset or security boundary. Authorization procedures and controls must be implemented to ensure each authenticated entity also has a validated and current authorization. Authorization is the process of determining whether an entity, once authenticated, is permitted to access a specific asset. Information systems use access control policies and enforcement mechanisms to implement this requirement. Access control policies include identity-based policies, role-based policies, and attribute-based policies. Access enforcement mechanisms include access control lists, access control matrices, and cryptography. These policies and mechanisms must be employed by the application to control access between users (or processes acting on behalf of users) and objects (e.g., devices, files, records, processes, programs, and domains) in the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000213Note: If the system does not use a BIOS, this requirement is not applicable. @@ -108,9 +117,9 @@ Verify that SLEM 5 has set an encrypted root password with the following command > sudo cat /boot/grub2/grub.cfg | grep -i password password_pbkdf2 root grub.pbkdf2.sha512.10000.03255F190F0E2F7B4F0D1C3216012309162F022A7A636771 -If the root password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLEM-05-212015SLEM 5 with Unified Extensible Firmware Interface (UEFI) implemented must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system allows a user to boot into single-user or maintenance mode without authentication, any user that invokes single-user or maintenance mode is granted privileged access to all system information.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000213Note: If the system does not use UEFI, this requirement is not applicable. +If the root password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000080-GPOS-00048<GroupDescription></GroupDescription>SLEM-05-212015SLEM 5 with Unified Extensible Firmware Interface (UEFI) implemented must require authentication upon booting into single-user mode and maintenance.<VulnDiscussion>If the system allows a user to boot into single-user or maintenance mode without authentication, any user that invokes single-user or maintenance mode is granted privileged access to all system information.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000213Note: If the system does not use UEFI, this requirement is not applicable. -Configure SLEM 5 to encrypt the boot password. +Configure SLEM 5 to encrypt the GRUB bootloader password. Generate an encrypted GRUB bootloader password for root with the following command: @@ -121,21 +130,21 @@ Generate an encrypted GRUB bootloader password for root with the following comma Using the hash from the output, modify the "/etc/grub.d/40_custom" file and add the following two lines to add a boot password for the root entry: - set superusers="rooty" + set superusers="root" password_pbkdf2 root grub.pbkdf2.sha512.03255F190F0E2F7B4F0D1C3216012309162F022A7A636771 Generate an updated "grub.conf" file with the new password using the following commands: > sudo grub2-mkconfig --output=/tmp/grub2.cfg - > sudo mv /tmp/grub2.cfg /boot/efi/EFI/BOOT/grub.cfgNote: If the system does not use UEFI, this requirement is not applicable. + > sudo mv /tmp/grub2.cfg /boot/efi/EFI/BOOT/grub.cfgNote: If the system does not use UEFI, this requirement is not applicable. -Verify that SLEM 5 has set an encrypted root password with the following command: +Verify that SLEM 5 has set an encrypted GRUB bootloader password with the following command: > sudo cat /boot/efi/EFI/BOOT/grub.cfg | grep -i password password_pbkdf2 root grub.pbkdf2.sha512.10000.03255F190F0E2F7B4F0D1C3216012309162F022A7A636771 -If the root password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLEM-05-213010SLEM 5 must restrict access to the kernel message buffer.<VulnDiscussion>Restricting access to the kernel message buffer limits access only to root. This prevents attackers from gaining additional system information as a nonprivileged user.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001090Configure SLEM 5 to restrict access to the kernel message buffer. +If the GRUB bootloader password entry does not begin with "password_pbkdf2", this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLEM-05-213010SLEM 5 must restrict access to the kernel message buffer.<VulnDiscussion>Restricting access to the kernel message buffer limits access only to root. This prevents attackers from gaining additional system information as a nonprivileged user.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001090Configure SLEM 5 to restrict access to the kernel message buffer. Set the system to the required kernel parameter by adding or modifying the following line in /etc/sysctl.conf or a config file in the /etc/sysctl.d/ directory: @@ -235,20 +244,21 @@ If the patch repository data is corrupt, check that the available package securi 2023-09-25 12:23:26 | install | cockpit-storaged | 298-150500.1.4 2023-09-25 12:23:26 | install | cockpit-selinux | 298-150500.1.4 -If SLEM 5 has not been patched within the site or PMO frequency, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>SLEM-05-214015The SLEM 5 tool zypper must have gpgcheck enabled.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of SLEM 5. This requirement ensures the software has not been tampered with and has been provided by a trusted vendor. +If SLEM 5 has not been patched within the site or PMO frequency, this is a finding.SRG-OS-000366-GPOS-00153<GroupDescription></GroupDescription>SLEM-05-214015The SLEM 5 tool zypper must have gpgcheck enabled.<VulnDiscussion>Changes to any software components can have significant effects on the overall security of SLEM 5. This requirement ensures the software has not been tampered with and has been provided by a trusted vendor. Accordingly, patches, service packs, device drivers, or SLEM 5 components must be signed with a certificate recognized and approved by the organization. -Verifying the authenticity of the software prior to installation validates the integrity of the patch or upgrade received from a vendor. This ensures the software has not been tampered with and that it has been provided by a trusted vendor. Self-signed certificates are disallowed by this requirement. SLEM 5 should not have to verify the software again. This requirement does not mandate DOD certificates for this purpose; however, the certificate used to verify the software must be from an approved Certification Authority (CA).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001749Configure that SLEM 5 tool zypper to enable gpgcheck. +Verifying the authenticity of the software prior to installation validates the integrity of the patch or upgrade received from a vendor. This ensures the software has not been tampered with and that it has been provided by a trusted vendor. Self-signed certificates are disallowed by this requirement. SLEM 5 should not have to verify the software again. This requirement does not mandate DOD certificates for this purpose; however, the certificate used to verify the software must be from an approved Certification Authority (CA). -Add or modify the following line in the "/etc/zypp/zypp.conf" file: - -gpgcheck = onVerify that SLEM 5 tool zypper has gpgcheck enabled with the following command: +For zypper on SUSE Linux Enterprise systems, GPG signature checking is enabled by default for all repositories, even if it's not explicitly set in /etc/zypp/zypp.conf or individual .repo files. The presence of the gpgcheck setting in repository files (like gpgcheck=1) or a global zypp.conf entry would override this default behavior if the user wanted to disable it (e.g., gpgcheck=0), but its absence simply means the default is in effect.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001749Configure the SLEM 5 tool zypper to enable gpgcheck. + +Add or modify the following line in the "/etc/zypp/zypp.conf" file or remove the line completely, ensuring the default zypper setting is enabled: + +gpgcheck = onVerify the SLEM 5 tool zypper has gpgcheck enabled with the following command: > grep -i '^gpgcheck' /etc/zypp/zypp.conf - gpgcheck = on -If "gpgcheck" is not set to "on", is commented out, or missing, this is a finding.SRG-OS-000437-GPOS-00194<GroupDescription></GroupDescription>SLEM-05-214020SLEM 5 must remove all outdated software components after updated versions have been installed.<VulnDiscussion>Previous versions of software components that are not removed from the information system after updates have been installed may be exploited by adversaries. Some information technology products may remove older versions of software automatically from the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-002617Configure SLEM 5 to remove all outdated software components after an update. +If "gpgcheck" is set to "off", this is a finding.SRG-OS-000437-GPOS-00194<GroupDescription></GroupDescription>SLEM-05-214020SLEM 5 must remove all outdated software components after updated versions have been installed.<VulnDiscussion>Previous versions of software components that are not removed from the information system after updates have been installed may be exploited by adversaries. Some information technology products may remove older versions of software automatically from the information system.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-002617Configure SLEM 5 to remove all outdated software components after an update. Add or modify the following line in the "/etc/zypp/zypp.conf" file: @@ -284,14 +294,14 @@ Check that the telnet-server package is not installed on SLEM 5 by running the f > sudo zypper se telnet-server | grep Installed -If the telnet-server package is installed, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-231010A separate file system must be used for SLEM 5 user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Create a separate file system/partition for SLEM 5 nonprivileged local interactive user home directories. +If the telnet-server package is installed, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-231010A separate file system must be used for SLEM 5 user home directories (such as /home or an equivalent).<VulnDiscussion>The use of separate file systems for different paths can protect the system from failures resulting from a file system becoming full or failing.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Create a separate file system/partition for SLEM 5 nonprivileged local interactive user home directories. -Migrate the nonprivileged local interactive user home directories onto the separate file system/partition.Verify that a separate file system/partition has been created for SLEM 5 nonprivileged local interactive users (those with a UID greater than 1000) home directories with the following command: +Migrate the nonprivileged local interactive user home directories onto the separate file system/partition.Verify that a separate file system/partition has been created for SLEM 5 nonprivileged local interactive users (those with a UID greater than 1000) home directories with the following command: > awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $3, $6, $7}' /etc/passwd - adamsj 1002 /home/adamsj /bin/bash - jacksonm 1003 /home/jacksonm /bin/bash - smithj 1001 /home/smithj /bin/bash + disauser 1002 /home/disauser /bin/bash + dosuser 1003 /home/dosuser /bin/bash + dosuser 1001 /home/dosuser /bin/bash The output of the command will give the directory/partition that contains the home directories for the nonprivileged users on the system (in this example, /home) and user's shell. All accounts with a valid shell (such as /bin/bash) are considered interactive users. @@ -333,47 +343,47 @@ If a file system found in "/etc/fstab" refers to NFS and it does not have the "n > more /etc/fstab UUID=2bc871e4-e2a3-4f29-9ece-3be60c835222 /mnt/usbflash vfat noauto,owner,ro,nosuid 0 0 -If a file system found in "/etc/fstab" refers to removable media and does not have the "nosuid" option set, this is a finding.SRG-OS-000185-GPOS-00079<GroupDescription></GroupDescription>SLEM-05-231040All SLEM 5 persistent disk partitions must implement cryptographic mechanisms to prevent unauthorized disclosure or modification of all information that requires at-rest protection.<VulnDiscussion>SLEM 5 handling data requiring data-at-rest protections must employ cryptographic mechanisms to prevent unauthorized disclosure and modification of the information at rest. +If a file system found in "/etc/fstab" refers to removable media and does not have the "nosuid" option set, this is a finding.SRG-OS-000185-GPOS-00079<GroupDescription></GroupDescription>SLEM-05-231040All SLEM 5 persistent disk partitions must implement cryptographic mechanisms to prevent unauthorized disclosure or modification of all information that requires at-rest protection.<VulnDiscussion>SLEM 5 handling data requiring data-at-rest protections must employ cryptographic mechanisms to prevent unauthorized disclosure and modification of the information at rest. -Selection of a cryptographic mechanism is based on the need to protect the integrity of organizational information. The strength of the mechanism is commensurate with the security category and/or classification of the information. Organizations have the flexibility to either encrypt all information on storage devices (i.e., full disk encryption) or encrypt specific data structures (e.g., files, records, or fields).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001199CCI-002475CCI-002476Configure SLEM 5 to prevent unauthorized modification of all information at rest by using disk encryption. +Selection of a cryptographic mechanism is based on the need to protect the integrity of organizational information. The strength of the mechanism is commensurate with the security category and/or classification of the information. Organizations have the flexibility to either encrypt all information on storage devices (i.e., full disk encryption) or encrypt specific data structures (e.g., files, records, or fields).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001199CCI-002475CCI-002476Configure SLEM 5 to prevent unauthorized modification of all information at rest by using disk encryption. Encrypting a partition in an already-installed system is more difficult because of the need to resize and change existing partitions. To encrypt an entire partition, dedicate a partition for encryption in the partition layout. The standard partitioning proposal as suggested by YaST (installation and configuration tool for Linux) does not include an encrypted partition by default. Add it manually in the partitioning dialog. The following set of commands will switch SLEM 5 to work in FIPS mode: - >sudo transactional-update pkg install -t pattern microos-fips + > sudo transactional-update pkg install -t pattern microos-fips - >reboot + > reboot - Add of modify the following line in the "/etc/default/grub" file to include "fips=1": +Add or modify the following line in the "/etc/default/grub" file to include "fips=1": GRUB_CMDLINE_LINUX_DEFAULT="splash=silent swapaccount=1 apparmor=0 mitigations=auto quiet crashkernel=195M,high crashkernel=72M,low fips=1" - >sudo transactional-update grub.cfg + > sudo transactional-update grub.cfg - >sudo reboot:Verify SLEM 5 prevents unauthorized disclosure or modification of all information requiring at-rest protection by using disk encryption. - -Verify the system partitions are all encrypted with the following commands: - - > sudo blkid - /dev/sda1: "UUID=26d4a101-7f48-4394-b730-56dc00e65f64" TYPE="crypto_LUKS" - /dev/sda2: "UUID=f5b8a790-14cb-4b82-882d-707d52f27765" TYPE="crypto_LUKS" - /dev/sda3: "UUID=f2d86128-f975-478d-a5b0-25806c900eac" TYPE="crypto_LUKS" - -Every persistent disk partition present must be of type "crypto_LUKS". If any partitions other than the boot partition or pseudo file systems (such as /proc or /sys) or temporary file systems (that are tmpfs) are not type "crypto_LUKS", ask the administrator to indicate how the partitions are encrypted. If there is no evidence that these partitions are encrypted, this is a finding. - - > sudo more /etc/crypttab - cr_root UUID=26d4a101-7f48-4394-b730-56dc00e65f64 - cr_home UUID=f5b8a790-14cb-4b82-882d-707d52f27765 - cr_swap UUID=f2d86128-f975-478d-a5b0-25806c900eac - -Every persistent disk partition present on the system must have an entry in the /etc/crypttab file. - -If any partitions other than pseudo file systems (such as /proc or /sys) are not listed or "/etc/crypttab" does not exist, this is a finding. - -Verify the system works in FIPS mode with the following command: - - > sudo sysctl - a | grep fips + > sudo rebootVerify SLEM 5 prevents unauthorized disclosure or modification of all information requiring at-rest protection by using disk encryption. + +Verify the system partitions are all encrypted with the following commands: + + > sudo blkid + /dev/sda1: "UUID=26d4a101-7f48-4394-b730-56dc00e65f64" TYPE="crypto_LUKS" + /dev/sda2: "UUID=f5b8a790-14cb-4b82-882d-707d52f27765" TYPE="crypto_LUKS" + /dev/sda3: "UUID=f2d86128-f975-478d-a5b0-25806c900eac" TYPE="crypto_LUKS" + +Every persistent disk partition present must be of type "crypto_LUKS". If any partitions other than the boot partition or pseudo file systems (such as /proc or /sys) or temporary file systems (that are tmpfs) are not type "crypto_LUKS", ask the administrator to indicate how the partitions are encrypted. If there is no evidence that these partitions are encrypted, this is a finding. + + > sudo more /etc/crypttab + cr_root UUID=26d4a101-7f48-4394-b730-56dc00e65f64 + cr_home UUID=f5b8a790-14cb-4b82-882d-707d52f27765 + cr_swap UUID=f2d86128-f975-478d-a5b0-25806c900eac + +Every persistent disk partition present on the system must have an entry in the /etc/crypttab file. + +If any partitions other than pseudo file systems (such as /proc or /sys) are not listed or "/etc/crypttab" does not exist, this is a finding. + +Verify the system works in FIPS mode with the following command: + + > sudo sysctl -a | grep fips crypto.fips_enabled = 1SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-231045SLEM 5 file systems that contain user home directories must be mounted to prevent files with the setuid and setgid bit set from being executed.<VulnDiscussion>The "nosuid" mount option causes the system to not execute setuid and setgid files with owner privileges. This option must be used for mounting any file system not containing approved setuid and setguid files. Executing files from untrusted file systems increases the opportunity for unprivileged users to attain unauthorized administrative access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Configure SLEM 5 "/etc/fstab" file to use the "nosuid" option on file systems that contain user home directories for interactive users. Remount the filesystems. @@ -387,15 +397,13 @@ Print the currently active file system mount options of the file system(s) that If a file system containing user home directories is not mounted with the FSTYPE OPTION nosuid, this is a finding. -Note: If a separate file system has not been created for the user home directories (user home directories are mounted under "/"), this is not a finding as the "nosuid" option cannot be used on the "/" system.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>SLEM-05-231050SLEM 5 must disable the file system automounter unless required.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000778Configure SLEM 5 to disable the ability to automount devices. +Note: If a separate file system has not been created for the user home directories (user home directories are mounted under "/"), this is not a finding as the "nosuid" option cannot be used on the "/" system.SRG-OS-000114-GPOS-00059<GroupDescription></GroupDescription>SLEM-05-231050SLEM 5 must disable the file system automounter.<VulnDiscussion>Automatically mounting file systems permits easy introduction of unknown devices, thereby facilitating malicious activity.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000778Configure SLEM 5 to disable the ability to automount devices. Turn off the automount service with the following command: > sudo systemctl stop autofs - > sudo systemctl disable autofs - -If "autofs" is required for Network File System (NFS), it must be documented with the ISSO.Verify SLEM 5 disables the ability to automount devices. + > sudo systemctl disable autofsVerify SLEM 5 disables the ability to automount devices. Verify the automounter service is installed with the following command: @@ -408,38 +416,43 @@ If it is installed, verify the automounter service is active with the following Loaded: loaded (/usr/lib/systemd/system/autofs.service; disabled) Active: inactive (dead) -If the "autofs" status is set to "active" and is not documented with the information system security officer (ISSO) as an operational requirement, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232010SLEM 5 must have directories that contain system commands set to a mode of 755 or less permissive.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If the "autofs" status is set to "active" this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232010SLEM 5 must have directories that contain system commands set to a mode of 755 or less permissive.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system command directories to be protected from unauthorized access. - > sudo find -L /usr/local/bin /usr/local/sbin -perm /022 -type f -exec chmod 755 '{}' \; - > sudo transactional-update shell - > sudo find -L /bin /sbin /usr/bin /usr/sbin -perm /022 -type f -exec chmod 755 '{}' \; - > exit - > sudo rebootVerify that the system command directories have mode "755" or less permissive with the following command: +Run the following command, replacing "[DIRECTORY]" with any library directory with a mode more permissive than 755: + +> sudo chmod 755 [DIRECTORY]Verify the system command directories have mode "755" or less permissive with the following command: + + > find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin -type d -exec stat -c "%n %a" '{}' \; - > find -L /usr/local/bin /usr/local/sbin -perm /022 -type d -exec stat -c "%n %a" '{}' \; +If any directories are found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232015SLEM 5 must have system commands set to a mode of 755 or less permissive.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -If any directories are found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232015SLEM 5 must have system commands set to a mode of 755 or less permissive.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: +If the command requiring a permissions change resides in /usr/local/bin or /usr/local/sbin run the following command: > sudo find -L /usr/local/bin /usr/local/sbin -perm /022 -type f -exec chmod 755 '{}' \; + +If the command requiring a permissions change resides in /bin, /sbin, /usr/bin, /or usr/sbin run the following commands: + > sudo transactional-update shell > sudo find -L /bin /sbin /usr/bin /usr/sbin -perm /022 -type f -exec chmod 755 '{}' \; > exit - > sudo rebootVerify that the system command directories have mode "755" or less permissive with the following command: + > sudo rebootVerify that the system commands have mode "755" or less permissive with the following command: - > find -L /usr/local/bin /usr/local/sbin -perm /022 -type d -exec stat -c "%n %a" '{}' \; + > find -L /usr/local/bin /usr/local/sbin -perm /022 -type f -exec stat -c "%n %a" '{}' \; -If any directories are found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232020SLEM 5 library directories must have mode 755 or less permissive.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any files are found to be group-writable or world-writable, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232020SLEM 5 library directories must have mode 755 or less permissive.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the library files to be protected from unauthorized access. Run the following command: +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the library directories to be protected from unauthorized access. + +Run the following commands: > sudo transactional-update shell - > sudo find /lib /lib64 /usr/lib /usr/lib64 -perm /022 -type f -exec chmod 755 '{}' \; + > sudo find /lib /lib64 /usr/lib /usr/lib64 -perm /022 -type d -exec chmod 755 '{}' \; > exit - > sudo rebootVerify the system-wide shared library directories "/lib", "/lib64", "/usr/lib" and "/usr/lib64" have mode "755" or less permissive with the following command: + > sudo rebootVerify the system-wide shared library directories "/lib", "/lib64", "/usr/lib" and "/usr/lib64" have mode "755" or less permissive with the following command: > sudo find /lib /lib64 /usr/lib /usr/lib64 -perm /022 -type d -exec stat -c "%n %a" '{}' \; @@ -456,29 +469,29 @@ Check that the systemwide shared library files have mode 0755 or less permissive > sudo find /lib /lib64 /usr/lib /usr/lib64 -type f -name '*.so*' -perm /022 -exec stat -c "%n %a" {} + -If any output is returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232030All SLEM 5 local interactive user home directories must have mode 750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Change the mode of SLEM 5 local interactive user's home directories to "750". To change the mode of a local interactive user's home directory, use the following command: +If any output is returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232030All SLEM 5 local interactive user home directories must have mode 750 or less permissive.<VulnDiscussion>Excessive permissions on local interactive user home directories may allow unauthorized access to user files by other users.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Change the mode of SLEM 5 local interactive user's home directories to "750". To change the mode of a local interactive user's home directory, use the following command: -Note: The example will be for the user "smithj". +Note: The example will be for the user "dosuser". - > sudo chmod 750 /home/smithjNote: This may miss interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. + > sudo chmod 750 /home/dosuserNote: This may miss interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. Verify the assigned home directory of all SLEM 5 local interactive users has a mode of "750" or less permissive with the following command: > ls -ld $(awk -F: '($3>=1000)&&($7 !~ /nologin/){print $6}' /etc/passwd) - -rwxr-x--- 1 smithj users 18 Mar 5 17:6 /home/smithj + -rwxr-x--- 1 dosuser users 18 Mar 5 17:6 /home/dosuser -If home directories referenced in "/etc/passwd" do not have a mode of "750" or less permissive, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232035All SLEM 5 local initialization files must have mode 740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Set the mode of SLEM 5 local initialization files to "740" with the following command: +If home directories referenced in "/etc/passwd" do not have a mode of "750" or less permissive, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232035All SLEM 5 local initialization files must have mode 740 or less permissive.<VulnDiscussion>Local initialization files are used to configure the user's shell environment upon logon. Malicious modification of these files could compromise accounts upon logon.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Set the mode of SLEM 5 local initialization files to "740" with the following command: -Note: The example will be for the smithj user, who has a home directory of "/home/smithj". +Note: The example will be for the dosuser user, who has a home directory of "/home/dosuser". - > sudo chmod 740 /home/smithj/.<INIT_FILE>Verify that all SLEM 5 local initialization files have a mode of "740" or less permissive with the following command: + > sudo chmod 740 /home/dosuser/.<INIT_FILE>Verify that all SLEM 5 local initialization files have a mode of "740" or less permissive with the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj". +Note: The example will be for the user "dosuser", who has a home directory of "/home/dosuser". - > sudo ls -al /home/smithj/.* | more - -rw-r-x---- 1 smithj users 896 Mar 10 2011 .profile - -rw-r-x---- 1 smithj users 497 Jan 6 27 .login - -rw-r-x---- 1 smithj users 886 Jan 6 27 .something + > sudo ls -al /home/dosuser/.* | more + -rw-r-x---- 1 dosuser users 896 Mar 10 2011 .profile + -rw-r-x---- 1 dosuser users 497 Jan 6 27 .login + -rw-r-x---- 1 dosuser users 886 Jan 6 27 .something If any local initialization files have a mode more permissive than "740", this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232040SLEM 5 SSH daemon public host key files must have mode 644 or less permissive.<VulnDiscussion>If a public host key file is modified by an unauthorized user, the SSH service may be compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Configure SLEM 5 SSH daemon public host key files have mode "644" or less permissive. @@ -556,49 +569,49 @@ This requirement applies to SLEM 5 with software libraries that are accessible a > sudo find /lib /lib64 /usr/lib /usr/lib64 ! -group root -type d -exec stat -c "%n %G" '{}' \; -If any system wide library directory is returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232070SLEM 5 must have system commands owned by root.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any system wide library directory is returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232070SLEM 5 must have system commands owned by root.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: > sudo transactional-update shell - > sudo find -L /bin /sbin /usr/bin /usr/sbin ! -user root -type f -exec chown root '{}' \; + > sudo find -L /bin /sbin /usr/bin /usr/sbin /bin /sbin /usr/bin /usr/sbin ! -user root -type f -exec chown root '{}' \; > exit - > sudo rebootVerify that the system commands are owned by root with the following command: + > sudo rebootVerify that the system commands are owned by root with the following command: - > sudo find -L /usr/local/bin /usr/local/sbin ! -user root -type f -exec stat -c "%n %U" '{}' \; + > sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -user root -type f -exec stat -c "%n %U" '{}' \; -If any system commands are returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232075SLEM 5 must have system commands group-owned by root or a system account.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any system commands are returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232075SLEM 5 must have system commands group-owned by root or a system account.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: > sudo transactional-update shell - > sudo find -L /bin /sbin /usr/bin /usr/sbin ! -user root -type f -exec chown root '{}' \; + > sudo find -L /bin /sbin /usr/bin /usr/sbin /bin /sbin /usr/bin /usr/sbin ! -user root -type f -exec chgrp root '{}' \; > exit - > sudo rebootVerify that the system commands are group-owned by root with the following command: + > sudo rebootVerify the system commands are group-owned by root with the following command: - > sudo find -L /usr/local/bin /usr/local/sbin! -group root -type f -exec stat -c "%n %G" '{}' \; + > sudo find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -group root -type f -exec stat -c "%n %G" '{}' \; -If any system commands are returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232080SLEM 5 must have directories that contain system commands owned by root.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any system commands are returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232080SLEM 5 must have directories that contain system commands owned by root.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: > sudo transactional-update shell - > sudo find -L /bin /sbin /usr/bin /usr/sbin ! -user root -type d -exec chown root '{}' \; + > sudo find -L /bin /sbin /usr/bin /usr/sbin /bin /sbin /usr/bin /usr/sbin ! -user root -type d -exec chown root '{}' \; > exit - > sudo rebootVerify that the system command directories are owned by root with the following command: + > sudo rebootVerify the system command directories are owned by root with the following command: - > find -L /usr/local/bin /usr/local/sbin ! -user root -type d -exec stat -c "%n %U" '{}' \; + > find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -user root -type d -exec stat -c "%n %U" '{}' \; -If any system command directories are returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232085SLEM 5 must have directories that contain system commands group-owned by root.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. +If any system command directories are returned, this is a finding.SRG-OS-000259-GPOS-00100<GroupDescription></GroupDescription>SLEM-05-232085SLEM 5 must have directories that contain system commands group-owned by root.<VulnDiscussion>If SLEM 5 were to allow any user to make changes to software libraries, then those changes might be implemented without undergoing the appropriate testing and approvals that are part of a robust change management process. -This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: +This requirement applies to SLEM 5 with software libraries that are accessible and configurable, as in the case of interpreted languages. Software libraries also include privileged programs which execute with escalated privileges. Only qualified and authorized individuals must be allowed to obtain access to information system components for purposes of initiating changes, including upgrades and modifications.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001499Configure the system commands to be protected from unauthorized access. Run the following command: > sudo transactional-update shell - > sudo find -L /bin /sbin /usr/bin /usr/sbin ! -group root -type d -exec chgrp root '{}' \; + > sudo find -L /bin /sbin /usr/bin /usr/sbin /bin /sbin /usr/bin /usr/sbin ! -group root -type d -exec chgrp root '{}' \; > exit - > sudo rebootVerify that the system command directories are group-owned by root with the following command: + > sudo rebootVerify the system command directories are group-owned by root with the following command: - > find -L /usr/local/bin /usr/local/sbin ! -group root -type d -exec stat -c "%n %G" '{}' \; + > find -L /bin /sbin /usr/bin /usr/sbin /usr/local/bin /usr/local/sbin ! -group root -type d -exec stat -c "%n %G" '{}' \; If any system command directories are returned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232090All SLEM 5 files and directories must have a valid owner.<VulnDiscussion>Unowned files and directories may be unintentionally inherited if a user is assigned the same User Identifier (UID) as the UID of the unowned files.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Either remove all files and directories from SLEM 5 that do not have a valid user or assign a valid user to all unowned files and directories on the system with the "chown" command: @@ -616,21 +629,21 @@ Note: The value after -fstype must be replaced with the filesystem type. XFS is > sudo find / -fstype xfs -nogroup -If any files on the system do not have a valid group, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232100All SLEM 5 local interactive user home directories must be group-owned by the home directory owner's primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user's home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user's files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Change the group owner of a SLEM 5 local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: +If any files on the system do not have a valid group, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232100All SLEM 5 local interactive user home directories must be group-owned by the home directory owner's primary group.<VulnDiscussion>If the Group Identifier (GID) of a local interactive user's home directory is not the same as the primary GID of the user, this would allow unauthorized access to the user's files, and users that share the same group may not be able to access files that they legitimately should.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Change the group owner of a SLEM 5 local interactive user's home directory to the group found in "/etc/passwd". To change the group owner of a local interactive user's home directory, use the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj", and has a primary group of users. +Note: The example will be for the user "dosuser", who has a home directory of "/home/dosuser", and has a primary group of users. - > sudo chgrp users /home/smithjVerify the assigned home directory of all SLEM 5 local interactive users is group-owned by that user's primary GID with the following command: + > sudo chgrp users /home/dosuserVerify the assigned home directory of all SLEM 5 local interactive users is group-owned by that user's primary GID with the following command: -Note: This may miss local interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/smithj" is used as an example. +Note: This may miss local interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. The returned directory "/home/dosuser" is used as an example. > awk -F: '($3>=1000)&&($7 !~ /nologin/){print $4, $6}' /etc/passwd) - 250:/home/smithj + 250:/home/dosuser Check the user's primary group with the following command: > grep users /etc/group - users:x:250:smithj,jonesj,jacksons + users:x:250:dosuser,dosuser,nsauser If the user home directory referenced in "/etc/passwd" is not group-owned by that user's primary GID, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-232105All SLEM 5 world-writable directories must be group-owned by root, sys, bin, or an application group.<VulnDiscussion>If a world-writable directory has the sticky bit set and is not group-owned by a privileged Group Identifier (GID), unauthorized users may be able to modify files created by others. @@ -643,7 +656,7 @@ The only authorized public directories are those temporary directories supplied drwxrwxrwt. 2 root root 220 Aug 26 13:23 /dev/shm drwxrwxrwt. 14 root root 4096 Aug 26 13:29 /tmp -If any world-writable directories are not owned by root, sys, bin, or an application group associated with the directory, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLEM-05-232110The sticky bit must be set on all SLEM 5 world-writable directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, and hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. +If any world-writable directories are not owned by root, sys, bin, or an application group associated with the directory, this is a finding.SRG-OS-000138-GPOS-00069<GroupDescription></GroupDescription>SLEM-05-232110The sticky bit must be set on all SLEM 5 world-writable directories.<VulnDiscussion>Preventing unauthorized information transfers mitigates the risk of information, including encrypted representations of information, produced by the actions of prior users/roles (or the actions of processes acting on behalf of prior users/roles) from being available to any current users/roles (or current processes) that obtain access to shared system resources (e.g., registers, main memory, and hard disks) after those resources have been released back to information systems. The control of information in shared resources is also commonly referred to as object reuse and residual information protection. This requirement generally applies to the design of an information technology product, but it can also apply to the configuration of particular information system components that are, or use, such products. This can be verified by acceptance/validation processes in DOD or other government agencies. @@ -970,36 +983,40 @@ For the changes to take effect immediately, start the service with the following > systemctl status sshd.service | grep -i active Active: active (running) since Wed 2023-11-29 09:49:45 MST; 2 months 23 days ago -If "openssh.service" is not active, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLEM-05-255020SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner before granting access via SSH.<VulnDiscussion>Display of a standardized and approved use notification before granting access to SLEM 5 ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. - -System use notifications are required only for access via logon interfaces with human users and are not required when such human interfaces do not exist. - -The banner must be formatted in accordance with applicable DOD policy. Use the following verbiage for SLEM 5 that can accommodate banners of 1300 characters: - -"You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. - -By using this IS (which includes any device attached to this IS), you consent to the following conditions: - --The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations. - --At any time, the USG may inspect and seize data stored on this IS. - --Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose. - --This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy. - --Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details."</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000048Add or modify the following line in the "/etc/ssh/sshd_config" file: +If "openssh.service" is not active, this is a finding.SRG-OS-000023-GPOS-00006<GroupDescription></GroupDescription>SLEM-05-255020SLEM 5 must display the Standard Mandatory DOD Notice and Consent Banner before granting access via SSH.<VulnDiscussion>Display of a standardized and approved use notification before granting access to SLEM 5 ensures privacy and security notification verbiage used is consistent with applicable federal laws, Executive Orders, directives, policies, regulations, standards, and guidance. + +System use notifications are required only for access via logon interfaces with human users and are not required when such human interfaces do not exist. + +Because SLEM 5 employs an immutable architecture and "/etc/issue" is a system file, the banner must be stored in a different location. In this example, the location is "/etc/ssh/dod_banner", but any nonsystem location is acceptable. + +The banner must be formatted in accordance with applicable DOD policy. Use the following verbiage for SLEM 5 that can accommodate banners of 1300 characters: + +"You are accessing a U.S. Government (USG) Information System (IS) that is provided for USG-authorized use only. + +By using this IS (which includes any device attached to this IS), you consent to the following conditions: + +-The USG routinely intercepts and monitors communications on this IS for purposes including, but not limited to, penetration testing, COMSEC monitoring, network operations and defense, personnel misconduct (PM), law enforcement (LE), and counterintelligence (CI) investigations. + +-At any time, the USG may inspect and seize data stored on this IS. + +-Communications using, or data stored on, this IS are not private, are subject to routine monitoring, interception, and search, and may be disclosed or used for any USG-authorized purpose. + +-This IS includes security measures (e.g., authentication and access controls) to protect USG interests--not for your personal benefit or privacy. + +-Notwithstanding the above, using this IS does not constitute consent to PM, LE or CI investigative searching or monitoring of the content of privileged communications, or work product, related to personal representation or services by attorneys, psychotherapists, or clergy, and their assistants. Such communications and work product are private and confidential. See User Agreement for details."</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000048Add or modify the following line in the "/etc/ssh/sshd_config" file: -Banner /etc/issue/ +Banner /etc/ssh/dod_banner -Restart the "sshd.service": +Restart the "sshd.service" to use the new file location: - > sudo systemctl restart sshd.serviceVerify SLEM 5 displays the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via SSH with the following command: + > sudo systemctl restart sshd.serviceVerify SLEM 5 displays the Standard Mandatory DOD Notice and Consent Banner before granting access to the system via SSH with the following command: > sudo /usr/sbin/sshd -dd 2>&1 | awk '/filename/ {print $4}' | tr -d '\r' | tr '\n' ' ' | xargs sudo grep -iH '^\s*banner' - /etc/ssh/sshd_config:Banner /etc/issue + /etc/ssh/sshd_config:Banner /etc/ssh/dod_banner + +If "Banner" is commented out or missing, or if the location returned will be overridden by package updates, this is a finding. -If "Banner" is not set to "/etc/issue", is commented out, missing, or conflicting results are returned, this is a finding.SRG-OS-000480-GPOS-00229<GroupDescription></GroupDescription>SLEM-05-255025SLEM 5 must not allow unattended or automatic logon via SSH.<VulnDiscussion>Failure to restrict system access via SSH to authenticated users negatively impacts SLEM 5 security.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Configure SLEM 5 disables unattended or automatic logon via SSH. +Note: The file /etc/issue is overridden by package updates and will not maintain the banner text as it does in other Linux distributions.SRG-OS-000480-GPOS-00229<GroupDescription></GroupDescription>SLEM-05-255025SLEM 5 must not allow unattended or automatic logon via SSH.<VulnDiscussion>Failure to restrict system access via SSH to authenticated users negatively impacts SLEM 5 security.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Configure SLEM 5 disables unattended or automatic logon via SSH. Add or modify the following lines in the "/etc/ssh/sshd_config" file: @@ -1219,35 +1236,35 @@ Check that unattended or automatic login is disabled with the following commands > grep -i ^DISPLAYMANAGER_PASSWORD_LESS_LOGIN /etc/sysconfig/displaymanager DISPLAYMANAGER_PASSWORD_LESS_LOGIN="no" -If the "DISPLAYMANAGER_AUTOLOGIN" parameter includes a username or the "DISPLAYMANAGER_PASSWORD_LESS_LOGIN" is not set to "no", this is a finding.SRG-OS-000299-GPOS-00117<GroupDescription></GroupDescription>SLEM-05-291010SLEM 5 wireless network adapters must be disabled unless approved and documented.<VulnDiscussion>Without protection of communications with wireless peripherals, confidentiality and integrity may be compromised because unprotected communications can be intercepted and either read, altered, or used to compromise SLEM 5. +If the "DISPLAYMANAGER_AUTOLOGIN" parameter includes a username or the "DISPLAYMANAGER_PASSWORD_LESS_LOGIN" is not set to "no", this is a finding.SRG-OS-000299-GPOS-00117<GroupDescription></GroupDescription>SLEM-05-291010SLEM 5 wireless network adapters must be disabled unless approved and documented.<VulnDiscussion>Without protection of communications with wireless peripherals, confidentiality and integrity may be compromised because unprotected communications can be intercepted and either read, altered, or used to compromise SLEM 5. This requirement applies to wireless peripheral technologies (e.g., wireless mice, keyboards, displays, etc.) used with a SLEM 5. Wireless peripherals (e.g., Wi-Fi/Bluetooth/IR keyboards, mice, pointing devices, and Near Field Communications [NFC]) present a unique challenge by creating an open, unsecured port on a computer. Wireless peripherals must meet DOD requirements for wireless data transmission and be approved for use by the AO. Even though some wireless peripherals, such as mice and pointing devices, do not ordinarily carry information that need to be protected, modification of communications with these wireless peripherals may be used to compromise SLEM 5. Communication paths outside the physical protection of a controlled boundary are exposed to the possibility of interception and modification. -Protecting the confidentiality and integrity of communications with wireless peripherals can be accomplished by physical means (e.g., employing physical barriers to wireless radio frequencies) or by logical means (e.g., employing cryptographic techniques). If physical means of protection are employed, then logical means (cryptography) do not have to be employed, and vice versa. If the wireless peripheral is only passing telemetry data, encryption of the data may not be required.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001444CCI-001443CCI-002418Configure SLEM 5 to disable all wireless network interfaces with the following command: +Protecting the confidentiality and integrity of communications with wireless peripherals can be accomplished by physical means (e.g., employing physical barriers to wireless radio frequencies) or by logical means (e.g., employing cryptographic techniques). If physical means of protection are employed, then logical means (cryptography) do not have to be employed, and vice versa. If the wireless peripheral is only passing telemetry data, encryption of the data may not be required.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001444CCI-001443CCI-002418Configure SLEM 5 to disable all wireless network interfaces. -For each interface of type wireless, bring the interface into "down" state: +Run "nmcli device status" and note the device name from the DEVICE column for any wireless devices (e.g., wlan0). - > sudo wicked ifdown wlan0 +Set the device to unmanaged using the device name: + > sudo nmcli device set wlan0 managed no -For each interface of type wireless with a configuration type of "compat:suse:", remove the associated file: +Set the software switches to "off" with the following commands: + > sudo nmcli radio wwan off + > sudo nmcli radio wifi offVerify SLEM 5 has no wireless network adapters enabled. - > sudo rm /etc/sysconfig/network/ifcfg-wlan0 +Check the status of all network devices with this command: + > nmcli device status + DEVICE TYPE STATE CONNECTION + eth0 ethernet connected Wired connection 1 + lo loopback unmanaged -- -For each interface of type wireless, for each configuration of type "wicked:xml:", remove the associated file or remove the interface configuration from the file. +If there is a device listed with a type of "wifi", and it is not documented and approved as an operational requirement with the authorizing official (AO), this is a finding. - > sudo rm /etc/wicked/ifconfig/wlan0.xmlVerify that SLEM 5 has no wireless network adapters enabled with the following command: +Check the status of the software switches with the following command: + > nmcli radio + WIFI-HW WIFI WWAN-HW WWAN + missing disabled missing disabled - > sudo wicked show all - ... - wlan0 up - link: #3, state up, mtu 1500 - type: wireless, hwaddr 06:00:00:00:00:02 - config: wicked:xml:/etc/wicked/ifconfig/wlan0.xml - leases: ipv4 dhcp granted - addr: ipv4 10.0.0.101/16 [dhcp] - route: ipv4 default via 10.0.0.1 proto dhcp - -If a wireless interface is configured and has not been documented and approved by the AO, this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>SLEM-05-291015SLEM 5 must disable the USB mass storage kernel module.<VulnDiscussion>Without identifying devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. +If any wireless devices are "enabled" that are not documented and approved as an operational requirement with the AO, this is a finding.SRG-OS-000378-GPOS-00163<GroupDescription></GroupDescription>SLEM-05-291015SLEM 5 must disable the USB mass storage kernel module.<VulnDiscussion>Without identifying devices, unidentified or unknown devices may be introduced, thereby facilitating malicious activity. Peripherals include but are not limited to such devices as flash drives, external storage, and printers.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-001958Configure SLEM 5 to prevent USB mass storage devices from automounting when connected to the host. @@ -1287,47 +1304,47 @@ FAIL_DELAY 5SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411025All SLEM 5 local interactive users must have a home directory assigned in the /etc/passwd file.<VulnDiscussion>If local interactive users are not assigned a valid home directory, there is no place for the storage and control of files they should own.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Assign home directories to all SLEM 5 local interactive users that currently do not have a home directory assigned. +If the value of "FAIL_DELAY" is not set to "5" or greater, the line is commented out, or the line is missing, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411025All SLEM 5 local interactive users must have a home directory assigned in the /etc/passwd file.<VulnDiscussion>If local interactive users are not assigned a valid home directory, there is no place for the storage and control of files they should own.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Assign home directories to all SLEM 5 local interactive users that currently do not have a home directory assigned. Assign a home directory to users via the usermod command: - > sudo usermod -d /home/smithj smithjVerify SLEM 5 local interactive users on the system have a home directory assigned with the following command: + > sudo usermod -d /home/dosuser dosuserVerify SLEM 5 local interactive users on the system have a home directory assigned with the following command: > sudo pwck -r - user 'smithj': directory '/home/smithj' does not exist + user 'dosuser': directory '/home/dosuser' does not exist Ask the system administrator (SA) if any users found without home directories are local interactive users. If the SA is unable to provide a response, check for users with a User Identifier (UID) of 1000 or greater with the following command: > awk -F: '($3>=1000)&&($1!="nobody"){print $1 ":" $3}' /etc/passwd -If any interactive users do not have a home directory assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411030All SLEM 5 local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a denial of service (DoS) because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Create home directories to all SLEM 5 local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": +If any interactive users do not have a home directory assigned, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411030All SLEM 5 local interactive user home directories defined in the /etc/passwd file must exist.<VulnDiscussion>If a local interactive user has a home directory defined that does not exist, the user may be given access to the / directory as the current working directory upon logon. This could create a denial of service (DoS) because the user would not be able to access their logon configuration files, and it may give them visibility to system files they normally would not be able to access.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Create home directories to all SLEM 5 local interactive users that currently do not have a home directory assigned. Use the following commands to create the user home directory assigned in "/etc/ passwd": -Note: The example will be for the user smithj, who has a home directory of "/home/smithj", a UID of "smithj", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". +Note: The example will be for the user dosuser, who has a home directory of "/home/dosuser", a UID of "dosuser", and a Group Identifier (GID) of "users assigned" in "/etc/passwd". - > sudo mkdir /home/smithj - > sudo chown smithj /home/smithj - > sudo chgrp users /home/smithj - > sudo chmod 0750 /home/smithjVerify the assigned home directory of all SLEM 5 local interactive users on the system exists. + > sudo mkdir /home/dosuser + > sudo chown dosuser /home/dosuser + > sudo chgrp users /home/dosuser + > sudo chmod 0750 /home/dosuserVerify the assigned home directory of all SLEM 5 local interactive users on the system exists. Check the home directory assignment for all local interactive nonprivileged users on the system with the following command: > awk -F: '($3>=1000)&&($7 !~ /nologin/){print $1, $6}' /etc/passwd - smithj /home/smithj + dosuser /home/dosuser Note: This may miss interactive users that have been assigned a privileged User Identifier (UID). Evidence of interactive use may be obtained from a number of log files containing system logon information. Check that all referenced home directories exist with the following command: > sudo pwck -r - user 'smithj': directory '/home/smithj' does not exist + user 'dosuser': directory '/home/dosuser' does not exist -If any home directories referenced in "/etc/passwd" are returned as not defined, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411035All SLEM 5 local interactive user initialization files executable search paths must contain only paths that resolve to the users' home directory.<VulnDiscussion>The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory (other than the user's home directory), executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. If deviations from the default system search path for the local interactive user are required, they must be documented with the information system security officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Edit SLEM 5 local interactive user initialization files to change any PATH variable statements for executables that reference directories other than their home directory. If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.Verify that all SLEM 5 local interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the user's home directory with the following command: +If any home directories referenced in "/etc/passwd" are returned as not defined, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411035All SLEM 5 local interactive user initialization files executable search paths must contain only paths that resolve to the users' home directory.<VulnDiscussion>The executable search path (typically the PATH environment variable) contains a list of directories for the shell to search to find executables. If this path includes the current working directory (other than the user's home directory), executables in these directories may be executed instead of system commands. This variable is formatted as a colon-separated list of directories. If there is an empty entry, such as a leading or trailing colon or two consecutive colons, this is interpreted as the current working directory. If deviations from the default system search path for the local interactive user are required, they must be documented with the information system security officer (ISSO).</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Edit SLEM 5 local interactive user initialization files to change any PATH variable statements for executables that reference directories other than their home directory. If a local interactive user requires path variables to reference a directory owned by the application, it must be documented with the ISSO.Verify that all SLEM 5 local interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the user's home directory with the following command: -Note: The example will be for the user "smithj", who has a home directory of "/home/smithj". +Note: The example will be for the user "dosuser", who has a home directory of "/home/dosuser". - > sudo grep -i path= /home/smithj/.* + > sudo grep -i path= /home/dosuser/.* -/home/smithj/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin +/home/dosuser/.bash_profile:PATH=$PATH:$HOME/.local/bin:$HOME/bin If any local interactive user initialization files have executable search path statements that include directories outside of their home directory, and the additional path statements are not documented with the ISSO as an operational requirement, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-411040All SLEM 5 local initialization files must not execute world-writable programs.<VulnDiscussion>If user start-up files execute world-writable programs, especially in unprotected directories, they could be maliciously modified to destroy user files or otherwise compromise the system at the user level. If the system is compromised at the user level, it is easier to elevate privileges to eventually compromise the system at the root and network level.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Remove the references to these files in the local initialization scripts or remove the world-writable permission of files referenced by SLEM 5 local initialization scripts with the following command: @@ -1422,16 +1439,7 @@ Edit the file "/etc/passwd" and provide each interactive user account that has a > awk -F ":" 'list[$3]++{print $1, $3}' /etc/passwd -If output is produced, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-412010SLEM 5 must display the date and time of the last successful account logon upon logon.<VulnDiscussion>Providing users with feedback on when account accesses last occurred facilitates user recognition and reporting of unauthorized account use.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Configure SLEM 5 to provide users with feedback on when account accesses last occurred by setting the required configuration options in "/etc/pam.d/login". - -Add the following line to the top of "/etc/pam.d/login": - -session required pam_lastlog.so showfailedVerify SLEM 5 users are provided with feedback on when account accesses last occurred with the following command: - - > grep pam_lastlog /etc/pam.d/login - session required pam_lastlog.so showfailed - -If "pam_lastlog" is missing from "/etc/pam.d/login" file, the "silent" option is present, the second column value different from "requisite", or the returned line is commented out, this is a finding.SRG-OS-000029-GPOS-00010<GroupDescription></GroupDescription>SLEM-05-412015SLEM 5 must initiate a session lock after a 15-minute period of inactivity.<VulnDiscussion>A session time-out lock is a temporary action taken when a user stops work and moves away from the immediate physical vicinity of the information system but does not log out because of the temporary nature of the absence. +If output is produced, this is a finding.SRG-OS-000029-GPOS-00010<GroupDescription></GroupDescription>SLEM-05-412015SLEM 5 must initiate a session lock after a 15-minute period of inactivity.<VulnDiscussion>A session time-out lock is a temporary action taken when a user stops work and moves away from the immediate physical vicinity of the information system but does not log out because of the temporary nature of the absence. Rather than relying on the users to manually lock their SLEM 5 session prior to vacating the vicinity, SLEM 5 needs to be able to identify when a user's session has idled and take action to initiate the session lock. @@ -1578,18 +1586,22 @@ All administrators must be mapped to the "sysadm_u", "staff_u", or an appropriat All authorized nonadministrative users must be mapped to the "user_u" role. -If any interactive users are not mapped in this way, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-432010SLEM 5 must use the invoking user's password for privilege escalation when using "sudo".<VulnDiscussion>The sudoers security policy requires that users authenticate themselves before they can use sudo. When sudoers requires authentication, it validates the invoking user's credentials. If the rootpw, targetpw, or runaspw flags are defined and not disabled, by default the operating system will prompt the invoking user for the "root" user password. +If any interactive users are not mapped in this way, this is a finding.SRG-OS-000480-GPOS-00227<GroupDescription></GroupDescription>SLEM-05-432010SLEM 5 must use the invoking user's password for privilege escalation when using "sudo".<VulnDiscussion>The sudoers security policy requires that users authenticate themselves before they can use sudo. When sudoers requires authentication, it validates the invoking user's credentials. If the rootpw, targetpw, or runaspw flags are defined and not disabled, by default the operating system will prompt the invoking user for the "root" user password. + +For more information on each of the listed configurations, reference the sudoers(5) manual page.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Configure the sudoers security policy to use the invoking user's password for privilege escalation. + +Define the defaults in a configuration file in the /etc/sudoers.d/ directory with the following command and entries: -For more information on each of the listed configurations, reference the sudoers(5) manual page.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000366Define the following in the Defaults section of the /etc/sudoers file or a configuration file in the /etc/sudoers.d/ directory: + > sudo visudo -f /etc/sudoers.d/hardening_defaults Defaults !targetpw Defaults !rootpw -Defaults !runaspwVerify that the sudoers security policy is configured to use the invoking user's password for privilege escalation with the following command: +Defaults !runaspwVerify that the sudoers security policy is configured to use the invoking user's password for privilege escalation with the following command: - > sudo egrep -ir '(rootpw|targetpw|runaspw)' /etc/sudoers /etc/sudoers.d* | grep -v '#' - /etc/sudoers:Defaults !targetpw - /etc/sudoers:Defaults !rootpw - /etc/sudoers:Defaults !runaspw + > sudo egrep -ir '(rootpw|targetpw|runaspw)' /etc/sudoers /etc/sudoers.d* | grep -v '#' + /etc/sudoers.d/hardening_defaults:Defaults !targetpw + /etc/sudoers.d/hardening_defaults:Defaults !rootpw + /etc/sudoers.d/hardening_defaults:Defaults !runaspw If "Defaults" types are not defined for "!targetpw", "!rootpw", and "!runaspw", there are conflicting results between files, this is a finding.SRG-OS-000373-GPOS-00156<GroupDescription></GroupDescription>SLEM-05-432015SLEM 5 must reauthenticate users when changing authenticators, roles, or escalating privileges.<VulnDiscussion>Without reauthentication, users may access resources or perform tasks for which they do not have authorization. @@ -1730,14 +1742,14 @@ Lock the account: > sudo awk -F: '!$2 {print $1}' /etc/shadow -If the command returns any results, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>SLEM-05-611065SLEM 5 must employ user passwords with a minimum lifetime of 24 hours (one day).<VulnDiscussion>Enforcing a minimum password lifetime helps prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000198Configure SLEM 5 to enforce 24 hours/one day or greater as the minimum password age for user accounts. +If the command returns any results, this is a finding.SRG-OS-000075-GPOS-00043<GroupDescription></GroupDescription>SLEM-05-611065SLEM 5 must employ user passwords with a minimum lifetime of 24 hours (one day).<VulnDiscussion>Enforcing a minimum password lifetime helps prevent repeated password changes to defeat the password reuse or history enforcement requirement. If users are allowed to immediately and continually change their password, the password could be repeatedly changed in a short period of time to defeat the organization's policy regarding password reuse.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000198Configure SLEM 5 to enforce 24 hours/one day or greater as the minimum password age for user accounts. Change the minimum time period between password changes for each <username> account to "1" day with the command, replacing <username> with the user account that must be changed: - > sudo passwd -n 1 <username>Verify SLEM 5 enforces a minimum time period between password changes for each user account of one day or greater with the following command: + > sudo passwd -n 1 <username>Verify SLEM 5 enforces a minimum time period between password changes for each user account of one day or greater with the following command: > sudo awk -F: '$4 < 1 {print $1 ":" $4}' /etc/shadow - smithj:1 + dosuser:1 If any results are returned that are not associated with a system account, this is a finding.SRG-OS-000076-GPOS-00044<GroupDescription></GroupDescription>SLEM-05-611070SLEM 5 must employ user passwords with a maximum lifetime of 60 days.<VulnDiscussion>Any password, no matter how complex, can eventually be cracked. Therefore, passwords need to be changed periodically. If SLEM 5 does not limit the lifetime of passwords and force users to change their passwords, there is the risk that SLEM 5 passwords could be compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000199Configure SLEM 5 to enforce a maximum password age of each <username> account to 60 days. The command in the check text will give a list of users that need to be updated to be in compliance: @@ -1774,21 +1786,21 @@ Lock all interactive user accounts not using SHA512 hashing until the passwords Password hashes "!" or "*" indicate inactive accounts not available for logon and are not evaluated. -If any interactive user password hash does not begin with "$6", this is a finding.SRG-OS-000073-GPOS-00041<GroupDescription></GroupDescription>SLEM-05-611085SLEM 5 shadow password suite must be configured to use a sufficient number of hashing rounds.<VulnDiscussion>The system must use a strong hashing algorithm to store the password. The system must use a sufficient number of hashing rounds to ensure the required level of entropy. +If any interactive user password hash does not begin with "$6", this is a finding.SRG-OS-000073-GPOS-00041<GroupDescription></GroupDescription>SLEM-05-611085SLEM 5 shadow password suite must be configured to use a sufficient number of hashing rounds.<VulnDiscussion>The system must use a strong hashing algorithm to store the password. The system must use a sufficient number of hashing rounds to ensure the required level of entropy. -Passwords need to be protected at all times, and encryption is the standard method for protecting passwords. If passwords are not encrypted, they can be plainly read (i.e., clear text) and easily compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000196CCI-000803Configure SLEM 5 shadow password suite is configured to encrypt passwords using sufficient number of hashing rounds. +Passwords need to be protected at all times, and encryption is the standard method for protecting passwords. If passwords are not encrypted, they can be plainly read (i.e., clear text) and easily compromised.</VulnDiscussion><FalsePositives></FalsePositives><FalseNegatives></FalseNegatives><Documentable>false</Documentable><Mitigations></Mitigations><SeverityOverrideGuidance></SeverityOverrideGuidance><PotentialImpacts></PotentialImpacts><ThirdPartyTools></ThirdPartyTools><MitigationControl></MitigationControl><Responsibility></Responsibility><IAControls></IAControls>DPMS Target SUSE Linux Enterprise Micro (SLEM) 5DISADPMS TargetSUSE Linux Enterprise Micro (SLEM) 55596CCI-000196CCI-000803Configure SLEM 5 shadow password suite to encrypt passwords using sufficient number of hashing rounds. Add or modify the following line in the "/etc/login.defs" file: -SHA_CRYPT_MIN_ROUNDS 5000Verify SLEM 5 shadow password suite is configured to encrypt passwords using sufficient number of hashing rounds. +SHA_CRYPT_MIN_ROUNDS 100000Verify SLEM 5 shadow password suite is configured to encrypt passwords using sufficient number of hashing rounds. > egrep "^SHA_CRYPT_" /etc/login.defs - SHA_CRYPT_MIN_ROUNDS 5000 - SHA_CRYPT_MAX_ROUNDS 5000 + SHA_CRYPT_MIN_ROUNDS 100000 + SHA_CRYPT_MAX_ROUNDS 100000 -If only one of "SHA_CRYPT_MIN_ROUNDS" or "SHA_CRYPT_MAX_ROUNDS" is set, and this value is below "5000", this is a finding. +If only one of "SHA_CRYPT_MIN_ROUNDS" or "SHA_CRYPT_MAX_ROUNDS" is set, and this value is below "100000", this is a finding. -If both "SHA_CRYPT_MIN_ROUNDS" and "SHA_CRYPT_MAX_ROUNDS" are set, and the highest value for either is below "5000", this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>SLEM-05-611090SLEM 5 must employ FIPS 140-2/140-3 approved cryptographic hashing algorithm for system authentication (login.defs).<VulnDiscussion>Unapproved mechanisms that are used for authentication to the cryptographic module are not verified and therefore cannot be relied on to provide confidentiality or integrity, and DOD data may be compromised. +If both "SHA_CRYPT_MIN_ROUNDS" and "SHA_CRYPT_MAX_ROUNDS" are set, and the highest value for either is below "100000", this is a finding.SRG-OS-000120-GPOS-00061<GroupDescription></GroupDescription>SLEM-05-611090SLEM 5 must employ FIPS 140-2/140-3 approved cryptographic hashing algorithm for system authentication (login.defs).<VulnDiscussion>Unapproved mechanisms that are used for authentication to the cryptographic module are not verified and therefore cannot be relied on to provide confidentiality or integrity, and DOD data may be compromised. SLEM 5 using encryption are required to use FIPS 140-2/140-3 compliant mechanisms for authenticating to cryptographic modules. diff --git a/shared/references/disa-stig-ubuntu2204-v2r3-xccdf-manual.xml b/shared/references/disa-stig-ubuntu2204-v2r8-xccdf-manual.xml similarity index 79% rename from shared/references/disa-stig-ubuntu2204-v2r3-xccdf-manual.xml rename to shared/references/disa-stig-ubuntu2204-v2r8-xccdf-manual.xml index f980c3ac456b..47b8e270bebd 100644 --- a/shared/references/disa-stig-ubuntu2204-v2r3-xccdf-manual.xml +++ b/shared/references/disa-stig-ubuntu2204-v2r8-xccdf-manual.xml @@ -1,4 +1,4 @@ -acceptedCanonical Ubuntu 22.04 LTS Security Technical Implementation GuideThis Security Technical Implementation Guide is published as a tool to improve the security of Department of Defense (DOD) information systems. The requirements are derived from the National Institute of Standards and Technology (NIST) 800-53 and related documents. Comments or proposed revisions to this document should be sent via email to the following address: disa.stig_spt@mail.mil.DISASTIG.DOD.MILRelease: 3 Benchmark Date: 30 Jan 20253.51.10.02I - Mission Critical Classified<ProfileDescription></ProfileDescription>I - Mission Critical Sensitive<ProfileDescription></ProfileDescription>II - Mission Support Public<ProfileDescription></ProfileDescription>III - Administrative Classified<ProfileDescription></ProfileDescription>III - Administrative Sensitive<ProfileDescription></ProfileDescription>' + '' + ' + {refine_values} + + + 42 + default_val + + + echo bash_fix + - name: test task + debug: + msg: hello + echo hummingbird_fix + + + + +""" + +RULE_ID = OSCAP_RULE + "test_rule" +PROFILE_ID = OSCAP_PROFILE + "test_profile" +VALUE_ID = "xccdf_org.ssgproject.content_value_test_var" + + +@pytest.fixture +def minimal_ds_path(tmp_path): + ds_content = MINIMAL_DS_TEMPLATE.format( + ds_ns=DS_NS, + xccdf_ns=XCCDF_NS, + profile_id=PROFILE_ID, + rule_id=RULE_ID, + value_id=VALUE_ID, + bash_system=BASH_SYSTEM, + ansible_system=ANSIBLE_SYSTEM, + hummingbird_system=HUMMINGBIRD_SYSTEM, + refine_values="", + ) + ds_file = tmp_path / "ssg-test-ds.xml" + ds_file.write_text(ds_content) + return str(ds_file) + + +@pytest.fixture +def ds_path_with_refinement(tmp_path): + refine = '' % VALUE_ID + ds_content = MINIMAL_DS_TEMPLATE.format( + ds_ns=DS_NS, + xccdf_ns=XCCDF_NS, + profile_id=PROFILE_ID, + rule_id=RULE_ID, + value_id=VALUE_ID, + bash_system=BASH_SYSTEM, + ansible_system=ANSIBLE_SYSTEM, + hummingbird_system=HUMMINGBIRD_SYSTEM, + refine_values=refine, + ) + ds_file = tmp_path / "ssg-test-ds.xml" + ds_file.write_text(ds_content) + return str(ds_file) + + +def _make_generator(ds_path, tmp_path, language="bash"): + output_dir = str(tmp_path / "output") + os.makedirs(output_dir, exist_ok=True) + return gpr.ScriptGenerator(language, "test_product", ds_path, output_dir) + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.get_output_file_path() +# --------------------------------------------------------------------------- + +def test_get_output_file_path_bash(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "bash") + profile_el = ET.fromstring( + '' % (XCCDF_NS, PROFILE_ID) + ) + path = sg.get_output_file_path(profile_el) + assert path.endswith("test_product-script-test_profile.sh") + + +def test_get_output_file_path_ansible(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "ansible") + profile_el = ET.fromstring( + '' % (XCCDF_NS, PROFILE_ID) + ) + path = sg.get_output_file_path(profile_el) + assert path.endswith("test_product-playbook-test_profile.yml") + + +def test_get_output_file_path_hummingbird(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "hummingbird") + profile_el = ET.fromstring( + '' % (XCCDF_NS, PROFILE_ID) + ) + path = sg.get_output_file_path(profile_el) + assert path.endswith("test_product-script-test_profile.sh") + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.create_header() +# --------------------------------------------------------------------------- + +def _make_profile_el(): + xml = ( + '' + 'My Title' + 'My description.' + '' % (XCCDF_NS, PROFILE_ID) + ) + return ET.fromstring(xml) + + +def test_create_header_bash(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "bash") + header = sg.create_header(_make_profile_el()) + assert header.startswith("#!/usr/bin/env bash\n") + assert "Bash Remediation Script" in header + assert "My Title" in header + assert PROFILE_ID in header + assert "oscap xccdf generate fix" in header + + +def test_create_header_ansible(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "ansible") + header = sg.create_header(_make_profile_el()) + assert header.startswith("---\n") + assert "Ansible Playbook" in header + assert "ansible-playbook" in header + + +def test_create_header_hummingbird(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "hummingbird") + header = sg.create_header(_make_profile_el()) + assert header.startswith("#!/usr/bin/env bash\n") + assert "Hummingbird" in header + assert "RUN remediation-script.sh" in header + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.generate_bash_rule_remediation() +# --------------------------------------------------------------------------- + +def test_generate_bash_rule_remediation_with_fix(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "bash") + output = sg.generate_bash_rule_remediation(RULE_ID, (1, 5), {}) + assert "BEGIN fix" in output + assert "1 / 5" in output + assert RULE_ID in output + assert "echo bash_fix" in output + assert "END fix" in output + + +def test_generate_bash_rule_remediation_missing_fix(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "bash") + fake_rule = OSCAP_RULE + "nonexistent" + sg.remediations[fake_rule] = None + output = sg.generate_bash_rule_remediation(fake_rule, (1, 1), {}) + assert "FIX FOR THIS RULE" in output + assert "IS MISSING" in output + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.generate_hummingbird_rule_remediation() +# --------------------------------------------------------------------------- + +def test_generate_hummingbird_rule_remediation_with_fix(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "hummingbird") + output = sg.generate_hummingbird_rule_remediation(RULE_ID, {}) + assert "BEGIN fix" in output + assert "echo hummingbird_fix" in output + assert "END fix" in output + + +def test_generate_hummingbird_rule_remediation_no_fix(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "hummingbird") + fake_rule = OSCAP_RULE + "nonexistent" + sg.remediations[fake_rule] = None + output = sg.generate_hummingbird_rule_remediation(fake_rule, {}) + assert output == "" + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.generate_ansible_rule_remediation() +# --------------------------------------------------------------------------- + +def test_generate_ansible_rule_remediation_with_fix(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "ansible") + fix_el = sg.remediations[RULE_ID] + rule_vars, tasks = sg.generate_ansible_rule_remediation(fix_el, {}) + assert isinstance(rule_vars, dict) + assert isinstance(tasks, list) + + +def test_generate_ansible_rule_remediation_no_fix(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "ansible") + rule_vars, tasks = sg.generate_ansible_rule_remediation(None, {}) + assert rule_vars == {} + assert tasks == [] + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.create_output_linear() +# --------------------------------------------------------------------------- + +def test_create_output_linear_bash(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "bash") + benchmark_xpath = "./{%s}component/{%s}Benchmark" % (DS_NS, XCCDF_NS) + profile_xpath = benchmark_xpath + "/{%s}Profile" % XCCDF_NS + profile = sg.ds.find(profile_xpath) + output = sg.create_output_linear(profile) + assert "#!/usr/bin/env bash" in output + assert "echo bash_fix" in output + assert "NEWROOT" not in output + + +def test_create_output_linear_hummingbird(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "hummingbird") + benchmark_xpath = "./{%s}component/{%s}Benchmark" % (DS_NS, XCCDF_NS) + profile_xpath = benchmark_xpath + "/{%s}Profile" % XCCDF_NS + profile = sg.ds.find(profile_xpath) + output = sg.create_output_linear(profile) + assert 'NEWROOT="$1"' in output + assert "echo hummingbird_fix" in output + + +# --------------------------------------------------------------------------- +# Tests for ScriptGenerator.generate_remediation_scripts() +# --------------------------------------------------------------------------- + +def test_generate_remediation_scripts_creates_files(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "bash") + sg.generate_remediation_scripts() + output_dir = str(tmp_path / "output") + files = os.listdir(output_dir) + assert len(files) == 1 + assert files[0].endswith(".sh") + content = open(os.path.join(output_dir, files[0])).read() + assert "echo bash_fix" in content + + +def test_generate_remediation_scripts_ansible(minimal_ds_path, tmp_path): + sg = _make_generator(minimal_ds_path, tmp_path, "ansible") + sg.generate_remediation_scripts() + output_dir = str(tmp_path / "output") + files = os.listdir(output_dir) + assert len(files) == 1 + assert files[0].endswith(".yml") diff --git a/tests/unit/ssg-module/test_build_cel_content.py b/tests/unit/ssg-module/test_build_cel_content.py new file mode 100644 index 000000000000..c0fbbe67fa85 --- /dev/null +++ b/tests/unit/ssg-module/test_build_cel_content.py @@ -0,0 +1,750 @@ +import os +import sys +import tempfile +import pytest +import json + +import ssg.build_yaml + +# Add build-scripts to path to import the module +BUILD_SCRIPTS_DIR = os.path.abspath(os.path.join(os.path.dirname(__file__), "..", "..", "..", "build-scripts")) +sys.path.insert(0, BUILD_SCRIPTS_DIR) + +import build_cel_content + +DATADIR = os.path.abspath(os.path.join(os.path.dirname(__file__), "data")) + + +@pytest.fixture +def cel_rule_data(): + """Sample rule data with CEL checks matching rule.yml + cel/shared.yml format.""" + return { + 'documentation_complete': True, + 'title': 'Ensure NonRoot Feature Gate is Enabled', + 'description': 'The NonRoot feature gate restricts containers from running as root.', + 'rationale': 'Running containers as non-root reduces security risks.', + 'severity': 'medium', + 'check_type': 'Platform', + 'ocil': 'Verify that the NonRoot feature gate is enabled.', + 'expression': 'hco.spec.featureGates.nonRoot == true', + 'inputs': [ + { + 'name': 'hco', + 'kubernetes_input_spec': { + 'api_version': 'hco.kubevirt.io/v1beta1', + 'resource': 'hyperconvergeds', + 'resource_name': 'kubevirt-hyperconverged', + 'resource_namespace': 'openshift-cnv' + } + } + ], + 'references': { + 'cis@ocp4': ['1.2.3'], + 'nist': ['AC-6', 'CM-6'] + } + } + + +@pytest.fixture +def oval_rule_data(): + """Sample OVAL rule data (should be excluded from CEL content).""" + return { + 'documentation_complete': True, + 'title': 'Some OVAL Rule', + 'description': 'This rule uses OVAL checks.', + 'rationale': 'OVAL rules should not appear in CEL content.', + 'severity': 'high', + 'template': { + 'name': 'yamlfile_value', + 'vars': { + 'filepath': '/api/test', + 'yamlpath': '.spec.value' + } + } + } + + +@pytest.fixture +def cel_profile_data(): + """Sample CEL profile data.""" + return { + 'documentation_complete': True, + 'title': 'CIS Virtual Machine Extension Benchmark', + 'description': 'Profile for virtual machine security.', + 'scanner_type': 'CEL', + 'selections': [ + 'kubevirt_nonroot_feature_gate_is_enabled', + 'kubevirt_no_permitted_host_devices' + ] + } + + +@pytest.fixture +def oval_profile_data(): + """Sample OVAL profile data (should be excluded from CEL content).""" + return { + 'documentation_complete': True, + 'title': 'Standard Profile', + 'description': 'Standard OVAL-based profile.', + 'selections': [ + 'some_oval_rule', + 'another_oval_rule' + ] + } + + +@pytest.fixture +def temp_rules_dir(cel_rule_data, oval_rule_data): + """Create temporary directory with test rules.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Write rule with CEL checks - create dict with required structure + cel_rule_dict = dict(cel_rule_data) + cel_rule_dict['platforms'] = [] + cel_rule_dict['platform'] = None + cel_rule_dict['inherited_platforms'] = [] + cel_rule_dict['cpe_platform_names'] = [] + cel_rule_path = os.path.join(tmpdir, 'kubevirt_nonroot_feature_gate_is_enabled.json') + + with open(cel_rule_path, 'w') as f: + json.dump(cel_rule_dict, f) + + # Write OVAL rule + oval_rule_dict = dict(oval_rule_data) + oval_rule_dict['platforms'] = [] + oval_rule_dict['platform'] = None + oval_rule_dict['inherited_platforms'] = [] + oval_rule_dict['cpe_platform_names'] = [] + oval_rule_path = os.path.join(tmpdir, 'some_oval_rule.json') + + with open(oval_rule_path, 'w') as f: + json.dump(oval_rule_dict, f) + + yield tmpdir + + +@pytest.fixture +def temp_profiles_dir(cel_profile_data, oval_profile_data): + """Create temporary directory with test profiles.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Write CEL profile - create dict with required structure + cel_profile_dict = dict(cel_profile_data) + cel_profile_dict['selected'] = ['kubevirt_nonroot_feature_gate_is_enabled'] + cel_profile_dict['platforms'] = [] + cel_profile_dict['cpe_names'] = [] + cel_profile_path = os.path.join(tmpdir, 'cis-vm-extension.json') + + with open(cel_profile_path, 'w') as f: + json.dump(cel_profile_dict, f) + + # Write OVAL profile + oval_profile_dict = dict(oval_profile_data) + oval_profile_dict['selected'] = ['some_oval_rule'] + oval_profile_dict['platforms'] = [] + oval_profile_dict['cpe_names'] = [] + oval_profile_path = os.path.join(tmpdir, 'standard.json') + + with open(oval_profile_path, 'w') as f: + json.dump(oval_profile_dict, f) + + yield tmpdir + + +def test_rule_id_to_name(): + """Test conversion of rule IDs with underscores to names with hyphens.""" + assert build_cel_content.rule_id_to_name('kubevirt_nonroot_enabled') == 'kubevirt-nonroot-enabled' + assert build_cel_content.rule_id_to_name('api_server_tls') == 'api-server-tls' + assert build_cel_content.rule_id_to_name('no_underscores') == 'no-underscores' + assert build_cel_content.rule_id_to_name('already-hyphens') == 'already-hyphens' + + +def test_convert_inputs_to_camelcase(): + """Test conversion of inputs from snake_case to camelCase for CRD compatibility.""" + # Test with full kubernetes_input_spec + inputs_snake = [ + { + 'name': 'hco', + 'kubernetes_input_spec': { + 'api_version': 'hco.kubevirt.io/v1beta1', + 'resource': 'hyperconvergeds', + 'resource_name': 'kubevirt-hyperconverged', + 'resource_namespace': 'openshift-cnv' + } + } + ] + + converted = build_cel_content.convert_inputs_to_camelcase(inputs_snake) + + assert len(converted) == 1 + assert converted[0]['name'] == 'hco' + assert 'kubernetesInputSpec' in converted[0] + assert 'kubernetes_input_spec' not in converted[0] + + spec = converted[0]['kubernetesInputSpec'] + assert spec['apiVersion'] == 'hco.kubevirt.io/v1beta1' + assert spec['resource'] == 'hyperconvergeds' + assert spec['resourceName'] == 'kubevirt-hyperconverged' + assert spec['resourceNamespace'] == 'openshift-cnv' + + # Verify snake_case keys are not in output + assert 'api_version' not in spec + assert 'resource_name' not in spec + assert 'resource_namespace' not in spec + + # Test with minimal spec (no optional fields) + inputs_minimal = [ + { + 'name': 'pods', + 'kubernetes_input_spec': { + 'api_version': 'v1', + 'resource': 'pods' + } + } + ] + + converted_minimal = build_cel_content.convert_inputs_to_camelcase(inputs_minimal) + spec_minimal = converted_minimal[0]['kubernetesInputSpec'] + assert spec_minimal['apiVersion'] == 'v1' + assert spec_minimal['resource'] == 'pods' + assert 'resourceName' not in spec_minimal + assert 'resourceNamespace' not in spec_minimal + + +def test_extract_controls_from_references(): + """Test extraction of controls from references dictionary.""" + # Test with list values + refs = { + 'cis@ocp4': ['1.2.3', '4.5.6'], + 'nist': ['AC-6', 'CM-6'] + } + controls = build_cel_content.extract_controls_from_references(refs) + assert controls == refs + + # Test with string values (should be converted to list) + refs_str = { + 'cis@ocp4': '1.2.3', + 'nist': 'AC-6' + } + controls_str = build_cel_content.extract_controls_from_references(refs_str) + assert controls_str == { + 'cis@ocp4': ['1.2.3'], + 'nist': ['AC-6'] + } + + # Test with None + controls_none = build_cel_content.extract_controls_from_references(None) + assert controls_none == {} + + # Test with empty dict + controls_empty = build_cel_content.extract_controls_from_references({}) + assert controls_empty == {} + + +def test_load_cel_rules(temp_rules_dir): + """Test loading rules with CEL checks from directory.""" + cel_rules = build_cel_content.load_cel_rules(temp_rules_dir) + + # Should load only the rule with CEL checks (identified by presence of expression + inputs) + assert len(cel_rules) == 1 + assert 'kubevirt_nonroot_feature_gate_is_enabled' in cel_rules + + rule = cel_rules['kubevirt_nonroot_feature_gate_is_enabled'] + # Rules with CEL checks are identified by presence of expression and inputs + assert hasattr(rule, 'expression') and rule.expression + assert hasattr(rule, 'inputs') and rule.inputs + assert rule.title == 'Ensure NonRoot Feature Gate is Enabled' + + +def test_load_cel_rules_nonexistent_dir(): + """Test loading rules with CEL checks from nonexistent directory.""" + cel_rules = build_cel_content.load_cel_rules('/nonexistent/path') + assert cel_rules == {} + + +def test_load_profiles(temp_profiles_dir): + """Test loading CEL profiles from directory.""" + cel_rule_ids = {'kubevirt_nonroot_feature_gate_is_enabled'} + profiles = build_cel_content.load_profiles(temp_profiles_dir, cel_rule_ids) + + # Should load only the CEL profile + assert len(profiles) == 1 + assert profiles[0].scanner_type == 'CEL' + assert profiles[0].title == 'CIS Virtual Machine Extension Benchmark' + + +def test_load_profiles_nonexistent_dir(): + """Test loading profiles from nonexistent directory.""" + profiles = build_cel_content.load_profiles('/nonexistent/path', set()) + assert profiles == [] + + +def test_rule_to_cel_dict(cel_rule_data): + """Test conversion of Rule object to CEL content dictionary.""" + rule = ssg.build_yaml.Rule('kubevirt_nonroot_feature_gate_is_enabled') + for key, value in cel_rule_data.items(): + setattr(rule, key, value) + rule.id_ = 'kubevirt_nonroot_feature_gate_is_enabled' + + cel_dict = build_cel_content.rule_to_cel_dict(rule) + + assert cel_dict['id'] == 'kubevirt_nonroot_feature_gate_is_enabled' + assert cel_dict['name'] == 'kubevirt-nonroot-feature-gate-is-enabled' + assert cel_dict['title'] == 'Ensure NonRoot Feature Gate is Enabled' + assert cel_dict['description'] == 'The NonRoot feature gate restricts containers from running as root.' + assert cel_dict['rationale'] == 'Running containers as non-root reduces security risks.' + assert cel_dict['severity'] == 'medium' + assert cel_dict['checkType'] == 'Platform' # camelCase for output + assert cel_dict['instructions'] == 'Verify that the NonRoot feature gate is enabled.' + assert cel_dict['expression'] == 'hco.spec.featureGates.nonRoot == true' + assert 'inputs' in cel_dict + assert len(cel_dict['inputs']) == 1 + assert cel_dict['inputs'][0]['name'] == 'hco' + # Check that inputs were converted to camelCase + assert 'kubernetesInputSpec' in cel_dict['inputs'][0] + assert cel_dict['inputs'][0]['kubernetesInputSpec']['apiVersion'] == 'hco.kubevirt.io/v1beta1' + assert cel_dict['inputs'][0]['kubernetesInputSpec']['resourceName'] == 'kubevirt-hyperconverged' + assert cel_dict['inputs'][0]['kubernetesInputSpec']['resourceNamespace'] == 'openshift-cnv' + assert 'controls' in cel_dict + assert cel_dict['controls']['cis@ocp4'] == ['1.2.3'] + assert cel_dict['controls']['nist'] == ['AC-6', 'CM-6'] + + +def test_rule_to_cel_dict_minimal(): + """Test conversion with minimal rule data.""" + rule = ssg.build_yaml.Rule('minimal_rule') + rule.id_ = 'minimal_rule' + rule.title = 'Minimal Rule' + rule.description = 'Description' + rule.rationale = 'Rationale' + rule.severity = 'low' + rule.expression = 'true' + rule.inputs = [{'name': 'test'}] # Required for rules with CEL checks + rule.references = {} + + cel_dict = build_cel_content.rule_to_cel_dict(rule) + + assert cel_dict['id'] == 'minimal_rule' + assert cel_dict['name'] == 'minimal-rule' + assert cel_dict['checkType'] == 'Platform' # default, camelCase for output + assert 'instructions' not in cel_dict # ocil not provided + assert 'failureReason' not in cel_dict # not provided, camelCase for output + assert 'controls' not in cel_dict # no references + + +def test_rule_to_cel_dict_with_failure_reason(): + """Test conversion with failure_reason field (snake_case input, camelCase output).""" + rule = ssg.build_yaml.Rule('test_rule') + rule.id_ = 'test_rule' + rule.title = 'Test Rule' + rule.description = 'Description' + rule.rationale = 'Rationale' + rule.severity = 'medium' + rule.check_type = 'Platform' + rule.expression = 'true' + rule.inputs = [{'name': 'test'}] # Required for rules with CEL checks + rule.failure_reason = 'The configuration is not compliant' # snake_case input + rule.references = {} + + cel_dict = build_cel_content.rule_to_cel_dict(rule) + + assert cel_dict['id'] == 'test_rule' + assert cel_dict['checkType'] == 'Platform' # camelCase output + assert cel_dict['failureReason'] == 'The configuration is not compliant' # camelCase output + + +def test_profile_to_cel_dict(cel_profile_data): + """Test conversion of Profile object to CEL content dictionary.""" + profile = ssg.build_yaml.Profile('cis_vm_extension') + for key, value in cel_profile_data.items(): + setattr(profile, key, value) + profile.id_ = 'cis_vm_extension' + profile.selected = ['kubevirt_nonroot_feature_gate_is_enabled', 'kubevirt_no_permitted_host_devices'] + + cel_rule_ids = {'kubevirt_nonroot_feature_gate_is_enabled', 'kubevirt_no_permitted_host_devices'} + cel_dict = build_cel_content.profile_to_cel_dict(profile, cel_rule_ids) + + assert cel_dict['id'] == 'cis_vm_extension' + assert cel_dict['name'] == 'cis-vm-extension' + assert cel_dict['title'] == 'CIS Virtual Machine Extension Benchmark' + assert cel_dict['description'] == 'Profile for virtual machine security.' + assert cel_dict['productType'] == 'Platform' + assert len(cel_dict['rules']) == 2 + assert 'kubevirt-nonroot-feature-gate-is-enabled' in cel_dict['rules'] + assert 'kubevirt-no-permitted-host-devices' in cel_dict['rules'] + assert cel_dict['rules'] == sorted(cel_dict['rules']) # should be sorted + + +def test_profile_to_cel_dict_no_cel_rules(): + """Test profile conversion when no rules with CEL checks are selected.""" + profile = ssg.build_yaml.Profile('test_profile') + profile.id_ = 'test_profile' + profile.title = 'Test Profile' + profile.description = 'Test' + profile.selected = ['oval_rule_1', 'oval_rule_2'] + + cel_rule_ids = set() # No rules with CEL checks + cel_dict = build_cel_content.profile_to_cel_dict(profile, cel_rule_ids) + + assert cel_dict is None # Should return None when no rules with CEL checks + + +def test_generate_cel_content(): + """Test generation of complete CEL content structure.""" + # Create mock rules + rule1 = ssg.build_yaml.Rule('rule_one') + rule1.id_ = 'rule_one' + rule1.title = 'Rule One' + rule1.description = 'Description 1' + rule1.rationale = 'Rationale 1' + rule1.severity = 'high' + rule1.expression = 'true' + rule1.inputs = [{'name': 'test1'}] + rule1.references = {} + + rule2 = ssg.build_yaml.Rule('rule_two') + rule2.id_ = 'rule_two' + rule2.title = 'Rule Two' + rule2.description = 'Description 2' + rule2.rationale = 'Rationale 2' + rule2.severity = 'medium' + rule2.expression = 'false' + rule2.inputs = [{'name': 'test2'}] + rule2.references = {} + + cel_rules = { + 'rule_one': rule1, + 'rule_two': rule2 + } + + # Create mock profile + profile = ssg.build_yaml.Profile('test_profile') + profile.id_ = 'test_profile' + profile.title = 'Test Profile' + profile.description = 'Test Description' + profile.selected = ['rule_one', 'rule_two'] + + profiles = [profile] + + content = build_cel_content.generate_cel_content(cel_rules, profiles) + + assert 'profiles' in content + assert 'rules' in content + assert len(content['profiles']) == 1 + assert len(content['rules']) == 2 + + # Check profile + assert content['profiles'][0]['id'] == 'test_profile' + assert len(content['profiles'][0]['rules']) == 2 + + # Check rules are sorted + rule_ids = [r['id'] for r in content['rules']] + assert rule_ids == sorted(rule_ids) + + +def test_generate_cel_content_empty(): + """Test generation with no rules with CEL checks or profiles.""" + content = build_cel_content.generate_cel_content({}, []) + + assert content == {'profiles': [], 'rules': []} + + +def test_load_cel_rules_missing_expression(): + """Test that rule without expression is skipped.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Create rule without expression (but with inputs - incomplete for CEL checks) + rule_dict = { + 'documentation_complete': True, + 'title': 'Test Rule', + 'description': 'Test', + 'rationale': 'Test', + 'severity': 'medium', + 'inputs': [{'name': 'test'}], # Has inputs but no expression + 'platforms': [], + 'platform': None, + 'inherited_platforms': [], + 'cpe_platform_names': [] + } + rule_path = os.path.join(tmpdir, 'test_rule.json') + with open(rule_path, 'w') as f: + json.dump(rule_dict, f) + + # Should not raise error - rule is not identified as CEL without both expression and inputs + # This rule will be skipped since it doesn't have both fields + cel_rules = build_cel_content.load_cel_rules(tmpdir) + assert len(cel_rules) == 0 # Rule should be skipped + + +def test_load_cel_rules_missing_inputs(): + """Test that rule without inputs is skipped.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Create rule without inputs (but with expression - incomplete for CEL checks) + rule_dict = { + 'documentation_complete': True, + 'title': 'Test Rule', + 'description': 'Test', + 'rationale': 'Test', + 'severity': 'medium', + 'expression': 'true', # Has expression but no inputs + 'platforms': [], + 'platform': None, + 'inherited_platforms': [], + 'cpe_platform_names': [] + } + rule_path = os.path.join(tmpdir, 'test_rule.json') + with open(rule_path, 'w') as f: + json.dump(rule_dict, f) + + # Should not raise error - rule is not identified as CEL without both expression and inputs + # This rule will be skipped since it doesn't have both fields + cel_rules = build_cel_content.load_cel_rules(tmpdir) + assert len(cel_rules) == 0 # Rule should be skipped + + +def test_load_profiles_no_rules(): + """Test that loading CEL profile without rules raises error.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Create profile without rules + profile_dict = { + 'documentation_complete': True, + 'title': 'Test Profile', + 'description': 'Test', + 'scanner_type': 'CEL', + 'selections': [], + 'selected': [], + 'platforms': [], + 'cpe_names': [] + } + profile_path = os.path.join(tmpdir, 'test_profile.json') + with open(profile_path, 'w') as f: + json.dump(profile_dict, f) + + with pytest.raises(ValueError, match="has no rules"): + build_cel_content.load_profiles(tmpdir, set()) + + +def test_generate_cel_content_duplicate_rule_names(): + """Test that duplicate rule names are detected.""" + # Create two rules that will have the same name after conversion to hyphens + # Rule IDs are different, but they convert to the same hyphenated name + rule1 = ssg.build_yaml.Rule('test_rule_one') + rule1.id_ = 'test_rule_one' + rule1.title = 'Test Rule 1' + rule1.description = 'Description 1' + rule1.rationale = 'Rationale 1' + rule1.severity = 'high' + rule1.expression = 'true' + rule1.inputs = [{'name': 'test'}] + rule1.references = {} + + # This will convert to 'test-rule-one' - same as rule1 + rule2 = ssg.build_yaml.Rule('test_rule_one') # Same ID after underscore conversion + rule2.id_ = 'test_rule_one' + rule2.title = 'Test Rule 2' + rule2.description = 'Description 2' + rule2.rationale = 'Rationale 2' + rule2.severity = 'medium' + rule2.expression = 'false' + rule2.inputs = [{'name': 'test2'}] + rule2.references = {} + + # Can't have duplicate keys in dict, so this test validates + # that if somehow we had duplicates, they'd be caught + # The real protection is that rule IDs themselves must be unique + # But the validation still checks for duplicate names after conversion + + # For this test, we just verify the dict prevents duplicates at load time + # The build system itself prevents duplicate rule IDs + # So this test just documents the behavior + assert rule1.id_ == rule2.id_ # They're actually the same + + +def test_generate_cel_content_unknown_rule_reference(): + """Test that profile referencing unknown rule is detected.""" + # Create a rule + rule1 = ssg.build_yaml.Rule('existing_rule') + rule1.id_ = 'existing_rule' + rule1.title = 'Existing Rule' + rule1.description = 'Description' + rule1.rationale = 'Rationale' + rule1.severity = 'high' + rule1.expression = 'true' + rule1.inputs = [{'name': 'test'}] + rule1.references = {} + + cel_rules = { + 'existing_rule': rule1 + } + + # Create a profile that references a non-existent rule + profile = ssg.build_yaml.Profile('test_profile') + profile.id_ = 'test_profile' + profile.title = 'Test Profile' + profile.description = 'Test' + profile.selected = ['existing_rule', 'nonexistent_rule'] + + profiles = [profile] + + with pytest.raises(ValueError, match="references unknown rule 'nonexistent-rule'"): + build_cel_content.generate_cel_content(cel_rules, profiles) + + +def test_validation_empty_expression(): + """Test that rule with empty expression is skipped.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Create rule with empty expression + rule_dict = { + 'documentation_complete': True, + 'title': 'Test Rule', + 'description': 'Test', + 'rationale': 'Test', + 'severity': 'medium', + 'expression': '', # Empty string is falsy, won't be identified as CEL + 'inputs': [{'name': 'test'}], + 'platforms': [], + 'platform': None, + 'inherited_platforms': [], + 'cpe_platform_names': [] + } + rule_path = os.path.join(tmpdir, 'test_rule.json') + with open(rule_path, 'w') as f: + json.dump(rule_dict, f) + + # Empty expression means rule is not identified as CEL and is skipped + cel_rules = build_cel_content.load_cel_rules(tmpdir) + assert len(cel_rules) == 0 + + +def test_validation_empty_inputs(): + """Test that rule with empty inputs list is skipped.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Create rule with empty inputs + rule_dict = { + 'documentation_complete': True, + 'title': 'Test Rule', + 'description': 'Test', + 'rationale': 'Test', + 'severity': 'medium', + 'expression': 'true', + 'inputs': [], # Empty list is falsy, won't be identified as CEL + 'platforms': [], + 'platform': None, + 'inherited_platforms': [], + 'cpe_platform_names': [] + } + rule_path = os.path.join(tmpdir, 'test_rule.json') + with open(rule_path, 'w') as f: + json.dump(rule_dict, f) + + # Empty inputs means rule is not identified as CEL and is skipped + cel_rules = build_cel_content.load_cel_rules(tmpdir) + assert len(cel_rules) == 0 + + +def test_validation_profile_with_empty_selections(): + """Test that profile with empty selections is caught.""" + with tempfile.TemporaryDirectory() as tmpdir: + # Create profile with empty selected list + # Note: from_compiled_json uses 'selections' to populate 'selected' + profile_dict = { + 'documentation_complete': True, + 'title': 'Test Profile', + 'description': 'Test', + 'scanner_type': 'CEL', + 'selections': [], # Empty selections + 'selected': [], # This gets populated from selections + 'platforms': [], + 'cpe_names': [] + } + profile_path = os.path.join(tmpdir, 'test_profile.json') + with open(profile_path, 'w') as f: + json.dump(profile_dict, f) + + with pytest.raises(ValueError, match="has no rules"): + build_cel_content.load_profiles(tmpdir, set()) + + +def test_validation_mixed_oval_and_cel_in_profile(): + """Test that profile with both OVAL and CEL checks only includes rules with CEL checks.""" + # Create rule with CEL checks + cel_rule = ssg.build_yaml.Rule('cel_rule') + cel_rule.id_ = 'cel_rule' + cel_rule.title = 'CEL Rule' + cel_rule.description = 'Description' + cel_rule.rationale = 'Rationale' + cel_rule.severity = 'high' + cel_rule.expression = 'true' + cel_rule.inputs = [{'name': 'test'}] + cel_rule.references = {} + + cel_rules = { + 'cel_rule': cel_rule + } + + # Create a CEL profile that references both CEL and OVAL rules + # (OVAL rules won't be in cel_rule_ids) + profile = ssg.build_yaml.Profile('mixed_profile') + profile.id_ = 'mixed_profile' + profile.title = 'Mixed Profile' + profile.description = 'Test' + profile.selected = ['cel_rule', 'oval_rule'] # oval_rule doesn't have CEL checks + + profiles = [profile] + + # This should fail because oval_rule doesn't have CEL checks + with pytest.raises(ValueError, match="references unknown rule 'oval-rule'"): + build_cel_content.generate_cel_content(cel_rules, profiles) + + +def test_validation_integration_full_flow(): + """Integration test: validate full flow from directories to content generation.""" + with tempfile.TemporaryDirectory() as rules_dir, tempfile.TemporaryDirectory() as profiles_dir: + # Create valid rule with CEL checks + rule_dict = { + 'documentation_complete': True, + 'title': 'Valid Rule with CEL Checks', + 'description': 'This is a valid rule using the CEL checking engine', + 'rationale': 'Security is important', + 'severity': 'high', + 'expression': 'resource.spec.enabled == true', + 'inputs': [{'name': 'resource', 'kubernetes_input_spec': {'resource': 'pods'}}], + 'platforms': [], + 'platform': None, + 'inherited_platforms': [], + 'cpe_platform_names': [], + 'references': {'cis@ocp4': ['1.2.3']} + } + rule_path = os.path.join(rules_dir, 'valid_cel_rule.json') + with open(rule_path, 'w') as f: + json.dump(rule_dict, f) + + # Create valid profile targeting CEL + profile_dict = { + 'documentation_complete': True, + 'title': 'Valid Profile Targeting CEL', + 'description': 'This is a valid profile targeting the CEL checking engine', + 'scanner_type': 'CEL', + 'selections': ['valid_cel_rule'], + 'selected': ['valid_cel_rule'], + 'platforms': [], + 'cpe_names': [] + } + profile_path = os.path.join(profiles_dir, 'valid_profile.json') + with open(profile_path, 'w') as f: + json.dump(profile_dict, f) + + # Load and validate + cel_rules = build_cel_content.load_cel_rules(rules_dir) + assert len(cel_rules) == 1 + assert 'valid_cel_rule' in cel_rules + + cel_rule_ids = set(cel_rules.keys()) + profiles = build_cel_content.load_profiles(profiles_dir, cel_rule_ids) + assert len(profiles) == 1 + + # Generate content + content = build_cel_content.generate_cel_content(cel_rules, profiles) + assert len(content['rules']) == 1 + assert len(content['profiles']) == 1 + assert content['rules'][0]['name'] == 'valid-cel-rule' + assert content['rules'][0]['expression'] == 'resource.spec.enabled == true' + assert content['profiles'][0]['name'] == 'valid-profile' + assert 'valid-cel-rule' in content['profiles'][0]['rules'] diff --git a/tests/unit/ssg-module/test_build_renumber.py b/tests/unit/ssg-module/test_build_renumber.py index 493016892c1b..90db64ecfa20 100644 --- a/tests/unit/ssg-module/test_build_renumber.py +++ b/tests/unit/ssg-module/test_build_renumber.py @@ -195,8 +195,6 @@ def xccdf_with_no_cce(): def test_verify_correct_form_of_referenced_cce_identifiers_no_cce( xccdf_with_no_cce): - try: - ssg.build_renumber.verify_correct_form_of_referenced_cce_identifiers( + # Should not raise an exception when there's no CCE + ssg.build_renumber.verify_correct_form_of_referenced_cce_identifiers( xccdf_with_no_cce) - except SSGError as e: - assert False, "Raised SSGError: " + str(e) diff --git a/tests/unit/ssg-module/test_build_yaml.py b/tests/unit/ssg-module/test_build_yaml.py index cbb7adc8d5d7..38c2802f4b98 100644 --- a/tests/unit/ssg-module/test_build_yaml.py +++ b/tests/unit/ssg-module/test_build_yaml.py @@ -2,7 +2,6 @@ import collections import os import tempfile -import sys import yaml import pytest @@ -454,7 +453,6 @@ def rule_accounts_tmout(): return ssg.build_yaml.Rule.from_yaml(rule_file) -@pytest.mark.skipif(sys.version_info[0] < 3, reason="requires python3 or higher") def test_rule_to_xml_element(rule_accounts_tmout): xmldiff_main = pytest.importorskip("xmldiff.main") rule_el = rule_accounts_tmout.to_xml_element() @@ -487,7 +485,6 @@ def value_system_crypto_policy(): return ssg.build_yaml.Value.from_yaml(value_file) -@pytest.mark.skipif(sys.version_info[0] < 3, reason="requires python3 or higher") def test_value_to_xml_element(value_system_crypto_policy): xmldiff_main = pytest.importorskip("xmldiff.main") value_el = value_system_crypto_policy.to_xml_element() @@ -575,7 +572,8 @@ def test_profile_with_version(profile_with_version): profile_el = profile_with_version.to_xml_element() assert profile_el.find("{%s}version" % XCCDF12_NS).text == "3.2.1" + def test_profile_ospp_with_invalid_status(): value_file = os.path.join(DATADIR, "ospp_invalid_status.profile") - with pytest.raises(Exception): + with pytest.raises(RuntimeError): profile = ssg.build_yaml.Profile.from_yaml(value_file) # noqa: F841 diff --git a/tests/unit/ssg-module/test_controls.py b/tests/unit/ssg-module/test_controls.py index b6e74388b8e0..62b4f2e390b9 100644 --- a/tests/unit/ssg-module/test_controls.py +++ b/tests/unit/ssg-module/test_controls.py @@ -1,6 +1,5 @@ import pytest import os -import sys import ssg.controls import ssg.build_yaml @@ -104,7 +103,6 @@ def test_controls_load(controls_manager): _load_test(controls_manager, "abcd") -@pytest.mark.skipif(sys.version_info[0] < 3, reason="requires python3 or higher") def test_controls_invalid_rules(env_yaml): existing_rules = {"accounts_tmout", "configure_crypto_policy"} controls_manager = ssg.controls.ControlsManager( @@ -115,7 +113,6 @@ def test_controls_invalid_rules(env_yaml): "Control abcd:R1 contains nonexisting rule(s) sshd_set_idle_timeout" -@pytest.mark.skipif(sys.version_info[0] < 3, reason="requires python3 or higher") def test_controls_levels(controls_manager): # Default level is the lowest level c_1 = controls_manager.get_control("abcd-levels", "S1") diff --git a/tests/unit/ssg-module/test_playbook_builder_data/guide/package_abrt_removed/rule.yml b/tests/unit/ssg-module/test_playbook_builder_data/guide/package_abrt_removed/rule.yml index 44815f6b2f6b..c70cceb690d5 100644 --- a/tests/unit/ssg-module/test_playbook_builder_data/guide/package_abrt_removed/rule.yml +++ b/tests/unit/ssg-module/test_playbook_builder_data/guide/package_abrt_removed/rule.yml @@ -21,7 +21,7 @@ references: srg: SRG-OS-000095-GPOS-00049 stigid@rhel8: RHEL-08-040001 -{{{ complete_ocil_entry_package(package="abrt") }}} +{{{ complete_ocil_entry_package_removed("abrt") }}} template: name: package_removed diff --git a/tests/unit/ssg-module/test_rule_yaml.py b/tests/unit/ssg-module/test_rule_yaml.py index 3588860f81b8..068551adb2d6 100644 --- a/tests/unit/ssg-module/test_rule_yaml.py +++ b/tests/unit/ssg-module/test_rule_yaml.py @@ -1,4 +1,5 @@ import os +import pytest import ssg.rule_yaml data_dir = os.path.abspath(os.path.join(os.path.dirname(__file__), "data")) @@ -11,3 +12,219 @@ def test_read_file_list(): assert isinstance(contents, list) assert len(contents) == 1 assert contents[0] == 'testing' + + +class TestSortSectionKeys: + """Tests for sort_section_keys function.""" + + def test_single_line_keys_sorted(self): + file_contents = [ + "identifiers:", + " cce@rhel9: CCE-90000-0", + " cce@rhel8: CCE-80000-0", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "identifiers" + ) + assert result == [ + "identifiers:", + " cce@rhel8: CCE-80000-0", + " cce@rhel9: CCE-90000-0", + "", + ] + + def test_already_sorted_unchanged(self): + file_contents = [ + "identifiers:", + " cce@rhel8: CCE-80000-0", + " cce@rhel9: CCE-90000-0", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "identifiers" + ) + assert result == file_contents + + def test_multi_line_values_sorted(self): + file_contents = [ + "references:", + " nist: CM-6,CM-6(1),", + " AC-2", + " cis@rhel9: 1.2.3", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "references" + ) + assert result == [ + "references:", + " cis@rhel9: 1.2.3", + " nist: CM-6,CM-6(1),", + " AC-2", + "", + ] + + def test_multi_line_values_multiple_continuations(self): + file_contents = [ + "references:", + " zz_last: value_z", + " aa_first: line1,", + " line2,", + " line3", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "references" + ) + assert result == [ + "references:", + " aa_first: line1,", + " line2,", + " line3", + " zz_last: value_z", + "", + ] + + def test_section_not_found_returns_unchanged(self): + file_contents = [ + "identifiers:", + " cce@rhel9: CCE-90000-0", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "nonexistent" + ) + assert result == file_contents + + def test_single_subkey_unchanged(self): + file_contents = [ + "identifiers:", + " cce@rhel9: CCE-90000-0", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "identifiers" + ) + assert result == file_contents + + def test_empty_section_unchanged(self): + """Section with key but no subkeys (value is None) is skipped.""" + file_contents = [ + "references:", + "", + "identifiers:", + " cce@rhel9: CCE-90000-0", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "references" + ) + assert result == file_contents + + def test_preserves_surrounding_content(self): + file_contents = [ + "title: My Rule", + "identifiers:", + " cce@rhel9: CCE-90000-0", + " cce@rhel8: CCE-80000-0", + "", + "severity: medium", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "identifiers" + ) + assert result == [ + "title: My Rule", + "identifiers:", + " cce@rhel8: CCE-80000-0", + " cce@rhel9: CCE-90000-0", + "", + "severity: medium", + ] + + def test_duplicated_key_raises(self): + """YAML parser deduplicates keys, so we need raw lines with a key + that the parser kept as one entry but appears twice in the text.""" + file_contents = [ + "references:", + " nist: CM-6", + " cis@rhel9: 1.2.3", + " nist: AC-2", + "", + ] + with pytest.raises(ValueError, match="duplicated key"): + ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "references" + ) + + def test_custom_sort_func(self): + """Reverse sort should put zz_last before aa_first.""" + file_contents = [ + "references:", + " aa_first: val_a", + " zz_last: val_z", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "references", + sort_func=lambda k: k[::-1] + ) + # Reversed keys: 'tsrif_aa' < 'tsal_zz', so aa_first still first? + # No: reversed 'aa_first' = 'tsrif_aa', 'zz_last' = 'tsal_zz' + # 'tsal_zz' < 'tsrif_aa', so zz_last sorts before aa_first + assert result == [ + "references:", + " zz_last: val_z", + " aa_first: val_a", + "", + ] + + def test_multiple_sections(self): + file_contents = [ + "identifiers:", + " cce@rhel9: CCE-90000-0", + " cce@rhel8: CCE-80000-0", + "", + "references:", + " nist: CM-6", + " cis@rhel9: 1.2.3", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, ["identifiers", "references"] + ) + assert result == [ + "identifiers:", + " cce@rhel8: CCE-80000-0", + " cce@rhel9: CCE-90000-0", + "", + "references:", + " cis@rhel9: 1.2.3", + " nist: CM-6", + "", + ] + + def test_multi_line_values_both_keys(self): + """Both keys have multi-line values and need reordering.""" + file_contents = [ + "references:", + " zz_ref: val1,", + " val2", + " aa_ref: val3,", + " val4,", + " val5", + "", + ] + result = ssg.rule_yaml.sort_section_keys( + "test.yml", file_contents, "references" + ) + assert result == [ + "references:", + " aa_ref: val3,", + " val4,", + " val5", + " zz_ref: val1,", + " val2", + "", + ] diff --git a/tests/unit/ssg_test_suite/test_assert_reference_unique.py b/tests/unit/ssg_test_suite/test_assert_reference_unique.py index 373589dce72c..9bcb452f4c9f 100755 --- a/tests/unit/ssg_test_suite/test_assert_reference_unique.py +++ b/tests/unit/ssg_test_suite/test_assert_reference_unique.py @@ -1,15 +1,5 @@ import os -import pytest import subprocess -import sys - -if sys.version_info < (3, 0): - try: - # pytest v4.6 has allow_module_level - pytest.skip("requires python3", allow_module_level=True) - except TypeError: - # older pytest v2.7 does not have it and it is implied - pytest.skip("requires python3") DATADIR = os.path.abspath(os.path.join(os.path.dirname(__file__), "data")) CMD = os.path.abspath( diff --git a/tests/unit/utils/oscal/data/build-config.yml b/tests/unit/utils/oscal/data/build-config.yml deleted file mode 100644 index 80370ba2e341..000000000000 --- a/tests/unit/utils/oscal/data/build-config.yml +++ /dev/null @@ -1,8 +0,0 @@ -cmake_build_type: "Release" - -ssg_version: [0, 1, 59] -ssg_version_str: "0.1.59" - -jinja2_cache_enabled: false - -sce_enabled: "OFF" diff --git a/tests/unit/utils/oscal/data/rule_dirs.json b/tests/unit/utils/oscal/data/rule_dirs.json deleted file mode 100644 index c1ec5c099210..000000000000 --- a/tests/unit/utils/oscal/data/rule_dirs.json +++ /dev/null @@ -1 +0,0 @@ -{"test_rule": {"id": "test_rule", "dir": "test_rule_dir", "guide": "test_rule_guide", "products": ["test_product"], "title": "My Test Rule", "identifiers": {}, "ovals": {}, "remediations": {"anaconda": {}, "ansible": {}, "bash": {}, "puppet": {}, "ignition": {}, "kubernetes": {}, "blueprint": {}}, "oval_products": {}, "remediation_products": {}}} diff --git a/tests/unit/utils/oscal/data/simplified_nist_catalog.json b/tests/unit/utils/oscal/data/simplified_nist_catalog.json deleted file mode 100644 index e897600c9507..000000000000 --- a/tests/unit/utils/oscal/data/simplified_nist_catalog.json +++ /dev/null @@ -1,5225 +0,0 @@ -{ - "catalog": { - "uuid": "613fca2d-704a-42e7-8e2b-b206fb92b456", - "metadata": { - "title": "Trestle simplified: NIST Special Publication 800-53 Revision 5: Security and Privacy Controls for Federal Information Systems and Organizations", - "last-modified": "2021-06-08T13:57:33.013981-04:00", - "version": "5.0.1", - "oscal-version": "1.0.0", - "props": [ - { - "name": "keywords", - "value": "assurance; availability; computer security; confidentiality; control; cybersecurity; FISMA; information security; information system; integrity; personally identifiable information; Privacy Act; privacy controls; privacy functions; privacy requirements; Risk Management Framework; security controls; security functions; security requirements; system; system security." - } - ], - "links": [ - { - "href": "#c3397cc9-83c6-4459-adb2-836739dc1b94", - "rel": "alternate" - }, - { - "href": "#f7cf488d-bc64-4a91-a994-810e153ee481", - "rel": "canonical" - } - ], - "roles": [ - { - "id": "creator", - "title": "Document creator" - }, - { - "id": "contact", - "title": "Contact" - } - ], - "parties": [ - { - "uuid": "41a93829-b76b-43ec-b9e7-250553511549", - "type": "organization", - "name": "Joint Task Force, Interagency Working Group", - "email-addresses": [ - "sec-cert@nist.gov" - ], - "addresses": [ - { - "addr-lines": [ - "National Institute of Standards and Technology", - "Attn: Computer Security Division" - ], - "city": "Gaithersburg", - "state": "MD", - "postal-code": "20899-8930" - } - ] - } - ], - "responsible-parties": [ - { - "role-id": "creator", - "party-uuids": [ - "41a93829-b76b-43ec-b9e7-250553511549" - ] - }, - { - "role-id": "contact", - "party-uuids": [ - "41a93829-b76b-43ec-b9e7-250553511549" - ] - } - ] - }, - "params": [ - { - "id": "loose_1", - "label": "loose_1_label", - "values": [ - "loose_1_value" - ] - }, - { - "id": "loose_2", - "label": "loose_2_label", - "values": [ - "loose_2_value" - ] - } - ], - "groups": [ - { - "id": "ac", - "class": "family", - "title": "Access Control", - "controls": [ - { - "id": "ac-1", - "class": "SP800-53", - "title": "Policy and Procedures", - "params": [ - { - "id": "ac-1_prm_1", - "props": [ - { - "name": "param_1_prop", - "value": "prop value" - } - ], - "links": [ - { - "href": "#123456789", - "text": "orig link text" - } - ], - "label": "organization-defined personnel or roles", - "constraints": [ - { - "description": "orig constraint desc" - } - ], - "guidelines": [ - { - "prose": "original guideline" - } - ], - "values": [ - "Param_1_value_in_catalog" - ] - }, - { - "id": "ac-1_prm_2", - "select": { - "how-many": "one-or-more", - "choice": [ - "Organization-level", - "Mission/business process-level", - "System-level" - ] - } - }, - { - "id": "ac-1_prm_3", - "label": "organization-defined official" - }, - { - "id": "ac-1_prm_4", - "label": "organization-defined frequency" - }, - { - "id": "ac-1_prm_5", - "label": "organization-defined events" - }, - { - "id": "ac-1_prm_6", - "label": "organization-defined frequency" - }, - { - "id": "ac-1_prm_7", - "label": "organization-defined events" - } - ], - "props": [ - { - "name": "label", - "value": "AC-1" - }, - { - "name": "sort-id", - "value": "ac-01" - }, - { - "name": "extra_prop", - "value": "extra value" - } - ], - "links": [ - { - "href": "#27847491-5ce1-4f6a-a1e4-9e483782f0ef", - "rel": "reference" - }, - { - "href": "#c7ac44e8-10db-4b64-b2b9-9e32ec1efed0", - "rel": "reference" - }, - { - "href": "#08b07465-dbdc-48d6-8a0b-37279602ac16", - "rel": "reference" - }, - { - "href": "#cec037f3-8aba-4c97-84b4-4082f9e515d2", - "rel": "reference" - }, - { - "href": "#4c0ec2ee-a0d6-428a-9043-4504bc3ade6f", - "rel": "reference" - }, - { - "href": "#7f473f21-fdbf-4a6c-81a1-0ab95919609d", - "rel": "reference" - }, - { - "href": "#ia-1", - "rel": "related" - }, - { - "href": "#pm-9", - "rel": "related" - }, - { - "href": "#pm-24", - "rel": "related" - }, - { - "href": "#ps-8", - "rel": "related" - }, - { - "href": "#si-12", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-1_smt", - "name": "statement", - "prose": "The organization:", - "parts": [ - { - "id": "ac-1_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "a." - } - ], - "prose": "Develop, document, and disseminate to {{ insert: param, ac-1_prm_1 }}:", - "parts": [ - { - "id": "ac-1_smt.a.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": " {{ insert: param, ac-1_prm_2 }} access control policy that:", - "parts": [ - { - "id": "ac-1_smt.a.1.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Addresses purpose, scope, roles, responsibilities, management commitment, coordination among organizational entities, and compliance; and" - }, - { - "id": "ac-1_smt.a.1.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Is consistent with applicable laws, executive orders, directives, regulations, policies, standards, and guidelines; and" - } - ] - }, - { - "id": "ac-1_smt.a.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": "Procedures to facilitate the implementation of the access control policy and the associated access controls;" - } - ] - }, - { - "id": "ac-1_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "b." - } - ], - "prose": "Designate an {{ insert: param, ac-1_prm_3 }} to manage the development, documentation, and dissemination of the access control policy and procedures; and" - }, - { - "id": "ac-1_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "c." - } - ], - "prose": "Review and update the current access control:", - "parts": [ - { - "id": "ac-1_smt.c.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": "Policy {{ insert: param, ac-1_prm_4 }} and following {{ insert: param, ac-1_prm_5 }}; and" - }, - { - "id": "ac-1_smt.c.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": "Procedures {{ insert: param, ac-1_prm_6 }} and following {{ insert: param, ac-1_prm_7 }}." - } - ] - } - ], - "props": [ - { - "name": "prop_in_part", - "value": "value in part" - } - ] - }, - { - "id": "ac-1_gdn", - "name": "guidance", - "prose": "Access control policy and procedures address the controls in the AC family that are implemented within systems and organizations. The risk management strategy is an important factor in establishing such policies and procedures. Policies and procedures contribute to security and privacy assurance. Therefore, it is important that security and privacy programs collaborate on the development of access control policy and procedures. Security and privacy program policies and procedures at the organization level are preferable, in general, and may obviate the need for mission- or system-specific policies and procedures. The policy can be included as part of the general security and privacy policy or be represented by multiple policies reflecting the complex nature of organizations. Procedures can be established for security and privacy programs, for mission or business processes, and for systems, if needed. Procedures describe how the policies or controls are implemented and can be directed at the individual or role that is the object of the procedure. Procedures can be documented in system security and privacy plans or in one or more separate documents. Events that may precipitate an update to access control policy and procedures include assessment or audit findings, security incidents or breaches, or changes in laws, executive orders, directives, regulations, policies, standards, and guidelines. Simply restating controls does not constitute an organizational policy or procedure." - } - ] - }, - { - "id": "ac-2", - "class": "SP800-53", - "title": "Account Management", - "params": [ - { - "id": "ac-2_prm_1", - "label": "organization-defined prerequisites and criteria" - }, - { - "id": "ac-2_prm_2", - "label": "organization-defined attributes (as required)" - }, - { - "id": "ac-2_prm_3", - "label": "organization-defined personnel or roles" - }, - { - "id": "ac-2_prm_4", - "label": "organization-defined policy, procedures, prerequisites, and criteria" - }, - { - "id": "ac-2_prm_5", - "label": "organization-defined personnel or roles" - }, - { - "id": "ac-2_prm_6", - "label": "organization-defined time period" - }, - { - "id": "ac-2_prm_7", - "label": "organization-defined time period" - }, - { - "id": "ac-2_prm_8", - "label": "organization-defined time period" - }, - { - "id": "ac-2_prm_9", - "label": "organization-defined attributes (as required)" - }, - { - "id": "ac-2_prm_10", - "label": "organization-defined frequency" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2" - }, - { - "name": "sort-id", - "value": "ac-02" - } - ], - "links": [ - { - "href": "#2956e175-f674-43f4-b1b9-e074ad9fc39c", - "rel": "reference" - }, - { - "href": "#388a3aa2-5d85-4bad-b8a3-77db80d63c4f", - "rel": "reference" - }, - { - "href": "#53df282b-8b3f-483a-bad1-6a8b8ac00114", - "rel": "reference" - }, - { - "href": "#ac-3", - "rel": "related" - }, - { - "href": "#ac-5", - "rel": "related" - }, - { - "href": "#ac-6", - "rel": "related" - }, - { - "href": "#ac-17", - "rel": "related" - }, - { - "href": "#ac-18", - "rel": "related" - }, - { - "href": "#ac-20", - "rel": "related" - }, - { - "href": "#ac-24", - "rel": "related" - }, - { - "href": "#au-2", - "rel": "related" - }, - { - "href": "#au-12", - "rel": "related" - }, - { - "href": "#cm-5", - "rel": "related" - }, - { - "href": "#ia-2", - "rel": "related" - }, - { - "href": "#ia-4", - "rel": "related" - }, - { - "href": "#ia-5", - "rel": "related" - }, - { - "href": "#ia-8", - "rel": "related" - }, - { - "href": "#ma-3", - "rel": "related" - }, - { - "href": "#ma-5", - "rel": "related" - }, - { - "href": "#pe-2", - "rel": "related" - }, - { - "href": "#pl-4", - "rel": "related" - }, - { - "href": "#ps-2", - "rel": "related" - }, - { - "href": "#ps-4", - "rel": "related" - }, - { - "href": "#ps-5", - "rel": "related" - }, - { - "href": "#ps-7", - "rel": "related" - }, - { - "href": "#pt-2", - "rel": "related" - }, - { - "href": "#pt-3", - "rel": "related" - }, - { - "href": "#sc-7", - "rel": "related" - }, - { - "href": "#sc-12", - "rel": "related" - }, - { - "href": "#sc-13", - "rel": "related" - }, - { - "href": "#sc-37", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2_smt", - "name": "statement", - "parts": [ - { - "id": "ac-2_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "a." - } - ], - "prose": "Define and document the types of accounts allowed and specifically prohibited for use within the system;" - }, - { - "id": "ac-2_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "b." - } - ], - "prose": "Assign account managers;" - }, - { - "id": "ac-2_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "c." - } - ], - "prose": "Require {{ insert: param, ac-2_prm_1 }} for group and role membership;" - }, - { - "id": "ac-2_smt.d", - "name": "item", - "props": [ - { - "name": "label", - "value": "d." - } - ], - "prose": "Specify:", - "parts": [ - { - "id": "ac-2_smt.d.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": "Authorized users of the system;" - }, - { - "id": "ac-2_smt.d.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": "Group and role membership; and" - }, - { - "id": "ac-2_smt.d.3", - "name": "item", - "props": [ - { - "name": "label", - "value": "3." - } - ], - "prose": "Access authorizations (i.e., privileges) and {{ insert: param, ac-2_prm_2 }} for each account;" - } - ] - }, - { - "id": "ac-2_smt.e", - "name": "item", - "props": [ - { - "name": "label", - "value": "e." - } - ], - "prose": "Require approvals by {{ insert: param, ac-2_prm_3 }} for requests to create accounts;" - }, - { - "id": "ac-2_smt.f", - "name": "item", - "props": [ - { - "name": "label", - "value": "f." - } - ], - "prose": "Create, enable, modify, disable, and remove accounts in accordance with {{ insert: param, ac-2_prm_4 }};" - }, - { - "id": "ac-2_smt.g", - "name": "item", - "props": [ - { - "name": "label", - "value": "g." - } - ], - "prose": "Monitor the use of accounts;" - }, - { - "id": "ac-2_smt.h", - "name": "item", - "props": [ - { - "name": "label", - "value": "h." - } - ], - "prose": "Notify account managers and {{ insert: param, ac-2_prm_5 }} within:", - "parts": [ - { - "id": "ac-2_smt.h.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": " {{ insert: param, ac-2_prm_6 }} when accounts are no longer required;" - }, - { - "id": "ac-2_smt.h.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": " {{ insert: param, ac-2_prm_7 }} when users are terminated or transferred; and" - }, - { - "id": "ac-2_smt.h.3", - "name": "item", - "props": [ - { - "name": "label", - "value": "3." - } - ], - "prose": " {{ insert: param, ac-2_prm_8 }} when system usage or need-to-know changes for an individual;" - } - ] - }, - { - "id": "ac-2_smt.i", - "name": "item", - "props": [ - { - "name": "label", - "value": "i." - } - ], - "prose": "Authorize access to the system based on:", - "parts": [ - { - "id": "ac-2_smt.i.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": "A valid access authorization;" - }, - { - "id": "ac-2_smt.i.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": "Intended system usage; and" - }, - { - "id": "ac-2_smt.i.3", - "name": "item", - "props": [ - { - "name": "label", - "value": "3." - } - ], - "prose": " {{ insert: param, ac-2_prm_9 }};" - } - ] - }, - { - "id": "ac-2_smt.j", - "name": "item", - "props": [ - { - "name": "label", - "value": "j." - } - ], - "prose": "Review accounts for compliance with account management requirements {{ insert: param, ac-2_prm_10 }};" - }, - { - "id": "ac-2_smt.k", - "name": "item", - "props": [ - { - "name": "label", - "value": "k." - } - ], - "prose": "Establish and implement a process for changing shared or group account authenticators (if deployed) when individuals are removed from the group; and" - }, - { - "id": "ac-2_smt.l", - "name": "item", - "props": [ - { - "name": "label", - "value": "l." - } - ], - "prose": "Align account management processes with personnel termination and transfer processes." - } - ] - }, - { - "id": "ac-2_gdn", - "name": "guidance", - "prose": "Examples of system account types include individual, shared, group, system, guest, anonymous, emergency, developer, temporary, and service. Identification of authorized system users and the specification of access privileges reflect the requirements in other controls in the security plan. Users requiring administrative privileges on system accounts receive additional scrutiny by organizational personnel responsible for approving such accounts and privileged access, including system owner, mission or business owner, senior agency information security officer, or senior agency official for privacy. Types of accounts that organizations may wish to prohibit due to increased risk include shared, group, emergency, anonymous, temporary, and guest accounts.\n\nWhere access involves personally identifiable information, security programs collaborate with the senior agency official for privacy to establish the specific conditions for group and role membership; specify authorized users, group and role membership, and access authorizations for each account; and create, adjust, or remove system accounts in accordance with organizational policies. Policies can include such information as account expiration dates or other factors that trigger the disabling of accounts. Organizations may choose to define access privileges or other attributes by account, type of account, or a combination of the two. Examples of other attributes required for authorizing access include restrictions on time of day, day of week, and point of origin. In defining other system account attributes, organizations consider system-related requirements and mission/business requirements. Failure to consider these factors could affect system availability.\n\nTemporary and emergency accounts are intended for short-term use. Organizations establish temporary accounts as part of normal account activation procedures when there is a need for short-term accounts without the demand for immediacy in account activation. Organizations establish emergency accounts in response to crisis situations and with the need for rapid account activation. Therefore, emergency account activation may bypass normal account authorization processes. Emergency and temporary accounts are not to be confused with infrequently used accounts, including local logon accounts used for special tasks or when network resources are unavailable (may also be known as accounts of last resort). Such accounts remain available and are not subject to automatic disabling or removal dates. Conditions for disabling or deactivating accounts include when shared/group, emergency, or temporary accounts are no longer required and when individuals are transferred or terminated. Changing shared/group authenticators when members leave the group is intended to ensure that former group members do not retain access to the shared or group account. Some types of system accounts may require specialized training." - } - ], - "controls": [ - { - "id": "ac-2.1", - "class": "SP800-53-enhancement", - "title": "Automated System Account Management", - "params": [ - { - "id": "ac-2.1_prm_1", - "label": "organization-defined automated mechanisms" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(1)" - }, - { - "name": "sort-id", - "value": "ac-02.01" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-2.1_smt", - "name": "statement", - "prose": "Support the management of system accounts using {{ insert: param, ac-2.1_prm_1 }}." - }, - { - "id": "ac-2.1_gdn", - "name": "guidance", - "prose": "Automated system account management includes using automated mechanisms to create, enable, modify, disable, and remove accounts; notify account managers when an account is created, enabled, modified, disabled, or removed, or when users are terminated or transferred; monitor system account usage; and report atypical system account usage. Automated mechanisms can include internal system functions and email, telephonic, and text messaging notifications." - } - ] - }, - { - "id": "ac-2.2", - "class": "SP800-53-enhancement", - "title": "Automated Temporary and Emergency Account Management", - "params": [ - { - "id": "ac-2.2_prm_1", - "select": { - "choice": [ - "remove", - "disable" - ] - } - }, - { - "id": "ac-2.2_prm_2", - "label": "organization-defined time period for each type of account" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(2)" - }, - { - "name": "sort-id", - "value": "ac-02.02" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-2.2_smt", - "name": "statement", - "prose": "Automatically {{ insert: param, ac-2.2_prm_1 }} temporary and emergency accounts after {{ insert: param, ac-2.2_prm_2 }}." - }, - { - "id": "ac-2.2_gdn", - "name": "guidance", - "prose": "Management of temporary and emergency accounts includes the removal or disabling of such accounts automatically after a predefined time period rather than at the convenience of the system administrator. Automatic removal or disabling of accounts provides a more consistent implementation." - } - ] - }, - { - "id": "ac-2.3", - "class": "SP800-53-enhancement", - "title": "Disable Accounts", - "params": [ - { - "id": "ac-2.3_prm_1", - "label": "organization-defined time period" - }, - { - "id": "ac-2.3_prm_2", - "label": "organization-defined time period" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(3)" - }, - { - "name": "sort-id", - "value": "ac-02.03" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-2.3_smt", - "name": "statement", - "prose": "Disable accounts within {{ insert: param, ac-2.3_prm_1 }} when the accounts:", - "parts": [ - { - "id": "ac-2.3_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Have expired;" - }, - { - "id": "ac-2.3_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Are no longer associated with a user or individual;" - }, - { - "id": "ac-2.3_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "(c)" - } - ], - "prose": "Are in violation of organizational policy; or" - }, - { - "id": "ac-2.3_smt.d", - "name": "item", - "props": [ - { - "name": "label", - "value": "(d)" - } - ], - "prose": "Have been inactive for {{ insert: param, ac-2.3_prm_2 }}." - } - ] - }, - { - "id": "ac-2.3_gdn", - "name": "guidance", - "prose": "Disabling expired, inactive, or otherwise anomalous accounts supports the concepts of least privilege and least functionality which reduce the attack surface of the system." - } - ] - }, - { - "id": "ac-2.4", - "class": "SP800-53-enhancement", - "title": "Automated Audit Actions", - "props": [ - { - "name": "label", - "value": "AC-2(4)" - }, - { - "name": "sort-id", - "value": "ac-02.04" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - }, - { - "href": "#au-2", - "rel": "related" - }, - { - "href": "#au-6", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2.4_smt", - "name": "statement", - "prose": "Automatically audit account creation, modification, enabling, disabling, and removal actions." - }, - { - "id": "ac-2.4_gdn", - "name": "guidance", - "prose": "Account management audit records are defined in accordance with [AU-2](#au-2) and reviewed, analyzed, and reported in accordance with [AU-6](#au-6)." - } - ] - }, - { - "id": "ac-2.5", - "class": "SP800-53-enhancement", - "title": "Inactivity Logout", - "params": [ - { - "id": "ac-2.5_prm_1", - "label": "organization-defined time period of expected inactivity or description of when to log out" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(5)" - }, - { - "name": "sort-id", - "value": "ac-02.05" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - }, - { - "href": "#ac-11", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2.5_smt", - "name": "statement", - "prose": "Require that users log out when {{ insert: param, ac-2.5_prm_1 }}." - }, - { - "id": "ac-2.5_gdn", - "name": "guidance", - "prose": "Inactivity logout is behavior- or policy-based and requires users to take physical action to log out when they are expecting inactivity longer than the defined period. Automatic enforcement of inactivity logout is addressed by [AC-11](#ac-11)." - } - ] - }, - { - "id": "ac-2.6", - "class": "SP800-53-enhancement", - "title": "Dynamic Privilege Management", - "params": [ - { - "id": "ac-2.6_prm_1", - "label": "organization-defined dynamic privilege management capabilities" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(6)" - }, - { - "name": "sort-id", - "value": "ac-02.06" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - }, - { - "href": "#ac-16", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2.6_smt", - "name": "statement", - "prose": "Implement {{ insert: param, ac-2.6_prm_1 }}." - }, - { - "id": "ac-2.6_gdn", - "name": "guidance", - "prose": "In contrast to access control approaches that employ static accounts and predefined user privileges, dynamic access control approaches rely on runtime access control decisions facilitated by dynamic privilege management, such as attribute-based access control. While user identities remain relatively constant over time, user privileges typically change more frequently based on ongoing mission or business requirements and the operational needs of organizations. An example of dynamic privilege management is the immediate revocation of privileges from users as opposed to requiring that users terminate and restart their sessions to reflect changes in privileges. Dynamic privilege management can also include mechanisms that change user privileges based on dynamic rules as opposed to editing specific user profiles. Examples include automatic adjustments of user privileges if they are operating out of their normal work times, if their job function or assignment changes, or if systems are under duress or in emergency situations. Dynamic privilege management includes the effects of privilege changes, for example, when there are changes to encryption keys used for communications." - } - ] - }, - { - "id": "ac-2.7", - "class": "SP800-53-enhancement", - "title": "Privileged User Accounts", - "params": [ - { - "id": "ac-2.7_prm_1", - "select": { - "choice": [ - "a role-based access scheme", - "an attribute-based access scheme" - ] - } - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(7)" - }, - { - "name": "sort-id", - "value": "ac-02.07" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-2.7_smt", - "name": "statement", - "parts": [ - { - "id": "ac-2.7_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Establish and administer privileged user accounts in accordance with {{ insert: param, ac-2.7_prm_1 }};" - }, - { - "id": "ac-2.7_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Monitor privileged role or attribute assignments;" - }, - { - "id": "ac-2.7_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "(c)" - } - ], - "prose": "Monitor changes to roles or attributes; and" - }, - { - "id": "ac-2.7_smt.d", - "name": "item", - "props": [ - { - "name": "label", - "value": "(d)" - } - ], - "prose": "Revoke access when privileged role or attribute assignments are no longer appropriate." - } - ] - }, - { - "id": "ac-2.7_gdn", - "name": "guidance", - "prose": "Privileged roles are organization-defined roles assigned to individuals that allow those individuals to perform certain security-relevant functions that ordinary users are not authorized to perform. Privileged roles include key management, account management, database administration, system and network administration, and web administration. A role-based access scheme organizes permitted system access and privileges into roles. In contrast, an attribute-based access scheme specifies allowed system access and privileges based on attributes." - } - ] - }, - { - "id": "ac-2.8", - "class": "SP800-53-enhancement", - "title": "Dynamic Account Management", - "params": [ - { - "id": "ac-2.8_prm_1", - "label": "organization-defined system accounts" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(8)" - }, - { - "name": "sort-id", - "value": "ac-02.08" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - }, - { - "href": "#ac-16", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2.8_smt", - "name": "statement", - "prose": "Create, activate, manage, and deactivate {{ insert: param, ac-2.8_prm_1 }} dynamically." - }, - { - "id": "ac-2.8_gdn", - "name": "guidance", - "prose": "Approaches for dynamically creating, activating, managing, and deactivating system accounts rely on automatically provisioning the accounts at runtime for entities that were previously unknown. Organizations plan for the dynamic management, creation, activation, and deactivation of system accounts by establishing trust relationships, business rules, and mechanisms with appropriate authorities to validate related authorizations and privileges." - } - ] - }, - { - "id": "ac-2.9", - "class": "SP800-53-enhancement", - "title": "Restrictions on Use of Shared and Group Accounts", - "params": [ - { - "id": "ac-2.9_prm_1", - "label": "organization-defined conditions for establishing shared and group accounts" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(9)" - }, - { - "name": "sort-id", - "value": "ac-02.09" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-2.9_smt", - "name": "statement", - "prose": "Only permit the use of shared and group accounts that meet {{ insert: param, ac-2.9_prm_1 }}." - }, - { - "id": "ac-2.9_gdn", - "name": "guidance", - "prose": "Before permitting the use of shared or group accounts, organizations consider the increased risk due to the lack of accountability with such accounts." - } - ] - }, - { - "id": "ac-2.10", - "class": "SP800-53-enhancement", - "title": "Shared and Group Account Credential Change", - "props": [ - { - "name": "label", - "value": "AC-2(10)" - }, - { - "name": "sort-id", - "value": "ac-02.10" - }, - { - "name": "status", - "value": "withdrawn" - } - ], - "links": [ - { - "href": "#ac-2_smt.k", - "rel": "incorporated-into" - } - ] - }, - { - "id": "ac-2.11", - "class": "SP800-53-enhancement", - "title": "Usage Conditions", - "params": [ - { - "id": "ac-2.11_prm_1", - "label": "organization-defined circumstances and/or usage conditions" - }, - { - "id": "ac-2.11_prm_2", - "label": "organization-defined system accounts" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(11)" - }, - { - "name": "sort-id", - "value": "ac-02.11" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-2.11_smt", - "name": "statement", - "prose": "Enforce {{ insert: param, ac-2.11_prm_1 }} for {{ insert: param, ac-2.11_prm_2 }}." - }, - { - "id": "ac-2.11_gdn", - "name": "guidance", - "prose": "Specifying and enforcing usage conditions helps to enforce the principle of least privilege, increase user accountability, and enable effective account monitoring. Account monitoring includes alerts generated if the account is used in violation of organizational parameters. Organizations can describe specific conditions or circumstances under which system accounts can be used, such as by restricting usage to certain days of the week, time of day, or specific durations of time." - } - ] - }, - { - "id": "ac-2.12", - "class": "SP800-53-enhancement", - "title": "Account Monitoring for Atypical Usage", - "params": [ - { - "id": "ac-2.12_prm_1", - "label": "organization-defined atypical usage" - }, - { - "id": "ac-2.12_prm_2", - "label": "organization-defined personnel or roles" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(12)" - }, - { - "name": "sort-id", - "value": "ac-02.12" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - }, - { - "href": "#au-6", - "rel": "related" - }, - { - "href": "#au-7", - "rel": "related" - }, - { - "href": "#ca-7", - "rel": "related" - }, - { - "href": "#ir-8", - "rel": "related" - }, - { - "href": "#si-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2.12_smt", - "name": "statement", - "parts": [ - { - "id": "ac-2.12_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Monitor system accounts for {{ insert: param, ac-2.12_prm_1 }}; and" - }, - { - "id": "ac-2.12_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Report atypical usage of system accounts to {{ insert: param, ac-2.12_prm_2 }}." - } - ] - }, - { - "id": "ac-2.12_gdn", - "name": "guidance", - "prose": "Atypical usage includes accessing systems at certain times of the day or from locations that are not consistent with the normal usage patterns of individuals. Monitoring for atypical usage may reveal rogue behavior by individuals or an attack in progress. Account monitoring may inadvertently create privacy risks since data collected to identify atypical usage may reveal previously unknown information about the behavior of individuals. Organizations assess and document privacy risks from monitoring accounts for atypical usage in their privacy impact assessment and make determinations that are in alignment with their privacy program plan." - } - ] - }, - { - "id": "ac-2.13", - "class": "SP800-53-enhancement", - "title": "Disable Accounts for High-risk Individuals", - "params": [ - { - "id": "ac-2.13_prm_1", - "label": "organization-defined time period" - }, - { - "id": "ac-2.13_prm_2", - "label": "organization-defined significant risks" - } - ], - "props": [ - { - "name": "label", - "value": "AC-2(13)" - }, - { - "name": "sort-id", - "value": "ac-02.13" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "required" - }, - { - "href": "#au-6", - "rel": "related" - }, - { - "href": "#si-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-2.13_smt", - "name": "statement", - "prose": "Disable accounts of individuals within {{ insert: param, ac-2.13_prm_1 }} of discovery of {{ insert: param, ac-2.13_prm_2 }}." - }, - { - "id": "ac-2.13_gdn", - "name": "guidance", - "prose": "Users who pose a significant security and/or privacy risk include individuals for whom reliable evidence indicates either the intention to use authorized access to systems to cause harm or through whom adversaries will cause harm. Such harm includes adverse impacts to organizational operations, organizational assets, individuals, other organizations, or the Nation. Close coordination among system administrators, legal staff, human resource managers, and authorizing officials is essential when disabling system accounts for high-risk individuals." - } - ] - } - ] - }, - { - "id": "ac-3", - "class": "SP800-53", - "title": "Access Enforcement", - "props": [ - { - "name": "label", - "value": "AC-3" - }, - { - "name": "sort-id", - "value": "ac-03" - } - ], - "links": [ - { - "href": "#18e71fec-c6fd-475a-925a-5d8495cf8455", - "rel": "reference" - }, - { - "href": "#27847491-5ce1-4f6a-a1e4-9e483782f0ef", - "rel": "reference" - }, - { - "href": "#110e26af-4765-49e1-8740-6750f83fcda1", - "rel": "reference" - }, - { - "href": "#e7942589-e267-4a5a-a3d9-f39a7aae81f0", - "rel": "reference" - }, - { - "href": "#8306620b-1920-4d73-8b21-12008528595f", - "rel": "reference" - }, - { - "href": "#2956e175-f674-43f4-b1b9-e074ad9fc39c", - "rel": "reference" - }, - { - "href": "#388a3aa2-5d85-4bad-b8a3-77db80d63c4f", - "rel": "reference" - }, - { - "href": "#7f473f21-fdbf-4a6c-81a1-0ab95919609d", - "rel": "reference" - }, - { - "href": "#ac-2", - "rel": "related" - }, - { - "href": "#ac-4", - "rel": "related" - }, - { - "href": "#ac-5", - "rel": "related" - }, - { - "href": "#ac-6", - "rel": "related" - }, - { - "href": "#ac-16", - "rel": "related" - }, - { - "href": "#ac-17", - "rel": "related" - }, - { - "href": "#ac-18", - "rel": "related" - }, - { - "href": "#ac-19", - "rel": "related" - }, - { - "href": "#ac-20", - "rel": "related" - }, - { - "href": "#ac-21", - "rel": "related" - }, - { - "href": "#ac-22", - "rel": "related" - }, - { - "href": "#ac-24", - "rel": "related" - }, - { - "href": "#ac-25", - "rel": "related" - }, - { - "href": "#at-2", - "rel": "related" - }, - { - "href": "#at-3", - "rel": "related" - }, - { - "href": "#au-9", - "rel": "related" - }, - { - "href": "#ca-9", - "rel": "related" - }, - { - "href": "#cm-5", - "rel": "related" - }, - { - "href": "#cm-11", - "rel": "related" - }, - { - "href": "#ia-2", - "rel": "related" - }, - { - "href": "#ia-5", - "rel": "related" - }, - { - "href": "#ia-6", - "rel": "related" - }, - { - "href": "#ia-7", - "rel": "related" - }, - { - "href": "#ia-11", - "rel": "related" - }, - { - "href": "#ma-3", - "rel": "related" - }, - { - "href": "#ma-4", - "rel": "related" - }, - { - "href": "#ma-5", - "rel": "related" - }, - { - "href": "#mp-4", - "rel": "related" - }, - { - "href": "#pm-2", - "rel": "related" - }, - { - "href": "#ps-3", - "rel": "related" - }, - { - "href": "#pt-2", - "rel": "related" - }, - { - "href": "#pt-3", - "rel": "related" - }, - { - "href": "#sa-17", - "rel": "related" - }, - { - "href": "#sc-2", - "rel": "related" - }, - { - "href": "#sc-3", - "rel": "related" - }, - { - "href": "#sc-4", - "rel": "related" - }, - { - "href": "#sc-12", - "rel": "related" - }, - { - "href": "#sc-13", - "rel": "related" - }, - { - "href": "#sc-28", - "rel": "related" - }, - { - "href": "#sc-31", - "rel": "related" - }, - { - "href": "#sc-34", - "rel": "related" - }, - { - "href": "#si-4", - "rel": "related" - }, - { - "href": "#si-8", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3_smt", - "name": "statement", - "prose": "Enforce approved authorizations for logical access to information and system resources in accordance with applicable access control policies." - }, - { - "id": "ac-3_gdn", - "name": "guidance", - "prose": "Access control policies control access between active entities or subjects (i.e., users or processes acting on behalf of users) and passive entities or objects (i.e., devices, files, records, domains) in organizational systems. In addition to enforcing authorized access at the system level and recognizing that systems can host many applications and services in support of mission and business functions, access enforcement mechanisms can also be employed at the application and service level to provide increased information security and privacy. In contrast to logical access controls that are implemented within the system, physical access controls are addressed by the controls in the Physical and Environmental Protection ([PE](#pe)) family." - } - ], - "controls": [ - { - "id": "ac-3.1", - "class": "SP800-53-enhancement", - "title": "Restricted Access to Privileged Functions", - "props": [ - { - "name": "label", - "value": "AC-3(1)" - }, - { - "name": "sort-id", - "value": "ac-03.01" - }, - { - "name": "status", - "value": "withdrawn" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "incorporated-into" - } - ] - }, - { - "id": "ac-3.2", - "class": "SP800-53-enhancement", - "title": "Dual Authorization", - "params": [ - { - "id": "ac-3.2_prm_1", - "label": "organization-defined privileged commands and/or other organization-defined actions" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(2)" - }, - { - "name": "sort-id", - "value": "ac-03.02" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#cp-9", - "rel": "related" - }, - { - "href": "#mp-6", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.2_smt", - "name": "statement", - "prose": "Enforce dual authorization for {{ insert: param, ac-3.2_prm_1 }}." - }, - { - "id": "ac-3.2_gdn", - "name": "guidance", - "prose": "Dual authorization, also known as two-person control, reduces risk related to insider threats. Dual authorization mechanisms require the approval of two authorized individuals to execute. To reduce the risk of collusion, organizations consider rotating dual authorization duties. Organizations consider the risk associated with implementing dual authorization mechanisms when immediate responses are necessary to ensure public and environmental safety." - } - ] - }, - { - "id": "ac-3.3", - "class": "SP800-53-enhancement", - "title": "Mandatory Access Control", - "params": [ - { - "id": "ac-3.3_prm_1", - "label": "organization-defined mandatory access control policy" - }, - { - "id": "ac-3.3_prm_2", - "label": "organization-defined subjects" - }, - { - "id": "ac-3.3_prm_3", - "label": "organization-defined privileges" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(3)" - }, - { - "name": "sort-id", - "value": "ac-03.03" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#sc-7", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.3_smt", - "name": "statement", - "prose": "Enforce {{ insert: param, ac-3.3_prm_1 }} over the set of covered subjects and objects specified in the policy, and where the policy:", - "parts": [ - { - "id": "ac-3.3_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Is uniformly enforced across the covered subjects and objects within the system;" - }, - { - "id": "ac-3.3_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Specifies that a subject that has been granted access to information is constrained from doing any of the following;", - "parts": [ - { - "id": "ac-3.3_smt.b.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "(1)" - } - ], - "prose": "Passing the information to unauthorized subjects or objects;" - }, - { - "id": "ac-3.3_smt.b.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "(2)" - } - ], - "prose": "Granting its privileges to other subjects;" - }, - { - "id": "ac-3.3_smt.b.3", - "name": "item", - "props": [ - { - "name": "label", - "value": "(3)" - } - ], - "prose": "Changing one or more security attributes (specified by the policy) on subjects, objects, the system, or system components;" - }, - { - "id": "ac-3.3_smt.b.4", - "name": "item", - "props": [ - { - "name": "label", - "value": "(4)" - } - ], - "prose": "Choosing the security attributes and attribute values (specified by the policy) to be associated with newly created or modified objects; and" - }, - { - "id": "ac-3.3_smt.b.5", - "name": "item", - "props": [ - { - "name": "label", - "value": "(5)" - } - ], - "prose": "Changing the rules governing access control; and" - } - ] - }, - { - "id": "ac-3.3_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "(c)" - } - ], - "prose": "Specifies that {{ insert: param, ac-3.3_prm_2 }} may explicitly be granted {{ insert: param, ac-3.3_prm_3 }} such that they are not limited by any defined subset (or all) of the above constraints." - } - ] - }, - { - "id": "ac-3.3_gdn", - "name": "guidance", - "prose": "Mandatory access control is a type of nondiscretionary access control. Mandatory access control policies constrain what actions subjects can take with information obtained from objects for which they have already been granted access. This prevents the subjects from passing the information to unauthorized subjects and objects. Mandatory access control policies constrain actions that subjects can take with respect to the propagation of access control privileges; that is, a subject with a privilege cannot pass that privilege to other subjects. The policy is uniformly enforced over all subjects and objects to which the system has control. Otherwise, the access control policy can be circumvented. This enforcement is provided by an implementation that meets the reference monitor concept as described in [AC-25](#ac-25). The policy is bounded by the system (i.e., once the information is passed outside of the control of the system, additional means may be required to ensure that the constraints on the information remain in effect).\n\nThe trusted subjects described above are granted privileges consistent with the concept of least privilege (see [AC-6](#ac-6)). Trusted subjects are only given the minimum privileges necessary for satisfying organizational mission/business needs relative to the above policy. The control is most applicable when there is a mandate that establishes a policy regarding access to controlled unclassified information or classified information and some users of the system are not authorized access to all such information resident in the system. Mandatory access control can operate in conjunction with discretionary access control as described in [AC-3(4)](#ac-3.4). A subject constrained in its operation by mandatory access control policies can still operate under the less rigorous constraints of AC-3(4), but mandatory access control policies take precedence over the less rigorous constraints of AC-3(4). For example, while a mandatory access control policy imposes a constraint that prevents a subject from passing information to another subject operating at a different impact or classification level, AC-3(4) permits the subject to pass the information to any other subject with the same impact or classification level as the subject. Examples of mandatory access control policies include the Bell-LaPadula policy to protect confidentiality of information and the Biba policy to protect the integrity of information." - } - ] - }, - { - "id": "ac-3.4", - "class": "SP800-53-enhancement", - "title": "Discretionary Access Control", - "params": [ - { - "id": "ac-3.4_prm_1", - "label": "organization-defined discretionary access control policy" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(4)" - }, - { - "name": "sort-id", - "value": "ac-03.04" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-3.4_smt", - "name": "statement", - "prose": "Enforce {{ insert: param, ac-3.4_prm_1 }} over the set of covered subjects and objects specified in the policy, and where the policy specifies that a subject that has been granted access to information can do one or more of the following:", - "parts": [ - { - "id": "ac-3.4_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Pass the information to any other subjects or objects;" - }, - { - "id": "ac-3.4_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Grant its privileges to other subjects;" - }, - { - "id": "ac-3.4_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "(c)" - } - ], - "prose": "Change security attributes on subjects, objects, the system, or the system’s components;" - }, - { - "id": "ac-3.4_smt.d", - "name": "item", - "props": [ - { - "name": "label", - "value": "(d)" - } - ], - "prose": "Choose the security attributes to be associated with newly created or revised objects; or" - }, - { - "id": "ac-3.4_smt.e", - "name": "item", - "props": [ - { - "name": "label", - "value": "(e)" - } - ], - "prose": "Change the rules governing access control." - } - ] - }, - { - "id": "ac-3.4_gdn", - "name": "guidance", - "prose": "When discretionary access control policies are implemented, subjects are not constrained with regard to what actions they can take with information for which they have already been granted access. Thus, subjects that have been granted access to information are not prevented from passing the information to other subjects or objects (i.e., subjects have the discretion to pass). Discretionary access control can operate in conjunction with mandatory access control as described in [AC-3(3)](#ac-3.3) and [AC-3(15)](#ac-3.15). A subject that is constrained in its operation by mandatory access control policies can still operate under the less rigorous constraints of discretionary access control. Therefore, while [AC-3(3)](#ac-3.3) imposes constraints that prevent a subject from passing information to another subject operating at a different impact or classification level, [AC-3(4)](#ac-3.4) permits the subject to pass the information to any subject at the same impact or classification level. The policy is bounded by the system. Once the information is passed outside of system control, additional means may be required to ensure that the constraints remain in effect. While traditional definitions of discretionary access control require identity-based access control, that limitation is not required for this particular use of discretionary access control." - } - ] - }, - { - "id": "ac-3.5", - "class": "SP800-53-enhancement", - "title": "Security-relevant Information", - "params": [ - { - "id": "ac-3.5_prm_1", - "label": "organization-defined security-relevant information" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(5)" - }, - { - "name": "sort-id", - "value": "ac-03.05" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#cm-6", - "rel": "related" - }, - { - "href": "#sc-39", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.5_smt", - "name": "statement", - "prose": "Prevent access to {{ insert: param, ac-3.5_prm_1 }} except during secure, non-operable system states." - }, - { - "id": "ac-3.5_gdn", - "name": "guidance", - "prose": "Security-relevant information is information within systems that can potentially impact the operation of security functions or the provision of security services in a manner that could result in failure to enforce system security and privacy policies or maintain the separation of code and data. Security-relevant information includes access control lists, filtering rules for routers or firewalls, configuration parameters for security services, and cryptographic key management information. Secure, non-operable system states include the times in which systems are not performing mission or business-related processing, such as when the system is offline for maintenance, boot-up, troubleshooting, or shut down." - } - ] - }, - { - "id": "ac-3.6", - "class": "SP800-53-enhancement", - "title": "Protection of User and System Information", - "props": [ - { - "name": "label", - "value": "AC-3(6)" - }, - { - "name": "sort-id", - "value": "ac-03.06" - }, - { - "name": "status", - "value": "withdrawn" - } - ], - "links": [ - { - "href": "#mp-4", - "rel": "incorporated-into" - }, - { - "href": "#sc-28", - "rel": "incorporated-into" - } - ] - }, - { - "id": "ac-3.7", - "class": "SP800-53-enhancement", - "title": "Role-based Access Control", - "params": [ - { - "id": "ac-3.7_prm_1", - "label": "organization-defined roles and users authorized to assume such roles" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(7)" - }, - { - "name": "sort-id", - "value": "ac-03.07" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-3.7_smt", - "name": "statement", - "prose": "Enforce a role-based access control policy over defined subjects and objects and control access based upon {{ insert: param, ac-3.7_prm_1 }}." - }, - { - "id": "ac-3.7_gdn", - "name": "guidance", - "prose": "Role-based access control (RBAC) is an access control policy that enforces access to objects and system functions based on the defined role (i.e., job function) of the subject. Organizations can create specific roles based on job functions and the authorizations (i.e., privileges) to perform needed operations on the systems associated with the organization-defined roles. When users are assigned to specific roles, they inherit the authorizations or privileges defined for those roles. RBAC simplifies privilege administration for organizations because privileges are not assigned directly to every user (which can be a large number of individuals) but are instead acquired through role assignments. RBAC can also increase privacy and security risk if individuals assigned to a role are given access to information beyond what they need to support organizational missions or business functions. RBAC can be implemented as a mandatory or discretionary form of access control. For organizations implementing RBAC with mandatory access controls, the requirements in [AC-3(3)](#ac-3.3) define the scope of the subjects and objects covered by the policy." - } - ] - }, - { - "id": "ac-3.8", - "class": "SP800-53-enhancement", - "title": "Revocation of Access Authorizations", - "params": [ - { - "id": "ac-3.8_prm_1", - "label": "organization-defined rules governing the timing of revocations of access authorizations" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(8)" - }, - { - "name": "sort-id", - "value": "ac-03.08" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-3.8_smt", - "name": "statement", - "prose": "Enforce the revocation of access authorizations resulting from changes to the security attributes of subjects and objects based on {{ insert: param, ac-3.8_prm_1 }}." - }, - { - "id": "ac-3.8_gdn", - "name": "guidance", - "prose": "Revocation of access rules may differ based on the types of access revoked. For example, if a subject (i.e., user or process acting on behalf of a user) is removed from a group, access may not be revoked until the next time the object is opened or the next time the subject attempts to access the object. Revocation based on changes to security labels may take effect immediately. Organizations provide alternative approaches on how to make revocations immediate if systems cannot provide such capability and immediate revocation is necessary." - } - ] - }, - { - "id": "ac-3.9", - "class": "SP800-53-enhancement", - "title": "Controlled Release", - "params": [ - { - "id": "ac-3.9_prm_1", - "label": "organization-defined system or system component" - }, - { - "id": "ac-3.9_prm_2", - "label": "organization-defined controls" - }, - { - "id": "ac-3.9_prm_3", - "label": "organization-defined controls" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(9)" - }, - { - "name": "sort-id", - "value": "ac-03.09" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#ca-3", - "rel": "related" - }, - { - "href": "#pt-7", - "rel": "related" - }, - { - "href": "#pt-8", - "rel": "related" - }, - { - "href": "#sa-9", - "rel": "related" - }, - { - "href": "#sc-16", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.9_smt", - "name": "statement", - "prose": "Release information outside of the system only if:", - "parts": [ - { - "id": "ac-3.9_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "The receiving {{ insert: param, ac-3.9_prm_1 }} provides {{ insert: param, ac-3.9_prm_2 }}; and" - }, - { - "id": "ac-3.9_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": " {{ insert: param, ac-3.9_prm_3 }} are used to validate the appropriateness of the information designated for release." - } - ] - }, - { - "id": "ac-3.9_gdn", - "name": "guidance", - "prose": "Organizations can only directly protect information when it resides within the system. Additional controls may be needed to ensure that organizational information is adequately protected once it is transmitted outside of the system. In situations where the system is unable to determine the adequacy of the protections provided by external entities, as a mitigation measure, organizations procedurally determine whether the external systems are providing adequate controls. The means used to determine the adequacy of controls provided by external systems include conducting periodic assessments (inspections/tests), establishing agreements between the organization and its counterpart organizations, or some other process. The means used by external entities to protect the information received need not be the same as those used by the organization, but the means employed are sufficient to provide consistent adjudication of the security and privacy policy to protect the information and individuals’ privacy.\n\nControlled release of information requires systems to implement technical or procedural means to validate the information prior to releasing it to external systems. For example, if the system passes information to a system controlled by another organization, technical means are employed to validate that the security and privacy attributes associated with the exported information are appropriate for the receiving system. Alternatively, if the system passes information to a printer in organization-controlled space, procedural means can be employed to ensure that only authorized individuals gain access to the printer." - } - ] - }, - { - "id": "ac-3.10", - "class": "SP800-53-enhancement", - "title": "Audited Override of Access Control Mechanisms", - "params": [ - { - "id": "ac-3.10_prm_1", - "label": "organization-defined conditions" - }, - { - "id": "ac-3.10_prm_2", - "label": "organization-defined roles" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(10)" - }, - { - "name": "sort-id", - "value": "ac-03.10" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#au-2", - "rel": "related" - }, - { - "href": "#au-6", - "rel": "related" - }, - { - "href": "#au-10", - "rel": "related" - }, - { - "href": "#au-12", - "rel": "related" - }, - { - "href": "#au-14", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.10_smt", - "name": "statement", - "prose": "Employ an audited override of automated access control mechanisms under {{ insert: param, ac-3.10_prm_1 }} by {{ insert: param, ac-3.10_prm_2 }}." - }, - { - "id": "ac-3.10_gdn", - "name": "guidance", - "prose": "In certain situations, such as when there is a threat to human life or an event that threatens the organization’s ability to carry out critical missions or business functions, an override capability for access control mechanisms may be needed. Override conditions are defined by organizations and used only in those limited circumstances. Audit events are defined in [AU-2](#au-2). Audit records are generated in [AU-12](#au-12)." - } - ] - }, - { - "id": "ac-3.11", - "class": "SP800-53-enhancement", - "title": "Restrict Access to Specific Information Types", - "params": [ - { - "id": "ac-3.11_prm_1", - "label": "organization-defined information types" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(11)" - }, - { - "name": "sort-id", - "value": "ac-03.11" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#cm-8", - "rel": "related" - }, - { - "href": "#cm-12", - "rel": "related" - }, - { - "href": "#cm-13", - "rel": "related" - }, - { - "href": "#pm-5", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.11_smt", - "name": "statement", - "prose": "Restrict access to data repositories containing {{ insert: param, ac-3.11_prm_1 }}." - }, - { - "id": "ac-3.11_gdn", - "name": "guidance", - "prose": "Restricting access to specific information is intended to provide flexibility regarding access control of specific information types within a system. For example, role-based access could be employed to allow access to only a specific type of personally identifiable information within a database rather than allowing access to the database in its entirety. Other examples include restricting access to cryptographic keys, authentication information, and selected system information." - } - ] - }, - { - "id": "ac-3.12", - "class": "SP800-53-enhancement", - "title": "Assert and Enforce Application Access", - "params": [ - { - "id": "ac-3.12_prm_1", - "label": "organization-defined system applications and functions" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(12)" - }, - { - "name": "sort-id", - "value": "ac-03.12" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#cm-7", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.12_smt", - "name": "statement", - "parts": [ - { - "id": "ac-3.12_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Require applications to assert, as part of the installation process, the access needed to the following system applications and functions: {{ insert: param, ac-3.12_prm_1 }};" - }, - { - "id": "ac-3.12_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Provide an enforcement mechanism to prevent unauthorized access; and" - }, - { - "id": "ac-3.12_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "(c)" - } - ], - "prose": "Approve access changes after initial installation of the application." - } - ] - }, - { - "id": "ac-3.12_gdn", - "name": "guidance", - "prose": "Asserting and enforcing application access is intended to address applications that need to access existing system applications and functions, including user contacts, global positioning systems, cameras, keyboards, microphones, networks, phones, or other files." - } - ] - }, - { - "id": "ac-3.13", - "class": "SP800-53-enhancement", - "title": "Attribute-based Access Control", - "params": [ - { - "id": "ac-3.13_prm_1", - "label": "organization-defined attributes to assume access permissions" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(13)" - }, - { - "name": "sort-id", - "value": "ac-03.13" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-3.13_smt", - "name": "statement", - "prose": "Enforce attribute-based access control policy over defined subjects and objects and control access based upon {{ insert: param, ac-3.13_prm_1 }}." - }, - { - "id": "ac-3.13_gdn", - "name": "guidance", - "prose": "Attribute-based access control is an access control policy that restricts system access to authorized users based on specified organizational attributes (e.g., job function, identity), action attributes (e.g., read, write, delete), environmental attributes (e.g., time of day, location), and resource attributes (e.g., classification of a document). Organizations can create rules based on attributes and the authorizations (i.e., privileges) to perform needed operations on the systems associated with organization-defined attributes and rules. When users are assigned to attributes defined in attribute-based access control policies or rules, they can be provisioned to a system with the appropriate privileges or dynamically granted access to a protected resource. Attribute-based access control can be implemented as either a mandatory or discretionary form of access control. When implemented with mandatory access controls, the requirements in [AC-3(3)](#ac-3.3) define the scope of the subjects and objects covered by the policy." - } - ] - }, - { - "id": "ac-3.14", - "class": "SP800-53-enhancement", - "title": "Individual Access", - "params": [ - { - "id": "ac-3.14_prm_1", - "label": "organization-defined mechanisms" - }, - { - "id": "ac-3.14_prm_2", - "label": "organization-defined elements" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(14)" - }, - { - "name": "sort-id", - "value": "ac-03.14" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#ia-8", - "rel": "related" - }, - { - "href": "#pm-22", - "rel": "related" - }, - { - "href": "#pm-20", - "rel": "related" - }, - { - "href": "#pm-21", - "rel": "related" - }, - { - "href": "#pt-6", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.14_smt", - "name": "statement", - "prose": "Provide {{ insert: param, ac-3.14_prm_1 }} to enable individuals to have access to the following elements of their personally identifiable information: {{ insert: param, ac-3.14_prm_2 }}." - }, - { - "id": "ac-3.14_gdn", - "name": "guidance", - "prose": "Individual access affords individuals the ability to review personally identifiable information about them held within organizational records, regardless of format. Access helps individuals to develop an understanding about how their personally identifiable information is being processed. It can also help individuals ensure that their data is accurate. Access mechanisms can include request forms and application interfaces. For federal agencies, [PRIVACT](#18e71fec-c6fd-475a-925a-5d8495cf8455) processes can be located in systems of record notices and on agency websites. Access to certain types of records may not be appropriate (e.g., for federal agencies, law enforcement records within a system of records may be exempt from disclosure under the [PRIVACT](#18e71fec-c6fd-475a-925a-5d8495cf8455)) or may require certain levels of authentication assurance. Organizational personnel consult with the senior agency official for privacy and legal counsel to determine appropriate mechanisms and access rights or limitations." - } - ] - }, - { - "id": "ac-3.15", - "class": "SP800-53-enhancement", - "title": "Discretionary and Mandatory Access Control", - "params": [ - { - "id": "ac-3.15_prm_1", - "label": "organization-defined mandatory access control policy" - }, - { - "id": "ac-3.15_prm_2", - "label": "organization-defined discretionary access control policy" - } - ], - "props": [ - { - "name": "label", - "value": "AC-3(15)" - }, - { - "name": "sort-id", - "value": "ac-03.15" - } - ], - "links": [ - { - "href": "#ac-3", - "rel": "required" - }, - { - "href": "#sc-2", - "rel": "related" - }, - { - "href": "#sc-3", - "rel": "related" - }, - { - "href": "#ac-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-3.15_smt", - "name": "statement", - "parts": [ - { - "id": "ac-3.15_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Enforce {{ insert: param, ac-3.15_prm_1 }} over the set of covered subjects and objects specified in the policy; and" - }, - { - "id": "ac-3.15_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Enforce {{ insert: param, ac-3.15_prm_2 }} over the set of covered subjects and objects specified in the policy." - } - ] - }, - { - "id": "ac-3.15_gdn", - "name": "guidance", - "prose": "Simultaneously implementing a mandatory access control policy and a discretionary access control policy can provide additional protection against the unauthorized execution of code by users or processes acting on behalf of users. This helps prevent a single compromised user or process from compromising the entire system." - } - ] - } - ] - }, - { - "id": "ac-4", - "class": "SP800-53", - "title": "Information Flow Enforcement", - "params": [ - { - "id": "ac-4_prm_1", - "label": "organization-defined information flow control policies" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4" - }, - { - "name": "sort-id", - "value": "ac-04" - } - ], - "links": [ - { - "href": "#e3cc0520-a366-4fc9-abc2-5272db7e3564", - "rel": "reference" - }, - { - "href": "#2956e175-f674-43f4-b1b9-e074ad9fc39c", - "rel": "reference" - }, - { - "href": "#388a3aa2-5d85-4bad-b8a3-77db80d63c4f", - "rel": "reference" - }, - { - "href": "#a2590922-82f3-4277-83c0-ca5bee06dba4", - "rel": "reference" - }, - { - "href": "#ac-3", - "rel": "related" - }, - { - "href": "#ac-6", - "rel": "related" - }, - { - "href": "#ac-16", - "rel": "related" - }, - { - "href": "#ac-17", - "rel": "related" - }, - { - "href": "#ac-19", - "rel": "related" - }, - { - "href": "#ac-21", - "rel": "related" - }, - { - "href": "#au-10", - "rel": "related" - }, - { - "href": "#ca-3", - "rel": "related" - }, - { - "href": "#ca-9", - "rel": "related" - }, - { - "href": "#cm-7", - "rel": "related" - }, - { - "href": "#pl-9", - "rel": "related" - }, - { - "href": "#pm-24", - "rel": "related" - }, - { - "href": "#sa-17", - "rel": "related" - }, - { - "href": "#sc-4", - "rel": "related" - }, - { - "href": "#sc-7", - "rel": "related" - }, - { - "href": "#sc-16", - "rel": "related" - }, - { - "href": "#sc-31", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4_smt", - "name": "statement", - "prose": "Enforce approved authorizations for controlling the flow of information within the system and between connected systems based on {{ insert: param, ac-4_prm_1 }}." - }, - { - "id": "ac-4_gdn", - "name": "guidance", - "prose": "Information flow control regulates where information can travel within a system and between systems (in contrast to who is allowed to access the information) and without regard to subsequent accesses to that information. Flow control restrictions include blocking external traffic that claims to be from within the organization, keeping export-controlled information from being transmitted in the clear to the Internet, restricting web requests that are not from the internal web proxy server, and limiting information transfers between organizations based on data structures and content. Transferring information between organizations may require an agreement specifying how the information flow is enforced (see [CA-3](#ca-3)). Transferring information between systems in different security or privacy domains with different security or privacy policies introduces the risk that such transfers violate one or more domain security or privacy policies. In such situations, information owners/stewards provide guidance at designated policy enforcement points between connected systems. Organizations consider mandating specific architectural solutions to enforce specific security and privacy policies. Enforcement includes prohibiting information transfers between connected systems (i.e., allowing access only), verifying write permissions before accepting information from another security or privacy domain or connected system, employing hardware mechanisms to enforce one-way information flows, and implementing trustworthy regrading mechanisms to reassign security or privacy attributes and labels.\n\nOrganizations commonly employ information flow control policies and enforcement mechanisms to control the flow of information between designated sources and destinations within systems and between connected systems. Flow control is based on the characteristics of the information and/or the information path. Enforcement occurs, for example, in boundary protection devices that employ rule sets or establish configuration settings that restrict system services, provide a packet-filtering capability based on header information, or provide a message-filtering capability based on message content. Organizations also consider the trustworthiness of filtering and/or inspection mechanisms (i.e., hardware, firmware, and software components) that are critical to information flow enforcement. Control enhancements 3 through 32 primarily address cross-domain solution needs that focus on more advanced filtering techniques, in-depth analysis, and stronger flow enforcement mechanisms implemented in cross-domain products, such as high-assurance guards. Such capabilities are generally not available in commercial off-the-shelf products. Information flow enforcement also applies to control plane traffic (e.g., routing and DNS)." - } - ], - "controls": [ - { - "id": "ac-4.1", - "class": "SP800-53-enhancement", - "title": "Object Security and Privacy Attributes", - "params": [ - { - "id": "ac-4.1_prm_1", - "label": "organization-defined security and privacy attributes" - }, - { - "id": "ac-4.1_prm_2", - "label": "organization-defined information, source, and destination objects" - }, - { - "id": "ac-4.1_prm_3", - "label": "organization-defined information flow control policies" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(1)" - }, - { - "name": "sort-id", - "value": "ac-04.01" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.1_smt", - "name": "statement", - "prose": "Use {{ insert: param, ac-4.1_prm_1 }} associated with {{ insert: param, ac-4.1_prm_2 }} to enforce {{ insert: param, ac-4.1_prm_3 }} as a basis for flow control decisions." - }, - { - "id": "ac-4.1_gdn", - "name": "guidance", - "prose": "Information flow enforcement mechanisms compare security and privacy attributes associated with information (i.e., data content and structure) and source and destination objects and respond appropriately when the enforcement mechanisms encounter information flows not explicitly allowed by information flow policies. For example, an information object labeled Secret would be allowed to flow to a destination object labeled Secret, but an information object labeled Top Secret would not be allowed to flow to a destination object labeled Secret. A dataset of personally identifiable information may be tagged with restrictions against combining with other types of datasets and, thus, would not be allowed to flow to the restricted dataset. Security and privacy attributes can also include source and destination addresses employed in traffic filter firewalls. Flow enforcement using explicit security or privacy attributes can be used, for example, to control the release of certain types of information." - } - ] - }, - { - "id": "ac-4.2", - "class": "SP800-53-enhancement", - "title": "Processing Domains", - "params": [ - { - "id": "ac-4.2_prm_1", - "label": "organization-defined information flow control policies" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(2)" - }, - { - "name": "sort-id", - "value": "ac-04.02" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#sc-39", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.2_smt", - "name": "statement", - "prose": "Use protected processing domains to enforce {{ insert: param, ac-4.2_prm_1 }} as a basis for flow control decisions." - }, - { - "id": "ac-4.2_gdn", - "name": "guidance", - "prose": "Protected processing domains within systems are processing spaces that have controlled interactions with other processing spaces, enabling control of information flows between these spaces and to/from information objects. A protected processing domain can be provided, for example, by implementing domain and type enforcement. In domain and type enforcement, system processes are assigned to domains, information is identified by types, and information flows are controlled based on allowed information accesses (i.e., determined by domain and type), allowed signaling among domains, and allowed process transitions to other domains." - } - ] - }, - { - "id": "ac-4.3", - "class": "SP800-53-enhancement", - "title": "Dynamic Information Flow Control", - "params": [ - { - "id": "ac-4.3_prm_1", - "label": "organization-defined information flow control policies" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(3)" - }, - { - "name": "sort-id", - "value": "ac-04.03" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#si-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.3_smt", - "name": "statement", - "prose": "Enforce {{ insert: param, ac-4.3_prm_1 }}." - }, - { - "id": "ac-4.3_gdn", - "name": "guidance", - "prose": "Organizational policies regarding dynamic information flow control include allowing or disallowing information flows based on changing conditions or mission or operational considerations. Changing conditions include changes in risk tolerance due to changes in the immediacy of mission or business needs, changes in the threat environment, and detection of potentially harmful or adverse events." - } - ] - }, - { - "id": "ac-4.4", - "class": "SP800-53-enhancement", - "title": "Flow Control of Encrypted Information", - "params": [ - { - "id": "ac-4.4_prm_1", - "label": "organization-defined information flow control mechanisms" - }, - { - "id": "ac-4.4_prm_2", - "select": { - "how-many": "one-or-more", - "choice": [ - "decrypting the information", - "blocking the flow of the encrypted information", - "terminating communications sessions attempting to pass encrypted information", - " {{ insert: param, ac-4.4_prm_3 }} " - ] - } - }, - { - "id": "ac-4.4_prm_3", - "depends-on": "ac-4.4_prm_2", - "label": "organization-defined procedure or method", - "values": ["my procedure"] - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(4)" - }, - { - "name": "sort-id", - "value": "ac-04.04" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#si-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.4_smt", - "name": "statement", - "prose": "Prevent encrypted information from bypassing {{ insert: param, ac-4.4_prm_1 }} by {{ insert: param, ac-4.4_prm_2 }}." - }, - { - "id": "ac-4.4_gdn", - "name": "guidance", - "prose": "Flow control mechanisms include content checking, security policy filters, and data type identifiers. The term encryption is extended to cover encoded data not recognized by filtering mechanisms." - } - ] - }, - { - "id": "ac-4.5", - "class": "SP800-53-enhancement", - "title": "Embedded Data Types", - "params": [ - { - "id": "ac-4.5_prm_1", - "label": "organization-defined limitations" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(5)" - }, - { - "name": "sort-id", - "value": "ac-04.05" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.5_smt", - "name": "statement", - "prose": "Enforce {{ insert: param, ac-4.5_prm_1 }} on embedding data types within other data types." - }, - { - "id": "ac-4.5_gdn", - "name": "guidance", - "prose": "Embedding data types within other data types may result in reduced flow control effectiveness. Data type embedding includes inserting files as objects within other files and using compressed or archived data types that may include multiple embedded data types. Limitations on data type embedding consider the levels of embedding and prohibit levels of data type embedding that are beyond the capability of the inspection tools." - } - ] - }, - { - "id": "ac-4.6", - "class": "SP800-53-enhancement", - "title": "Metadata", - "params": [ - { - "id": "ac-4.6_prm_1", - "label": "organization-defined metadata" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(6)" - }, - { - "name": "sort-id", - "value": "ac-04.06" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#ac-16", - "rel": "related" - }, - { - "href": "#si-7", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.6_smt", - "name": "statement", - "prose": "Enforce information flow control based on {{ insert: param, ac-4.6_prm_1 }}." - }, - { - "id": "ac-4.6_gdn", - "name": "guidance", - "prose": "Metadata is information that describes the characteristics of data. Metadata can include structural metadata describing data structures or descriptive metadata describing data content. Enforcement of allowed information flows based on metadata enables simpler and more effective flow control. Organizations consider the trustworthiness of metadata regarding data accuracy (i.e., knowledge that the metadata values are correct with respect to the data), data integrity (i.e., protecting against unauthorized changes to metadata tags), and the binding of metadata to the data payload (i.e., employing sufficiently strong binding techniques with appropriate assurance)." - } - ] - }, - { - "id": "ac-4.7", - "class": "SP800-53-enhancement", - "title": "One-way Flow Mechanisms", - "props": [ - { - "name": "label", - "value": "AC-4(7)" - }, - { - "name": "sort-id", - "value": "ac-04.07" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.7_smt", - "name": "statement", - "prose": "Enforce one-way information flows through hardware-based flow control mechanisms." - }, - { - "id": "ac-4.7_gdn", - "name": "guidance", - "prose": "One-way flow mechanisms may also be referred to as a unidirectional network, unidirectional security gateway, or data diode. One-way flow mechanisms can be used to prevent data from being exported from a higher impact or classified domain or system while permitting data from a lower impact or unclassified domain or system to be imported." - } - ] - }, - { - "id": "ac-4.8", - "class": "SP800-53-enhancement", - "title": "Security and Privacy Policy Filters", - "params": [ - { - "id": "ac-4.8_prm_1", - "label": "organization-defined security or privacy policy filters" - }, - { - "id": "ac-4.8_prm_2", - "label": "organization-defined information flows" - }, - { - "id": "ac-4.8_prm_3", - "select": { - "how-many": "one-or-more", - "choice": [ - "Block", - "Strip", - "Modify", - "Quarantine" - ] - } - }, - { - "id": "ac-4.8_prm_4", - "label": "organization-defined security or privacy policy" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(8)" - }, - { - "name": "sort-id", - "value": "ac-04.08" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.8_smt", - "name": "statement", - "parts": [ - { - "id": "ac-4.8_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Enforce information flow control using {{ insert: param, ac-4.8_prm_1 }} as a basis for flow control decisions for {{ insert: param, ac-4.8_prm_2 }}; and" - }, - { - "id": "ac-4.8_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": " {{ insert: param, ac-4.8_prm_3 }} data after a filter processing failure in accordance with {{ insert: param, ac-4.8_prm_4 }}." - } - ] - }, - { - "id": "ac-4.8_gdn", - "name": "guidance", - "prose": "Organization-defined security or privacy policy filters can address data structures and content. For example, security or privacy policy filters for data structures can check for maximum file lengths, maximum field sizes, and data/file types (for structured and unstructured data). Security or privacy policy filters for data content can check for specific words, enumerated values or data value ranges, and hidden content. Structured data permits the interpretation of data content by applications. Unstructured data refers to digital information without a data structure or with a data structure that does not facilitate the development of rule sets to address the impact or classification level of the information conveyed by the data or the flow enforcement decisions. Unstructured data consists of bitmap objects that are inherently non-language-based (i.e., image, video, or audio files) and textual objects that are based on written or printed languages. Organizations can implement more than one security or privacy policy filter to meet information flow control objectives." - } - ] - }, - { - "id": "ac-4.9", - "class": "SP800-53-enhancement", - "title": "Human Reviews", - "params": [ - { - "id": "ac-4.9_prm_1", - "label": "organization-defined information flows" - }, - { - "id": "ac-4.9_prm_2", - "label": "organization-defined conditions" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(9)" - }, - { - "name": "sort-id", - "value": "ac-04.09" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.9_smt", - "name": "statement", - "prose": "Enforce the use of human reviews for {{ insert: param, ac-4.9_prm_1 }} under the following conditions: {{ insert: param, ac-4.9_prm_2 }}." - }, - { - "id": "ac-4.9_gdn", - "name": "guidance", - "prose": "Organizations define security or privacy policy filters for all situations where automated flow control decisions are possible. When a fully automated flow control decision is not possible, then a human review may be employed in lieu of or as a complement to automated security or privacy policy filtering. Human reviews may also be employed as deemed necessary by organizations." - } - ] - }, - { - "id": "ac-4.10", - "class": "SP800-53-enhancement", - "title": "Enable and Disable Security or Privacy Policy Filters", - "params": [ - { - "id": "ac-4.10_prm_1", - "label": "organization-defined security or privacy policy filters" - }, - { - "id": "ac-4.10_prm_2", - "label": "organization-defined conditions" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(10)" - }, - { - "name": "sort-id", - "value": "ac-04.10" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.10_smt", - "name": "statement", - "prose": "Provide the capability for privileged administrators to enable and disable {{ insert: param, ac-4.10_prm_1 }} under the following conditions: {{ insert: param, ac-4.10_prm_2 }}." - }, - { - "id": "ac-4.10_gdn", - "name": "guidance", - "prose": "For example, as allowed by the system authorization, administrators can enable security or privacy policy filters to accommodate approved data types. Administrators also have the capability to select the filters that are executed on a specific data flow based on the type of data that is being transferred, the source and destination security domains, and other security or privacy relevant features, as needed." - } - ] - }, - { - "id": "ac-4.11", - "class": "SP800-53-enhancement", - "title": "Configuration of Security or Privacy Policy Filters", - "params": [ - { - "id": "ac-4.11_prm_1", - "label": "organization-defined security or privacy policy filters" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(11)" - }, - { - "name": "sort-id", - "value": "ac-04.11" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.11_smt", - "name": "statement", - "prose": "Provide the capability for privileged administrators to configure {{ insert: param, ac-4.11_prm_1 }} to support different security or privacy policies." - }, - { - "id": "ac-4.11_gdn", - "name": "guidance", - "prose": "Documentation contains detailed information for configuring security or privacy policy filters. For example, administrators can configure security or privacy policy filters to include the list of inappropriate words that security or privacy policy mechanisms check in accordance with the definitions provided by organizations." - } - ] - }, - { - "id": "ac-4.12", - "class": "SP800-53-enhancement", - "title": "Data Type Identifiers", - "params": [ - { - "id": "ac-4.12_prm_1", - "label": "organization-defined data type identifiers" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(12)" - }, - { - "name": "sort-id", - "value": "ac-04.12" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.12_smt", - "name": "statement", - "prose": "When transferring information between different security domains, use {{ insert: param, ac-4.12_prm_1 }} to validate data essential for information flow decisions." - }, - { - "id": "ac-4.12_gdn", - "name": "guidance", - "prose": "Data type identifiers include filenames, file types, file signatures or tokens, and multiple internal file signatures or tokens. Systems only allow transfer of data that is compliant with data type format specifications. Identification and validation of data types is based on defined specifications associated with each allowed data format. The filename and number alone are not used for data type identification. Content is validated syntactically and semantically against its specification to ensure that it is the proper data type." - } - ] - }, - { - "id": "ac-4.13", - "class": "SP800-53-enhancement", - "title": "Decomposition into Policy-relevant Subcomponents", - "params": [ - { - "id": "ac-4.13_prm_1", - "label": "organization-defined policy-relevant subcomponents" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(13)" - }, - { - "name": "sort-id", - "value": "ac-04.13" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.13_smt", - "name": "statement", - "prose": "When transferring information between different security domains, decompose information into {{ insert: param, ac-4.13_prm_1 }} for submission to policy enforcement mechanisms." - }, - { - "id": "ac-4.13_gdn", - "name": "guidance", - "prose": "Decomposing information into policy-relevant subcomponents prior to information transfer facilitates policy decisions on source, destination, certificates, classification, attachments, and other security- or privacy-related component differentiators. Policy enforcement mechanisms apply filtering, inspection, and/or sanitization rules to the policy-relevant subcomponents of information to facilitate flow enforcement prior to transferring such information to different security domains." - } - ] - }, - { - "id": "ac-4.14", - "class": "SP800-53-enhancement", - "title": "Security or Privacy Policy Filter Constraints", - "params": [ - { - "id": "ac-4.14_prm_1", - "label": "organization-defined security or privacy policy filters" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(14)" - }, - { - "name": "sort-id", - "value": "ac-04.14" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.14_smt", - "name": "statement", - "prose": "When transferring information between different security domains, implement {{ insert: param, ac-4.14_prm_1 }} requiring fully enumerated formats that restrict data structure and content." - }, - { - "id": "ac-4.14_gdn", - "name": "guidance", - "prose": "Data structure and content restrictions reduce the range of potential malicious or unsanctioned content in cross-domain transactions. Security or privacy policy filters that restrict data structures include restricting file sizes and field lengths. Data content policy filters include encoding formats for character sets, restricting character data fields to only contain alpha-numeric characters, prohibiting special characters, and validating schema structures." - } - ] - }, - { - "id": "ac-4.15", - "class": "SP800-53-enhancement", - "title": "Detection of Unsanctioned Information", - "params": [ - { - "id": "ac-4.15_prm_1", - "label": "organization-defined unsanctioned information" - }, - { - "id": "ac-4.15_prm_2", - "label": "organization-defined security or privacy policy" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(15)" - }, - { - "name": "sort-id", - "value": "ac-04.15" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#si-3", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.15_smt", - "name": "statement", - "prose": "When transferring information between different security domains, examine the information for the presence of {{ insert: param, ac-4.15_prm_1 }} and prohibit the transfer of such information in accordance with the {{ insert: param, ac-4.15_prm_2 }}." - }, - { - "id": "ac-4.15_gdn", - "name": "guidance", - "prose": "Unsanctioned information includes malicious code, information that is inappropriate for release from the source network, or executable code that could disrupt or harm the services or systems on the destination network." - } - ] - }, - { - "id": "ac-4.16", - "class": "SP800-53-enhancement", - "title": "Information Transfers on Interconnected Systems", - "props": [ - { - "name": "label", - "value": "AC-4(16)" - }, - { - "name": "sort-id", - "value": "ac-04.16" - }, - { - "name": "status", - "value": "withdrawn" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "incorporated-into" - } - ] - }, - { - "id": "ac-4.17", - "class": "SP800-53-enhancement", - "title": "Domain Authentication", - "params": [ - { - "id": "ac-4.17_prm_1", - "select": { - "how-many": "one-or-more", - "choice": [ - "organization", - "system", - "application", - "service", - "individual" - ] - } - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(17)" - }, - { - "name": "sort-id", - "value": "ac-04.17" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#ia-2", - "rel": "related" - }, - { - "href": "#ia-3", - "rel": "related" - }, - { - "href": "#ia-9", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.17_smt", - "name": "statement", - "prose": "Uniquely identify and authenticate source and destination points by {{ insert: param, ac-4.17_prm_1 }} for information transfer." - }, - { - "id": "ac-4.17_gdn", - "name": "guidance", - "prose": "Attribution is a critical component of a security and privacy concept of operations. The ability to identify source and destination points for information flowing within systems allows the forensic reconstruction of events and encourages policy compliance by attributing policy violations to specific organizations or individuals. Successful domain authentication requires that system labels distinguish among systems, organizations, and individuals involved in preparing, sending, receiving, or disseminating information. Attribution also allows organizations to better maintain the lineage of personally identifiable information processing as it flows through systems and can facilitate consent tracking, as well as correction, deletion, or access requests from individuals." - } - ] - }, - { - "id": "ac-4.18", - "class": "SP800-53-enhancement", - "title": "Security Attribute Binding", - "props": [ - { - "name": "label", - "value": "AC-4(18)" - }, - { - "name": "sort-id", - "value": "ac-04.18" - }, - { - "name": "status", - "value": "withdrawn" - } - ], - "links": [ - { - "href": "#ac-16", - "rel": "incorporated-into" - } - ] - }, - { - "id": "ac-4.19", - "class": "SP800-53-enhancement", - "title": "Validation of Metadata", - "params": [ - { - "id": "ac-4.19_prm_1", - "label": "organization-defined security or privacy policy filters" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(19)" - }, - { - "name": "sort-id", - "value": "ac-04.19" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.19_smt", - "name": "statement", - "prose": "When transferring information between different security domains, implement {{ insert: param, ac-4.19_prm_1 }} on metadata." - }, - { - "id": "ac-4.19_gdn", - "name": "guidance", - "prose": "All information (including metadata and the data to which the metadata applies) is subject to filtering and inspection. Some organizations distinguish between metadata and data payloads (i.e., only the data to which the metadata is bound). Other organizations do not make such distinctions and consider metadata and the data to which the metadata applies to be part of the payload." - } - ] - }, - { - "id": "ac-4.20", - "class": "SP800-53-enhancement", - "title": "Approved Solutions", - "params": [ - { - "id": "ac-4.20_prm_1", - "label": "organization-defined solutions in approved configurations" - }, - { - "id": "ac-4.20_prm_2", - "label": "organization-defined information" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(20)" - }, - { - "name": "sort-id", - "value": "ac-04.20" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.20_smt", - "name": "statement", - "prose": "Employ {{ insert: param, ac-4.20_prm_1 }} to control the flow of {{ insert: param, ac-4.20_prm_2 }} across security domains." - }, - { - "id": "ac-4.20_gdn", - "name": "guidance", - "prose": "Organizations define approved solutions and configurations in cross-domain policies and guidance in accordance with the types of information flows across classification boundaries. The National Security Agency (NSA) National Cross Domain Strategy and Management Office provides a listing of approved cross-domain solutions. Contact [ncdsmo@nsa.gov](mailto:ncdsmo@nsa.gov) for more information." - } - ] - }, - { - "id": "ac-4.21", - "class": "SP800-53-enhancement", - "title": "Physical or Logical Separation of Information Flows", - "params": [ - { - "id": "ac-4.21_prm_1", - "label": "organization-defined mechanisms and/or techniques" - }, - { - "id": "ac-4.21_prm_2", - "label": "organization-defined required separations by types of information" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(21)" - }, - { - "name": "sort-id", - "value": "ac-04.21" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#sc-32", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.21_smt", - "name": "statement", - "prose": "Separate information flows logically or physically using {{ insert: param, ac-4.21_prm_1 }} to accomplish {{ insert: param, ac-4.21_prm_2 }}." - }, - { - "id": "ac-4.21_gdn", - "name": "guidance", - "prose": "Enforcing the separation of information flows associated with defined types of data can enhance protection by ensuring that information is not commingled while in transit and by enabling flow control by transmission paths that are not otherwise achievable. Types of separable information include inbound and outbound communications traffic, service requests and responses, and information of differing security impact or classification levels." - } - ] - }, - { - "id": "ac-4.22", - "class": "SP800-53-enhancement", - "title": "Access Only", - "props": [ - { - "name": "label", - "value": "AC-4(22)" - }, - { - "name": "sort-id", - "value": "ac-04.22" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.22_smt", - "name": "statement", - "prose": "Provide access from a single device to computing platforms, applications, or data residing in multiple different security domains, while preventing information flow between the different security domains." - }, - { - "id": "ac-4.22_gdn", - "name": "guidance", - "prose": "The system provides a capability for users to access each connected security domain without providing any mechanisms to allow users to transfer data or information between the different security domains. An example of an access-only solution is a terminal that provides a user access to information with different security classifications while assuredly keeping the information separate." - } - ] - }, - { - "id": "ac-4.23", - "class": "SP800-53-enhancement", - "title": "Modify Non-releasable Information", - "params": [ - { - "id": "ac-4.23_prm_1", - "label": "organization-defined modification action" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(23)" - }, - { - "name": "sort-id", - "value": "ac-04.23" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.23_smt", - "name": "statement", - "prose": "When transferring information between different security domains, modify non-releasable information by implementing {{ insert: param, ac-4.23_prm_1 }}." - }, - { - "id": "ac-4.23_gdn", - "name": "guidance", - "prose": "Modifying non-releasable information can help prevent a data spill or attack when information is transferred across security domains. Modification actions include masking, permutation, alteration, removal, or redaction." - } - ] - }, - { - "id": "ac-4.24", - "class": "SP800-53-enhancement", - "title": "Internal Normalized Format", - "props": [ - { - "name": "label", - "value": "AC-4(24)" - }, - { - "name": "sort-id", - "value": "ac-04.24" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.24_smt", - "name": "statement", - "prose": "When transferring information between different security domains, parse incoming data into an internal normalized format and regenerate the data to be consistent with its intended specification." - }, - { - "id": "ac-4.24_gdn", - "name": "guidance", - "prose": "Converting data into normalized forms is one of most of effective mechanisms to stop malicious attacks and large classes of data exfiltration." - } - ] - }, - { - "id": "ac-4.25", - "class": "SP800-53-enhancement", - "title": "Data Sanitization", - "params": [ - { - "id": "ac-4.25_prm_1", - "select": { - "how-many": "one-or-more", - "choice": [ - "delivery of malicious content, command and control of malicious code, malicious code augmentation, and steganography encoded data", - "spillage of sensitive information" - ] - } - }, - { - "id": "ac-4.25_prm_2", - "label": "organization-defined policy" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(25)" - }, - { - "name": "sort-id", - "value": "ac-04.25" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#mp-6", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.25_smt", - "name": "statement", - "prose": "When transferring information between different security domains, sanitize data to minimize {{ insert: param, ac-4.25_prm_1 }} in accordance with {{ insert: param, ac-4.25_prm_2 }}." - }, - { - "id": "ac-4.25_gdn", - "name": "guidance", - "prose": "Data sanitization is the process of irreversibly removing or destroying data stored on a memory device (e.g., hard drives, flash memory/solid state drives, mobile devices, CDs, and DVDs) or in hard copy form." - } - ] - }, - { - "id": "ac-4.26", - "class": "SP800-53-enhancement", - "title": "Audit Filtering Actions", - "props": [ - { - "name": "label", - "value": "AC-4(26)" - }, - { - "name": "sort-id", - "value": "ac-04.26" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - }, - { - "href": "#au-2", - "rel": "related" - }, - { - "href": "#au-3", - "rel": "related" - }, - { - "href": "#au-12", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-4.26_smt", - "name": "statement", - "prose": "When transferring information between different security domains, record and audit content filtering actions and results for the information being filtered." - }, - { - "id": "ac-4.26_gdn", - "name": "guidance", - "prose": "Content filtering is the process of inspecting information as it traverses a cross-domain solution and determines if the information meets a predefined policy. Content filtering actions and the results of filtering actions are recorded for individual messages to ensure that the correct filter actions were applied. Content filter reports are used to assist in troubleshooting actions by, for example, determining why message content was modified and/or why it failed the filtering process. Audit events are defined in [AU-2](#au-2). Audit records are generated in [AU-12](#au-12)." - } - ] - }, - { - "id": "ac-4.27", - "class": "SP800-53-enhancement", - "title": "Redundant/independent Filtering Mechanisms", - "props": [ - { - "name": "label", - "value": "AC-4(27)" - }, - { - "name": "sort-id", - "value": "ac-04.27" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.27_smt", - "name": "statement", - "prose": "When transferring information between different security domains, implement content filtering solutions that provide redundant and independent filtering mechanisms for each data type." - }, - { - "id": "ac-4.27_gdn", - "name": "guidance", - "prose": "Content filtering is the process of inspecting information as it traverses a cross-domain solution and determines if the information meets a predefined policy. Redundant and independent content filtering eliminates a single point of failure filtering system. Independence is defined as the implementation of a content filter that uses a different code base and supporting libraries (e.g., two JPEG filters using different vendors’ JPEG libraries) and multiple, independent system processes." - } - ] - }, - { - "id": "ac-4.28", - "class": "SP800-53-enhancement", - "title": "Linear Filter Pipelines", - "props": [ - { - "name": "label", - "value": "AC-4(28)" - }, - { - "name": "sort-id", - "value": "ac-04.28" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.28_smt", - "name": "statement", - "prose": "When transferring information between different security domains, implement a linear content filter pipeline that is enforced with discretionary and mandatory access controls." - }, - { - "id": "ac-4.28_gdn", - "name": "guidance", - "prose": "Content filtering is the process of inspecting information as it traverses a cross-domain solution and determines if the information meets a predefined policy. The use of linear content filter pipelines ensures that filter processes are non-bypassable and always invoked. In general, the use of parallel filtering architectures for content filtering of a single data type introduces bypass and non-invocation issues." - } - ] - }, - { - "id": "ac-4.29", - "class": "SP800-53-enhancement", - "title": "Filter Orchestration Engines", - "params": [ - { - "id": "ac-4.29_prm_1", - "label": "organization-defined policy" - } - ], - "props": [ - { - "name": "label", - "value": "AC-4(29)" - }, - { - "name": "sort-id", - "value": "ac-04.29" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.29_smt", - "name": "statement", - "prose": "When transferring information between different security domains, employ content filter orchestration engines to ensure that:", - "parts": [ - { - "id": "ac-4.29_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Content filtering mechanisms successfully complete execution without errors; and" - }, - { - "id": "ac-4.29_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Content filtering actions occur in the correct order and comply with {{ insert: param, ac-4.29_prm_1 }}." - } - ] - }, - { - "id": "ac-4.29_gdn", - "name": "guidance", - "prose": "Content filtering is the process of inspecting information as it traverses a cross-domain solution and determines if the information meets a predefined security policy. An orchestration engine coordinates the sequencing of activities (manual and automated) in a content filtering process. Errors are defined as either anomalous actions or unexpected termination of the content filter process. This is not the same as a filter failing content due to non-compliance with policy. Content filter reports are a commonly used mechanism to ensure that expected filtering actions are completed successfully." - } - ] - }, - { - "id": "ac-4.30", - "class": "SP800-53-enhancement", - "title": "Filter Mechanisms Using Multiple Processes", - "props": [ - { - "name": "label", - "value": "AC-4(30)" - }, - { - "name": "sort-id", - "value": "ac-04.30" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.30_smt", - "name": "statement", - "prose": "When transferring information between different security domains, implement content filtering mechanisms using multiple processes." - }, - { - "id": "ac-4.30_gdn", - "name": "guidance", - "prose": "The use of multiple processes to implement content filtering mechanisms reduces the likelihood of a single point of failure." - } - ] - }, - { - "id": "ac-4.31", - "class": "SP800-53-enhancement", - "title": "Failed Content Transfer Prevention", - "props": [ - { - "name": "label", - "value": "AC-4(31)" - }, - { - "name": "sort-id", - "value": "ac-04.31" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.31_smt", - "name": "statement", - "prose": "When transferring information between different security domains, prevent the transfer of failed content to the receiving domain." - }, - { - "id": "ac-4.31_gdn", - "name": "guidance", - "prose": "Content that failed filtering checks can corrupt the system if transferred to the receiving domain." - } - ] - }, - { - "id": "ac-4.32", - "class": "SP800-53-enhancement", - "title": "Process Requirements for Information Transfer", - "props": [ - { - "name": "label", - "value": "AC-4(32)" - }, - { - "name": "sort-id", - "value": "ac-04.32" - } - ], - "links": [ - { - "href": "#ac-4", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-4.32_smt", - "name": "statement", - "prose": "When transferring information between different security domains, the process that transfers information between filter pipelines:", - "parts": [ - { - "id": "ac-4.32_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Does not filter message content;" - }, - { - "id": "ac-4.32_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Validates filtering metadata;" - }, - { - "id": "ac-4.32_smt.c", - "name": "item", - "props": [ - { - "name": "label", - "value": "(c)" - } - ], - "prose": "Ensures the content associated with the filtering metadata has successfully completed filtering; and" - }, - { - "id": "ac-4.32_smt.d", - "name": "item", - "props": [ - { - "name": "label", - "value": "(d)" - } - ], - "prose": "Transfers the content to the destination filter pipeline." - } - ] - }, - { - "id": "ac-4.32_gdn", - "name": "guidance", - "prose": "The processes transferring information between filter pipelines have minimum complexity and functionality to provide assurance that the processes operate correctly." - } - ] - } - ] - }, - { - "id": "ac-5", - "class": "SP800-53", - "title": "Separation of Duties", - "params": [ - { - "id": "ac-5_prm_1", - "label": "organization-defined duties of individuals requiring separation" - } - ], - "props": [ - { - "name": "label", - "value": "AC-5" - }, - { - "name": "sort-id", - "value": "ac-05" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "related" - }, - { - "href": "#ac-3", - "rel": "related" - }, - { - "href": "#ac-6", - "rel": "related" - }, - { - "href": "#au-9", - "rel": "related" - }, - { - "href": "#cm-5", - "rel": "related" - }, - { - "href": "#cm-11", - "rel": "related" - }, - { - "href": "#cp-9", - "rel": "related" - }, - { - "href": "#ia-2", - "rel": "related" - }, - { - "href": "#ia-4", - "rel": "related" - }, - { - "href": "#ia-5", - "rel": "related" - }, - { - "href": "#ia-12", - "rel": "related" - }, - { - "href": "#ma-3", - "rel": "related" - }, - { - "href": "#ma-5", - "rel": "related" - }, - { - "href": "#ps-2", - "rel": "related" - }, - { - "href": "#sa-8", - "rel": "related" - }, - { - "href": "#sa-17", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-5_smt", - "name": "statement", - "parts": [ - { - "id": "ac-5_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "a." - } - ], - "prose": "Identify and document {{ insert: param, ac-5_prm_1 }}; and" - }, - { - "id": "ac-5_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "b." - } - ], - "prose": "Define system access authorizations to support separation of duties." - } - ] - }, - { - "id": "ac-5_gdn", - "name": "guidance", - "prose": "Separation of duties addresses the potential for abuse of authorized privileges and helps to reduce the risk of malevolent activity without collusion. Separation of duties includes dividing mission or business functions and support functions among different individuals or roles, conducting system support functions with different individuals, and ensuring that security personnel who administer access control functions do not also administer audit functions. Because separation of duty violations can span systems and application domains, organizations consider the entirety of systems and system components when developing policy on separation of duties. Separation of duties is enforced through the account management activities in [AC-2](#ac-2), access control mechanisms in [AC-3](#ac-3), and identity management activities in [IA-2](#ia-2), [IA-4](#ia-4), and [IA-12](#ia-12)." - } - ] - }, - { - "id": "ac-6", - "class": "SP800-53", - "title": "Least Privilege", - "props": [ - { - "name": "label", - "value": "AC-6" - }, - { - "name": "sort-id", - "value": "ac-06" - } - ], - "links": [ - { - "href": "#ac-2", - "rel": "related" - }, - { - "href": "#ac-3", - "rel": "related" - }, - { - "href": "#ac-5", - "rel": "related" - }, - { - "href": "#ac-16", - "rel": "related" - }, - { - "href": "#cm-5", - "rel": "related" - }, - { - "href": "#cm-11", - "rel": "related" - }, - { - "href": "#pl-2", - "rel": "related" - }, - { - "href": "#pm-12", - "rel": "related" - }, - { - "href": "#sa-8", - "rel": "related" - }, - { - "href": "#sa-15", - "rel": "related" - }, - { - "href": "#sa-17", - "rel": "related" - }, - { - "href": "#sc-38", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6_smt", - "name": "statement", - "prose": "Employ the principle of least privilege, allowing only authorized accesses for users (or processes acting on behalf of users) that are necessary to accomplish assigned organizational tasks." - }, - { - "id": "ac-6_gdn", - "name": "guidance", - "prose": "Organizations employ least privilege for specific duties and systems. The principle of least privilege is also applied to system processes, ensuring that the processes have access to systems and operate at privilege levels no higher than necessary to accomplish organizational missions or business functions. Organizations consider the creation of additional processes, roles, and accounts as necessary to achieve least privilege. Organizations apply least privilege to the development, implementation, and operation of organizational systems." - } - ], - "controls": [ - { - "id": "ac-6.1", - "class": "SP800-53-enhancement", - "title": "Authorize Access to Security Functions", - "params": [ - { - "id": "ac-6.1_prm_1", - "label": "organization-defined individuals or roles" - }, - { - "id": "ac-6.1_prm_2", - "label": "organization-defined security functions (deployed in hardware, software, and firmware)" - }, - { - "id": "ac-6.1_prm_3", - "label": "organization-defined security-relevant information" - } - ], - "props": [ - { - "name": "label", - "value": "AC-6(1)" - }, - { - "name": "sort-id", - "value": "ac-06.01" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ac-17", - "rel": "related" - }, - { - "href": "#ac-18", - "rel": "related" - }, - { - "href": "#ac-19", - "rel": "related" - }, - { - "href": "#au-9", - "rel": "related" - }, - { - "href": "#pe-2", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.1_smt", - "name": "statement", - "prose": "Authorize access for {{ insert: param, ac-6.1_prm_1 }} to:", - "parts": [ - { - "id": "ac-6.1_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": " {{ insert: param, ac-6.1_prm_2 }}; and" - }, - { - "id": "ac-6.1_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": " {{ insert: param, ac-6.1_prm_3 }}." - } - ] - }, - { - "id": "ac-6.1_gdn", - "name": "guidance", - "prose": "Security functions include establishing system accounts, configuring access authorizations (i.e., permissions, privileges), configuring settings for events to be audited, and establishing intrusion detection parameters. Security-relevant information includes filtering rules for routers or firewalls, configuration parameters for security services, cryptographic key management information, and access control lists. Authorized personnel include security administrators, system administrators, system security officers, system programmers, and other privileged users." - } - ] - }, - { - "id": "ac-6.2", - "class": "SP800-53-enhancement", - "title": "Non-privileged Access for Nonsecurity Functions", - "params": [ - { - "id": "ac-6.2_prm_1", - "label": "organization-defined security functions or security-relevant information" - } - ], - "props": [ - { - "name": "label", - "value": "AC-6(2)" - }, - { - "name": "sort-id", - "value": "ac-06.02" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ac-17", - "rel": "related" - }, - { - "href": "#ac-18", - "rel": "related" - }, - { - "href": "#ac-19", - "rel": "related" - }, - { - "href": "#pl-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.2_smt", - "name": "statement", - "prose": "Require that users of system accounts (or roles) with access to {{ insert: param, ac-6.2_prm_1 }} use non-privileged accounts or roles, when accessing nonsecurity functions." - }, - { - "id": "ac-6.2_gdn", - "name": "guidance", - "prose": "Requiring the use of non-privileged accounts when accessing nonsecurity functions limits exposure when operating from within privileged accounts or roles. The inclusion of roles addresses situations where organizations implement access control policies, such as role-based access control, and where a change of role provides the same degree of assurance in the change of access authorizations for the user and the processes acting on behalf of the user as would be provided by a change between a privileged and non-privileged account." - } - ] - }, - { - "id": "ac-6.3", - "class": "SP800-53-enhancement", - "title": "Network Access to Privileged Commands", - "params": [ - { - "id": "ac-6.3_prm_1", - "label": "organization-defined privileged commands" - }, - { - "id": "ac-6.3_prm_2", - "label": "organization-defined compelling operational needs" - } - ], - "props": [ - { - "name": "label", - "value": "AC-6(3)" - }, - { - "name": "sort-id", - "value": "ac-06.03" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ac-17", - "rel": "related" - }, - { - "href": "#ac-18", - "rel": "related" - }, - { - "href": "#ac-19", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.3_smt", - "name": "statement", - "prose": "Authorize network access to {{ insert: param, ac-6.3_prm_1 }} only for {{ insert: param, ac-6.3_prm_2 }} and document the rationale for such access in the security plan for the system." - }, - { - "id": "ac-6.3_gdn", - "name": "guidance", - "prose": "Network access is any access across a network connection in lieu of local access (i.e., user being physically present at the device)." - } - ] - }, - { - "id": "ac-6.4", - "class": "SP800-53-enhancement", - "title": "Separate Processing Domains", - "props": [ - { - "name": "label", - "value": "AC-6(4)" - }, - { - "name": "sort-id", - "value": "ac-06.04" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ac-4", - "rel": "related" - }, - { - "href": "#sc-2", - "rel": "related" - }, - { - "href": "#sc-3", - "rel": "related" - }, - { - "href": "#sc-30", - "rel": "related" - }, - { - "href": "#sc-32", - "rel": "related" - }, - { - "href": "#sc-39", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.4_smt", - "name": "statement", - "prose": "Provide separate processing domains to enable finer-grained allocation of user privileges." - }, - { - "id": "ac-6.4_gdn", - "name": "guidance", - "prose": "Providing separate processing domains for finer-grained allocation of user privileges includes using virtualization techniques to permit additional user privileges within a virtual machine while restricting privileges to other virtual machines or to the underlying physical machine, implementing separate physical domains, and employing hardware or software domain separation mechanisms." - } - ] - }, - { - "id": "ac-6.5", - "class": "SP800-53-enhancement", - "title": "Privileged Accounts", - "params": [ - { - "id": "ac-6.5_prm_1", - "label": "organization-defined personnel or roles" - } - ], - "props": [ - { - "name": "label", - "value": "AC-6(5)" - }, - { - "name": "sort-id", - "value": "ac-06.05" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ia-2", - "rel": "related" - }, - { - "href": "#ma-3", - "rel": "related" - }, - { - "href": "#ma-4", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.5_smt", - "name": "statement", - "prose": "Restrict privileged accounts on the system to {{ insert: param, ac-6.5_prm_1 }}." - }, - { - "id": "ac-6.5_gdn", - "name": "guidance", - "prose": "Privileged accounts, including super user accounts, are typically described as system administrator for various types of commercial off-the-shelf operating systems. Restricting privileged accounts to specific personnel or roles prevents day-to-day users from accessing privileged information or privileged functions. Organizations may differentiate in the application of restricting privileged accounts between allowed privileges for local accounts and for domain accounts provided that they retain the ability to control system configurations for key parameters and as otherwise necessary to sufficiently mitigate risk." - } - ] - }, - { - "id": "ac-6.6", - "class": "SP800-53-enhancement", - "title": "Privileged Access by Non-organizational Users", - "props": [ - { - "name": "label", - "value": "AC-6(6)" - }, - { - "name": "sort-id", - "value": "ac-06.06" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ac-18", - "rel": "related" - }, - { - "href": "#ac-19", - "rel": "related" - }, - { - "href": "#ia-2", - "rel": "related" - }, - { - "href": "#ia-8", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.6_smt", - "name": "statement", - "prose": "Prohibit privileged access to the system by non-organizational users." - }, - { - "id": "ac-6.6_gdn", - "name": "guidance", - "prose": "An organizational user is an employee or an individual considered by the organization to have the equivalent status of an employee. Organizational users include contractors, guest researchers, or individuals detailed from other organizations. A non-organizational user is a user who is not an organizational user. Policies and procedures for granting equivalent status of employees to individuals include a need-to-know, citizenship, and the relationship to the organization." - } - ] - }, - { - "id": "ac-6.7", - "class": "SP800-53-enhancement", - "title": "Review of User Privileges", - "params": [ - { - "id": "ac-6.7_prm_1", - "label": "organization-defined frequency" - }, - { - "id": "ac-6.7_prm_2", - "label": "organization-defined roles or classes of users" - } - ], - "props": [ - { - "name": "label", - "value": "AC-6(7)" - }, - { - "name": "sort-id", - "value": "ac-06.07" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#ca-7", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.7_smt", - "name": "statement", - "parts": [ - { - "id": "ac-6.7_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Review {{ insert: param, ac-6.7_prm_1 }} the privileges assigned to {{ insert: param, ac-6.7_prm_2 }} to validate the need for such privileges; and" - }, - { - "id": "ac-6.7_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Reassign or remove privileges, if necessary, to correctly reflect organizational mission and business needs." - } - ] - }, - { - "id": "ac-6.7_gdn", - "name": "guidance", - "prose": "The need for certain assigned user privileges may change over time to reflect changes in organizational mission and business functions, environments of operation, technologies, or threats. A periodic review of assigned user privileges is necessary to determine if the rationale for assigning such privileges remains valid. If the need cannot be revalidated, organizations take appropriate corrective actions." - } - ] - }, - { - "id": "ac-6.8", - "class": "SP800-53-enhancement", - "title": "Privilege Levels for Code Execution", - "params": [ - { - "id": "ac-6.8_prm_1", - "label": "organization-defined software" - } - ], - "props": [ - { - "name": "label", - "value": "AC-6(8)" - }, - { - "name": "sort-id", - "value": "ac-06.08" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-6.8_smt", - "name": "statement", - "prose": "Prevent the following software from executing at higher privilege levels than users executing the software: {{ insert: param, ac-6.8_prm_1 }}." - }, - { - "id": "ac-6.8_gdn", - "name": "guidance", - "prose": "In certain situations, software applications or programs need to execute with elevated privileges to perform required functions. However, depending on the software functionality and configuration, if the privileges required for execution are at a higher level than the privileges assigned to organizational users invoking such applications or programs, those users may indirectly be provided with greater privileges than assigned." - } - ] - }, - { - "id": "ac-6.9", - "class": "SP800-53-enhancement", - "title": "Log Use of Privileged Functions", - "props": [ - { - "name": "label", - "value": "AC-6(9)" - }, - { - "name": "sort-id", - "value": "ac-06.09" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - }, - { - "href": "#au-2", - "rel": "related" - }, - { - "href": "#au-3", - "rel": "related" - }, - { - "href": "#au-12", - "rel": "related" - } - ], - "parts": [ - { - "id": "ac-6.9_smt", - "name": "statement", - "prose": "Log the execution of privileged functions." - }, - { - "id": "ac-6.9_gdn", - "name": "guidance", - "prose": "The misuse of privileged functions, either intentionally or unintentionally by authorized users or by unauthorized external entities that have compromised system accounts, is a serious and ongoing concern and can have significant adverse impacts on organizations. Logging and analyzing the use of privileged functions is one way to detect such misuse and, in doing so, help mitigate the risk from insider threats and the advanced persistent threat." - } - ] - }, - { - "id": "ac-6.10", - "class": "SP800-53-enhancement", - "title": "Prohibit Non-privileged Users from Executing Privileged Functions", - "props": [ - { - "name": "label", - "value": "AC-6(10)" - }, - { - "name": "sort-id", - "value": "ac-06.10" - } - ], - "links": [ - { - "href": "#ac-6", - "rel": "required" - } - ], - "parts": [ - { - "id": "ac-6.10_smt", - "name": "statement", - "prose": "Prevent non-privileged users from executing privileged functions." - }, - { - "id": "ac-6.10_gdn", - "name": "guidance", - "prose": "Privileged functions include disabling, circumventing, or altering implemented security or privacy controls, establishing system accounts, performing system integrity checks, and administering cryptographic key management activities. Non-privileged users are individuals who do not possess appropriate authorizations. Privileged functions that require protection from non-privileged users include circumventing intrusion detection and prevention mechanisms or malicious code protection mechanisms. Preventing non-privileged users from executing privileged functions is enforced by [AC-3](#ac-3)." - } - ] - } - ] - } - ] - }, - { - "id": "at", - "class": "family", - "title": "Awareness and Training", - "controls": [ - { - "id": "at-1", - "class": "SP800-53", - "title": "Policy and Procedures", - "params": [ - { - "id": "at-1_prm_1", - "label": "organization-defined personnel or roles" - }, - { - "id": "at-1_prm_2", - "select": { - "how-many": "one-or-more", - "choice": [ - "Organization-level", - "Mission/business process-level" - ] - } - } - ], - "props": [ - { - "name": "label", - "value": "AT-1" - }, - { - "name": "sort-id", - "value": "at-01" - } - ], - "links": [ - { - "href": "#27847491-5ce1-4f6a-a1e4-9e483782f0ef", - "rel": "reference" - }, - { - "href": "#c7ac44e8-10db-4b64-b2b9-9e32ec1efed0", - "rel": "reference" - } - ], - "parts": [ - { - "id": "at-1_smt", - "name": "statement", - "parts": [ - { - "id": "at-1_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "a." - } - ], - "prose": "Develop, document, and disseminate to {{ insert: param, at-1_prm_1 }}:", - "parts": [ - { - "id": "at-1_smt.a.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": " {{ insert: param, at-1_prm_2 }} awareness and training policy that:", - "parts": [ - { - "id": "at-1_smt.a.1.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "(a)" - } - ], - "prose": "Addresses purpose, scope, roles, responsibilities, management commitment, coordination among organizational entities, and compliance; and" - }, - { - "id": "at-1_smt.a.1.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "(b)" - } - ], - "prose": "Is consistent with applicable laws, executive orders, directives, regulations, policies, standards, and guidelines; and" - } - ] - }, - { - "id": "at-1_smt.a.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": "Procedures to facilitate the implementation of the awareness and training policy and the associated awareness and training controls;" - } - ] - }, - { - "id": "at-1_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "b." - } - ], - "prose": "Designate an {{ insert: param, at-1_prm_1 }} to manage the development, documentation, and dissemination of the awareness and training policy and procedures; and" - } - ] - }, - { - "id": "at-1_gdn", - "name": "guidance", - "prose": "Awareness and training policy and procedures address the controls in the AT family that are implemented within systems and organizations. The risk management strategy is an important factor in establishing such policies and procedures. Policies and procedures contribute to security and privacy assurance. Therefore, it is important that security and privacy programs collaborate on the development of awareness and training policy and procedures. Security and privacy program policies and procedures at the organization level are preferable, in general, and may obviate the need for mission- or system-specific policies and procedures. The policy can be included as part of the general security and privacy policy or be represented by multiple policies that reflect the complex nature of organizations. Procedures can be established for security and privacy programs, for mission or business processes, and for systems, if needed. Procedures describe how the policies or controls are implemented and can be directed at the individual or role that is the object of the procedure. Procedures can be documented in system security and privacy plans or in one or more separate documents. Events that may precipitate an update to awareness and training policy and procedures include assessment or audit findings, security incidents or breaches, or changes in applicable laws, executive orders, directives, regulations, policies, standards, and guidelines. Simply restating controls does not constitute an organizational policy or procedure." - } - ] - }, - { - "id": "at-2", - "class": "SP800-53", - "title": "Literacy Training and Awareness", - "params": [ - { - "id": "at-2_prm_1", - "label": "organization-defined frequency" - }, - { - "id": "at-2_prm_2", - "label": "organization-defined events" - } - ], - "props": [ - { - "name": "label", - "value": "AT-2" - }, - { - "name": "sort-id", - "value": "at-02" - } - ], - "links": [ - { - "href": "#27847491-5ce1-4f6a-a1e4-9e483782f0ef", - "rel": "reference" - }, - { - "href": "#511f6832-23ca-49a3-8c0f-ce493373cab8", - "rel": "reference" - } - ], - "parts": [ - { - "id": "at-2_smt", - "name": "statement", - "parts": [ - { - "id": "at-2_smt.a", - "name": "item", - "props": [ - { - "name": "label", - "value": "a." - } - ], - "prose": "Provide security and privacy literacy training to system users (including managers, senior executives, and contractors):", - "parts": [ - { - "id": "at-2_smt.a.1", - "name": "item", - "props": [ - { - "name": "label", - "value": "1." - } - ], - "prose": "As part of initial training for new users and {{ insert: param, at-2_prm_1 }} thereafter; and" - }, - { - "id": "at-2_smt.a.2", - "name": "item", - "props": [ - { - "name": "label", - "value": "2." - } - ], - "prose": "When required by system changes or following {{ insert: param, at-2_prm_2 }};" - } - ] - }, - { - "id": "at-2_smt.b", - "name": "item", - "props": [ - { - "name": "label", - "value": "b." - } - ], - "prose": "Employ the following techniques to increase the security and privacy awareness of system users {{ insert: param, at-2_prm_1 }};" - } - ] - }, - { - "id": "at-2_gdn", - "name": "guidance", - "prose": "Organizations provide basic and advanced levels of literacy training to system users, including measures to test the knowledge level of users. Organizations determine the content of literacy training and awareness based on specific organizational requirements, the systems to which personnel have authorized access, and work environments (e.g., telework). The content includes an understanding of the need for security and privacy as well as actions by users to maintain security and personal privacy and to respond to suspected incidents. The content addresses the need for operations security and the handling of personally identifiable information.\n\nAwareness techniques include displaying posters, offering supplies inscribed with security and privacy reminders, displaying logon screen messages, generating email advisories or notices from organizational officials, and conducting awareness events. Literacy training after the initial training described in [AT-2a.1](#at-2_smt.a.1) is conducted at a minimum frequency consistent with applicable laws, directives, regulations, and policies. Subsequent literacy training may be satisfied by one or more short ad hoc sessions and include topical information on recent attack schemes, changes to organizational security and privacy policies, revised security and privacy expectations, or a subset of topics from the initial training. Updating literacy training and awareness content on a regular basis helps to ensure that the content remains relevant. Events that may precipitate an update to literacy training and awareness content include, but are not limited to, assessment or audit findings, security incidents or breaches, or changes in applicable laws, executive orders, directives, regulations, policies, standards, and guidelines." - } - ], - "controls": [ - { - "id": "at-2.1", - "class": "SP800-53-enhancement", - "title": "Practical Exercises", - "props": [ - { - "name": "label", - "value": "AT-2(1)" - }, - { - "name": "sort-id", - "value": "at-02.01" - } - ], - "links": [ - { - "href": "#at-2", - "rel": "required" - }, - { - "href": "#ca-2", - "rel": "related" - } - ], - "parts": [ - { - "id": "at-2.1_smt", - "name": "statement", - "prose": "Provide practical exercises in literacy training that simulate events and incidents." - }, - { - "id": "at-2.1_gdn", - "name": "guidance", - "prose": "Practical exercises include no-notice social engineering attempts to collect information, gain unauthorized access, or simulate the adverse impact of opening malicious email attachments or invoking, via spear phishing attacks, malicious web links." - } - ] - }, - { - "id": "at-2.2", - "class": "SP800-53-enhancement", - "title": "Insider Threat", - "props": [ - { - "name": "label", - "value": "AT-2(2)" - }, - { - "name": "sort-id", - "value": "at-02.02" - } - ], - "links": [ - { - "href": "#at-2", - "rel": "required" - }, - { - "href": "#pm-12", - "rel": "related" - } - ], - "parts": [ - { - "id": "at-2.2_smt", - "name": "statement", - "prose": "Provide literacy training on recognizing and reporting potential indicators of insider threat." - }, - { - "id": "at-2.2_gdn", - "name": "guidance", - "prose": "Potential indicators and possible precursors of insider threat can include behaviors such as inordinate, long-term job dissatisfaction; attempts to gain access to information not required for job performance; unexplained access to financial resources; bullying or harassment of fellow employees; workplace violence; and other serious violations of policies, procedures, directives, regulations, rules, or practices. Literacy training includes how to communicate the concerns of employees and management regarding potential indicators of insider threat through channels established by the organization and in accordance with established policies and procedures. Organizations may consider tailoring insider threat awareness topics to the role. For example, training for managers may be focused on changes in the behavior of team members, while training for employees may be focused on more general observations." - } - ] - } - ] - } - ] - } - ], - "back-matter": { - "resources": [ - { - "uuid": "91f992fb-f668-4c91-a50f-0f05b95ccee3", - "title": "32 CFR 2002", - "citation": { - "text": "Code of Federal Regulations, Title 32, *Controlled Unclassified Information* (32 C.F.R. 2002)." - }, - "rlinks": [ - { - "href": "https://www.federalregister.gov/documents/2016/09/14/2016-21665/controlled-unclassified-information" - } - ] - }, - { - "uuid": "0f963c17-ab5a-432a-a867-91eac550309b", - "title": "41 CFR 201", - "citation": { - "text": " \"Federal Acquisition Supply Chain Security Act; Rule,\" 85 Federal Register 54263 (September 1, 2020), pp 54263-54271." - }, - "rlinks": [ - { - "href": "https://www.federalregister.gov/d/2020-18939" - } - ] - } - ] - } - } -} diff --git a/tests/unit/utils/oscal/data/simplified_nist_profile.json b/tests/unit/utils/oscal/data/simplified_nist_profile.json deleted file mode 100644 index 31d5ca50e330..000000000000 --- a/tests/unit/utils/oscal/data/simplified_nist_profile.json +++ /dev/null @@ -1,142 +0,0 @@ -{ - "profile": { - "uuid": "1019f424-1556-4aa3-9df3-337b97c2c856", - "metadata": { - "title": "NIST Special Publication 800-53 Revision 5 MODERATE IMPACT BASELINE", - "last-modified": "2021-06-08T13:57:34.337491-04:00", - "version": "Final", - "oscal-version": "1.0.0", - "roles": [ - { - "id": "creator", - "title": "Document Creator" - }, - { - "id": "contact", - "title": "Contact" - } - ], - "parties": [ - { - "uuid": "cde369ce-57f8-4ec1-847f-2681a9a881e7", - "type": "organization", - "name": "Joint Task Force, Transformation Initiative", - "email-addresses": [ - "sec-cert@nist.gov" - ], - "addresses": [ - { - "addr-lines": [ - "National Institute of Standards and Technology", - "Attn: Computer Security Division", - "Information Technology Laboratory", - "100 Bureau Drive (Mail Stop 8930)" - ], - "city": "Gaithersburg", - "state": "MD", - "postal-code": "20899-8930" - } - ] - } - ], - "responsible-parties": [ - { - "role-id": "creator", - "party-uuids": [ - "cde369ce-57f8-4ec1-847f-2681a9a881e7" - ] - }, - { - "role-id": "contact", - "party-uuids": [ - "cde369ce-57f8-4ec1-847f-2681a9a881e7" - ] - } - ] - }, - "imports": [ - { - "href": "trestle://catalogs/simplified_nist_catalog/catalog.json", - "include-controls": [ - { - "with-ids": [ - "ac-1", - "ac-2", - "ac-2.1", - "ac-2.2", - "ac-2.3", - "ac-2.4", - "ac-2.5", - "ac-2.13", - "ac-3", - "ac-4", - "ac-4.4", - "ac-5" - ] - } - ] - } - ], - "merge": { - "as-is": true - }, - "modify": { - "set-parameters": [ - { - "param_id": "ac-1_prm_1", - "class": "newclassfromprof", - "depends-on": "newdependsonfromprof", - "usage": "new usage from prof", - "props": [ - { - "name": "param_1_prop", - "value": "prop value from prof" - }, - { - "name": "param_1_prop_2", - "value": "new prop value from prof" - } - ], - "links": [ - { - "href": "#123456789", - "text": "new text from prof" - }, - { - "href": "#new_link", - "text": "new link text" - } - ], - "constraints": [ - { - "description": "new constraint" - } - ], - "guidelines": [ - { - "prose": "new guideline" - } - ] - }, - { - "param_id": "ac-4.4_prm_3", - "values": [ - "hacking the system" - ] - }, - { - "param_id": "loose_2", - "values": [ - "loose_2_val_from_prof" - ] - }, - { - "param_id": "bad_param_id", - "values": [ - "this will cause warning" - ] - } - ] - } - } -} diff --git a/tests/unit/utils/oscal/data/test_root/applications/test_application/rule_1/rule.yml b/tests/unit/utils/oscal/data/test_root/applications/test_application/rule_1/rule.yml deleted file mode 100644 index 274f2c4c1a43..000000000000 --- a/tests/unit/utils/oscal/data/test_root/applications/test_application/rule_1/rule.yml +++ /dev/null @@ -1,24 +0,0 @@ -title: 'rule_1' - -description: |- - This is a rule with a template example. - It has two lines. - -rationale: 'This is a rationale' - -severity: medium - -references: - nist: SC-12 - -ocil_clause: 'Test rule' - -ocil: 'Test rule' - -template: - name: yamlfile_value - vars: - yamlpath: ".test" - check_existence: "all_exist" - xccdf_variable: var_test - regex_data: true diff --git a/tests/unit/utils/oscal/data/test_root/applications/test_application/rule_2/rule.yml b/tests/unit/utils/oscal/data/test_root/applications/test_application/rule_2/rule.yml deleted file mode 100644 index 2e4bc25ac0a2..000000000000 --- a/tests/unit/utils/oscal/data/test_root/applications/test_application/rule_2/rule.yml +++ /dev/null @@ -1,15 +0,0 @@ -title: 'rule_2' - -description: |- - This is a rule with no template. - -rationale: 'This is a rationale' - -severity: medium - -references: - nist: SC-12 - -ocil_clause: 'Ingress Operator default certificate needs to be replaced' - -ocil: 'Test' diff --git a/tests/unit/utils/oscal/data/test_root/applications/test_application/var_test.var b/tests/unit/utils/oscal/data/test_root/applications/test_application/var_test.var deleted file mode 100644 index 9e9a958d89f2..000000000000 --- a/tests/unit/utils/oscal/data/test_root/applications/test_application/var_test.var +++ /dev/null @@ -1,16 +0,0 @@ -documentation_complete: true - -title: 'Test Variable' - -description: 'This is a test variable.' - -type: string - -operator: equals - -interactive: false - -options: - default: "default" - alt: "alternate" - diff --git a/tests/unit/utils/oscal/data/test_root/controls/test_policy.yml b/tests/unit/utils/oscal/data/test_root/controls/test_policy.yml deleted file mode 100644 index 249425e513ab..000000000000 --- a/tests/unit/utils/oscal/data/test_root/controls/test_policy.yml +++ /dev/null @@ -1,69 +0,0 @@ -policy: Simplified NIST Policy -title: Simplified NIST Recommendations for Test Product -id: test_policy -version: Revision 4 -source: https://www.fedramp.gov/assets/resources/documents/FedRAMP_Security_Controls_Baseline.xlsx -levels: - - id: low - - id: moderate - - id: high -controls: - - id: AC-1 - status: not applicable - notes: |- - Section a: AC-1(a) is an organizational control outside the scope of - Test Product configuration. - - Section b: AC-1(b) is an organizational control outside the scope of - Test Product configuration. - rules: [] - description: "The organization:\n a. Develops, documents, and disseminates to [Assignment:\ - \ organization-defined personnel or roles]:\n 1. An access control policy that\ - \ addresses purpose, scope, roles, responsibilities, management commitment, coordination\ - \ among organizational entities, and compliance; and\n 2. Procedures to facilitate\ - \ the implementation of the access control policy and associated access controls;\ - \ and\n b. Reviews and updates the current:\n 1. Access control policy [Assignment:\ - \ organization-defined frequency]; and\n 2. Access control procedures [Assignment:\ - \ organization-defined frequency].\n\nSupplemental Guidance: This control addresses\ - \ the establishment of policy and procedures for the effective implementation\ - \ of selected security controls and control enhancements in the AC family. Policy\ - \ and procedures reflect applicable federal laws, Executive Orders, directives,\ - \ regulations, policies, standards, and guidance. Security program policies and\ - \ procedures at the organization level may make the need for system-specific policies\ - \ and procedures unnecessary. The policy can be included as part of the general\ - \ information security policy for organizations or conversely, can be represented\ - \ by multiple policies reflecting the complex nature of certain organizations.\ - \ The procedures can be established for the security program in general and for\ - \ particular information systems, if needed. \n\nThe organizational risk management\ - \ strategy is a key factor in establishing policy and procedures. Related control:\ - \ PM-9.\nControl Enhancements: None.\nReferences: NIST Special Publications 800-12,\ - \ 800-100.\n\nAC-1 (b) (1) [at least annually] \nAC-1 (b) (2) [at least annually\ - \ or whenever a significant change occurs]" - title: >- - AC-1 - ACCESS CONTROL POLICY AND PROCEDURES - levels: - - high - - moderate - - low - - id: AC-2(1) - status: automated - notes: |- - This is a test notes that details the AC-2(1) control implementation for Test Product and - how it is automated. - rules: - - rule_1 - - rule_2 - description: |- - The organization employs automated mechanisms to support the - management of information system accounts. - - Supplemental Guidance: The use of automated mechanisms can include, for example: - using email or text messaging to automatically notify account - managers when users are terminated or transferred; using the information - system to monitor account usage; and using telephonic notification to - report atypical system account usage. - title: >- - AC-2(1) - ACCOUNT MANAGEMENT | AUTOMATED SYSTEM ACCOUNT MANAGEMENT - levels: - - high - - moderate diff --git a/tests/unit/utils/oscal/data/test_root/products/test_product/product.yml b/tests/unit/utils/oscal/data/test_root/products/test_product/product.yml deleted file mode 100644 index 87f6f0e692f5..000000000000 --- a/tests/unit/utils/oscal/data/test_root/products/test_product/product.yml +++ /dev/null @@ -1,20 +0,0 @@ -product: test_product -full_name: Test Product -type: platform - -benchmark_id: EXAMPLE -benchmark_root: "../../applications" -components_root: "../../components" - -profiles_root: "./profiles" - -pkg_manager: "dnf" - -init_system: "systemd" - -cpes_root: "../../shared/applicability" -cpes: - - example: - name: "cpe:/o:example" - title: "Example" - check_id: installed_OS_is_part_of_Unix_family diff --git a/tests/unit/utils/oscal/test_cd_generator.py b/tests/unit/utils/oscal/test_cd_generator.py deleted file mode 100644 index 313499a61e48..000000000000 --- a/tests/unit/utils/oscal/test_cd_generator.py +++ /dev/null @@ -1,394 +0,0 @@ -import argparse -import os -import pathlib -import shutil -from typing import Any, Dict, Generator, Tuple -from tempfile import TemporaryDirectory -from unittest.mock import Mock - -import pytest -from trestle.common.common_types import TopLevelOscalModel -from trestle.common.const import IMPLEMENTATION_STATUS, REPLACE_ME -from trestle.common.err import TrestleError -from trestle.core.generators import generate_sample_model -from trestle.common.model_utils import ModelUtils -from trestle.core.commands.init import InitCmd -from trestle.core.models.file_content_type import FileContentType -from trestle.oscal import catalog as cat -from trestle.oscal import profile as prof -from trestle.oscal.component import ComponentDefinition -from trestle.oscal.component import ImplementedRequirement - -import ssg.environment -import ssg.products -from ssg.controls import Control, Status - -from utils.oscal.cd_generator import ( - ComponentDefinitionGenerator, - OscalStatus, - OSCALProfileHelper, -) -from utils.oscal.control_selector import ControlSelector, PolicyControlSelector - - -DATADIR = os.path.join(os.path.dirname(__file__), "data") -TEST_ROOT = os.path.abspath(os.path.join(DATADIR, "test_root")) -TEST_BUILD_CONFIG = os.path.join(DATADIR, "build-config.yml") -TEST_RULE_JSON = os.path.join(DATADIR, "rule_dirs.json") - - -@pytest.fixture(scope="function") -def vendor_dir() -> Generator[str, None, None]: - """Create a temporary trestle directory for testing.""" - with TemporaryDirectory(prefix="temp_vendor") as tmpdir: - tmp_path = pathlib.Path(tmpdir) - try: - args = argparse.Namespace( - verbose=0, - trestle_root=tmp_path, - full=True, - local=False, - govdocs=False, - ) - init = InitCmd() - init._run(args) - load_oscal_test_data(tmp_path, "simplified_nist_catalog", cat.Catalog) # type: ignore - load_oscal_test_data(tmp_path, "simplified_nist_profile", prof.Profile) # type: ignore - except Exception as e: - raise TrestleError( - f"Initialization failed for temporary trestle directory: {e}." - ) - yield tmpdir - - -@pytest.fixture(scope="function") -def env_yaml() -> Generator[Dict[str, Any], None, None]: - product_yaml_path = ssg.products.product_yaml_path(TEST_ROOT, "test_product") - env_yaml = ssg.environment.open_environment( - TEST_BUILD_CONFIG, - product_yaml_path, - os.path.join(TEST_ROOT, "product_properties"), - ) - yield env_yaml - - -def load_oscal_test_data( - trestle_dir: pathlib.Path, model_name: str, model_type: TopLevelOscalModel -) -> None: - dst_path = ModelUtils.get_model_path_for_name_and_class( - trestle_dir, model_name, model_type, FileContentType.JSON # type: ignore - ) - if dst_path is None: - raise TrestleError(f"Unable to get model path for {model_name}") - dst_path.parent.mkdir(parents=True, exist_ok=True) - src_path = os.path.join(DATADIR, model_name + ".json") - shutil.copy2(src_path, dst_path) - - -@pytest.mark.parametrize( - "input, response", - [ - ("AC-1", "ac-1"), - ("AC-2(2)", "ac-2.2"), - ("ac-1_smt.a", "ac-1_smt.a"), - ("AC-200", None), - ], -) -def test_oscal_profile_helper(vendor_dir: str, input: str, response: str) -> None: - "Test the OSCALProfileHelper class validate method." - trestle_root = pathlib.Path(vendor_dir) - oscal_profile_helper = OSCALProfileHelper(trestle_root=trestle_root) - profile_path = f"{vendor_dir}/profiles/simplified_nist_profile/profile.json" - oscal_profile_helper.load(profile_path=profile_path) - result_id = oscal_profile_helper.validate(input) - assert result_id == response - - -@pytest.mark.parametrize( - "ssg_status, oscal_status, err_msg", - [ - (Status.INHERENTLY_MET, OscalStatus.IMPLEMENTED, ""), - (Status.PARTIAL, OscalStatus.PARTIAL, ""), - (Status.MANUAL, OscalStatus.ALTERNATIVE, ""), - ("fake_status", "", "Invalid status: fake_status.*"), - ], -) -def test_oscal_status(ssg_status: str, oscal_status: str, err_msg: str) -> None: - """ - Test OSCALStatus class mapping. - - Test a few valid mappings and an invalid mapping. - """ - if not err_msg: - assert OscalStatus.from_string(ssg_status) == oscal_status - else: - with pytest.raises(ValueError, match=err_msg): - OscalStatus.from_string(ssg_status) - - -section_response = """ -Section a: My response is a single statement -Section b: My response is a list of statements - -This link for section b. -""" - -single_response = """ -A single response with no sections -""" - -expected_single_response = "A single response with no sections" -expected_section_a_response = "My response is a single statement" -expected_section_b_response = ( - "My response is a list of statements\n\nThis link for section b." -) - - -@pytest.mark.parametrize( - "notes, input_status, description, status, remarks", - [ - ( - single_response, - Status.MANUAL, - REPLACE_ME, - OscalStatus.ALTERNATIVE, - expected_single_response, - ), - ( - single_response, - Status.INHERENTLY_MET, - expected_single_response, - OscalStatus.IMPLEMENTED, - None, - ), - ], -) -def test_handle_response_with_implemented_requirements( - vendor_dir: str, - env_yaml: Dict[str, Any], - notes: str, - input_status: str, - description: str, - status: str, - remarks: str, -) -> None: - """Test handling responses with various scenarios.""" - - control = Control() - control.notes = notes - control.status = input_status - - mock_selector = Mock(spec=ControlSelector) - mock_selector.get_controls = [control] - - cd_generator = ComponentDefinitionGenerator( - vendor_dir=vendor_dir, - json_path=TEST_RULE_JSON, - root=TEST_ROOT, - profile_name_or_href="simplified_nist_profile", - env_yaml=env_yaml, - control_selector=mock_selector, - ) - - implemented_req = generate_sample_model(ImplementedRequirement) - implemented_req.control_id = "ac-1" - cd_generator.handle_response(implemented_req, control) - - assert implemented_req.statements is None - assert implemented_req.description == description - assert implemented_req.props is not None - - prop = next( - (prop for prop in implemented_req.props if prop.name == IMPLEMENTATION_STATUS), - None, - ) - - assert prop is not None - assert prop.value == status - assert prop.remarks == remarks - - -@pytest.mark.parametrize( - "notes, status, id, results", - [ - ( - section_response, - Status.PARTIAL, - "ac-1", - ( - OscalStatus.PARTIAL, - None, - { - "ac-1_smt.a": expected_section_a_response, - "ac-1_smt.b": expected_section_b_response, - }, - ), - ), - ( - section_response, - Status.MANUAL, - "ac-1", - ( - OscalStatus.ALTERNATIVE, - REPLACE_ME, - { - "ac-1_smt.a": expected_section_a_response, - "ac-1_smt.b": expected_section_b_response, - }, - ), - ), - ], -) -def test_handle_response_with_statements( - vendor_dir: str, - env_yaml: Dict[str, Any], - notes: str, - status: str, - id: str, - results: Tuple[str, str, Dict[str, str]], -) -> None: - """Test handling responses with various scenarios.""" - product_yaml_path = ssg.products.product_yaml_path(TEST_ROOT, "test_product") - env_yaml = ssg.environment.open_environment( - TEST_BUILD_CONFIG, - product_yaml_path, - os.path.join(TEST_ROOT, "product_properties"), - ) - - control = Control() - control.notes = notes - control.status = status - - mock_selector = Mock(spec=ControlSelector) - mock_selector.get_controls = [control] - - cd_generator = ComponentDefinitionGenerator( - vendor_dir=vendor_dir, - json_path=TEST_RULE_JSON, - root=TEST_ROOT, - profile_name_or_href="simplified_nist_profile", - env_yaml=env_yaml, - control_selector=mock_selector, - ) - - implemented_req = generate_sample_model(ImplementedRequirement) - implemented_req.control_id = id - cd_generator.handle_response(implemented_req, control) - - status, remarks, statements = results - - assert implemented_req.description == REPLACE_ME - assert implemented_req.props is not None - - prop = next( - (prop for prop in implemented_req.props if prop.name == IMPLEMENTATION_STATUS), - None, - ) - - assert prop is not None - assert prop.value == status - assert prop.remarks == remarks - - assert implemented_req.statements is not None - assert len(implemented_req.statements) == len(statements) - - for stm in implemented_req.statements: - assert stm.description == statements.get(stm.statement_id) # type: ignore - - -def test_create_control_implementation( - vendor_dir: str, env_yaml: Dict[str, Any] -) -> None: - """Test the create_control_implementation with PolicyControlSelection.""" - control_selector = PolicyControlSelector( - control="test_policy", - ssg_root=TEST_ROOT, - env_yaml=env_yaml, - ) - - cd_generator = ComponentDefinitionGenerator( - vendor_dir=vendor_dir, - json_path=TEST_RULE_JSON, - root=TEST_ROOT, - profile_name_or_href="simplified_nist_profile", - env_yaml=env_yaml, - control_selector=control_selector, - ) - - control_impl = cd_generator.create_control_implementation() - - assert len(control_impl.implemented_requirements) == 2 - assert control_impl.implemented_requirements[0].control_id == "ac-1" - assert control_impl.implemented_requirements[1].control_id == "ac-2.1" - - # Check set parameters - assert control_impl.set_parameters is not None - assert len(control_impl.set_parameters) == 1 - assert control_impl.set_parameters[0].param_id == "var_test" - assert "default" in control_impl.set_parameters[0].values - - -def test_create_control_implementation_with_level( - vendor_dir: str, env_yaml: Dict[str, Any] -) -> None: - """Test the create_component_definition with a level filter on the control file.""" - control_selector = PolicyControlSelector( - control="test_policy", - ssg_root=TEST_ROOT, - env_yaml=env_yaml, - filter_by_level="low", - ) - - cd_generator = ComponentDefinitionGenerator( - vendor_dir=vendor_dir, - json_path=TEST_RULE_JSON, - root=TEST_ROOT, - profile_name_or_href="simplified_nist_profile", - env_yaml=env_yaml, - control_selector=control_selector, - ) - - control_impl = cd_generator.create_control_implementation() - - assert len(control_impl.implemented_requirements) == 1 - assert control_impl.implemented_requirements[0].control_id == "ac-1" - - -def test_create_cd(vendor_dir: str, env_yaml: Dict[str, Any]) -> None: - """Test creating a component definition.""" - control_selector = PolicyControlSelector( - control="test_policy", - ssg_root=TEST_ROOT, - env_yaml=env_yaml, - ) - - cd_generator = ComponentDefinitionGenerator( - vendor_dir=vendor_dir, - json_path=TEST_RULE_JSON, - root=TEST_ROOT, - profile_name_or_href="simplified_nist_profile", - env_yaml=env_yaml, - control_selector=control_selector, - ) - cd_output = os.path.join(vendor_dir, "test_comp.json") - cd_path = pathlib.Path(cd_output) - cd_generator.create_cd(cd_output) - - component_definition: ComponentDefinition - component_definition = ComponentDefinition.oscal_read(cd_path) # type: ignore - assert component_definition is not None - - assert component_definition.components is not None - assert len(component_definition.components) == 1 - component = component_definition.components[0] - - assert component.title == "test_product" - assert component.description == "test_product" - assert component.type == "service" - - assert component.control_implementations is not None - assert len(component.control_implementations) == 1 - assert len(component.control_implementations[0].implemented_requirements) == 2 - - assert component.props is not None - assert len(component.props) == 7 diff --git a/tests/unit/utils/oscal/test_control_selector.py b/tests/unit/utils/oscal/test_control_selector.py deleted file mode 100644 index 95bfd014de2e..000000000000 --- a/tests/unit/utils/oscal/test_control_selector.py +++ /dev/null @@ -1,21 +0,0 @@ -import os - -import pytest - -from utils.oscal.control_selector import PolicyControlSelector - -DATADIR = os.path.join(os.path.dirname(__file__), "data") -TEST_ROOT = os.path.abspath(os.path.join(DATADIR, "test_root")) -TEST_BUILD_CONFIG = os.path.join(DATADIR, "build-config.yml") - - -def test_control_selector_invalid_level() -> None: - """Trigger an error when the level filter is invalid.""" - - with pytest.raises(ValueError, match="Level fake not found in policy test_policy"): - PolicyControlSelector( - control="test_policy", - ssg_root=TEST_ROOT, - env_yaml=dict(), - filter_by_level="fake", - ) diff --git a/tests/unit/utils/oscal/test_rules_transformer.py b/tests/unit/utils/oscal/test_rules_transformer.py deleted file mode 100644 index 2c8bd1e8d798..000000000000 --- a/tests/unit/utils/oscal/test_rules_transformer.py +++ /dev/null @@ -1,174 +0,0 @@ -import os -import pytest -from typing import Any, Dict, List - -from trestle.oscal.common import Property - - -from ssg.environment import open_environment -from ssg.products import product_yaml_path - -from utils.oscal.params_extractor import ParameterExtractor, ParamInfo -from utils.oscal.rules_transformer import RulesTransformer, RuleInfo - - -DATADIR = os.path.join(os.path.dirname(__file__), "data") -TEST_ROOT = os.path.abspath(os.path.join(DATADIR, "test_root")) -TEST_BUILD_CONFIG = os.path.join(DATADIR, "build-config.yml") -TEST_RULE_JSON = os.path.join(DATADIR, "rule_dirs.json") -TEST_PRODUCT = "test_product" - - -@pytest.fixture(scope="function") -def env_yaml() -> Dict[str, Any]: - """Return the environment yaml.""" - product_yaml = product_yaml_path(TEST_ROOT, TEST_PRODUCT) - return open_environment( - TEST_BUILD_CONFIG, - product_yaml, - os.path.join(TEST_ROOT, "product_properties"), - ) - - -@pytest.fixture(scope="function") -def test_rule_objs() -> List[RuleInfo]: - """Create a set of test rules.""" - rule_with_parameter = RuleInfo(rule_id="rule_1", rule_dir="rule_dir") - rule_with_parameter.add_description("Rule 1 description") - test_parameter = ParamInfo( - param_id="var_test", - description="Test parameter", - ) - test_parameter.set_selected_value("default") - test_parameter.set_options({"default": "default", "alternate": "alternate"}) - rule_with_parameter.add_parameter(test_parameter) - rule_with_no_parameter = RuleInfo( - rule_id="rule_2", - rule_dir="rule_dir", - ) - rule_with_no_parameter.add_description("Rule 2 description") - return [rule_with_parameter, rule_with_no_parameter] - - -def test_rule_transformer_load(env_yaml: Dict[str, Any]) -> None: - """Test loading rules from a set of rules ids.""" - transformer = RulesTransformer( - TEST_ROOT, - env_yaml, - TEST_RULE_JSON, - ParameterExtractor(TEST_ROOT, env_yaml), - ) - transformer.add_rules(["rule_1", "rule_2"]) - rule_objs = transformer.get_all_rules() - - assert len(rule_objs) == 2 - assert rule_objs[0].id == "rule_1" - assert ( - rule_objs[0].description - == "This is a rule with a template example. It has two lines." - ) - assert rule_objs[0].parameters is not None - assert rule_objs[0].parameters[0].id == "var_test" - assert rule_objs[0].parameters[0].description == "This is a test variable." - assert rule_objs[0].parameters[0].selected_value == "default" - assert rule_objs[0].parameters[0].options == { - "default": "default", - "alt": "alternate", - } - assert rule_objs[1].id == "rule_2" - assert rule_objs[1].description == "This is a rule with no template." - assert not rule_objs[1].parameters - - -def test_rule_transformer_load_with_param(env_yaml: Dict[str, Any]) -> None: - """Test loading rules from a set of rules ids with a parameter override.""" - transformer = RulesTransformer( - TEST_ROOT, - env_yaml, - TEST_RULE_JSON, - ParameterExtractor(TEST_ROOT, env_yaml), - ) - transformer.add_rules( - [ - "rule_1", - "rule_2", - ], - {"var_test": "alternate"}, - ) - rule_objs = transformer.get_all_rules() - - assert len(rule_objs) == 2 - assert rule_objs[0].id == "rule_1" - assert rule_objs[0].parameters is not None - assert rule_objs[0].parameters[0].id == "var_test" - assert rule_objs[0].parameters[0].selected_value == "alternate" - assert rule_objs[1].id == "rule_2" - assert not rule_objs[1].parameters - - -def test_rules_transformer_transform( - test_rule_objs: List[RuleInfo], env_yaml: Dict[str, Any] -) -> None: - """Test transforming a set of rules into properties.""" - transformer = RulesTransformer( - TEST_ROOT, - env_yaml, - TEST_RULE_JSON, - ParameterExtractor(TEST_ROOT, env_yaml), - ) - props = transformer.transform(test_rule_objs) - - assert len(props) == 7 - - # Verify there are two rule sets - rulesets: Dict[str, List[Property]] = dict() - for prop in props: - if prop.remarks not in rulesets: - rulesets[prop.remarks] = [] # type: ignore - rulesets[prop.remarks].append(prop) # type: ignore - - assert len(rulesets) == 2 - - set1_props: List[Property] = next( - (rulesets[ruleset] for ruleset in rulesets.keys() if ruleset == "rule_set_0"), - [], - ) - - assert len(set1_props) == 5 - prop_names = [prop.name for prop in set1_props] - expected_prop_names = [ - "Rule_Id", - "Rule_Description", - "Parameter_Id", - "Parameter_Description", - "Parameter_Value_Alternatives", - ] - assert sorted(prop_names) == sorted(expected_prop_names) - prop_values = [prop.value for prop in set1_props] - expected_prop_values = [ - "rule_1", - "Rule 1 description", - "var_test", - "Test parameter", - "{'default': 'default', 'alternate': 'alternate'}", - ] - assert sorted(prop_values) == sorted(expected_prop_values) - - set2_props: List[Property] = next( - (rulesets[ruleset] for ruleset in rulesets.keys() if ruleset == "rule_set_1"), - [], - ) - - assert len(set2_props) == 2 - prop_names = [prop.name for prop in set2_props] - expected_prop_names = [ - "Rule_Id", - "Rule_Description", - ] - assert sorted(prop_names) == sorted(expected_prop_names) - prop_values = [prop.value for prop in set2_props] - expected_prop_values = [ - "rule_2", - "Rule 2 description", - ] - assert sorted(prop_values) == sorted(expected_prop_values) diff --git a/tests/unit/utils/test_generate_most_used_rules.py b/tests/unit/utils/test_generate_most_used_rules.py index d213fd6c0ea8..7900093bebde 100644 --- a/tests/unit/utils/test_generate_most_used_rules.py +++ b/tests/unit/utils/test_generate_most_used_rules.py @@ -1,6 +1,4 @@ import os -import sys -import pytest from argparse import Namespace from utils.profile_tool import command_most_used_rules @@ -16,7 +14,6 @@ def get_fake_args(): ) -@pytest.mark.skipif(sys.version_info[0] < 3, reason="requires python3") def test_command(capsys): command_most_used_rules(get_fake_args()) captured = capsys.readouterr() diff --git a/tox.ini b/tox.ini index 618e2cfdb1ec..ff71e7b8c25e 100644 --- a/tox.ini +++ b/tox.ini @@ -10,7 +10,7 @@ setenv = tests_dir = {toxinidir}{/}tests/unit PYTHONPATH = {toxinidir} commands = - python -m pytest --cov-append --cov-report=xml --cov=ssg "{env:tests_dir}{/}ssg-module" + python -m pytest --cov-append --cov-report=xml --cov=ssg "{env:tests_dir}{/}ssg-module" "{env:tests_dir}{/}build-scripts" deps = pyyaml diff --git a/utils/add_kubernetes_rule.py b/utils/add_kubernetes_rule.py index bb79b469c939..30ea08ed7b5b 100755 --- a/utils/add_kubernetes_rule.py +++ b/utils/add_kubernetes_rule.py @@ -406,7 +406,7 @@ def testFunc(args): if not args.skip_build: createTestProfile(args.rule) - ret_code, out = subprocess.getstatusoutput('./build_product --datastream-only ocp4') + ret_code, out = subprocess.getstatusoutput('./build_product --datastream ocp4 --cel-content=ocp4') if ret_code != 0: print('build failed: %s' % out) return 1 diff --git a/utils/ansible_playbook_to_role.py b/utils/ansible_playbook_to_role.py index d2da9d810fd4..4faeb7ca3690 100755 --- a/utils/ansible_playbook_to_role.py +++ b/utils/ansible_playbook_to_role.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function from tempfile import mkdtemp import io @@ -23,7 +22,7 @@ except ImportError: print("Please install PyGithub, you need a specific version of pygithub, install it through $ pip install \"PyGithub>=1.58.2,<2.0\"", file=sys.stderr) - raise SystemExit(1) + raise SystemExit(1) from None try: @@ -32,7 +31,7 @@ from ssg.utils import mkdir_p except ImportError: print("Unable to find the ssg module. Please run 'source .pyenv.sh'", file=sys.stderr) - raise SystemExit(1) + raise SystemExit(1) from None def memoize(f): @@ -198,7 +197,7 @@ def added_variables(self): variables = set() for task in self.tasks_data: if "tags" not in task: - next + continue if "when" not in task: task["when"] = [] elif isinstance(task["when"], str): @@ -281,7 +280,7 @@ def _description(self): break else: desc += (line + "\n") - return desc.strip("\n\n") + return desc.strip("\n") @property def _update_galaxy_tags(self): diff --git a/utils/ansible_shell_diff.py b/utils/ansible_shell_diff.py index 48d5f447102d..8c55ea1f79f2 100755 --- a/utils/ansible_shell_diff.py +++ b/utils/ansible_shell_diff.py @@ -25,7 +25,7 @@ def get_shell_tasks(tasks): for task in tasks: for task_name in ['shell', 'ansible.builtin.shell', 'command', 'ansible.builtin.command']: if task_name in task: - if type(task[task_name]) is dict and 'cmd' in task[task_name]: + if isinstance(task[task_name], dict) and 'cmd' in task[task_name]: shell_tasks.append(task[task_name]['cmd']) else: shell_tasks.append(task[task_name]) diff --git a/utils/build_ds_container.py b/utils/build_ds_container.py index 896488250ab0..8382819701a0 100755 --- a/utils/build_ds_container.py +++ b/utils/build_ds_container.py @@ -207,7 +207,7 @@ def copy_build_files_to_output_directory(output_directory): build_directory = os.path.join(REPO_PATH, 'build') for f in os.listdir(build_directory): filepath = os.path.join(build_directory, f) - if os.path.isfile(filepath) and filepath.endswith('-ds.xml'): + if os.path.isfile(filepath) and (filepath.endswith('-ds.xml') or filepath.endswith('-cel-content.yaml')): shutil.copy(filepath, output_directory) @@ -235,17 +235,34 @@ def create_profile_bundles(products, content_image=None): product_name = product else: product_name = 'upstream-' + product + + # Check if CEL content exists for this product + cel_content_file = product + '-cel-content.yaml' + build_directory = os.path.join(REPO_PATH, 'build') + cel_content_path = os.path.join(build_directory, cel_content_file) + + profile_bundle_spec = { + 'contentImage': content_image or 'openscap-ocp4-ds:latest', + 'contentFile': content_file + } + + # Add celContentFile if CEL content exists + if os.path.isfile(cel_content_path): + profile_bundle_spec['celContentFile'] = cel_content_file + log.debug(f'Including CEL content for {product}: {cel_content_file}') + profile_bundle_update = { 'apiVersion': 'compliance.openshift.io/v1alpha1', 'kind': 'ProfileBundle', 'metadata': {'name': product_name}, - 'spec': { - 'contentImage': content_image or 'openscap-ocp4-ds:latest', - 'contentFile': content_file}} + 'spec': profile_bundle_spec + } + with tempfile.NamedTemporaryFile() as f: yaml.dump(profile_bundle_update, f, encoding='utf-8') command = ['kubectl', 'apply', '-n', args.namespace, '-f', f.name] subprocess.run(command, check=True, capture_output=CAPTURE_OUTPUT) + log.info(f'Created profile bundles for {", ".join(products)}') diff --git a/utils/build_stig_control.py b/utils/build_stig_control.py index d767fbf1ca29..7f4de481038f 100755 --- a/utils/build_stig_control.py +++ b/utils/build_stig_control.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import argparse import json diff --git a/utils/compare_ds.py b/utils/compare_ds.py index ebdf2b67ffc7..bd82911dab7d 100755 --- a/utils/compare_ds.py +++ b/utils/compare_ds.py @@ -22,19 +22,20 @@ def parse_args(): "--rule", metavar="RULE_ID", help="Compare only the rule specified by given RULE_ID" ) - parser.add_argument( + diff_group = parser.add_mutually_exclusive_group() + diff_group.add_argument( "--no-diffs", action="store_true", help="Do not perform detailed comparison of checks and remediations contents." ) + diff_group.add_argument( + "--rule-diffs", action="store_true", + help="Output diffs per rule, instead of a single diff. " + "The rule diffs are output to directory './compare_ds-diffs/', override by --output-dir." + ) parser.add_argument( "--only-rules", action="store_true", help="Print only removals from rule set." ) - parser.add_argument( - "--rule-diffs", action="store_true", - help="Output diffs per rule, instead of a single diff. " - "The rule diffs are output to directory './compare_ds-diffs/'." - ) parser.add_argument( "--output-dir", metavar="OUTPUT_DIR", type=str, action="store", default="./compare_ds-diffs", diff --git a/utils/complyscribe-cli-compd.sh b/utils/complyscribe-cli-compd.sh deleted file mode 100644 index 963a7b65a841..000000000000 --- a/utils/complyscribe-cli-compd.sh +++ /dev/null @@ -1,55 +0,0 @@ -#!/bin/bash - -# This script aims to run the complyscribe CLI, which will sync CaC -# content controls/profiles updates to OSCAL component-definition. - -# The requirements are as follows: -# 1. The flag, "true" means the second requirement is policy_id. -# 2. The related policy_id or profile id of the CaC updates. -# 3. The product. -# 4. The oscal-content branch name. -# 5. The GitHub workspace path. -# 6. The mapping file for the specific product. - -# Usage: -# sh utils/complyscribe-cli-compd.sh false anssi_bp28_minimal rhel10 branch_name "/User/huiwang" rhel10_map.json -# sh utils/complyscribe-cli-compd.sh true anssi rhel10 branch_name "/User/huiwang" rhel10_map.json - -# Get the arguments -flag=$1 -policy_or_profile=$2 -product=$3 -branch_name=$4 -workspace_path=$5 -product_mapping_file=$6 - -if [ $# -lt 6 ]; then - echo "Please provide the necessary inputs." - exit 1 -fi - -sed -i "s/'/\"/g" "$product_mapping_file" -while IFS= read -r line; do - policy_id=$(echo "$line" | jq -r '.policy_id') - profile=$(echo "$line" | jq -r '.profile_name') - echo "$line" | jq -r '.levels[]' > levels - if [ "$flag" = "true" ]; then - param="$policy_id" - else - param="$profile" - fi - if [ "$policy_or_profile" = "$param" ]; then - while IFS= read -r level; do - oscal_profile=$product-$policy_id-$level - if echo "$product" | grep -q 'ocp4'; then - type="service" - else - type="software" - fi - sed -i "/href/s|\(trestle://\)[^ ]*\(catalogs\)|\1\2|g" "../oscal-content/profiles/$oscal_profile/profile.json" - poetry run complyscribe sync-cac-content component-definition --repo-path ../oscal-content --committer-email "openscap-ci@gmail.com" --committer-name "openscap-ci" --branch "$branch_name" --cac-content-root "$workspace_path/cac-content" --product "$product" --component-definition-type "$type" --cac-profile "$profile" --oscal-profile "$oscal_profile" - type="validation" - poetry run complyscribe sync-cac-content component-definition --repo-path ../oscal-content --committer-email "openscap-ci@gmail.com" --committer-name "openscap-ci" --branch "$branch_name" --cac-content-root "$workspace_path/cac-content" --product "$product" --component-definition-type "$type" --cac-profile "$profile" --oscal-profile "$oscal_profile" - done < levels - fi -done < "$product_mapping_file" diff --git a/utils/create-stig-overlay.py b/utils/create-stig-overlay.py index dc504e40b2c5..73055824d433 100755 --- a/utils/create-stig-overlay.py +++ b/utils/create-stig-overlay.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import sys import argparse diff --git a/utils/fix_rules.py b/utils/fix_rules.py index 7fc95804cef9..71fd850c1cb0 100755 --- a/utils/fix_rules.py +++ b/utils/fix_rules.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import sys import os @@ -10,7 +9,6 @@ import re from ssg import yaml, cce, products -from ssg.shims import input_func from ssg.utils import read_file_list import ssg import ssg.products @@ -440,7 +438,7 @@ def has_product_cce(yaml_contents, product): if not yaml_contents[section]: return False - for i_type, i_value in yaml_contents[section].items(): + for i_type, _ in yaml_contents[section].items(): if i_type[0:3] != 'cce' or "@" not in i_type: continue @@ -500,7 +498,7 @@ def _fixed_file_contents(path, file_contents, product_yaml, func): new_file_contents = func(file_contents, yaml_contents) except Exception as exc: msg = "Refusing to fix file: {path}: {error}".format(path=path, error=str(exc)) - raise RuntimeError(msg) + raise RuntimeError(msg) from exc return new_file_contents @@ -541,7 +539,7 @@ def fix_file_prompt(path, product_yaml, func, args): response = 'n' if need_input: - response = input_func("Confirm writing output to %s: (y/n): " % path) + response = input("Confirm writing output to %s: (y/n): " % path) if args.assume_yes or response.strip().lower() == 'y': changes = True @@ -577,16 +575,16 @@ def is_relevant_rule(rule_path, rule, rule_lines): cce = cce_pool.random_cce() - def fix_callback(file_contents, yaml_contents): + def fix_callback(file_contents, yaml_contents, cce=cce): return add_product_cce(file_contents, yaml_contents, product_yaml["product"], cce) try: changes = fix_file(rule_path, product_yaml, fix_callback) except RuntimeError as exc: - msg = ( # noqa: F841 + msg = ( "Error adding CCE into {rule_path}: {exc}" .format(rule_path=rule_path, exc=str(exc))) - raise RuntimeError(exc) + raise RuntimeError(msg) from exc if changes: cce_pool.remove_cce_from_file(cce) diff --git a/utils/gen_profile_table.py b/utils/gen_profile_table.py index 84d2cdd6eab2..2efce26e4624 100644 --- a/utils/gen_profile_table.py +++ b/utils/gen_profile_table.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import os import sys diff --git a/utils/generate_html_pages.sh b/utils/generate_html_pages.sh index 33b9a3878c76..2ffc7b648129 100755 --- a/utils/generate_html_pages.sh +++ b/utils/generate_html_pages.sh @@ -112,6 +112,14 @@ if [ $retVal -ne 0 ]; then exit 1 fi +# Copy NIST 800-53 Control Viewer +NIST_VIEWER_DIR="$PAGES_DIR/nist-viewer" +if [ -d "build/nist-controls-viewer" ]; then + mkdir -p "$NIST_VIEWER_DIR" + cp -rf build/nist-controls-viewer/* "$NIST_VIEWER_DIR/" + echo "NIST 800-53 Control Viewer copied to $NIST_VIEWER_DIR" +fi + # Generate Prometheus Stats PROMETHEUS_STATS_DIR="$PAGES_DIR/prometheus_stats" mkdir -p "$PROMETHEUS_STATS_DIR" @@ -134,6 +142,7 @@ echo "
  • Guides
  • " >> index.html echo "
  • Mapping Tables
  • " >> index.html echo "
  • SRG Mapping Tables
  • " >> index.html echo "
  • Rendered Policies
  • " >> index.html +echo "
  • NIST 800-53 Control Viewer & Gap Analysis
  • " >> index.html echo "
  • Components
  • " >> index.html echo "
  • Prometheus Policies Metrics
  • " >> index.html echo "" >> index.html diff --git a/utils/generate_profile.py b/utils/generate_profile.py index b02b12b839ea..bd7917581a7e 100755 --- a/utils/generate_profile.py +++ b/utils/generate_profile.py @@ -194,8 +194,8 @@ def _generate(self, node: pycompliance.Node) -> dict: d['levels'] = node.level.replace(' ', '_').lower() if node.children: d['controls'] = [] - for node in node.children: - d['controls'].append(self._generate(node)) + for sub_node in node.children: + d['controls'].append(self._generate(sub_node)) return d diff --git a/utils/nist_sync/.gitignore b/utils/nist_sync/.gitignore new file mode 100644 index 000000000000..da26b804e3ec --- /dev/null +++ b/utils/nist_sync/.gitignore @@ -0,0 +1,36 @@ +# Downloaded OSCAL data files +data/nist_800_53_rev5_*.json + +# Generated files (regenerated from source data) +data/variable_to_products.json + +# Generated profile files (derived from CIS profiles) +../../products/rhel8/profiles/cis_nist.profile +../../products/rhel9/profiles/cis_nist.profile +../../products/rhel10/profiles/cis_nist.profile + +# Note: data/cis_nist_mappings.json is COMMITTED (not ignored) +# It's only regenerated when CIS benchmark PDFs are updated + +# CIS Benchmark documents (large binary files) +*.pdf + +# Markdown conversions of PDFs +CIS_Red_Hat_Enterprise_Linux_*.md + +# Python virtual environment +venv/ +__pycache__/ +*.pyc +*.pyo + +# Temporary files +*.tmp +*.bak + +# Documentation (keep only workflow docs) +!CIS_NIST_WORKFLOW.md +!README.md + +# Auto-generated CIS-NIST profiles (derived from CIS profiles) +products/*/profiles/cis_nist.profile diff --git a/utils/nist_sync/README.md b/utils/nist_sync/README.md new file mode 100644 index 000000000000..1ec7b3246cb4 --- /dev/null +++ b/utils/nist_sync/README.md @@ -0,0 +1,294 @@ +# NIST 800-53 / CIS Synchronization Toolkit + +Automated tooling to generate and maintain NIST 800-53 control files from CIS benchmark mappings for ComplianceAsCode products. + +## Quick Start + +```bash +# Run the complete workflow (generates product-specific reference files) +./generate_cis_nist_workflow.sh + +# Test locally before committing +./test_workflow_local.sh +``` + +## Architecture Overview + +### Directory Structure + +The toolkit generates **product-specific split-by-family** reference control files: + +``` +shared/references/controls/ # Reference files (auto-generated) + ├── nist_800_53_cis_reference_rhel8.yml + ├── nist_800_53_cis_reference_rhel8/ # 21 family files (rhel8-specific) + │ ├── ac.yml + │ ├── au.yml + │ └── ... (19 more) + ├── nist_800_53_cis_reference_rhel9.yml + ├── nist_800_53_cis_reference_rhel9/ # 21 family files (rhel9-specific) + ├── nist_800_53_cis_reference_rhel10.yml + └── nist_800_53_cis_reference_rhel10/ # 21 family files (rhel10-specific) + +products/rhel8/controls/ # Product control files (human-maintained) + ├── nist_800_53.yml + └── nist_800_53/ # 21 family files (rhel8-specific) + ├── ac.yml + └── ... + +products/rhel9/controls/ + ├── nist_800_53.yml + └── nist_800_53/ # 21 family files (rhel9-specific) + +products/rhel10/controls/ + ├── nist_800_53.yml + └── nist_800_53/ # 21 family files (rhel10-specific) +``` + +Each control file contains: +- **Product-specific rules**: Only rules available for that product +- **NO Jinja2 guards**: Clean, simple YAML +- **NO OSCAL metadata**: Lean files (OSCAL data retrieved separately when needed) +- **Baseline levels**: Low, moderate, high applicability + +## Scripts + +### Main Workflow + +- **`generate_cis_nist_workflow.sh`** - Master orchestration script + - Downloads NIST OSCAL catalog + - Scans CIS control files for product-specific mappings + - Generates product-specific family files (rhel8, rhel9, rhel10) + - NO guards applied (product-specific filtering instead) + - Compares with previous version + - Used by GitHub Actions weekly automation + +### Core Components + +- **`sync_nist_split.py`** - Generate product-specific split control files + - **NEW**: Requires `--product` argument (rhel8, rhel9, or rhel10) + - Extracts control structure from OSCAL catalog (title, levels only) + - Inverts CIS→NIST mappings to populate rule selections + - **Filters rules to only those in target product's CIS control file** + - **Does NOT include OSCAL metadata** (description, parameters, guidance, related_controls) + - Outputs 21 family files per product + - Example: `python3 sync_nist_split.py --product rhel9` + +- **`harvest_cis_nist_mappings.py`** - Extract CIS→NIST mappings + - Scans CIS benchmark PDFs/documents + - Builds rule→NIST control mapping + - Outputs `data/cis_nist_mappings.json` + +- **`generate_variable_to_products.py`** - Build variable→products mapping + - Scans CIS control files for variable assignments + - Outputs `data/variable_to_products.json` + - Used during generation to identify product-specific variables + +### Utilities + +- **`download_oscal.py`** - Download NIST OSCAL catalog JSON +- **`compare_profile_rules.py`** - Validate CIS profile coverage +- **`generate_nist_based_cis_profile.py`** - Generate CIS-NIST profiles +- **`test_workflow_local.sh`** - Local testing script + +### Deprecated Scripts (Removed) + +- ~~`generate_product_family_guards.py`~~ - No longer needed (product-specific files instead of guards) + +## File Locations + +``` +products/{product}/controls/ +├── nist_800_53.yml # 👤 Product-specific metadata (human-edited) +└── nist_800_53/*.yml # 👤 Product-specific family files (human-edited) + +shared/references/controls/ +├── nist_800_53_cis_reference_{product}.yml # 🤖 Reference metadata (auto-generated) +└── nist_800_53_cis_reference_{product}/*.yml # 🤖 Reference family files (auto-generated) + +utils/nist_sync/ +├── *.py # Python scripts +├── *.sh # Bash orchestration +└── data/ # Generated mappings + ├── cis_nist_mappings.json # CIS→NIST mappings + ├── variable_to_products.json # Variable availability + └── nist_800_53_rev5_catalog.json # OSCAL catalog + +.github/workflows/ +└── cis-nist-sync.yml # Weekly automation workflow +``` + +## Workflows + +### Weekly Automation (GitHub Actions) + +Every Sunday at 2 PM UTC: +1. Downloads latest NIST OSCAL catalog +2. Generates product-specific reference family files for rhel8, rhel9, rhel10 +3. Compares with previous week's version +4. Creates PR if changes detected + +### Local Development + +```bash +# Run full workflow for all products +cd utils/nist_sync +./generate_cis_nist_workflow.sh + +# Generate for specific product only +python3 sync_nist_split.py --product rhel9 + +# Compare reference vs product files +diff -ur shared/references/controls/nist_800_53_cis_reference_rhel9/ \ + products/rhel9/controls/nist_800_53/ + +# Test profile coverage +python3 compare_profile_rules.py \ + ../../products/rhel9/profiles/cis.profile \ + ../../products/rhel9/profiles/cis_nist.profile \ + --product rhel9 +``` + +### Manual Sync + +When you need to manually sync changes: + +```bash +cd utils/nist_sync + +# Step 1: Regenerate reference files +python3 download_oscal.py # Update OSCAL catalog if needed +python3 sync_nist_split.py --product rhel9 + +# Step 2: Review and copy to product files if needed +# Compare reference vs product files to see differences +diff -ur ../../shared/references/controls/nist_800_53_cis_reference_rhel9/ \ + ../../products/rhel9/controls/nist_800_53/ + +# Step 3: Test build +cd ../.. +./build_product rhel9 --datastream-only +``` + +## Documentation + +- **Main documentation**: `docs/manual/developer/13_nist_800_53_controls.md` +- **Workflow details**: `.github/workflows/cis-nist-sync.yml` +- **Script usage**: Run any script with `--help` flag + +## Requirements + +```bash +pip install -r requirements.txt +``` + +Dependencies: +- `ruamel.yaml` - Round-trip YAML parsing +- Python 3.8+ + +## Key Concepts + +### Product-Specific Architecture + +Controls are generated separately for each product instead of using a single global file with Jinja2 guards: + +**Benefits**: +- ✅ Cleaner files without conditional logic +- ✅ Each product can evolve independently +- ✅ No NoneType build errors from guards evaluating to None +- ✅ Easier to understand (no guards cluttering rule lists) + +**Trade-offs**: +- ❌ More files to maintain (3x sets of family files) +- ❌ Changes to shared controls require updating multiple products +- ✅ But files are auto-generated weekly, so duplication manageable + +### Split-by-Family Architecture + +Controls are organized into 21 family files instead of a single monolithic file: +- Easier to navigate and edit +- Clearer git diffs +- Parallel processing support +- Better organization for 1,196 controls + +Families: AC, AT, AU, CA, CM, CP, IA, IR, MA, MP, PE, PL, PM, PS, PT, RA, SA, SC, SI, SR, OTHER + +### OSCAL Metadata (Excluded) + +OSCAL metadata fields are **NOT included** in generated control files: +- ❌ `description` - Full control statement with sub-parts +- ❌ `parameters` - Organization-Defined Parameters (ODPs) +- ❌ `guidance` - Implementation advice text +- ❌ `related_controls` - Control dependency references + +**Why excluded?**: +- Control files stay small and focused (~50-200 lines per family vs. thousands) +- OSCAL data retrieved from authoritative source when needed +- No duplication of large text blocks across products +- Updates to OSCAL catalog don't require regenerating control files + +**How to retrieve OSCAL metadata**: +1. Load OSCAL catalog: `utils/nist_sync/data/nist_800_53_rev5_catalog.json` +2. Look up control by ID (e.g., "ac-2") +3. Extract description, parameters, guidance, related_controls +4. Display in web application or documentation + +### Product-Specific Filtering + +During generation, rules are filtered to only those available in the target product: + +```python +# sync_nist_split.py filters rules by: +1. Reading target product's CIS control file (e.g., products/rhel9/controls/cis_rhel9.yml) +2. Extracting all rules/variables defined for that product +3. Filtering NIST control rules to only those in the product's CIS file +4. Handling variables with product-specific values (var_x=value) +``` + +Result: Each product's control files contain only rules that actually exist for that product. + +### Two File Sets + +- **Reference files** (`shared/references/...`) - Auto-generated from OSCAL + CIS, for comparison +- **Product files** (`products/{product}/controls/...`) - Human-editable, used for building + +This separation prevents automation from overwriting human edits while tracking upstream changes. + +## Troubleshooting + +**Build fails with "Control file not found":** +- Ensure product-specific control file exists: `products/{product}/controls/nist_800_53.yml` +- Check `controls_dir` field points to `nist_800_53` + +**Profile comparison shows missing rules:** +- Regenerate controls: `./generate_cis_nist_workflow.sh` +- Verify variable mappings: `cat data/variable_to_products.json` +- Check that CIS control file includes the rule + +**Want to add OSCAL metadata:** +- OSCAL metadata is not in control files (kept separate) +- Download catalog: `python3 download_oscal.py` +- Catalog location: `data/nist_800_53_rev5_catalog.json` +- Retrieve on-demand for web application or documentation + +**Sync script requires --product argument:** +- Old: `python3 sync_nist_split.py` (generated global file with guards) +- New: `python3 sync_nist_split.py --product rhel9` (generates product-specific files) +- Must specify product: rhel8, rhel9, or rhel10 + +## Contributing + +When modifying scripts: +1. Test locally with `test_workflow_local.sh` +2. Verify builds succeed for all products: + ```bash + ./build_product rhel8 rhel9 rhel10 --datastream-only + ``` +3. Check profile coverage: `compare_profile_rules.py` for each product +4. Update this README if workflow changes + +## References + +- NIST OSCAL: https://pages.nist.gov/OSCAL/ +- NIST 800-53: https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final +- CIS Benchmarks: https://www.cisecurity.org/cis-benchmarks diff --git a/utils/nist_sync/__init__.py b/utils/nist_sync/__init__.py new file mode 100644 index 000000000000..426144f6a3e4 --- /dev/null +++ b/utils/nist_sync/__init__.py @@ -0,0 +1 @@ +# NIST 800-53 Synchronization Utilities diff --git a/utils/nist_sync/ci_sync.sh b/utils/nist_sync/ci_sync.sh new file mode 100755 index 000000000000..ee00b513163b --- /dev/null +++ b/utils/nist_sync/ci_sync.sh @@ -0,0 +1,446 @@ +#!/usr/bin/env bash +# CI helper script for the CIS-NIST sync workflow. +# Called from .github/workflows/cis-nist-sync.yml with a subcommand. +# +# Usage: ci_sync.sh +# Subcommands: verify, collect-artifacts, summarize, check-changes, +# show-diff, create-pr, workflow-summary +# +# Required env vars depend on the subcommand; see each function for details. + +set -euo pipefail + +PRODUCTS="rhel8 rhel9 rhel10" + +cmd_verify() { + echo "✓ Product-Specific Reference files (auto-generated, for comparison):" + for product in $PRODUCTS; do + REF_DIR="shared/references/controls/nist_800_53_cis_reference_${product}" + echo " $product:" + echo " - Metadata: ${REF_DIR}.yml" + FAMILY_COUNT=$(find "${REF_DIR}" -maxdepth 1 -name "*.yml" 2>/dev/null | wc -l) + echo " - Families: ${REF_DIR}/*.yml ($FAMILY_COUNT files)" + done + echo "" + echo "✓ Product-Specific Control files (used in builds):" + for product in $PRODUCTS; do + NIST_DIR="products/$product/controls/nist_800_53" + echo " $product:" + echo " - Metadata: ${NIST_DIR}.yml" + REAL_COUNT=$(find "${NIST_DIR}" -maxdepth 1 -name "*.yml" 2>/dev/null | wc -l) + echo " - Families: ${NIST_DIR}/*.yml ($REAL_COUNT files)" + done + echo "" + echo "Note: Each product has its own NIST 800-53 control files" + echo " (NO guards, product-filtered)" +} + +cmd_collect_artifacts() { + mkdir -p artifacts/controls artifacts/profiles artifacts/data artifacts/datastreams + + for product in $PRODUCTS; do + REF_YML="shared/references/controls/nist_800_53_cis_reference_${product}.yml" + [ -f "$REF_YML" ] && cp "$REF_YML" "artifacts/controls/" + done + + cp utils/nist_sync/data/cis_nist_mappings.json artifacts/data/ + + for product in $PRODUCTS; do + if [ -f "products/$product/profiles/cis_nist.profile" ]; then + mkdir -p "artifacts/profiles/$product" + cp "products/$product/profiles/cis_nist.profile" "artifacts/profiles/$product/" + fi + done + + for product in $PRODUCTS; do + [ -f "build/ssg-$product-ds.xml" ] && cp "build/ssg-$product-ds.xml" artifacts/datastreams/ + done +} + +cmd_summarize() { + # Requires: GITHUB_STEP_SUMMARY + { + echo "# CIS-NIST Sync Report (Product-Specific)" + echo "" + echo "## Generated Artifacts" + echo "" + echo "### Product-Specific CIS Reference Files (Auto-Generated, NO Guards)" + + for product in $PRODUCTS; do + REF_DIR="shared/references/controls/nist_800_53_cis_reference_${product}" + echo "#### $product" + echo "- Metadata: \`${REF_DIR}.yml\`" + echo "- Families: \`${REF_DIR}/*.yml\`" + if [ -d "$REF_DIR" ]; then + FAMILY_COUNT=$(find "${REF_DIR}" -maxdepth 1 -name "*.yml" 2>/dev/null | wc -l) + echo " - Family files: $FAMILY_COUNT" + fi + echo "" + done + + echo "### Product-Specific Control Files (Used for Builds)" + for product in $PRODUCTS; do + PDIR="products/$product/controls/nist_800_53" + echo "- \`${PDIR}.yml\` + \`${PDIR}/*.yml\`" + done + + echo "" + echo "### Profiles" + for product in $PRODUCTS; do + if [ -f "products/$product/profiles/cis_nist.profile" ]; then + echo "- \`products/$product/profiles/cis_nist.profile\` (uses \`nist_800_53:all\`)" + fi + done + + echo "" + echo "## Mapping Statistics" + echo "" + + python3 - <<'PYEOF' +import json +with open('utils/nist_sync/data/cis_nist_mappings.json', 'r') as f: + data = json.load(f) + +print(f"- Rules mapped to NIST: {len(data['rules'])}") +print(f"- Variables mapped to NIST: {len(data['variables'])}") + +nist_controls = set() +for nist_list in data['rules'].values(): + nist_controls.update(nist_list) +for nist_list in data['variables'].values(): + nist_controls.update(nist_list) + +print(f"- Unique NIST controls referenced: {len(nist_controls)}") +PYEOF + + } >> "$GITHUB_STEP_SUMMARY" +} + +cmd_check_changes() { + # Requires: GITHUB_STEP_SUMMARY, GITHUB_OUTPUT + HAS_CHANGES=false + + echo "Checking for changes in product-specific CIS reference files..." + + for product in $PRODUCTS; do + echo "" + echo "Checking $product..." + + METADATA_FILE="shared/references/controls/nist_800_53_cis_reference_${product}.yml" + if [ -f "$METADATA_FILE" ]; then + if git ls-files --error-unmatch "$METADATA_FILE" >/dev/null 2>&1; then + if ! git diff --quiet HEAD -- "$METADATA_FILE"; then + echo " ✓ Changes in metadata file" + HAS_CHANGES=true + else + echo " - Metadata unchanged" + fi + else + echo " ✓ Metadata file is new" + HAS_CHANGES=true + fi + fi + + FAMILY_DIR="shared/references/controls/nist_800_53_cis_reference_${product}" + if [ -d "$FAMILY_DIR" ]; then + if git ls-files --error-unmatch "$FAMILY_DIR/" >/dev/null 2>&1; then + if ! git diff --quiet HEAD -- "$FAMILY_DIR/"; then + CHANGED_COUNT=$(git diff --name-only HEAD -- "$FAMILY_DIR/" | wc -l) + echo " ✓ Changes in family files ($CHANGED_COUNT files)" + HAS_CHANGES=true + else + echo " - Family files unchanged" + fi + else + echo " ✓ Family directory is new" + HAS_CHANGES=true + fi + fi + done + + echo "" + if [ "$HAS_CHANGES" = "true" ]; then + echo "has_changes=true" >> "$GITHUB_OUTPUT" + echo "✅ Changes detected - will create PR" + else + echo "has_changes=false" >> "$GITHUB_OUTPUT" + echo "ℹ️ No changes detected - skipping PR creation" + fi +} + +cmd_show_diff() { + # Requires: GITHUB_STEP_SUMMARY + { + echo "## ℹ️ Changes Detected (PR Creation Pending)" + echo "" + echo "Changes were detected. A PR will be created if:" + echo "- The changes can be staged (files differ from branch)" + echo "- The commits differ from origin/master" + echo "" + echo "## Changes Detected in CIS Reference" + echo "" + echo "The CIS→NIST mapping reference files have changed." + echo "" + + echo "### File Statistics" + echo '```' + for product in $PRODUCTS; do + REF_YML="shared/references/controls/nist_800_53_cis_reference_${product}.yml" + REF_DIR="shared/references/controls/nist_800_53_cis_reference_${product}/" + git diff --stat HEAD -- "$REF_YML" "$REF_DIR" 2>/dev/null || true + done + echo '```' + echo "" + + for product in $PRODUCTS; do + REF_DIR="shared/references/controls/nist_800_53_cis_reference_${product}" + echo "### $product Changes" + CHANGED_COUNT=$(git diff --name-only HEAD -- "$REF_DIR" | wc -l) + if [ "$CHANGED_COUNT" -gt 0 ]; then + echo "Changed files: $CHANGED_COUNT" + echo '```' + git diff --name-only HEAD -- "$REF_DIR" \ + | xargs -n 1 basename 2>/dev/null || true + echo '```' + else + echo "No changes for $product" + fi + echo "" + done + + echo "### What This Means" + echo "- CIS reference files show CIS→NIST mappings per product" + echo "- NO Jinja2 guards - rules are filtered by product" + echo "- Review the full diff in the PR to see all changes" + PDIR="\`products/{product}/controls/nist_800_53/\*.yml\`" + echo "- Manually apply relevant changes to $PDIR" + echo "- Product control files may have additional human edits" + + } >> "$GITHUB_STEP_SUMMARY" +} + +cmd_create_pr() { + # Requires: GITHUB_TOKEN, GITHUB_STEP_SUMMARY, GITHUB_OUTPUT + # Requires: GHA_EVENT_NAME, GHA_RUN_ID, GHA_REPOSITORY + + BRANCH_NAME="auto-update-nist-800-53-$(date +%Y%m%d-%H%M%S)" + echo "Creating branch: $BRANCH_NAME" + git checkout -b "$BRANCH_NAME" + + echo "Staging product-specific reference files..." + for product in $PRODUCTS; do + REF_BASE="shared/references/controls/nist_800_53_cis_reference_${product}" + git add "${REF_BASE}.yml" 2>/dev/null || true + git add "${REF_BASE}/" 2>/dev/null || true + done + + echo "Checking for staged changes..." + if git diff --cached --quiet; then + { + echo "⚠️ No staged changes detected" + echo "" + echo "**Reason:** Files are identical to what's in master." + echo "- The CIS mappings haven't changed since last sync" + echo "- The OSCAL catalog is the same version" + echo "✓ No action needed - everything is in sync!" + } | tee -a "$GITHUB_STEP_SUMMARY" + exit 0 + fi + + echo "✓ Found staged changes, proceeding with commit..." + git diff --cached --stat + + ADDED=$(git diff --cached --numstat | awk '{sum+=$1} END {print sum}') + REMOVED=$(git diff --cached --numstat | awk '{sum+=$2} END {print sum}') + CHANGES_SUMMARY="+${ADDED:-0}/-${REMOVED:-0}" + + git commit -m "$(cat < +EOF + )" + + git push origin "$BRANCH_NAME" + + echo "Verifying commits differ from origin/master..." + COMMITS_AHEAD=$(git rev-list --count origin/master.."$BRANCH_NAME" 2>/dev/null || echo "0") + if [ "$COMMITS_AHEAD" = "0" ]; then + { + echo "⚠️ No commits ahead of origin/master" + echo "" + echo "**Branch:** $BRANCH_NAME" + echo "Skipping PR creation (would fail with 'no commits' error)." + } | tee -a "$GITHUB_STEP_SUMMARY" + exit 0 + fi + + echo "✓ Found $COMMITS_AHEAD commit(s) ahead of origin/master" + + echo "Checking for existing open PRs..." + EXISTING_PR=$(gh pr list \ + --base master --state open \ + --search "NIST 800-53 CIS Reference Update in:title" \ + --json number --jq '.[0].number' \ + 2>/dev/null || echo "") + + if [ -n "$EXISTING_PR" ]; then + EXISTING_PR_URL=$(gh pr view "$EXISTING_PR" --json url --jq '.url') + TIMESTAMP=$(date '+%Y-%m-%d %H:%M:%S UTC') + RUN_URL="https://github.com/${GHA_REPOSITORY}/actions/runs/${GHA_RUN_ID}" + + gh pr comment "$EXISTING_PR" --body "$(cat </dev/null || true + + { + echo "⚠️ Found existing open PR #$EXISTING_PR" + echo "✅ Updated existing PR with timestamp comment" + echo " at $EXISTING_PR_URL" + } >> "$GITHUB_STEP_SUMMARY" + exit 0 + fi + + if [ "$GHA_EVENT_NAME" = "schedule" ]; then + TRIGGER="Weekly scheduled workflow" + else + TRIGGER="Manual workflow dispatch" + fi + + PR_URL=$(gh pr create \ + --title "🔄 NIST 800-53 CIS Reference Update ($(date +%Y-%m-%d))" \ + --body "$(cat </dev/null | sort || echo "None") + + FAMILIES_DIFF=$(git diff origin/master...HEAD -- "${REF_BASE}*/" | head -1000) + TRUNC_MSG="" + FULL_LINES=$(git diff origin/master...HEAD -- "${REF_BASE}*/" | wc -l) + [ "$FULL_LINES" -gt 1000 ] && \ + TRUNC_MSG="_Diff truncated to 1000 lines. View full diff in Files Changed._" + + gh pr comment "$PR_URL" --body "$(cat < +📁 Family files diff + +\`\`\`diff +$FAMILIES_DIFF +\`\`\` + +$TRUNC_MSG + + + +**Tip:** Family files (ac.yml, au.yml, cm.yml, etc.) make it +easier to review changes by control area. +EOF + )" + + { + echo "✅ Pull request created: $PR_URL" + echo "Branch: \`$BRANCH_NAME\`" + } >> "$GITHUB_STEP_SUMMARY" +} + +cmd_workflow_summary() { + # Requires: GITHUB_STEP_SUMMARY, GHA_EVENT_NAME, HAS_CHANGES + { + echo "## 📊 CIS-NIST Sync Workflow Summary" + echo "" + echo "**Event:** ${GHA_EVENT_NAME}" + echo "**Run ID:** ${GHA_RUN_ID}" + echo "" + + if [ "${HAS_CHANGES}" = "true" ]; then + if [ "$GHA_EVENT_NAME" = "schedule" ] || [ "$GHA_EVENT_NAME" = "workflow_dispatch" ]; then + echo "**Outcome:** Changes detected, attempted PR creation" + echo "" + echo "See the 'Create Pull Request' step for PR creation status." + else + echo "**Outcome:** Changes detected" + echo "(PR creation only runs on schedule/manual trigger)" + fi + else + echo "**Outcome:** ✅ No changes - reference files are up to date" + echo "" + echo "CIS mappings and OSCAL catalog have not changed since last sync." + fi + } >> "$GITHUB_STEP_SUMMARY" +} + +case "${1:-}" in + verify) cmd_verify ;; + collect-artifacts) cmd_collect_artifacts ;; + summarize) cmd_summarize ;; + check-changes) cmd_check_changes ;; + show-diff) cmd_show_diff ;; + create-pr) cmd_create_pr ;; + workflow-summary) cmd_workflow_summary ;; + *) + echo "Usage: $0 {verify|collect-artifacts|summarize|check-changes|show-diff|create-pr|workflow-summary}" >&2 + exit 1 + ;; +esac diff --git a/utils/nist_sync/compare_profile_rules.py b/utils/nist_sync/compare_profile_rules.py new file mode 100755 index 000000000000..6bc4480564dc --- /dev/null +++ b/utils/nist_sync/compare_profile_rules.py @@ -0,0 +1,254 @@ +#!/usr/bin/env python3 +""" +Compare rules between CIS profile and NIST-based CIS profile. + +This script verifies that the NIST-based CIS profile produces the same +set of rules and variables as the original CIS profile. + +Usage: + ./compare_profile_rules.py --product rhel9 --cis-level l2_server +""" + +import sys +from pathlib import Path +from typing import Dict, List, Set +import argparse + +try: + from ruamel.yaml import YAML +except ImportError: + print("Error: ruamel.yaml is required. Install it with:", file=sys.stderr) + print(" pip install ruamel.yaml", file=sys.stderr) + sys.exit(1) + + +class ProfileComparator: + """Compares rules between CIS and NIST-based profiles.""" + + def __init__(self, repo_root: Path): + self.repo_root = repo_root + self.yaml = YAML() + self.yaml.preserve_quotes = True + self.yaml.default_flow_style = False + + def load_control_file(self, control_file: Path) -> Dict: + """Load a control file.""" + with open(control_file, 'r', encoding='utf-8') as f: + return self.yaml.load(f) + + def get_rules_from_cis_controls( + self, + product: str, + cis_level: str + ) -> tuple[Set[str], Set[str]]: + """Get rules and variables from CIS control file for a specific level.""" + cis_file = self.repo_root / "products" / product / "controls" / f"cis_{product}.yml" + + if not cis_file.exists(): + print(f"Error: CIS control file not found at {cis_file}", file=sys.stderr) + sys.exit(1) + + cis_data = self.load_control_file(cis_file) + + # Map level to list (handle inheritance) + levels_to_include = set() + if cis_level in ['l2_server', 'l2_workstation']: + # L2 includes L1 + levels_to_include.add(cis_level) + base_level = 'l1_server' if 'server' in cis_level else 'l1_workstation' + levels_to_include.add(base_level) + else: + levels_to_include.add(cis_level) + + rules = set() + variables = set() + + for control in cis_data.get('controls', []): + control_levels = control.get('levels', []) + + # Check if control applies to any of the levels we're including + if any(level in control_levels for level in levels_to_include): + for rule in control.get('rules', []): + if '=' in rule: + variables.add(rule) + else: + rules.add(rule) + + return rules, variables + + def get_rules_from_nist_controls( + self, + nist_control_ids: List[str] + ) -> tuple[Set[str], Set[str]]: + """Get rules and variables from NIST control file for given control IDs.""" + nist_file = self.repo_root / "controls" / "nist_800_53.yml" + + if not nist_file.exists(): + print(f"Error: NIST control file not found at {nist_file}", file=sys.stderr) + sys.exit(1) + + nist_data = self.load_control_file(nist_file) + + # Create lookup by control ID + controls_by_id = { + ctrl['id']: ctrl + for ctrl in nist_data.get('controls', []) + } + + rules = set() + variables = set() + + for ctrl_id in nist_control_ids: + if ctrl_id in controls_by_id: + control = controls_by_id[ctrl_id] + for rule in control.get('rules', []): + if '=' in rule: + variables.add(rule) + else: + rules.add(rule) + + return rules, variables + + def get_nist_profile_selections(self, product: str) -> List[str]: + """Get control selections from NIST-based profile.""" + profile_file = self.repo_root / "products" / product / "profiles" / "cis_nist.profile" + + if not profile_file.exists(): + print(f"Error: NIST-based profile not found at {profile_file}", file=sys.stderr) + print("Run generate_nist_based_cis_profile.py first", file=sys.stderr) + sys.exit(1) + + with open(profile_file, 'r', encoding='utf-8') as f: + profile_data = self.yaml.load(f) + + # Extract control IDs from selections + control_ids = [] + for selection in profile_data.get('selections', []): + if selection.startswith('nist_800_53:'): + ctrl_id = selection.split(':', 1)[1] + control_ids.append(ctrl_id) + + return control_ids + + def compare(self, product: str, cis_level: str): + """Compare CIS and NIST-based profiles.""" + print(f"Comparing CIS and NIST-based profiles for {product} ({cis_level})...") + print() + + # Get rules from CIS control file + print("Analyzing CIS control file...") + cis_rules, cis_vars = self.get_rules_from_cis_controls(product, cis_level) + print(f" Found {len(cis_rules)} rules and {len(cis_vars)} variables") + + # Get rules from NIST-based profile + print("\nAnalyzing NIST-based profile...") + nist_control_ids = self.get_nist_profile_selections(product) + print(f" Profile includes {len(nist_control_ids)} control selections") + + nist_rules, nist_vars = self.get_rules_from_nist_controls(nist_control_ids) + print(f" Found {len(nist_rules)} rules and {len(nist_vars)} variables") + + # Compare + print("\n" + "=" * 60) + print("COMPARISON RESULTS") + print("=" * 60) + + # Rules comparison + print("\nRules:") + print(f" CIS: {len(cis_rules)}") + print(f" NIST: {len(nist_rules)}") + + missing_in_nist = cis_rules - nist_rules + extra_in_nist = nist_rules - cis_rules + + if missing_in_nist: + print(f"\n ⚠ {len(missing_in_nist)} rules in CIS but NOT in NIST profile:") + for rule in sorted(missing_in_nist)[:10]: + print(f" - {rule}") + if len(missing_in_nist) > 10: + print(f" ... and {len(missing_in_nist) - 10} more") + + if extra_in_nist: + print(f"\n ⚠ {len(extra_in_nist)} rules in NIST but NOT in CIS profile:") + for rule in sorted(extra_in_nist)[:10]: + print(f" - {rule}") + if len(extra_in_nist) > 10: + print(f" ... and {len(extra_in_nist) - 10} more") + + if not missing_in_nist and not extra_in_nist: + print(" ✓ Rules match perfectly!") + + # Variables comparison + print("\nVariables:") + print(f" CIS: {len(cis_vars)}") + print(f" NIST: {len(nist_vars)}") + + missing_vars_in_nist = cis_vars - nist_vars + extra_vars_in_nist = nist_vars - cis_vars + + if missing_vars_in_nist: + print(f"\n ⚠ {len(missing_vars_in_nist)} variables in CIS but NOT in NIST profile:") + for var in sorted(missing_vars_in_nist)[:10]: + print(f" - {var}") + if len(missing_vars_in_nist) > 10: + print(f" ... and {len(missing_vars_in_nist) - 10} more") + + if extra_vars_in_nist: + print(f"\n ⚠ {len(extra_vars_in_nist)} variables in NIST but NOT in CIS profile:") + for var in sorted(extra_vars_in_nist)[:10]: + print(f" - {var}") + if len(extra_vars_in_nist) > 10: + print(f" ... and {len(extra_vars_in_nist) - 10} more") + + if not missing_vars_in_nist and not extra_vars_in_nist: + print(" ✓ Variables match perfectly!") + + # Overall result + print("\n" + "=" * 60) + if not missing_in_nist and not extra_in_nist and not missing_vars_in_nist and not extra_vars_in_nist: + print("✓ Profiles are equivalent!") + return 0 + else: + total_diff = len(missing_in_nist) + len(extra_in_nist) + len(missing_vars_in_nist) + len(extra_vars_in_nist) + print(f"⚠ Profiles differ by {total_diff} items") + return 1 + + +def main(): + """Main entry point.""" + parser = argparse.ArgumentParser( + description='Compare CIS and NIST-based profiles' + ) + parser.add_argument( + '--product', + default='rhel9', + help='Product ID (default: rhel9)' + ) + parser.add_argument( + '--cis-level', + default='l2_server', + choices=['l1_server', 'l2_server', 'l1_workstation', 'l2_workstation'], + help='CIS level to compare (default: l2_server)' + ) + parser.add_argument( + '--repo-root', + type=Path, + default=Path(__file__).parent.parent.parent, + help='Path to repository root (default: auto-detect)' + ) + + args = parser.parse_args() + + comparator = ProfileComparator(args.repo_root) + + try: + return comparator.compare(args.product, args.cis_level) + except Exception as e: + print(f"\n✗ Comparison failed: {e}", file=sys.stderr) + import traceback + traceback.print_exc() + return 1 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/utils/nist_sync/data/cis_nist_mappings.json b/utils/nist_sync/data/cis_nist_mappings.json new file mode 100644 index 000000000000..00011ee09c5e --- /dev/null +++ b/utils/nist_sync/data/cis_nist_mappings.json @@ -0,0 +1,1710 @@ +{ + "rules": { + "account_password_pam_faillock_password_auth": [ + "ac-7", + "cm-1" + ], + "account_password_pam_faillock_system_auth": [ + "ac-7", + "cm-1" + ], + "account_unique_id": [ + "cm-1", + "ia-2" + ], + "account_unique_name": [ + "cm-1" + ], + "accounts_maximum_age_login_defs": [ + "cm-1" + ], + "accounts_minimum_age_login_defs": [ + "ia-5" + ], + "accounts_no_uid_except_zero": [ + "cm-1" + ], + "accounts_password_all_shadowed": [ + "ia-5" + ], + "accounts_password_pam_dictcheck": [ + "ia-5" + ], + "accounts_password_pam_difok": [ + "ia-5" + ], + "accounts_password_pam_enforce_root": [ + "ia-5" + ], + "accounts_password_pam_maxrepeat": [ + "ia-5" + ], + "accounts_password_pam_maxsequence": [ + "ia-5" + ], + "accounts_password_pam_minclass": [ + "ia-5" + ], + "accounts_password_pam_minlen": [ + "ia-5" + ], + "accounts_password_pam_pwhistory_enforce_for_root": [ + "ia-5" + ], + "accounts_password_pam_pwhistory_remember_password_auth": [ + "ia-5.1" + ], + "accounts_password_pam_pwhistory_remember_system_auth": [ + "ia-5.1" + ], + "accounts_password_pam_pwhistory_use_authtok": [ + "ia-5" + ], + "accounts_password_pam_pwquality_password_auth": [ + "cm-6" + ], + "accounts_password_pam_pwquality_system_auth": [ + "cm-6" + ], + "accounts_password_pam_unix_authtok": [ + "ia-5" + ], + "accounts_password_pam_unix_enabled": [ + "ia-5.1" + ], + "accounts_password_set_max_life_existing": [ + "cm-1" + ], + "accounts_password_set_min_life_existing": [ + "ia-5" + ], + "accounts_root_gid_zero": [ + "cm-1" + ], + "accounts_root_path_dirs_no_write": [ + "cm-1" + ], + "accounts_umask_etc_bashrc": [ + "ac-3", + "cm-6" + ], + "accounts_umask_etc_login_defs": [ + "ac-3", + "cm-6" + ], + "accounts_umask_etc_profile": [ + "ac-3", + "cm-6" + ], + "accounts_umask_root": [ + "ac-3" + ], + "accounts_user_dot_group_ownership": [ + "cm-1" + ], + "accounts_user_dot_user_ownership": [ + "cm-1" + ], + "accounts_user_interactive_home_directory_exists": [ + "cm-6" + ], + "aide_build_database": [ + "au-2" + ], + "aide_periodic_cron_checking": [ + "au-2" + ], + "audit_rules_dac_modification_chmod": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_chown": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_fchmod": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_fchmodat": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_fchmodat2": [ + "au-12" + ], + "audit_rules_dac_modification_fchown": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_fchownat": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_fremovexattr": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_fsetxattr": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_lchown": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_lremovexattr": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_lsetxattr": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_removexattr": [ + "au-12", + "au-3" + ], + "audit_rules_dac_modification_setxattr": [ + "au-12", + "au-3" + ], + "audit_rules_execution_chacl": [ + "au-2" + ], + "audit_rules_execution_chcon": [ + "au-12", + "au-2" + ], + "audit_rules_execution_setfacl": [ + "au-2" + ], + "audit_rules_file_deletion_events_rename": [ + "au-12" + ], + "audit_rules_file_deletion_events_renameat": [ + "au-12" + ], + "audit_rules_file_deletion_events_renameat2": [ + "au-12" + ], + "audit_rules_file_deletion_events_unlink": [ + "au-12" + ], + "audit_rules_file_deletion_events_unlinkat": [ + "au-12" + ], + "audit_rules_immutable": [ + "ac-3", + "au-9" + ], + "audit_rules_kernel_module_loading_create": [ + "au-12", + "au-3" + ], + "audit_rules_kernel_module_loading_delete": [ + "au-12", + "au-3" + ], + "audit_rules_kernel_module_loading_finit": [ + "au-12", + "au-3" + ], + "audit_rules_kernel_module_loading_init": [ + "au-12", + "au-3" + ], + "audit_rules_kernel_module_loading_query": [ + "au-12", + "au-3" + ], + "audit_rules_login_events_faillock": [ + "au-12", + "au-3" + ], + "audit_rules_login_events_lastlog": [ + "au-12", + "au-3" + ], + "audit_rules_mac_modification": [ + "au-3" + ], + "audit_rules_mac_modification_etc_selinux": [ + "au-3" + ], + "audit_rules_mac_modification_usr_share": [ + "au-3" + ], + "audit_rules_media_export": [ + "au-12", + "cm-6" + ], + "audit_rules_networkconfig_modification": [ + "au-3" + ], + "audit_rules_networkconfig_modification_etc_hosts": [ + "au-3" + ], + "audit_rules_networkconfig_modification_etc_issue": [ + "au-3" + ], + "audit_rules_networkconfig_modification_etc_issue_net": [ + "au-3" + ], + "audit_rules_networkconfig_modification_etc_networkmanager_system_connections": [ + "au-3" + ], + "audit_rules_networkconfig_modification_etc_sysconfig_network": [ + "au-3" + ], + "audit_rules_networkconfig_modification_hostname_file": [ + "au-3" + ], + "audit_rules_networkconfig_modification_network_scripts": [ + "au-3" + ], + "audit_rules_networkconfig_modification_networkmanager": [ + "au-3" + ], + "audit_rules_networkconfig_modification_setdomainname": [ + "au-3" + ], + "audit_rules_networkconfig_modification_sethostname": [ + "au-3" + ], + "audit_rules_privileged_commands": [ + "au-3" + ], + "audit_rules_privileged_commands_kmod": [ + "au-12", + "au-3" + ], + "audit_rules_privileged_commands_usermod": [ + "au-12", + "au-2" + ], + "audit_rules_session_events_btmp": [ + "au-3" + ], + "audit_rules_session_events_utmp": [ + "au-3" + ], + "audit_rules_session_events_wtmp": [ + "au-3" + ], + "audit_rules_suid_auid_privilege_function": [ + "au-3" + ], + "audit_rules_sysadmin_actions": [ + "au-12", + "au-3" + ], + "audit_rules_time_adjtimex": [ + "au-3" + ], + "audit_rules_time_clock_settime": [ + "au-3" + ], + "audit_rules_time_settimeofday": [ + "au-3" + ], + "audit_rules_time_watch_localtime": [ + "au-3" + ], + "audit_rules_unsuccessful_file_modification_creat": [ + "au-12", + "au-3" + ], + "audit_rules_unsuccessful_file_modification_ftruncate": [ + "au-12", + "au-3" + ], + "audit_rules_unsuccessful_file_modification_open": [ + "au-12", + "au-3" + ], + "audit_rules_unsuccessful_file_modification_openat": [ + "au-12", + "au-3" + ], + "audit_rules_unsuccessful_file_modification_truncate": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_group": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_gshadow": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_nsswitch_conf": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_opasswd": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_pam_conf": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_pamd": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_passwd": [ + "au-12", + "au-3" + ], + "audit_rules_usergroup_modification_shadow": [ + "au-12", + "au-3" + ], + "auditd_data_disk_error_action": [ + "au-2", + "au-5" + ], + "auditd_data_disk_full_action": [ + "au-2", + "au-5" + ], + "auditd_data_retention_action_mail_acct": [ + "au-2" + ], + "auditd_data_retention_admin_space_left_action": [ + "au-2" + ], + "auditd_data_retention_max_log_file": [ + "au-8" + ], + "auditd_data_retention_max_log_file_action": [ + "au-8" + ], + "auditd_data_retention_space_left_action": [ + "au-2" + ], + "banner_etc_issue_cis": [ + "cm-6" + ], + "banner_etc_issue_net_cis": [ + "cm-6" + ], + "banner_etc_motd_cis": [ + "cm-6" + ], + "chronyd_specify_remote_server": [ + "au-3" + ], + "configure_custom_crypto_policy_cis": [ + "ac-17", + "cm-1", + "sc-8" + ], + "configure_ssh_crypto_policy": [ + "ac-17" + ], + "coredump_disable_backtraces": [ + "cm-6" + ], + "coredump_disable_storage": [ + "cm-6" + ], + "dconf_gnome_banner_enabled": [ + "ac-8" + ], + "dconf_gnome_disable_automount": [ + "ia-3" + ], + "dconf_gnome_disable_automount_open": [ + "ia-3" + ], + "dconf_gnome_disable_autorun": [ + "cm-7" + ], + "dconf_gnome_disable_user_list": [ + "cm-6" + ], + "dconf_gnome_login_banner_text": [ + "ac-8" + ], + "dconf_gnome_screensaver_idle_delay": [ + "ac-11" + ], + "dconf_gnome_screensaver_lock_delay": [ + "ac-11" + ], + "dconf_gnome_screensaver_user_locks": [ + "ac-11" + ], + "dconf_gnome_session_idle_user_locks": [ + "ac-11" + ], + "dir_perms_world_writable_sticky_bits": [ + "ac-3", + "sc-4" + ], + "directory_groupowner_sshd_config_d": [ + "ac-3" + ], + "directory_owner_sshd_config_d": [ + "ac-3" + ], + "directory_permissions_sshd_config_d": [ + "ac-3" + ], + "directory_permissions_var_log_audit": [ + "au-3" + ], + "disable_host_auth": [ + "cm-1", + "cm-6" + ], + "disable_users_coredumps": [ + "cm-6" + ], + "ensure_gpgcheck_globally_activated": [ + "si-2" + ], + "ensure_gpgcheck_never_disabled": [ + "si-2" + ], + "ensure_pam_wheel_group_empty": [ + "ac-3" + ], + "ensure_redhat_gpgkey_installed": [ + "si-2" + ], + "file_at_allow_exists": [ + "ac-3" + ], + "file_at_deny_not_exist": [ + "ac-3" + ], + "file_cron_allow_exists": [ + "ac-3" + ], + "file_cron_deny_not_exist": [ + "ac-3" + ], + "file_etc_security_opasswd": [ + "ac-3" + ], + "file_groupowner_at_allow": [ + "ac-3" + ], + "file_groupowner_backup_etc_group": [ + "ac-3" + ], + "file_groupowner_backup_etc_gshadow": [ + "ac-3" + ], + "file_groupowner_backup_etc_passwd": [ + "ac-3" + ], + "file_groupowner_backup_etc_shadow": [ + "ac-3" + ], + "file_groupowner_boot_grub2": [ + "cm-6" + ], + "file_groupowner_cron_allow": [ + "ac-3" + ], + "file_groupowner_cron_d": [ + "ac-3" + ], + "file_groupowner_cron_daily": [ + "ac-3" + ], + "file_groupowner_cron_hourly": [ + "ac-3" + ], + "file_groupowner_cron_monthly": [ + "ac-3" + ], + "file_groupowner_cron_weekly": [ + "ac-3" + ], + "file_groupowner_cron_yearly": [ + "ac-3" + ], + "file_groupowner_crontab": [ + "ac-3" + ], + "file_groupowner_efi_grub2_cfg": [ + "cm-6" + ], + "file_groupowner_efi_user_cfg": [ + "cm-6" + ], + "file_groupowner_etc_group": [ + "ac-3" + ], + "file_groupowner_etc_gshadow": [ + "ac-3" + ], + "file_groupowner_etc_issue": [ + "ac-3" + ], + "file_groupowner_etc_issue_net": [ + "ac-3" + ], + "file_groupowner_etc_motd": [ + "ac-3" + ], + "file_groupowner_etc_passwd": [ + "ac-3" + ], + "file_groupowner_etc_security_opasswd": [ + "ac-3" + ], + "file_groupowner_etc_security_opasswd_old": [ + "ac-3" + ], + "file_groupowner_etc_shadow": [ + "ac-3" + ], + "file_groupowner_etc_shells": [ + "ac-3" + ], + "file_groupowner_etc_sysconfig_sshd": [ + "ac-3" + ], + "file_groupowner_grub2_cfg": [ + "ac-3", + "cm-6" + ], + "file_groupowner_sshd_config": [ + "ac-3" + ], + "file_groupowner_sshd_drop_in_config": [ + "ac-3" + ], + "file_groupowner_user_cfg": [ + "ac-3", + "cm-6" + ], + "file_groupownership_audit_binaries": [ + "au-3" + ], + "file_groupownership_sshd_private_key": [ + "ac-3", + "cm-6" + ], + "file_groupownership_sshd_pub_key": [ + "ac-3", + "cm-6" + ], + "file_owner_at_allow": [ + "ac-3" + ], + "file_owner_backup_etc_group": [ + "ac-3" + ], + "file_owner_backup_etc_gshadow": [ + "ac-3" + ], + "file_owner_backup_etc_passwd": [ + "ac-3" + ], + "file_owner_backup_etc_shadow": [ + "ac-3" + ], + "file_owner_boot_grub2": [ + "cm-6" + ], + "file_owner_cron_allow": [ + "ac-3" + ], + "file_owner_cron_d": [ + "ac-3" + ], + "file_owner_cron_daily": [ + "ac-3" + ], + "file_owner_cron_hourly": [ + "ac-3" + ], + "file_owner_cron_monthly": [ + "ac-3" + ], + "file_owner_cron_weekly": [ + "ac-3" + ], + "file_owner_cron_yearly": [ + "ac-3" + ], + "file_owner_crontab": [ + "ac-3" + ], + "file_owner_efi_grub2_cfg": [ + "cm-6" + ], + "file_owner_efi_user_cfg": [ + "cm-6" + ], + "file_owner_etc_group": [ + "ac-3" + ], + "file_owner_etc_gshadow": [ + "ac-3" + ], + "file_owner_etc_issue": [ + "ac-3" + ], + "file_owner_etc_issue_net": [ + "ac-3" + ], + "file_owner_etc_motd": [ + "ac-3" + ], + "file_owner_etc_passwd": [ + "ac-3" + ], + "file_owner_etc_security_opasswd": [ + "ac-3" + ], + "file_owner_etc_security_opasswd_old": [ + "ac-3" + ], + "file_owner_etc_shadow": [ + "ac-3" + ], + "file_owner_etc_shells": [ + "ac-3" + ], + "file_owner_etc_sysconfig_sshd": [ + "ac-3" + ], + "file_owner_grub2_cfg": [ + "ac-3", + "cm-6" + ], + "file_owner_sshd_config": [ + "ac-3" + ], + "file_owner_sshd_drop_in_config": [ + "ac-3" + ], + "file_owner_user_cfg": [ + "ac-3", + "cm-6" + ], + "file_ownership_home_directories": [ + "cm-6" + ], + "file_ownership_sshd_private_key": [ + "ac-3", + "cm-6" + ], + "file_ownership_sshd_pub_key": [ + "ac-3", + "cm-6" + ], + "file_ownership_var_log_audit_stig": [ + "au-3", + "cm-7" + ], + "file_permission_user_bash_history": [ + "cm-1" + ], + "file_permission_user_init_files": [ + "cm-1" + ], + "file_permissions_at_allow": [ + "ac-3" + ], + "file_permissions_audit_binaries": [ + "au-3" + ], + "file_permissions_audit_configuration": [ + "au-12" + ], + "file_permissions_backup_etc_group": [ + "ac-3" + ], + "file_permissions_backup_etc_gshadow": [ + "ac-3" + ], + "file_permissions_backup_etc_passwd": [ + "ac-3" + ], + "file_permissions_backup_etc_shadow": [ + "ac-3" + ], + "file_permissions_boot_grub2": [ + "cm-6" + ], + "file_permissions_cron_allow": [ + "ac-3" + ], + "file_permissions_cron_d": [ + "ac-3" + ], + "file_permissions_cron_daily": [ + "ac-3" + ], + "file_permissions_cron_hourly": [ + "ac-3" + ], + "file_permissions_cron_monthly": [ + "ac-3" + ], + "file_permissions_cron_weekly": [ + "ac-3" + ], + "file_permissions_cron_yearly": [ + "ac-3" + ], + "file_permissions_crontab": [ + "ac-3" + ], + "file_permissions_efi_grub2_cfg": [ + "cm-6" + ], + "file_permissions_efi_user_cfg": [ + "cm-6" + ], + "file_permissions_etc_group": [ + "ac-3" + ], + "file_permissions_etc_gshadow": [ + "ac-3" + ], + "file_permissions_etc_issue": [ + "ac-3" + ], + "file_permissions_etc_issue_net": [ + "ac-3" + ], + "file_permissions_etc_motd": [ + "ac-3" + ], + "file_permissions_etc_passwd": [ + "ac-3" + ], + "file_permissions_etc_security_opasswd": [ + "ac-3" + ], + "file_permissions_etc_security_opasswd_old": [ + "ac-3" + ], + "file_permissions_etc_shadow": [ + "ac-3" + ], + "file_permissions_etc_shells": [ + "ac-3" + ], + "file_permissions_etc_sysconfig_sshd": [ + "ac-3" + ], + "file_permissions_grub2_cfg": [ + "ac-3", + "cm-6" + ], + "file_permissions_home_directories": [ + "cm-6" + ], + "file_permissions_sshd_config": [ + "ac-3" + ], + "file_permissions_sshd_drop_in_config": [ + "ac-3" + ], + "file_permissions_sshd_private_key": [ + "ac-3", + "cm-6" + ], + "file_permissions_sshd_pub_key": [ + "ac-3", + "cm-6" + ], + "file_permissions_unauthorized_world_writable": [ + "ac-3", + "sc-4" + ], + "file_permissions_ungroupowned": [ + "ac-3" + ], + "file_permissions_user_cfg": [ + "ac-3", + "cm-6" + ], + "firewalld-backend": [ + "ca-9" + ], + "firewalld_loopback_traffic_restricted": [ + "ca-9" + ], + "firewalld_loopback_traffic_trusted": [ + "ca-9" + ], + "gid_passwd_group_same": [ + "cm-1" + ], + "group_unique_id": [ + "cm-1" + ], + "group_unique_name": [ + "cm-1" + ], + "groups_no_zero_gid_except_root": [ + "cm-1" + ], + "grub2_audit_argument": [ + "au-12" + ], + "grub2_audit_backlog_limit_argument": [ + "au-2" + ], + "grub2_enable_selinux": [ + "ac-3" + ], + "grub2_password": [ + "ac-3" + ], + "grub2_uefi_password": [ + "ac-3" + ], + "has_nonlocal_mta": [ + "cm-7" + ], + "journald_compress": [ + "au-4" + ], + "journald_disable_forward_to_syslog": [ + "au-2" + ], + "journald_storage": [ + "au-3" + ], + "kernel_module_atm_disabled": [ + "cm-7" + ], + "kernel_module_can_disabled": [ + "cm-7" + ], + "kernel_module_cramfs_disabled": [ + "cm-7" + ], + "kernel_module_dccp_disabled": [ + "cm-7", + "si-4" + ], + "kernel_module_firewire-core_disabled": [ + "cm-7" + ], + "kernel_module_freevxfs_disabled": [ + "cm-7" + ], + "kernel_module_hfs_disabled": [ + "cm-7" + ], + "kernel_module_hfsplus_disabled": [ + "cm-7" + ], + "kernel_module_jffs2_disabled": [ + "cm-7" + ], + "kernel_module_overlayfs_disabled": [ + "cm-7" + ], + "kernel_module_rds_disabled": [ + "cm-7", + "si-4" + ], + "kernel_module_sctp_disabled": [ + "cm-7", + "si-4" + ], + "kernel_module_squashfs_disabled": [ + "cm-7" + ], + "kernel_module_tipc_disabled": [ + "cm-7", + "si-4" + ], + "kernel_module_udf_disabled": [ + "cm-7" + ], + "kernel_module_usb-storage_disabled": [ + "ia-3", + "si-3" + ], + "mount_option_dev_shm_nodev": [ + "ac-3", + "cm-7" + ], + "mount_option_dev_shm_noexec": [ + "ac-3", + "cm-7" + ], + "mount_option_dev_shm_nosuid": [ + "ac-3", + "cm-7" + ], + "mount_option_home_nodev": [ + "ac-3" + ], + "mount_option_home_nosuid": [ + "ac-3" + ], + "mount_option_tmp_nodev": [ + "cm-7" + ], + "mount_option_tmp_noexec": [ + "ac-3", + "cm-7" + ], + "mount_option_tmp_nosuid": [ + "ac-3", + "cm-7" + ], + "mount_option_var_log_audit_nodev": [ + "ac-3" + ], + "mount_option_var_log_audit_noexec": [ + "ac-3" + ], + "mount_option_var_log_audit_nosuid": [ + "ac-3" + ], + "mount_option_var_log_nodev": [ + "ac-3" + ], + "mount_option_var_log_noexec": [ + "ac-3" + ], + "mount_option_var_log_nosuid": [ + "ac-3" + ], + "mount_option_var_nodev": [ + "ac-3" + ], + "mount_option_var_nosuid": [ + "ac-3" + ], + "mount_option_var_tmp_nodev": [ + "ac-3" + ], + "mount_option_var_tmp_noexec": [ + "ac-3" + ], + "mount_option_var_tmp_nosuid": [ + "ac-3" + ], + "no_dirs_unowned_by_root": [ + "cm-1" + ], + "no_empty_passwords": [ + "cm-6" + ], + "no_empty_passwords_etc_shadow": [ + "cm-6", + "ia-5" + ], + "no_files_or_dirs_ungroupowned": [ + "cm-6" + ], + "no_files_or_dirs_unowned_by_user": [ + "cm-6" + ], + "no_files_unowned_by_user": [ + "ac-3" + ], + "no_forward_files": [ + "cm-1" + ], + "no_invalid_shell_accounts_unlocked": [ + "ac-2.5" + ], + "no_netrc_files": [ + "cm-1" + ], + "no_nologin_in_shells": [ + "cm-1" + ], + "no_password_auth_for_systemaccounts": [ + "ac-2.5" + ], + "no_rhost_files": [ + "cm-1" + ], + "no_rsh_trust_files": [ + "cm-1" + ], + "no_shelllogin_for_systemaccounts": [ + "ac-2.5" + ], + "package_aide_installed": [ + "au-2" + ], + "package_audit-libs_installed": [ + "au-2" + ], + "package_audit_installed": [ + "au-2" + ], + "package_bind_removed": [ + "cm-7" + ], + "package_chrony_installed": [ + "au-3" + ], + "package_cron_installed": [ + "cm-1" + ], + "package_cyrus-imapd_removed": [ + "cm-7" + ], + "package_dhcp_removed": [ + "cm-7" + ], + "package_dovecot_removed": [ + "cm-7" + ], + "package_firewalld_installed": [ + "ca-9" + ], + "package_ftp_removed": [ + "cm-7" + ], + "package_httpd_removed": [ + "cm-7" + ], + "package_kea_removed": [ + "cm-7" + ], + "package_libselinux_installed": [ + "ac-3" + ], + "package_mcstrans_removed": [ + "ac-3" + ], + "package_net-snmp_removed": [ + "cm-7" + ], + "package_nftables_installed": [ + "ca-9" + ], + "package_nginx_removed": [ + "cm-7" + ], + "package_openldap-clients_removed": [ + "cm-7" + ], + "package_pam_pwquality_installed": [ + "cm-6" + ], + "package_rsync_removed": [ + "cm-6" + ], + "package_rsyslog_installed": [ + "cm-6" + ], + "package_samba_removed": [ + "cm-6" + ], + "package_setroubleshoot_removed": [ + "ac-3" + ], + "package_squid_removed": [ + "cm-6" + ], + "package_sudo_installed": [ + "ac-6.2" + ], + "package_systemd-journal-remote_installed": [ + "au-2" + ], + "package_telnet-server_removed": [ + "cm-7" + ], + "package_telnet_removed": [ + "cm-7" + ], + "package_tftp-server_removed": [ + "cm-7" + ], + "package_tftp_removed": [ + "cm-7" + ], + "package_vsftpd_removed": [ + "cm-7" + ], + "package_xinetd_removed": [ + "cm-7" + ], + "package_xorg-x11-server-Xwayland_removed": [ + "cm-11" + ], + "package_xorg-x11-server-common_removed": [ + "cm-11" + ], + "package_ypbind_removed": [ + "cm-7" + ], + "package_ypserv_removed": [ + "cm-7" + ], + "partition_for_dev_shm": [ + "cm-7" + ], + "partition_for_home": [ + "cm-7" + ], + "partition_for_tmp": [ + "cm-6", + "cm-7" + ], + "partition_for_var": [ + "cm-7" + ], + "partition_for_var_log": [ + "cm-6", + "cm-7" + ], + "partition_for_var_log_audit": [ + "cm-7" + ], + "partition_for_var_tmp": [ + "cm-7" + ], + "postfix_network_listening_disabled": [ + "cm-7" + ], + "root_path_all_dirs": [ + "cm-1" + ], + "root_path_no_dot": [ + "cm-1" + ], + "rsyslog_filecreatemode": [ + "ac-3" + ], + "rsyslog_files_groupownership": [ + "ac-3" + ], + "rsyslog_files_ownership": [ + "ac-3" + ], + "rsyslog_files_permissions": [ + "ac-3" + ], + "rsyslog_nolisten": [ + "au-2" + ], + "selinux_not_disabled": [ + "ac-3", + "sc-3" + ], + "selinux_policytype": [ + "ac-3" + ], + "selinux_state": [ + "sc-3" + ], + "service_auditd_enabled": [ + "au-12", + "au-2" + ], + "service_autofs_disabled": [ + "si-3" + ], + "service_avahi-daemon_disabled": [ + "si-4" + ], + "service_bluetooth_disabled": [ + "cm-7" + ], + "service_cockpit_disabled": [ + "cm-7" + ], + "service_crond_enabled": [ + "cm-1" + ], + "service_cups_disabled": [ + "cm-7" + ], + "service_dnsmasq_disabled": [ + "cm-7" + ], + "service_nfs_disabled": [ + "cm-6" + ], + "service_rpcbind_disabled": [ + "cm-6" + ], + "service_rsyslog_enabled": [ + "au-2" + ], + "service_systemd-journal-upload_enabled": [ + "au-2" + ], + "service_systemd-journald_enabled": [ + "au-2", + "sc-24" + ], + "set_password_hashing_algorithm_libuserconf": [ + "ia-5" + ], + "set_password_hashing_algorithm_logindefs": [ + "ia-5" + ], + "set_password_hashing_algorithm_passwordauth": [ + "ia-5" + ], + "set_password_hashing_algorithm_systemauth": [ + "ia-5" + ], + "socket_systemd-journal-remote_disabled": [ + "au-2" + ], + "sshd_disable_empty_passwords": [ + "cm-1" + ], + "sshd_disable_forwarding": [ + "cm-7" + ], + "sshd_disable_gssapi_auth": [ + "cm-1", + "cm-6" + ], + "sshd_disable_rhosts": [ + "cm-1" + ], + "sshd_disable_root_login": [ + "ac-6" + ], + "sshd_do_not_permit_user_env": [ + "cm-1" + ], + "sshd_enable_pam": [ + "cm-1" + ], + "sshd_enable_warning_banner_net": [ + "cm-1" + ], + "sshd_limit_user_access": [ + "ac-3" + ], + "sshd_set_idle_timeout": [ + "cm-1" + ], + "sshd_set_keepalive": [ + "cm-1" + ], + "sshd_set_login_grace_time": [ + "cm-6" + ], + "sshd_set_loglevel_verbose": [ + "au-3" + ], + "sshd_set_max_auth_tries": [ + "au-3" + ], + "sshd_set_max_sessions": [ + "cm-1" + ], + "sshd_set_maxstartups": [ + "cm-1" + ], + "sudo_add_use_pty": [ + "ac-6" + ], + "sudo_custom_logfile": [ + "au-3" + ], + "sudo_remove_no_authenticate": [ + "ac-6" + ], + "sudo_remove_nopasswd": [ + "ac-6" + ], + "sudo_require_reauthentication": [ + "ia-11" + ], + "sysctl_fs_protected_hardlinks": [ + "ac-3" + ], + "sysctl_fs_protected_symlinks": [ + "ac-3" + ], + "sysctl_kernel_dmesg_restrict": [ + "sc-2" + ], + "sysctl_kernel_kptr_restrict": [ + "cm-6" + ], + "sysctl_kernel_randomize_va_space": [ + "cm-6", + "si-16" + ], + "sysctl_kernel_yama_ptrace_scope": [ + "cm-6" + ], + "sysctl_net_ipv4_conf_all_accept_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_accept_source_route": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_forwarding": [ + "cm-6" + ], + "sysctl_net_ipv4_conf_all_log_martians": [ + "au-3", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_rp_filter": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_secure_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_send_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_accept_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_accept_source_route": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_forwarding": [ + "cm-6" + ], + "sysctl_net_ipv4_conf_default_log_martians": [ + "au-3", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_rp_filter": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_secure_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_send_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_icmp_echo_ignore_broadcasts": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_icmp_ignore_bogus_error_responses": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_ip_forward": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_tcp_syncookies": [ + "cm-1", + "sc-5" + ], + "sysctl_net_ipv6_conf_all_accept_ra": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_all_accept_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_all_accept_source_route": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_all_forwarding": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_accept_ra": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_accept_redirects": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_accept_source_route": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_forwarding": [ + "cm-6" + ], + "use_pam_wheel_group_for_su": [ + "ac-3" + ], + "wireless_disable_interfaces": [ + "ac-18", + "cm-7" + ], + "xwindows_runlevel_target": [ + "cm-11" + ] + }, + "variables": { + "cis_banner_text=cis": [ + "cm-6" + ], + "dconf_login_banner_contents=cis_default": [ + "ac-8" + ], + "dconf_login_banner_text=cis_banners": [ + "ac-8" + ], + "inactivity_timeout_value=15_minutes": [ + "ac-11" + ], + "sshd_idle_timeout_value=5_minutes": [ + "cm-1" + ], + "sshd_max_auth_tries_value=4": [ + "au-3" + ], + "sysctl_net_ipv4_conf_all_accept_redirects_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_accept_source_route_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_log_martians_value=enabled": [ + "au-3", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_rp_filter_value=enabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_all_secure_redirects_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_accept_redirects_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_accept_source_route_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_forwarding_value=disabled": [ + "cm-6" + ], + "sysctl_net_ipv4_conf_default_log_martians_value=enabled": [ + "au-3", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_rp_filter_value=enabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_conf_default_secure_redirects_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_icmp_echo_ignore_broadcasts_value=enabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_icmp_ignore_bogus_error_responses_value=enabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv4_tcp_syncookies_value=enabled": [ + "cm-1", + "sc-5" + ], + "sysctl_net_ipv6_conf_all_accept_ra_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_all_accept_redirects_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_all_accept_source_route_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_all_forwarding_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_accept_ra_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_accept_redirects_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_accept_source_route_value=disabled": [ + "cm-1", + "cm-6" + ], + "sysctl_net_ipv6_conf_default_forwarding_value=disabled": [ + "cm-6" + ], + "var_accounts_maximum_age_login_defs=365": [ + "cm-1" + ], + "var_accounts_minimum_age_login_defs=1": [ + "ia-5" + ], + "var_accounts_passwords_pam_faillock_dir=run": [ + "au-12", + "au-3" + ], + "var_accounts_user_umask=027": [ + "ac-3", + "cm-6" + ], + "var_audit_backlog_limit=8192": [ + "au-2" + ], + "var_auditd_action_mail_acct=root": [ + "au-2" + ], + "var_auditd_admin_space_left_action=cis_rhel10": [ + "au-2" + ], + "var_auditd_admin_space_left_action=cis_rhel8": [ + "au-2" + ], + "var_auditd_admin_space_left_action=cis_rhel9": [ + "au-2" + ], + "var_auditd_disk_error_action=cis_rhel10": [ + "au-5" + ], + "var_auditd_disk_error_action=cis_rhel8": [ + "au-5" + ], + "var_auditd_disk_error_action=cis_rhel9": [ + "au-2" + ], + "var_auditd_disk_full_action=cis_rhel10": [ + "au-5" + ], + "var_auditd_disk_full_action=cis_rhel8": [ + "au-5" + ], + "var_auditd_disk_full_action=cis_rhel9": [ + "au-2" + ], + "var_auditd_max_log_file=6": [ + "au-8" + ], + "var_auditd_max_log_file=8": [ + "au-8" + ], + "var_auditd_max_log_file_action=keep_logs": [ + "au-8" + ], + "var_auditd_space_left_action=cis_rhel10": [ + "au-2" + ], + "var_auditd_space_left_action=cis_rhel8": [ + "au-2" + ], + "var_auditd_space_left_action=cis_rhel9": [ + "au-2" + ], + "var_multiple_time_servers=rhel": [ + "au-3" + ], + "var_pam_wheel_group_for_su=cis": [ + "ac-3" + ], + "var_password_hashing_algorithm=SHA512": [ + "ia-5" + ], + "var_password_hashing_algorithm=cis_rhel10": [ + "ia-5" + ], + "var_password_hashing_algorithm=cis_rhel8": [ + "ia-5" + ], + "var_password_hashing_algorithm_pam=cis_rhel10": [ + "ia-5" + ], + "var_password_hashing_algorithm_pam=cis_rhel8": [ + "ia-5" + ], + "var_password_hashing_algorithm_pam=sha512": [ + "ia-5" + ], + "var_password_pam_dictcheck=1": [ + "ia-5" + ], + "var_password_pam_difok=2": [ + "ia-5" + ], + "var_password_pam_maxrepeat=3": [ + "ia-5" + ], + "var_password_pam_maxsequence=3": [ + "ia-5" + ], + "var_password_pam_minclass=4": [ + "ia-5" + ], + "var_password_pam_minlen=14": [ + "ia-5" + ], + "var_password_pam_remember=24": [ + "ia-5.1" + ], + "var_password_pam_remember_control_flag=requisite_or_required": [ + "ia-5.1" + ], + "var_postfix_inet_interfaces=loopback-only": [ + "cm-7" + ], + "var_screensaver_lock_delay=5_seconds": [ + "ac-11" + ], + "var_selinux_policy_name=targeted": [ + "ac-3" + ], + "var_selinux_state=enforcing": [ + "sc-3" + ], + "var_sshd_max_sessions=10": [ + "cm-1" + ], + "var_sshd_set_keepalive=1": [ + "cm-1" + ], + "var_sshd_set_login_grace_time=60": [ + "cm-6" + ], + "var_sshd_set_maxstartups=10:30:60": [ + "cm-1" + ], + "var_sudo_timestamp_timeout=15_minutes": [ + "ia-11" + ], + "var_user_initialization_files_regex=all_dotfiles": [ + "cm-1" + ] + } +} diff --git a/utils/nist_sync/download_oscal.py b/utils/nist_sync/download_oscal.py new file mode 100755 index 000000000000..2f0cf6268ad7 --- /dev/null +++ b/utils/nist_sync/download_oscal.py @@ -0,0 +1,70 @@ +#!/usr/bin/env python3 +""" +Download NIST OSCAL catalog and baseline profiles. +Downloads the official NIST SP 800-53 Rev 5 catalog in JSON format. +""" + +import json +import os +import sys +from pathlib import Path +import requests + +# NIST OSCAL official repository URLs +OSCAL_CATALOG_URL = "https://raw.githubusercontent.com/usnistgov/oscal-content/main/nist.gov/SP800-53/rev5/json/NIST_SP-800-53_rev5_catalog.json" +OSCAL_LOW_BASELINE_URL = "https://raw.githubusercontent.com/usnistgov/oscal-content/main/nist.gov/SP800-53/rev5/json/NIST_SP-800-53_rev5_LOW-baseline_profile.json" +OSCAL_MODERATE_BASELINE_URL = "https://raw.githubusercontent.com/usnistgov/oscal-content/main/nist.gov/SP800-53/rev5/json/NIST_SP-800-53_rev5_MODERATE-baseline_profile.json" +OSCAL_HIGH_BASELINE_URL = "https://raw.githubusercontent.com/usnistgov/oscal-content/main/nist.gov/SP800-53/rev5/json/NIST_SP-800-53_rev5_HIGH-baseline_profile.json" + + +def download_file(url: str, output_path: Path) -> bool: + """Download a file from URL to output path.""" + try: + print(f"Downloading {url}...") + response = requests.get(url, timeout=30) + response.raise_for_status() + + # Validate JSON + data = response.json() + + # Write to file + output_path.parent.mkdir(parents=True, exist_ok=True) + with open(output_path, 'w', encoding='utf-8') as f: + json.dump(data, f, indent=2) + + print(f" ✓ Saved to {output_path}") + return True + except Exception as e: + print(f" ✗ Failed: {e}", file=sys.stderr) + return False + + +def main(): + """Download all NIST OSCAL files.""" + script_dir = Path(__file__).parent + data_dir = script_dir / "data" + + downloads = [ + (OSCAL_CATALOG_URL, data_dir / "nist_800_53_rev5_catalog.json"), + (OSCAL_LOW_BASELINE_URL, data_dir / "nist_800_53_rev5_low_baseline.json"), + (OSCAL_MODERATE_BASELINE_URL, data_dir / "nist_800_53_rev5_moderate_baseline.json"), + (OSCAL_HIGH_BASELINE_URL, data_dir / "nist_800_53_rev5_high_baseline.json"), + ] + + success_count = 0 + for url, path in downloads: + if download_file(url, path): + success_count += 1 + + print(f"\nDownloaded {success_count}/{len(downloads)} files successfully") + + if success_count == len(downloads): + print("\n✓ All NIST OSCAL files downloaded successfully!") + return 0 + else: + print("\n✗ Some downloads failed. Please check errors above.", file=sys.stderr) + return 1 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/utils/nist_sync/generate_cis_nist_workflow.sh b/utils/nist_sync/generate_cis_nist_workflow.sh new file mode 100755 index 000000000000..bc2c89125cfd --- /dev/null +++ b/utils/nist_sync/generate_cis_nist_workflow.sh @@ -0,0 +1,492 @@ +#!/bin/bash +# +# CIS-NIST Workflow - Complete Generation and Validation +# +# This script runs the complete workflow to generate CIS-NIST control files and profiles. +# +# Steps: +# 1. Harvest CIS→NIST mappings from benchmark PDFs +# 2. Generate unified NIST 800-53 control file from OSCAL + CIS mappings +# 3. Apply product family guards to control file +# 4. Generate CIS-NIST profiles for each RHEL version +# 5. Build products to validate +# 6. Compare CIS vs CIS-NIST profiles to ensure they match +# 7. Generate HTML tables from control file + +set -e # Exit on error + +SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" +REPO_ROOT="$SCRIPT_DIR/../.." +cd "$SCRIPT_DIR" + +# Colors for output +RED='\033[0;31m' +GREEN='\033[0;32m' +YELLOW='\033[1;33m' +BLUE='\033[0;34m' +CYAN='\033[0;36m' +NC='\033[0m' # No Color + +log_info() { + echo -e "${BLUE}▶${NC} $1" +} + +log_success() { + echo -e "${GREEN}✓${NC} $1" +} + +log_warning() { + echo -e "${YELLOW}!${NC} $1" +} + +log_error() { + echo -e "${RED}✗${NC} $1" +} + +log_section() { + echo "" + echo -e "${CYAN}═══════════════════════════════════════════════════════════${NC}" + echo -e "${CYAN} $1${NC}" + echo -e "${CYAN}═══════════════════════════════════════════════════════════${NC}" + echo "" +} + +# Parse command line arguments +SKIP_BUILD=false +SKIP_COMPARISON=false +SKIP_HARVEST=true # Skip by default, only harvest when explicitly requested +PRODUCTS="rhel8 rhel9 rhel10" + +while [[ $# -gt 0 ]]; do + case $1 in + --skip-build) + SKIP_BUILD=true + shift + ;; + --skip-comparison) + SKIP_COMPARISON=true + shift + ;; + --harvest) + SKIP_HARVEST=false + shift + ;; + --products) + PRODUCTS="$2" + shift 2 + ;; + --help|-h) + cat << EOF +CIS-NIST Workflow - Complete Generation and Validation + +Usage: ./generate_cis_nist_workflow.sh [OPTIONS] + +Options: + --harvest Harvest CIS→NIST mappings from PDFs (slow, only needed when PDFs change) + --skip-build Skip building products (use existing builds) + --skip-comparison Skip profile comparison step + --products "..." Specify products to process (default: "rhel8 rhel9 rhel10") + --help, -h Show this help message + +Example: + ./generate_cis_nist_workflow.sh + ./generate_cis_nist_workflow.sh --harvest # Update CIS→NIST mappings from PDFs + ./generate_cis_nist_workflow.sh --skip-build + ./generate_cis_nist_workflow.sh --products "rhel9" + +Output: + - shared/references/controls/nist_800_53_cis_reference_{product}.yml (per-product reference) + - shared/references/controls/nist_800_53_cis_reference_{product}/*.yml (family files, NO guards) + - products/rhel8/profiles/cis_nist.profile + - products/rhel9/profiles/cis_nist.profile + - products/rhel10/profiles/cis_nist.profile + - Comparison reports showing CIS == CIS-NIST for each product + +EOF + exit 0 + ;; + *) + log_error "Unknown option: $1" + echo "Use --help for usage information" + exit 1 + ;; + esac +done + +# Check dependencies +if ! command -v python3 &> /dev/null; then + log_error "Python 3 is required but not found. Please install Python 3.8 or later." + exit 1 +fi + +# Check for required Python packages +MISSING_DEPS=() +for pkg in ruamel.yaml PyPDF2; do + if ! python3 -c "import ${pkg%.*}" 2>/dev/null; then + MISSING_DEPS+=("$pkg") + fi +done + +if [ ${#MISSING_DEPS[@]} -gt 0 ]; then + log_error "Missing Python packages: ${MISSING_DEPS[*]}" + log_info "Install with: pip install ${MISSING_DEPS[*]}" + exit 1 +fi + +echo "" +echo "╔════════════════════════════════════════════════════════════╗" +echo "║ CIS-NIST Workflow - Complete Generation ║" +echo "╚════════════════════════════════════════════════════════════╝" +echo "" +# Step 0: Download OSCAL catalog +log_section "Step 0: Ensuring OSCAL Catalog is Available" + +OSCAL_CATALOG="$SCRIPT_DIR/data/nist_800_53_rev5_catalog.json" +if [ -f "$OSCAL_CATALOG" ]; then + log_info "OSCAL catalog already exists: data/nist_800_53_rev5_catalog.json" +else + log_info "Downloading OSCAL catalog..." + if python3 download_oscal.py; then + log_success "OSCAL catalog downloaded" + log_info "Catalog: data/nist_800_53_rev5_catalog.json" + else + log_error "Failed to download OSCAL catalog" + exit 1 + fi +fi + + + +# Step 1: Harvest CIS→NIST mappings (optional) +if [ "$SKIP_HARVEST" = false ]; then + log_section "Step 1: Harvesting CIS→NIST Mappings" + log_info "Parsing CIS benchmark PDFs to extract NIST references..." + if python3 harvest_cis_nist_mappings.py; then + log_success "CIS→NIST mappings harvested" + log_info "Mapping cache: data/cis_nist_mappings.json" + else + log_error "Failed to harvest CIS→NIST mappings" + exit 1 + fi +else + log_section "Step 1: Using Existing CIS→NIST Mappings" + + # Check if mapping file exists + MAPPING_FILE="$SCRIPT_DIR/data/cis_nist_mappings.json" + if [ ! -f "$MAPPING_FILE" ]; then + log_error "CIS→NIST mapping file not found: $MAPPING_FILE" + log_error "Run with --harvest to generate it from CIS benchmark PDFs" + exit 1 + fi + + log_info "Using existing mapping cache: data/cis_nist_mappings.json" + log_warning "To update mappings from PDFs, run with --harvest flag" +fi + +# Step 2: Generate product-specific CIS reference files in split-by-family format +log_section "Step 2: Generating Product-Specific NIST 800-53 CIS Reference Files" + +# Delete existing reference files (old global and product-specific) +log_info "Removing old reference files..." +rm -rf "$REPO_ROOT/shared/references/controls/nist_800_53_cis_reference" +rm -f "$REPO_ROOT/shared/references/controls/nist_800_53_cis_reference.yml" +for product in $PRODUCTS; do + rm -rf "$REPO_ROOT/shared/references/controls/nist_800_53_cis_reference_${product}" + rm -f "$REPO_ROOT/shared/references/controls/nist_800_53_cis_reference_${product}.yml" +done + +# Generate product-specific reference files (NO guards, product-filtered) +for product in $PRODUCTS; do + log_info "Generating CIS reference files for $product (split by family, no guards)..." + if python3 sync_nist_split.py --product "$product"; then + log_success "$product: CIS reference files generated" + log_info " → shared/references/controls/nist_800_53_cis_reference_${product}.yml" + log_info " → shared/references/controls/nist_800_53_cis_reference_${product}/*.yml" + else + log_error "$product: Failed to generate CIS reference files" + exit 1 + fi +done + +# Step 3: Compare product-specific CIS references with previous versions +log_section "Step 3: Comparing Product-Specific CIS Reference Changes" +for product in $PRODUCTS; do + REF_FILE="$REPO_ROOT/shared/references/controls/nist_800_53_cis_reference_${product}.yml" + if [ -f "$REF_FILE" ]; then + if git diff --quiet HEAD -- "$REF_FILE" 2>/dev/null; then + log_info "$product: No changes in CIS reference file" + else + log_warning "$product: CIS reference file has changes!" + log_info " Review diff: git diff shared/references/controls/nist_800_53_cis_reference_${product}.yml" + fi + else + log_info "$product: First time generating CIS reference file" + fi +done + +# Step 4: Generate CIS-NIST profiles +log_section "Step 4: Generating CIS-NIST Profiles" +for product in $PRODUCTS; do + log_info "Generating CIS-NIST profile for $product..." + if python3 generate_nist_based_cis_profile.py --product "$product"; then + log_success "$product: CIS-NIST profile generated" + log_info " → products/$product/profiles/cis_nist.profile" + else + log_error "$product: Failed to generate CIS-NIST profile" + exit 1 + fi +done + +# Step 5: Build products (optional) +if [ "$SKIP_BUILD" = false ]; then + log_section "Step 5: Building Products" + cd "$REPO_ROOT" + + log_info "Building products: $PRODUCTS" + + # Run build for all products at once and capture output + BUILD_LOG=$(mktemp) + if ./build_product $PRODUCTS --datastream-only > "$BUILD_LOG" 2>&1; then + # Check if all datastreams were generated + ALL_BUILT=true + for product in $PRODUCTS; do + if [ -f "build/ssg-$product-ds.xml" ]; then + log_success "$product: Build complete" + else + log_error "$product: Datastream not generated" + ALL_BUILT=false + fi + done + + if [ "$ALL_BUILT" = false ]; then + echo "Last 30 lines of build log:" + tail -30 "$BUILD_LOG" + rm -f "$BUILD_LOG" + exit 1 + fi + else + log_error "Build failed" + echo "Last 50 lines of build log:" + tail -50 "$BUILD_LOG" + rm -f "$BUILD_LOG" + exit 1 + fi + rm -f "$BUILD_LOG" + # Render policies for all products + log_info "Rendering policies..." + cd build + if ninja render-policies; then + log_success "Policies rendered" + log_info "Rendered policies:" + for product in $PRODUCTS; do + if [ -f "$product/rendered-policies/nist_800_53.html" ]; then + echo " - build/$product/rendered-policies/nist_800_53.html" + fi + done + else + log_warning "Failed to render policies (non-fatal)" + fi + cd "$REPO_ROOT" + + cd "$SCRIPT_DIR" +else + log_section "Step 5: Skipping Build (--skip-build)" + log_warning "Using existing builds for validation" +fi + +# Step 6: Compare CIS vs CIS-NIST profiles +if [ "$SKIP_COMPARISON" = false ]; then + log_section "Step 6: Comparing CIS vs CIS-NIST Profiles" + + ALL_MATCH=true + for product in $PRODUCTS; do + log_info "Comparing profiles for $product..." + + cd "$REPO_ROOT" + + # Set up PYTHONPATH for profile_tool.py + export PYTHONPATH="$REPO_ROOT:${PYTHONPATH:-}" + + # Profile paths (source .profile files in build/ directory) + CIS_PROFILE="build/$product/profiles/cis.profile" + CIS_NIST_PROFILE="build/$product/profiles/cis_nist.profile" + BUILD_CONFIG="build/build_config.yml" + + # Debug: Show paths being checked + echo " Debug: CIS profile path: $CIS_PROFILE" + echo " Debug: CIS-NIST profile path: $CIS_NIST_PROFILE" + + # Check if profiles exist + if [ ! -f "$CIS_PROFILE" ]; then + log_error "$product: CIS profile not found: $CIS_PROFILE" + echo " Debug: Directory contents:" + ls -la "build/$product/profiles/" 2>&1 | head -10 || echo " Directory does not exist" + ALL_MATCH=false + continue + fi + if [ ! -f "$CIS_NIST_PROFILE" ]; then + log_error "$product: CIS-NIST profile not found: $CIS_NIST_PROFILE" + echo " Debug: Directory contents:" + ls -la "build/$product/profiles/" 2>&1 | head -10 || echo " Directory does not exist" + ALL_MATCH=false + continue + fi + + echo " Debug: Both profiles found" + + # Calculate actual rule counts (total selections in profile) + CIS_COUNT=$(grep -E '^[[:space:]]*-[[:space:]]' "$CIS_PROFILE" | grep -v '^[[:space:]]*-[[:space:]]*!' | wc -l) + CIS_NIST_COUNT=$(grep -E '^[[:space:]]*-[[:space:]]' "$CIS_NIST_PROFILE" | grep -v '^[[:space:]]*-[[:space:]]*!' | wc -l) + + echo " CIS: ~$CIS_COUNT selections" + echo " CIS-NIST: ~$CIS_NIST_COUNT selections" + + # Do bidirectional subtraction to ensure they're identical + # Check for "Subtraction would produce an empty profile" message + echo " Debug: Running profile_tool.py sub (CIS - CIS_NIST)..." + DIFF_A_OUTPUT=$(python3 build-scripts/profile_tool.py sub \ + --profile1 "$CIS_PROFILE" \ + --profile2 "$CIS_NIST_PROFILE" \ + --build-config-yaml "$BUILD_CONFIG" \ + --ssg-root . \ + --product "$product" 2>&1) + DIFF_A_EXIT=$? + echo " Debug: Exit code: $DIFF_A_EXIT" + + echo " Debug: Running profile_tool.py sub (CIS_NIST - CIS)..." + DIFF_B_OUTPUT=$(python3 build-scripts/profile_tool.py sub \ + --profile1 "$CIS_NIST_PROFILE" \ + --profile2 "$CIS_PROFILE" \ + --build-config-yaml "$BUILD_CONFIG" \ + --ssg-root . \ + --product "$product" 2>&1) + DIFF_B_EXIT=$? + echo " Debug: Exit code: $DIFF_B_EXIT" + + # Check if CIS - CIS_NIST produces empty profile + # This is the CRITICAL check: CIS_NIST must have ALL CIS rules + MISSING_FROM_CIS_NIST=false + + if echo "$DIFF_A_OUTPUT" | grep -q "Subtraction would produce an empty profile"; then + echo " ✓ CIS - CIS_NIST = empty (CIS_NIST has all CIS rules)" + else + echo " ✗ CIS - CIS_NIST has differences (CIS_NIST is missing CIS rules!)" + echo " Debug: First 10 lines of output:" + echo "$DIFF_A_OUTPUT" | head -10 + MISSING_FROM_CIS_NIST=true + fi + + # Check if CIS_NIST - CIS produces empty profile + # This is INFORMATIONAL only: extras are allowed (unmapped items, human edits, cross-product rules) + if echo "$DIFF_B_OUTPUT" | grep -q "Subtraction would produce an empty profile"; then + echo " ✓ CIS_NIST - CIS = empty (exact match)" + else + echo " ℹ CIS_NIST - CIS has differences (extras are OK: unmapped items, human edits, cross-product rules)" + echo " Debug: First 10 lines of output:" + echo "$DIFF_B_OUTPUT" | head -10 + fi + + if [ "$MISSING_FROM_CIS_NIST" = false ]; then + log_success "$product: CIS_NIST has all required CIS rules ✓" + else + log_error "$product: CIS_NIST is missing CIS rules!" + echo "" + echo " ✗ CRITICAL: Rules in CIS but NOT in CIS_NIST:" + echo "$DIFF_A_OUTPUT" + echo "" + echo " This means CIS_NIST profile is missing required CIS coverage!" + echo " Check controls/nist_800_53/*.yml files for missing rules." + + ALL_MATCH=false + fi + + cd "$SCRIPT_DIR" + done + + echo "" + if [ "$ALL_MATCH" = true ]; then + log_success "All profiles match! ✓" + else + log_error "Some profiles don't match. Please review the differences." + # exit 1 + fi +else + log_section "Step 6: Skipping Comparison (--skip-comparison)" +fi + +# Step 7: File Status +log_section "Step 7: File Status" +log_info "Product-Specific Reference Files (auto-generated, for comparison):" +for product in $PRODUCTS; do + log_info " $product:" + log_info " - shared/references/controls/nist_800_53_cis_reference_${product}.yml" + log_info " - shared/references/controls/nist_800_53_cis_reference_${product}/*.yml" +done +log_info "" +log_info "Product-Specific Real Files (used in builds, human-editable):" +for product in $PRODUCTS; do + log_info " $product:" + log_info " - products/$product/controls/nist_800_53.yml" + log_info " - products/$product/controls/nist_800_53/*.yml" +done + +# Step 8: Summary +log_section "Summary" +echo "Generated artifacts:" +echo "" +echo " Product-Specific CIS Reference Files (auto-generated, for comparison):" +for product in $PRODUCTS; do + echo " $product:" + echo " - shared/references/controls/nist_800_53_cis_reference_${product}.yml (metadata)" + echo " - shared/references/controls/nist_800_53_cis_reference_${product}/*.yml (21 family files, NO guards)" +done +echo "" +echo " Product-Specific Real Control Files (used in builds, human-maintained):" +for product in $PRODUCTS; do + echo " $product:" + echo " - products/$product/controls/nist_800_53.yml (metadata)" + echo " - products/$product/controls/nist_800_53/*.yml (21 family files, NO guards)" +done +echo "" +echo " Mapping Cache:" +echo " - utils/nist_sync/data/cis_nist_mappings.json" +echo "" +echo " Profiles:" +for product in $PRODUCTS; do + echo " - products/$product/profiles/cis_nist.profile" +done +echo "" + +if [ "$SKIP_BUILD" = false ]; then + echo " Built Artifacts:" + for product in $PRODUCTS; do + echo " - build/ssg-$product-ds.xml" + done + echo "" + echo " Rendered Policies:" + for product in $PRODUCTS; do + if [ -f "build/$product/rendered-policies/nist_800_53.html" ]; then + echo " - build/$product/rendered-policies/nist_800_53.html" + fi + done + echo "" +fi + +log_success "Workflow complete! ✓" +echo "" +log_info "Next steps:" +echo " - Review CIS reference changes for each product:" +for product in $PRODUCTS; do + echo " git diff shared/references/controls/nist_800_53_cis_reference_${product}.yml" +done +echo " - Copy reference files to product control directories if needed:" +for product in $PRODUCTS; do + echo " cp -r shared/references/controls/nist_800_53_cis_reference_${product}* products/$product/controls/" +done +echo " - Review profiles: git diff products/*/profiles/cis_nist.profile" +echo " - Commit changes: git add shared/references/controls/ products/ utils/nist_sync/data/" +echo "" +echo "ℹ️ NOTE: Product-specific reference files show what CIS currently maps to NIST for each product." +echo " NO Jinja2 guards - rules are already filtered by product." +echo " OSCAL metadata (description, parameters, guidance) NOT included - retrieve from OSCAL catalog when needed." +echo "" diff --git a/utils/nist_sync/generate_nist_based_cis_profile.py b/utils/nist_sync/generate_nist_based_cis_profile.py new file mode 100755 index 000000000000..c02c5ab765f5 --- /dev/null +++ b/utils/nist_sync/generate_nist_based_cis_profile.py @@ -0,0 +1,175 @@ +#!/usr/bin/env python3 +""" +Generate a CIS-NIST profile based on the NIST 800-53 control file. + +This script copies the existing CIS profile and changes the control file +reference from cis_rhelX:all to nist_800_53:all, while keeping all other +selections (exclusions, variable overrides, etc.) intact. + +Usage: + ./generate_nist_based_cis_profile.py --product rhel9 +""" + +import sys +from pathlib import Path +from typing import Dict, List +import argparse +import re + +try: + from ruamel.yaml import YAML +except ImportError: + print("Error: ruamel.yaml is required. Install it with:", file=sys.stderr) + print(" pip install ruamel.yaml", file=sys.stderr) + sys.exit(1) + + +class NISTBasedCISProfileGenerator: + """Generates NIST-based CIS profiles.""" + + def __init__(self, repo_root: Path): + self.repo_root = repo_root + self.yaml = YAML() + self.yaml.preserve_quotes = True + self.yaml.default_flow_style = False + self.yaml.indent(mapping=2, sequence=4, offset=2) + self.yaml.width = 4096 + + def load_cis_profile(self, product: str) -> Dict: + """Load the existing CIS profile for a product.""" + cis_profile = self.repo_root / "products" / product / "profiles" / "cis.profile" + + if not cis_profile.exists(): + print(f"Error: CIS profile not found at {cis_profile}", file=sys.stderr) + sys.exit(1) + + with open(cis_profile, 'r', encoding='utf-8') as f: + return self.yaml.load(f) + + def generate_profile(self, product: str, output_file: Path): + """Generate NIST-based CIS profile by copying CIS profile and changing control reference.""" + print(f"Generating NIST-based CIS profile for {product}...") + + # Load CIS profile + cis_profile = self.load_cis_profile(product) + + # Copy the profile + nist_profile = dict(cis_profile) + + # Update title to indicate NIST-based + if 'title' in nist_profile: + nist_profile['title'] = nist_profile['title'] + ' (NIST-based)' + + # Update description to mention NIST source + if 'description' in nist_profile: + version = nist_profile.get('metadata', {}).get('version', '2.0.0') + product_number = product.replace('rhel', '') + + # Extract level from original description + level_match = re.search(r'"([^"]+)"', nist_profile['description']) + level_desc = level_match.group(1) if level_match else 'Level 2 - Server' + + nist_profile['description'] = f'''This profile defines a baseline that aligns to the "{level_desc}" +configuration from the Center for Internet Security® Red Hat Enterprise +Linux {product_number} Benchmark™, v{version}. + +This profile is generated from the NIST 800-53 control file and uses +the unified NIST 800-53 controls that include CIS-derived rules and +variables from all RHEL versions. + +This profile includes Center for Internet Security® +Red Hat Enterprise Linux {product_number} CIS Benchmarks™ content.''' + + # Update SMEs to indicate automation + if 'metadata' not in nist_profile: + nist_profile['metadata'] = {} + nist_profile['metadata']['SMEs'] = ['nist_sync_automation'] + + # Update selections: replace cis_rhelX:all with nist_800_53:all + if 'selections' in nist_profile: + new_selections = [] + replaced = False + + for selection in nist_profile['selections']: + # Check if this is a CIS control file selection + if isinstance(selection, str) and re.match(r'cis_rhel\d+:all', selection): + # Replace with NIST control file selection + new_selections.append('nist_800_53:all') + replaced = True + print(f" Replaced: {selection} → nist_800_53:all") + else: + # Keep all other selections (exclusions, variables, etc.) + new_selections.append(selection) + + nist_profile['selections'] = new_selections + + if not replaced: + print(" Warning: No CIS control file selection found to replace", file=sys.stderr) + + # Count extra selections + extra_count = len([s for s in new_selections if s != 'nist_800_53:all']) + if extra_count > 0: + print(f" Kept {extra_count} extra selections from CIS profile:") + for sel in [s for s in new_selections if s != 'nist_800_53:all']: + print(f" - {sel}") + + # Write profile + output_file.parent.mkdir(parents=True, exist_ok=True) + with open(output_file, 'w', encoding='utf-8') as f: + self.yaml.dump(nist_profile, f) + + print(f" ✓ Profile saved to {output_file}") + + +def main(): + """Main entry point.""" + parser = argparse.ArgumentParser( + description='Generate NIST-based CIS profile' + ) + parser.add_argument( + '--product', + default='rhel9', + help='Product ID (default: rhel9)' + ) + parser.add_argument( + '--output', + type=Path, + help='Output profile file (default: products//profiles/cis_nist.profile)' + ) + parser.add_argument( + '--repo-root', + type=Path, + default=Path(__file__).parent.parent.parent, + help='Path to repository root (default: auto-detect)' + ) + + args = parser.parse_args() + + # Determine output file + if args.output: + output_file = args.output + else: + output_file = args.repo_root / "products" / args.product / "profiles" / "cis_nist.profile" + + generator = NISTBasedCISProfileGenerator(args.repo_root) + + try: + generator.generate_profile(args.product, output_file) + + print("\n✓ Profile generation complete!") + print("\nNext steps:") + print(f" 1. Review the profile: {output_file}") + print(" 2. Build the product to test:") + print(f" ./build_product {args.product} --profile cis_nist --datastream-only") + + return 0 + + except Exception as e: + print(f"\n✗ Profile generation failed: {e}", file=sys.stderr) + import traceback + traceback.print_exc() + return 1 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/utils/nist_sync/generate_nist_viewer.py b/utils/nist_sync/generate_nist_viewer.py new file mode 100755 index 000000000000..f3fda7fc283c --- /dev/null +++ b/utils/nist_sync/generate_nist_viewer.py @@ -0,0 +1,364 @@ +#!/usr/bin/env python3 +""" +Generate NIST 800-53 Control Viewer HTML page with gap analysis and backlog management. + +This script: +1. Loads NIST 800-53 control files for each product +2. Loads OSCAL catalog data for NIST 800-53 Rev 5 +3. Merges control data with OSCAL metadata +4. Generates interactive HTML viewer with gap analysis +""" + +import json +import yaml +import argparse +from pathlib import Path +from typing import Dict, List, Any +import sys + +# Add parent directory to path for imports +sys.path.insert(0, str(Path(__file__).parent.parent.parent)) + +try: + from ruamel.yaml import YAML + yaml_loader = YAML() + yaml_loader.preserve_quotes = True + yaml_loader.default_flow_style = False +except ImportError: + yaml_loader = None + + +def load_yaml(filepath: Path) -> Dict[str, Any]: + """Load YAML file.""" + with open(filepath, 'r') as f: + if yaml_loader: + return yaml_loader.load(f) + else: + return yaml.safe_load(f) + + +def load_oscal_catalog(data_dir: Path) -> Dict[str, Any]: + """Load NIST OSCAL catalog.""" + catalog_file = data_dir / 'nist_800_53_rev5_catalog.json' + + if not catalog_file.exists(): + print(f"Warning: OSCAL catalog not found at {catalog_file}") + print("Run: cd utils/nist_sync && python3 download_oscal.py") + return {} + + with open(catalog_file, 'r') as f: + catalog = json.load(f) + + # Build control ID -> control data mapping + controls_map = {} + + def extract_controls(controls_list, parent_id=None): + """Recursively extract controls from OSCAL catalog.""" + for control in controls_list: + ctrl_id = control.get('id', '').lower() + + controls_map[ctrl_id] = { + 'id': ctrl_id, + 'title': control.get('title', ''), + 'class': control.get('class', ''), + 'parts': control.get('parts', []), + 'properties': control.get('props', []), + 'parameters': control.get('params', []), + 'parent': parent_id + } + + # Process sub-controls + if 'controls' in control: + extract_controls(control['controls'], parent_id=ctrl_id) + + # Extract controls from catalog + if 'catalog' in catalog: + for group in catalog['catalog'].get('groups', []): + if 'controls' in group: + extract_controls(group['controls']) + + return controls_map + + +def load_product_controls(product: str, repo_root: Path) -> Dict[str, Any]: + """Load control files for a product.""" + controls_dir = repo_root / 'products' / product / 'controls' / 'nist_800_53' + metadata_file = repo_root / 'products' / product / 'controls' / 'nist_800_53.yml' + + if not controls_dir.exists(): + print(f"Warning: Control directory not found for {product}: {controls_dir}") + return {} + + # Load metadata + metadata = {} + if metadata_file.exists(): + metadata = load_yaml(metadata_file) + + # Load all family files + controls = [] + for family_file in sorted(controls_dir.glob('*.yml')): + family_data = load_yaml(family_file) + if 'controls' in family_data: + controls.extend(family_data['controls']) + + return { + 'product': product, + 'metadata': metadata, + 'controls': controls + } + + +def merge_control_data(product_controls: Dict[str, Any], oscal_controls: Dict[str, Any]) -> List[Dict[str, Any]]: + """Merge product control data with OSCAL metadata.""" + merged = [] + + for control in product_controls.get('controls', []): + ctrl_id = control.get('id', '').lower() + + # Get OSCAL metadata + oscal_data = oscal_controls.get(ctrl_id, {}) + + # Extract description from OSCAL parts + description = "" + guidance = "" + if oscal_data.get('parts'): + for part in oscal_data['parts']: + if part.get('name') == 'statement': + description = part.get('prose', '') + elif part.get('name') == 'guidance': + guidance = part.get('prose', '') + + # Extract related controls from OSCAL + related_controls = [] + for prop in oscal_data.get('properties', []): + if prop.get('name') == 'related': + related_controls.append(prop.get('value', '')) + + merged_control = { + 'id': ctrl_id, + 'title': control.get('title', oscal_data.get('title', '')), + 'levels': control.get('levels', []), + 'rules': control.get('rules', []), + 'status': control.get('status', 'pending'), + 'notes': control.get('notes', ''), + # OSCAL metadata + 'description': description, + 'guidance': guidance, + 'parameters': oscal_data.get('parameters', []), + 'related_controls': related_controls, + 'class': oscal_data.get('class', ''), + 'parent': oscal_data.get('parent', ''), + # Gap analysis + 'has_rules': len(control.get('rules', [])) > 0, + 'is_automated': control.get('status') == 'automated', + 'is_manual': control.get('status') == 'manual', + 'is_pending': control.get('status') == 'pending', + 'is_inherently_met': control.get('status') == 'inherently met', + 'is_does_not_meet': control.get('status') == 'does not meet', + 'is_not_applicable': control.get('status') == 'not applicable', + } + + merged.append(merged_control) + + return merged + + +def generate_viewer_data(products: List[str], repo_root: Path) -> Dict[str, Any]: + """Generate complete data structure for the viewer.""" + data_dir = repo_root / 'utils' / 'nist_sync' / 'data' + + # Load OSCAL catalog + print("Loading OSCAL catalog...") + oscal_controls = load_oscal_catalog(data_dir) + + # Load controls for each product + products_data = {} + for product in products: + print(f"Loading controls for {product}...") + product_controls = load_product_controls(product, repo_root) + + if product_controls: + merged = merge_control_data(product_controls, oscal_controls) + products_data[product] = { + 'metadata': product_controls.get('metadata', {}), + 'controls': merged + } + + # Calculate statistics + stats = {} + for product, data in products_data.items(): + controls = data['controls'] + stats[product] = { + 'total': len(controls), + 'automated': sum(1 for c in controls if c['is_automated']), + 'manual': sum(1 for c in controls if c['is_manual']), + 'pending': sum(1 for c in controls if c['is_pending']), + 'inherently_met': sum(1 for c in controls if c['is_inherently_met']), + 'does_not_meet': sum(1 for c in controls if c['is_does_not_meet']), + 'not_applicable': sum(1 for c in controls if c['is_not_applicable']), + 'with_rules': sum(1 for c in controls if c['has_rules']), + 'without_rules': sum(1 for c in controls if not c['has_rules']), + } + + return { + 'products': products_data, + 'statistics': stats, + 'families': [ + {'id': 'ac', 'name': 'Access Control'}, + {'id': 'at', 'name': 'Awareness and Training'}, + {'id': 'au', 'name': 'Audit and Accountability'}, + {'id': 'ca', 'name': 'Assessment, Authorization, and Monitoring'}, + {'id': 'cm', 'name': 'Configuration Management'}, + {'id': 'cp', 'name': 'Contingency Planning'}, + {'id': 'ia', 'name': 'Identification and Authentication'}, + {'id': 'ir', 'name': 'Incident Response'}, + {'id': 'ma', 'name': 'Maintenance'}, + {'id': 'mp', 'name': 'Media Protection'}, + {'id': 'pe', 'name': 'Physical and Environmental Protection'}, + {'id': 'pl', 'name': 'Planning'}, + {'id': 'pm', 'name': 'Program Management'}, + {'id': 'ps', 'name': 'Personnel Security'}, + {'id': 'pt', 'name': 'PII Processing and Transparency'}, + {'id': 'ra', 'name': 'Risk Assessment'}, + {'id': 'sa', 'name': 'System and Services Acquisition'}, + {'id': 'sc', 'name': 'System and Communications Protection'}, + {'id': 'si', 'name': 'System and Information Integrity'}, + {'id': 'sr', 'name': 'Supply Chain Risk Management'}, + {'id': 'other', 'name': 'Other (Unmapped CIS Items)'}, + ] + } + + +def generate_html_viewer(output_dir: Path, templates_dir: Path, viewer_data: Dict[str, Any]): + """Generate multi-page HTML viewer from templates with embedded data.""" + + # Read shared components + shared_styles = (templates_dir / '_shared_styles.html').read_text() + shared_header_template = (templates_dir / '_shared_header.html').read_text() + + # List of page templates to generate + pages = [ + 'index.html', + 'controls.html', + 'control-detail.html', + 'gaps.html', + 'statistics.html', + 'family.html' + ] + + # Generate pages for each product in separate subdirectories + for product in viewer_data['products'].keys(): + product_dir = output_dir / product + product_dir.mkdir(parents=True, exist_ok=True) + + # Create product-specific data (only this product's data) + product_data = { + 'products': {product: viewer_data['products'][product]}, + 'statistics': {product: viewer_data['statistics'][product]}, + 'families': viewer_data['families'] + } + + # Embed the JSON data for this product + json_data = json.dumps(product_data, indent=2) + embedded_data_script = f'const EMBEDDED_DATA = {json_data};\nconst CURRENT_PRODUCT = "{product}";' + + # Create product selector links for header + all_products = list(viewer_data['products'].keys()) + product_links = [] + for prod in all_products: + if prod == product: + product_links.append(f'{prod.upper()}') + else: + product_links.append(f'{prod.upper()}') + + product_selector_html = ' | '.join(product_links) + + # Update shared header with product selector + shared_header = shared_header_template.replace( + '', + f'
    Product: {product_selector_html}
    ' + ) + + # Generate each page for this product + for page in pages: + template_file = templates_dir / page + + if not template_file.exists(): + print(f"Warning: Template not found: {template_file}") + continue + + # Read template + html_content = template_file.read_text() + + # Replace placeholders + html_content = html_content.replace('', f'') + html_content = html_content.replace('', shared_header) + html_content = html_content.replace('/* DATA_PLACEHOLDER */', embedded_data_script) + + # Write output file + output_file = product_dir / page + output_file.write_text(html_content) + print(f"Generated: {output_file}") + + # Create an index.html that redirects to rhel9 by default + default_product = 'rhel9' if 'rhel9' in viewer_data['products'] else list(viewer_data['products'].keys())[0] + redirect_html = f''' + + + + + NIST 800-53 Control Viewer + + +

    Redirecting to {default_product.upper()} viewer...

    + +''' + + (output_dir / 'index.html').write_text(redirect_html) + print(f"Generated redirect: {output_dir / 'index.html'}") + + print(f"\nMulti-page viewer generated in: {output_dir}") + print("Product-specific viewers:") + for product in viewer_data['products'].keys(): + print(f" - {product.upper()}: {output_dir / product / 'index.html'}") + print(f"\nOpen {output_dir / 'index.html'} in a web browser (redirects to {default_product.upper()}).") + + +def main(): + parser = argparse.ArgumentParser(description='Generate NIST 800-53 Control Viewer') + parser.add_argument('--products', nargs='+', default=['rhel8', 'rhel9', 'rhel10'], + help='Products to include (default: rhel8 rhel9 rhel10)') + parser.add_argument('--output-dir', type=Path, required=True, + help='Output directory for generated files') + parser.add_argument('--repo-root', type=Path, default=Path.cwd(), + help='Repository root directory') + + args = parser.parse_args() + + # Ensure output directory exists + args.output_dir.mkdir(parents=True, exist_ok=True) + + # Generate viewer data + print("Generating viewer data...") + viewer_data = generate_viewer_data(args.products, args.repo_root) + + # Write data file (for reference/debugging) + data_file = args.output_dir / 'nist-controls-data.json' + with open(data_file, 'w') as f: + json.dump(viewer_data, f, indent=2) + print(f"Generated data file: {data_file}") + + # Generate multi-page HTML viewer + templates_dir = Path(__file__).parent / 'templates' + + if templates_dir.exists(): + generate_html_viewer(args.output_dir, templates_dir, viewer_data) + else: + print(f"Warning: Templates directory not found: {templates_dir}") + print("HTML viewer not generated. Ensure templates directory exists.") + + print("\nViewer generation complete!") + + +if __name__ == '__main__': + main() diff --git a/utils/nist_sync/generate_product_family_guards.py b/utils/nist_sync/generate_product_family_guards.py new file mode 100755 index 000000000000..4a610430c345 --- /dev/null +++ b/utils/nist_sync/generate_product_family_guards.py @@ -0,0 +1,717 @@ +#!/usr/bin/env python3 +""" +Product Family-Aware Jinja2 Guard Generator + +This script generates guards considering product families (e.g., all RHEL versions). +When targeting "rhel", it automatically includes rhel8, rhel9, rhel10. + +Example: + # Target all RHEL versions + ./generate_product_family_guards.py --target rhel \ + --control-file controls/nist_800_53.yml + + # Target multiple families + ./generate_product_family_guards.py --target rhel ocp \ + --control-file controls/nist_800_53.yml + +Output generates smart guards: + {{{% if product.startswith('rhel') %}} + - sshd_disable_root_login + {{{% endif %}}} +""" + +import json +import sys +from pathlib import Path +from typing import Dict, Set, List, Optional +from collections import defaultdict +import re + +try: + from ruamel.yaml import YAML +except ImportError: + print("Error: ruamel.yaml is required. Install it with:", file=sys.stderr) + print(" pip install ruamel.yaml", file=sys.stderr) + sys.exit(1) + + +# Product family definitions +PRODUCT_FAMILIES = { + 'rhel': ['rhel8', 'rhel9', 'rhel10'], + 'ol': ['ol7', 'ol8', 'ol9'], + 'ocp': ['ocp4'], + 'ubuntu': ['ubuntu2004', 'ubuntu2204', 'ubuntu2404'], + 'fedora': ['fedora'], + 'sle': ['sle12', 'sle15'], + 'rhcos': ['rhcos4'], + 'debian': ['debian10', 'debian11', 'debian12'], + 'almalinux': ['almalinux8', 'almalinux9'], +} + + +class ProductFamilyGuardGenerator: + """Generates product family-aware guards for control files.""" + + def __init__(self, repo_root: Path): + self.repo_root = repo_root + self.build_dir = repo_root / "build" + + # Setup YAML parser + self.yaml = YAML() + self.yaml.preserve_quotes = True + self.yaml.default_flow_style = False + self.yaml.indent(mapping=2, sequence=4, offset=2) + self.yaml.width = 4096 + + def expand_product_targets(self, targets: List[str]) -> List[str]: + """ + Expand product family targets to specific products. + + Args: + targets: List like ['rhel', 'ocp'] + + Returns: + Expanded list like ['rhel8', 'rhel9', 'rhel10', 'ocp4'] + """ + expanded = [] + + for target in targets: + target_lower = target.lower() + + if target_lower in PRODUCT_FAMILIES: + # It's a family, expand it + expanded.extend(PRODUCT_FAMILIES[target_lower]) + else: + # It's a specific product + expanded.append(target_lower) + + return sorted(set(expanded)) + + def detect_product_family(self, products: Set[str]) -> Optional[str]: + """ + Detect if a set of products forms a complete family. + + Args: + products: Set of product IDs + + Returns: + Family name if products form a complete family, None otherwise + """ + products_set = set(p.lower() for p in products) + + for family, members in PRODUCT_FAMILIES.items(): + members_set = set(members) + + # Only use family guard if ALL members of the family are present + if products_set == members_set: + return family + + return None + + def find_built_products(self) -> List[str]: + """Find all products that have been built.""" + if not self.build_dir.exists(): + print(f"Error: Build directory not found: {self.build_dir}", file=sys.stderr) + print("Run ./build_product first to generate builds", file=sys.stderr) + sys.exit(1) + + products = [] + for product_dir in self.build_dir.iterdir(): + if product_dir.is_dir() and (product_dir / "profiles").exists(): + products.append(product_dir.name) + + return sorted(products) + + def scan_product_profiles(self, product: str) -> Set[str]: + """Scan all profiles for a product and collect all selected rules.""" + profiles_dir = self.build_dir / product / "profiles" + + if not profiles_dir.exists(): + return set() + + all_rules = set() + + for profile_file in profiles_dir.glob("*.profile"): + try: + with open(profile_file, 'r', encoding='utf-8') as f: + profile_data = json.load(f) + + selections = profile_data.get('selections', []) + + # Filter out variable assignments and exclusions + rule_ids = { + sel for sel in selections + if '=' not in sel and not sel.startswith('!') + } + + all_rules.update(rule_ids) + + except (json.JSONDecodeError, IOError) as e: + print(f"Warning: Failed to read {profile_file}: {e}", file=sys.stderr) + + return all_rules + + def scan_cis_control_files(self, products: List[str]) -> Dict[str, Set[str]]: + """Scan CIS control files to determine which products each item belongs to.""" + rule_to_products = defaultdict(set) + + for product in products: + cis_file = self.repo_root / 'products' / product / 'controls' / f'cis_{product}.yml' + + if not cis_file.exists(): + continue + + try: + with open(cis_file, 'r', encoding='utf-8') as f: + cis_data = self.yaml.load(f) + + for control in cis_data.get('controls', []): + for rule_id in control.get('rules', []): + rule_to_products[rule_id].add(product) + + except Exception as e: + print(f"Warning: Failed to read {cis_file}: {e}", file=sys.stderr) + + return dict(rule_to_products) + + def build_rule_to_products_map( + self, + products: List[str], + verbose: bool = False + ) -> Dict[str, Set[str]]: + """Build a mapping of rule IDs to the products they appear in.""" + print("Scanning CIS control files for product availability...") + + rule_to_products = defaultdict(set) + + # Scan CIS control files (source of truth for which items belong to which product) + cis_mappings = self.scan_cis_control_files(products) + for rule_id, prods in cis_mappings.items(): + rule_to_products[rule_id].update(prods) + + print(f" ✓ Scanned {len(products)} products") + print(f" ✓ Found {len(rule_to_products)} unique rules/variables") + + return dict(rule_to_products) + + def generate_jinja_guard( + self, + products: Set[str], + all_products: Set[str], + use_family_guards: bool = True + ) -> str: + """ + Generate a Jinja2 conditional guard for a rule. + + Args: + products: Set of products where this rule exists + all_products: Set of all known products + use_family_guards: Use product.startswith() for families + + Returns: + Jinja2 conditional string or empty string if applies to all + """ + # If rule applies to all products, no guard needed + if products == all_products: + return "" + + # If rule applies to no products, exclude it entirely + if not products: + return "EXCLUDE" + + # Try to detect if products form a family + if use_family_guards: + family = self.detect_product_family(products) + + if family: + # Use family-based guard (double braces for YAML file guards) + return '{{% if product.startswith("' + family + '") %}}' + + # Otherwise, generate explicit list (double braces for YAML file guards) + products_list = sorted(products) + + if len(products_list) == 1: + return '{{% if product == "' + products_list[0] + '" %}}' + else: + products_str = '", "'.join(products_list) + return '{{% if product in ["' + products_str + '"] %}}' + + def load_variable_to_products_map(self) -> Dict[str, Set[str]]: + """Load variable-to-products mapping from CIS control files.""" + var_map_file = self.repo_root / "utils" / "nist_sync" / "data" / "variable_to_products.json" + + if not var_map_file.exists(): + print(f"Warning: Variable map not found at {var_map_file}", file=sys.stderr) + print("Variables will be included for all products", file=sys.stderr) + return {} + + with open(var_map_file, 'r', encoding='utf-8') as f: + var_map = json.load(f) + + # Convert lists to sets + return {var: set(products) for var, products in var_map.items()} + + def _group_variable_variants(self, rules: List[str]) -> List[str]: + """Group product-specific variable variants into conditional blocks.""" + from collections import defaultdict + + # Find variable variants (same base variable, different product-specific values) + variants = defaultdict(list) + regular_items = [] + + for item in rules: + if item.startswith('GUARD:') and '=' in item: + # Extract variable name (before =) + parts = item.split(':', 2) + if len(parts) >= 3: + var_assignment = parts[2] + var_name = var_assignment.split('=')[0] + variants[var_name].append(item) + else: + regular_items.append(item) + else: + regular_items.append(item) + + # Rebuild the list, grouping variants + grouped_rules = [] + variant_groups_count = 0 + + for item in rules: + # Skip items that are part of a variant group (we'll add them back grouped) + if item.startswith('GUARD:') and '=' in item: + parts = item.split(':', 2) + if len(parts) >= 3: + var_assignment = parts[2] + var_name = var_assignment.split('=')[0] + + # Only process if this is the first occurrence of this variant + if var_name in variants and len(variants[var_name]) > 1: + # Add all variants for this variable as a special marker + grouped_rules.append(f"VARIANT_GROUP:{var_name}:{'|'.join(variants[var_name])}") + variant_groups_count += 1 + # Remove from variants dict so we don't process it again + del variants[var_name] + elif var_name not in variants: + # Already processed or single variant + continue + else: + # Single variant, keep as-is + grouped_rules.append(item) + del variants[var_name] + else: + grouped_rules.append(item) + else: + grouped_rules.append(item) + + self._variant_groups_count = variant_groups_count + return grouped_rules + + def apply_guards_to_control_file( + self, + control_file: Path, + rule_to_products: Dict[str, Set[str]], + output_file: Optional[Path] = None, + use_family_guards: bool = True, + verbose: bool = False + ): + """Apply product guards to a control file.""" + if not control_file.exists(): + print(f"Error: Control file not found: {control_file}", file=sys.stderr) + sys.exit(1) + + print(f"Loading control file: {control_file}") + + with open(control_file, 'r', encoding='utf-8') as f: + control_data = self.yaml.load(f) + + # Load variable-to-products mapping + var_to_products = self.load_variable_to_products_map() + + if not control_data or 'controls' not in control_data: + print("Error: Invalid control file format", file=sys.stderr) + sys.exit(1) + + all_products = set() + for products in rule_to_products.values(): + all_products.update(products) + + guard_type = "family-based" if use_family_guards else "explicit" + print(f"Applying {guard_type} product guards") + print(f" Products: {', '.join(sorted(all_products))}") + + total_rules = 0 + guarded_rules = 0 + excluded_rules = 0 + family_guards = 0 + grouped_variants = 0 + + for control in control_data['controls']: + if 'rules' not in control or not control['rules']: + continue + + # Process each rule in the control + new_rules = [] + has_unguarded_rules = False + + for rule_id in control['rules']: + total_rules += 1 + + # Check if this is a variable or a rule + if '=' in rule_id: + # It's a variable - get products from variable map + products = var_to_products.get(rule_id, set()) + else: + # It's a rule - get products from rule map + products = rule_to_products.get(rule_id, set()) + + # Generate guard + guard = self.generate_jinja_guard(products, all_products, use_family_guards) + + if guard == "EXCLUDE": + if verbose: + print(f" {control['id']}: Excluding {rule_id} (not in any product)") + excluded_rules += 1 + continue + + elif guard: + guarded_rules += 1 + if 'startswith' in guard: + family_guards += 1 + + if verbose: + products_str = ', '.join(sorted(products)) + print(f" {control['id']}: {rule_id} → {products_str}") + print(f" Guard: {guard}") + + # Store as marker for later conversion + new_rules.append(f"GUARD:{guard}:{rule_id}") + + else: + # Rule applies to all products + new_rules.append(rule_id) + has_unguarded_rules = True + + # Group product-specific variable variants + new_rules = self._group_variable_variants(new_rules) + if hasattr(self, '_variant_groups_count'): + grouped_variants += self._variant_groups_count + + # If ALL rules are guarded AND there's only ONE unique guard, + # mark to add else: [] + if new_rules and not has_unguarded_rules: + # Count unique guards + unique_guards = set() + for rule in new_rules: + if isinstance(rule, str) and rule.startswith('GUARD:'): + parts = rule.split(':', 2) + if len(parts) >= 2: + unique_guards.add(parts[1]) + + # Only add else: [] if there's exactly ONE guard + if len(unique_guards) == 1: + control['_NEEDS_ELSE_EMPTY'] = True + + control['rules'] = new_rules + + print(f" ✓ Processed {total_rules} rules") + print(f" ✓ Added guards to {guarded_rules} rules") + if use_family_guards: + print(f" ✓ Used family guards for {family_guards} rules") + if grouped_variants > 0: + print(f" ✓ Grouped {grouped_variants} variable variant groups") + print(f" ✓ Excluded {excluded_rules} rules (not in any product)") + + # Determine output path + if output_file is None: + output_file = control_file + + print(f"Writing guarded control file: {output_file}") + + # Count controls that need else: [] + controls_needing_else = sum(1 for c in control_data['controls'] if '_NEEDS_ELSE_EMPTY' in c) + if controls_needing_else > 0: + print(f" ✓ Will add else: [] to {controls_needing_else} controls with all-guarded rules") + + # Write to file with custom formatting for guards + self._write_guarded_yaml(control_data, output_file) + + print(f" ✓ Saved to {output_file}") + + def _write_guarded_yaml(self, data: Dict, output_path: Path): + """Write YAML with Jinja2 guards expanded.""" + import io + + # First, dump to string + stream = io.StringIO() + self.yaml.dump(data, stream) + yaml_content = stream.getvalue() + + # Process to convert GUARD markers to Jinja2 + lines = yaml_content.split('\n') + output_lines = [] + current_guard = None + indent_level = 0 + current_control_needs_else = False + in_rules_section = False + + for i, line in enumerate(lines): + # Check if line contains a VARIANT_GROUP marker + if 'VARIANT_GROUP:' in line: + # Extract variable name and variant items + parts = line.split('VARIANT_GROUP:', 1)[1] + var_name_end = parts.index(':', 0) + variants_str = parts[var_name_end + 1:].strip().strip("'\"") + variants = variants_str.split('|') + + # Get indentation + indent = len(line) - len(line.lstrip()) + + # Close any existing guard + if current_guard: + output_lines.append(' ' * indent_level + '{{% endif %}}') + current_guard = None + + # Generate if/elif block for variants + for i, variant in enumerate(variants): + # Parse the variant (GUARD:condition:var_name=value) + if variant.startswith('GUARD:'): + v_parts = variant.split(':', 2) + if len(v_parts) >= 3: + guard_condition = v_parts[1] + var_assignment = v_parts[2] + + if i == 0: + # First variant uses 'if' + output_lines.append(' ' * indent + guard_condition) + else: + # Subsequent variants use 'elif' + elif_condition = guard_condition.replace('{{% if ', '{{% elif ') + output_lines.append(' ' * indent + elif_condition) + + # Add the variable assignment + output_lines.append(' ' * indent + f'- {var_assignment}') + + # Close the if/elif block + output_lines.append(' ' * indent + '{{% endif %}}') + + # Check if line contains a GUARD marker (but not _CONTROL_GUARD) + elif 'GUARD:' in line and '_CONTROL_GUARD:' not in line: + # Extract guard and rule + parts = line.split('GUARD:', 1)[1] + try: + guard_end = parts.index(':', 0) + guard = parts[:guard_end] + rule_id = parts[guard_end + 1:].strip().strip("'\"") + except ValueError: + print(f"Error parsing GUARD marker in line: {line}", file=sys.stderr) + print(f"Parts after split: {parts}", file=sys.stderr) + raise + + # Get indentation + indent = len(line) - len(line.lstrip()) + + # Close previous guard if different + if current_guard and current_guard != guard: + output_lines.append(' ' * indent_level + '{{% endif %}}') + current_guard = None + + # Open new guard if needed + if not current_guard: + output_lines.append(' ' * indent + guard) + indent_level = indent + current_guard = guard + + # Add the rule + output_lines.append(' ' * indent + f'- {rule_id}') + + else: + # Regular line + stripped = line.lstrip() + indent = len(line) - len(line.lstrip()) + + # Check for control start (- id: at indentation 2) + if stripped.startswith('- id:') and indent == 2: + current_control_needs_else = False + in_rules_section = False + # Look ahead for _NEEDS_ELSE_EMPTY marker + for j in range(i + 1, min(i + 20, len(lines))): + next_line = lines[j] + if '_NEEDS_ELSE_EMPTY:' in next_line: + current_control_needs_else = True + break + if next_line.lstrip().startswith('- id:'): + break + + # Skip marker lines + if '_NEEDS_ELSE_EMPTY:' in line: + continue + + # Detect rules: section + if stripped.startswith('rules:'): + in_rules_section = True + + # Check if this is a plain rule (starts with '- ' but no GUARD marker) + is_plain_rule = stripped.startswith('- ') and 'GUARD:' not in line and 'VARIANT_GROUP:' not in line + + # Close guard if: + # 1. We're moving to a different section (not a list item), OR + # 2. We encounter a plain rule (should not be inside a guard) + if current_guard and line: + if not line.startswith(' ' * indent_level + '- ') or is_plain_rule: + # Check if we're exiting the rules section + exiting_rules = in_rules_section and not (stripped.startswith('- ') or stripped.startswith('{')) + + # Before closing, check if we need to add else: [] + if current_control_needs_else and exiting_rules: + # Add else: [] at the same indentation as the rules + output_lines.append(' ' * indent_level + '{{% else %}}') + output_lines.append(' ' * indent_level + '[]') + output_lines.append(' ' * indent_level + '{{% endif %}}') + else: + # Regular endif + output_lines.append(' ' * indent_level + '{{% endif %}}') + current_guard = None + + # Mark that we've exited the rules section + if exiting_rules: + in_rules_section = False + + output_lines.append(line) + + # Close final guard if needed + if current_guard: + # If we're still in rules section and control needs else, add it + if in_rules_section and current_control_needs_else: + output_lines.append(' ' * indent_level + '{{% else %}}') + output_lines.append(' ' * indent_level + '[]') + output_lines.append(' ' * indent_level + '{{% endif %}}') + + # Write output + output_path.parent.mkdir(parents=True, exist_ok=True) + with open(output_path, 'w', encoding='utf-8') as f: + f.write('\n'.join(output_lines)) + + +def main(): + """Main entry point.""" + import argparse + + parser = argparse.ArgumentParser( + description='Generate product family-aware Jinja2 guards for control files', + formatter_class=argparse.RawDescriptionHelpFormatter, + epilog=''' +Product Families: + rhel → rhel8, rhel9, rhel10 + ol → ol7, ol8, ol9 + ocp → ocp4 + ubuntu → ubuntu2004, ubuntu2204, ubuntu2404 + fedora → fedora + sle → sle12, sle15 + rhcos → rhcos4 + debian → debian10, debian11, debian12 + almalinux → almalinux8, almalinux9 + +Examples: + # Target all RHEL versions (uses defaults: .source → .yml) + %(prog)s --target rhel + + # Target RHEL and OCP families + %(prog)s --target rhel ocp + + # Target specific products + %(prog)s --target rhel8 rhel9 ocp4 + + # Use explicit guards instead of family guards + %(prog)s --target rhel --no-family-guards + + # Custom input/output files + %(prog)s --target rhel --control-file custom.yml.source --output custom.yml + +Output example with family guards: + {{{% if product.startswith('rhel') %} + - sshd_disable_root_login + {{{% endif %}} + ''' + ) + parser.add_argument( + '--target', + nargs='+', + required=True, + help='Target product families or specific products (e.g., rhel ocp)' + ) + parser.add_argument( + '--control-file', + type=Path, + help='Path to source control file to process (default: controls/nist_800_53.yml.source)' + ) + parser.add_argument( + '--output', + type=Path, + help='Output file path (default: controls/nist_800_53.yml)' + ) + parser.add_argument( + '--repo-root', + type=Path, + default=Path(__file__).parent.parent.parent, + help='Path to repository root (default: auto-detect)' + ) + parser.add_argument( + '--no-family-guards', + action='store_true', + help='Use explicit product lists instead of family-based guards' + ) + parser.add_argument( + '--verbose', '-v', + action='store_true', + help='Enable verbose output' + ) + + args = parser.parse_args() + + # Set defaults for source/output files + if not args.control_file: + args.control_file = args.repo_root / "controls" / "nist_800_53.yml.source" + if not args.output: + args.output = args.repo_root / "controls" / "nist_800_53.yml" + + generator = ProductFamilyGuardGenerator(args.repo_root) + + try: + # Expand family targets to specific products + products = generator.expand_product_targets(args.target) + + print(f"Target families/products: {', '.join(args.target)}") + print(f"Expanded to products: {', '.join(products)}") + print() + + # Build rule→products mapping + rule_to_products = generator.build_rule_to_products_map( + products, + verbose=args.verbose + ) + + print() + + # Apply guards to control file + generator.apply_guards_to_control_file( + args.control_file, + rule_to_products, + output_file=args.output, + use_family_guards=not args.no_family_guards, + verbose=args.verbose + ) + + print() + print("✓ Product family guards generated successfully!") + + return 0 + + except Exception as e: + print(f"\n✗ Failed to generate guards: {e}", file=sys.stderr) + import traceback + traceback.print_exc() + return 1 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/utils/nist_sync/generate_variable_to_products.py b/utils/nist_sync/generate_variable_to_products.py new file mode 100755 index 000000000000..8571414bc8b3 --- /dev/null +++ b/utils/nist_sync/generate_variable_to_products.py @@ -0,0 +1,160 @@ +#!/usr/bin/env python3 +""" +Generate variable-to-products mapping from CIS control files. + +This script scans CIS control files for each RHEL version and builds +a mapping of which products use which variable assignments. + +Usage: + ./generate_variable_to_products.py +""" + +import json +import sys +from pathlib import Path +from collections import defaultdict +from typing import Dict, Set + +try: + from ruamel.yaml import YAML +except ImportError: + print("Error: ruamel.yaml is required. Install it with:", file=sys.stderr) + print(" pip install ruamel.yaml", file=sys.stderr) + sys.exit(1) + + +class VariableToProductsGenerator: + """Generates variable-to-products mapping from CIS control files.""" + + def __init__(self, repo_root: Path): + self.repo_root = repo_root + self.yaml = YAML() + self.yaml.preserve_quotes = True + + def extract_variables_from_controls(self, controls) -> Set[str]: + """ + Recursively extract variable assignments from control structure. + + Returns set of variable assignments like "var_name=value" + """ + variables = set() + + def traverse(obj): + if isinstance(obj, dict): + # Check for rules (variable assignments in CIS control files) + rules = obj.get('rules', []) + for rule in rules: + if isinstance(rule, str) and '=' in rule and not rule.startswith('!'): + # This is a variable assignment + variables.add(rule) + + # Check for selections (variable assignments in profile files) + selections = obj.get('selections', []) + for sel in selections: + if isinstance(sel, str) and '=' in sel and not sel.startswith('!'): + # This is a variable assignment + variables.add(sel) + + # Recurse into nested controls + nested_controls = obj.get('controls', []) + if nested_controls: + traverse(nested_controls) + + # Recurse into other dict values + for value in obj.values(): + if isinstance(value, (dict, list)): + traverse(value) + + elif isinstance(obj, list): + for item in obj: + if isinstance(item, (dict, list)): + traverse(item) + + traverse(controls) + return variables + + def scan_cis_control_file(self, product: str) -> Set[str]: + """Scan CIS control file for a product and extract variable assignments.""" + cis_file = self.repo_root / "products" / product / "controls" / f"cis_{product}.yml" + + if not cis_file.exists(): + print(f"Warning: CIS control file not found: {cis_file}", file=sys.stderr) + return set() + + print(f"Scanning {product}...") + + with open(cis_file, 'r', encoding='utf-8') as f: + data = self.yaml.load(f) + + # Extract variables from all controls + controls = data.get('controls', []) + variables = self.extract_variables_from_controls(controls) + + print(f" Found {len(variables)} variable assignments") + return variables + + def build_variable_to_products_map(self, products: list) -> Dict[str, list]: + """Build mapping of variable assignments to products that use them.""" + var_to_products = defaultdict(set) + + for product in products: + variables = self.scan_cis_control_file(product) + for var in variables: + var_to_products[var].add(product) + + # Convert to dict with sorted lists + result = { + var: sorted(list(prods)) + for var, prods in sorted(var_to_products.items()) + } + + return result + + def save_mapping(self, mapping: Dict[str, list], output_file: Path): + """Save mapping to JSON file.""" + output_file.parent.mkdir(parents=True, exist_ok=True) + + with open(output_file, 'w', encoding='utf-8') as f: + json.dump(mapping, f, indent=2, sort_keys=True) + + print(f"\n✓ Saved variable-to-products mapping to {output_file}") + print(f" Total variables: {len(mapping)}") + + # Show statistics + all_products = set() + for prods in mapping.values(): + all_products.update(prods) + print(f" Products found: {', '.join(sorted(all_products))}") + + +def main(): + """Main entry point.""" + repo_root = Path(__file__).parent.parent.parent + products = ['rhel8', 'rhel9', 'rhel10'] + + output_file = repo_root / "utils" / "nist_sync" / "data" / "variable_to_products.json" + + print("Generating variable-to-products mapping from CIS control files...") + print() + + generator = VariableToProductsGenerator(repo_root) + + try: + # Build mapping + mapping = generator.build_variable_to_products_map(products) + + # Save to file + generator.save_mapping(mapping, output_file) + + print("\n✓ Generation complete!") + return 0 + + except Exception as e: + print(f"\n✗ Generation failed: {e}", file=sys.stderr) + import traceback + traceback.print_exc() + return 1 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/utils/nist_sync/harvest_cis_nist_mappings.py b/utils/nist_sync/harvest_cis_nist_mappings.py new file mode 100755 index 000000000000..bab1c60604b9 --- /dev/null +++ b/utils/nist_sync/harvest_cis_nist_mappings.py @@ -0,0 +1,609 @@ +#!/usr/bin/env python3 +""" +Harvest NIST 800-53 mappings from CIS benchmark documents and control files. + +This script: +1. Parses CIS benchmark MD and PDF files to extract NIST references for each CIS control +2. Reads CIS control YAML files to get rule mappings for each CIS control +3. Combines them to create rule → NIST control mappings +4. Updates the nist_800_53.yml control file with these mappings +""" + +import re +import sys +from pathlib import Path +from typing import Dict, List, Set +from collections import defaultdict + +try: + from ruamel.yaml import YAML +except ImportError: + print("Error: ruamel.yaml is required. Install it with:", file=sys.stderr) + print(" pip install ruamel.yaml", file=sys.stderr) + sys.exit(1) + +try: + import PyPDF2 + PDF_AVAILABLE = True +except ImportError: + PDF_AVAILABLE = False + print("Warning: PyPDF2 not available. PDF parsing will be skipped.", file=sys.stderr) + print(" Install with: pip install PyPDF2", file=sys.stderr) + + +class CISNISTHarvester: + """Harvests NIST mappings from CIS benchmarks and control files.""" + + def __init__(self, repo_root: Path): + self.repo_root = repo_root + self.nist_sync_dir = repo_root / "utils" / "nist_sync" + self.nist_control_file = repo_root / "controls" / "nist_800_53.yml" + self.mapping_cache_file = self.nist_sync_dir / "data" / "cis_nist_mappings.json" + + # Setup YAML parser + self.yaml = YAML() + self.yaml.preserve_quotes = True + self.yaml.default_flow_style = False + self.yaml.indent(mapping=2, sequence=4, offset=2) + self.yaml.width = 4096 + + def parse_cis_md_file(self, md_file: Path) -> Dict[str, Set[str]]: + """ + Parse CIS benchmark MD file to extract NIST references. + + Args: + md_file: Path to CIS benchmark MD file + + Returns: + Dict mapping CIS control ID to set of NIST control IDs + e.g., {"1.1.1.1": {"cm-7"}, "1.2.1": {"ac-2", "ac-3"}} + """ + print(f" Parsing {md_file.name}...") + + with open(md_file, 'r', encoding='utf-8') as f: + lines = f.readlines() + + cis_to_nist = {} + current_cis_id = None + + for line in lines: + # Check if this is a CIS control header + # Pattern: # *1.1.1.1 Ensure ...* + cis_header = re.match(r'^#+ \*([0-9.]+)\s+[^*]+\*', line) + if cis_header: + current_cis_id = cis_header.group(1) + continue + + # Check if line contains NIST reference + # Pattern matches multiple formats: + # - "NIST SP 800-53 Rev. 5: CM-7" + # - "NIST SP 800-53 :: CM-7" + # - "NIST SP 800-53: CM-7 a" + nist_match = re.search( + r'NIST SP 800-53(?:\s+Rev\.?\s*\d+)?(?:\s*[:]{1,2})\s*([A-Z]{2}-[0-9]+(?:\([0-9]+\))?)(?:\s+[a-z])?', + line + ) + + if nist_match and current_cis_id: + ctrl = nist_match.group(1) + # Convert to OSCAL format + ctrl = ctrl.lower() # Lowercase + ctrl = re.sub(r'\((\d+)\)', r'.\1', ctrl) # ac-2(5) → ac-2.5 + + if current_cis_id not in cis_to_nist: + cis_to_nist[current_cis_id] = set() + cis_to_nist[current_cis_id].add(ctrl) + + print(f" Found {len(cis_to_nist)} CIS controls with NIST references") + return cis_to_nist + + def parse_cis_pdf_file(self, pdf_file: Path) -> Dict[str, Set[str]]: + """ + Parse CIS benchmark PDF file to extract NIST references using pdftotext. + + Args: + pdf_file: Path to CIS benchmark PDF file + + Returns: + Dict mapping CIS control ID to set of NIST control IDs + """ + import subprocess + import shutil + + # Check if pdftotext is available + if not shutil.which('pdftotext'): + print(" Skipping PDF parsing (pdftotext not available)") + return {} + + print(f" Parsing {pdf_file.name}...") + + try: + # Use pdftotext to extract text + result = subprocess.run( + ['pdftotext', '-layout', str(pdf_file), '-'], + capture_output=True, + text=True, + timeout=60 + ) + + if result.returncode != 0: + print(f" Warning: pdftotext failed with code {result.returncode}") + return {} + + text = result.stdout + cis_to_nist = {} + current_cis_id = None + + # Process line by line + for line in text.split('\n'): + # Check for CIS control header + # Patterns: "1.1.1.1 Ensure..." or variations + cis_header = re.search(r'\b([0-9]+\.[0-9.]+)\s+Ensure', line) + if cis_header: + current_cis_id = cis_header.group(1) + continue + + # Check for NIST reference + nist_match = re.search( + r'NIST SP 800-53(?:\s+Rev\.?\s*\d+)?(?:\s*[:]{1,2})\s*([A-Z]{2}-[0-9]+(?:\([0-9]+\))?)(?:\s+[a-z])?', + line + ) + + if nist_match and current_cis_id: + ctrl = nist_match.group(1) + # Convert to OSCAL format + ctrl = ctrl.lower() + ctrl = re.sub(r'\((\d+)\)', r'.\1', ctrl) + + if current_cis_id not in cis_to_nist: + cis_to_nist[current_cis_id] = set() + cis_to_nist[current_cis_id].add(ctrl) + + print(f" Found {len(cis_to_nist)} CIS controls with NIST references") + return cis_to_nist + + except subprocess.TimeoutExpired: + print(" Warning: PDF parsing timed out") + return {} + except Exception as e: + print(f" Warning: Failed to parse PDF: {e}") + return {} + + def merge_nist_mappings( + self, + md_mapping: Dict[str, Set[str]], + pdf_mapping: Dict[str, Set[str]] + ) -> Dict[str, Set[str]]: + """ + Merge NIST mappings from MD and PDF sources. + + Args: + md_mapping: CIS→NIST from MD file + pdf_mapping: CIS→NIST from PDF file + + Returns: + Merged mapping with all unique NIST controls per CIS control + """ + merged = defaultdict(set) + + # Add MD mappings + for cis_id, nist_controls in md_mapping.items(): + merged[cis_id].update(nist_controls) + + # Add PDF mappings + for cis_id, nist_controls in pdf_mapping.items(): + merged[cis_id].update(nist_controls) + + return dict(merged) + + def parse_cis_control_file(self, control_file: Path) -> Dict[str, List[str]]: + """ + Parse CIS control YAML file to extract rule mappings. + + Args: + control_file: Path to CIS control YAML file + + Returns: + Dict mapping CIS control ID to list of rules + e.g., {"1.1.1.1": ["kernel_module_cramfs_disabled"]} + """ + print(f" Parsing {control_file.name}...") + + with open(control_file, 'r', encoding='utf-8') as f: + control_data = self.yaml.load(f) + + cis_to_rules = {} + + for control in control_data.get('controls', []): + cis_id = control.get('id') + rules = control.get('rules', []) + + if cis_id and rules: + # Filter out variable assignments (contain '=') + rule_ids = [r for r in rules if '=' not in r] + if rule_ids: + cis_to_rules[cis_id] = rule_ids + + print(f" Found {len(cis_to_rules)} CIS controls with rules") + return cis_to_rules + + def parse_cis_control_file_variables(self, control_file: Path) -> Dict[str, List[str]]: + """ + Parse CIS control YAML file to extract variable assignments. + + Args: + control_file: Path to CIS control YAML file + + Returns: + Dict mapping CIS control ID to list of variable assignments + e.g., {"enable_authselect": ["var_authselect_profile=sssd"]} + """ + print(f" Parsing variables from {control_file.name}...") + + with open(control_file, 'r', encoding='utf-8') as f: + control_data = self.yaml.load(f) + + cis_to_vars = {} + + for control in control_data.get('controls', []): + cis_id = control.get('id') + rules = control.get('rules', []) + + if cis_id and rules: + # Extract only variable assignments (contain '=') + var_assignments = [r for r in rules if '=' in r] + if var_assignments: + cis_to_vars[cis_id] = var_assignments + + print(f" Found {len(cis_to_vars)} CIS controls with variables") + return cis_to_vars + + def build_rule_to_nist_mapping( + self, + cis_to_nist: Dict[str, Set[str]], + cis_to_rules: Dict[str, List[str]] + ) -> Dict[str, Set[str]]: + """ + Combine CIS→NIST and CIS→rules mappings to create rule→NIST mapping. + + Args: + cis_to_nist: CIS control ID → NIST control IDs + cis_to_rules: CIS control ID → rule IDs + + Returns: + Dict mapping rule ID to set of NIST control IDs + """ + rule_to_nist = defaultdict(set) + + for cis_id, nist_controls in cis_to_nist.items(): + if cis_id in cis_to_rules: + rules = cis_to_rules[cis_id] + for rule_id in rules: + rule_to_nist[rule_id].update(nist_controls) + + return dict(rule_to_nist) + + def build_variable_to_nist_mapping( + self, + cis_to_nist: Dict[str, Set[str]], + cis_to_vars: Dict[str, List[str]] + ) -> Dict[str, Set[str]]: + """ + Combine CIS→NIST and CIS→variables mappings to create variable→NIST mapping. + + Args: + cis_to_nist: CIS control ID → NIST control IDs + cis_to_vars: CIS control ID → variable assignments + + Returns: + Dict mapping variable assignment to set of NIST control IDs + """ + var_to_nist = defaultdict(set) + + for cis_id, nist_controls in cis_to_nist.items(): + if cis_id in cis_to_vars: + variables = cis_to_vars[cis_id] + for var_assignment in variables: + var_to_nist[var_assignment].update(nist_controls) + + return dict(var_to_nist) + + def harvest_from_product( + self, + product: str, + rhel_version: str + ) -> tuple[Dict[str, Set[str]], Dict[str, Set[str]]]: + """ + Harvest NIST mappings for a specific product. + + Args: + product: Product ID (e.g., "rhel9") + rhel_version: RHEL version for file matching (e.g., "9") + + Returns: + Tuple of (rule_to_nist, var_to_nist) mappings + """ + print(f"\nHarvesting from {product}...") + + # Find CIS PDF file + pdf_pattern = f"CIS_Red_Hat_Enterprise_Linux_{rhel_version}_Benchmark_*.pdf" + pdf_files = list(self.nist_sync_dir.glob(pdf_pattern)) + + # Find CIS control file + control_file = self.repo_root / "products" / product / "controls" / f"cis_{product}.yml" + + if not control_file.exists(): + print(f" Warning: CIS control file not found at {control_file}") + return {}, {} + + # Parse MD file if available + # NOTE: MD files have formatting issues - skip MD parsing and use PDF only + # if md_files: + # md_mapping = self.parse_cis_md_file(md_files[0]) + # else: + # print(f" Warning: No CIS MD file found matching {md_pattern}") + print(" Skipping MD parsing (using PDF only for more reliable NIST reference extraction)") + + # Parse PDF file if available + pdf_mapping = {} + if pdf_files: + pdf_mapping = self.parse_cis_pdf_file(pdf_files[0]) + else: + print(f" Warning: No CIS PDF file found matching {pdf_pattern}") + + # Use PDF mappings only + print(" Using PDF mappings...") + cis_to_nist = pdf_mapping + print(f" ✓ Total: {len(cis_to_nist)} CIS controls with NIST references") + + # Parse control file to get CIS→rules mapping + cis_to_rules = self.parse_cis_control_file(control_file) + + # Parse control file to get CIS→variables mapping + cis_to_vars = self.parse_cis_control_file_variables(control_file) + + # Combine to get rule→NIST mapping + rule_to_nist = self.build_rule_to_nist_mapping(cis_to_nist, cis_to_rules) + + # Combine to get variable→NIST mapping + var_to_nist = self.build_variable_to_nist_mapping(cis_to_nist, cis_to_vars) + + print(f" ✓ Mapped {len(rule_to_nist)} rules to NIST controls") + print(f" ✓ Mapped {len(var_to_nist)} variables to NIST controls") + + return rule_to_nist, var_to_nist + + def merge_rule_mappings( + self, + *mappings: Dict[str, Set[str]] + ) -> Dict[str, Set[str]]: + """ + Merge multiple rule→NIST mappings. + + Args: + *mappings: Variable number of rule→NIST mapping dicts + + Returns: + Combined dict with all unique mappings + """ + merged = defaultdict(set) + + for mapping in mappings: + for rule_id, nist_controls in mapping.items(): + merged[rule_id].update(nist_controls) + + return dict(merged) + + def save_mapping_cache( + self, + rule_to_nist: Dict[str, Set[str]], + var_to_nist: Dict[str, Set[str]] + ): + """Save rule→NIST and variable→NIST mappings to JSON cache file.""" + import json + + # Convert sets to lists for JSON serialization + cache_data = { + 'rules': { + rule_id: sorted(list(nist_controls)) + for rule_id, nist_controls in rule_to_nist.items() + }, + 'variables': { + var_id: sorted(list(nist_controls)) + for var_id, nist_controls in var_to_nist.items() + } + } + + self.mapping_cache_file.parent.mkdir(parents=True, exist_ok=True) + + with open(self.mapping_cache_file, 'w', encoding='utf-8') as f: + json.dump(cache_data, f, indent=2, sort_keys=True) + + print(f"\n✓ Saved mapping cache to {self.mapping_cache_file}") + print(f" {len(cache_data['rules'])} rules mapped to NIST controls") + print(f" {len(cache_data['variables'])} variables mapped to NIST controls") + + @staticmethod + def load_mapping_cache(cache_file: Path) -> Dict[str, Set[str]]: + """Load rule→NIST mapping from JSON cache file.""" + import json + + if not cache_file.exists(): + return {} + + with open(cache_file, 'r', encoding='utf-8') as f: + cache_data = json.load(f) + + # Convert lists back to sets + return { + rule_id: set(nist_controls) + for rule_id, nist_controls in cache_data.items() + } + + def update_nist_control_file( + self, + rule_to_nist: Dict[str, Set[str]], + dry_run: bool = False + ): + """ + Update nist_800_53.yml control file with rule mappings. + + Args: + rule_to_nist: Dict mapping rule ID to set of NIST control IDs + dry_run: If True, show changes without saving + """ + print("\nUpdating NIST control file...") + + # Load control file + with open(self.nist_control_file, 'r', encoding='utf-8') as f: + control_data = self.yaml.load(f) + + # Create lookup of controls by ID + controls_by_id = { + ctrl['id']: ctrl + for ctrl in control_data.get('controls', []) + } + + # Build reverse mapping: NIST control ID → rules + nist_to_rules = defaultdict(set) + for rule_id, nist_controls in rule_to_nist.items(): + for nist_id in nist_controls: + nist_to_rules[nist_id].add(rule_id) + + # Update controls + rules_added = 0 + controls_updated = 0 + controls_not_found = [] + + for nist_id, rules in sorted(nist_to_rules.items()): + if nist_id in controls_by_id: + control = controls_by_id[nist_id] + existing_rules = set(control.get('rules', [])) + + # Filter out variable assignments from existing rules + existing_rules = {r for r in existing_rules if '=' not in r} + + # Add new rules + new_rules = rules - existing_rules + if new_rules: + if 'rules' not in control: + control['rules'] = [] + + # Add new rules (sorted) + control['rules'].extend(sorted(new_rules)) + # Re-sort all rules + control['rules'] = sorted(set(r for r in control['rules'] if '=' not in r)) + + # Update status to automated if rules are present + if control.get('status') == 'pending' and control['rules']: + control['status'] = 'automated' + + rules_added += len(new_rules) + controls_updated += 1 + + if dry_run: + print(f" {nist_id}: would add {len(new_rules)} rules") + else: + controls_not_found.append(nist_id) + + print(f" ✓ Updated {controls_updated} controls") + print(f" ✓ Added {rules_added} rule mappings") + + if controls_not_found: + print(f" ! {len(controls_not_found)} NIST controls not found in control file:") + for nist_id in sorted(controls_not_found)[:10]: + print(f" {nist_id}") + if len(controls_not_found) > 10: + print(f" ... and {len(controls_not_found) - 10} more") + + if not dry_run: + # Save control file + print(f" Saving to {self.nist_control_file}...") + with open(self.nist_control_file, 'w', encoding='utf-8') as f: + self.yaml.dump(control_data, f) + print(" ✓ Saved") + else: + print(" (Dry run - no changes saved)") + + +def main(): + """Main entry point.""" + import argparse + + parser = argparse.ArgumentParser( + description='Harvest NIST mappings from CIS benchmarks' + ) + parser.add_argument( + '--products', + nargs='+', + default=['rhel8', 'rhel9', 'rhel10'], + help='Products to harvest from (default: rhel8 rhel9 rhel10)' + ) + parser.add_argument( + '--repo-root', + type=Path, + default=Path(__file__).parent.parent.parent, + help='Path to repository root (default: auto-detect)' + ) + parser.add_argument( + '--dry-run', + action='store_true', + help='Show what would be changed without saving' + ) + + args = parser.parse_args() + + harvester = CISNISTHarvester(args.repo_root) + + # Product to RHEL version mapping + product_to_version = { + 'rhel8': '8', + 'rhel9': '9', + 'rhel10': '10' + } + + print("╔════════════════════════════════════════════════════════════╗") + print("║ CIS NIST Mapping Harvester ║") + print("╚════════════════════════════════════════════════════════════╝") + + try: + # Harvest from each product + all_rule_mappings = [] + all_var_mappings = [] + for product in args.products: + if product not in product_to_version: + print(f"Warning: Unknown product {product}, skipping") + continue + + rhel_version = product_to_version[product] + rule_mapping, var_mapping = harvester.harvest_from_product(product, rhel_version) + all_rule_mappings.append(rule_mapping) + all_var_mappings.append(var_mapping) + + # Merge all mappings + print("\nMerging mappings from all products...") + merged_rules = harvester.merge_rule_mappings(*all_rule_mappings) + merged_vars = harvester.merge_rule_mappings(*all_var_mappings) # Same merge logic + print(f" ✓ Total unique rules: {len(merged_rules)}") + print(f" ✓ Total unique variables: {len(merged_vars)}") + + # Save mapping cache (always save, even in dry-run) + harvester.save_mapping_cache(merged_rules, merged_vars) + + # Note: update_nist_control_file is not used in the new workflow + # The sync_nist.py script handles updating the control file + + print("\n✓ Harvest complete!") + print(f"\nMapping cache saved to: {harvester.mapping_cache_file}") + print("This cache can be used by sync_nist.py to populate rule and variable mappings.") + return 0 + + except Exception as e: + print(f"\n✗ Harvest failed: {e}", file=sys.stderr) + import traceback + traceback.print_exc() + return 1 + + +if __name__ == "__main__": + sys.exit(main()) diff --git a/utils/nist_sync/nist_viewer_template.html b/utils/nist_sync/nist_viewer_template.html new file mode 100644 index 000000000000..f899fdc25535 --- /dev/null +++ b/utils/nist_sync/nist_viewer_template.html @@ -0,0 +1,1414 @@ + + + + + + NIST 800-53 Control Viewer & Gap Analysis + + + +
    +
    +

    NIST 800-53 Control Viewer & Gap Analysis

    +
    +
    + + +
    + + +
    +
    + +
    + +
    + +
    + + +
    +
    +
    +
    + +
    +
    + + + +

    Select a control to view details

    +

    Choose a control from the list to see its description, rules, and OSCAL metadata

    +
    +
    +
    +
    + + + + diff --git a/utils/nist_sync/requirements.txt b/utils/nist_sync/requirements.txt new file mode 100644 index 000000000000..ba408a73e745 --- /dev/null +++ b/utils/nist_sync/requirements.txt @@ -0,0 +1,2 @@ +ruamel.yaml>=0.18.0 +requests>=2.31.0 diff --git a/utils/nist_sync/sync_nist_split.py b/utils/nist_sync/sync_nist_split.py new file mode 100755 index 000000000000..579684c460a2 --- /dev/null +++ b/utils/nist_sync/sync_nist_split.py @@ -0,0 +1,710 @@ +#!/usr/bin/env python3 +""" +NIST 800-53 Split Control File Synchronization (Product-Specific) + +Generates product-specific NIST 800-53 control files in SPLIT-BY-FAMILY format: + - shared/references/controls/nist_800_53_cis_reference_{product}.yml (top-level metadata) + - shared/references/controls/nist_800_53_cis_reference_{product}/*.yml (family files) + +Each product (rhel8, rhel9, rhel10) gets its own control file set with only +rules/variables available for that specific product. No Jinja2 guards needed. + +OSCAL metadata (description, parameters, guidance, related_controls) is NOT +included in control files. This data can be retrieved separately from the +OSCAL catalog when needed (e.g., for web application display). + +The split format is supported natively by the build system: + - Policy class loads from directory if it exists + - Automatically merges all .yml files in the directory + - See: ssg/controls.py:661-662 + +Architecture: + 1. Load CIS control file for specific product + 2. Generate control data from OSCAL catalog (structure only, no metadata) + 3. Filter rules/variables to only those available for target product + 4. Split by control family (AC, AU, CM, etc.) + 5. Write product-specific top-level metadata file + 6. Write product-specific family files +""" + +import io +import json +import sys +from pathlib import Path +from typing import Dict, List, Set +from collections import defaultdict +from ruamel.yaml.scalarstring import LiteralScalarString + +try: + from ruamel.yaml import YAML +except ImportError: + print("Error: ruamel.yaml is required", file=sys.stderr) + sys.exit(1) + + +class NISTSplitSync: + """Synchronizes NIST 800-53 controls in split-by-family format.""" + + # NIST 800-53 Rev 5 control families + FAMILIES = { + 'ac': 'Access Control', + 'at': 'Awareness and Training', + 'au': 'Audit and Accountability', + 'ca': 'Assessment, Authorization, and Monitoring', + 'cm': 'Configuration Management', + 'cp': 'Contingency Planning', + 'ia': 'Identification and Authentication', + 'ir': 'Incident Response', + 'ma': 'Maintenance', + 'mp': 'Media Protection', + 'pe': 'Physical and Environmental Protection', + 'pl': 'Planning', + 'pm': 'Program Management', + 'ps': 'Personnel Security', + 'pt': 'PII Processing and Transparency', + 'ra': 'Risk Assessment', + 'sa': 'System and Services Acquisition', + 'sc': 'System and Communications Protection', + 'si': 'System and Information Integrity', + 'sr': 'Supply Chain Risk Management', + 'other': 'CIS Items Without NIST Mapping', + } + + def __init__(self, repo_root: Path, product: str = None, mode='reference', flat_structure=False): + """ + Initialize syncer. + + Args: + repo_root: Repository root path + product: Target product (rhel8, rhel9, rhel10, etc.) + mode: 'reference' (auto-generated) or 'real' (human-maintained) + flat_structure: If True, save family files in same directory with prefix + """ + self.repo_root = repo_root + self.product = product + self.mode = mode + self.flat_structure = flat_structure + self.data_dir = repo_root / "utils" / "nist_sync" / "data" + + # Set paths based on mode and product + if mode == 'reference': + if product: + self.top_level_file = repo_root / "shared" / "references" / "controls" / f"nist_800_53_cis_reference_{product}.yml" + self.family_dir = repo_root / "shared" / "references" / "controls" / f"nist_800_53_cis_reference_{product}" + self.file_prefix = "" + else: + # Legacy non-product-specific reference (deprecated) + self.top_level_file = repo_root / "shared" / "references" / "controls" / "nist_800_53_cis_reference.yml" + if flat_structure: + self.family_dir = repo_root / "shared" / "references" / "controls" + self.file_prefix = "nist_800_53_cis_reference_" + else: + self.family_dir = repo_root / "shared" / "references" / "controls" / "nist_800_53_cis_reference" + self.file_prefix = "" + else: # mode == 'real' + if product: + # Product-specific real files (in products/{product}/controls/) + product_dir = repo_root / "products" / product / "controls" + self.top_level_file = product_dir / "nist_800_53.yml" + self.family_dir = product_dir / "nist_800_53" + self.file_prefix = "" + else: + # Legacy global real files (deprecated) + self.top_level_file = repo_root / "controls" / "nist_800_53.yml" + if flat_structure: + self.family_dir = repo_root / "controls" + self.file_prefix = "nist_800_53_" + else: + self.family_dir = repo_root / "controls" / "nist_800_53" + self.file_prefix = "" + + # YAML handler + self.yaml = YAML() + self.yaml.preserve_quotes = False + self.yaml.default_flow_style = False + self.yaml.width = 99 + self.yaml.indent(mapping=4, sequence=6, offset=4) + + def extract_family(self, control_id: str) -> str: + """Extract family prefix from control ID.""" + if '-' not in control_id: + return 'other' + family = control_id.split('-')[0].lower() + return family if family in self.FAMILIES else 'other' + + def load_oscal_catalog(self) -> Dict: + """Load NIST OSCAL catalog.""" + catalog_file = self.data_dir / "nist_800_53_rev5_catalog.json" + with open(catalog_file, 'r') as f: + return json.load(f) + + def load_baselines(self) -> Dict[str, Set[str]]: + """Load LOW/MODERATE/HIGH baselines.""" + baselines = {'low': set(), 'moderate': set(), 'high': set()} + + for level in ['low', 'moderate', 'high']: + filepath = self.data_dir / f"nist_800_53_rev5_{level}_baseline.json" + if not filepath.exists(): + continue + + with open(filepath, 'r') as f: + data = json.load(f) + + # Extract control IDs from imports + for imp in data.get('profile', {}).get('imports', []): + for inc in imp.get('include-controls', []): + if 'with-ids' in inc: + baselines[level].update(inc['with-ids']) + + return baselines + + def load_all_cis_items_from_control_files(self) -> Set[str]: + """Scan CIS control files to find all CIS rules/variables for specified product. + + Returns: + Set of rule/variable names (variables have values stripped: var_name=value → var_name) + """ + all_items = set() + + # If product is specified, only load from that product + products = [self.product] if self.product else ['rhel8', 'rhel9', 'rhel10'] + + for product in products: + control_file = self.repo_root / "products" / product / "controls" / f"cis_{product}.yml" + if not control_file.exists(): + continue + + with open(control_file) as f: + data = self.yaml.load(f) + + def extract_rules(controls): + """Recursively extract rules from controls.""" + for ctrl in controls: + if 'rules' in ctrl: + for rule in ctrl['rules']: + # Handle both "rule_id" and "var_name=value" formats + if '=' in rule: + rule_id = rule.split('=')[0] + else: + rule_id = rule.lstrip('!') # Remove exclusion prefix + all_items.add(rule_id) + + # Recursively process nested controls + if 'controls' in ctrl: + extract_rules(ctrl['controls']) + + extract_rules(data.get('controls', [])) + + return all_items + + def load_all_cis_items_with_values(self) -> Dict[str, Set[str]]: + """Scan CIS control files to find all rules/variables WITH their assigned values for specified product. + + Returns: + Dict mapping variable/rule name to set of full assignments (e.g., {'var_x': {'var_x=1', 'var_x=2'}}) + """ + items_with_values = defaultdict(set) + + # If product is specified, only load from that product + products = [self.product] if self.product else ['rhel8', 'rhel9', 'rhel10'] + + for product in products: + control_file = self.repo_root / "products" / product / "controls" / f"cis_{product}.yml" + if not control_file.exists(): + continue + + with open(control_file) as f: + data = self.yaml.load(f) + + def extract_rules(controls): + """Recursively extract rules from controls.""" + for ctrl in controls: + if 'rules' in ctrl: + for rule in ctrl['rules']: + rule = rule.lstrip('!') # Remove exclusion prefix + if '=' in rule: + # Variable assignment: store both the name and full assignment + var_name = rule.split('=')[0] + items_with_values[var_name].add(rule) + else: + # Regular rule: store as-is + items_with_values[rule].add(rule) + + # Recursively process nested controls + if 'controls' in ctrl: + extract_rules(ctrl['controls']) + + extract_rules(data.get('controls', [])) + + return items_with_values + + def load_cis_mappings(self) -> tuple: + """Load CIS→NIST mappings and invert to NIST→CIS.""" + mapping_file = self.data_dir / "cis_nist_mappings.json" + + if not mapping_file.exists(): + print(f" No CIS mappings found at {mapping_file}") + return {}, {}, set() + + with open(mapping_file, 'r') as f: + data = json.load(f) + + # Handle existing format: {"rules": {...}, "variables": {...}} + rule_to_nist = {} + var_to_nist = {} + + if 'rules' in data and 'variables' in data: + # New format + rule_to_nist = data['rules'] + var_to_nist = data['variables'] + elif 'rules' in data: + # Old format (rules only) + rule_to_nist = data['rules'] + else: + # Very old format (direct dict) + rule_to_nist = data + + # Invert: rule→nist to nist→rules + nist_to_rules = defaultdict(set) + nist_to_vars = defaultdict(set) + mapped_items = set() + + for rule_id, nist_controls in rule_to_nist.items(): + mapped_items.add(rule_id) + for nist_id in nist_controls: + nist_to_rules[nist_id].add(rule_id) + + for var_id, nist_controls in var_to_nist.items(): + mapped_items.add(var_id) + for nist_id in nist_controls: + nist_to_vars[nist_id].add(var_id) + + return nist_to_rules, nist_to_vars, mapped_items + + @staticmethod + def escape_jinja_syntax(text: str) -> str: + """Replace {{ }} with [[ ]] to avoid Jinja2 macro expansion conflicts.""" + if not text: + return text + return text.replace('{{', '[[').replace('}}', ']]') + + def extract_statement(self, parts: List[Dict], indent=0) -> str: + """Extract and format control statement from OSCAL parts.""" + lines = [] + + for part in parts: + if part.get('name') == 'statement': + # Top-level statement + if 'prose' in part: + lines.append(self.escape_jinja_syntax(part['prose'])) + + # Process sub-parts (a, b, c, etc.) + if 'parts' in part: + for subpart in part['parts']: + label = subpart.get('id', '') + prose = subpart.get('prose', '') + + # Extract the letter/number from id (e.g., "ac-2_smt.a" → "a") + if label and '.' in label: + label = label.split('.')[-1] + + if label and prose: + lines.append(f" {label}. {self.escape_jinja_syntax(prose)}") + elif prose: + lines.append(f" {self.escape_jinja_syntax(prose)}") + + # Handle nested sub-parts (a.1, a.2, etc.) + if 'parts' in subpart: + for nested in subpart['parts']: + nested_label = nested.get('id', '').split('.')[-1] + nested_prose = nested.get('prose', '') + if nested_label and nested_prose: + lines.append(f" {nested_label}. {self.escape_jinja_syntax(nested_prose)}") + + return '\n'.join(lines) if lines else '' + + def extract_parameters(self, ctrl_data: Dict) -> List[Dict]: + """Extract organization-defined parameters (ODPs) from control.""" + parameters = [] + + for param in ctrl_data.get('params', []): + param_info = { + 'id': param.get('id', ''), + 'label': self.escape_jinja_syntax(param.get('label', '')) + } + + # Extract guidelines/constraints if available + if 'guidelines' in param: + guidelines = [] + for guideline in param['guidelines']: + if 'prose' in guideline: + guidelines.append(self.escape_jinja_syntax(guideline['prose'])) + if guidelines: + param_info['guidelines'] = guidelines + + # Extract select options if available + if 'select' in param: + select = param['select'] + if 'choice' in select: + param_info['choices'] = [self.escape_jinja_syntax(c) for c in select['choice']] + + parameters.append(param_info) + + return parameters + + def extract_guidance(self, parts: List[Dict]) -> str: + """Extract guidance/discussion text from control.""" + for part in parts: + if part.get('name') == 'guidance' and 'prose' in part: + return self.escape_jinja_syntax(part['prose']) + return '' + + def extract_related_controls(self, links: List[Dict]) -> List[str]: + """Extract related control references.""" + related = [] + for link in links: + if link.get('rel') == 'related' and 'href' in link: + # Extract control ID from href (e.g., "#ac-3" → "ac-3") + ctrl_id = link['href'].replace('#', '').lower() + related.append(ctrl_id) + return related + + def extract_controls_from_catalog(self, catalog: Dict) -> List[Dict]: + """Extract all controls with full OSCAL metadata from catalog.""" + controls = [] + + def process_control(ctrl_data, parent_id=None): + """Recursively process controls and enhancements.""" + ctrl_id = ctrl_data.get('id', '').lower() + title = ctrl_data.get('title', '') + + control = { + 'id': ctrl_id, + 'title': title + } + + # Extract full statement (with all sub-parts a, b, c, etc.) + parts = ctrl_data.get('parts', []) + statement = self.extract_statement(parts) + if statement: + control['description'] = statement + + # Extract parameters (ODPs - Organization-Defined Parameters) + parameters = self.extract_parameters(ctrl_data) + if parameters: + control['parameters'] = parameters + + # Extract guidance + guidance = self.extract_guidance(parts) + if guidance: + control['guidance'] = guidance + + # Extract related controls + links = ctrl_data.get('links', []) + related = self.extract_related_controls(links) + if related: + control['related_controls'] = related + + controls.append(control) + + # Process enhancements (sub-controls) + for subctrl in ctrl_data.get('controls', []): + process_control(subctrl, parent_id=ctrl_id) + + # Process top-level controls and groups + for group in catalog.get('catalog', {}).get('groups', []): + for ctrl in group.get('controls', []): + process_control(ctrl) + + return controls + + def generate_controls(self, verbose=False) -> Dict: + """Generate control data from OSCAL + CIS mappings.""" + print("Phase 1: Loading OSCAL catalog and baselines...") + catalog = self.load_oscal_catalog() + baselines = self.load_baselines() + print(f" Found {sum(len(b) for b in baselines.values())} total baseline assignments") + + print("Phase 2: Loading CIS mappings...") + nist_to_rules, nist_to_vars, mapped_items = self.load_cis_mappings() + print(f" Loaded {len(nist_to_rules)} rule mappings, {len(nist_to_vars)} variable mappings") + + print("Phase 3: Scanning CIS control files for product-specific rules...") + all_cis_items = self.load_all_cis_items_from_control_files() + all_cis_items_with_values = self.load_all_cis_items_with_values() + product_info = f" for {self.product}" if self.product else " across all products" + print(f" Found {len(all_cis_items)} total CIS rules/variables{product_info}") + print(f" Items WITH NIST mappings: {len(mapped_items)}") + print(f" Items WITHOUT NIST mappings: {len(all_cis_items - mapped_items)}") + + print("Phase 4: Extracting controls from OSCAL...") + oscal_controls = self.extract_controls_from_catalog(catalog) + print(f" Found {len(oscal_controls)} controls in catalog") + + print("Phase 5: Building control data...") + controls_by_family = defaultdict(list) + + for ctrl in oscal_controls: + ctrl_id = ctrl['id'] + + # Determine minimum applicable level (inheritance handles the rest: + # moderate inherits low, high inherits moderate) + levels = [] + for level in ['low', 'moderate', 'high']: + if ctrl_id in baselines[level]: + levels.append(level) + break # Only record the minimum level + + # Get CIS rules/vars for this control from mapping file + mapped_rules = nist_to_rules.get(ctrl_id, set()) + mapped_vars = nist_to_vars.get(ctrl_id, set()) + + # Filter to only rules/variables that exist in target product + # For product-specific mode: only include rules present in target product + # For non-product mode: include all rules (legacy behavior) + if self.product: + # Filter rules: only include if in target product's CIS control file + filtered_rules = [r for r in mapped_rules if r in all_cis_items] + + # Filter variables: only include the specific assignment for target product + filtered_vars = [] + for var_name in mapped_vars: + if var_name in all_cis_items_with_values: + # Get all assignments for this variable + assignments = all_cis_items_with_values[var_name] + # Add all assignments (should only be one per product) + filtered_vars.extend(sorted(assignments)) + + rules = sorted(filtered_rules) + vars = filtered_vars + else: + # Legacy: include all rules/vars + rules = sorted(mapped_rules) + vars = sorted(mapped_vars) + + selections = vars + rules # Variables first + + # Build control entry (WITHOUT OSCAL metadata - only structure) + # OSCAL metadata (description, parameters, guidance, related_controls) + # can be retrieved separately from the OSCAL catalog when needed + control_entry = { + 'id': ctrl_id, + 'title': ctrl['title'] + } + + if levels: + control_entry['levels'] = levels + + if selections: + control_entry['rules'] = selections + control_entry['status'] = 'automated' + else: + control_entry['rules'] = [] + control_entry['status'] = 'pending' + + # Group by family + family = self.extract_family(ctrl_id) + controls_by_family[family].append(control_entry) + + # Add unmapped CIS items (items in CIS control files but not in mapping file) + unmapped_item_names = all_cis_items - mapped_items + + # Build list of unmapped items WITH their values (for variables) + unmapped_items_full = [] + for item_name in sorted(unmapped_item_names): + if item_name in all_cis_items_with_values: + # Get all assignments for this item (may have multiple values across products) + assignments = all_cis_items_with_values[item_name] + if len(assignments) == 1: + # Single value: use it directly + unmapped_items_full.extend(assignments) + else: + # Multiple values: keep them all (guards will be added later) + unmapped_items_full.extend(sorted(assignments)) + else: + # No value found (shouldn't happen, but fallback to name) + unmapped_items_full.append(item_name) + + if unmapped_items_full: + controls_by_family['other'].append({ + 'id': 'CIS_UNMAPPED', + 'title': 'CIS Benchmark Items Without NIST 800-53 Mapping', + 'notes': LiteralScalarString( + 'These CIS items do not have explicit NIST 800-53 mappings in the benchmark PDFs.\n' + 'They are included here to ensure complete CIS coverage when using nist_800_53:all.\n' + ), + 'rules': unmapped_items_full, + 'status': 'automated' + }) + print(f" Added {len(unmapped_item_names)} unmapped CIS items ({len(unmapped_items_full)} total assignments) to 'other' family") + + print(f" Generated {sum(len(c) for c in controls_by_family.values())} controls across {len(controls_by_family)} families") + + return controls_by_family + + def _dump_yaml(self, data, f): + """Dump YAML to file, stripping trailing whitespace from each line.""" + buf = io.StringIO() + self.yaml.dump(data, buf) + content = buf.getvalue() + lines = content.splitlines() + cleaned = '\n'.join(line.rstrip() for line in lines) + if content.endswith('\n'): + cleaned += '\n' + f.write(cleaned) + + def save_split_format(self, controls_by_family: Dict, verbose=False): + """Save controls in split-by-family format.""" + print(f"\nPhase 6: Saving split format to {self.family_dir}...") + + # Create family directory if needed + if not self.flat_structure: + self.family_dir.mkdir(parents=True, exist_ok=True) + + # Write top-level metadata file + if self.product: + # Product-specific metadata + if self.mode == 'reference': + metadata = { + 'policy': f'NIST 800-53 Revision 5 CIS Reference ({self.product.upper()})', + 'title': f'NIST Special Publication 800-53 Revision 5 CIS Reference for {self.product.upper()}', + 'id': f'nist_800_53_cis_reference_{self.product}', + 'version': 'Revision 5', + 'source': 'https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final', + 'product': self.product, + } + else: + metadata = { + 'policy': f'NIST 800-53 Revision 5 ({self.product.upper()})', + 'title': f'NIST Special Publication 800-53 Revision 5 for {self.product.upper()}', + 'id': 'nist_800_53', + 'version': 'Revision 5', + 'source': 'https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final', + 'product': self.product, + } + else: + # Legacy non-product-specific metadata (deprecated) + metadata = { + 'policy': 'NIST 800-53 Revision 5 CIS Reference' if self.mode == 'reference' else 'NIST 800-53 Revision 5', + 'title': 'NIST Special Publication 800-53 Revision 5 CIS Reference' if self.mode == 'reference' else 'NIST Special Publication 800-53 Revision 5', + 'id': 'nist_800_53_cis_reference' if self.mode == 'reference' else 'nist_800_53', + 'version': 'Revision 5', + 'source': 'https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final', + } + + # Add controls_dir (tells build system where to find family files) + if self.flat_structure: + metadata['controls_dir'] = '.' + else: + # For subdirectory structure, specify the directory name + if self.product and self.mode == 'reference': + dir_name = f'nist_800_53_cis_reference_{self.product}' + elif self.mode == 'reference': + dir_name = 'nist_800_53_cis_reference' + else: + dir_name = 'nist_800_53' + metadata['controls_dir'] = dir_name + + # Add levels with inheritance: moderate ⊇ low, high ⊇ moderate + metadata['levels'] = [ + {'id': 'low'}, + {'id': 'moderate', 'inherits_from': ['low']}, + {'id': 'high', 'inherits_from': ['moderate']} + ] + + print(f" Writing top-level file: {self.top_level_file}") + with open(self.top_level_file, 'w') as f: + if self.mode == 'reference': + if self.product: + f.write(f"# AUTO-GENERATED Product-Specific CIS Reference File ({self.product.upper()})\n") + f.write("#\n") + f.write(f"# This file contains only metadata for {self.product.upper()}.\n") + f.write(f"# Control families are in nist_800_53_cis_reference_{self.product}/\n") + f.write("# Do NOT edit manually. Updated by weekly sync workflow.\n") + f.write("#\n") + f.write("# OSCAL metadata (description, parameters, guidance, related_controls) is NOT\n") + f.write("# included in control files. Retrieve from OSCAL catalog when needed.\n") + f.write("#\n") + elif self.flat_structure: + f.write("# AUTO-GENERATED CIS Reference File\n") + f.write("#\n") + f.write("# This file contains only metadata. Family files are in the same directory.\n") + f.write("# Do NOT edit manually. Updated by weekly sync workflow.\n") + f.write("#\n") + else: + f.write("# AUTO-GENERATED CIS Reference File\n") + f.write("#\n") + f.write("# This file contains only metadata. Control families are in nist_800_53_cis_reference/\n") + f.write("# Do NOT edit manually. Updated by weekly sync workflow.\n") + f.write("#\n") + self._dump_yaml(metadata, f) + + # Write family files + for family, controls in sorted(controls_by_family.items()): + family_file = self.family_dir / f"{self.file_prefix}{family}.yml" + family_title = self.FAMILIES.get(family, family.upper()) + + print(f" Writing {family.upper()}: {len(controls)} controls → {family_file}") + + with open(family_file, 'w') as f: + f.write(f"# NIST 800-53 {family.upper()} Family: {family_title}\n") + self._dump_yaml({'controls': controls}, f) + + print("\n✓ Split format saved!") + print(f" Top-level: {self.top_level_file}") + if self.flat_structure: + print(f" Families: {self.family_dir}/{self.file_prefix}*.yml ({len(controls_by_family)} families)") + else: + print(f" Families: {self.family_dir}/*.yml ({len(controls_by_family)} families)") + + +def main(): + """Main entry point.""" + import argparse + + parser = argparse.ArgumentParser( + description='Generate product-specific NIST 800-53 controls in split format', + epilog='Example: sync_nist_split.py --product rhel9' + ) + parser.add_argument('--product', type=str, required=True, + help='Target product (rhel8, rhel9, rhel10)') + parser.add_argument('--mode', type=str, default='reference', + choices=['reference', 'real'], + help='reference: write to shared/references/ (default); real: write to products/') + parser.add_argument('--flat', action='store_true', + help='Use flat structure (files in same dir with prefix) instead of subdirectory') + args = parser.parse_args() + + repo_root = Path(__file__).parent.parent.parent + + print("╔════════════════════════════════════════════════════════════╗") + print("║ NIST 800-53 Product-Specific Synchronization ║") + print("╚════════════════════════════════════════════════════════════╝") + print() + + print(f"Product: {args.product}") + print(f"Mode: {args.mode}") + print() + + print(f"Generating {args.mode} files for {args.product} (split by family)...") + syncer = NISTSplitSync(repo_root, product=args.product, mode=args.mode, flat_structure=args.flat) + controls_by_family = syncer.generate_controls(verbose=False) + syncer.save_split_format(controls_by_family, verbose=False) + + print() + print("✓ Synchronization complete!") + print() + print("Next steps:") + if args.mode == 'reference': + print(f" 1. Review generated files in shared/references/controls/nist_800_53_cis_reference_{args.product}/") + print(f" 2. Copy to products/{args.product}/controls/nist_800_53/ if needed") + print(" 3. Compare with previous version to detect changes") + else: + print(f" 1. Review generated files in products/{args.product}/controls/nist_800_53/") + print(" 4. Test build: ./build_product", args.product, "--datastream-only") + + return 0 + + +if __name__ == '__main__': + sys.exit(main()) diff --git a/utils/nist_sync/templates/_shared_header.html b/utils/nist_sync/templates/_shared_header.html new file mode 100644 index 000000000000..e2f72f2d1fec --- /dev/null +++ b/utils/nist_sync/templates/_shared_header.html @@ -0,0 +1,35 @@ +
    + +
    + + + + diff --git a/utils/nist_sync/templates/_shared_styles.html b/utils/nist_sync/templates/_shared_styles.html new file mode 100644 index 000000000000..9fd9d91cde07 --- /dev/null +++ b/utils/nist_sync/templates/_shared_styles.html @@ -0,0 +1,262 @@ + diff --git a/utils/nist_sync/templates/control-detail.html b/utils/nist_sync/templates/control-detail.html new file mode 100644 index 000000000000..7c2934b5a49a --- /dev/null +++ b/utils/nist_sync/templates/control-detail.html @@ -0,0 +1,459 @@ + + + + + + NIST 800-53 Control Viewer - Control Detail + + + + + + +
    + + +
    +

    Loading control details...

    +
    +
    + + + + diff --git a/utils/nist_sync/templates/controls.html b/utils/nist_sync/templates/controls.html new file mode 100644 index 000000000000..c1913b390937 --- /dev/null +++ b/utils/nist_sync/templates/controls.html @@ -0,0 +1,383 @@ + + + + + + NIST 800-53 Control Viewer - Controls + + + + + + +
    + + +
    + + + + +
    +
    Loading...
    +
    + +
    +
    +
    +
    + + + + diff --git a/utils/nist_sync/templates/family.html b/utils/nist_sync/templates/family.html new file mode 100644 index 000000000000..2e8c460fbbe9 --- /dev/null +++ b/utils/nist_sync/templates/family.html @@ -0,0 +1,381 @@ + + + + + + NIST 800-53 Control Viewer - Control Families + + + + + + +
    +
    + + +
    + +
    +
    + + +
    + + + + diff --git a/utils/nist_sync/templates/gaps.html b/utils/nist_sync/templates/gaps.html new file mode 100644 index 000000000000..78296337bc28 --- /dev/null +++ b/utils/nist_sync/templates/gaps.html @@ -0,0 +1,309 @@ + + + + + + NIST 800-53 Control Viewer - Gap Analysis + + + + + + +
    + + + +
    +
    +
    0
    +
    Total Gaps
    +
    +
    +
    0
    +
    High Baseline
    +
    +
    +
    0
    +
    Moderate Baseline
    +
    +
    +
    0
    +
    Low Baseline
    +
    +
    + + +
    +
    +
    + 🔴 High Baseline Gaps +
    + 0 +
    +
    + +
    +
    + + +
    +
    +
    + 🟡 Moderate Baseline Gaps +
    + 0 +
    +
    + +
    +
    + + +
    +
    +
    + 🔵 Low Baseline Gaps +
    + 0 +
    +
    + +
    +
    + + +
    +

    Gaps by Control Family

    +
    + +
    +
    +
    + + + + diff --git a/utils/nist_sync/templates/index.html b/utils/nist_sync/templates/index.html new file mode 100644 index 000000000000..855faa049e46 --- /dev/null +++ b/utils/nist_sync/templates/index.html @@ -0,0 +1,268 @@ + + + + + + NIST 800-53 Control Viewer - Dashboard + + + + + +
    + + + +
    +
    +
    0
    +
    Total Controls
    +
    +
    +
    0
    +
    Automated
    +
    +
    +
    0
    +
    Manual
    +
    +
    +
    0
    +
    Inherently Met
    +
    +
    +
    0
    +
    Not Applicable
    +
    +
    +
    0
    +
    Does Not Meet
    +
    +
    +
    0
    +
    Pending
    +
    +
    + + +
    +

    Overall Coverage

    +
    +
    0%
    +
    +

    + 0 of 0 controls have rules +

    +
    + + +
    +

    Product Comparison

    + + + + + + + + + + + + + + +
    ProductTotalAutomatedManualPendingCoverage
    +
    + + +
    +

    Gap Analysis - Controls Without Rules

    +

    + 0 + controls need rule implementation + View All Gaps +

    + + + + + + + + + + + +
    Control IDTitleBaselines
    +
    + + +
    +

    Coverage by Control Family

    + Detailed View +
    + +
    +
    +
    + + + + diff --git a/utils/nist_sync/templates/statistics.html b/utils/nist_sync/templates/statistics.html new file mode 100644 index 000000000000..bf20c3e011df --- /dev/null +++ b/utils/nist_sync/templates/statistics.html @@ -0,0 +1,403 @@ + + + + + + NIST 800-53 Control Viewer - Statistics + + + + + + +
    + + + +
    +

    Product Overview

    +
    +
    +
    0
    +
    Total Controls
    +
    +
    +
    0
    +
    With Rules
    +
    0%
    +
    +
    +
    0
    +
    Without Rules
    +
    0%
    +
    +
    +
    0
    +
    Automated
    +
    0%
    +
    +
    +
    0
    +
    Manual
    +
    0%
    +
    +
    +
    0
    +
    Pending
    +
    0%
    +
    +
    + +
    +

    Implementation Status Distribution

    +
    + +
    +
    +
    + + +
    +

    Baseline Level Breakdown

    +
    + +
    +
    + + +
    +

    Cross-Product Comparison

    + + + + + + + + + + + + + + + + +
    ProductTotalWith RulesWithout RulesAutomatedManualPendingCoverage %
    +
    + + +
    +

    Statistics by Control Family

    + + + + + + + + + + + + + + + +
    FamilyTotalAutomatedManualPendingGapsCoverage %
    +
    +
    + + + + diff --git a/utils/nist_sync/test_workflow_local.sh b/utils/nist_sync/test_workflow_local.sh new file mode 100755 index 000000000000..11dd99be4a07 --- /dev/null +++ b/utils/nist_sync/test_workflow_local.sh @@ -0,0 +1,132 @@ +#!/bin/bash +# Local CIS-NIST Workflow Test +# Simulates the GitHub Actions workflow locally + +set -e + +echo "╔════════════════════════════════════════════════════════════╗" +echo "║ Local CIS-NIST Workflow Test ║" +echo "╚════════════════════════════════════════════════════════════╝" +echo "" + +PRODUCTS="rhel8 rhel9 rhel10" + +# Step 1: Run the complete workflow +echo "Step 1: Running CIS-NIST workflow..." +cd utils/nist_sync +./generate_cis_nist_workflow.sh --products "$PRODUCTS" +cd ../.. + +# Step 2: Verify control files exist +echo "" +echo "Step 2: Verifying control files..." +for product in $PRODUCTS; do + echo "" + echo "Product: $product" + echo "✓ Reference files (for comparison):" + ls -lh "shared/references/controls/nist_800_53_cis_reference_${product}.yml" + echo " Family files:" + ls -1 "shared/references/controls/nist_800_53_cis_reference_${product}/"*.yml | head -5 + echo " ... (21 total families)" + echo "" + echo "✓ Product control files (used in builds):" + ls -lh "products/${product}/controls/nist_800_53.yml" + echo " Family files:" + ls -1 "products/${product}/controls/nist_800_53/"*.yml | head -5 + echo " ... (21 total families)" +done + +# Step 3: Verify profiles +echo "" +echo "Step 3: Verifying profiles..." +for product in $PRODUCTS; do + if [ -f "products/$product/profiles/cis_nist.profile" ]; then + echo "✓ products/$product/profiles/cis_nist.profile" + # Show what it selects + grep "nist_800_53:all" "products/$product/profiles/cis_nist.profile" && echo " → Uses nist_800_53:all ✓" + fi +done + +# Step 4: Check datastreams +echo "" +echo "Step 4: Checking built datastreams..." +for product in $PRODUCTS; do + if [ -f "build/ssg-$product-ds.xml" ]; then + SIZE=$(du -h "build/ssg-$product-ds.xml" | cut -f1) + echo "✓ build/ssg-$product-ds.xml ($SIZE)" + + # Count profiles in datastream + PROFILE_COUNT=$(grep -c 'Profile id="xccdf_org.ssgproject.content_profile_' "build/ssg-$product-ds.xml" || true) + echo " → Contains $PROFILE_COUNT profiles" + + # Check if cis_nist profile exists + if grep -q 'Profile id="xccdf_org.ssgproject.content_profile_cis_nist"' "build/ssg-$product-ds.xml"; then + echo " → cis_nist profile: ✓" + else + echo " → cis_nist profile: NOT FOUND" + fi + else + echo "✗ build/ssg-$product-ds.xml NOT FOUND" + fi +done + +# Step 5: Check rendered policies +echo "" +echo "Step 5: Checking rendered policies..." +for product in $PRODUCTS; do + if [ -f "build/$product/rendered-policies/nist_800_53.html" ]; then + SIZE=$(du -h "build/$product/rendered-policies/nist_800_53.html" | cut -f1) + echo "✓ build/$product/rendered-policies/nist_800_53.html ($SIZE)" + fi +done + +# Step 6: Profile comparison results +echo "" +echo "Step 6: Profile comparison summary..." +echo "(Results from workflow run above)" + +# Step 7: Show control file stats +echo "" +echo "Step 7: Control file statistics..." +for product in $PRODUCTS; do + echo "" + echo "Product: $product" + echo " Reference files (nist_800_53_cis_reference_${product}):" + TOTAL_CONTROLS=0 + TOTAL_RULES=0 + for family in "shared/references/controls/nist_800_53_cis_reference_${product}/"*.yml; do + CONTROLS=$(grep -c '^ - id:' "$family" || true) + RULES=$(grep -c '^ -' "$family" || true) + TOTAL_CONTROLS=$((TOTAL_CONTROLS + CONTROLS)) + TOTAL_RULES=$((TOTAL_RULES + RULES)) + done + echo " Total controls: $TOTAL_CONTROLS" + echo " Total rule selections: $TOTAL_RULES" + + echo " Product control files (products/${product}/controls/nist_800_53):" + TOTAL_CONTROLS=0 + TOTAL_RULES=0 + for family in "products/${product}/controls/nist_800_53/"*.yml; do + CONTROLS=$(grep -c '^ - id:' "$family" || true) + RULES=$(grep -c '^ -' "$family" || true) + TOTAL_CONTROLS=$((TOTAL_CONTROLS + CONTROLS)) + TOTAL_RULES=$((TOTAL_RULES + RULES)) + done + echo " Total controls: $TOTAL_CONTROLS" + echo " Total rule selections: $TOTAL_RULES" +done + +echo "" +echo "╔════════════════════════════════════════════════════════════╗" +echo "║ Test Complete ✓ ║" +echo "╚════════════════════════════════════════════════════════════╝" +echo "" +echo "Next steps:" +echo " - Review any diff between reference and product control files:" +for product in $PRODUCTS; do + echo " diff -ur shared/references/controls/nist_800_53_cis_reference_${product}/ \\" + echo " products/${product}/controls/nist_800_53/" +done +echo " - Edit product-specific control files if needed" +echo " - Run oscap to scan with cis_nist profile" +echo "" diff --git a/utils/oscal/__init__.py b/utils/oscal/__init__.py deleted file mode 100644 index 05b6af90555a..000000000000 --- a/utils/oscal/__init__.py +++ /dev/null @@ -1,35 +0,0 @@ -import os -from typing import Optional - -import ssg.products - -from trestle.common.const import TRESTLE_GENERIC_NS -from trestle.core.generators import generate_sample_model -from trestle.oscal.common import Property - -SSG_ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), "..", "..")) -VENDOR_ROOT = os.path.join(SSG_ROOT, "shared", "references", "oscal") -RULES_JSON = os.path.join(SSG_ROOT, "build", "rule_dirs.json") -BUILD_CONFIG = os.path.join(SSG_ROOT, "build", "build_config.yml") -TRESTLE_CD_NS = f"{TRESTLE_GENERIC_NS}/cd" -LOGGER_NAME = "oscal" - - -def get_benchmark_root(root: str, product: str) -> str: - """Get the benchmark root.""" - product_yaml_path = ssg.products.product_yaml_path(root, product) - product_yaml = ssg.products.load_product_yaml(product_yaml_path) - product_dir = product_yaml.get("product_dir") - benchmark_root = os.path.join(product_dir, product_yaml.get("benchmark_root")) - return benchmark_root - - -def add_prop(name: str, value: str, remarks: Optional[str] = None) -> Property: - """Add a property to a set of rule properties.""" - prop = generate_sample_model(Property) - prop.name = name - prop.value = value - if remarks: - prop.remarks = remarks - prop.ns = TRESTLE_CD_NS # type: ignore - return prop diff --git a/utils/oscal/build_cd_from_policy.py b/utils/oscal/build_cd_from_policy.py deleted file mode 100755 index 7b21d6a5c98b..000000000000 --- a/utils/oscal/build_cd_from_policy.py +++ /dev/null @@ -1,156 +0,0 @@ -#!/usr/bin/env python3 - -"""CLI for building a component definition for a product using a policy for control responses.""" - -import argparse -import logging -import os -import sys -from typing import Any, Dict - -import ssg.environment - -from utils.oscal import SSG_ROOT, VENDOR_ROOT, RULES_JSON, BUILD_CONFIG, LOGGER_NAME -from utils.oscal.control_selector import PolicyControlSelector -from utils.oscal.cd_generator import ComponentDefinitionGenerator - - -logger = logging.getLogger(LOGGER_NAME) - -LOG_FILE = os.path.join(SSG_ROOT, "build", "build_cd_for_product.log") - - -def _parse_args() -> argparse.Namespace: - parser = argparse.ArgumentParser( - description="Create a component definition for a product." - ) - parser.add_argument("-o", "--output", help="Path to write the cd to", required=True) - parser.add_argument( - "-r", - "--root", - help=f"Root of the SSG project. Defaults to {SSG_ROOT}", - default=SSG_ROOT, - ) - parser.add_argument( - "-v", - "--vendor-dir", - help="Path to the vendor directory with third party OSCAL artifacts", - default=VENDOR_ROOT, - ) - parser.add_argument( - "-p", - "--profile", - help="Main profile href, or name of the profile model in the trestle workspace", - required=True, - ) - parser.add_argument( - "-pr", - "--product", - help="Product to build cd with", - required=True, - ) - parser.add_argument( - "-c", - "--control", - help="Control to use as the source for control responses. \ - To optionally filter by level, use the format :.", - required=True, - ) - parser.add_argument( - "-j", - "--json", - type=str, - action="store", - default=RULES_JSON, - help=f"Path to the rules_dir.json (defaults to {RULES_JSON})", - ) - parser.add_argument( - "-b", - "--build-config-yaml", - default=BUILD_CONFIG, - help="YAML file with information about the build configuration", - ) - parser.add_argument( - "--component-definition-type", - choices=["service", "validation"], - default="service", - help="Type of component definition to create", - ) - return parser.parse_args() - - -def configure_logger(log_file=None, log_level=logging.INFO): - """Configure the logger.""" - logger.setLevel(log_level) - - log_format_file = "%(asctime)s - %(name)s - %(levelname)s - %(message)s" - formatter_file = logging.Formatter(log_format_file) - - log_format_console = "%(levelname)s - %(message)s" - formatter_console = logging.Formatter(log_format_console) - - if log_file: - file_handler = logging.FileHandler(log_file) - file_handler.setLevel(log_level) - file_handler.setFormatter(formatter_file) - logger.addHandler(file_handler) - - console_handler = logging.StreamHandler(sys.stdout) - console_handler.setLevel(log_level) - console_handler.setFormatter(formatter_console) - logger.addHandler(console_handler) - - -def get_env_yaml(ssg_root: str, build_config_yaml: str, product: str) -> Dict[str, Any]: - """Get the environment yaml.""" - product_yaml_path = ssg.products.product_yaml_path(ssg_root, product) - env_yaml = ssg.environment.open_environment( - build_config_yaml, - product_yaml_path, - os.path.join(ssg_root, "product_properties"), - ) - return env_yaml - - -def main(): - """Main function.""" - args = _parse_args() - configure_logger(LOG_FILE, log_level=logging.INFO) - - filter_by_level = None - if ":" in args.control: - args.control, filter_by_level = args.control.split(":") - - env_yaml = get_env_yaml(args.root, args.build_config_yaml, args.product) - - control_selector = PolicyControlSelector( - args.control, - args.root, - env_yaml, - filter_by_level, - ) - - cd_generator = ComponentDefinitionGenerator( - args.root, - args.json, - env_yaml, - args.vendor_dir, - args.profile, - control_selector, - ) - - try: - cd_generator.create_cd(args.output, args.component_definition_type) - except ValueError as e: - logger.error(f"Invalid value: {e}", exc_info=True) - sys.exit(2) - except FileNotFoundError as e: - logger.error(f"File not found: {e}", exc_info=True) - sys.exit(3) - except Exception as e: - logger.error(f"An unexpected error occurred: {e}", exc_info=True) - sys.exit(1) - - -if __name__ == "__main__": - main() diff --git a/utils/oscal/cd_generator.py b/utils/oscal/cd_generator.py deleted file mode 100644 index da4904eef58a..000000000000 --- a/utils/oscal/cd_generator.py +++ /dev/null @@ -1,400 +0,0 @@ -"""Build a component definition for a product from pre-existing OSCAL profiles""" - -import logging -import pathlib -import re -from typing import Any, Dict, List, Optional, Set, Tuple - -from trestle.common.common_types import TypeWithProps, TypeWithParts -from trestle.common.const import TRESTLE_HREF_HEADING, IMPLEMENTATION_STATUS, REPLACE_ME -from trestle.common.list_utils import as_list, none_if_empty -from trestle.core.generators import generate_sample_model -from trestle.core.catalog.catalog_interface import CatalogInterface -from trestle.core.control_interface import ControlInterface -from trestle.core.profile_resolver import ProfileResolver -from trestle.oscal import catalog as cat -from trestle.oscal.common import Property -from trestle.oscal.component import ( - ComponentDefinition, - DefinedComponent, - ControlImplementation, - ImplementedRequirement, - Statement, - SetParameter, -) - - -from ssg.controls import Status, Control -from ssg.utils import required_key - -from utils.oscal import add_prop -from utils.oscal.control_selector import ControlSelector -from utils.oscal.params_extractor import ParameterExtractor -from utils.oscal.rules_transformer import RulesTransformer, RuleInfo - -from utils.oscal import LOGGER_NAME - - -logger = logging.getLogger(LOGGER_NAME) - -SECTION_PATTERN = r"Section ([a-z]):" - - -class OscalStatus: - """ - Represent the status of a control in OSCAL. - - Notes: - This transforms the status from SSG to OSCAL in the from - string method. - """ - - PLANNED = "planned" - NOT_APPLICABLE = "not-applicable" - ALTERNATIVE = "alternative" - IMPLEMENTED = "implemented" - PARTIAL = "partial" - - @staticmethod - def from_string(source: str) -> str: - data = { - Status.INHERENTLY_MET: OscalStatus.IMPLEMENTED, - Status.DOES_NOT_MEET: OscalStatus.ALTERNATIVE, - Status.DOCUMENTATION: OscalStatus.IMPLEMENTED, - Status.AUTOMATED: OscalStatus.IMPLEMENTED, - Status.MANUAL: OscalStatus.ALTERNATIVE, - Status.PLANNED: OscalStatus.PLANNED, - Status.PARTIAL: OscalStatus.PARTIAL, - Status.SUPPORTED: OscalStatus.IMPLEMENTED, - Status.PENDING: OscalStatus.ALTERNATIVE, - Status.NOT_APPLICABLE: OscalStatus.NOT_APPLICABLE, - } - if source not in data.keys(): - raise ValueError(f"Invalid status: {source}. Use one of {data.keys()}") - return data.get(source) # type: ignore - - STATUSES = {PLANNED, NOT_APPLICABLE, ALTERNATIVE, IMPLEMENTED, PARTIAL} - - -class OSCALProfileHelper: - """Helper class to handle OSCAL profile.""" - - def __init__(self, trestle_root: pathlib.Path) -> None: - """Initialize.""" - self._root = trestle_root - self.profile_controls: Set[str] = set() - self.controls_by_label: Dict[str, str] = dict() - - def load(self, profile_path: str) -> None: - """Load the profile catalog.""" - profile_resolver = ProfileResolver() - resolved_catalog: cat.Catalog = profile_resolver.get_resolved_profile_catalog( - self._root, - profile_path, - block_params=False, - params_format="[.]", - show_value_warnings=True, - ) - - for control in CatalogInterface(resolved_catalog).get_all_controls_from_dict(): - self.profile_controls.add(control.id) - label = ControlInterface.get_label(control) - if label: - self.controls_by_label[label] = control.id - self._handle_parts(control) - - def _handle_parts( - self, - control: TypeWithParts, - ) -> None: - """Handle parts of a control.""" - if control.parts: - for part in control.parts: - if not part.id: - continue - self.profile_controls.add(part.id) - label = ControlInterface.get_label(part) - # Avoiding key collision here. The higher level control object will take - # precedence. - if label and label not in self.controls_by_label.keys(): - self.controls_by_label[label] = part.id - self._handle_parts(part) - - def validate(self, control_id: str) -> Optional[str]: - """Validate that the control id exists in the catalog and return the id""" - if control_id in self.controls_by_label.keys(): - logger.debug(f"Found control {control_id} in control labels") - return self.controls_by_label.get(control_id) - elif control_id in self.profile_controls: - logger.debug(f"Found control {control_id} in profile control ids") - return control_id - - logger.debug(f"Control {control_id} does not exist in the profile") - return None - - -class ComponentDefinitionGenerator: - """Generate a component definition from a product""" - - def __init__( - self, - root: str, - json_path: str, - env_yaml: Dict[str, Any], - vendor_dir: str, - profile_name_or_href, - control_selector: ControlSelector, - ) -> None: - """ - Initialize the component definition generator and load the necessary files. - - Args: - root: Root of the SSG project - json_path: Path to the rules_dir.json file - env_yaml: Yaml file with environment information - vendor_dir: Path to the vendor directory - profile_name_or_href: Name or href of the profile to use - control_selector: Control selector that contains control responses - """ - self.ssg_root = root - self.trestle_root = pathlib.Path(vendor_dir) - self.product = required_key(env_yaml, "product") - self.env_yaml = env_yaml - self.control_selector = control_selector - - profile_path, profile_href = self.get_source(profile_name_or_href) - self.profile_href = profile_href - - self.profile = OSCALProfileHelper(self.trestle_root) - self.profile.load(profile_path) - - self.params_extractor = ParameterExtractor(root, self.env_yaml) - self.rules_transformer = RulesTransformer( - root, self.env_yaml, json_path, self.params_extractor - ) - - def get_source(self, profile_name_or_href: str) -> Tuple[str, str]: - """Get the source of the profile.""" - profile_in_trestle_dir = "://" not in profile_name_or_href - profile_href = profile_name_or_href - if profile_in_trestle_dir: - local_path = f"profiles/{profile_name_or_href}/profile.json" - profile_href = TRESTLE_HREF_HEADING + local_path - profile_path = str(self.trestle_root / local_path) - else: - profile_path = profile_href - - return profile_path, profile_href - - def create_implemented_requirement( - self, control: Control - ) -> Optional[ImplementedRequirement]: - """Create implemented requirement from a control object""" - - logger.info(f"Creating implemented requirement for {control.id}") - control_id = self.profile.validate(control.id) - if control_id: - implemented_req = generate_sample_model(ImplementedRequirement) - implemented_req.control_id = control_id - self.handle_response(implemented_req, control) - - rule_ids, params_values = self._process_rule_ids(control.rules) - self.add_rules(implemented_req, rule_ids, params_values) - return implemented_req - return None - - def add_rules( - self, - type_with_props: TypeWithProps, - rule_ids: List[str], - params_values: Optional[Dict[str, str]] = None, - ) -> None: - """Add rules to a type with props.""" - all_props: List[Property] = as_list(type_with_props.props) - self.rules_transformer.add_rules(rule_ids, params_values) - rule_properties: List[Property] = self.rules_transformer.get_rule_id_props( - rule_ids - ) - all_props.extend(rule_properties) - type_with_props.props = none_if_empty(all_props) - - def _process_rule_ids( - self, rule_ids: List[str] - ) -> Tuple[List[str], Dict[str, str]]: - """ - Process rule ids. - - Returns: - A tuple of processed rule ids and parameter selection values. - - Notes: Rule ids with an "=" are parameters and should not be included when searching for - rules. - """ - processed_rule_ids: List[str] = list() - params_values: Dict[str, str] = dict() - for rule_id in rule_ids: - parts = rule_id.split("=") - if len(parts) == 2: - param_id, value = parts - params_values[param_id] = value - else: - processed_rule_ids.append(rule_id) - return (processed_rule_ids, params_values) - - def handle_response(self, implemented_req, control: Control) -> None: - """ - Break down the response into parts. - - Args: - implemented_req: The implemented requirement to add the response and statements to. - control_response: The control response to add to the implemented requirement. - """ - control_response = control.notes - pattern = re.compile(SECTION_PATTERN, re.IGNORECASE) - - sections_dict = self.build_sections_dict(control_response, pattern) - oscal_status = OscalStatus.from_string(control.status) - - if sections_dict: - self._add_response_by_status(implemented_req, oscal_status, REPLACE_ME) - # process into statements - implemented_req.statements = list() - for section_label, section_content in sections_dict.items(): - statement_id = self.profile.validate( - f"{implemented_req.control_id}_smt.{section_label}" - ) - if statement_id is None: - continue - - section_content_str = "\n".join(section_content) - section_content_str = pattern.sub("", section_content_str) - statement = self.create_statement( - statement_id, section_content_str.strip() - ) - implemented_req.statements.append(statement) - else: - self._add_response_by_status( - implemented_req, oscal_status, control_response.strip() - ) - - @staticmethod - def build_sections_dict( - control_response: str, section_pattern: re.Pattern - ) -> Dict[str, List[str]]: - """Find all sections in the control response and build a dictionary of them.""" - lines = control_response.split("\n") - - sections_dict: Dict[str, List[str]] = dict() - current_section_label = None - - for line in lines: - match = section_pattern.match(line) - - if match: - current_section_label = match.group(1) - sections_dict[current_section_label] = [line] - elif current_section_label is not None: - sections_dict[current_section_label].append(line) - - return sections_dict - - @staticmethod - def _add_response_by_status( - impl_req: ImplementedRequirement, - implementation_status: str, - control_response: str, - ) -> None: - """ - Add the response to the implemented requirement depending on the status. - - Notes: Per OSCAL requirements, any status other than implemented and partial should have - remarks with justification for the status. - """ - - status_prop = add_prop(IMPLEMENTATION_STATUS, implementation_status, "") - - if ( - implementation_status == OscalStatus.IMPLEMENTED - or implementation_status == OscalStatus.PARTIAL - ): - impl_req.description = control_response - else: - status_prop.remarks = control_response - - impl_req.props = as_list(impl_req.props) - impl_req.props.append(status_prop) - - def create_statement(self, statement_id, description="") -> Statement: - """Create a statement.""" - statement = generate_sample_model(Statement) - statement.statement_id = statement_id - if description: - statement.description = description - return statement - - def add_set_parameters(self, control_implementation: ControlImplementation) -> None: - """Add set parameters to a type with props.""" - param_selections: Dict[ - str, str - ] = self.params_extractor.get_all_selected_values() - if param_selections: - all_set_params: List[SetParameter] = as_list( - control_implementation.set_parameters - ) - for param_id, value in param_selections.items(): - set_param = generate_sample_model(SetParameter) - set_param.param_id = param_id - set_param.values = [value] - all_set_params.append(set_param) - control_implementation.set_parameters = none_if_empty(all_set_params) - - def create_control_implementation(self) -> ControlImplementation: - """Get the control implementation for a component.""" - ci = generate_sample_model(ControlImplementation) - ci.source = self.profile_href - all_implement_reqs = list() - - for control in self.control_selector.get_controls(): - implemented_req = self.create_implemented_requirement(control) - if implemented_req: - all_implement_reqs.append(implemented_req) - ci.implemented_requirements = all_implement_reqs - self.add_set_parameters(ci) - return ci - - def create_cd( - self, output: str, component_definition_type: str = "service" - ) -> None: - """Create a component definition and write it to a file.""" - logger.info(f"Creating component definition for {self.product}") - component_definition = generate_sample_model(ComponentDefinition) - component_definition.metadata.title = f"Component definition for {self.product}" - component_definition.components = list() - - control_implementation: ControlImplementation = ( - self.create_control_implementation() - ) - - if not control_implementation.implemented_requirements: - logger.warning( - f"No implemented requirements found for {self.product}, exiting" - ) - return - - oscal_component = generate_sample_model(DefinedComponent) - oscal_component.title = self.product - oscal_component.type = component_definition_type - oscal_component.description = self.product - oscal_component.control_implementations = [control_implementation] - - # Create all of the top-level component properties for rules - rules: List[RuleInfo] = self.rules_transformer.get_all_rules() - all_rule_properties: List[Property] = self.rules_transformer.transform(rules) - oscal_component.props = none_if_empty(all_rule_properties) - - component_definition.components.append(oscal_component) - - output_str = output - out_path = pathlib.Path(output_str) - logger.info(f"Writing component definition to {out_path}") - component_definition.oscal_write(out_path) diff --git a/utils/oscal/control_selector.py b/utils/oscal/control_selector.py deleted file mode 100644 index 27c6ddaa6a83..000000000000 --- a/utils/oscal/control_selector.py +++ /dev/null @@ -1,60 +0,0 @@ -"""Abstract and concrete classes for control selection to extract control responses.""" - -import os -from abc import ABC, abstractmethod -from typing import Any, Dict, List - -from ssg.controls import ControlsManager, Control - - -class ControlSelector(ABC): - @abstractmethod - def __init__(self) -> None: - raise NotImplementedError - - @abstractmethod - def get_controls(self) -> List[Control]: - raise NotImplementedError - - -class PolicyControlSelector(ControlSelector): - """Select controls from a policy with optional filtering by level.""" - - def __init__( - self, - control: str, - ssg_root: str, - env_yaml: Dict[str, Any], - filter_by_level: str = "", - ) -> None: - """ - Initialize the PolicyControlSelector. - - Args: - control: The policy id. - ssg_root: The path to the root of the ssg directory. - env_yaml: The environment yaml. - filter_by_level: Optional level to filter by. - """ - controls_dir = os.path.join(ssg_root, "controls") - controls_manager = ControlsManager(controls_dirs=[controls_dir], env_yaml=env_yaml) - controls_manager.load() - if control not in controls_manager.policies: - raise ValueError(f"Policy {control} not found in controls") - - self.controls: List[Control] = list() - if filter_by_level: - policy = controls_manager.policies[control] - if filter_by_level not in policy.levels_by_id.keys(): - raise ValueError( - f"Level {filter_by_level} not found in policy {control}" - ) - self.controls = controls_manager.get_all_controls_of_level( - control, filter_by_level - ) - else: - self.controls = controls_manager.get_all_controls(control) - - def get_controls(self) -> List[Control]: - """Get the controls.""" - return self.controls diff --git a/utils/oscal/params_extractor.py b/utils/oscal/params_extractor.py deleted file mode 100644 index e69aeb2c2f67..000000000000 --- a/utils/oscal/params_extractor.py +++ /dev/null @@ -1,116 +0,0 @@ -"""Extract parameters from var files.""" - -import logging -import os -from typing import Any, Dict, Generator - -import ssg.build_yaml -from ssg.utils import required_key - -from utils.oscal import get_benchmark_root, LOGGER_NAME - -logger = logging.getLogger(LOGGER_NAME) - -VAR_FILE_EXTENSION = ".var" - - -def find_var_files(directory: str) -> Generator[str, None, None]: - """Yield all files in a directory with a given extension.""" - for root, _, files in os.walk(directory): - for file in files: - if file.endswith(VAR_FILE_EXTENSION): - yield os.path.join(root, file) - - -class ParamInfo: - """Stores parameter information.""" - - def __init__(self, param_id: str, description: str) -> None: - """Initialize.""" - self._id = param_id - self._description = description - self._value = "" - self._options: Dict[str, str] = dict() - - @property - def id(self) -> str: - """Get the id.""" - return self._id - - @property - def description(self) -> str: - """Get the description.""" - return self._description - - @property - def selected_value(self) -> str: - """Get the selected value.""" - return self._value - - @property - def options(self) -> Dict[str, str]: - """Get the options.""" - return self._options - - def set_selected_value(self, value: str) -> None: - """Set the selected value.""" - self._value = value - - def set_options(self, value: Dict[str, str]) -> None: - """Set the options.""" - self._options = value - - -class ParameterExtractor: - """To extract parameters from var files""" - - def __init__(self, root: str, env_yaml: Dict[str, Any]) -> None: - """Initialize.""" - self.root = root - self.env_yaml = env_yaml - - product = required_key(env_yaml, "product") - benchmark_root = get_benchmark_root(root, product) - self.param_files_for_product: Dict[str, str] = dict() - for file in find_var_files(benchmark_root): - param_id = os.path.basename(file).replace(VAR_FILE_EXTENSION, "") - self.param_files_for_product[param_id] = file - - # Store any previously loaded parameters here - self._params_by_id: Dict[str, ParamInfo] = dict() - - def get_params_for_id(self, param_id: str) -> ParamInfo: - """Get the parameter information for a parameter id.""" - if param_id not in self._params_by_id: - param_obj: ParamInfo = self._load_param_info(param_id) - self._params_by_id[param_id] = param_obj - return param_obj - return self._params_by_id[param_id] - - def get_all_selected_values(self) -> Dict[str, str]: - """Get all of the selected values for each stored parameter.""" - return { - param_id: param_obj.selected_value - for param_id, param_obj in self._params_by_id.items() - } - - def _load_param_info(self, param_id: str) -> ParamInfo: - """Load the param from the var file.""" - try: - file = self.param_files_for_product[param_id] - value_yaml = ssg.build_yaml.Value.from_yaml(file, self.env_yaml) - parameter_id = os.path.basename(file).replace(VAR_FILE_EXTENSION, "") - default = required_key(value_yaml.options, "default") - param_obj = ParamInfo( - parameter_id, - value_yaml.description.replace("\n", " ").strip(), - ) - param_obj.set_selected_value(default) - param_obj.set_options(value_yaml.options) - logger.info(f"Adding parameter {parameter_id}") - return param_obj - except KeyError as e: - raise ValueError(f"Could not find parameter {param_id}: {e}") - except ValueError as e: - logger.warning(f"Var file {file} has missing fields: {e}") - return param_obj diff --git a/utils/oscal/rules_transformer.py b/utils/oscal/rules_transformer.py deleted file mode 100644 index 8669f577a809..000000000000 --- a/utils/oscal/rules_transformer.py +++ /dev/null @@ -1,291 +0,0 @@ -"""Transform rules from existing Compliance as Code locations into OSCAL properties.""" - -import json -import logging -import re -from typing import Any, List, Dict, Optional - -from lxml import etree -from trestle.oscal.common import Property -from trestle.tasks.csv_to_oscal_cd import ( - PARAMETER_DESCRIPTION, - PARAMETER_ID, - PARAMETER_VALUE_ALTERNATIVES, - # TODO(jpower432): Make this public in trestle - # https://github.com/oscal-compass/compliance-trestle/issues/1475 - _RuleSetIdMgr, - RULE_DESCRIPTION, - RULE_ID, -) - -import ssg.build_yaml -import ssg.products -import ssg.rules -from ssg.utils import required_key - -from utils.oscal import get_benchmark_root, add_prop, LOGGER_NAME -from utils.oscal.params_extractor import ParameterExtractor, ParamInfo - -logger = logging.getLogger(LOGGER_NAME) - - -XCCDF_VARIABLE = "xccdf_variable" - - -class RuleInfo: - """Stores rule information.""" - - def __init__(self, rule_id: str, rule_dir: str) -> None: - """Initialize.""" - self._id = rule_id - self._description = "" - self._rule_dir = rule_dir - self._parameters: List[ParamInfo] = list() - - @property - def id(self) -> str: - """Get the id.""" - return self._id - - @property - def description(self) -> str: - """Get the description.""" - return self._description - - @property - def rule_dir(self) -> str: - """Get the rule directory.""" - return self._rule_dir - - @property - def parameters(self) -> List[ParamInfo]: - """Get the parameters.""" - return self._parameters - - def add_description(self, value: str) -> None: - """Add a rule description.""" - self._description = value - - def add_parameter(self, value: ParamInfo) -> None: - """Add a a rule parameter.""" - self._parameters.append(value) - - -class RulesTransformer: - """Transforms rules into properties for creating component definitions.""" - - def __init__( - self, - root: str, - env_yaml: Dict[str, Any], - rule_dirs_json_path: str, - param_extractor: ParameterExtractor, - ) -> None: - """Initialize.""" - with open(rule_dirs_json_path, "r") as f: - rule_dir_json = json.load(f) - self.rule_json = rule_dir_json - self.root = root - self.env_yaml = env_yaml - self.product = required_key(env_yaml, "product") - self.param_extractor = param_extractor - - benchmark_root = get_benchmark_root(root, self.product) - self.rules_dirs_for_product: Dict[str, str] = dict() - for dir_path in ssg.rules.find_rule_dirs_in_paths([benchmark_root]): - rule_id = ssg.rules.get_rule_dir_id(dir_path) - self.rules_dirs_for_product[rule_id] = dir_path - - # Store loaded rules here - self._rules_by_id: Dict[str, RuleInfo] = dict() - - def add_rules( - self, rules: List[str], params_values: Optional[Dict[str, str]] = None - ) -> None: - """ - Load a set of rules into rule objects based on ids and - add them to the rules_by_id dictionary. - - Args: - rules: A list of rule ids. - param_values: Parameter selection values from the ruleset. - - Notes: This attempt to load all rules and will raise an error if any fail. - """ - rule_errors: List[str] = list() - - for rule_id in rules: - error = self.add_rule(rule_id, params_values) - if error: - rule_errors.append(error) - - if len(rule_errors) > 0: - raise RuntimeError( - f"Error loading rules: \ - \n{', '.join(rule_errors)}" - ) - - def add_rule( - self, rule_id: str, params_values: Optional[Dict[str, str]] = None - ) -> Optional[str]: - """Add a single rule to the rules_by_id dictionary.""" - try: - if rule_id not in self._rules_by_id: - rule_obj = self._new_rule_obj(rule_id) - self._load_rule_yaml(rule_obj, params_values) - self._rules_by_id[rule_id] = rule_obj - except ValueError as e: - return f"Could not find rule {rule_id}: {e}" - except FileNotFoundError as e: - return f"Could not load rule {rule_id}: {e}" - return None - - def _new_rule_obj(self, rule_id: str) -> RuleInfo: - """Create a new rule object.""" - # Search the rules json first, then search the product benchmark - # root directory if it does not exist. - rule_dir = self._from_rules_json(rule_id) - if not rule_dir: - rule_dir = self._from_product_dir(rule_id) - if not rule_dir: - raise ValueError( - f"Could not find rule {rule_id} in rules json or product directory." - ) - rule_obj = RuleInfo(rule_id, rule_dir) - return rule_obj - - def _from_rules_json(self, rule_id: str) -> Optional[str]: - """Locate the rule dir in the rule JSON.""" - if rule_id not in self.rule_json: - return None - return self.rule_json[rule_id]["dir"] - - def _from_product_dir(self, rule_id: str) -> Optional[str]: - """Locate the rule dir in the product directory.""" - if rule_id not in self.rules_dirs_for_product: - return None - return self.rules_dirs_for_product.get(rule_id) - - def _load_rule_yaml( - self, rule_obj: RuleInfo, params_values: Optional[Dict[str, str]] = None - ) -> None: - """ - Update the rule object with the rule yaml data. - - Args: - rule_obj: The rule object where collection rule data is stored. - param_values: Parameter selection values from the ruleset. - """ - rule_file = ssg.rules.get_rule_dir_yaml(rule_obj.rule_dir) - rule_yaml = ssg.build_yaml.Rule.from_yaml(rule_file, env_yaml=self.env_yaml) - rule_yaml.normalize(self.product) - description = self._clean_rule_description(rule_yaml.description) - rule_obj.add_description(description) - self._get_params_ids(rule_yaml, rule_obj, params_values) - - @staticmethod - def _clean_rule_description(description: str) -> str: - """Clean the rule description.""" - parser = etree.HTMLParser() - tree = etree.fromstring(description, parser) # type: ignore - cleaned_description = etree.tostring(tree, encoding="unicode", method="text") - cleaned_description = cleaned_description.replace("\n", " ").strip() - cleaned_description = re.sub(" +", " ", cleaned_description) - return cleaned_description - - def _get_params_ids( - self, - rule_yaml: ssg.build_yaml.Rule, - rule_obj: RuleInfo, - param_values: Optional[Dict[str, str]] = None, - ) -> None: - """ - Rules reference variables in a variety of ways. - Each is attempted in order to find the parameter id. - - Args: - rule_yaml: The rule yaml object. - rule_obj: The rule object where collection rule data is stored. - param_values: Parameter values from the ruleset. - - Notes: - Just starting with the XCCDF variable for now for linking rules to parameters. - """ - if not rule_yaml.is_templated(): - return - - xccdf_variable = rule_yaml.get_template_vars(self.env_yaml).get(XCCDF_VARIABLE) - - if xccdf_variable: - param_id = xccdf_variable - param = self.param_extractor.get_params_for_id(param_id=param_id) - - # Update the selected value if provided by the ruleset under the control - if param_values and param_id in param_values: - param.set_selected_value(param_values[param_id]) - - rule_obj.add_parameter(param) - else: - logger.debug(f"Could not find {XCCDF_VARIABLE} for rule {rule_obj.id}") - - def _get_rule_properties(self, ruleset: str, rule_obj: RuleInfo) -> List[Property]: - """Get a set of rule properties for a rule object.""" - rule_properties: List[Property] = list() - - # Add rule properties for the rule set - rule_properties.append(add_prop(RULE_ID, rule_obj.id, ruleset)) - rule_properties.append( - add_prop(RULE_DESCRIPTION, rule_obj.description, ruleset) - ) - - for param in rule_obj.parameters: - rule_properties.extend(self._get_params_properties(ruleset, param)) - - return rule_properties - - @staticmethod - def _get_params_properties(ruleset: str, param_info: ParamInfo) -> List[Property]: - """Get a set of parameter properties for a rule object.""" - id_prop = add_prop(PARAMETER_ID, param_info.id, ruleset) - - description_prop = add_prop( - PARAMETER_DESCRIPTION, param_info.description, ruleset - ) - alternative_prop = add_prop( - PARAMETER_VALUE_ALTERNATIVES, - str(param_info.options), - ruleset, - ) - return [id_prop, description_prop, alternative_prop] - - def get_rule_id_props(self, rule_ids: List[str]) -> List[Property]: - """ - Get the rule id property for a rule id. - - Note: - This is used for linking rules to rulesets. Not the rules must be loaded - with add_rules before calling this method. - """ - props: List[Property] = list() - for rule_id in rule_ids: - if rule_id not in self._rules_by_id: - raise ValueError(f"Could not find rule {rule_id}") - props.append(add_prop(RULE_ID, rule_id)) - return props - - def get_all_rules(self) -> List[RuleInfo]: - """Get all rules that have been loaded""" - return list(self._rules_by_id.values()) - - def transform(self, rule_objs: List[RuleInfo]) -> List[Property]: - """Get the rules properties for a set of rule ids.""" - rule_properties: List[Property] = list() - - start_val = -1 - for i, rule_obj in enumerate(rule_objs): - rule_set_mgr = _RuleSetIdMgr(start_val + i, len(rule_objs)) - rule_set_props = self._get_rule_properties( - rule_set_mgr.get_next_rule_set_id(), rule_obj - ) - rule_properties.extend(rule_set_props) - return rule_properties diff --git a/utils/profile_tool/most_used_components.py b/utils/profile_tool/most_used_components.py index 0f67851ec02d..dde3ae181150 100644 --- a/utils/profile_tool/most_used_components.py +++ b/utils/profile_tool/most_used_components.py @@ -1,4 +1,3 @@ -import sys import os from collections import defaultdict @@ -7,13 +6,10 @@ from .most_used_rules import _sorted_dict_by_num_value from .common import generate_output, merge_dicts, remove_zero_counts -PYTHON_2 = sys.version_info[0] < 3 - -if not PYTHON_2: - from .most_used_rules import _get_profiles_for_product - from ..controleval import ( - load_controls_manager, - load_product_yaml, +from .most_used_rules import _get_profiles_for_product +from ..controleval import ( + load_controls_manager, + load_product_yaml, ) diff --git a/utils/release_helper.py b/utils/release_helper.py index e351a2f797f7..de6680283afa 100755 --- a/utils/release_helper.py +++ b/utils/release_helper.py @@ -242,10 +242,10 @@ def create_repo_milestone(repo, name) -> None: f'Stabilization phase starts on {formatted_date_stabilization}') try: repo.create_milestone( - title=name, description=milestone_description, due_on=estimated_release_date) + title=name, description=milestone_description, due_on=future_release_date) print(f'Milestone {name} successfully created with the following information:') print(f'Description: {milestone_description}') - print(f'Due on: {estimated_release_date}') + print(f'Due on: {future_release_date}') except Exception as e: print(f'Error: {e}') exit(1) @@ -353,9 +353,10 @@ def get_next_stabilization_date(release_date: datetime) -> datetime: def get_next_release_date(latest_release_date: datetime) -> datetime: month = get_next_quarter_second_month(latest_release_date) - now = datetime.now(UTC) - if month > 9 and latest_release_date <= now: + # If the next release month is earlier in the year than the latest release month, + # it means we've wrapped around to the next year + if month <= latest_release_date.month: year = latest_release_date.year + 1 else: year = latest_release_date.year diff --git a/utils/render-rules.py b/utils/render-rules.py index 1bb8abdcfe55..03630e8b1630 100755 --- a/utils/render-rules.py +++ b/utils/render-rules.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function from glob import glob import os diff --git a/utils/rule_dir_json.py b/utils/rule_dir_json.py index ee7b3196f936..e090bb6ba050 100755 --- a/utils/rule_dir_json.py +++ b/utils/rule_dir_json.py @@ -1,6 +1,5 @@ #!/usr/bin/python3 -from __future__ import print_function import argparse import os @@ -15,6 +14,7 @@ import ssg.products import ssg.rules import ssg.yaml +from ssg.entities.common import make_items_product_specific SSG_ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), "..")) @@ -158,6 +158,15 @@ def handle_remediations(product_list, product_yamls, rule_obj): env_yaml = dict() env_yaml.update(product_yaml) + env_yaml["rule_title"] = rule_obj["title"] + env_yaml["rule_id"] = rule_obj["id"] + identifiers = rule_obj.get("identifiers") or {} + if identifiers: + product_suffix = "@{0}".format(prod_type) + env_yaml["cce_identifiers"] = make_items_product_specific( + dict(identifiers), product_suffix, allow_overwrites=False) + else: + env_yaml["cce_identifiers"] = {} _, config = ssg.build_remediations.parse_from_file_with_jinja( r_path, env_yaml ) diff --git a/utils/strip_jinja_for_yamllint.py b/utils/strip_jinja_for_yamllint.py new file mode 100644 index 000000000000..b0782bb23b76 --- /dev/null +++ b/utils/strip_jinja_for_yamllint.py @@ -0,0 +1,78 @@ +#!/usr/bin/env python3 +"""Strip Jinja2 constructs from YAML files to make them yamllint-safe. + +This project uses Jinja2 templating ({{% %}}, {{{ }}}, {{# #}}) inside YAML +files. yamllint cannot parse these constructs, so this script removes them +while preserving line numbers (replaced regions become blank lines) so that +yamllint error messages still point to the correct source lines. + +Usage: + python3 utils/strip_jinja_for_yamllint.py FILE + +The cleaned content is written to stdout. +""" + +import re +import sys + + +def _replace_with_blanks(match): + """Replace a match with the same number of newlines to preserve line numbers.""" + return "\n" * match.group(0).count("\n") + + +def strip_jinja(content): + # 1. Remove whole-line Jinja block tags: {{% ... %}} on their own line(s). + # Match the entire line (including leading whitespace) to avoid leaving + # trailing spaces behind. + content = re.sub( + r"^[ \t]*\{\{%.*?%\}\}[ \t]*$", + _replace_with_blanks, + content, + flags=re.MULTILINE | re.DOTALL, + ) + # Remove any remaining inline block tags (rare). + content = re.sub(r"\{\{%.*?%\}\}", _replace_with_blanks, content, flags=re.DOTALL) + + # 2. Remove whole-line Jinja comments: {{# ... #}} + content = re.sub( + r"^[ \t]*\{\{#.*?#\}\}[ \t]*$", + _replace_with_blanks, + content, + flags=re.MULTILINE | re.DOTALL, + ) + # Remove any remaining inline comments. + content = re.sub(r"\{\{#.*?#\}\}", "", content, flags=re.DOTALL) + + # 3a. Standalone Jinja expressions occupying entire lines — these typically + # expand to top-level YAML keys (e.g. ocil/ocil_clause macros) or + # Ansible tasks, so replacing them with a placeholder string would + # produce invalid YAML. Replace with a YAML-safe comment placeholder + # to avoid trailing whitespace on otherwise blank lines. + content = re.sub( + r"^([ \t]*)\{\{\{.*?\}\}\}[ \t]*$", + lambda m: m.group(1) + "# jinja" + "\n" * (m.group(0).count("\n") - 1) + if m.group(0).count("\n") > 0 + else m.group(1) + "# jinja", + content, + flags=re.MULTILINE | re.DOTALL, + ) + + # 3b. Inline Jinja expressions embedded inside a YAML value — replace + # with a short placeholder so the surrounding YAML stays valid. + content = re.sub(r"\{\{\{.*?\}\}\}", "JINJA_EXPRESSION", content) + + return content + + +def main(): + if len(sys.argv) != 2: + print(f"Usage: {sys.argv[0]} FILE", file=sys.stderr) + sys.exit(2) + + with open(sys.argv[1]) as f: + sys.stdout.write(strip_jinja(f.read())) + + +if __name__ == "__main__": + main()