documentation_complete: true


title: 'Modify the System Login Banner'

description: |-
    {{% if product == "rhcos4" %}}
    To configure the system login banner create a file under
    <tt>/etc/issue.d</tt>

    The Machine Configuration provided with this rule is generic. You may need
    to adjust it accordingly to fit your usecase.
    {{% else %}}
    To configure the system login banner edit <tt>/etc/issue</tt>. Replace the
    default text with a message compliant with the local site policy or a legal
    disclaimer.
    {{% endif %}}

    The DoD required text is either:
    <br /><br />
    <tt>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:
    <br />-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.
    <br />-At any time, the USG may inspect and seize data stored on this IS.
    <br />-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.
    <br />-This IS includes security measures (e.g., authentication and access
    controls) to protect USG interests -- not for your personal benefit or
    privacy.
    <br />-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.</tt>
    <br /><br />
    OR:
    <br /><br />
    <tt>I've read &amp; consent to terms in IS user agreem't.</tt>
    {{% if product == "rhcos4" %}}
    <p>
    To address this, please create a <tt>MachineConfig</tt> object with the
    appropriate text in a drop-in file in <tt>/etc/issue.d/</tt>. You can also
    use the supplied remediation, which will be available based on scan results
    using `oc get remediations`. The default remediation is opinionated and you
    may need to adjust the <tt>MachineConfig</tt> accordingly for your use
    case.

    Do not try to edit <tt>/etc/issue</tt> directly as this is a symlink
    provided by the Operating System.
    </p>
    <p>
    For example, if you're using the DoD required text, the manifest would
    look as follows:
    <pre>
    ---
    apiVersion: machineconfiguration.openshift.io/v1
    kind: MachineConfig
    metadata:
      labels:
        machineconfiguration.openshift.io/role: master
      name: 75-master-etc-issue
    spec:
      config:
        ignition:
          version: 3.1.0
        storage:
          files:
          - contents:
              source: data:,You%20are%20accessing%20a%20U.S.%20Government%20%28USG%29%20Information%20System%20%28IS%29%20that%20is%20%0Aprovided%20for%20USG-authorized%20use%20only.%20By%20using%20this%20IS%20%28which%20includes%20any%20%0Adevice%20attached%20to%20this%20IS%29%2C%20you%20consent%20to%20the%20following%20conditions%3A%0A%0A-The%20USG%20routinely%20intercepts%20and%20monitors%20communications%20on%20this%20IS%20for%20%0Apurposes%20including%2C%20but%20not%20limited%20to%2C%20penetration%20testing%2C%20COMSEC%20monitoring%2C%20%0Anetwork%20operations%20and%20defense%2C%20personnel%20misconduct%20%28PM%29%2C%20law%20enforcement%20%0A%28LE%29%2C%20and%20counterintelligence%20%28CI%29%20investigations.%0A%0A-At%20any%20time%2C%20the%20USG%20may%20inspect%20and%20seize%20data%20stored%20on%20this%20IS.%0A%0A-Communications%20using%2C%20or%20data%20stored%20on%2C%20this%20IS%20are%20not%20private%2C%20are%20subject%20%0Ato%20routine%20monitoring%2C%20interception%2C%20and%20search%2C%20and%20may%20be%20disclosed%20or%20used%20%0Afor%20any%20USG-authorized%20purpose.%0A%0A-This%20IS%20includes%20security%20measures%20%28e.g.%2C%20authentication%20and%20access%20controls%29%20%0Ato%20protect%20USG%20interests--not%20for%20your%20personal%20benefit%20or%20privacy.%0A%0A-Notwithstanding%20the%20above%2C%20using%20this%20IS%20does%20not%20constitute%20consent%20to%20PM%2C%20LE%20%0Aor%20CI%20investigative%20searching%20or%20monitoring%20of%20the%20content%20of%20privileged%20%0Acommunications%2C%20or%20work%20product%2C%20related%20to%20personal%20representation%20or%20services%20%0Aby%20attorneys%2C%20psychotherapists%2C%20or%20clergy%2C%20and%20their%20assistants.%20Such%20%0Acommunications%20and%20work%20product%20are%20private%20and%20confidential.%20See%20User%20%0AAgreement%20for%20details.
            mode: 0644
            path: /etc/issue.d/legal-notice
            overwrite: true
    </pre>
    </p>
    {{{ machineconfig_description_footer() | indent(4) }}}
    {{% endif %}}

rationale: |-
    Display of a standardized and approved use notification before granting
    access to the operating system ensures privacy and security notification
    verbiage used is consistent with applicable federal laws, Executive Orders,
    directives, policies, regulations, standards, and guidance.
    <br /><br />
    System use notifications are required only for access via login interfaces
    with human users and are not required when such human interfaces do not
    exist.

severity: medium

identifiers:
    cce@rhcos4: CCE-82555-4
    cce@rhel8: CCE-80763-6
    cce@rhel9: CCE-83557-9
    cce@rhel10: CCE-88261-3
    cce@sle12: CCE-83054-7
    cce@sle15: CCE-83262-6
    cce@slmicro5: CCE-93802-7
    cce@slmicro6: CCE-94665-7

references:
    cis-csc: 1,12,15,16
    cis@sle12: 1.8.1.2
    cis@sle15: 1.8.1.2
    cobit5: DSS05.04,DSS05.10,DSS06.10
    cui: 3.1.9
    isa-62443-2009: 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
    isa-62443-2013: 'SR 1.1,SR 1.10,SR 1.2,SR 1.5,SR 1.7,SR 1.8,SR 1.9'
    iso27001-2013: A.18.1.4,A.9.2.1,A.9.2.4,A.9.3.1,A.9.4.2,A.9.4.3
    nist: AC-8(a),AC-8(c)
    nist-csf: PR.AC-7
    nist@sle12: AC-8(a),AC-8.1(ii)
    srg: SRG-OS-000023-GPOS-00006,SRG-OS-000228-GPOS-00088
    stigid@ol7: OL07-00-010050
    stigid@ol8: OL08-00-010060
    stigid@sle12: SLES-12-010030
    stigid@sle15: SLES-15-010020

platform: system_with_kernel

ocil_clause: 'it does not display the required banner'

ocil: |-
    To check if the system login banner is compliant,
    run the following command:
    {{% if product == "rhcos4" %}}
    <pre>$ cat /etc/issue.d/legal-notice</pre>
    {{% else %}}
    <pre>$ cat /etc/issue</pre>
    {{% endif %}}

fixtext: |-
  Configure {{{ full_name }}} to display the Standard Mandatory DoD Notice and Consent Banner before granting access to the system via command line logon.

  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."

checktext: |-
    Verify {{{ full_name }}} displays the Standard Mandatory DoD Notice and Consent Banner before
    granting access to the operating system via a command line user logon.

    Check that a banner is displayed at the command line login screen with the following command:

    $ sudo cat /etc/issue

    If the banner is set correctly it will return the following text:

     "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 banner text does not match the Standard Mandatory DoD Notice and Consent Banner exactly, or the line is commented out, this is a finding.

srg_requirement: '{{{ full_name }}} 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.'
