CCE Identifiers in Guide to the Secure Configuration of Red Hat Enterprise Linux 7

CCE ID | Rule Title | Description

CCE-80440-1

Enable the Docker service

The docker service is commonly needed to create containers. The `docker` service can be enabled with the following command:

    $ sudo systemctl enable docker.service

CCE-80441-9 | Use direct-lvm with the Device Mapper Storage Driver | To use Docker in production with the device mapper storage driver, the Docker daemon should be configured to use direct-lvm instead of loopback device as a storage. For setting up the LVM and configuring Docker, see the Docker Device Mapper Storage Documentation.
CCE-27274-0 | Uninstall rsh Package | The `rsh` package contains the client commands for the rsh services

CCE-27336-7

Disable rlogin Service

The `rlogin` service, which is available with the `rsh-server` package and runs as a service through xinetd or separately as a systemd socket, should be disabled. If using xinetd, set `disable` to `yes` in `/etc/xinetd.d/rlogin`. If using systemd, The `rlogin` socket can be disabled with the following command:

    $ sudo systemctl disable rlogin.socket

CCE-27408-4

Disable rexec Service

The `rexec` service, which is available with the `rsh-server` package and runs as a service through xinetd or separately as a systemd socket, should be disabled. If using xinetd, set `disable` to `yes` in `/etc/xinetd.d/rexec`. If using systemd, The `rexec` socket can be disabled with the following command:

    $ sudo systemctl disable rexec.socket

CCE-80513-5

Remove Host-Based Authentication Files

The `shosts.equiv` file list remote hosts and users that are trusted by the local system. To remove these files, run the following command to delete them from any location:

    $ sudo rm /[path]/[to]/[file]/shosts.equiv

CCE-27337-5

Disable rsh Service

The `rsh` service, which is available with the `rsh-server` package and runs as a service through xinetd or separately as a systemd socket, should be disabled. If using xinetd, set `disable` to `yes` in `/etc/xinetd.d/rsh`. If using systemd, The `rsh` socket can be disabled with the following command:

    $ sudo systemctl disable rsh.socket

CCE-80514-3

Remove User Host-Based Authentication Files

The `~/.shosts` (in each user's home directory) files list remote hosts and users that are trusted by the local system. To remove these files, run the following command to delete them from any location:

    $ sudo rm ~/.shosts

CCE-27342-5

Uninstall rsh-server Package

The `rsh-server` package can be uninstalled with the following command:

    $ sudo yum erase rsh-server

CCE-27406-8

Remove Rsh Trust Files

The files `/etc/hosts.equiv` and `~/.rhosts` (in each user's home directory) list remote hosts and users that are trusted by the local system when using the rshd daemon. To remove these files, run the following command to delete them from any location:

    $ sudo rm /etc/hosts.equiv

    $ rm ~/.rhosts

CCE-27305-2 | Remove telnet Clients | The telnet client allows users to start connections to other systems via the telnet protocol.

CCE-27401-9

Disable telnet Service

The `telnet` service configuration file `/etc/xinetd.d/telnet` is not created automatically. If it was created manually, check the `/etc/xinetd.d/telnet` file and ensure that `disable = no` is changed to read `disable = yes` as follows below:

    # description: The telnet server serves telnet sessions; it uses \\
    #       unencrypted username/password pairs for authentication.
    service telnet
    {
            flags           = REUSE
            socket_type     = stream

            wait            = no
            user            = root
            server          = /usr/sbin/in.telnetd
            log_on_failure  += USERID
            disable         = yes
    }

If the `/etc/xinetd.d/telnet` file does not exist, make sure that the activation of the `telnet` service on system boot is disabled via the following command: The `rexec` socket can be disabled with the following command:

    $ sudo systemctl disable rexec.socket

CCE-27165-0

Uninstall telnet-server Package

The `telnet-server` package can be uninstalled with the following command:

    $ sudo yum erase telnet-server

CCE-27385-4

Disable ypbind Service

The `ypbind` service, which allows the system to act as a client in a NIS or NIS+ domain, should be disabled. The `ypbind` service can be disabled with the following command:

    $ sudo systemctl disable ypbind.service

CCE-27396-1 | Remove NIS Client | The Network Information Service (NIS), formerly known as Yellow Pages, is a client-server directory service protocol used to distribute system configuration files. The NIS client (`ypbind`) was used to bind a system to an NIS server and receive the distributed configuration files.

CCE-27399-5

Uninstall ypserv Package

The `ypserv` package can be uninstalled with the following command:

    $ sudo yum erase ypserv

CCE-80443-5 | Remove tftp Daemon | Trivial File Transfer Protocol (TFTP) is a simple file transfer protocol, typically used to automatically transfer configuration or boot files between systems. TFTP does not support authentication and can be easily hacked. The package `tftp` is a client program that allows for connections to a `tftp` server.

CCE-80212-4

Disable tftp Service

The `tftp` service should be disabled. The `tftp` service can be disabled with the following command:

    $ sudo systemctl disable tftp.service

CCE-80214-0

Ensure tftp Daemon Uses Secure Mode

If running the `tftp` service is necessary, it should be configured to change its root directory at startup. To do so, ensure `/etc/xinetd.d/tftp` includes `-s` as a command line argument, as shown in the following example (which is also the default):

    server_args = -s /var/lib/tftpboot

CCE-80213-2

Uninstall tftp-server Package

The `tftp-server` package can be removed with the following command:

    $ sudo yum erase tftp-server

CCE-27443-1

Disable xinetd Service

The `xinetd` service can be disabled with the following command:

    $ sudo systemctl disable xinetd.service

CCE-27361-5

Install tcp_wrappers Package

When network services are using the `xinetd` service, the `tcp_wrappers` package should be installed. The `tcp_wrappers` package can be installed with the following command:

    $ sudo yum install tcp_wrappers

CCE-27354-0

Uninstall xinetd Package

The `xinetd` package can be uninstalled with the following command:

    $ sudo yum erase xinetd

CCE-27432-4

Uninstall talk Package

The `talk` package contains the client program for the Internet talk protocol, which allows the user to chat with other users on different systems. Talk is a communication program which copies lines from one terminal to the terminal of another user. The `talk` package can be removed with the following command:

    $ sudo yum erase talk

CCE-27210-4

Uninstall talk-server Package

The `talk-server` package can be removed with the following command:

    $ sudo yum erase talk-server

CCE-80249-6

Restrict Access to Anonymous Users if Possible

Is there a mission-critical reason for users to transfer files to/from their own accounts using FTP, rather than using a secure protocol like SCP/SFTP? If not, edit the vsftpd configuration file. Add or correct the following configuration option:

    local_enable=NO

If non-anonymous FTP logins are necessary, follow the guidance in the remainder of this section to secure these logins as much as possible.

CCE-80248-8

Create Warning Banners for All FTP Users

Edit the vsftpd configuration file, which resides at `/etc/vsftpd/vsftpd.conf` by default. Add or correct the following configuration options:

    banner_file=/etc/issue

CCE-80247-0

Enable Logging of All FTP Transactions

Add or correct the following configuration options within the `vsftpd` configuration file, located at `/etc/vsftpd/vsftpd.conf`:

    xferlog_enable=YES
    xferlog_std_format=NO
    log_ftp_protocol=YES

CCE-80250-4

Disable FTP Uploads if Possible

Is there a mission-critical reason for users to upload files via FTP? If not, edit the vsftpd configuration file to add or correct the following configuration options:

    write_enable=NO

If FTP uploads are necessary, follow the guidance in the remainder of this section to secure these transactions as much as possible.

CCE-80251-2 | Place the FTP Home Directory on its Own Partition | By default, the anonymous FTP root is the home directory of the FTP user account. The df command can be used to verify that this directory is on its own partition.

CCE-80246-2

Install vsftpd Package

If this system must operate as an FTP server, install the `vsftpd` package via the standard channels.

    $ sudo yum install vsftpd

CCE-80244-7

Disable vsftpd Service

The `vsftpd` service can be disabled with the following command:

    $ sudo systemctl disable vsftpd.service

CCE-80245-4

Uninstall vsftpd Package

The `vsftpd` package can be removed with the following command:

    $ sudo yum erase vsftpd

CCE-80276-9

Configure SNMP Service to Use Only SNMPv3 or Newer

Edit `/etc/snmp/snmpd.conf`, removing any references to `rocommunity`, `rwcommunity`, or `com2sec`. Upon doing that, restart the SNMP service:

    $ sudo service snmpd restart

CCE-27386-2

Ensure Default SNMP Password Is Not Used

Edit `/etc/snmp/snmpd.conf`, remove or change the default community strings of `public` and `private`. Once the default community strings have been changed, restart the SNMP service:

    $ sudo service snmpd restart

CCE-80275-1

Uninstall net-snmp Package

The `net-snmp` package provides the snmpd service. The `net-snmp` package can be removed with the following command:

    $ sudo yum erase net-snmp

CCE-80274-4

Disable snmpd Service

The `snmpd` service can be disabled with the following command:

    $ sudo systemctl disable snmpd.service

CCE-80379-1

Verify Group Who Owns /etc/cron.allow file

If `/etc/cron.allow` exists, it must be group-owned by `root`. To properly set the group owner of `/etc/cron.allow`, run the command:

    $ sudo chgrp root /etc/cron.allow

CCE-80378-3

Verify User Who Owns /etc/cron.allow file

If `/etc/cron.allow` exists, it must be owned by `root`. To properly set the owner of `/etc/cron.allow`, run the command:

    $ sudo chown root /etc/cron.allow

CCE-80344-5

Disable anacron Service

The `cronie-anacron` package, which provides `anacron` functionality, is installed by default. The `cronie-anacron` package can be removed with the following command:

    $ sudo yum erase cronie-anacron

CCE-27323-5

Enable cron Service

The `crond` service is used to execute commands at preconfigured times. It is required by almost all systems to perform necessary maintenance tasks, such as notifying root of system activity. The `crond` service can be enabled with the following command:

    $ sudo systemctl enable crond.service

CCE-80345-2

Disable At Service (atd)

The `at` and `batch` commands can be used to schedule tasks that are meant to be executed only once. This allows delayed execution in a manner similar to cron, except that it is not recurring. The daemon `atd` keeps track of tasks scheduled via `at` and `batch`, and executes them at the specified time. The `atd` service can be disabled with the following command:

    $ sudo systemctl disable atd.service

CCE-27285-6

Disable X Windows Startup By Setting Default Target

Systems that do not require a graphical user interface should only boot by default into `multi-user.target` mode. This prevents accidental booting of the system into a `graphical.target` mode. Setting the system's default target to `multi-user.target` will prevent automatic startup of the X server. To do so, run:

    $ systemctl set-default multi-user.target

You should see the following output:

    rm '/etc/systemd/system/default.target'
    ln -s '/usr/lib/systemd/system/multi-user.target' '/etc/systemd/system/default.target'

CCE-27218-7

Remove the X Windows Package Group

By removing the xorg-x11-server-common package, the system no longer has X Windows installed. If X Windows is not installed then the system cannot boot into graphical user mode. This prevents the system from being accidentally or maliciously booted into a `graphical.target` mode. To do so, run the following command:

    $ sudo yum groupremove "X Window System"

    $ sudo yum remove xorg-x11-server-common

CCE-27594-1

Uninstall quagga Package

The `quagga` package can be removed with the following command:

    $ sudo yum erase quagga

CCE-27191-6

Disable Quagga Service

The `zebra` service can be disabled with the following command:

    $ sudo systemctl disable zebra.service

CCE-80327-0

Disable Zone Transfers from the Nameserver

Is it necessary for a secondary nameserver to receive zone data via zone transfer from the primary server? If not, follow the instructions in this section. If so, see the next section for instructions on protecting zone transfers. Add or correct the following directive within `/etc/named.conf`:

    options {
      allow-transfer { none; };
      ...
    }

CCE-80329-6

Disable Dynamic Updates

Is there a mission-critical reason to enable the risky dynamic update functionality? If not, edit `/etc/named.conf`. For each zone specification, correct the following directive if necessary:

    zone "example.com " IN {
      allow-update { none; };
      ...
    };

CCE-80328-8

Authenticate Zone Transfers

If it is necessary for a secondary nameserver to receive zone data via zone transfer from the primary server, follow the instructions here. Use dnssec-keygen to create a symmetric key file in the current directory:

    $ cd /tmp
    $ sudo dnssec-keygen -a HMAC-MD5 -b 128 -n HOST dns.example.com
    Kdns.example.com .+aaa +iiiii

This output is the name of a file containing the new key. Read the file to find the base64-encoded key string:

    $ sudo cat Kdns.example.com .+NNN +MMMMM .key
    dns.example.com IN KEY 512 3 157 base64-key-string

Add the directives to `/etc/named.conf` on the primary server:

    key zone-transfer-key {
      algorithm hmac-md5;
      secret "base64-key-string ";
    };
    zone "example.com " IN {
      type master;
      allow-transfer { key zone-transfer-key; };
      ...
    };

Add the directives below to `/etc/named.conf` on the secondary nameserver:

    key zone-transfer-key {
      algorithm hmac-md5;
      secret "base64-key-string ";
    };

    server IP-OF-MASTER {
      keys { zone-transfer-key; };
    };

    zone "example.com " IN {
      type slave;
      masters { IP-OF-MASTER ; };
      ...
    };

CCE-80325-4

Disable DNS Server

The `named` service can be disabled with the following command:

    $ sudo systemctl disable named.service

CCE-80326-2

Uninstall bind Package

To remove the `bind` package, which contains the `named` service, run the following command:

    $ sudo yum erase bind

CCE-80293-4

Uninstall openldap-servers Package

The `openldap-servers` package should be removed if not in use. Is this system the OpenLDAP server? If not, remove the package.

    $ sudo yum erase openldap-servers

The openldap-servers RPM is not installed by default on Red Hat Enterprise Linux 7 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.

CCE-80448-4

Enable the LDAP Client For Use in Authconfig

To determine if LDAP is being used for authentication, use the following command:

    $ sudo grep -i useldapauth /etc/sysconfig/authconfig

If `USELDAPAUTH=yes`, then LDAP is being used. If not, set `USELDAPAUTH` to `yes`.

CCE-80292-6

Configure Certificate Directives for LDAP Use of TLS

Ensure a copy of a trusted CA certificate has been placed in the file `/etc/pki/tls/CA/cacert.pem`. Configure LDAP to enforce TLS use and to trust certificates signed by that CA. First, edit the file `/etc/nslcd.conf`, and add or correct either of the following lines:

    tls_cacertdir /etc/pki/tls/CA

or

    tls_cacertfile /etc/pki/tls/CA/cacert.pem

Then review the LDAP server and ensure TLS has been configured.

CCE-80291-8

Configure LDAP Client to Use TLS For All Transactions

This check verifies that RHEL7 implements cryptography to protect the integrity of remote LDAP authentication sessions.
To determine if LDAP is being used for authentication, use the following command:

    $ sudo grep -i useldapauth /etc/sysconfig/authconfig

If `USELDAPAUTH=yes`, then LDAP is being used. To check if LDAP is configured to use TLS, use the following command:

    $ sudo grep -i ssl /etc/pam_ldap.conf

CCE-80337-9

Disable DHCP Client

For each interface on the system (e.g. eth0), edit `/etc/sysconfig/network-scripts/ifcfg-interface` and make the following changes:

- Correct the BOOTPROTO line to read:

      BOOTPROTO=none

- Add or correct the following lines, substituting the appropriate values based on your site's addressing scheme:

      NETMASK=255.255.255.0
      IPADDR=192.168.1.2
      GATEWAY=192.168.1.1

CCE-80334-6

Deny BOOTP Queries

Unless your network needs to support older BOOTP clients, disable support for the bootp protocol by adding or correcting the global option:

    deny bootp;

CCE-80332-0

Do Not Use Dynamic DNS

To prevent the DHCP server from receiving DNS information from clients, edit `/etc/dhcp/dhcpd.conf`, and add or correct the following global option:

    ddns-update-style none;

CCE-80333-8

Deny Decline Messages

Edit `/etc/dhcp/dhcpd.conf` and add or correct the following global option to prevent the DHCP server from responding the DHCPDECLINE messages, if possible:

    deny declines;

CCE-80336-1

Configure Logging

Ensure that the following line exists in `/etc/rsyslog.conf`:

    daemon.*           /var/log/daemon.log

Configure logwatch or other log monitoring tools to summarize error conditions reported by the dhcpd process.

CCE-80331-2

Uninstall DHCP Server Package

If the system does not need to act as a DHCP server, the dhcp package can be uninstalled. The `dhcp` package can be removed with the following command:

    $ sudo yum erase dhcp

CCE-80330-4

Disable DHCP Service

The `dhcpd` service should be disabled on any system that does not need to act as a DHCP server. The `dhcpd` service can be disabled with the following command:

    $ sudo systemctl disable dhcpd.service

CCE-80277-7

Disable Samba

The `smb` service can be disabled with the following command:

    $ sudo systemctl disable smb.service

CCE-80278-5

Uninstall Samba Package

The `samba` package can be uninstalled with the following command:

    $ sudo yum erase samba

CCE-80360-1

Install the Samba Common Package

The `samba-common` package should be installed. The `samba-common` package can be installed with the following command:

    $ sudo yum install samba-common

CCE-80279-3

Disable Root Access to SMB Shares

Administrators should not use administrator accounts to access Samba file and printer shares. Disable the root user and the wheel administrator group:

    [share]
      invalid users = root @wheel

If administrator accounts cannot be disabled, ensure that local system passwords and Samba service passwords do not match.

CCE-80280-1

Require Client SMB Packet Signing, if using smbclient

To require samba clients running `smbclient` to use packet signing, add the following to the `[global]` section of the Samba configuration file, `/etc/samba/smb.conf`:

    client signing = mandatory

Requiring samba clients such as `smbclient` to use packet signing ensures they can only communicate with servers that support packet signing.

CCE-80281-9

Require Client SMB Packet Signing, if using mount.cifs

Require packet signing of clients who mount Samba shares using the `mount.cifs` program (e.g., those who specify shares in `/etc/fstab`). To do so, ensure signing options (either `sec=krb5i` or `sec=ntlmv2i`) are used.
See the `mount.cifs(8)` man page for more information. A Samba client should only communicate with servers who can support SMB packet signing.

CCE-80300-7

Disable httpd Service

The `httpd` service can be disabled with the following command:

    $ sudo systemctl disable httpd.service

CCE-80301-5

Uninstall httpd Package

The `httpd` package can be removed with the following command:

    $ sudo yum erase httpd

CCE-80302-3

Set httpd ServerTokens Directive to Prod

`ServerTokens Prod` restricts information in page headers, returning only the word "Apache."
Add or correct the following directive in `/etc/httpd/conf/httpd.conf`:

    ServerTokens Prod

CCE-80303-1

Set httpd ServerSignature Directive to Off

`ServerSignature Off` restricts `httpd` from displaying server version number on error pages.
Add or correct the following directive in `/etc/httpd/conf/httpd.conf`:

    ServerSignature Off

CCE-80562-2

HTTPD Log Files Must Be Owned By Root

All `httpd` logs must be owned by root user and group. By default, the path for httpd logs is `/var/log/httpd/` To properly set the owner of `/var/log/httpd`, run the command:

    $ sudo chown root /var/log/httpd

To properly set the owner of `/var/log/httpd/*`, run the command:

    $ sudo chown root /var/log/httpd/*

CCE-80322-1

Set Permissions on the /var/log/httpd/ Directory

Ensure that the permissions on the web server log directory is set to 700:

    $ sudo chmod 700 /var/log/httpd/

This is its default setting.

CCE-80382-5

Set Permissions on All Configuration Files Inside /etc/httpd/conf.modules.d/

To properly set the permissions of `/etc/http/conf.modules.d/*`, run the command:

    $ sudo chmod 0640 /etc/http/conf.modules.d/*

CCE-80323-9

Set Permissions on the /etc/httpd/conf/ Directory

To properly set the permissions of `/etc/http/conf`, run the command:

    $ sudo chmod 0750 /etc/http/conf

CCE-80381-7

Set Permissions on All Configuration Files Inside /etc/httpd/conf.d/

To properly set the permissions of `/etc/http/conf.d/*`, run the command:

    $ sudo chmod 0640 /etc/http/conf.d/*

CCE-80324-7

Set Permissions on All Configuration Files Inside /etc/httpd/conf/

To properly set the permissions of `/etc/http/conf/*`, run the command:

    $ sudo chmod 0640 /etc/http/conf/*

CCE-

Ensure Remote Administrative Access Is Encrypted

Ensure that the SSH server service is enabled. The `sshd` service can be enabled with the following command:

    $ sudo systemctl enable sshd.service

CCE-80561-4 | Scan All Uploaded Content for Malicious Software | Install anti-virus software on the system and set it to automatically scan new files that are introduced to the web server.
CCE- | Configure firewalld to Allow Access to the Web Server | By default, `firewalld` blocks access to the ports used by the web server. To configure `firewalld` to allow access, run the following command(s): `firewall-cmd --permanent --add-service=http` To configure `firewalld` to allow access, run the following command(s): `firewall-cmd --permanent --add-service=https`

CCE-80321-3

Install mod_security

Install the `security` module:

    $ sudo yum install mod_security

CCE-80558-0

Require Client Certificates

`SSLVerifyClient` should be set and configured to `require` by setting the following in `/etc/httpd/conf/httpd.conf`:

    SSLVerifyClient require

CCE-80557-2

Enable Transport Layer Security (TLS) Encryption

Disable old SSL and TLS version and enable the latest TLS encryption by setting the following in `/etc/httpd/conf.modules.d/ssl.conf`:

    SSLProtocol all -SSLv2 -SSLv3 -TLSv1 -TLSv1.1

Make sure to also set `SSLEngine` to `on` in `/etc/httpd/conf.modules.d/ssl.conf` like the following:

    SSLEngine on

CCE-80559-8 | Configure A Valid Server Certificate | Configure the web site to use a valid organizationally defined certificate. For DoD, this is a DoD server certificate issued by the DoD CA.

CCE-80320-5

Install mod_ssl

Install the `mod_ssl` module:

    $ sudo yum install mod_ssl

CCE-80317-1

Restrict Web Directory

The default configuration for the web (`/var/www/html`) Directory allows directory indexing (`Indexes`) and the following of symbolic links (`FollowSymLinks`). Neither of these is recommended.
The `/var/www/html` directory hierarchy should not be viewable via the web, and symlinks should only be followed if the owner of the symlink also owns the linked file.
Ensure that this policy is adhered to by altering the related section of the configuration:

    <Directory "/var/www/html">
    #  ...
       Options SymLinksIfOwnerMatch
    #  ...
    </Directory>

CCE-80318-9 | Restrict Other Critical Directories | All accessible web directories should be configured with similarly restrictive settings. The `Options` directive should be limited to necessary functionality and the `AllowOverride` directive should be used only if needed. The `Order` and `Deny` access control tags should be used to deny access by default, allowing access only where necessary.

CCE-80316-3

Restrict Root Directory

The `httpd` root directory should always have the most restrictive configuration enabled.

    <Directory / >
       Options None
       AllowOverride None
       Order allow,deny
    </Directory>

CCE-80554-9 | Ignore HTTPD .htaccess Files | Set `AllowOverride` to `none` for each instant of `<Directory>`.
CCE-80553-1 | Disable Anonymous FTP Access | If any directories that contain dynamic scripts can be accessed via FTP by any group or user that does not require access, remove permissions to such directories that allow anonymous access. Also, ensure that any such access employs an encrypted connection.

CCE-80556-4

Remove Write Permissions From Filesystem Paths And Server Scripts

Configure permissions for each instance of `Alias`, `ScriptAlias`, and `ScriptAliasMatch` that exist.

    $ sudo find DIR -type d -exec chmod 755 {} \;
    $ sudo find DIR -type f -exec chmod 555 {} \;

Where DIR matches the paths from `Alias`, `ScriptAlias`, and `ScriptAliasMatch`.

CCE-80319-7

Limit Available Methods

Web server methods are defined in section 9 of RFC 2616 (http://www.ietf.org/rfc/rfc2616.txt). If a web server does not require the implementation of all available methods, they should be disabled.
Note: `GET` and `POST` are the most common methods. A majority of the others are limited to the WebDAV protocol.

    <Directory /var/www/html>
    # ...
       # Only allow specific methods (this command is case-sensitive!)
       <LimitExcept GET POST>
          Order allow,deny
       </LimitExcept>
    # ...
    </Directory>

CCE-80555-6 | Web Content Directories Must Not Be Shared Anonymously | Web content directories should not be shared anonymously over remote filesystems such as `nfs` and `smb`. Remove the shares from the applicable directories.

CCE-80306-4

Disable LDAP Support

The `ldap` module provides HTTP authentication via an LDAP directory. If its functionality is unnecessary, comment out the related modules:

    #LoadModule ldap_module modules/mod_ldap.so
    #LoadModule authnz_ldap_module modules/mod_authnz_ldap.so

If LDAP is to be used, SSL encryption should be used as well.

CCE-80315-5

Disable CGI Support

The `cgi` module allows HTML to interact with the CGI web programming language.
If this functionality is unnecessary, comment out the module:

    #LoadModule cgi_module modules/mod_cgi.so

If the web server requires the use of CGI, enable `mod_cgi`.

CCE-80312-2

Disable URL Correction on Misspelled Entries

The `speling` module attempts to find a document match by allowing one misspelling in an otherwise failed request. If this functionality is unnecessary, comment out the module:

    #LoadModule speling_module modules/mod_speling.so

This functionality weakens server security by making site enumeration easier.

CCE-80308-0

Disable MIME Magic

The `mime_magic` module provides a second layer of MIME support that in most configurations is likely extraneous. If its functionality is unnecessary, comment out the related module:

    #LoadModule mime_magic_module modules/mod_mime_magic.so

CCE-80310-6

Disable Server Activity Status

The `status` module provides real-time access to statistics on the internal operation of the web server. This may constitute an unnecessary information leak and should be disabled unless necessary. To do so, comment out the related module:

    #LoadModule status_module modules/mod_status.so

If there is a critical need for this module, ensure that access to the status page is properly restricted to a limited set of hosts in the status handler configuration.

CCE-80304-9

Disable HTTP Digest Authentication

The `auth_digest` module provides encrypted authentication sessions. If this functionality is unnecessary, comment out the related module:

    #LoadModule auth_digest_module modules/mod_auth_digest.so

CCE-80309-8

Disable WebDAV (Distributed Authoring and Versioning)

WebDAV is an extension of the HTTP protocol that provides distributed and collaborative access to web content. If its functionality is unnecessary, comment out the related modules:

    #LoadModule dav_module modules/mod_dav.so
    #LoadModule dav_fs_module modules/mod_dav_fs.so

If there is a critical need for WebDAV, extra care should be taken in its configuration. Since DAV access allows remote clients to manipulate server files, any location on the server that is DAV enabled should be protected by access controls.

CCE-80311-4

Disable Web Server Configuration Display

The `info` module creates a web page illustrating the configuration of the web server. This can create an unnecessary security leak and should be disabled. If its functionality is unnecessary, comment out the module:

    #LoadModule info_module modules/mod_info.so

If there is a critical need for this module, use the `Location` directive to provide an access control list to restrict access to the information.

CCE-80313-0

Disable Proxy Support

The `proxy` module provides proxying support, allowing `httpd` to forward requests and serve as a gateway for other servers. If its functionality is unnecessary, comment out the module:

    #LoadModule proxy_module modules/mod_proxy.so

If proxy support is needed, load `mod_proxy` and the appropriate proxy protocol handler module (one of `mod_proxy_http`, `mod_proxy_ftp`, or `mod_proxy_connect`). Additionally, make certain that a server is secure before enabling proxying, as open proxy servers are a security risk. `mod_proxy_balancer` enables load balancing, but requires that `mod status` be enabled.

CCE-80314-8

Disable Cache Support

The `cache` module allows `httpd` to cache data, optimizing access to frequently accessed content. However, it introduces potential security flaws such as the possibility of circumventing `Allow` and `Deny` directives.
If this functionality is unnecessary, comment out the module:

    #LoadModule cache_module modules/mod_cache.so

If caching is required, it should not be enabled for any limited-access content.

CCE-80305-6

Disable HTTP mod_rewrite

The `mod_rewrite` module is very powerful and can protect against certain classes of web attacks. However, it is also very complex and has a significant history of vulnerabilities itself. If its functionality is unnecessary, comment out the related module:

    #LoadModule rewrite_module modules/mod_rewrite.so

CCE-80307-2

Disable Server Side Includes

Server Side Includes provide a method of dynamically generating web pages through the insertion of server-side code. However, the technology is also deprecated and introduces significant security concerns. If this functionality is unnecessary, comment out the related module:

    #LoadModule include_module modules/mod_include.so

If there is a critical need for Server Side Includes, they should be enabled with the option `IncludesNoExec` to prevent arbitrary code execution. Additionally, user supplied data should be encoded to prevent cross-site scripting vulnerabilities.

CCE-80552-3

Enable log_config_module For HTTPD Logging

The `log_config_module` should exist and be configured in the `/etc/httpd/conf/httpd.conf` file by adding the following module to configure logging:

    log_config_module

CCE-80560-6

Configure HTTP PERL Scripts To Use TAINT Option

If the `mod_perl` module is installed, enable Perl Taint checking in `/etc/httpd/conf/httpd.conf`. To enable Perl Taint checking, add or uncomment the following to `/etc/httpd/conf.d/perl.conf`:

    PerlSwitches -T

CCE- | Ensure Web Content Located on Separate partition | The `DocumentRoot` directory is used for storing web content and data. Ensure that the `DocumentRoot` directory exists on a separate logical volume at installation time, or migrate it using LVM.

CCE-

Disable Web Content Symbolic Links

For each `<Directory>` instance, remove the following:

    FollowSymLinks

If symbolic links are allowed, the following can be added for each `<Directory>` instance:

    Options SymLinksIfOwnerMatchDisable

CCE- | Remove .java And .jpp Files | `.java` and `.jpp` files should not exist and should be removed from the web server.
CCE- | Each Web Content Directory Must Contain An index.html File | Every `DocumentRoot` that is configured should have an `index.html` file that exists. Add an `index.html` file to every configured `DocumentRoot`.

CCE-

The robots.txt Files Must Not Exist

Remove any `robots.txt` files that may exist with any web content. Other methods must be employed if there is information on the web site that needs protection from search engines and public view. Inspect all instances of `DocumentRoot` and `Alias` and remove any `robots.txt` file.

    $ sudo rm -f path/to/robots.txt

CCE- | Configure A Banner Page For Each Website | Configure a login banner for each website when authentication is required for user access.
CCE- | Encrypt All File Uploads | Use only secure encrypted logons and connections for uploading files to the web site.

CCE-81130-7

Enable HTTPD Error Logging

`ErrorLog` should be enabled and set to the following in `/etc/httpd/conf/httpd.conf`:

    ErrorLog "logs/error_log"

CCE-

A public web server, if hosted on the NIPRNet, must be isolated in an accredited DoD DMZ extension

To minimize exposure of private assets to unnecesarry risk by attackers, public web servers must be isolated from internal systems. Logically relocate public web servers to be isolated from internal systems. In addition, ensure the public web server does not have trusted connections with assets outside the confines of the demilitarizez done (DMZ) other than application and/or database servers that are a part of the same system as the web server.

CCE- | A private web server must be located on a separate controlled access subnet | Private web servers, which host sites that serve controlled access data, must be protected from outside threats in addition to insider threats. Isolate the private web server from the public DMZ and separate it from the internal general population LAN.

CCE-80551-5

Configure The Number of Allowed Simultaneous Requests

The `MaxKeepAliveRequests` directive should be set and configured to or greater by setting the following in `/etc/httpd/conf/httpd.conf`:

    MaxKeepAliveRequests

CCE- | Public web server resources must not be shared with private assets | It is important to segregate public web server resources from private resources located behind the DoD DMZ in order to protect private assets.

CCE-

The web server password(s) must be entrusted to the SA or Web Manager

Normally, a service account is established for the web server. This is because a privileged account is not desirable and the server is designed to run for long uninterrupted periods of time. The SA or Web Manager will need password access to the web server to restart the service in the event or an emergency as the web server is not to restart automatically after an unscheduled interruption.

CCE-80548-1

Configure Error Log Format

`LogFormat` should be enabled and set to the following in `/etc/httpd/conf/httpd.conf`:

    LogFormat "a %A %h %H %l %m %s %t %u %U \"%{Referer}i\" \"%{User-Agent}i\"" combined

CCE- | Backup interactive scripts on the production web server are prohibited | Copies of backup files will not execute on the server, but they can be read by the anonymous user if special precautions are not taken.
CCE- | MIME types for csh or sh shell programs must be disabled | Users must not be allowed to access the shell programs.

CCE-80549-9

Enable HTTPD System Logging

`CustomLog` should be enabled and set to the following in `/etc/httpd/conf/httpd.conf`:

    CustomLog "logs/access_log" combined

CCE-80550-7

Enable HTTPD LogLevel

`LogLevel` should be enabled and set to . Add or edit the following in `/etc/httpd/conf/httpd.conf`:

    LogLevel

CCE- | Installation of a compiler on production web server is prohibited | The presence of a compiler on a production server facilitates the malicious user's task of creating custom versions of programs and installing Trojan Horses or viruses.

CCE-80515-0

Configure SSSD LDAP Backend Client CA Certificate Location

Configure SSSD to implement cryptography to protect the integrity of LDAP remote access sessions. By setting the

    ldap_tls_cacertdir

option in

    /etc/sssd/sssd.conf

to point to the path for the X.509 certificates used for peer authentication.

    ldap_tls_cacertdir /path/to/tls/cacert

CCE-80546-5

Configure SSSD LDAP Backend to Use TLS For All Transactions

This check verifies that RHEL7 implements cryptography to protect the integrity of remote LDAP authentication sessions.
To determine if LDAP is being used for authentication, use the following command:

    $ sudo grep -i useldapauth /etc/sysconfig/authconfig

If `USELDAPAUTH=yes`, then LDAP is being used. To check if LDAP is configured to use TLS, use the following command:

    $ sudo grep -i ldap_id_use_start_tls /etc/sssd/sssd.conf

CCE-80516-8

Configure SSSD LDAP Backend Client CA Certificate

Configure SSSD to implement cryptography to protect the integrity of LDAP remote access sessions. By setting the

    ldap_tls_cacert

option in

    /etc/sssd/sssd.conf

to point to the path for the X.509 certificates used for peer authentication.

    ldap_tls_cacert /path/to/tls/ca.cert

CCE-80364-3

Configure SSSD's Memory Cache to Expire

SSSD's memory cache should be configured to set to expire records after 1 day. To configure SSSD to expire memory cache, set `memcache_timeout` to `86400` under the `[nss]` section in `/etc/sssd/sssd.conf`. For example:

    [nss]
    memcache_timeout = 86400

CCE-80437-7

Configure PAM in SSSD Services

SSSD should be configured to run SSSD `pam` services. To configure SSSD to known SSH hosts, add `pam` to `services` under the `[sssd]` section in `/etc/sssd/sssd.conf`. For example:

    [sssd]
    services = sudo, autofs, pam

CCE-80365-0

Configure SSSD to Expire Offline Credentials

SSSD should be configured to expire offline credentials after 1 day. To configure SSSD to expire offline credentials, set `offline_credentials_expiration` to `1` under the `[pam]` section in `/etc/sssd/sssd.conf`. For example:

    [pam]
    offline_credentials_expiration = 1

CCE-80362-7

Install the SSSD Package

The `sssd` package should be installed. The `sssd` package can be installed with the following command:

    $ sudo yum install sssd

CCE-80366-8

Configure SSSD to Expire SSH Known Hosts

SSSD should be configured to expire keys from known SSH hosts after 1 day. To configure SSSD to known SSH hosts, set `ssh_known_hosts_timeout` to `86400` under the `[ssh]` section in `/etc/sssd/sssd.conf`. For example:

    [ssh]
    ssh_known_hosts_timeout = 86400

CCE-80363-5

Enable the SSSD Service

The SSSD service should be enabled. The `sssd` service can be enabled with the following command:

    $ sudo systemctl enable sssd.service

CCE-27012-4

Specify Additional Remote NTP Servers

Depending on specific functional requirements of a concrete production environment, the Red Hat Enterprise Linux 7 Server system can be configured to utilize the services of the `chronyd` NTP daemon (the default), or services of the `ntpd` NTP daemon. Refer to https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/System_Administrators_Guide/ch-Configuring_NTP_Using_the_chrony_Suite.html for more detailed comparison of the features of both of the choices, and for further guidance how to choose between the two NTP daemons.
Additional NTP servers can be specified for time synchronization. To do so, perform the following:

- if the system is configured to use the `chronyd` as the NTP daemon (the default), edit the file `/etc/chrony.conf` as follows,
- if the system is configured to use the `ntpd` as the NTP daemon, edit the file `/etc/ntp.conf` as documented below.

Add additional lines of the following form, substituting the IP address or hostname of a remote NTP server for ntpserver:

    server ntpserver

CCE-27278-1

Specify a Remote NTP Server

Depending on specific functional requirements of a concrete production environment, the Red Hat Enterprise Linux 7 Server system can be configured to utilize the services of the `chronyd` NTP daemon (the default), or services of the `ntpd` NTP daemon. Refer to https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/System_Administrators_Guide/ch-Configuring_NTP_Using_the_chrony_Suite.html for more detailed comparison of the features of both of the choices, and for further guidance how to choose between the two NTP daemons.
To specify a remote NTP server for time synchronization, perform the following:

- if the system is configured to use the `chronyd` as the NTP daemon (the default), edit the file `/etc/chrony.conf` as follows,
- if the system is configured to use the `ntpd` as the NTP daemon, edit the file `/etc/ntp.conf` as documented below.

Add or correct the following lines, substituting the IP or hostname of a remote NTP server for ntpserver:

    server ntpserver

This instructs the NTP software to contact that remote server to obtain time data.

CCE-27444-9

Enable the NTP Daemon

The `chronyd` service can be enabled with the following command:

    $ sudo systemctl enable chronyd.service

Note: The `chronyd` daemon is enabled by default.
The `ntpd` service can be enabled with the following command:

    $ sudo systemctl enable ntpd.service

Note: The `ntpd` daemon is not enabled by default. Though as mentioned in the previous sections in certain environments the `ntpd` daemon might be preferred to be used rather than the `chronyd` one. Refer to: https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/System_Administrators_Guide/ch-Configuring_NTP_Using_the_chrony_Suite.html for guidance which NTP daemon to choose depending on the environment used.

CCE-80439-3

Configure Time Service Maxpoll Interval

The `maxpoll` should be configured to in `/etc/ntp.conf` or `/etc/chrony.conf` to continuously poll time servers. To configure `maxpoll` in `/etc/ntp.conf` or `/etc/chrony.conf` add the following:

    maxpoll

CCE-80255-3

Disable Control Group Rules Engine (cgred)

The `cgred` service moves tasks into control groups according to parameters set in the `/etc/cgrules.conf` configuration file. The `cgred` service can be disabled with the following command:

    $ sudo systemctl disable cgred.service

CCE-80260-3

Disable D-Bus IPC Service (messagebus)

D-Bus provides an IPC mechanism used by a growing list of programs, such as those used for Gnome, Bluetooth, and Avahi. Due to these dependencies, disabling D-Bus may not be practical for many systems. The `messagebus` service can be disabled with the following command:

    $ sudo systemctl disable messagebus.service

CCE-80252-0

Disable Advanced Configuration and Power Interface (acpid)

The Advanced Configuration and Power Interface Daemon (`acpid`) dispatches ACPI events (such as power/reset button depressed) to userspace programs. The `acpid` service can be disabled with the following command:

    $ sudo systemctl disable acpid.service

CCE-80268-6

Disable Network Router Discovery Daemon (rdisc)

The `rdisc` service implements the client side of the ICMP Internet Router Discovery Protocol (IRDP), which allows discovery of routers on the local subnet. If a router is discovered then the local routing table is updated with a corresponding default route. By default this daemon is disabled. The `rdisc` service can be disabled with the following command:

    $ sudo systemctl disable rdisc.service

CCE-80261-1

Disable Network Console (netconsole)

The `netconsole` service is responsible for loading the netconsole kernel module, which logs kernel printk messages over UDP to a syslog server. This allows debugging of problems where disk logging fails and serial consoles are impractical. The `netconsole` service can be disabled with the following command:

    $ sudo systemctl disable netconsole.service

CCE-80253-8

Disable Certmonger Service (certmonger)

Certmonger is a D-Bus based service that attempts to simplify interaction with certifying authorities on networks which use public-key infrastructure. It is often combined with Red Hat's IPA (Identity Policy Audit) security information management solution to aid in the management of certificates. The `certmonger` service can be disabled with the following command:

    $ sudo systemctl disable certmonger.service

CCE-80267-8

Disable Quota Netlink (quota_nld)

The `quota_nld` service provides notifications to users of disk space quota violations. It listens to the kernel via a netlink socket for disk quota violations and notifies the appropriate user of the violation using D-Bus or by sending a message to the terminal that the user has last accessed. The `quota_nld` service can be disabled with the following command:

    $ sudo systemctl disable quota_nld.service

CCE-80265-2

Enable Process Accounting (psacct)

The process accounting service, `psacct`, works with programs including `acct` and `ac` to allow system administrators to view user activity, such as commands issued by users of the system. The `psacct` service can be enabled with the following command:

    $ sudo systemctl enable psacct.service

CCE-80269-4

Disable Red Hat Network Service (rhnsd)

The Red Hat Network service automatically queries Red Hat Network servers to determine whether there are any actions that should be executed, such as package updates. This only occurs if the system was registered to an RHN server or satellite and managed as such. The `rhnsd` service can be disabled with the following command:

    $ sudo systemctl disable rhnsd.service

CCE-80259-5

Disable Software RAID Monitor (mdmonitor)

The `mdmonitor` service is used for monitoring a software RAID array; hardware RAID setups do not use this service. The `mdmonitor` service can be disabled with the following command:

    $ sudo systemctl disable mdmonitor.service

CCE-80257-9

Enable IRQ Balance (irqbalance)

The `irqbalance` service optimizes the balance between power savings and performance through distribution of hardware interrupts across multiple processors. The `irqbalance` service can be enabled with the following command:

    $ sudo systemctl enable irqbalance.service

CCE-80263-7

Disable Odd Job Daemon (oddjobd)

The `oddjobd` service exists to provide an interface and access control mechanism through which specified privileged tasks can run tasks for unprivileged client applications. Communication with `oddjobd` through the system message bus. The `oddjobd` service can be disabled with the following command:

    $ sudo systemctl disable oddjobd.service

CCE-80272-8

Disable SMART Disk Monitoring Service (smartd)

SMART (Self-Monitoring, Analysis, and Reporting Technology) is a feature of hard drives that allows them to detect symptoms of disk failure and relay an appropriate warning. The `smartd` service can be disabled with the following command:

    $ sudo systemctl disable smartd.service

CCE-80266-0

Disable Apache Qpid (qpidd)

The `qpidd` service provides high speed, secure, guaranteed delivery services. It is an implementation of the Advanced Message Queuing Protocol. By default the qpidd service will bind to port 5672 and listen for connection attempts. The `qpidd` service can be disabled with the following command:

    $ sudo systemctl disable qpidd.service

CCE-26872-2

Disable Automatic Bug Reporting Tool (abrtd)

The Automatic Bug Reporting Tool (`abrtd`) daemon collects and reports crash data when an application crash is detected. Using a variety of plugins, abrtd can email crash reports to system administrators, log crash reports to files, or forward crash reports to a centralized issue tracking system such as RHTSupport. The `abrtd` service can be disabled with the following command:

    $ sudo systemctl disable abrtd.service

CCE-80256-1

Disable CPU Speed (cpupower)

The `cpupower` service can adjust the clock speed of supported CPUs based upon the current processing load thereby conserving power and reducing heat. The `cpupower` service can be disabled with the following command:

    $ sudo systemctl disable cpupower.service

CCE-80254-6

Disable Control Group Config (cgconfig)

Control groups allow an administrator to allocate system resources (such as CPU, memory, network bandwidth, etc) among a defined group (or groups) of processes executing on a system. The `cgconfig` daemon starts at boot and establishes the predefined control groups. The `cgconfig` service can be disabled with the following command:

    $ sudo systemctl disable cgconfig.service

CCE-80271-0

Disable Cyrus SASL Authentication Daemon (saslauthd)

The `saslauthd` service handles plaintext authentication requests on behalf of the SASL library. The service isolates all code requiring superuser privileges for SASL authentication into a single process, and can also be used to provide proxy authentication services to clients that do not understand SASL based authentication. The `saslauthd` service can be disabled with the following command:

    $ sudo systemctl disable saslauthd.service

CCE-80262-9

Disable ntpdate Service (ntpdate)

The `ntpdate` service sets the local hardware clock by polling NTP servers when the system boots. It synchronizes to the NTP servers listed in `/etc/ntp/step-tickers` or `/etc/ntp.conf` and then sets the local hardware clock to the newly synchronized system time. The `ntpdate` service can be disabled with the following command:

    $ sudo systemctl disable ntpdate.service

CCE-80258-7

Disable KDump Kernel Crash Analyzer (kdump)

The `kdump` service provides a kernel crash dump analyzer. It uses the `kexec` system call to boot a secondary kernel ("capture" kernel) following a system crash, which can load information from the crashed kernel for analysis. The `kdump` service can be disabled with the following command:

    $ sudo systemctl disable kdump.service

CCE-80270-2

Disable Red Hat Subscription Manager Daemon (rhsmcertd)

The Red Hat Subscription Manager (rhsmcertd) periodically checks for changes in the entitlement certificates for a registered system and updates it accordingly. The `rhsmcertd` service can be disabled with the following command:

    $ sudo systemctl disable rhsmcertd.service

CCE-80264-5

Disable Portreserve (portreserve)

The `portreserve` service is a TCP port reservation utility that can be used to prevent portmap from binding to well known TCP ports that are required for other services. The `portreserve` service can be disabled with the following command:

    $ sudo systemctl disable portreserve.service

CCE-80273-6

Disable System Statistics Reset Service (sysstat)

The `sysstat` service resets various I/O and CPU performance statistics to zero in order to begin counting from a fresh state at boot time. The `sysstat` service can be disabled with the following command:

    $ sudo systemctl disable sysstat.service

CCE-80285-0

Disable Squid

The `squid` service can be disabled with the following command:

    $ sudo systemctl disable squid.service

CCE-80286-8

Uninstall squid Package

The `squid` package can be removed with the following command:

    $ sudo yum erase squid

CCE-80289-2

Disable Postfix Network Listening

Edit the file `/etc/postfix/main.cf` to ensure that only the following `inet_interfaces` line appears:

    inet_interfaces = localhost

CCE-80512-7

Prevent Unrestricted Mail Relaying

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'

CCE-80290-0

Configure SMTP Greeting Banner

Edit `/etc/postfix/main.cf`, and add or correct the following line, substituting some other wording for the banner information if you prefer:

    smtpd_banner = $myhostname ESMTP

CCE-80288-4

Uninstall Sendmail Package

Sendmail is not the default mail transfer agent and is not installed by default. The `sendmail` package can be removed with the following command:

    $ sudo yum erase sendmail

CCE-80287-6

Enable Postfix Service

The Postfix mail transfer agent is used for local mail delivery within the system. The default configuration only listens for connections to the default SMTP port (port 25) on the loopback interface (127.0.0.1). It is recommended to leave this service enabled for local mail delivery. The `postfix` service can be enabled with the following command:

    $ sudo systemctl enable postfix.service

CCE-80298-3

Configure Dovecot to Use the SSL Key file

This option tells Dovecot where to find the the mail server's SSL Key.
Edit `/etc/dovecot/conf.d/10-ssl.conf` and add or correct the following line (note: the path below is the default path set by the Dovecot installation. If you are using a different path, ensure you reference the appropriate file):

    ssl_key = </etc/pki/dovecot/private/dovecot.pem

CCE-80299-1

Disable Plaintext Authentication

To prevent Dovecot from attempting plaintext authentication of clients, edit `/etc/dovecot/conf.d/10-auth.conf` and add or correct the following line:

    disable_plaintext_auth = yes

CCE-80296-7

Enable the SSL flag in /etc/dovecot.conf

To allow clients to make encrypted connections the `ssl` flag in Dovecot's configuration file needs to be set to `yes`.
Edit `/etc/dovecot/conf.d/10-ssl.conf` and add or correct the following line:

    ssl = yes

CCE-80297-5

Configure Dovecot to Use the SSL Certificate file

This option tells Dovecot where to find the the mail server's SSL Certificate.
Edit `/etc/dovecot/conf.d/10-ssl.conf` and add or correct the following line (note: the path below is the default path set by the Dovecot installation. If you are using a different path, ensure you reference the appropriate file):

    ssl_cert = </etc/pki/dovecot/certs/dovecot.pem

CCE-80294-2

Disable Dovecot Service

The `dovecot` service can be disabled with the following command:

    $ sudo systemctl disable dovecot.service

CCE-80295-9

Uninstall dovecot Package

The `dovecot` package can be uninstalled with the following command:

    $ sudo yum erase dovecot

CCE-80241-3

Use Root-Squashing on All Exports

If a filesystem is exported using root squashing, requests from root on the client are considered to be unprivileged (mapped to a user such as nobody). This provides some mild protection against remote abuse of an NFS server. Root squashing is enabled by default, and should not be disabled.
Ensure that no line in `/etc/exports` contains the option `no_root_squash`.

CCE-80242-1

Restrict NFS Clients to Privileged Ports

By default, the server NFS implementation requires that all client requests be made from ports less than 1024. If your organization has control over systems connected to its network, and if NFS requests are prohibited at the border firewall, this offers some protection against malicious requests from unprivileged users. Therefore, the default should not be changed.
To ensure that the default has not been changed, ensure no line in `/etc/exports` contains the option `insecure`.

CCE-27464-7 | Use Kerberos Security on All Exports | Using Kerberos on all exported mounts prevents a malicious client or user from impersonating a system user. To cryptography authenticate users to the NFS server, add `sec=krb5:krb5i:krb5p` to each export in `/etc/exports`.

CCE-80243-9

Ensure Insecure File Locking is Not Allowed

By default the NFS server requires secure file-lock requests, which require credentials from the client in order to lock a file. Most NFS clients send credentials with file lock requests, however, there are a few clients that do not send credentials when requesting a file-lock, allowing the client to only be able to lock world-readable files. To get around this, the `insecure_locks` option can be used so these clients can access the desired export. This poses a security risk by potentially allowing the client access to data for which it does not have authorization. Remove any instances of the `insecure_locks` option from the file `/etc/exports`.

CCE-80229-8

Disable Secure RPC Client Service (rpcgssd)

The rpcgssd service manages RPCSEC GSS contexts required to secure protocols that use RPC (most often Kerberos and NFS). The rpcgssd service is the client-side of RPCSEC GSS. If the system does not require secure RPC then this service should be disabled. The `rpcgssd` service can be disabled with the following command:

    $ sudo systemctl disable rpcgssd.service

CCE-80231-4

Disable RPC ID Mapping Service (rpcidmapd)

The rpcidmapd service is used to map user names and groups to UID and GID numbers on NFSv4 mounts. If NFS is not in use on the local system then this service should be disabled. The `rpcidmapd` service can be disabled with the following command:

    $ sudo systemctl disable rpcidmapd.service

CCE-80228-0

Disable Network File System Lock Service (nfslock)

The Network File System Lock (nfslock) service starts the required remote procedure call (RPC) processes which allow clients to lock files on the server. If the local system is not configured to mount NFS filesystems then this service should be disabled. The `nfslock` service can be disabled with the following command:

    $ sudo systemctl disable nfslock.service

CCE-80230-6

Disable rpcbind Service

The rpcbind utility maps RPC services to the ports on which they listen. RPC processes notify rpcbind when they start, registering the ports they are listening on and the RPC program numbers they expect to serve. The rpcbind service redirects the client to the proper port number so it can communicate with the requested service. If the system does not require RPC (such as for NFS servers) then this service should be disabled. The `rpcbind` service can be disabled with the following command:

    $ sudo systemctl disable rpcbind.service

CCE-80232-2

Configure lockd to use static TCP port

Configure the `lockd` daemon to use a static TCP port as opposed to letting the RPC Bind service dynamically assign a port. Edit the file `/etc/sysconfig/nfs`. Add or correct the following line:

    LOCKD_TCPPORT=lockd-port

Where `lockd-port` is a port which is not used by any other service on your network.

CCE-80233-0

Configure lockd to use static UDP port

Configure the `lockd` daemon to use a static UDP port as opposed to letting the RPC Bind service dynamically assign a port. Edit the file `/etc/sysconfig/nfs`. Add or correct the following line:

    LOCKD_UDPPORT=lockd-port

Where `lockd-port` is a port which is not used by any other service on your network.

CCE-80234-8

Configure statd to use static port

Configure the `statd` daemon to use a static port as opposed to letting the RPC Bind service dynamically assign a port. Edit the file `/etc/sysconfig/nfs`. Add or correct the following line:

    STATD_PORT=statd-port

Where `statd-port` is a port which is not used by any other service on your network.

CCE-80235-5

Configure mountd to use static port

Configure the `mountd` daemon to use a static port as opposed to letting the RPC Bind service dynamically assign a port. Edit the file `/etc/sysconfig/nfs`. Add or correct the following line:

    MOUNTD_PORT=statd-port

Where `mountd-port` is a port which is not used by any other service on your network.

CCE-27458-9 | Mount Remote Filesystems with Kerberos Security | Add the `sec=krb5:krb5i:krb5p` option to the fourth column of `/etc/fstab` for the line which controls mounting of any NFS mounts.
CCE-80436-9 | Mount Remote Filesystems with noexec | Add the `noexec` option to the fourth column of `/etc/fstab` for the line which controls mounting of any NFS mounts.
CCE-80240-5 | Mount Remote Filesystems with nosuid | Add the `nosuid` option to the fourth column of `/etc/fstab` for the line which controls mounting of any NFS mounts.
CCE-80239-7 | Mount Remote Filesystems with nodev | Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of any NFS mounts.

CCE-80236-3

Specify UID and GID for Anonymous NFS Connections

To specify the UID and GID for remote root users, edit the `/etc/exports` file and add the following for each export:

    anonuid=value greater than UID_MAX from /etc/login.defs
    anongid=value greater than GID_MAX from /etc/login.defs

Alternatively, functionally equivalent values of 60001, 65534, 65535 may be used.

CCE-80237-1

Disable Network File System (nfs)

The Network File System (NFS) service allows remote hosts to mount and interact with shared filesystems on the local system. If the local system is not designated as a NFS server then this service should be disabled. The `nfs` service can be disabled with the following command:

    $ sudo systemctl disable nfs.service

CCE-80238-9

Disable Secure RPC Server Service (rpcsvcgssd)

The rpcsvcgssd service manages RPCSEC GSS contexts required to secure protocols that use RPC (most often Kerberos and NFS). The rpcsvcgssd service is the server-side of RPCSEC GSS. If the system does not require secure RPC then this service should be disabled. The `rpcsvcgssd` service can be disabled with the following command:

    $ sudo systemctl disable rpcsvcgssd.service

CCE-80283-5

Disable Printer Browsing Entirely if Possible

By default, CUPS listens on the network for printer list broadcasts on UDP port 631. This functionality is called printer browsing. To disable printer browsing entirely, edit the CUPS configuration file, located at `/etc/cups/cupsd.conf`, to include the following:

    Browsing Off
    BrowseAllow none

CCE-80284-3

Disable Print Server Capabilities

To prevent remote users from potentially connecting to and using locally configured printers, disable the CUPS print server sharing capabilities. To do so, limit how the server will listen for print jobs by removing the more generic port directive from /etc/cups/cupsd.conf:

    Port 631

and replacing it with the `Listen` directive:

    Listen localhost:631

This will prevent remote users from printing to locally configured printers while still allowing local users on the system to print normally.

CCE-80282-7

Disable the CUPS Service

The `cups` service can be disabled with the following command:

    $ sudo systemctl disable cups.service

CCE-80338-7

Disable Avahi Server Software

The `avahi-daemon` service can be disabled with the following command:

    $ sudo systemctl disable avahi-daemon.service

CCE-80340-3

Check Avahi Responses' TTL Field

To make Avahi ignore packets unless the TTL field is 255, edit `/etc/avahi/avahi-daemon.conf` and ensure the following line appears in the `[server]` section:

    check-response-ttl=yes

CCE-80342-9

Disable Avahi Publishing

To prevent other mDNS stacks from running, edit `/etc/avahi/avahi-daemon.conf` and ensure the following line appears in the `[server]` section:

    disallow-other-stacks=yes

CCE-80343-7

Restrict Information Published by Avahi

If it is necessary to publish some information to the network, it should not be joined by any extraneous information, or by information supplied by a non-trusted source on the system. Prevent user applications from using Avahi to publish services by adding or correcting the following line in the `[publish]` section:

    disable-user-service-publishing=yes

Implement as many of the following lines as possible, to restrict the information published by Avahi.

    publish-addresses=no
    publish-hinfo=no
    publish-workstation=no
    publish-domain=no

Inspect the files in the directory `/etc/avahi/services/`. Unless there is an operational need to publish information about each of these services, delete the corresponding file.

CCE-80339-5

Serve Avahi Only via Required Protocol

If you are using only IPv4, edit `/etc/avahi/avahi-daemon.conf` and ensure the following line exists in the `[server]` section:

    use-ipv6=no

Similarly, if you are using only IPv6, disable IPv4 sockets with the line:

    use-ipv4=no

CCE-80341-1

Prevent Other Programs from Using Avahi's Port

To prevent other mDNS stacks from running, edit `/etc/avahi/avahi-daemon.conf` and ensure the following line appears in the `[server]` section:

    disallow-other-stacks=yes

Use Only Strong MACs

Limit the MACs to strong hash algorithms. The following line in `/etc/ssh/sshd_config` demonstrates use of those MACs:

    MACs 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

CCE-80372-6

Disable SSH Support for User Known Hosts

SSH can allow system users user host-based authentication to connect to systems if a cache of the remote systems public keys are available. This should be disabled.
To ensure this behavior is disabled, add or correct the following line in `/etc/ssh/sshd_config`:

    IgnoreUserKnownHosts yes

CCE-27471-2

Disable SSH Access via Empty Passwords

To explicitly disallow SSH login from accounts with empty passwords, add or correct the following line in `/etc/ssh/sshd_config`:

    PermitEmptyPasswords no

Any accounts with empty passwords should be disabled immediately, and PAM configuration should prevent users from being able to assign themselves empty passwords.

CCE-27082-7

Set SSH Client Alive Count

To ensure the SSH idle timeout occurs precisely when the `ClientAliveCountMax` is set, edit `/etc/ssh/sshd_config` as follows:

    ClientAliveCountMax 0

CCE-80373-4

Disable SSH Support for Rhosts RSA Authentication

SSH can allow authentication through the obsolete rsh command through the use of the authenticating user's SSH keys. This should be disabled.
To ensure this behavior is disabled, add or correct the following line in `/etc/ssh/sshd_config`:

    RhostsRSAAuthentication no

CCE-80219-9

Limit Users' SSH Access

By default, the SSH configuration allows any user with an account to access the system. In order to specify the users that are allowed to login via SSH and deny all other users, add or correct the following line in the `/etc/ssh/sshd_config` file:

    DenyUsers USER1 USER2

Where `USER1` and `USER2` are valid user names.

CCE-27314-4

Enable SSH Warning Banner

To enable the warning banner and ensure it is consistent across the system, add or correct the following line in `/etc/ssh/sshd_config`:

    Banner /etc/issue

Another section contains information on how to create an appropriate system-wide warning banner.

CCE-27455-5

Use Only FIPS 140-2 Validated MACs

Limit the MACs to those hash algorithms which are FIPS-approved. The following line in `/etc/ssh/sshd_config` demonstrates use of FIPS-approved MACs:

    MACs hmac-sha2-512,hmac-sha2-256

Only the following message authentication codes are FIPS 140-2 certified on RHEL 7:
- hmac-sha1
- hmac-sha2-256
- hmac-sha2-512
- hmac-sha1-etm@openssh.com
- hmac-sha2-256-etm@openssh.com
- hmac-sha2-512-etm@openssh.com
Any combination of the above MACs will pass this check. Official FIPS 140-2 paperwork for RHEL7 can be found at http://csrc.nist.gov/groups/STM/cmvp/documents/140-1/140sp/140sp2630.pdf.

Set LogLevel to INFO

The INFO parameter specifices that record login and logout activity will be logged. To specify the log level in SSH, add or correct the following line in the `/etc/ssh/sshd_config` file:

    LogLevel INFO

CCE-80221-5

Disable Kerberos Authentication

Unless needed, SSH should not permit extraneous or unnecessary authentication mechanisms like Kerberos. To disable Kerberos authentication, add or correct the following line in the `/etc/ssh/sshd_config` file:

    KerberosAuthentication no

CCE-27320-1

Allow Only SSH Protocol 2

Only SSH protocol version 2 connections should be permitted. The default setting in `/etc/ssh/sshd_config` is correct, and can be verified by ensuring that the following line appears:

    Protocol 2

CCE-27377-1

Disable SSH Support for .rhosts Files

SSH can emulate the behavior of the obsolete rsh command in allowing users to enable insecure access to their accounts via `.rhosts` files.
To ensure this behavior is disabled, add or correct the following line in `/etc/ssh/sshd_config`:

    IgnoreRhosts yes

CCE-27433-2

Set SSH Idle Timeout Interval

SSH allows administrators to set an idle timeout interval. After this interval has passed, the idle user will be automatically logged out.
To set an idle timeout interval, edit the following line in `/etc/ssh/sshd_config` as follows:

    ClientAliveInterval interval

The timeout interval is given in seconds. To have a timeout of 10 minutes, set interval to 600.
If a shorter timeout has already been set for the login shell, that value will preempt any SSH setting made here. Keep in mind that some processes may stop SSH from correctly detecting that the user is idle.

CCE-27363-1

Do Not Allow SSH Environment Options

To ensure users are not able to override environment options to the SSH daemon, add or correct the following line in `/etc/ssh/sshd_config`:

    PermitUserEnvironment no

CCE-80226-4

Enable Encrypted X11 Forwarding

By default, remote X11 connections are not encrypted when initiated by users. SSH has the capability to encrypt remote X11 connections when SSH's `X11Forwarding` option is enabled.
To enable X11 Forwarding, add or correct the following line in `/etc/ssh/sshd_config`:

    X11Forwarding yes

CCE-27295-5

Use Only FIPS 140-2 Validated Ciphers

Limit the ciphers to those algorithms which are FIPS-approved. Counter (CTR) mode is also preferred over cipher-block chaining (CBC) mode. The following line in `/etc/ssh/sshd_config` demonstrates use of FIPS 140-2 validated ciphers:

    Ciphers aes128-ctr,aes192-ctr,aes256-ctr

The following ciphers are FIPS 140-2 certified on RHEL 7:
- aes128-ctr
- aes192-ctr
- aes256-ctr
- aes128-cbc
- aes192-cbc
- aes256-cbc
- 3des-cbc
- rijndael-cbc@lysator.liu.se
Any combination of the above ciphers will pass this check. Official FIPS 140-2 paperwork for RHEL7 can be found at http://csrc.nist.gov/groups/STM/cmvp/documents/140-1/140sp/140sp2630.pdf.

CCE-27413-4

Disable Host-Based Authentication

SSH's cryptographic host-based authentication is more secure than `.rhosts` authentication. However, it is not recommended that hosts unilaterally trust one another, even within an organization.
To disable host-based authentication, add or correct the following line in `/etc/ssh/sshd_config`:

    HostbasedAuthentication no

CCE-80361-9 | Enable SSH Server firewalld Firewall exception | By default, inbound connections to SSH's port are allowed. If the SSH server is being used but denied by the firewall, this exception should be added to the firewall configuration. To configure `firewalld` to allow access, run the following command(s): `firewall-cmd --permanent --add-service=ssh`

Set SSH authentication attempt limit

The `MaxAuthTries` parameter specifies the maximum number of authentication attempts permitted per connection. Once the number of failures reaches half this value, additional failures are logged. to set MaxAUthTries edit `/etc/ssh/sshd_config` as follows:

    MaxAuthTries tries

CCE-80222-3

Enable Use of Strict Mode Checking

SSHs StrictModes option checks file and ownership permissions in the user's home directory `.ssh` folder before accepting login. If world- writable permissions are found, logon is rejected. To enable StrictModes in SSH, add or correct the following line in the `/etc/ssh/sshd_config` file:

    StrictModes yes

CCE-80223-1

Enable Use of Privilege Separation

When enabled, SSH will create an unprivileged child process that has the privilege of the authenticated user. To enable privilege separation in SSH, add or correct the following line in the `/etc/ssh/sshd_config` file:

    UsePrivilegeSeparation sandbox

CCE-80225-6

Print Last Log

When enabled, SSH will display the date and time of the last successful account logon. To enable LastLog in SSH, add or correct the following line in the `/etc/ssh/sshd_config` file:

    PrintLastLog yes

Use Only Strong Ciphers

Limit the ciphers to strong algorithms. Counter (CTR) mode is also preferred over cipher-block chaining (CBC) mode. The following line in `/etc/ssh/sshd_config` demonstrates use of those ciphers:

    Ciphers aes128-ctr,aes192-ctr,aes256-ctr

    chacha20-poly1305@openssh.com,aes256-gcm@openssh.com,aes128-gcm@openssh.com,aes256-ctr,aes128-ctr

The man page `sshd_config(5)` contains a list of supported ciphers.

CCE-80220-7

Disable GSSAPI Authentication

Unless needed, SSH should not permit extraneous or unnecessary authentication mechanisms like GSSAPI. To disable GSSAPI authentication, add or correct the following line in the `/etc/ssh/sshd_config` file:

    GSSAPIAuthentication no

CCE-80224-9

Disable Compression Or Set Compression to delayed

Compression is useful for slow network connections over long distances but can cause performance issues on local LANs. If use of compression is required, it should be enabled only after a user has authenticated; otherwise , it should be disabled. To disable compression or delay compression until after a user has successfully authenticated, add or correct the following line in the `/etc/ssh/sshd_config` file:

    Compression no

or

    Compression delayed

CCE-27445-6

Disable SSH Root Login

The root user should never be allowed to login to a system directly over a network. To disable root login via SSH, add or correct the following line in `/etc/ssh/sshd_config`:

    PermitRootLogin no

CCE-80217-3

Disable SSH Server If Possible (Unusual)

The SSH server service, sshd, is commonly needed. However, if it can be disabled, do so. The `sshd` service can be disabled with the following command:

    $ sudo systemctl disable sshd.service

This is unusual, as SSH is a common method for encrypted and authenticated remote access.

CCE-80215-7

Install the OpenSSH Server Package

The `openssh-server` package should be installed. The `openssh-server` package can be installed with the following command:

    $ sudo yum install openssh-server

CCE-80218-1 | Remove SSH Server firewalld Firewall exception (Unusual) | By default, inbound connections to SSH's port are allowed. If the SSH server is not being used, this exception should be removed from the firewall configuration. To configure `firewalld` to not allow access, run the following command(s): ``

CCE-80216-5

Enable the OpenSSH Service

The SSH server service, sshd, is commonly needed. The `sshd` service can be enabled with the following command:

    $ sudo systemctl enable sshd.service

CCE-27311-0

Verify Permissions on SSH Server Public *.pub Key Files

To properly set the permissions of `/etc/ssh/*.pub`, run the command:

    $ sudo chmod 0644 /etc/ssh/*.pub

CCE-27485-2

Verify Permissions on SSH Server Private *_key Key Files

To properly set the permissions of `/etc/ssh/*_key`, run the command:

    $ sudo chmod 0640 /etc/ssh/*_key

CCE-27343-3

Ensure Logs Sent To Remote Host

To configure rsyslog to send logs to a remote log server, open `/etc/rsyslog.conf` and read and understand the last section of the file, which describes the multiple directives necessary to activate remote logging. Along with these other directives, the system can be configured to forward its logs to a particular log server by adding or correcting one of the following lines, substituting `loghost.example.com` appropriately. The choice of protocol depends on the environment of the system; although TCP and RELP provide more reliable message delivery, they may not be supported in all environments.
To use UDP for log message delivery:

    *.* @loghost.example.com

To use TCP for log message delivery:

    *.* @@loghost.example.com

To use RELP for log message delivery:

    *.* :omrelp:loghost.example.com

There must be a resolvable DNS CNAME or Alias record set to "" for logs to be sent correctly to the centralized logging utility.

CCE-80191-0

Ensure System Log Files Have Correct Permissions

The file permissions for all log files written by `rsyslog` should be set to 600, or more restrictive. These log files are determined by the second part of each Rule line in `/etc/rsyslog.conf` and typically all appear in `/var/log`. For each log file LOGFILE referenced in `/etc/rsyslog.conf`, run the following command to inspect the file's permissions:

    $ ls -l LOGFILE

If the permissions are not 600 or more restrictive, run the following command to correct this:

    $ sudo chmod 0600 LOGFILE

CCE-80189-4

Ensure Log Files Are Owned By Appropriate User

The owner of all log files written by `rsyslog` should be root. These log files are determined by the second part of each Rule line in `/etc/rsyslog.conf` and typically all appear in `/var/log`. For each log file LOGFILE referenced in `/etc/rsyslog.conf`, run the following command to inspect the file's owner:

    $ ls -l LOGFILE

If the owner is not `root`, run the following command to correct this:

    $ sudo chown root LOGFILE

CCE-80190-2

Ensure Log Files Are Owned By Appropriate Group

The group-owner of all log files written by `rsyslog` should be root. These log files are determined by the second part of each Rule line in `/etc/rsyslog.conf` and typically all appear in `/var/log`. For each log file LOGFILE referenced in `/etc/rsyslog.conf`, run the following command to inspect the file's group owner:

    $ ls -l LOGFILE

If the owner is not `root`, run the following command to correct this:

    $ sudo chgrp root LOGFILE

CCE-80380-9

Ensure cron Is Logging To Rsyslog

Cron logging must be implemented to spot intrusions or trace cron job status. If `cron` is not logging to `rsyslog`, it can be implemented by adding the following to the RULES section of `/etc/rsyslog.conf`:

    cron.*                                                  /var/log/cron

CCE-80194-4

Enable rsyslog to Accept Messages via UDP, if Acting As Log Server

The `rsyslog` daemon should not accept remote messages unless the system acts as a log server. If the system needs to act as a central log server, add the following lines to `/etc/rsyslog.conf` to enable reception of messages over UDP:

    $ModLoad imudp
    $UDPServerRun 514

CCE-80192-8

Ensure rsyslog Does Not Accept Remote Messages Unless Acting As Log Server

The `rsyslog` daemon should not accept remote messages unless the system acts as a log server. To ensure that it is not listening on the network, ensure the following lines are not found in `/etc/rsyslog.conf`:

    $ModLoad imtcp
    $InputTCPServerRun port
    $ModLoad imudp
    $UDPServerRun port
    $ModLoad imrelp
    $InputRELPServerRun port

CCE-80193-6

Enable rsyslog to Accept Messages via TCP, if Acting As Log Server

The `rsyslog` daemon should not accept remote messages unless the system acts as a log server. If the system needs to act as a central log server, add the following lines to `/etc/rsyslog.conf` to enable reception of messages over TCP:

    $ModLoad imtcp
    $InputTCPServerRun 514

CCE-80197-7

Configure Logwatch SplitHosts Line

If `SplitHosts` is set, Logwatch will separate entries by hostname. This makes the report longer but significantly more usable. If it is not set, then Logwatch will not report which host generated a given log entry, and that information is almost always necessary

     SplitHosts = yes

CCE-80196-9

Configure Logwatch HostLimit Line

On a central logserver, you want Logwatch to summarize all syslog entries, including those which did not originate on the logserver itself. The `HostLimit` setting tells Logwatch to report on all hosts, not just the one on which it is running.

     HostLimit = no

CCE-80195-1

Ensure Logrotate Runs Periodically

The `logrotate` utility allows for the automatic rotation of log files. The frequency of rotation is specified in `/etc/logrotate.conf`, which triggers a cron task. To configure logrotate to run daily, add or correct the following line in `/etc/logrotate.conf`:

    # rotate log files frequency
    daily

CCE-80198-5

Disable Logwatch on Clients if a Logserver Exists

Does your site have a central logserver which has been configured to report on logs received from all systems? If so:

    $ sudo rm /etc/cron.daily/0logwatch

If no logserver exists, it will be necessary for each system to run Logwatch individually. Using a central logserver provides the security and reliability benefits discussed earlier, and also makes monitoring logs easier and less time-intensive for administrators.

CCE-80188-6

Enable rsyslog Service

The `rsyslog` service provides syslog-style logging by default on Red Hat Enterprise Linux 7. The `rsyslog` service can be enabled with the following command:

    $ sudo systemctl enable rsyslog.service

CCE-80187-8

Ensure rsyslog is Installed

Rsyslog is installed by default. The `rsyslog` package can be installed with the following command:

    $ sudo yum install rsyslog

CCE-80335-1

Configure Kernel Parameter for Accepting Source-Routed Packets for Interfaces By Default

To set the runtime status of the `net.ipv6.conf.default.accept_source_route` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.default.accept_source_route=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.default.accept_source_route = 0

CCE-80179-5

Configure Kernel Parameter for Accepting Source-Routed Packets for All Interfaces

To set the runtime status of the `net.ipv6.conf.all.accept_source_route` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.all.accept_source_route=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.all.accept_source_route = 0

CCE-80356-9

Disable Kernel Parameter for IPv6 Forwarding

To set the runtime status of the `net.ipv6.conf.all.forwarding` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.all.forwarding=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.all.forwarding = 0

CCE-80182-9

Configure Accepting IPv6 Redirects By Default

To set the runtime status of the `net.ipv6.conf.all.accept_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.all.accept_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.all.accept_redirects = 0

CCE-80181-1

Configure Accepting IPv6 Router Advertisements

To set the runtime status of the `net.ipv6.conf.default.accept_ra` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.default.accept_ra=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.default.accept_ra = 0

CCE-80180-3

Configure Accepting IPv6 Router Advertisements

To set the runtime status of the `net.ipv6.conf.all.accept_ra` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.all.accept_ra=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.all.accept_ra = 0

CCE-80183-7

Configure Accepting IPv6 Redirects By Default

To set the runtime status of the `net.ipv6.conf.default.accept_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv6.conf.default.accept_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv6.conf.default.accept_redirects = 0

CCE-80186-0

Manually Assign IPv6 Router Address

Edit the file `/etc/sysconfig/network-scripts/ifcfg-interface`, and add or correct the following line (substituting your gateway IP as appropriate):

    IPV6_DEFAULTGW=2001:0DB8::0001

Router addresses should be manually set and not accepted via any auto-configuration or router advertisement.

CCE-80184-5

Manually Assign Global IPv6 Address

To manually assign an IP address for an interface, edit the file `/etc/sysconfig/network-scripts/ifcfg-interface`. Add or correct the following line (substituting the correct IPv6 address):

    IPV6ADDR=2001:0DB8::ABCD/64

Manually assigning an IP address is preferable to accepting one from routers or from the network otherwise. The example address here is an IPv6 address reserved for documentation purposes, as defined by RFC3849.

CCE-80185-2

Use Privacy Extensions for Address

To introduce randomness into the automatic generation of IPv6 addresses, add or correct the following line in `/etc/sysconfig/network-scripts/ifcfg-interface`:

    IPV6_PRIVACY=rfc3041

Automatically-generated IPv6 addresses are based on the underlying hardware (e.g. Ethernet) address, and so it becomes possible to track a piece of hardware over its lifetime using its traffic. If it is important for a system's IP address to not trivially reveal its hardware address, this setting should be applied.

CCE-80176-1

Disable Interface Usage of IPv6

To disable interface usage of IPv6, add or correct the following lines in `/etc/sysconfig/network`:

    NETWORKING_IPV6=no
    IPV6INIT=no

CCE-80177-9

Disable Support for RPC IPv6

RPC services for NFSv4 try to load transport modules for `udp6` and `tcp6` by default, even if IPv6 has been disabled in `/etc/modprobe.d`. To prevent RPC services such as `rpc.mountd` from attempting to start IPv6 network listeners, remove or comment out the following two lines in `/etc/netconfig`:

    udp6       tpi_clts      v     inet6    udp     -       -
    tcp6       tpi_cots_ord  v     inet6    tcp     -       -

CCE-80175-3

Disable IPv6 Networking Support Automatic Loading

To disable support for (`ipv6`) add the following line to `/etc/sysctl.d/ipv6.conf` (or another file in `/etc/sysctl.d`):

    net.ipv6.conf.all.disable_ipv6 = 1

This disables IPv6 on all network interfaces as other services and system functionality require the IPv6 stack loaded to work.

CCE-80171-2

Verify Any Configured IPSec Tunnel Connections

Libreswan provides an implementation of IPsec and IKE, which permits the creation of secure tunnels over untrusted networks. As such, IPsec can be used to circumvent certain network requirements such as filtering. Verify that if any IPsec connection (`conn`) configured in `/etc/ipsec.conf` and `/etc/ipsec.d` exists is an approved organizational connection.

CCE-80170-4

Install libreswan Package

The Libreswan package provides an implementation of IPsec and IKE, which permits the creation of secure tunnels over untrusted networks. The `libreswan` package can be installed with the following command:

    $ sudo yum install libreswan

CCE-27349-0

Set Default firewalld Zone for Incoming Packets

To set the default zone to `drop` for the built-in default zone which processes incoming IPv4 and IPv6 packets, modify the following line in `/etc/firewalld/firewalld.conf` to be:

    DefaultZone=drop

CCE-80447-6

Configure the Firewalld Ports

Configure the `firewalld` ports to allow approved services to have access to the system. To configure `firewalld` to open ports, run the following command:

    $ sudo firewall-cmd --permanent --add-port=port_number/tcp

or

    $ sudo firewall-cmd --permanent --add-port=service_name

Run the command list above for each of the ports listed below: To configure `firewalld` to allow access, run the following command(s): `firewall-cmd --permanent --add-service=ssh`

CCE-80542-4

Configure firewalld To Rate Limit Connections

Create a direct firewall rule to protect against DoS attacks with the following command:

    $ sudo firewall-cmd --permanent --direct --add-rule ipv4 filter INPUT_direct 0 -p tcp -m limit --limit 25/minute --limit-burst 100  -j ACCEPT

CCE-27361-5

Verify firewalld Enabled

The `firewalld` service can be enabled with the following command:

    $ sudo systemctl enable firewalld.service

Install firewalld

Install the firewalld package with the command:

    $ sudo yum install firewalld

CCE-80162-1

Configure Kernel Parameter for Accepting Source-Routed Packets By Default

To set the runtime status of the `net.ipv4.conf.default.accept_source_route` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.default.accept_source_route=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.default.accept_source_route = 0

CCE-80166-2

Configure Kernel Parameter to Ignore Bogus ICMP Error Responses

To set the runtime status of the `net.ipv4.icmp_ignore_bogus_error_responses` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.icmp_ignore_bogus_error_responses=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.icmp_ignore_bogus_error_responses = 1

CCE-80163-9

Configure Kernel Parameter for Accepting ICMP Redirects By Default

To set the runtime status of the `net.ipv4.conf.default.accept_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.default.accept_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.default.accept_redirects = 0

CCE-80168-8

Configure Kernel Parameter to Use Reverse Path Filtering by Default

To set the runtime status of the `net.ipv4.conf.default.rp_filter` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.default.rp_filter=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.default.rp_filter = 1

CCE-80159-7

Configure Kernel Parameter for Accepting Secure Redirects for All Interfaces

To set the runtime status of the `net.ipv4.conf.all.secure_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.all.secure_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.all.secure_redirects = 0

CCE-27495-1

Configure Kernel Parameter to Use TCP Syncookies

To set the runtime status of the `net.ipv4.tcp_syncookies` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.tcp_syncookies=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.tcp_syncookies = 1

CCE-80158-9

Configure Kernel Parameter for Accepting ICMP Redirects for All Interfaces

To set the runtime status of the `net.ipv4.conf.all.accept_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.all.accept_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.all.accept_redirects = 0

CCE-80160-5

Configure Kernel Parameter to Log Martian Packets

To set the runtime status of the `net.ipv4.conf.all.log_martians` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.all.log_martians=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.all.log_martians = 1

CCE-80167-0

Configure Kernel Parameter to Use Reverse Path Filtering for All Interfaces

To set the runtime status of the `net.ipv4.conf.all.rp_filter` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.all.rp_filter=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.all.rp_filter = 1

CCE-80165-4

Configure Kernel Parameter to Ignore ICMP Broadcast Echo Requests

To set the runtime status of the `net.ipv4.icmp_echo_ignore_broadcasts` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.icmp_echo_ignore_broadcasts=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.icmp_echo_ignore_broadcasts = 1

CCE-80164-7

Configure Kernel Parameter for Accepting Secure Redirects By Default

To set the runtime status of the `net.ipv4.conf.default.secure_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.default.secure_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.default.secure_redirects = 0

CCE-27434-0

Configure Kernel Parameter for Accepting Source-Routed Packets for All Interfaces

To set the runtime status of the `net.ipv4.conf.all.accept_source_route` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.all.accept_source_route=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.all.accept_source_route = 0

CCE-80161-3

Configure Kernel Parameter to Log Martian Packets By Default

To set the runtime status of the `net.ipv4.conf.default.log_martians` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.default.log_martians=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.default.log_martians = 1

CCE-80157-1

Disable Kernel Parameter for IP Forwarding

To set the runtime status of the `net.ipv4.ip_forward` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.ip_forward=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.ip_forward = 0

CCE-80156-3

Disable Kernel Parameter for Sending ICMP Redirects for All Interfaces

To set the runtime status of the `net.ipv4.conf.all.send_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.all.send_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.all.send_redirects = 0

CCE-80156-3

Disable Kernel Parameter for Sending ICMP Redirects by Default

To set the runtime status of the `net.ipv4.conf.default.send_redirects` kernel parameter, run the following command:

    $ sudo sysctl -w net.ipv4.conf.default.send_redirects=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    net.ipv4.conf.default.send_redirects = 0

CCE-26828-4

Disable DCCP Support

The Datagram Congestion Control Protocol (DCCP) is a relatively new transport layer protocol, designed to support streaming media and telephony. To configure the system to prevent the `dccp` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install dccp /bin/true

CCE-27106-4

Disable SCTP Support

The Stream Control Transmission Protocol (SCTP) is a transport layer protocol, designed to support the idea of message-oriented communication, with several streams of messages within one connection. To configure the system to prevent the `sctp` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install sctp /bin/true

CCE-27327-6

Disable Bluetooth Kernel Modules

The kernel's module loading system can be configured to prevent loading of the Bluetooth module. Add the following to the appropriate `/etc/modprobe.d` configuration file to prevent the loading of the Bluetooth module:

    install bluetooth /bin/true

CCE-27397-9 | Disable WiFi or Bluetooth in BIOS | Some machines that include built-in wireless support offer the ability to disable the device through the BIOS. This is hardware-specific; consult your hardware manual or explore the BIOS setup during boot.

CCE-27328-4

Disable Bluetooth Service

The `bluetooth` service can be disabled with the following command:

    $ sudo systemctl disable bluetooth.service

    $ sudo service bluetooth stop

CCE-27358-1

Deactivate Wireless Network Interfaces

Deactivating wireless network interfaces should prevent normal usage of the wireless capability.
Configure the system to disable all wireless network interfaces with the following command:

    $ sudo nmcli radio wifi off

CCE-80173-8

Disable Zeroconf Networking

Zeroconf networking allows the system to assign itself an IP address and engage in IP communication without a statically-assigned address or even a DHCP server. Automatic address assignment via Zeroconf (or DHCP) is not recommended. To disable Zeroconf automatic route assignment in the 169.254.0.0 subnet, add or correct the following line in `/etc/sysconfig/network`:

    NOZEROCONF=yes

CCE-80357-7

Disable Client Dynamic DNS Updates

Dynamic DNS allows clients to dynamically update their own DNS records. The updates are transmitted by unencrypted means which can reveal information to a potential malicious user. If the system does not require Dynamic DNS, remove all `DHCP_HOSTNAME` references from the `/etc/sysconfig/network-scripts/ifcfg-interface` scripts. If `dhclient` is used, remove all `send host-name hostname` references from the `/etc/dhclient.conf` configuration file and/or any reference from the `/etc/dhcp` directory.

CCE-80438-5

Configure Multiple DNS Servers in /etc/resolv.conf

Multiple Domain Name System (DNS) Servers should be configured in `/etc/resolv.conf`. This provides redundant name resolution services in the event that a domain server crashes. To configure the system to contain as least `2` DNS servers, add a corresponding `nameserver ip_address` entry in `/etc/resolv.conf` for each DNS server where ip_address is the IP address of a valid DNS server. For example:

    search example.com
    nameserver 192.168.0.1
    nameserver 192.168.0.2

CCE-80174-6

Ensure System is Not Acting as a Network Sniffer

The system should not be acting as a network sniffer, which can capture all traffic on the network to which it is connected. Run the following to determine if any interface is running in promiscuous mode:

    $ ip link | grep PROMISC

CCE-RHEL7-CCE-TBD

Disable the openvpn_can_network_connect SELinux Boolean

By default, the SELinux boolean `openvpn_can_network_connect` is enabled. This setting should be disabled. To disable the `openvpn_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P openvpn_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the pcp_bind_all_unreserved_ports SELinux Boolean

By default, the SELinux boolean `pcp_bind_all_unreserved_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `pcp_bind_all_unreserved_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P pcp_bind_all_unreserved_ports off

CCE-RHEL7-CCE-TBD

Disable the ssh_sysadm_login SELinux Boolean

By default, the SELinux boolean `ssh_sysadm_login` is disabled. If this setting is enabled, it should be disabled. To disable the `ssh_sysadm_login` SELinux boolean, run the following command:

    $ sudo setsebool -P ssh_sysadm_login off

CCE-RHEL7-CCE-TBD

Disable the polipo_connect_all_unreserved SELinux Boolean

By default, the SELinux boolean `polipo_connect_all_unreserved` is disabled. If this setting is enabled, it should be disabled. To disable the `polipo_connect_all_unreserved` SELinux boolean, run the following command:

    $ sudo setsebool -P polipo_connect_all_unreserved off

CCE-RHEL7-CCE-TBD

Disable the httpd_sys_script_anon_write SELinux Boolean

By default, the SELinux boolean `httpd_sys_script_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_sys_script_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_sys_script_anon_write off

CCE-RHEL7-CCE-TBD

Disable the httpd_run_stickshift SELinux Boolean

By default, the SELinux boolean `httpd_run_stickshift` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_run_stickshift` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_run_stickshift off

CCE-RHEL7-CCE-TBD

Disable the minidlna_read_generic_user_content SELinux Boolean

By default, the SELinux boolean `minidlna_read_generic_user_content` is disabled. If this setting is enabled, it should be disabled. To disable the `minidlna_read_generic_user_content` SELinux boolean, run the following command:

    $ sudo setsebool -P minidlna_read_generic_user_content off

CCE-RHEL7-CCE-TBD

Disable the mozilla_plugin_use_bluejeans SELinux Boolean

By default, the SELinux boolean `mozilla_plugin_use_bluejeans` is disabled. If this setting is enabled, it should be disabled. To disable the `mozilla_plugin_use_bluejeans` SELinux boolean, run the following command:

    $ sudo setsebool -P mozilla_plugin_use_bluejeans off

CCE-RHEL7-CCE-TBD

Disable the samba_run_unconfined SELinux Boolean

By default, the SELinux boolean `samba_run_unconfined` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_run_unconfined` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_run_unconfined off

CCE-RHEL7-CCE-TBD

Disable the rsync_client SELinux Boolean

By default, the SELinux boolean `rsync_client` is disabled. If this setting is enabled, it should be disabled. To disable the `rsync_client` SELinux boolean, run the following command:

    $ sudo setsebool -P rsync_client off

CCE-RHEL7-CCE-TBD

Disable the logrotate_use_nfs SELinux Boolean

By default, the SELinux boolean `logrotate_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `logrotate_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P logrotate_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the samba_export_all_rw SELinux Boolean

By default, the SELinux boolean `samba_export_all_rw` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_export_all_rw` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_export_all_rw off

CCE-RHEL7-CCE-TBD

Disable the cobbler_anon_write SELinux Boolean

By default, the SELinux boolean `cobbler_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `cobbler_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P cobbler_anon_write off

CCE-RHEL7-CCE-TBD

disable the selinuxuser_execstack SELinux Boolean

By default, the SELinux boolean `selinuxuser_execstack` is enabled. This setting should be disabled as unconfined executables should not be able to make their stack executable. To disable the `selinuxuser_execstack` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_execstack off

CCE-RHEL7-CCE-TBD

Disable the entropyd_use_audio SELinux Boolean

By default, the SELinux boolean `entropyd_use_audio` is enabled. This setting should be disabled as it uses audit input to generate entropy. To disable the `entropyd_use_audio` SELinux boolean, run the following command:

    $ sudo setsebool -P entropyd_use_audio off

CCE-RHEL7-CCE-TBD

Disable the gpg_web_anon_write SELinux Boolean

By default, the SELinux boolean `gpg_web_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `gpg_web_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P gpg_web_anon_write off

CCE-RHEL7-CCE-TBD

Enable the mount_anyfile SELinux Boolean

By default, the SELinux boolean `mount_anyfile` is enabled. If this setting is disabled, it should be enabled to allow any file or directory to be mounted. To enable the `mount_anyfile` SELinux boolean, run the following command:

    $ sudo setsebool -P mount_anyfile on

CCE-RHEL7-CCE-TBD

Disable the smartmon_3ware SELinux Boolean

By default, the SELinux boolean `smartmon_3ware` is disabled. If this setting is enabled, it should be disabled. To disable the `smartmon_3ware` SELinux boolean, run the following command:

    $ sudo setsebool -P smartmon_3ware off

CCE-RHEL7-CCE-TBD

Disable the git_cgi_enable_homedirs SELinux Boolean

By default, the SELinux boolean `git_cgi_enable_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `git_cgi_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P git_cgi_enable_homedirs off

CCE-RHEL7-CCE-TBD

Disable the mailman_use_fusefs SELinux Boolean

By default, the SELinux boolean `mailman_use_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `mailman_use_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P mailman_use_fusefs off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_check_spam SELinux Boolean

By default, the SELinux boolean `httpd_can_check_spam` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_check_spam` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_check_spam off

CCE-RHEL7-CCE-TBD

Disable the fenced_can_ssh SELinux Boolean

By default, the SELinux boolean `fenced_can_ssh` is disabled. If this setting is enabled, it should be disabled. To disable the `fenced_can_ssh` SELinux boolean, run the following command:

    $ sudo setsebool -P fenced_can_ssh off

CCE-RHEL7-CCE-TBD

Disable the nagios_run_pnp4nagios SELinux Boolean

By default, the SELinux boolean `nagios_run_pnp4nagios` is disabled. If this setting is enabled, it should be disabled. To disable the `nagios_run_pnp4nagios` SELinux boolean, run the following command:

    $ sudo setsebool -P nagios_run_pnp4nagios off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_network_connect SELinux Boolean

By default, the SELinux boolean `httpd_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the mozilla_plugin_can_network_connect SELinux Boolean

By default, the SELinux boolean `mozilla_plugin_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `mozilla_plugin_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P mozilla_plugin_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the git_session_bind_all_unreserved_ports SELinux Boolean

By default, the SELinux boolean `git_session_bind_all_unreserved_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `git_session_bind_all_unreserved_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P git_session_bind_all_unreserved_ports off

CCE-RHEL7-CCE-TBD

Disable the tmpreaper_use_samba SELinux Boolean

By default, the SELinux boolean `tmpreaper_use_samba` is disabled. If this setting is enabled, it should be disabled. To disable the `tmpreaper_use_samba` SELinux boolean, run the following command:

    $ sudo setsebool -P tmpreaper_use_samba off

CCE-RHEL7-CCE-TBD

Disable the virt_use_sanlock SELinux Boolean

By default, the SELinux boolean `virt_use_sanlock` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_sanlock` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_sanlock off

CCE-RHEL7-CCE-TBD

Disable the httpd_anon_write SELinux Boolean

By default, the SELinux boolean `httpd_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_anon_write off

CCE-RHEL7-CCE-TBD

Disable the cobbler_use_nfs SELinux Boolean

By default, the SELinux boolean `cobbler_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `cobbler_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P cobbler_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the httpd_dbus_avahi SELinux Boolean

By default, the SELinux boolean `httpd_dbus_avahi` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_dbus_avahi` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_dbus_avahi off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_network_connect_db SELinux Boolean

By default, the SELinux boolean `httpd_can_network_connect_db` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_network_connect_db` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_network_connect_db off

CCE-RHEL7-CCE-TBD

Disable the ftpd_connect_db SELinux Boolean

By default, the SELinux boolean `ftpd_connect_db` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_connect_db` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_connect_db off

CCE-RHEL7-CCE-TBD

Disable the ftpd_use_nfs SELinux Boolean

By default, the SELinux boolean `ftpd_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the cron_can_relabel SELinux Boolean

By default, the SELinux boolean `cron_can_relabel` is disabled. If this setting is enabled, it should be disabled. To disable the `cron_can_relabel` SELinux boolean, run the following command:

    $ sudo setsebool -P cron_can_relabel off

CCE-RHEL7-CCE-TBD

Disable the openvpn_run_unconfined SELinux Boolean

By default, the SELinux boolean `openvpn_run_unconfined` is disabled. If this setting is enabled, it should be disabled. To disable the `openvpn_run_unconfined` SELinux boolean, run the following command:

    $ sudo setsebool -P openvpn_run_unconfined off

CCE-RHEL7-CCE-TBD

Disable the cobbler_use_cifs SELinux Boolean

By default, the SELinux boolean `cobbler_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `cobbler_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P cobbler_use_cifs off

CCE-RHEL7-CCE-TBD

Disable the sge_use_nfs SELinux Boolean

By default, the SELinux boolean `sge_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `sge_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P sge_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the fcron_crond SELinux Boolean

By default, the SELinux boolean `fcron_crond` is disabled. If this setting is enabled, it should be disabled. To disable the `fcron_crond` SELinux boolean, run the following command:

    $ sudo setsebool -P fcron_crond off

CCE-RHEL7-CCE-TBD

Disable the nfsd_anon_write SELinux Boolean

By default, the SELinux boolean `nfsd_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `nfsd_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P nfsd_anon_write off

CCE-RHEL7-CCE-TBD

Disable the squid_connect_any SELinux Boolean

By default, the SELinux boolean `squid_connect_any` is enabled. This setting should be disabled as squid should only connect on specified ports. To disable the `squid_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P squid_connect_any off

CCE-RHEL7-CCE-TBD

Disable the sftpd_full_access SELinux Boolean

By default, the SELinux boolean `sftpd_full_access` is disabled. If this setting is enabled, it should be disabled. To disable the `sftpd_full_access` SELinux boolean, run the following command:

    $ sudo setsebool -P sftpd_full_access off

CCE-RHEL7-CCE-TBD

Enable the nfs_export_all_ro SELinux Boolean

By default, the SELinux boolean `nfs_export_all_ro` is enabled. If this setting is disabled, it should be enabled as it allows NFS to export read-only mounts. To enable the `nfs_export_all_ro` SELinux boolean, run the following command:

    $ sudo setsebool -P nfs_export_all_ro on

CCE-RHEL7-CCE-TBD

Disable the haproxy_connect_any SELinux Boolean

By default, the SELinux boolean `haproxy_connect_any` is disabled. If this setting is enabled, it should be disabled. To disable the `haproxy_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P haproxy_connect_any off

CCE-RHEL7-CCE-TBD

Disable the httpd_setrlimit SELinux Boolean

By default, the SELinux boolean `httpd_setrlimit` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_setrlimit` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_setrlimit off

CCE-RHEL7-CCE-TBD

Disable the racoon_read_shadow SELinux Boolean

By default, the SELinux boolean `racoon_read_shadow` is disabled. If this setting is enabled, it should be disabled. To disable the `racoon_read_shadow` SELinux boolean, run the following command:

    $ sudo setsebool -P racoon_read_shadow off

CCE-RHEL7-CCE-TBD

Disable the rsync_full_access SELinux Boolean

By default, the SELinux boolean `rsync_full_access` is disabled. If this setting is enabled, it should be disabled. To disable the `rsync_full_access` SELinux boolean, run the following command:

    $ sudo setsebool -P rsync_full_access off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_network_memcache SELinux Boolean

By default, the SELinux boolean `httpd_can_network_memcache` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_network_memcache` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_network_memcache off

CCE-RHEL7-CCE-TBD

Disable the ftpd_use_passive_mode SELinux Boolean

By default, the SELinux boolean `ftpd_use_passive_mode` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_use_passive_mode` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_use_passive_mode off

CCE-RHEL7-CCE-TBD

Disable the httpd_execmem SELinux Boolean

By default, the SELinux boolean `httpd_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_execmem off

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_use_ssh_chroot SELinux Boolean

By default, the SELinux boolean `selinuxuser_use_ssh_chroot` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_use_ssh_chroot` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_use_ssh_chroot off

CCE-RHEL7-CCE-TBD

Enable the user_exec_content SELinux Boolean

By default, the SELinux boolean `user_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `user_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P user_exec_content on

CCE-RHEL7-CCE-TBD

Disable the condor_tcp_network_connect SELinux Boolean

By default, the SELinux boolean `condor_tcp_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `condor_tcp_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P condor_tcp_network_connect off

CCE-RHEL7-CCE-TBD

Enable the gssd_read_tmp SELinux Boolean

By default, the SELinux boolean `gssd_read_tmp` is enabled. This setting allows `gssd` processes to access Kerberos to read TGTs in the temp directory. If this setting is disabled, it should be enabled. To enable the `gssd_read_tmp` SELinux boolean, run the following command:

    $ sudo setsebool -P gssd_read_tmp on

CCE-RHEL7-CCE-TBD

Disable the git_cgi_use_cifs SELinux Boolean

By default, the SELinux boolean `git_cgi_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `git_cgi_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P git_cgi_use_cifs off

CCE-RHEL7-CCE-TBD

Disable the httpd_read_user_content SELinux Boolean

By default, the SELinux boolean `httpd_read_user_content` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_read_user_content` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_read_user_content off

CCE-RHEL7-CCE-TBD

Disable the logwatch_can_network_connect_mail SELinux Boolean

By default, the SELinux boolean `logwatch_can_network_connect_mail` is disabled. If this setting is enabled, it should be disabled. To disable the `logwatch_can_network_connect_mail` SELinux boolean, run the following command:

    $ sudo setsebool -P logwatch_can_network_connect_mail off

CCE-RHEL7-CCE-TBD

Disable the dbadm_read_user_files SELinux Boolean

By default, the SELinux boolean `dbadm_read_user_files` is disabled. If this setting is enabled, it should be disabled. To disable the `dbadm_read_user_files` SELinux boolean, run the following command:

    $ sudo setsebool -P dbadm_read_user_files off

CCE-RHEL7-CCE-TBD

Disable the deny_ptrace SELinux Boolean

By default, the SELinux boolean `deny_ptrace` is disabled. If this setting is enabled, it should be disabled. To disable the `deny_ptrace` SELinux boolean, run the following command:

    $ sudo setsebool -P deny_ptrace off

CCE-RHEL7-CCE-TBD

Enable the nfs_export_all_rw SELinux Boolean

By default, the SELinux boolean `nfs_export_all_rw` is enabled. If this setting is disabled, it should be enabled as it allows NFS to export read/write mounts. To enable the `nfs_export_all_rw` SELinux boolean, run the following command:

    $ sudo setsebool -P nfs_export_all_rw on

CCE-RHEL7-CCE-TBD

Disable the rsync_anon_write SELinux Boolean

By default, the SELinux boolean `rsync_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `rsync_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P rsync_anon_write off

CCE-RHEL7-CCE-TBD

Disable the httpd_run_ipa SELinux Boolean

By default, the SELinux boolean `httpd_run_ipa` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_run_ipa` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_run_ipa off

CCE-RHEL7-CCE-TBD

Enable the virt_sandbox_use_audit SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_audit` is enabled. If this setting is disabled, it should be enabled to allow sandboxed containers to send audit messages. To enable the `virt_sandbox_use_audit` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_audit on

CCE-RHEL7-CCE-TBD

Disable the virt_sandbox_use_samba SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_samba` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_sandbox_use_samba` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_samba off

CCE-RHEL7-CCE-TBD

Disable the mozilla_read_content SELinux Boolean

By default, the SELinux boolean `mozilla_read_content` is disabled. If this setting is enabled, it should be disabled. To disable the `mozilla_read_content` SELinux boolean, run the following command:

    $ sudo setsebool -P mozilla_read_content off

CCE-RHEL7-CCE-TBD

Disable the xserver_object_manager SELinux Boolean

By default, the SELinux boolean `xserver_object_manager` is disabled. If this setting is enabled, it should be disabled. To disable the `xserver_object_manager` SELinux boolean, run the following command:

    $ sudo setsebool -P xserver_object_manager off

CCE-RHEL7-CCE-TBD

Disable the httpd_tty_comm SELinux Boolean

By default, the SELinux boolean `httpd_tty_comm` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_tty_comm` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_tty_comm off

CCE-RHEL7-CCE-TBD

Disable the collectd_tcp_network_connect SELinux Boolean

By default, the SELinux boolean `collectd_tcp_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `collectd_tcp_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P collectd_tcp_network_connect off

CCE-RHEL7-CCE-TBD

Disable the xdm_sysadm_login SELinux Boolean

By default, the SELinux boolean `xdm_sysadm_login` is disabled. If this setting is enabled, it should be disabled. To disable the `xdm_sysadm_login` SELinux boolean, run the following command:

    $ sudo setsebool -P xdm_sysadm_login off

CCE-RHEL7-CCE-TBD

Disable the pcp_read_generic_logs SELinux Boolean

By default, the SELinux boolean `pcp_read_generic_logs` is disabled. If this setting is enabled, it should be disabled. To disable the `pcp_read_generic_logs` SELinux boolean, run the following command:

    $ sudo setsebool -P pcp_read_generic_logs off

CCE-RHEL7-CCE-TBD

Enable the spamd_enable_home_dirs SELinux Boolean

By default, the SELinux boolean `spamd_enable_home_dirs` is enabled. If this setting is disabled, it should be enabled. To enable the `spamd_enable_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P spamd_enable_home_dirs on

CCE-RHEL7-CCE-TBD

Disable the polipo_session_users SELinux Boolean

By default, the SELinux boolean `polipo_session_users` is disabled. If this setting is enabled, it should be disabled. To disable the `polipo_session_users` SELinux boolean, run the following command:

    $ sudo setsebool -P polipo_session_users off

CCE-RHEL7-CCE-TBD

Disable the polipo_session_bind_all_unreserved_ports SELinux Boolean

By default, the SELinux boolean `polipo_session_bind_all_unreserved_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `polipo_session_bind_all_unreserved_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P polipo_session_bind_all_unreserved_ports off

CCE-RHEL7-CCE-TBD

Disable the spamassassin_can_network SELinux Boolean

By default, the SELinux boolean `spamassassin_can_network` is disabled. If this setting is enabled, it should be disabled. To disable the `spamassassin_can_network` SELinux boolean, run the following command:

    $ sudo setsebool -P spamassassin_can_network off

CCE-RHEL7-CCE-TBD

Disable the virt_use_samba SELinux Boolean

By default, the SELinux boolean `virt_use_samba` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_samba` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_samba off

CCE-RHEL7-CCE-TBD

Disable the git_system_use_nfs SELinux Boolean

By default, the SELinux boolean `git_system_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `git_system_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P git_system_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the virt_use_usb SELinux Boolean

By default, the SELinux boolean `virt_use_usb` is enabled. This setting should be disabled. To disable the `virt_use_usb` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_usb off

CCE-RHEL7-CCE-TBD

Disable the nis_enabled SELinux Boolean

By default, the SELinux boolean `nis_enabled` is disabled. If this setting is enabled, it should be disabled. To disable the `nis_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P nis_enabled off

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_mysql_connect_enabled SELinux Boolean

By default, the SELinux boolean `selinuxuser_mysql_connect_enabled` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_mysql_connect_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_mysql_connect_enabled off

CCE-RHEL7-CCE-TBD

Disable the samba_share_fusefs SELinux Boolean

By default, the SELinux boolean `samba_share_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_share_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_share_fusefs off

CCE-RHEL7-CCE-TBD

Disable the httpd_enable_ftp_server SELinux Boolean

By default, the SELinux boolean `httpd_enable_ftp_server` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_enable_ftp_server` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_enable_ftp_server off

CCE-RHEL7-CCE-TBD

Disable the pppd_for_user SELinux Boolean

By default, the SELinux boolean `pppd_for_user` is disabled. If this setting is enabled, it should be disabled. To disable the `pppd_for_user` SELinux boolean, run the following command:

    $ sudo setsebool -P pppd_for_user off

CCE-RHEL7-CCE-TBD

Disable the virt_sandbox_use_all_caps SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_all_caps` is enabled. This setting is disabled as containers should not run with privileges. To disable the `virt_sandbox_use_all_caps` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_all_caps off

CCE-RHEL7-CCE-TBD

Disable the mozilla_plugin_use_gps SELinux Boolean

By default, the SELinux boolean `mozilla_plugin_use_gps` is disabled. If this setting is enabled, it should be disabled. To disable the `mozilla_plugin_use_gps` SELinux boolean, run the following command:

    $ sudo setsebool -P mozilla_plugin_use_gps off

CCE-RHEL7-CCE-TBD

Disable the samba_domain_controller SELinux Boolean

By default, the SELinux boolean `samba_domain_controller` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_domain_controller` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_domain_controller off

CCE-RHEL7-CCE-TBD

Disable the dbadm_manage_user_files SELinux Boolean

By default, the SELinux boolean `dbadm_manage_user_files` is disabled. If this setting is enabled, it should be disabled. To disable the `dbadm_manage_user_files` SELinux boolean, run the following command:

    $ sudo setsebool -P dbadm_manage_user_files off

CCE-RHEL7-CCE-TBD

Disable the httpd_tmp_exec SELinux Boolean

By default, the SELinux boolean `httpd_tmp_exec` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_tmp_exec` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_tmp_exec off

CCE-RHEL7-CCE-TBD

Disable the use_fusefs_home_dirs SELinux Boolean

By default, the SELinux boolean `use_fusefs_home_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `use_fusefs_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P use_fusefs_home_dirs off

CCE-RHEL7-CCE-TBD

Disable the tmpreaper_use_nfs SELinux Boolean

By default, the SELinux boolean `tmpreaper_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `tmpreaper_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P tmpreaper_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_network_relay SELinux Boolean

By default, the SELinux boolean `httpd_can_network_relay` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_network_relay` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_network_relay off

CCE-RHEL7-CCE-TBD

Disable the ssh_keysign SELinux Boolean

By default, the SELinux boolean `ssh_keysign` is disabled. If this setting is enabled, it should be disabled. To disable the `ssh_keysign` SELinux boolean, run the following command:

    $ sudo setsebool -P ssh_keysign off

CCE-RHEL7-CCE-TBD

Disable the tftp_anon_write SELinux Boolean

By default, the SELinux boolean `tftp_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `tftp_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P tftp_anon_write off

CCE-RHEL7-CCE-TBD

Disable the httpd_use_fusefs SELinux Boolean

By default, the SELinux boolean `httpd_use_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_use_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_use_fusefs off

CCE-RHEL7-CCE-TBD

Enable the staff_exec_content SELinux Boolean

By default, the SELinux boolean `staff_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `staff_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P staff_exec_content on

CCE-RHEL7-CCE-TBD

Enable the nscd_use_shm SELinux Boolean

By default, the SELinux boolean `nscd_use_shm` is enabled. If this setting is disabled, it should be enabled to allow `nscd` to use shared memory. To enable the `nscd_use_shm` SELinux boolean, run the following command:

    $ sudo setsebool -P nscd_use_shm on

CCE-RHEL7-CCE-TBD

Disable the global_ssp SELinux Boolean

By default, the SELinux boolean `global_ssp` is disabled. If this setting is enabled, it should be disabled. To disable the `global_ssp` SELinux boolean, run the following command:

    $ sudo setsebool -P global_ssp off

CCE-RHEL7-CCE-TBD

Disable the virt_use_fusefs SELinux Boolean

By default, the SELinux boolean `virt_use_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_fusefs off

CCE-RHEL7-CCE-TBD

Disable the sge_domain_can_network_connect SELinux Boolean

By default, the SELinux boolean `sge_domain_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `sge_domain_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P sge_domain_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the gluster_anon_write SELinux Boolean

By default, the SELinux boolean `gluster_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `gluster_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P gluster_anon_write off

CCE-RHEL7-CCE-TBD

Disable the virt_read_qemu_ga_data SELinux Boolean

By default, the SELinux boolean `virt_read_qemu_ga_data` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_read_qemu_ga_data` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_read_qemu_ga_data off

CCE-RHEL7-CCE-TBD

Disable the wine_mmap_zero_ignore SELinux Boolean

By default, the SELinux boolean `wine_mmap_zero_ignore` is disabled. If this setting is enabled, it should be disabled. To disable the `wine_mmap_zero_ignore` SELinux boolean, run the following command:

    $ sudo setsebool -P wine_mmap_zero_ignore off

CCE-RHEL7-CCE-TBD

Disable the xserver_execmem SELinux Boolean

By default, the SELinux boolean `xserver_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `xserver_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P xserver_execmem off

CCE-RHEL7-CCE-TBD

Disable the fenced_can_network_connect SELinux Boolean

By default, the SELinux boolean `fenced_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `fenced_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P fenced_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the zabbix_can_network SELinux Boolean

By default, the SELinux boolean `zabbix_can_network` is disabled. If this setting is enabled, it should be disabled. To disable the `zabbix_can_network` SELinux boolean, run the following command:

    $ sudo setsebool -P zabbix_can_network off

CCE-RHEL7-CCE-TBD

Disable the virt_use_nfs SELinux Boolean

By default, the SELinux boolean `virt_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the nagios_run_sudo SELinux Boolean

By default, the SELinux boolean `nagios_run_sudo` is disabled. If this setting is enabled, it should be disabled. To disable the `nagios_run_sudo` SELinux boolean, run the following command:

    $ sudo setsebool -P nagios_run_sudo off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_sendmail SELinux Boolean

By default, the SELinux boolean `httpd_can_sendmail` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_sendmail` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_sendmail off

CCE-RHEL7-CCE-TBD

Disable the prosody_bind_http_port SELinux Boolean

By default, the SELinux boolean `prosody_bind_http_port` is disabled. If this setting is enabled, it should be disabled. To disable the `prosody_bind_http_port` SELinux boolean, run the following command:

    $ sudo setsebool -P prosody_bind_http_port off

CCE-RHEL7-CCE-TBD

Disable the xen_use_nfs SELinux Boolean

By default, the SELinux boolean `xen_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `xen_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P xen_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the ftpd_anon_write SELinux Boolean

By default, the SELinux boolean `ftpd_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_anon_write off

CCE-RHEL7-CCE-TBD

Enable the cron_userdomain_transition SELinux Boolean

By default, the SELinux boolean `cron_userdomain_transition` is enabled. This setting should be enabled as end user cron jobs run in their default associated user domain(s) instead of the general cronjob domain. To enable the `cron_userdomain_transition` SELinux boolean, run the following command:

    $ sudo setsebool -P cron_userdomain_transition on

CCE-RHEL7-CCE-TBD

Disable the mozilla_plugin_use_spice SELinux Boolean

By default, the SELinux boolean `mozilla_plugin_use_spice` is disabled. If this setting is enabled, it should be disabled. To disable the `mozilla_plugin_use_spice` SELinux boolean, run the following command:

    $ sudo setsebool -P mozilla_plugin_use_spice off

CCE-RHEL7-CCE-TBD

Disable the virt_sandbox_use_nfs SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_sandbox_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the xguest_mount_media SELinux Boolean

By default, the SELinux boolean `xguest_mount_media` is enabled. This setting should be disabled as guest users should not be able to mount any media. To disable the `xguest_mount_media` SELinux boolean, run the following command:

    $ sudo setsebool -P xguest_mount_media off

CCE-RHEL7-CCE-TBD

Disable the mysql_connect_any SELinux Boolean

By default, the SELinux boolean `mysql_connect_any` is disabled. If this setting is enabled, it should be disabled. To disable the `mysql_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P mysql_connect_any off

CCE-RHEL7-CCE-TBD

Disable the samba_load_libgfapi SELinux Boolean

By default, the SELinux boolean `samba_load_libgfapi` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_load_libgfapi` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_load_libgfapi off

CCE-RHEL7-CCE-TBD

Disable the samba_portmapper SELinux Boolean

By default, the SELinux boolean `samba_portmapper` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_portmapper` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_portmapper off

CCE-RHEL7-CCE-TBD

Disable the httpd_run_preupgrade SELinux Boolean

By default, the SELinux boolean `httpd_run_preupgrade` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_run_preupgrade` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_run_preupgrade off

CCE-RHEL7-CCE-TBD

Disable the gitosis_can_sendmail SELinux Boolean

By default, the SELinux boolean `gitosis_can_sendmail` is disabled. If this setting is enabled, it should be disabled. To disable the `gitosis_can_sendmail` SELinux boolean, run the following command:

    $ sudo setsebool -P gitosis_can_sendmail off

CCE-RHEL7-CCE-TBD

Disable the mplayer_execstack SELinux Boolean

By default, the SELinux boolean `mplayer_execstack` is disabled. If this setting is enabled, it should be disabled. To disable the `mplayer_execstack` SELinux boolean, run the following command:

    $ sudo setsebool -P mplayer_execstack off

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_rw_noexattrfile SELinux Boolean

By default, the SELinux boolean `selinuxuser_rw_noexattrfile` is enabled. This setting should be disabled as users should not be able to read/write files on filesystems that do not have extended attributes e.g. FAT, CDROM, FLOPPY, etc. To disable the `selinuxuser_rw_noexattrfile` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_rw_noexattrfile off

CCE-RHEL7-CCE-TBD

Disable the cdrecord_read_content SELinux Boolean

By default, the SELinux boolean `cdrecord_read_content` is disabled. If this setting is enabled, it should be disabled. To disable the `cdrecord_read_content` SELinux boolean, run the following command:

    $ sudo setsebool -P cdrecord_read_content off

CCE-RHEL7-CCE-TBD

Disable the ftpd_full_access SELinux Boolean

By default, the SELinux boolean `ftpd_full_access` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_full_access` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_full_access off

CCE-RHEL7-CCE-TBD

Enable the unconfined_mozilla_plugin_transition SELinux Boolean

By default, the SELinux boolean `unconfined_mozilla_plugin_transition` is enabled. If this setting is disabled, it should be enabled. To enable the `unconfined_mozilla_plugin_transition` SELinux boolean, run the following command:

    $ sudo setsebool -P unconfined_mozilla_plugin_transition on

CCE-RHEL7-CCE-TBD

Disable the deny_execmem SELinux Boolean

By default, the SELinux boolean `deny_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `deny_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P deny_execmem off

CCE-RHEL7-CCE-TBD

Disable the ssh_chroot_rw_homedirs SELinux Boolean

By default, the SELinux boolean `ssh_chroot_rw_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `ssh_chroot_rw_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P ssh_chroot_rw_homedirs off

CCE-RHEL7-CCE-TBD

Disable the glance_api_can_network SELinux Boolean

By default, the SELinux boolean `glance_api_can_network` is disabled. If this setting is enabled, it should be disabled. To disable the `glance_api_can_network` SELinux boolean, run the following command:

    $ sudo setsebool -P glance_api_can_network off

CCE-RHEL7-CCE-TBD

Disable the virt_use_execmem SELinux Boolean

By default, the SELinux boolean `virt_use_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_execmem off

CCE-80427-8

Disable the authlogin_yubikey SELinux Boolean

By default, the SELinux boolean `authlogin_yubikey` is disabled. If this setting is enabled, it should be disabled. To disable the `authlogin_yubikey` SELinux boolean, run the following command:

    $ sudo setsebool -P authlogin_yubikey off

CCE-RHEL7-CCE-TBD

Disable the mpd_use_nfs SELinux Boolean

By default, the SELinux boolean `mpd_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `mpd_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P mpd_use_nfs off

CCE-RHEL7-CCE-TBD

Enable the unconfined_chrome_sandbox_transition SELinux Boolean

By default, the SELinux boolean `unconfined_chrome_sandbox_transition` is enabled. If this setting is disabled, it should be enabled. To enable the `unconfined_chrome_sandbox_transition` SELinux boolean, run the following command:

    $ sudo setsebool -P unconfined_chrome_sandbox_transition on

CCE-RHEL7-CCE-TBD

Disable the httpd_can_connect_ftp SELinux Boolean

By default, the SELinux boolean `httpd_can_connect_ftp` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_connect_ftp` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_connect_ftp off

CCE-80419-5

Disable the abrt_anon_write SELinux Boolean

By default, the SELinux boolean `abrt_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `abrt_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P abrt_anon_write off

CCE-RHEL7-CCE-TBD

Disable the named_tcp_bind_http_port SELinux Boolean

By default, the SELinux boolean `named_tcp_bind_http_port` is disabled. If this setting is enabled, it should be disabled. To disable the `named_tcp_bind_http_port` SELinux boolean, run the following command:

    $ sudo setsebool -P named_tcp_bind_http_port off

CCE-RHEL7-CCE-TBD

Enable the dbadm_exec_content SELinux Boolean

By default, the SELinux boolean `dbadm_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `dbadm_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P dbadm_exec_content on

CCE-RHEL7-CCE-TBD

Enable the kerberos_enabled SELinux Boolean

By default, the SELinux boolean `kerberos_enabled` is enabled. If this setting is disabled, it should be enabled to allow confined applications to run with Kerberos. To enable the `kerberos_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P kerberos_enabled on

CCE-RHEL7-CCE-TBD

Disable the dhcpd_use_ldap SELinux Boolean

By default, the SELinux boolean `dhcpd_use_ldap` is disabled. If this setting is enabled, it should be disabled. To disable the `dhcpd_use_ldap` SELinux boolean, run the following command:

    $ sudo setsebool -P dhcpd_use_ldap off

CCE-RHEL7-CCE-TBD

Configure the httpd_builtin_scripting SELinux Boolean

By default, the SELinux boolean `httpd_builtin_scripting` is enabled. This setting should be disabled if `httpd` is not running `php` or some similary scripting language. To disable the `httpd_builtin_scripting` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_builtin_scripting off

CCE-80428-6

Disable the awstats_purge_apache_log_files SELinux Boolean

By default, the SELinux boolean `awstats_purge_apache_log_files` is disabled. If this setting is enabled, it should be disabled. To disable the `awstats_purge_apache_log_files` SELinux boolean, run the following command:

    $ sudo setsebool -P awstats_purge_apache_log_files off

CCE-RHEL7-CCE-TBD

Disable the samba_share_nfs SELinux Boolean

By default, the SELinux boolean `samba_share_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_share_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_share_nfs off

CCE-RHEL7-CCE-TBD

Disable the glance_use_fusefs SELinux Boolean

By default, the SELinux boolean `glance_use_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `glance_use_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P glance_use_fusefs off

CCE-RHEL7-CCE-TBD

Disable the sanlock_use_nfs SELinux Boolean

By default, the SELinux boolean `sanlock_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `sanlock_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P sanlock_use_nfs off

CCE-RHEL7-CCE-TBD

Configure the gluster_export_all_rw SELinux Boolean

By default, the SELinux boolean `gluster_export_all_rw` is enabled. If `GlusterFS` is in use, this setting should be enabled. Otherwise, disable it. To disable the `gluster_export_all_rw` SELinux boolean, run the following command:

    $ sudo setsebool -P gluster_export_all_rw off

CCE-RHEL7-CCE-TBD

Disable the mozilla_plugin_bind_unreserved_ports SELinux Boolean

By default, the SELinux boolean `mozilla_plugin_bind_unreserved_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `mozilla_plugin_bind_unreserved_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P mozilla_plugin_bind_unreserved_ports off

CCE-RHEL7-CCE-TBD

Enable the logging_syslogd_use_tty SELinux Boolean

By default, the SELinux boolean `logging_syslogd_use_tty` is enabled. If this setting is disabled, it should be enabled as it allows `syslog` the ability to read/write to terminal. To enable the `logging_syslogd_use_tty` SELinux boolean, run the following command:

    $ sudo setsebool -P logging_syslogd_use_tty on

CCE-RHEL7-CCE-TBD

Enable the login_console_enabled SELinux Boolean

By default, the SELinux boolean `login_console_enabled` is enabled. If this setting is disabled, it should be enabled as it allows login from `/dev/console` to a console session. To enable the `login_console_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P login_console_enabled on

CCE-RHEL7-CCE-TBD

Disable the httpd_mod_auth_pam SELinux Boolean

By default, the SELinux boolean `httpd_mod_auth_pam` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_mod_auth_pam` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_mod_auth_pam off

CCE-80420-3

Disable the abrt_handle_event SELinux Boolean

By default, the SELinux boolean `abrt_handle_event` is disabled. If this setting is enabled, it should be disabled. To disable the `abrt_handle_event` SELinux boolean, run the following command:

    $ sudo setsebool -P abrt_handle_event off

CCE-RHEL7-CCE-TBD

Disable the docker_connect_any SELinux Boolean

By default, the SELinux boolean `docker_connect_any` is disabled. If this setting is enabled, it should be disabled. To disable the `docker_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P docker_connect_any off

CCE-RHEL7-CCE-TBD

Disable the gluster_export_all_ro SELinux Boolean

By default, the SELinux boolean `gluster_export_all_ro` is disabled. If this setting is enabled, it should be disabled. To disable the `gluster_export_all_ro` SELinux boolean, run the following command:

    $ sudo setsebool -P gluster_export_all_ro off

CCE-RHEL7-CCE-TBD

Disable the sftpd_write_ssh_home SELinux Boolean

By default, the SELinux boolean `sftpd_write_ssh_home` is disabled. If this setting is enabled, it should be disabled. To disable the `sftpd_write_ssh_home` SELinux boolean, run the following command:

    $ sudo setsebool -P sftpd_write_ssh_home off

CCE-RHEL7-CCE-TBD

Disable the ksmtuned_use_nfs SELinux Boolean

By default, the SELinux boolean `ksmtuned_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `ksmtuned_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P ksmtuned_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the puppetagent_manage_all_files SELinux Boolean

By default, the SELinux boolean `puppetagent_manage_all_files` is disabled. If this setting is enabled, it should be disabled. To disable the `puppetagent_manage_all_files` SELinux boolean, run the following command:

    $ sudo setsebool -P puppetagent_manage_all_files off

CCE-RHEL7-CCE-TBD

Disable the logging_syslogd_run_nagios_plugins SELinux Boolean

By default, the SELinux boolean `logging_syslogd_run_nagios_plugins` is disabled. If this setting is enabled, it should be disabled. To disable the `logging_syslogd_run_nagios_plugins` SELinux boolean, run the following command:

    $ sudo setsebool -P logging_syslogd_run_nagios_plugins off

CCE-RHEL7-CCE-TBD

Disable the polipo_use_cifs SELinux Boolean

By default, the SELinux boolean `polipo_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `polipo_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P polipo_use_cifs off

CCE-80424-5

Enable the auditadm_exec_content SELinux Boolean

By default, the SELinux boolean `auditadm_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `auditadm_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P auditadm_exec_content on

CCE-RHEL7-CCE-TBD

Disable the postgresql_can_rsync SELinux Boolean

By default, the SELinux boolean `postgresql_can_rsync` is disabled. If this setting is enabled, it should be disabled. To disable the `postgresql_can_rsync` SELinux boolean, run the following command:

    $ sudo setsebool -P postgresql_can_rsync off

CCE-RHEL7-CCE-TBD

Disable the xguest_exec_content SELinux Boolean

By default, the SELinux boolean `xguest_exec_content` is enabled. This setting should be disabled as guest users should not be able to run executables. To disable the `xguest_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P xguest_exec_content off

CCE-RHEL7-CCE-TBD

Disable the mcelog_server SELinux Boolean

By default, the SELinux boolean `mcelog_server` is disabled. If this setting is enabled, it should be disabled. To disable the `mcelog_server` SELinux boolean, run the following command:

    $ sudo setsebool -P mcelog_server off

CCE-RHEL7-CCE-TBD

Enable the mcelog_exec_scripts SELinux Boolean

By default, the SELinux boolean `mcelog_exec_scripts` is enabled. If this setting is disabled, it should be enabled. To enable the `mcelog_exec_scripts` SELinux boolean, run the following command:

    $ sudo setsebool -P mcelog_exec_scripts on

CCE-RHEL7-CCE-TBD

Disable the virt_rw_qemu_ga_data SELinux Boolean

By default, the SELinux boolean `virt_rw_qemu_ga_data` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_rw_qemu_ga_data` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_rw_qemu_ga_data off

CCE-RHEL7-CCE-TBD

Disable the tor_bind_all_unreserved_ports SELinux Boolean

By default, the SELinux boolean `tor_bind_all_unreserved_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `tor_bind_all_unreserved_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P tor_bind_all_unreserved_ports off

CCE-RHEL7-CCE-TBD

Disable the piranha_lvs_can_network_connect SELinux Boolean

By default, the SELinux boolean `piranha_lvs_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `piranha_lvs_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P piranha_lvs_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the git_session_users SELinux Boolean

By default, the SELinux boolean `git_session_users` is disabled. If this setting is enabled, it should be disabled. To disable the `git_session_users` SELinux boolean, run the following command:

    $ sudo setsebool -P git_session_users off

CCE-RHEL7-CCE-TBD

Disable the domain_kernel_load_modules SELinux Boolean

By default, the SELinux boolean `domain_kernel_load_modules` is disabled. If this setting is enabled, it should be disabled. To disable the `domain_kernel_load_modules` SELinux boolean, run the following command:

    $ sudo setsebool -P domain_kernel_load_modules off

CCE-RHEL7-CCE-TBD

Disable the exim_manage_user_files SELinux Boolean

By default, the SELinux boolean `exim_manage_user_files` is disabled. If this setting is enabled, it should be disabled. To disable the `exim_manage_user_files` SELinux boolean, run the following command:

    $ sudo setsebool -P exim_manage_user_files off

CCE-RHEL7-CCE-TBD

Disable the virt_sandbox_use_netlink SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_netlink` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_sandbox_use_netlink` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_netlink off

CCE-RHEL7-CCE-TBD

Disable the tftp_home_dir SELinux Boolean

By default, the SELinux boolean `tftp_home_dir` is disabled. If this setting is enabled, it should be disabled. To disable the `tftp_home_dir` SELinux boolean, run the following command:

    $ sudo setsebool -P tftp_home_dir off

CCE-RHEL7-CCE-TBD

Enable the postgresql_selinux_users_ddl SELinux Boolean

By default, the SELinux boolean `postgresql_selinux_users_ddl` is enabled. If this setting is disabled, it should be enabled as it allows Database Administrators to execute Data Definition Language (DDL) statements. To enable the `postgresql_selinux_users_ddl` SELinux boolean, run the following command:

    $ sudo setsebool -P postgresql_selinux_users_ddl on

CCE-RHEL7-CCE-TBD

Disable the httpd_verify_dns SELinux Boolean

By default, the SELinux boolean `httpd_verify_dns` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_verify_dns` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_verify_dns off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_connect_zabbix SELinux Boolean

By default, the SELinux boolean `httpd_can_connect_zabbix` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_connect_zabbix` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_connect_zabbix off

CCE-RHEL7-CCE-TBD

Disable the glance_use_execmem SELinux Boolean

By default, the SELinux boolean `glance_use_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `glance_use_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P glance_use_execmem off

CCE-RHEL7-CCE-TBD

Disable the git_cgi_use_nfs SELinux Boolean

By default, the SELinux boolean `git_cgi_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `git_cgi_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P git_cgi_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the httpd_enable_homedirs SELinux Boolean

By default, the SELinux boolean `httpd_enable_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_enable_homedirs off

CCE-RHEL7-CCE-TBD

Disable the neutron_can_network SELinux Boolean

By default, the SELinux boolean `neutron_can_network` is disabled. If this setting is enabled, it should be disabled. To disable the `neutron_can_network` SELinux boolean, run the following command:

    $ sudo setsebool -P neutron_can_network off

CCE-RHEL7-CCE-TBD

Enable the unconfined_login SELinux Boolean

By default, the SELinux boolean `unconfined_login` is enabled. If this setting is disabled, it should be enabled. To enable the `unconfined_login` SELinux boolean, run the following command:

    $ sudo setsebool -P unconfined_login on

CCE-RHEL7-CCE-TBD

Disable the logging_syslogd_can_sendmail SELinux Boolean

By default, the SELinux boolean `logging_syslogd_can_sendmail` is disabled. If this setting is enabled, it should be disabled. To disable the `logging_syslogd_can_sendmail` SELinux boolean, run the following command:

    $ sudo setsebool -P logging_syslogd_can_sendmail off

CCE-RHEL7-CCE-TBD

Disable the webadm_read_user_files SELinux Boolean

By default, the SELinux boolean `webadm_read_user_files` is disabled. If this setting is enabled, it should be disabled. To disable the `webadm_read_user_files` SELinux boolean, run the following command:

    $ sudo setsebool -P webadm_read_user_files off

CCE-RHEL7-CCE-TBD

Disable the openvpn_enable_homedirs SELinux Boolean

By default, the SELinux boolean `openvpn_enable_homedirs` is enabled. This setting should be disabled. To disable the `openvpn_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P openvpn_enable_homedirs off

CCE-RHEL7-CCE-TBD

Disable the httpd_use_sasl SELinux Boolean

By default, the SELinux boolean `httpd_use_sasl` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_use_sasl` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_use_sasl off

CCE-RHEL7-CCE-TBD

Disable the git_system_use_cifs SELinux Boolean

By default, the SELinux boolean `git_system_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `git_system_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P git_system_use_cifs off

CCE-RHEL7-CCE-TBD

Disable the squid_use_tproxy SELinux Boolean

By default, the SELinux boolean `squid_use_tproxy` is disabled. If this setting is enabled, it should be disabled. To disable the `squid_use_tproxy` SELinux boolean, run the following command:

    $ sudo setsebool -P squid_use_tproxy off

CCE-RHEL7-CCE-TBD

Disable the virt_use_comm SELinux Boolean

By default, the SELinux boolean `virt_use_comm` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_comm` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_comm off

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_postgresql_connect_enabled SELinux Boolean

By default, the SELinux boolean `selinuxuser_postgresql_connect_enabled` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_postgresql_connect_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_postgresql_connect_enabled off

CCE-RHEL7-CCE-TBD

Disable the httpd_use_gpg SELinux Boolean

By default, the SELinux boolean `httpd_use_gpg` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_use_gpg` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_use_gpg off

CCE-80429-4

Disable the boinc_execmem SELinux Boolean

By default, the SELinux boolean `boinc_execmem` is enabled. This setting should be disabled. To disable the `boinc_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P boinc_execmem off

CCE-RHEL7-CCE-TBD

Disable the staff_use_svirt SELinux Boolean

By default, the SELinux boolean `staff_use_svirt` is disabled. If this setting is enabled, it should be disabled. To disable the `staff_use_svirt` SELinux boolean, run the following command:

    $ sudo setsebool -P staff_use_svirt off

CCE-RHEL7-CCE-TBD

Disable the daemons_use_tcp_wrapper SELinux Boolean

By default, the SELinux boolean `daemons_use_tcp_wrapper` is disabled. If this setting is enabled, it should be disabled. To disable the `daemons_use_tcp_wrapper` SELinux boolean, run the following command:

    $ sudo setsebool -P daemons_use_tcp_wrapper off

CCE-RHEL7-CCE-TBD

Configure the httpd_enable_cgi SELinux Boolean

By default, the SELinux boolean `httpd_enable_cgi` is enabled. This setting should be disabled unless `httpd` is used with `CGI` scripting. To disable the `httpd_enable_cgi` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_enable_cgi off

CCE-RHEL7-CCE-TBD

Disable the exim_can_connect_db SELinux Boolean

By default, the SELinux boolean `exim_can_connect_db` is disabled. If this setting is enabled, it should be disabled. To disable the `exim_can_connect_db` SELinux boolean, run the following command:

    $ sudo setsebool -P exim_can_connect_db off

CCE-RHEL7-CCE-TBD

Disable the zarafa_setrlimit SELinux Boolean

By default, the SELinux boolean `zarafa_setrlimit` is disabled. If this setting is enabled, it should be disabled. To disable the `zarafa_setrlimit` SELinux boolean, run the following command:

    $ sudo setsebool -P zarafa_setrlimit off

CCE-RHEL7-CCE-TBD

Disable the samba_export_all_ro SELinux Boolean

By default, the SELinux boolean `samba_export_all_ro` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_export_all_ro` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_export_all_ro off

CCE-RHEL7-CCE-TBD

Disable the zoneminder_anon_write SELinux Boolean

By default, the SELinux boolean `zoneminder_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `zoneminder_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P zoneminder_anon_write off

CCE-RHEL7-CCE-TBD

Disable the virt_use_rawip SELinux Boolean

By default, the SELinux boolean `virt_use_rawip` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_rawip` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_rawip off

CCE-RHEL7-CCE-TBD

Disable the sanlock_use_fusefs SELinux Boolean

By default, the SELinux boolean `sanlock_use_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `sanlock_use_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P sanlock_use_fusefs off

CCE-RHEL7-CCE-TBD

Disable the varnishd_connect_any SELinux Boolean

By default, the SELinux boolean `varnishd_connect_any` is disabled. If this setting is enabled, it should be disabled. To disable the `varnishd_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P varnishd_connect_any off

CCE-RHEL7-CCE-TBD

Disable the privoxy_connect_any SELinux Boolean

By default, the SELinux boolean `privoxy_connect_any` is enabled. This setting should be disabled. To disable the `privoxy_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P privoxy_connect_any off

CCE-RHEL7-CCE-TBD

Disable the irc_use_any_tcp_ports SELinux Boolean

By default, the SELinux boolean `irc_use_any_tcp_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `irc_use_any_tcp_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P irc_use_any_tcp_ports off

CCE-80421-1

Disable the abrt_upload_watch_anon_write SELinux Boolean

By default, the SELinux boolean `abrt_upload_watch_anon_write` is enabled. This setting should be disabled as it allows the Automatic Bug Report Tool (ABRT) to modify public files used for public file transfer services. To disable the `abrt_upload_watch_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P abrt_upload_watch_anon_write off

CCE-RHEL7-CCE-TBD

Disable the openshift_use_nfs SELinux Boolean

By default, the SELinux boolean `openshift_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `openshift_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P openshift_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the conman_can_network SELinux Boolean

By default, the SELinux boolean `conman_can_network` is disabled. If this setting is enabled, it should be disabled. To disable the `conman_can_network` SELinux boolean, run the following command:

    $ sudo setsebool -P conman_can_network off

CCE-RHEL7-CCE-TBD

Disable the cobbler_can_network_connect SELinux Boolean

By default, the SELinux boolean `cobbler_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `cobbler_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P cobbler_can_network_connect off

CCE-RHEL7-CCE-TBD

Disable the daemons_use_tty SELinux Boolean

By default, the SELinux boolean `daemons_use_tty` is disabled. If this setting is enabled, it should be disabled. To disable the `daemons_use_tty` SELinux boolean, run the following command:

    $ sudo setsebool -P daemons_use_tty off

CCE-RHEL7-CCE-TBD

Disable the zoneminder_run_sudo SELinux Boolean

By default, the SELinux boolean `zoneminder_run_sudo` is disabled. If this setting is enabled, it should be disabled. To disable the `zoneminder_run_sudo` SELinux boolean, run the following command:

    $ sudo setsebool -P zoneminder_run_sudo off

CCE-RHEL7-CCE-TBD

Enable the postgresql_selinux_unconfined_dbadm SELinux Boolean

By default, the SELinux boolean `postgresql_selinux_unconfined_dbadm` is enabled. If this setting is disabled, it should be enabled as it allows Database Administrators to execute Data Manipulation Language (DML) statements. To enable the `postgresql_selinux_unconfined_dbadm` SELinux boolean, run the following command:

    $ sudo setsebool -P postgresql_selinux_unconfined_dbadm on

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_tcp_server SELinux Boolean

By default, the SELinux boolean `selinuxuser_tcp_server` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_tcp_server` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_tcp_server off

CCE-RHEL7-CCE-TBD

Disable the smbd_anon_write SELinux Boolean

By default, the SELinux boolean `smbd_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `smbd_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P smbd_anon_write off

CCE-RHEL7-CCE-TBD

Enable the httpd_graceful_shutdown SELinux Boolean

By default, the SELinux boolean `httpd_graceful_shutdown` is enabled. If this setting is disabled, it should be enabled. To enable the `httpd_graceful_shutdown` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_graceful_shutdown on

CCE-RHEL7-CCE-TBD

Disable the pppd_can_insmod SELinux Boolean

By default, the SELinux boolean `pppd_can_insmod` is disabled. If this setting is enabled, it should be disabled. To disable the `pppd_can_insmod` SELinux boolean, run the following command:

    $ sudo setsebool -P pppd_can_insmod off

CCE-RHEL7-CCE-TBD

Disable the webadm_manage_user_files SELinux Boolean

By default, the SELinux boolean `webadm_manage_user_files` is disabled. If this setting is enabled, it should be disabled. To disable the `webadm_manage_user_files` SELinux boolean, run the following command:

    $ sudo setsebool -P webadm_manage_user_files off

CCE-RHEL7-CCE-TBD

Disable the cluster_use_execmem SELinux Boolean

By default, the SELinux boolean `cluster_use_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `cluster_use_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P cluster_use_execmem off

CCE-RHEL7-CCE-TBD

Disable the httpd_serve_cobbler_files SELinux Boolean

By default, the SELinux boolean `httpd_serve_cobbler_files` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_serve_cobbler_files` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_serve_cobbler_files off

CCE-RHEL7-CCE-TBD

Disable the irssi_use_full_network SELinux Boolean

By default, the SELinux boolean `irssi_use_full_network` is disabled. If this setting is enabled, it should be disabled. To disable the `irssi_use_full_network` SELinux boolean, run the following command:

    $ sudo setsebool -P irssi_use_full_network off

CCE-RHEL7-CCE-TBD

Configure the selinuxuser_direct_dri_enabled SELinux Boolean

By default, the SELinux boolean `selinuxuser_direct_dri_enabled` is enabled. If XWindows is not installed or used on the system, this setting should be disabled. Otherwise, enable it. To disable the `selinuxuser_direct_dri_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_direct_dri_enabled off

CCE-RHEL7-CCE-TBD

Disable the swift_can_network SELinux Boolean

By default, the SELinux boolean `swift_can_network` is disabled. If this setting is enabled, it should be disabled. To disable the `swift_can_network` SELinux boolean, run the following command:

    $ sudo setsebool -P swift_can_network off

CCE-RHEL7-CCE-TBD

Disable the cups_execmem SELinux Boolean

By default, the SELinux boolean `cups_execmem` is disabled. If this setting is enabled, it should be disabled. To disable the `cups_execmem` SELinux boolean, run the following command:

    $ sudo setsebool -P cups_execmem off

CCE-RHEL7-CCE-TBD

Disable the httpd_unified SELinux Boolean

By default, the SELinux boolean `httpd_unified` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_unified` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_unified off

CCE-RHEL7-CCE-TBD

Disable the virt_sandbox_use_sys_admin SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_sys_admin` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_sandbox_use_sys_admin` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_sys_admin off

CCE-RHEL7-CCE-TBD

Disable the xdm_bind_vnc_tcp_port SELinux Boolean

By default, the SELinux boolean `xdm_bind_vnc_tcp_port` is disabled. If this setting is enabled, it should be disabled. To disable the `xdm_bind_vnc_tcp_port` SELinux boolean, run the following command:

    $ sudo setsebool -P xdm_bind_vnc_tcp_port off

CCE-80422-9

Enable the antivirus_can_scan_system SELinux Boolean

By default, the SELinux boolean `antivirus_can_scan_system` is disabled. This setting should be enabled as it allows antivirus programs to read non-security files on a system. To enable the `antivirus_can_scan_system` SELinux boolean, run the following command:

    $ sudo setsebool -P antivirus_can_scan_system on

CCE-RHEL7-CCE-TBD

Disable the cluster_manage_all_files SELinux Boolean

By default, the SELinux boolean `cluster_manage_all_files` is disabled. If this setting is enabled, it should be disabled. To disable the `cluster_manage_all_files` SELinux boolean, run the following command:

    $ sudo setsebool -P cluster_manage_all_files off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_network_connect_cobbler SELinux Boolean

By default, the SELinux boolean `httpd_can_network_connect_cobbler` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_network_connect_cobbler` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_network_connect_cobbler off

CCE-RHEL7-CCE-TBD

Disable the ftp_home_dir SELinux Boolean

By default, the SELinux boolean `ftp_home_dir` is disabled. If this setting is enabled, it should be disabled. To disable the `ftp_home_dir` SELinux boolean, run the following command:

    $ sudo setsebool -P ftp_home_dir off

CCE-80426-0

Disable the authlogin_radius SELinux Boolean

By default, the SELinux boolean `authlogin_radius` is disabled. If this setting is enabled, it should be disabled. To disable the `authlogin_radius` SELinux boolean, run the following command:

    $ sudo setsebool -P authlogin_radius off

CCE-RHEL7-CCE-TBD

Disable the puppetmaster_use_db SELinux Boolean

By default, the SELinux boolean `puppetmaster_use_db` is disabled. If this setting is enabled, it should be disabled. To disable the `puppetmaster_use_db` SELinux boolean, run the following command:

    $ sudo setsebool -P puppetmaster_use_db off

CCE-RHEL7-CCE-TBD

Disable the xserver_clients_write_xshm SELinux Boolean

By default, the SELinux boolean `xserver_clients_write_xshm` is disabled. If this setting is enabled, it should be disabled. To disable the `xserver_clients_write_xshm` SELinux boolean, run the following command:

    $ sudo setsebool -P xserver_clients_write_xshm off

CCE-RHEL7-CCE-TBD

Disable the mpd_enable_homedirs SELinux Boolean

By default, the SELinux boolean `mpd_enable_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `mpd_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P mpd_enable_homedirs off

CCE-RHEL7-CCE-TBD

Disable the use_ecryptfs_home_dirs SELinux Boolean

By default, the SELinux boolean `use_ecryptfs_home_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `use_ecryptfs_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P use_ecryptfs_home_dirs off

CCE-RHEL7-CCE-TBD

Disable the zebra_write_config SELinux Boolean

By default, the SELinux boolean `zebra_write_config` is disabled. If this setting is enabled, it should be disabled. To disable the `zebra_write_config` SELinux boolean, run the following command:

    $ sudo setsebool -P zebra_write_config off

CCE-RHEL7-CCE-TBD

Disable the use_nfs_home_dirs SELinux Boolean

By default, the SELinux boolean `use_nfs_home_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `use_nfs_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P use_nfs_home_dirs off

CCE-RHEL7-CCE-TBD

Disable the mock_enable_homedirs SELinux Boolean

By default, the SELinux boolean `mock_enable_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `mock_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P mock_enable_homedirs off

CCE-RHEL7-CCE-TBD

Disable the telepathy_tcp_connect_generic_network_ports SELinux Boolean

By default, the SELinux boolean `telepathy_tcp_connect_generic_network_ports` is enabled. This setting should be disabled as `telepathy` should not connect to any generic network ports. To disable the `telepathy_tcp_connect_generic_network_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P telepathy_tcp_connect_generic_network_ports off

CCE-RHEL7-CCE-TBD

Disable the sftpd_anon_write SELinux Boolean

By default, the SELinux boolean `sftpd_anon_write` is disabled. If this setting is enabled, it should be disabled. To disable the `sftpd_anon_write` SELinux boolean, run the following command:

    $ sudo setsebool -P sftpd_anon_write off

CCE-RHEL7-CCE-TBD

Disable the virt_transition_userdomain SELinux Boolean

By default, the SELinux boolean `virt_transition_userdomain` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_transition_userdomain` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_transition_userdomain off

CCE-RHEL7-CCE-TBD

Disable the httpd_ssi_exec SELinux Boolean

By default, the SELinux boolean `httpd_ssi_exec` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_ssi_exec` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_ssi_exec off

CCE-RHEL7-CCE-TBD

Disable the sftpd_enable_homedirs SELinux Boolean

By default, the SELinux boolean `sftpd_enable_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `sftpd_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P sftpd_enable_homedirs off

CCE-RHEL7-CCE-TBD

Disable the mpd_use_cifs SELinux Boolean

By default, the SELinux boolean `mpd_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `mpd_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P mpd_use_cifs off

CCE-RHEL7-CCE-TBD

Disable the use_lpd_server SELinux Boolean

By default, the SELinux boolean `use_lpd_server` is disabled. If this setting is enabled, it should be disabled. To disable the `use_lpd_server` SELinux boolean, run the following command:

    $ sudo setsebool -P use_lpd_server off

CCE-RHEL7-CCE-TBD

Disable the xdm_write_home SELinux Boolean

By default, the SELinux boolean `xdm_write_home` is disabled. If this setting is enabled, it should be disabled. To disable the `xdm_write_home` SELinux boolean, run the following command:

    $ sudo setsebool -P xdm_write_home off

CCE-RHEL7-CCE-TBD

Disable the polipo_use_nfs SELinux Boolean

By default, the SELinux boolean `polipo_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `polipo_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P polipo_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the lsmd_plugin_connect_any SELinux Boolean

By default, the SELinux boolean `lsmd_plugin_connect_any` is disabled. If this setting is enabled, it should be disabled. To disable the `lsmd_plugin_connect_any` SELinux boolean, run the following command:

    $ sudo setsebool -P lsmd_plugin_connect_any off

CCE-RHEL7-CCE-TBD

Disable the ftpd_connect_all_unreserved SELinux Boolean

By default, the SELinux boolean `ftpd_connect_all_unreserved` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_connect_all_unreserved` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_connect_all_unreserved off

CCE-RHEL7-CCE-TBD

Disable the httpd_can_connect_mythtv SELinux Boolean

By default, the SELinux boolean `httpd_can_connect_mythtv` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_connect_mythtv` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_connect_mythtv off

CCE-RHEL7-CCE-TBD

Disable the ksmtuned_use_cifs SELinux Boolean

By default, the SELinux boolean `ksmtuned_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `ksmtuned_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P ksmtuned_use_cifs off

CCE-RHEL7-CCE-TBD

Disable the dhcpc_exec_iptables SELinux Boolean

By default, the SELinux boolean `dhcpc_exec_iptables` is disabled. If this setting is enabled, it should be disabled. To disable the `dhcpc_exec_iptables` SELinux boolean, run the following command:

    $ sudo setsebool -P dhcpc_exec_iptables off

CCE-RHEL7-CCE-TBD

Enable the selinuxuser_execmod SELinux Boolean

By default, the SELinux boolean `selinuxuser_execmod` is enabled. If this setting is disabled, it should be enabled. To enable the `selinuxuser_execmod` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_execmod on

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_udp_server SELinux Boolean

By default, the SELinux boolean `selinuxuser_udp_server` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_udp_server` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_udp_server off

CCE-RHEL7-CCE-TBD

Disable the samba_create_home_dirs SELinux Boolean

By default, the SELinux boolean `samba_create_home_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_create_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_create_home_dirs off

CCE-RHEL7-CCE-TBD

Disable the mmap_low_allowed SELinux Boolean

By default, the SELinux boolean `mmap_low_allowed` is disabled. If this setting is enabled, it should be disabled. To disable the `mmap_low_allowed` SELinux boolean, run the following command:

    $ sudo setsebool -P mmap_low_allowed off

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_share_music SELinux Boolean

By default, the SELinux boolean `selinuxuser_share_music` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_share_music` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_share_music off

CCE-RHEL7-CCE-TBD

Disable the ftpd_use_cifs SELinux Boolean

By default, the SELinux boolean `ftpd_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_use_cifs off

CCE-RHEL7-CCE-TBD

Enable the xend_run_blktap SELinux Boolean

By default, the SELinux boolean `xend_run_blktap` is enabled. If this setting is disabled, it should be enabled. To enable the `xend_run_blktap` SELinux boolean, run the following command:

    $ sudo setsebool -P xend_run_blktap on

CCE-RHEL7-CCE-TBD

Disable the mcelog_client SELinux Boolean

By default, the SELinux boolean `mcelog_client` is disabled. If this setting is enabled, it should be disabled. To disable the `mcelog_client` SELinux boolean, run the following command:

    $ sudo setsebool -P mcelog_client off

CCE-RHEL7-CCE-TBD

Disable the cluster_can_network_connect SELinux Boolean

By default, the SELinux boolean `cluster_can_network_connect` is disabled. If this setting is enabled, it should be disabled. To disable the `cluster_can_network_connect` SELinux boolean, run the following command:

    $ sudo setsebool -P cluster_can_network_connect off

CCE-RHEL7-CCE-TBD

Enable the domain_fd_use SELinux Boolean

By default, the SELinux boolean `domain_fd_use` is enabled. If this setting is disabled, it should be enabled. To enable the `domain_fd_use` SELinux boolean, run the following command:

    $ sudo setsebool -P domain_fd_use on

CCE-RHEL7-CCE-TBD

Disable the httpd_use_nfs SELinux Boolean

By default, the SELinux boolean `httpd_use_nfs` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_use_nfs` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_use_nfs off

CCE-RHEL7-CCE-TBD

Disable the ftpd_use_fusefs SELinux Boolean

By default, the SELinux boolean `ftpd_use_fusefs` is disabled. If this setting is enabled, it should be disabled. To disable the `ftpd_use_fusefs` SELinux boolean, run the following command:

    $ sudo setsebool -P ftpd_use_fusefs off

CCE-RHEL7-CCE-TBD

Disable the secure_mode SELinux Boolean

By default, the SELinux boolean `secure_mode` is disabled. If this setting is enabled, it should be disabled. To disable the `secure_mode` SELinux boolean, run the following command:

    $ sudo setsebool -P secure_mode off

CCE-RHEL7-CCE-TBD

Disable the cron_system_cronjob_use_shares SELinux Boolean

By default, the SELinux boolean `cron_system_cronjob_use_shares` is disabled. If this setting is enabled, it should be disabled. To disable the `cron_system_cronjob_use_shares` SELinux boolean, run the following command:

    $ sudo setsebool -P cron_system_cronjob_use_shares off

CCE-RHEL7-CCE-TBD

Enable the logadm_exec_content SELinux Boolean

By default, the SELinux boolean `logadm_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `logadm_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P logadm_exec_content on

CCE-RHEL7-CCE-TBD

Disable the use_samba_home_dirs SELinux Boolean

By default, the SELinux boolean `use_samba_home_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `use_samba_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P use_samba_home_dirs off

CCE-RHEL7-CCE-TBD

Disable the rsync_export_all_ro SELinux Boolean

By default, the SELinux boolean `rsync_export_all_ro` is disabled. If this setting is enabled, it should be disabled. To disable the `rsync_export_all_ro` SELinux boolean, run the following command:

    $ sudo setsebool -P rsync_export_all_ro off

CCE-RHEL7-CCE-TBD

Disable the xguest_connect_network SELinux Boolean

By default, the SELinux boolean `xguest_connect_network` is enabled. This setting should be disabled as guest users should not be able to configure `NetworkManager`. To disable the `xguest_connect_network` SELinux boolean, run the following command:

    $ sudo setsebool -P xguest_connect_network off

CCE-RHEL7-CCE-TBD

Disable the samba_enable_home_dirs SELinux Boolean

By default, the SELinux boolean `samba_enable_home_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `samba_enable_home_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P samba_enable_home_dirs off

CCE-RHEL7-CCE-TBD

Disable the saslauthd_read_shadow SELinux Boolean

By default, the SELinux boolean `saslauthd_read_shadow` is disabled. If this setting is enabled, it should be disabled. To disable the `saslauthd_read_shadow` SELinux boolean, run the following command:

    $ sudo setsebool -P saslauthd_read_shadow off

CCE-RHEL7-CCE-TBD

Disable the telepathy_connect_all_ports SELinux Boolean

By default, the SELinux boolean `telepathy_connect_all_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `telepathy_connect_all_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P telepathy_connect_all_ports off

CCE-RHEL7-CCE-TBD

Disable the named_write_master_zones SELinux Boolean

By default, the SELinux boolean `named_write_master_zones` is disabled. If this setting is enabled, it should be disabled. To disable the `named_write_master_zones` SELinux boolean, run the following command:

    $ sudo setsebool -P named_write_master_zones off

CCE-80423-7

Disable the antivirus_use_jit SELinux Boolean

By default, the SELinux boolean `antivirus_use_jit` is disabled. If this setting is enabled, it should be disabled. To disable the `antivirus_use_jit` SELinux boolean, run the following command:

    $ sudo setsebool -P antivirus_use_jit off

CCE-RHEL7-CCE-TBD

Enable the sysadm_exec_content SELinux Boolean

By default, the SELinux boolean `sysadm_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `sysadm_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P sysadm_exec_content on

CCE-RHEL7-CCE-TBD

Disable the xguest_use_bluetooth SELinux Boolean

By default, the SELinux boolean `xguest_use_bluetooth` is enabled. This setting should be disabled as guests users should not be able to access or use bluetooth. To disable the `xguest_use_bluetooth` SELinux boolean, run the following command:

    $ sudo setsebool -P xguest_use_bluetooth off

CCE-RHEL7-CCE-TBD

Disable the unprivuser_use_svirt SELinux Boolean

By default, the SELinux boolean `unprivuser_use_svirt` is disabled. If this setting is enabled, it should be disabled. To disable the `unprivuser_use_svirt` SELinux boolean, run the following command:

    $ sudo setsebool -P unprivuser_use_svirt off

CCE-RHEL7-CCE-TBD

Disable the kdumpgui_run_bootloader SELinux Boolean

By default, the SELinux boolean `kdumpgui_run_bootloader` is disabled. If this setting is enabled, it should be disabled. To disable the `kdumpgui_run_bootloader` SELinux boolean, run the following command:

    $ sudo setsebool -P kdumpgui_run_bootloader off

CCE-RHEL7-CCE-TBD

Disable the httpd_manage_ipa SELinux Boolean

By default, the SELinux boolean `httpd_manage_ipa` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_manage_ipa` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_manage_ipa off

CCE-RHEL7-CCE-TBD

Disable the tor_can_network_relay SELinux Boolean

By default, the SELinux boolean `tor_can_network_relay` is disabled. If this setting is enabled, it should be disabled. To disable the `tor_can_network_relay` SELinux boolean, run the following command:

    $ sudo setsebool -P tor_can_network_relay off

CCE-RHEL7-CCE-TBD

Disable the sanlock_use_samba SELinux Boolean

By default, the SELinux boolean `sanlock_use_samba` is disabled. If this setting is enabled, it should be disabled. To disable the `sanlock_use_samba` SELinux boolean, run the following command:

    $ sudo setsebool -P sanlock_use_samba off

CCE-RHEL7-CCE-TBD

Disable the httpd_dbus_sssd SELinux Boolean

By default, the SELinux boolean `httpd_dbus_sssd` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_dbus_sssd` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_dbus_sssd off

CCE-RHEL7-CCE-TBD

Disable the guest_exec_content SELinux Boolean

By default, the SELinux boolean `guest_exec_content` is enabled. This setting should be disabled as no guest accounts should be used. To enable the `guest_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P guest_exec_content on

CCE-RHEL7-CCE-TBD

Disable the httpd_can_connect_ldap SELinux Boolean

By default, the SELinux boolean `httpd_can_connect_ldap` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_can_connect_ldap` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_can_connect_ldap off

CCE-RHEL7-CCE-TBD

Disable the mcelog_foreground SELinux Boolean

By default, the SELinux boolean `mcelog_foreground` is disabled. If this setting is enabled, it should be disabled. To disable the `mcelog_foreground` SELinux boolean, run the following command:

    $ sudo setsebool -P mcelog_foreground off

CCE-RHEL7-CCE-TBD

Disable the httpd_mod_auth_ntlm_winbind SELinux Boolean

By default, the SELinux boolean `httpd_mod_auth_ntlm_winbind` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_mod_auth_ntlm_winbind` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_mod_auth_ntlm_winbind off

CCE-RHEL7-CCE-TBD

Disable the httpd_use_openstack SELinux Boolean

By default, the SELinux boolean `httpd_use_openstack` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_use_openstack` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_use_openstack off

CCE-RHEL7-CCE-TBD

Disable the httpd_use_cifs SELinux Boolean

By default, the SELinux boolean `httpd_use_cifs` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_use_cifs` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_use_cifs off

CCE-RHEL7-CCE-TBD

Disable the daemons_enable_cluster_mode SELinux Boolean

By default, the SELinux boolean `daemons_enable_cluster_mode` is disabled. If this setting is enabled, it should be disabled. To disable the `daemons_enable_cluster_mode` SELinux boolean, run the following command:

    $ sudo setsebool -P daemons_enable_cluster_mode off

CCE-RHEL7-CCE-TBD

Disable the daemons_dump_core SELinux Boolean

By default, the SELinux boolean `daemons_dump_core` is disabled. If this setting is enabled, it should be disabled. To disable the `daemons_dump_core` SELinux boolean, run the following command:

    $ sudo setsebool -P daemons_dump_core off

CCE-RHEL7-CCE-TBD

Enable the postfix_local_write_mail_spool SELinux Boolean

By default, the SELinux boolean `postfix_local_write_mail_spool` is enabled. If this setting is disabled, it should be enabled as it allows Postfix to write to the mail spool directories. To enable the `postfix_local_write_mail_spool` SELinux boolean, run the following command:

    $ sudo setsebool -P postfix_local_write_mail_spool on

CCE-RHEL7-CCE-TBD

Enable the xend_run_qemu SELinux Boolean

By default, the SELinux boolean `xend_run_qemu` is enabled. If this setting is disabled, it should be enabled. To enable the `xend_run_qemu` SELinux boolean, run the following command:

    $ sudo setsebool -P xend_run_qemu on

CCE-RHEL7-CCE-TBD

Disable the xdm_exec_bootloader SELinux Boolean

By default, the SELinux boolean `xdm_exec_bootloader` is disabled. If this setting is enabled, it should be disabled. To disable the `xdm_exec_bootloader` SELinux boolean, run the following command:

    $ sudo setsebool -P xdm_exec_bootloader off

CCE-RHEL7-CCE-TBD

Disable the exim_read_user_files SELinux Boolean

By default, the SELinux boolean `exim_read_user_files` is disabled. If this setting is enabled, it should be disabled. To disable the `exim_read_user_files` SELinux boolean, run the following command:

    $ sudo setsebool -P exim_read_user_files off

CCE-RHEL7-CCE-TBD

Disable the cvs_read_shadow SELinux Boolean

By default, the SELinux boolean `cvs_read_shadow` is disabled. If this setting is enabled, it should be disabled. To disable the `cvs_read_shadow` SELinux boolean, run the following command:

    $ sudo setsebool -P cvs_read_shadow off

CCE-RHEL7-CCE-TBD

Disable the git_system_enable_homedirs SELinux Boolean

By default, the SELinux boolean `git_system_enable_homedirs` is disabled. If this setting is enabled, it should be disabled. To disable the `git_system_enable_homedirs` SELinux boolean, run the following command:

    $ sudo setsebool -P git_system_enable_homedirs off

CCE-80418-7

Enable the fips_mode SELinux Boolean

By default, the SELinux boolean `fips_mode` is enabled. This allows all SELinux domains to execute in `fips_mode`. If this setting is disabled, it should be enabled. To enable the `fips_mode` SELinux boolean, run the following command:

    $ sudo setsebool -P fips_mode on

CCE-RHEL7-CCE-TBD

Enable the docker_transition_unconfined SELinux Boolean

By default, the SELinux boolean `docker_transition_unconfined` is enabled. If this setting is disabled, it should be enabled. To enable the `docker_transition_unconfined` SELinux boolean, run the following command:

    $ sudo setsebool -P docker_transition_unconfined on

CCE-RHEL7-CCE-TBD

Disable the polyinstantiation_enabled SELinux Boolean

By default, the SELinux boolean `polyinstantiation_enabled` is disabled. If this setting is enabled, it should be disabled. To disable the `polyinstantiation_enabled` SELinux boolean, run the following command:

    $ sudo setsebool -P polyinstantiation_enabled off

CCE-RHEL7-CCE-TBD

Disable the icecast_use_any_tcp_ports SELinux Boolean

By default, the SELinux boolean `icecast_use_any_tcp_ports` is disabled. If this setting is enabled, it should be disabled. To disable the `icecast_use_any_tcp_ports` SELinux boolean, run the following command:

    $ sudo setsebool -P icecast_use_any_tcp_ports off

CCE-RHEL7-CCE-TBD

Disable the secure_mode_insmod SELinux Boolean

By default, the SELinux boolean `secure_mode_insmod` is disabled. If this setting is enabled, it should be disabled. To disable the `secure_mode_insmod` SELinux boolean, run the following command:

    $ sudo setsebool -P secure_mode_insmod off

CCE-80425-2

Disable the authlogin_nsswitch_use_ldap SELinux Boolean

By default, the SELinux boolean `authlogin_nsswitch_use_ldap` is disabled. If this setting is enabled, it should be disabled. To disable the `authlogin_nsswitch_use_ldap` SELinux boolean, run the following command:

    $ sudo setsebool -P authlogin_nsswitch_use_ldap off

CCE-RHEL7-CCE-TBD

Disable the virt_sandbox_use_mknod SELinux Boolean

By default, the SELinux boolean `virt_sandbox_use_mknod` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_sandbox_use_mknod` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_sandbox_use_mknod off

CCE-RHEL7-CCE-TBD

Enable the selinuxuser_ping SELinux Boolean

By default, the SELinux boolean `selinuxuser_ping` is enabled. If this setting is disabled, it should be enabled as it allows confined users to use ping and traceroute which is helpful for network troubleshooting. To enable the `selinuxuser_ping` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_ping on

CCE-RHEL7-CCE-TBD

Disable the httpd_dontaudit_search_dirs SELinux Boolean

By default, the SELinux boolean `httpd_dontaudit_search_dirs` is disabled. If this setting is enabled, it should be disabled. To disable the `httpd_dontaudit_search_dirs` SELinux boolean, run the following command:

    $ sudo setsebool -P httpd_dontaudit_search_dirs off

CCE-RHEL7-CCE-TBD

Disable the secure_mode_policyload SELinux Boolean

By default, the SELinux boolean `secure_mode_policyload` is disabled. If this setting is enabled, it should be disabled. To disable the `secure_mode_policyload` SELinux boolean, run the following command:

    $ sudo setsebool -P secure_mode_policyload off

CCE-RHEL7-CCE-TBD

Disable the selinuxuser_execheap SELinux Boolean

By default, the SELinux boolean `selinuxuser_execheap` is disabled. If this setting is enabled, it should be disabled. To disable the `selinuxuser_execheap` SELinux boolean, run the following command:

    $ sudo setsebool -P selinuxuser_execheap off

CCE-RHEL7-CCE-TBD

Enable the secadm_exec_content SELinux Boolean

By default, the SELinux boolean `secadm_exec_content` is enabled. If this setting is disabled, it should be enabled. To enable the `secadm_exec_content` SELinux boolean, run the following command:

    $ sudo setsebool -P secadm_exec_content on

CCE-RHEL7-CCE-TBD

Disable the postgresql_selinux_transmit_client_label SELinux Boolean

By default, the SELinux boolean `postgresql_selinux_transmit_client_label` is disabled. If this setting is enabled, it should be disabled. To disable the `postgresql_selinux_transmit_client_label` SELinux boolean, run the following command:

    $ sudo setsebool -P postgresql_selinux_transmit_client_label off

CCE-RHEL7-CCE-TBD

Disable the virt_use_xserver SELinux Boolean

By default, the SELinux boolean `virt_use_xserver` is disabled. If this setting is enabled, it should be disabled. To disable the `virt_use_xserver` SELinux boolean, run the following command:

    $ sudo setsebool -P virt_use_xserver off

CCE-80445-0

Uninstall mcstrans Package

The `mcstransd` daemon provides category label information to client processes requesting information. The label translations are defined in `/etc/selinux/targeted/setrans.conf`. The `mcstrans` package can be removed with the following command:

    $ sudo yum erase mcstrans

CCE-80442-7

Ensure SELinux support is enabled in Docker

To enable the SELinux for the Docker service, the Docker service must be configured to run the Docker daemon with `--selinux-enabled` option. In `/etc/sysconfig/docker` configuration file, add or correct the following line to enable SELinux support in the Docker daemon:

    OPTIONS='--selinux-enabled'

CCE-27279-9

Configure SELinux Policy

The SELinux `targeted` policy is appropriate for general-purpose desktops and servers, as well as systems in many other roles. To configure the system to use this policy, add or correct the following line in `/etc/selinux/config`:

    SELINUXTYPE=

Other policies, such as `mls`, provide additional security labeling and greater confinement but are not compatible with many general-purpose use cases.

CCE-80444-3

Uninstall setroubleshoot Package

The SETroubleshoot service notifies desktop users of SELinux denials. The service provides information around configuration errors, unauthorized intrusions, and other potential errors. The `setroubleshoot` package can be removed with the following command:

    $ sudo yum erase setroubleshoot

CCE-26961-3 | Ensure SELinux Not Disabled in /etc/default/grub | SELinux can be disabled at boot time by an argument in `/etc/default/grub`. Remove any instances of `selinux=0` from the kernel arguments in that file to prevent SELinux from being disabled at boot.

CCE-27288-0

Ensure No Daemons are Unconfined by SELinux

Daemons for which the SELinux policy does not contain rules will inherit the context of the parent process. Because daemons are launched during startup and descend from the `init` process, they inherit the `initrc_t` context.
To check for unconfined daemons, run the following command:

    $ sudo ps -eZ | egrep "initrc" | egrep -vw "tr|ps|egrep|bash|awk" | tr ':' ' ' | awk '{ print $NF }'

It should produce no output in a well-configured system.

CCE-27326-8

Ensure No Device Files are Unlabeled by SELinux

Device files, which are used for communication with important system resources, should be labeled with proper SELinux types. If any device files do not carry the SELinux type `device_t`, report the bug so that policy can be corrected. Supply information about what the device is and what programs use it.
To check for unlabeled device files, run the following command:

    $ sudo find /dev -context *:device_t:* \( -type c -o -type b \) -printf "%p %Z\n"

It should produce no output in a well-configured system.

CCE-80543-2

Map System Users To The Appropriate SELinux Role

Configure the operating system to prevent non-privileged users from executing privileged functions to include disabling, circumventing, or altering implemented security safeguards/countermeasures. All administrators must be mapped to the `sysadm_u` or `staff_u` users with the appropriate domains (`sysadm_t` and `staff_t`).

    $ sudo semanage login -m -s sysadm_u USER

or

    $ sudo semanage login -m -s staff_u USER

All authorized non-administrative users must be mapped to the `user_u` role or the appropriate domain (user_t).

    $ sudo semanage login -m -s user_u USER

CCE-27334-2

Ensure SELinux State is Enforcing

The SELinux state should be set to `` at system boot time. In the file `/etc/selinux/config`, add or correct the following line to configure the system to boot into enforcing mode:

    SELINUX=

CCE-27268-2

Restrict Serial Port Root Logins

To restrict root logins on serial ports, ensure lines of this form do not appear in `/etc/securetty`:

    ttyS0
    ttyS1

CCE-80210-8

Root Path Must Be Vendor Default

Assuming root shell is bash, edit the following files:

    ~/.profile

    ~/.bashrc

Change any `PATH` variables to the vendor default for root and remove any empty `PATH` entries or references to relative paths.

CCE-27294-8

Direct root Logins Not Allowed

To further limit access to the `root` account, administrators can disable root logins at the console by editing the `/etc/securetty` file. This file lists all devices the root user is allowed to login to. If the file does not exist at all, the root user can login through any communication device on the system, whether via the console or via a raw network interface. This is dangerous as user can login to the system as root via Telnet, which sends the password in plain text over the network. By default, Red Hat Enteprise Linux's `/etc/securetty` file only allows the root user to login at the console physically attached to the system. To prevent root from logging in, remove the contents of this file. To prevent direct root logins, remove the contents of this file by typing the following command:

    $ sudo echo > /etc/securetty

CCE-80209-0 | Restrict Web Browser Use for Administrative Accounts | Enforce policy requiring administrative accounts use web browsers only for local service administration.

CCE-26448-1

Ensure that System Accounts Do Not Run a Shell Upon Login

Some accounts are not associated with a human user of the system, and exist to perform some administrative function. Should an attacker be able to log into these accounts, they should not be granted access to a shell.
The login shell for each local account is stored in the last field of each line in `/etc/passwd`. System accounts are those user accounts with a user ID less than UID_MIN, where value of UID_MIN directive is set in /etc/login.defs configuration file. In the default configuration UID_MIN is set to 1000, thus system accounts are those user accounts with a user ID less than 1000. The user ID is stored in the third field. If any system account SYSACCT (other than root) has a login shell, disable it with the command:

    $ sudo usermod -s /sbin/nologin SYSACCT

CCE-27318-5

Restrict Virtual Console Root Logins

To restrict root logins through the (deprecated) virtual console devices, ensure lines of this form do not appear in `/etc/securetty`:

    vc/1
    vc/2
    vc/3
    vc/4

CCE-27175-9

Verify Only Root Has UID 0

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.
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 greater than "1000" that has not already been assigned.

CCE-27286-4 | Prevent Log In to Accounts With Empty Password | If an account is configured for password authentication but does not have an assigned password, it may be possible to log into the account without authentication. Remove any instances of the `nullok` option in `/etc/pam.d/system-auth` to prevent logins with empty passwords.
CCE-80211-6 | Verify No netrc Files Exist | The `.netrc` files contain login information used to auto-login into FTP servers and reside in the user's home directory. These files may contain unencrypted passwords to remote FTP servers making them susceptible to access by unauthorized users and should not be used. Any `.netrc` files should be removed.
CCE-27352-4 | Verify All Account Password Hashes are Shadowed | If any password hashes are stored in `/etc/passwd` (in the second field, instead of an `x` or `*`), the cause of this misconfiguration should be investigated. The account should have its password reset and the hash should be properly stored, or the account should be deleted entirely.
CCE-27503-2 | All GIDs referenced in /etc/passwd must be defined in /etc/group | Add a group to the system for each GID referenced without a corresponding group.

CCE-27123-9

Set Password Minimum Length in login.defs

To specify password length requirements for new accounts, edit the file `/etc/login.defs` and add or correct the following line:

    PASS_MIN_LEN

The DoD requirement is `15`. The FISMA requirement is `12`. The profile requirement is ``. If a program consults `/etc/login.defs` and also another PAM module (such as `pam_pwquality`) during a password change operation, then the most restrictive must be satisfied. See PAM section for more information about enforcing password quality requirements.

CCE-26486-1

Set Password Warning Age

To specify how many days prior to password expiration that a warning will be issued to users, edit the file `/etc/login.defs` and add or correct the following line:

    PASS_WARN_AGE

The DoD requirement is 7. The profile requirement is ``.

CCE-27002-5

Set Password Minimum Age

To specify password minimum age for new accounts, edit the file `/etc/login.defs` and add or correct the following line:

    PASS_MIN_DAYS

A value of 1 day is considered sufficient for many environments. The DoD requirement is 1. The profile requirement is ``.

CCE-27051-2

Set Password Maximum Age

To specify password maximum age for new accounts, edit the file `/etc/login.defs` and add or correct the following line:

    PASS_MAX_DAYS

A value of 180 days is sufficient for many environments. The DoD requirement is 60. The profile requirement is ``.

CCE-80521-8

Set Existing Passwords Minimum Age

Configure non-compliant accounts to enforce a 24 hours/1 day minimum password lifetime by running the following command:

    $ sudo chage -m 1 USER

CCE-80522-6

Set Existing Passwords Maximum Age

Configure non-compliant accounts to enforce a 60-day maximum password lifetime restriction by running the following command:

    $ sudo chage -M 60 USER

CCE-80208-2 | Ensure All Accounts on the System Have Unique Names | Change usernames, or delete accounts, so each has a unique name.

CCE-27355-7

Set Account Expiration Following Inactivity

To specify the number of days after a password expires (which signifies inactivity) until an account is permanently disabled, add or correct the following lines in `/etc/default/useradd`, substituting `NUM_DAYS` appropriately:

    INACTIVE=

A value of 35 is recommended; however, this profile expects that the value is set to ``. If a password is currently on the verge of expiration, then 35 days remain until the account is automatically disabled. However, if the password will not expire for another 60 days, then 95 days could elapse until the account would be automatically disabled. See the `useradd` man page for more information. Determining the inactivity timeout must be done with careful consideration of the length of a "normal" period of inactivity for users in the particular environment. Setting the timeout too low incurs support costs and also has the potential to impact availability of the system to legitimate users.

CCE-27498-5

Assign Expiration Date to Temporary Accounts

Temporary accounts are established as part of normal account activation procedures when there is a need for short-term accounts. In the event temporary or emergency accounts are required, configure the system to terminate them after a documented time period. For every temporary and emergency account, run the following command to set an expiration date on it, substituting `USER` and `YYYY-MM-DD` appropriately:

    $ sudo chage -E YYYY-MM-DD USER

`YYYY-MM-DD` indicates the documented expiration date for the account. For U.S. Government systems, the operating system must be configured to automatically terminate these types of accounts after a period of 72 hours.

CCE-27351-6

Install the screen Package

To enable console screen locking, install the `screen` package:

    $ sudo yum install screen

Instruct users to begin new terminal sessions with the following command:

    $ screen

The console can now be locked with the following key combination:

    ctrl+a x

CCE-80207-4

Enable Smart Card Login

To enable smart card authentication, consult the documentation at:

- https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/System-Level_Authentication_Guide/smartcards.html#authconfig-smartcards

For guidance on enabling SSH to authenticate against a Common Access Card (CAC), consult documentation at:

- https://access.redhat.com/solutions/82273

CCE-80519-2

Install Smart Card Packages For Multifactor Authentication

Configure the operating system to implement multifactor authentication by installing the required packages with the following command:

    $ sudo yum install esc pam_pkcs11 authconfig-gtk

CCE-80520-0

Configure Smart Card Certificate Status Checking

Configure the operating system to do certificate status checking for PKI authentication. Modify all of the `cert_policy` lines in `/etc/pam_pkcs11/pam_pkcs11.conf` to include `ocsp_on` like so:

    cert_policy = ca, ocsp_on, signature;

CCE-26812-8

Verify /boot/grub2/grub.cfg Group Ownership

The file `/boot/grub2/grub.cfg` should be group-owned by the `root` group to prevent destruction or modification of the file. To properly set the group owner of `/boot/grub2/grub.cfg`, run the command:

    $ sudo chgrp root /boot/grub2/grub.cfg

CCE-26860-7

Verify /boot/grub2/grub.cfg User Ownership

The file `/boot/grub2/grub.cfg` should be owned by the `root` user to prevent destruction or modification of the file. To properly set the owner of `/boot/grub2/grub.cfg`, run the command:

    $ sudo chown root /boot/grub2/grub.cfg

CCE-27054-6

Verify /boot/grub2/grub.cfg Permissions

File permissions for `/boot/grub2/grub.cfg` should be set to 600. To properly set the permissions of `/boot/grub2/grub.cfg`, run the command:

    $ sudo chmod 600 /boot/grub2/grub.cfg

CCE-TBD

Verify /boot/efi/EFI/redhat/grub.cfg User Ownership

The file `/boot/efi/EFI/redhat/grub.cfg` should be owned by the `root` user to prevent destruction or modification of the file. To properly set the owner of `/boot/efi/EFI/redhat/grub.cfg`, run the command:

    $ sudo chown root /boot/efi/EFI/redhat/grub.cfg

CCE-80518-4

UEFI Boat Loader Is Not Installed On Removeable Media

The system must not allow removable media to be used as the boot loader. Remove alternate methods of booting the system from removable media. `usb0`, `cd`, `fd0`, etc. are some examples of removeable media which should not exist in the line:

    set root='hd0,msdos1'

CCE-TBD

Verify /boot/efi/EFI/redhat/grub.cfg Group Ownership

The file `/boot/efi/EFI/redhat/grub.cfg` should be group-owned by the `root` group to prevent destruction or modification of the file. To properly set the group owner of `/boot/efi/EFI/redhat/grub.cfg`, run the command:

    $ sudo chgrp root /boot/efi/EFI/redhat/grub.cfg

CCE-80517-6

Boat Loader Is Not Installed On Removeable Media

The system must not allow removable media to be used as the boot loader. Remove alternate methods of booting the system from removable media. `usb0`, `cd`, `fd0`, etc. are some examples of removeable media which should not exist in the line:

    set root='hd0,msdos1'

CCE-27309-4

Set Boot Loader Password

The grub2 boot loader should have a superuser account and password protection enabled to protect boot-time settings.
To do so, select a superuser account name and password and and modify the `/etc/grub.d/01_users` configuration file with the new account name.
Since plaintext passwords are a security risk, generate a hash for the pasword by running the following command:

    $ grub2-setpassword

When prompted, enter the password that was selected.
NOTE: It is recommended not to use common administrator account names like root, admin, or administrator for the grub2 superuser account.
Change the superuser to a different username (The default is 'root').

    $ sed -i s/root/bootuser/g /etc/grub.d/01_users

To meet FISMA Moderate, the bootloader superuser account and password MUST differ from the root account and password. Once the superuser account and password have been added, update the `grub.cfg` file by running:

    grub2-mkconfig -o /boot/grub2/grub.cfg

NOTE: Do NOT manually add the superuser account and password to the `grub.cfg` file as the grub2-mkconfig command overwrites this file.

CCE-80354-4

Set the UEFI Boot Loader Password

The grub2 boot loader should have a superuser account and password protection enabled to protect boot-time settings.
To do so, select a superuser account name and password and and modify the `/etc/grub.d/01_users` configuration file with the new account name.
Since plaintext passwords are a security risk, generate a hash for the pasword by running the following command:

    $ grub2-setpassword

When prompted, enter the password that was selected.
NOTE: It is recommended not to use common administrator account names like root, admin, or administrator for the grub2 superuser account.
Change the superuser to a different username (The default is 'root').

    $ sed -i s/root/bootuser/g /etc/grub.d/01_users

To meet FISMA Moderate, the bootloader superuser account and password MUST differ from the root account and password. Once the superuser account and password have been added, update the `grub.cfg` file by running:

    grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg

NOTE: Do NOT manually add the superuser account and password to the `grub.cfg` file as the grub2-mkconfig command overwrites this file.

CCE-TBD

Verify /boot/efi/EFI/redhat/grub.cfg Permissions

File permissions for `/boot/efi/EFI/redhat/grub.cfg` should be set to 600. To properly set the permissions of `/boot/efi/EFI/redhat/grub.cfg`, run the command:

    $ sudo chmod 700 /boot/efi/EFI/redhat/grub.cfg

CCE-27335-9

Verify that Interactive Boot is Disabled

Red Hat Enterprise Linux systems support an "interactive boot" option that can be used to prevent services from being started. On a Red Hat Enterprise Linux 7 system, interactive boot can be enabled by providing a `1`, `yes`, `true`, or `on` value to the `systemd.confirm_spawn` kernel argument in `/etc/default/grub`. Remove any instance of

    systemd.confirm_spawn=(1|yes|true|on)

from the kernel arguments in that file to disable interactive boot.

CCE-80449-2

Disable Ctrl-Alt-Del Burst Action

By default, `SystemD` will reboot the system if the `Ctrl-Alt-Del` key sequence is pressed Ctrl-Alt-Delete more than 7 times in 2 seconds.
To configure the system to ignore the `CtrlAltDelBurstAction` setting, add or modify the following to `/etc/systemd/system.conf`:

    CtrlAltDelBurstAction=none

CCE-27287-2

Require Authentication for Single User Mode

Single-user mode is intended as a system recovery method, providing a single user root access to the system by providing a boot option at startup. By default, no authentication is performed if single-user mode is selected.
By default, single-user mode is protected by requiring a password and is set in `/usr/lib/systemd/system/rescue.service`.

CCE-27511-5

Disable Ctrl-Alt-Del Reboot Activation

By default, `SystemD` will reboot the system if the `Ctrl-Alt-Del` key sequence is pressed.
To configure the system to ignore the `Ctrl-Alt-Del` key sequence from the command line instead of rebooting the system, do either of the following:

    ln -sf /dev/null /etc/systemd/system/ctrl-alt-del.target

or

    systemctl mask ctrl-alt-del.target

Do not simply delete the `/usr/lib/systemd/system/ctrl-alt-del.service` file, as this file may be restored during future system updates.

CCE-80206-6

Disable debug-shell SystemD Service

SystemD's `debug-shell` service is intended to diagnose SystemD related boot issues with various `systemctl` commands. Once enabled and following a system reboot, the root shell will be available on `tty9` which is access by pressing `CTRL-ALT-F9`. The `debug-shell` service should only be used for SystemD related issues and should otherwise be disabled.
By default, the `debug-shell` SystemD service is disabled. The `debug-shell` service can be disabled with the following command:

    $ sudo systemctl disable debug-shell.service

CCE-80199-3

Ensure that Root's Path Does Not Include Relative Paths or Null Directories

Ensure that none of the directories in root's path is equal to a single `.` character, or that it contains any instances that lead to relative path traversal, such as `..` or beginning a path without the slash (`/`) character. Also ensure that there are no "empty" elements in the path, such as in these examples:

    PATH=:/bin
    PATH=/bin:
    PATH=/bin::/sbin

These empty elements have the same effect as a single `.` character.

CCE-80200-9

Ensure that Root's Path Does Not Include World or Group-Writable Directories

For each element in root's path, run:

    # ls -ld DIR

and ensure that write permissions are disabled for group and other.

CCE-80536-6 | Ensure the Default Umask is Set Correctly For Interactive Users | Remove the `UMASK` environment variable from all interactive users initialization files.

CCE-80205-8

Ensure the Default Umask is Set Correctly in login.defs

To ensure the default umask controlled by `/etc/login.defs` is set properly, add or correct the `UMASK` setting in `/etc/login.defs` to read as follows:

    UMASK

CCE-80202-5

Ensure the Default Bash Umask is Set Correctly

To ensure the default umask for users of the Bash shell is set properly, add or correct the `umask` setting in `/etc/bashrc` to read as follows:

    umask

CCE-80203-3

Ensure the Default C Shell Umask is Set Correctly

To ensure the default umask for users of the C shell is set properly, add or correct the `umask` setting in `/etc/csh.cshrc` to read as follows:

    umask

CCE-80204-1

Ensure the Default Umask is Set Correctly in /etc/profile

To ensure the default umask controlled by `/etc/profile` is set properly, add or correct the `umask` setting in `/etc/profile` to read as follows:

    umask

CCE-80201-7

Ensure that User Home Directories are not Group-Writable or World-Readable

For each human user of the system, view the permissions of the user's home directory:

    # ls -ld /home/USER

Ensure that the directory is not group-writable and that it is not world-readable. If necessary, repair the permissions:

    # chmod g-w /home/USER
    # chmod o-rwx /home/USER

CCE-80529-1

All Interactive Users Home Directories Must Exist

Create home directories to all 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`:

    $ sudo mkdir /home/USER

CCE-80527-5

User Initialization Files Must Be Owned By the Primary User

Set the owner of the user initialization files for interactive users to the primary owner with the following command:

    $ sudo chown USER /home/USER/.*

CCE-80525-9

Ensure All User Initialization Files Have Mode 0740 Or Less Permissive

Set the mode of the user initialization files to `0740` with the following command:

    $ sudo chmod 0740 /home/USER/.INIT_FILE

CCE-80523-4

User Initialization Files Must Not Run World-Writable Programs

Set the mode on files being executed by the user initialization files with the following command:

    $ sudo chmod 0755 FILE

CCE-80434-4

Ensure Home Directories are Created for New Users

All local interactive user accounts, upon creation, should be assigned a home directory.
Configure the operating system to assign home directories to all new local interactive users by setting the `CREATE_HOME` parameter in `/etc/login.defs` to `yes` as follows:

    CREATE_HOME yes

CCE-80352-8

Ensure the Logon Failure Delay is Set Correctly in login.defs

To ensure the logon failure delay controlled by `/etc/login.defs` is set properly, add or correct the `FAIL_DELAY` setting in `/etc/login.defs` to read as follows:

    FAIL_DELAY

CCE-80534-1

All User Files and Directories In The Home Directory Must Be Group-Owned By The Primary User

Change the group of a local interactive users files and directories to a group that the interactive user is a member of. To change the group owner of a local interactive users files and directories, use the following command:

    $ sudo chgrp USER_GROUP /home/USER/FILE_DIR

CCE-80524-2 | Ensure that Users Path Contains Only Local Directories | Ensure that all interactive user initialization files executable search path statements do not contain statements that will reference a working directory other than the users home directory.

CCE-27557-8

Set Interactive Session Timeout

Setting the `TMOUT` option in `/etc/profile` ensures that all user sessions will terminate based on inactivity. The `TMOUT` setting in `/etc/profile` should read as follows:

    TMOUT=

CCE-80535-8

All User Files and Directories In The Home Directory Must Have Mode 0750 Or Less Permissive

Set the mode on files and directories in the local interactive user home directory with the following command:

    $ sudo chmod 0750 /home/USER/FILE_DIR

CCE-27081-9

Limit the Number of Concurrent Login Sessions Allowed Per User

Limiting the number of allowed users and sessions per user can limit risks related to Denial of Service attacks. This addresses concurrent sessions for a single account and does not address concurrent sessions by a single user via multiple accounts. To set the number of concurrent sessions per user add the following line in `/etc/security/limits.conf`:

    * hard maxlogins

CCE-80532-5

All Interactive User Home Directories Must Be Group-Owned By The Primary User

Change the group owner of interactive users home directory to the group found in `/etc/passwd`. To change the group owner of interactive users home directory, use the following command:

    $ sudo chgrp USER_GROUP /home/USER

CCE-80528-3 | All Interactive Users Must Have A Home Directory Defined | Assign home directories to all interactive users that currently do not have a home directory assigned.

CCE-80531-7

All Interactive User Home Directories Must Be Owned By The Primary User

Change the owner of interactive users home directories to that correct owner. To change the owner of a interactive users home directory, use the following command:

    $ sudo chown USER /home/USER

CCE-80533-3

All User Files and Directories In The Home Directory Must Be Owned By The Primary User

Change the owner of a interactive users files and directories to that owner. To change the of a local interactive users files and directories, use the following command:

    $ sudo chown -R USER /home/USER

CCE-80526-7

User Initialization Files Must Be Group-Owned By The Primary User

Change the group owner of interactive users files to the group found in

    /etc/passwd

for the user. To change the group owner of a local interactive user home directory, use the following command:

    $ sudo chgrp USER_GROUP /home/USER/.INIT_FILE

CCE-80530-9

All Interactive User Home Directories Must Have mode 0750 Or Less Permissive

Change the mode of interactive users home directories to `0750`. To change the mode of interactive users home directory, use the following command:

    $ sudo chmod 0750 /home/USER

CCE-26970-4

Enable GNOME3 Login Warning Banner

In the default graphical environment, displaying a login warning banner in the GNOME Display Manager's login screen can be enabled on the login screen by setting `banner-message-enable` to `true`.
To enable, add or edit `banner-message-enable` to `/etc/dconf/db/gdm.d/00-security-settings`. For example:

    [org/gnome/login-screen]
    banner-message-enable=true

Once the setting has been added, add a lock to `/etc/dconf/db/gdm.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/login-screen/banner-message-enable

After the settings have been set, run `dconf update`. The banner text must also be set.

CCE-26892-0

Set the GNOME3 Login Warning Banner Text

In the default graphical environment, configuring the login warning banner text in the GNOME Display Manager's login screen can be configured on the login screen by setting `banner-message-text` to `string 'APPROVED_BANNER'` where APPROVED_BANNER is the approved banner for your environment.
To enable, add or edit `banner-message-text` to `/etc/dconf/db/gdm.d/00-security-settings`. For example:

    [org/gnome/login-screen]
    banner-message-text=string 'APPROVED_BANNER'

Once the setting has been added, add a lock to `/etc/dconf/db/gdm.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/login-screen/banner-message-text

After the settings have been set, run `dconf update`. When entering a warning banner that spans several lines, remember to begin and end the string with `'` and use `\n` for new lines.

CCE-27303-7

Modify the System Login Banner

To configure the system login banner edit `/etc/issue`. Replace the default text with a message compliant with the local site policy or a legal disclaimer. The DoD required text is either:
`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.`
OR:
`I've read & consent to terms in IS user agreem't.`

CCE-27124-7

Set Password Hashing Algorithm in /etc/login.defs

In `/etc/login.defs`, add or correct the following line to ensure the system will use SHA-512 as the hashing algorithm:

    ENCRYPT_METHOD SHA512

CCE-27104-9

Set PAM's Password Hashing Algorithm

The PAM system service can be configured to only store encrypted representations of passwords. In `/etc/pam.d/system-auth`, the `password` section of the file controls which PAM modules execute during a password change. Set the `pam_unix.so` module in the `password` section to include the argument `sha512`, as shown below:

    password    sufficient    pam_unix.so sha512 other arguments...

This will help ensure when local users change their passwords, hashes for the new passwords will be generated using the SHA-512 algorithm. This is the default.

CCE-27053-8

Set Password Hashing Algorithm in /etc/libuser.conf

In `/etc/libuser.conf`, add or correct the following line in its `[defaults]` section to ensure the system will use the SHA-512 algorithm for password hashing:

    crypt_style = sha512

CCE-80353-6

Configure the root Account for Failed Password Attempts

To configure the system to lock out the `root` account after a number of incorrect login attempts using `pam_faillock.so`, modify the content of both `/etc/pam.d/system-auth` and `/etc/pam.d/password-auth` as follows:

- Modify the following line in the `AUTH` section to add `even_deny_root`:

      auth required pam_faillock.so preauth silent even_deny_root deny= unlock_time= fail_interval=

- Modify the following line in the `AUTH` section to add `even_deny_root`:

      auth [default=die] pam_faillock.so authfail even_deny_root deny= unlock_time= fail_interval=

CCE-26884-7

Set Lockout Time For Failed Password Attempts

To configure the system to lock out accounts after a number of incorrect login attempts and require an administrator to unlock the account using `pam_faillock.so`, modify the content of both `/etc/pam.d/system-auth` and `/etc/pam.d/password-auth` as follows:

- add the following line immediately `before` the `pam_unix.so` statement in the `AUTH` section:

      auth required pam_faillock.so preauth silent deny= unlock_time= fail_interval=

- add the following line immediately `after` the `pam_unix.so` statement in the `AUTH` section:

      auth [default=die] pam_faillock.so authfail deny= unlock_time= fail_interval=

- add the following line immediately `before` the `pam_unix.so` statement in the `ACCOUNT` section:

      account required pam_faillock.so

CCE-26923-3

Limit Password Reuse

Do not allow users to reuse recent passwords. This can be accomplished by using the `remember` option for the `pam_unix` or `pam_pwhistory` PAM modules.
In the file `/etc/pam.d/system-auth`, append `remember=` to the line which refers to the `pam_unix.so` or `pam_pwhistory.so`module, as shown below:

- for the `pam_unix.so` case:

      password sufficient pam_unix.so ...existing_options... remember=

- for the `pam_pwhistory.so` case:

      password requisite pam_pwhistory.so ...existing_options... remember=

The DoD STIG requirement is 5 passwords.

CCE-27297-1

Set Interval For Counting Failed Password Attempts

Utilizing `pam_faillock.so`, the `fail_interval` directive configures the system to lock out an accounts after a number of incorrect login attempts within a specified time period. Modify the content of both `/etc/pam.d/system-auth` and `/etc/pam.d/password-auth` as follows:

- Add the following line immediately `before` the `pam_unix.so` statement in the `AUTH` section:

      auth required pam_faillock.so preauth silent deny= unlock_time= fail_interval=

- Add the following line immediately `after` the `pam_unix.so` statement in the `AUTH` section:

      auth [default=die] pam_faillock.so authfail deny= unlock_time= fail_interval=

- Add the following line immediately `before` the `pam_unix.so` statement in the `ACCOUNT` section:

      account required pam_faillock.so

CCE-27350-8

Set Deny For Failed Password Attempts

To configure the system to lock out accounts after a number of incorrect login attempts using `pam_faillock.so`, modify the content of both `/etc/pam.d/system-auth` and `/etc/pam.d/password-auth` as follows:

- add the following line immediately `before` the `pam_unix.so` statement in the `AUTH` section:

      auth required pam_faillock.so preauth silent deny= unlock_time= fail_interval=

- add the following line immediately `after` the `pam_unix.so` statement in the `AUTH` section:

      auth [default=die] pam_faillock.so authfail deny= unlock_time= fail_interval=

- add the following line immediately `before` the `pam_unix.so` statement in the `ACCOUNT` section:

      account required pam_faillock.so

CCE-27293-0 | Set Password Minimum Length | The pam_pwquality module's `minlen` parameter controls requirements for minimum characters required in a password. Add `minlen=` after pam_pwquality to set minimum password length requirements.

CCE-27512-3

Set Password to Maximum of Consecutive Repeating Characters from Same Character Class

The pam_pwquality module's `maxclassrepeat` parameter controls requirements for consecutive repeating characters from the same character class. When set to a positive number, it will reject passwords which contain more than that number of consecutive characters from the same character class. Modify the `maxclassrepeat` setting in `/etc/security/pwquality.conf` to equal to prevent a run of ( + 1) or more identical characters.

CCE-27333-4

Set Password Maximum Consecutive Repeating Characters

The pam_pwquality module's `maxrepeat` parameter controls requirements for consecutive repeating characters. When set to a positive number, it will reject passwords which contain more than that number of consecutive characters. Modify the `maxrepeat` setting in `/etc/security/pwquality.conf` to equal to prevent a run of ( + 1) or more identical characters.

CCE-27214-6

Set Password Strength Minimum Digit Characters

The pam_pwquality module's `dcredit` parameter controls requirements for usage of digits in a password. When set to a negative number, any password will be required to contain that many digits. When set to a positive number, pam_pwquality will grant +1 additional length credit for each digit. Modify the `dcredit` setting in `/etc/security/pwquality.conf` to require the use of a digit in passwords.

CCE-27115-5

Set Password Strength Minimum Different Categories

The pam_pwquality module's `minclass` parameter controls requirements for usage of different character classes, or types, of character that must exist in a password before it is considered valid. For example, setting this value to three (3) requires that any password must have characters from at least three different categories in order to be approved. The default value is zero (0), meaning there are no required classes. There are four categories available:

    * Upper-case characters
    * Lower-case characters
    * Digits
    * Special characters (for example, punctuation)

Modify the `minclass` setting in `/etc/security/pwquality.conf` entry to require differing categories of characters when changing passwords.

CCE-26631-2 | Set Password Strength Minimum Different Characters | The pam_pwquality module's `difok` parameter sets the number of characters in a password that must not be present in and old password during a password change. Modify the `difok` setting in `/etc/security/pwquality.conf` to equal to require differing characters when changing passwords.

CCE-27360-7

Set Password Strength Minimum Special Characters

The pam_pwquality module's `ocredit=` parameter controls requirements for usage of special (or "other") characters in a password. When set to a negative number, any password will be required to contain that many special characters. When set to a positive number, pam_pwquality will grant +1 additional length credit for each special character. Modify the `ocredit` setting in `/etc/security/pwquality.conf` to equal to require use of a special character in passwords.

CCE-27345-8

Set Password Strength Minimum Lowercase Characters

The pam_pwquality module's `lcredit` parameter controls requirements for usage of lowercase letters in a password. When set to a negative number, any password will be required to contain that many lowercase characters. When set to a positive number, pam_pwquality will grant +1 additional length credit for each lowercase character. Modify the `lcredit` setting in `/etc/security/pwquality.conf` to require the use of a lowercase character in passwords.

CCE-27200-5

Set Password Strength Minimum Uppercase Characters

The pam_pwquality module's `ucredit=` parameter controls requirements for usage of uppercase letters in a password. When set to a negative number, any password will be required to contain that many uppercase characters. When set to a positive number, pam_pwquality will grant +1 additional length credit for each uppercase character. Modify the `ucredit` setting in `/etc/security/pwquality.conf` to require the use of an uppercase character in passwords.

CCE-27160-1 | Set Password Retry Prompts Permitted Per-Session | To configure the number of retry prompts that are permitted per-session: Edit the `pam_pwquality.so` statement in `/etc/pam.d/system-auth` to show `retry=`, or a lower value if site policy is more restrictive. The DoD requirement is a maximum of 3 prompts per session.

CCE-27275-7

Set Last Logon/Access Notification

To configure the system to notify users of last logon/access using `pam_lastlog`, add or correct the `pam_lastlog` settings in `/etc/pam.d/postlogin` to read as follows:

    session     [success=1 default=ignore] pam_succeed_if.so service !~ gdm* service !~ su* quiet
    session     [default=1]   pam_lastlog.so nowtmp showfailed
    session     optional      pam_lastlog.so silent noupdate showfailed

CCE-27100-7

Verify Permissions on shadow File

To properly set the permissions of `/etc/shadow`, run the command:

    $ sudo chmod 0000 /etc/shadow

CCE-27125-4

Verify Group Who Owns shadow File

To properly set the group owner of `/etc/shadow`, run the command:

    $ sudo chgrp root /etc/shadow

CCE-26933-2

Verify User Who Owns group File

To properly set the owner of `/etc/group`, run the command:

    $ sudo chown root /etc/group

CCE-26949-8

Verify Permissions on group File

To properly set the permissions of `/etc/group`, run the command:

    $ sudo chmod 644 /etc/group

CCE-27138-7

Verify User Who Owns passwd File

To properly set the owner of `/etc/passwd`, run the command:

    $ sudo chown root /etc/passwd

CCE-26840-9

Verify Group Who Owns gshadow File

To properly set the group owner of `/etc/gshadow`, run the command:

    $ sudo chgrp root /etc/gshadow

CCE-26639-5

Verify Group Who Owns passwd File

To properly set the group owner of `/etc/passwd`, run the command:

    $ sudo chgrp root /etc/passwd

CCE-27161-9

Verify User Who Owns gshadow File

To properly set the owner of `/etc/gshadow`, run the command:

    $ sudo chown root /etc/gshadow

CCE-27037-1

Verify Group Who Owns group File

To properly set the group owner of `/etc/group`, run the command:

    $ sudo chgrp root /etc/group

CCE-27162-7

Verify Permissions on gshadow File

To properly set the permissions of `/etc/gshadow`, run the command:

    $ sudo chmod 0000 /etc/gshadow

CCE-26795-5

Verify User Who Owns shadow File

To properly set the owner of `/etc/shadow`, run the command:

    $ sudo chown root /etc/shadow

CCE-26887-0

Verify Permissions on passwd File

To properly set the permissions of `/etc/passwd`, run the command:

    $ sudo chmod 0644 /etc/passwd

CCE-26648-6

Verify that Shared Library Files Have Root Ownership

System-wide shared library files, which are linked to executables during process load time or run time, are stored in the following directories by default:

    /lib
    /lib64
    /usr/lib
    /usr/lib64

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:

    $ sudo chown root FILE

CCE-27075-1

Verify that System Executables Have Restrictive Permissions

System executables are stored in the following directories by default:

    /bin
    /sbin
    /usr/bin
    /usr/libexec
    /usr/local/bin
    /usr/local/sbin
    /usr/sbin

All files in these directories should not be group-writable or world-writable. If any file 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

CCE-27119-7

Verify that System Executables Have Root Ownership

System executables are stored in the following directories by default:

    /bin
    /sbin
    /usr/bin
    /usr/libexec
    /usr/local/bin
    /usr/local/sbin
    /usr/sbin

All files in these directories should be owned by the `root` user. If any file 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

CCE-26966-2

Verify that Shared Library Files Have Restrictive Permissions

System-wide shared library files, which are linked to executables during process load time or run time, are stored in the following directories by default:

    /lib
    /lib64
    /usr/lib
    /usr/lib64

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:

    $ sudo chmod go-w FILE

CCE-80132-4 | Ensure All SGID Executables Are Authorized | The SGID (set group id) bit should be set only on files that were installed via authorized means. A straightforward means of identifying unauthorized SGID files is determine if any were not installed as part of an RPM package, which is cryptographically verified. Investigate the origin of any unpackaged SGID files.
CCE-80135-7 | Ensure All Files Are Owned by a Group | If any files are not owned by a group, then the cause of their lack of group-ownership should be investigated. Following this, the files should be deleted or assigned to an appropriate group.
CCE-80136-5 | Ensure All World-Writable Directories Are Owned by a System Account | All 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.
CCE-80134-0 | Ensure All Files Are Owned by a User | If any files are not owned by a user, then the cause of their lack of ownership should be investigated. Following this, the files should be deleted or assigned to an appropriate user.

CCE-80131-6

Ensure No World-Writable Files Exist

It is generally a good idea to remove global (other) write access to a file when it is discovered. However, check with documentation for specific applications before making changes. Also, monitor for recurring world-writable files, as these may be symptoms of a misconfigured application or user account. Finally, this applies to real files and not virtual files that are a part of pseudo file systems such as `sysfs` or `procfs`.

CCE-80130-8

Verify that All World-Writable Directories Have Sticky Bits Set

When the so-called 'sticky bit' is set on a directory, only the owner of a given file may remove that file from the directory. Without the sticky bit, any user with write access to a directory may remove any file in the directory. Setting the sticky bit prevents users from removing each other's files. In cases where there is no reason for a directory to be world-writable, a better solution is to remove that permission rather than to set the sticky bit. However, if a directory is used by a particular application, consult that application's documentation instead of blindly changing modes.
To set the sticky bit on a world-writable directory DIR, run the following command:

    $ sudo chmod +t DIR

CCE-80133-2 | Ensure All SUID Executables Are Authorized | The SUID (set user id) bit should be set only on files that were installed via authorized means. A straightforward means of identifying unauthorized SGID files is determine if any were not installed as part of an RPM package, which is cryptographically verified. Investigate the origin of any unpackaged SUID files.

CCE-27277-3

Disable Modprobe Loading of USB Storage Driver

To prevent USB storage devices from being used, configure the kernel module loading system to prevent automatic loading of the USB storage driver. To configure the system to prevent the `usb-storage` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install usb-storage /bin/true

This will prevent the `modprobe` program from loading the `usb-storage` module, but will not prevent an administrator (or another program) from using the `insmod` program to load the module manually.

CCE-26548-8

Disable Kernel Support for USB via Bootloader Configuration

All USB support can be disabled by adding the `nousb` argument to the kernel's boot loader configuration. To do so, append "nousb" to the kernel line in `/etc/default/grub` as shown:

    kernel /vmlinuz-VERSION ro vga=ext root=/dev/VolGroup00/LogVol00 rhgb quiet nousb

WARNING: Disabling all kernel support for USB will cause problems for systems with USB-based keyboards, mice, or printers. This configuration is infeasible for systems which require USB devices, which is common.

CCE-27194-0 | Assign Password to Prevent Changes to Boot Firmware Configuration | Assign a password to the system boot firmware (historically called BIOS on PC systems) to require a password for any configuration changes.
CCE-26960-5 | Disable Booting from USB Devices in Boot Firmware | Configure the system boot firmware (historically called BIOS on PC systems) to disallow booting from USB drives.

CCE-27498-5

Disable the Automounter

The `autofs` daemon mounts and unmounts filesystems, such as user home directories shared via NFS, on demand. In addition, autofs can be used to handle removable media, and the default configuration provides the cdrom device as `/misc/cd`. However, this method of providing access to removable media is not common, so autofs can almost always be disabled if NFS is not in use. Even if NFS is required, it may be possible to configure filesystem mounts statically by editing `/etc/fstab` rather than relying on the automounter.
The `autofs` service can be disabled with the following command:

    $ sudo systemctl disable autofs.service

CCE-80143-1

Disable Mounting of udf

To configure the system to prevent the `udf` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install udf /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80142-3

Disable Mounting of squashfs

To configure the system to prevent the `squashfs` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install squashfs /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80141-5

Disable Mounting of hfsplus

To configure the system to prevent the `hfsplus` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install hfsplus /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80139-9

Disable Mounting of jffs2

To configure the system to prevent the `jffs2` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install jffs2 /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80140-7

Disable Mounting of hfs

To configure the system to prevent the `hfs` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install hfs /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80137-3

Disable Mounting of cramfs

To configure the system to prevent the `cramfs` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install cramfs /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80138-1

Disable Mounting of freevxfs

To configure the system to prevent the `freevxfs` kernel module from being loaded, add the following line to a file in the directory `/etc/modprobe.d`:

    install freevxfs /bin/true

This effectively prevents usage of this uncommon filesystem.

CCE-80153-0 | Add noexec Option to /dev/shm | The `noexec` mount option can be used to prevent binaries from being executed out of `/dev/shm`. It can be dangerous to allow the execution of binaries from world-writable temporary storage directories such as `/dev/shm`. Add the `noexec` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/dev/shm`.
CCE-80154-8 | Add nosuid Option to /dev/shm | The `nosuid` mount option can be used to prevent execution of setuid programs in `/dev/shm`. The SUID and SGID permissions should not be required in these world-writable directories. Add the `nosuid` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/dev/shm`.
CCE-80149-8 | Add nodev Option to /tmp | The `nodev` mount option can be used to prevent device files from being created in `/tmp`. Legitimate character and block devices should not exist within temporary directories like `/tmp`. Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/tmp`.
CCE-80150-6 | Add noexec Option to /tmp | The `noexec` mount option can be used to prevent binaries from being executed out of `/tmp`. Add the `noexec` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/tmp`.
CCE-81153-9 | Add nosuid Option to /home | The `nosuid` mount option can be used to prevent execution of setuid programs in `/home`. The SUID and SGID permissions should not be required in these user data directories. Add the `nosuid` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/home`.
CCE-80151-4 | Add nosuid Option to /tmp | The `nosuid` mount option can be used to prevent execution of setuid programs in `/tmp`. The SUID and SGID permissions should not be required in these world-writable directories. Add the `nosuid` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/tmp`.
CCE-TBD | Add nodev Option to /var/tmp | The `nodev` mount option can be used to prevent device files from being created in `/var/tmp`. Legitimate character and block devices should not exist within temporary directories like `/var/tmp`. Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/var/tmp`.

CCE-80148-0

Add nosuid Option to Removable Media Partitions

The `nosuid` mount option prevents set-user-identifier (SUID) and set-group-identifier (SGID) permissions from taking effect. These permissions allow users to execute binaries with the same permissions as the owner and group of the file respectively. Users should not be allowed to introduce SUID and SGID files into the system via partitions mounted from removeable media. Add the `nosuid` option to the fourth column of `/etc/fstab` for the line which controls mounting of any removable media partitions.

CCE-80145-6

Add nodev Option to Non-Root Local Partitions

The `nodev` mount option prevents files from being interpreted as character or block devices. Legitimate character and block devices should exist only in the `/dev` directory on the root partition or within chroot jails built for system services. Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of any non-root local partitions.

CCE-80146-4

Add nodev Option to Removable Media Partitions

The `nodev` mount option prevents files from being interpreted as character or block devices. Legitimate character and block devices should exist only in the `/dev` directory on the root partition or within chroot jails built for system services. Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of any removable media partitions.

CCE-80147-2

Add noexec Option to Removable Media Partitions

The `noexec` mount option prevents the direct execution of binaries on the mounted filesystem. Preventing the direct execution of binaries from removable media (such as a USB key) provides a defense against malicious software that may be present on such untrusted media. Add the `noexec` option to the fourth column of `/etc/fstab` for the line which controls mounting of any removable media partitions.

CCE-TBD | Add nodev Option to /home | The `nodev` mount option can be used to prevent device files from being created in `/home`. Legitimate character and block devices should exist only in the `/dev` directory on the root partition or within chroot jails built for system services. Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/home`.

CCE-80155-5

Bind Mount /var/tmp To /tmp

The `/var/tmp` directory is a world-writable directory. Bind-mount it to `/tmp` in order to consolidate temporary storage into one location protected by the same techniques as `/tmp`. To do so, edit `/etc/fstab` and add the following line:

    /tmp     /var/tmp     none     rw,nodev,noexec,nosuid,bind     0 0

See the `mount(8)` man page for further explanation of bind mounting.

CCE-TBD | Add noexec Option to /var/tmp | The `noexec` mount option can be used to prevent binaries from being executed out of `/var/tmp`. Add the `noexec` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/var/tmp`.
CCE-TBD | Add nosuid Option to /var/tmp | The `nosuid` mount option can be used to prevent execution of setuid programs in `/var/tmp`. The SUID and SGID permissions should not be required in these world-writable directories. Add the `nosuid` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/var/tmp`.
CCE-80152-2 | Add nodev Option to /dev/shm | The `nodev` mount option can be used to prevent creation of device files in `/dev/shm`. Legitimate character and block devices should not exist within temporary directories like `/dev/shm`. Add the `nodev` option to the fourth column of `/etc/fstab` for the line which controls mounting of `/dev/shm`.

CCE-27068-6

Set Daemon Umask

The file `/etc/init.d/functions` includes initialization parameters for most or all daemons started at boot time. The default umask of 022 prevents creation of group- or world-writable files. To set the default umask for daemons, edit the following line, inserting 022 or 027 for UMASK appropriately:

    umask

Setting the umask to too restrictive a setting can cause serious errors at runtime. Many daemons on the system already individually restrict themselves to a umask of 077 in their own init scripts.

CCE-27116-3

Install PAE Kernel on Supported 32-bit x86 Systems

Systems that are using the 64-bit x86 kernel package do not need to install the kernel-PAE package because the 64-bit x86 kernel already includes this support. However, if the system is 32-bit and also supports the PAE and NX features as determined in the previous section, the kernel-PAE package should be installed to enable XD or NX support:

    $ sudo yum install kernel-PAE

The installation process should also have configured the bootloader to load the new kernel at boot. Verify this at reboot and modify `/etc/default/grub` if necessary.

CCE-27099-1 | Enable NX or XD Support in the BIOS | Reboot the system and enter the BIOS or Setup configuration menu. Navigate the BIOS configuration menu and make sure that the option is enabled. The setting may be located under a Security section. Look for Execute Disable (XD) on Intel-based systems and No Execute (NX) on AMD-based systems.

CCE-26900-1

Disable Core Dumps for SUID programs

To set the runtime status of the `fs.suid_dumpable` kernel parameter, run the following command:

    $ sudo sysctl -w fs.suid_dumpable=0

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    fs.suid_dumpable = 0

CCE-80169-6

Disable Core Dumps for All Users

To disable core dumps for all users, add the following line to `/etc/security/limits.conf`:

    *     hard   core    0

CCE-27211-2 | Enable ExecShield | By default on Red Hat Enterprise Linux 7 64-bit systems, ExecShield is enabled and can only be disabled if the hardware does not support ExecShield or is disabled in `/etc/default/grub`. For Red Hat Enterprise Linux 7 32-bit systems, `sysctl` can be used to enable ExecShield.

CCE-27127-0

Enable Randomized Layout of Virtual Address Space

To set the runtime status of the `kernel.randomize_va_space` kernel parameter, run the following command:

    $ sudo sysctl -w kernel.randomize_va_space=2

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    kernel.randomize_va_space = 2

CCE-27050-4

Restrict Access to Kernel Message Buffer

To set the runtime status of the `kernel.dmesg_restrict` kernel parameter, run the following command:

    $ sudo sysctl -w kernel.dmesg_restrict=1

If this is not the system's default value, add the following line to `/etc/sysctl.conf`:

    kernel.dmesg_restrict = 1

CCE-27331-8

Configure auditd flush priority

The `auditd` service can be configured to synchronously write audit event data to disk. Add or correct the following line in `/etc/audit/auditd.conf` to ensure that audit event data is fully synchronized with the log files on the disk:

    flush =

CCE-80540-8

Encrypt Audit Records Sent With audispd Plugin

Configure the operating system to encrypt the transfer of off-loaded audit records onto a different system or media from the system being audited. Uncomment the `enable_krb5` option in

    /etc/audisp/audisp-remote.conf

, and set it with the following line:

    enable_krb5 = yes

CCE-80541-6

Configure audispd Plugin To Send Logs To Remote Server

Configure the audispd plugin to off-load audit records onto a different system or media from the system being audited. Set the `remote_server` option in

    /etc/audisp/audisp-remote.conf

with an IP address or hostname of the system that the audispd plugin should send audit records to. For example replacing REMOTE_SYSTEM with an IP address or hostname:

    remote_server = REMOTE_SYSTEM

CCE-27341-7

Configure auditd to use audispd's syslog plugin

To configure the `auditd` service to use the `syslog` plug-in of the `audispd` audit event multiplexor, set the `active` line in `/etc/audisp/plugins.d/syslog.conf` to `yes`. Restart the `auditd` service:

    $ sudo service auditd restart

CCE-27319-3

Configure auditd Max Log File Size

Determine the amount of audit data (in megabytes) which should be retained in each log file. Edit the file `/etc/audit/auditd.conf`. Add or modify the following line, substituting the correct value of for STOREMB:

    max_log_file = STOREMB

Set the value to `6` (MB) or higher for general-purpose systems. Larger values, of course, support retention of even more audit data.

CCE-80537-4

Configure auditd space_left on Low Disk Space

The `auditd` service can be configured to take an action when disk space is running low but prior to running out of space completely. Edit the file `/etc/audit/auditd.conf`. Add or modify the following line, substituting SIZE_in_MB appropriately:

    space_left = SIZE_in_MB

Set this value to the appropriate size in Megabytes cause the system to notify the user of an issue.

CCE-27394-6

Configure auditd mail_acct Action on Low Disk Space

The `auditd` service can be configured to send email to a designated account in certain situations. Add or correct the following line in `/etc/audit/auditd.conf` to ensure that administrators are notified via email for those situations:

    action_mail_acct =

CCE-80538-2

Configure audispd's Plugin network_failure_action On Network Failure

Configure the action the operating system takes if there is an error sending audit records to a remote system. Edit the file `/etc/audisp/audisp-remote.conf`. Add or modify the following line, substituting ACTION appropriately:

    network_failure_action = ACTION

Set this value to `single` to cause the system to switch to single user mode for corrective action. Acceptable values also include `syslog` and `halt`. For certain systems, the need for availability outweighs the need to log all actions, and a different setting should be determined.

CCE-27370-6

Configure auditd admin_space_left Action on Low Disk Space

The `auditd` service can be configured to take an action when disk space is running low but prior to running out of space completely. Edit the file `/etc/audit/auditd.conf`. Add or modify the following line, substituting ACTION appropriately:

    admin_space_left_action = ACTION

Set this value to `single` to cause the system to switch to single user mode for corrective action. Acceptable values also include `suspend` and `halt`. For certain systems, the need for availability outweighs the need to log all actions, and a different setting should be determined. Details regarding all possible values for ACTION are described in the `auditd.conf` man page.

CCE-80539-0

Configure audispd's Plugin disk_full_action When Disk Is Full

Configure the action the operating system takes if the disk the audit records are written to becomes full. Edit the file `/etc/audisp/audisp-remote.conf`. Add or modify the following line, substituting ACTION appropriately:

    disk_full_action = ACTION

Set this value to `single` to cause the system to switch to single user mode for corrective action. Acceptable values also include `syslog` and `halt`. For certain systems, the need for availability outweighs the need to log all actions, and a different setting should be determined.

CCE-27375-5

Configure auditd space_left Action on Low Disk Space

The `auditd` service can be configured to take an action when disk space starts to run low. Edit the file `/etc/audit/auditd.conf`. Modify the following line, substituting ACTION appropriately:

    space_left_action = ACTION

Possible values for ACTION are described in the `auditd.conf` man page. These include:

- `syslog`
- `email`
- `exec`
- `suspend`
- `single`
- `halt`

Set this to `email` (instead of the default, which is `suspend`) as it is more likely to get prompt attention. Acceptable values also include `suspend`, `single`, and `halt`.

CCE-27348-2

Configure auditd Number of Logs Retained

Determine how many log files `auditd` should retain when it rotates logs. Edit the file `/etc/audit/auditd.conf`. Add or modify the following line, substituting NUMLOGS with the correct value of :

    num_logs = NUMLOGS

Set the value to 5 for general-purpose systems. Note that values less than 2 result in no log rotation.

CCE-27231-0

Configure auditd max_log_file_action Upon Reaching Maximum Log Size

The default action to take when the logs reach their maximum size is to rotate the log files, discarding the oldest one. To configure the action taken by `auditd`, add or correct the line in `/etc/audit/auditd.conf`:

    max_log_file_action = ACTION

Possible values for ACTION are described in the `auditd.conf` man page. These include:

- `syslog`
- `suspend`
- `rotate`
- `keep_logs`

Set the `ACTION` to `rotate` to ensure log rotation occurs. This is the default. The setting is case-insensitive.

CCE-80416-1

Ensure auditd Collects Information on Kernel Module Unloading - rmmod

To capture invocation of rmmod, utility used to remove modules from kernel, add the following line:

    -w /usr/sbin/rmmod -p x -k modules

Place to add the line depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the line to file `/etc/audit/audit.rules`.

CCE-27129-6

Ensure auditd Collects Information on Kernel Module Loading and Unloading

To capture kernel module loading and unloading events, use following lines, setting ARCH to either b32 for 32-bit system, or having two lines for both b32 and b64 in case your system is 64-bit:

    -w /usr/sbin/insmod -p x -k modules
    -w /usr/sbin/rmmod -p x -k modules
    -w /usr/sbin/modprobe -p x -k modules
    -a always,exit -F arch=ARCH -S init_module,delete_module -F key=modules

Place to add the lines depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the lines to file `/etc/audit/audit.rules`.

CCE-80415-3

Ensure auditd Collects Information on Kernel Module Unloading - delete_module

To capture kernel module unloading events, use following line, setting ARCH to either b32 for 32-bit system, or having two lines for both b32 and b64 in case your system is 64-bit:

    -a always,exit -F arch=ARCH -S delete_module -F key=modules

Place to add the line depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the line to file `/etc/audit/audit.rules`.

CCE-80446-8

Ensure auditd Collects Information on Kernel Module Loading - insmod

To capture invocation of insmod, utility used to insert modules into kernel, use the following line:

    -w /usr/sbin/insmod -p x -k modules

Place to add the line depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the line to file `/etc/audit/audit.rules`.

CCE-80547-3

Ensure auditd Collects Information on Kernel Module Loading and Unloading - finit_module

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d` to capture kernel module loading and unloading events, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S finit_module -F key=modules

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file in order to capture kernel module loading and unloading events, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S finit_module -F key=modules

CCE-80417-9

Ensure auditd Collects Information on Kernel Module Loading and Unloading - modprobe

To capture invocation of modprobe, utility used to insert / remove modules from kernel, add the following line:

    -w /usr/sbin/modprobe -p x -k modules

Place to add the line depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the line to file `/etc/audit/audit.rules`.

CCE-RHEL7-CCE-TBD

Ensure auditd Collects Information on Kernel Module Loading - create_module

To capture kernel module loading events, use following line, setting ARCH to either b32 for 32-bit system, or having two lines for both b32 and b64 in case your system is 64-bit:

    -a always,exit -F arch=ARCH -S create_module -F key=modules

Place to add the line depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the line to file `/etc/audit/audit.rules`.

CCE-80414-6

Ensure auditd Collects Information on Kernel Module Loading - init_module

To capture kernel module loading events, use following line, setting ARCH to either b32 for 32-bit system, or having two lines for both b32 and b64 in case your system is 64-bit:

    -a always,exit -F arch=ARCH -S init_module -F key=modules

Place to add the line depends on a way `auditd` daemon is configured. If it is configured to use the `augenrules` program (the default), add the line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`. If the `auditd` daemon is configured to use the `auditctl` utility, add the line to file `/etc/audit/audit.rules`.

CCE-27204-7

Record Attempts to Alter Logon and Logout Events

The audit system already collects login information for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d` in order to watch for attempted manual edits of files involved in storing logon events:

    -w /var/log/tallylog -p wa -k logins
    -w /var/run/faillock/ -p wa -k logins
    -w /var/log/lastlog -p wa -k logins

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file in order to watch for unattempted manual edits of files involved in storing logon events:

    -w /var/log/tallylog -p wa -k logins
    -w /var/run/faillock/ -p wa -k logins
    -w /var/log/lastlog -p wa -k logins

CCE-80384-1

Record Attempts to Alter Logon and Logout Events - lastlog

The audit system already collects login information for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d` in order to watch for attempted manual edits of files involved in storing logon events:

    -w /var/log/lastlog -p wa -k logins

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file in order to watch for unattempted manual edits of files involved in storing logon events:

    -w /var/log/lastlog -p wa -k logins

CCE-80383-3

Record Attempts to Alter Logon and Logout Events - faillock

The audit system already collects login information for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d` in order to watch for attempted manual edits of files involved in storing logon events:

    -w /var/run/faillock/ -p wa -k logins

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file in order to watch for unattempted manual edits of files involved in storing logon events:

    -w /var/run/faillock/ -p wa -k logins

CCE-80382-5

Record Attempts to Alter Logon and Logout Events - tallylog

The audit system already collects login information for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d` in order to watch for attempted manual edits of files involved in storing logon events:

    -w /var/log/tallylog -p wa -k logins

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file in order to watch for unattempted manual edits of files involved in storing logon events:

    -w /var/log/tallylog -p wa -k logins

CCE-27299-7

Record Attempts to Alter Time Through stime

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d` for both 32 bit and 64 bit systems:

    -a always,exit -F arch=b32 -S stime -F key=audit_time_rules

Since the 64 bit version of the "stime" system call is not defined in the audit lookup table, the corresponding "-F arch=b64" form of this rule is not expected to be defined on 64 bit systems (the aforementioned "-F arch=b32" stime rule form itself is sufficient for both 32 bit and 64 bit systems). If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file for both 32 bit and 64 bit systems:

    -a always,exit -F arch=b32 -S stime -F key=audit_time_rules

Since the 64 bit version of the "stime" system call is not defined in the audit lookup table, the corresponding "-F arch=b64" form of this rule is not expected to be defined on 64 bit systems (the aforementioned "-F arch=b32" stime rule form itself is sufficient for both 32 bit and 64 bit systems). The -k option allows for the specification of a key in string form that can be used for better reporting capability through ausearch and aureport. Multiple system calls can be defined on the same line to save space if desired, but is not required. See an example of multiple combined system calls:

    -a always,exit -F arch=b64 -S adjtimex,settimeofday -F key=audit_time_rules

CCE-27216-1

Record attempts to alter time through settimeofday

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S settimeofday -F key=audit_time_rules

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S settimeofday -F key=audit_time_rules

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S settimeofday -F key=audit_time_rules

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S settimeofday -F key=audit_time_rules

The -k option allows for the specification of a key in string form that can be used for better reporting capability through ausearch and aureport. Multiple system calls can be defined on the same line to save space if desired, but is not required. See an example of multiple combined syscalls:

    -a always,exit -F arch=b64 -S adjtimex,settimeofday -F key=audit_time_rules

CCE-27310-2

Record Attempts to Alter the localtime File

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -w /etc/localtime -p wa -k audit_time_rules

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -w /etc/localtime -p wa -k audit_time_rules

The -k option allows for the specification of a key in string form that can be used for better reporting capability through ausearch and aureport and should always be used.

CCE-27219-5

Record Attempts to Alter Time Through clock_settime

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S clock_settime -F a0=0x0 -F key=time-change

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S clock_settime -F a0=0x0 -F key=time-change

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S clock_settime -F a0=0x0 -F key=time-change

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S clock_settime -F a0=0x0 -F key=time-change

The -k option allows for the specification of a key in string form that can be used for better reporting capability through ausearch and aureport. Multiple system calls can be defined on the same line to save space if desired, but is not required. See an example of multiple combined syscalls:

    -a always,exit -F arch=b64 -S adjtimex,settimeofday -F key=audit_time_rules

CCE-27290-6

Record attempts to alter time through adjtimex

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S adjtimex -F key=audit_time_rules

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S adjtimex -F key=audit_time_rules

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S adjtimex -F key=audit_time_rules

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S adjtimex -F key=audit_time_rules

The -k option allows for the specification of a key in string form that can be used for better reporting capability through ausearch and aureport. Multiple system calls can be defined on the same line to save space if desired, but is not required. See an example of multiple combined syscalls:

    -a always,exit -F arch=b64 -S adjtimex,settimeofday -F key=audit_time_rules

CCE-27356-5

Record Events that Modify the System's Discretionary Access Controls - fchown

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S fchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S fchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27213-8

Record Events that Modify the System's Discretionary Access Controls - setxattr

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S setxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S setxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S setxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S setxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27364-9

Record Events that Modify the System's Discretionary Access Controls - chown

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S chown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S chown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S chown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S chown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27280-7

Record Events that Modify the System's Discretionary Access Controls - lsetxattr

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S lsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S lsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S lsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S lsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27083-5

Record Events that Modify the System's Discretionary Access Controls - lchown

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S lchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S lchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S lchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S lchown -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27339-1

Record Events that Modify the System's Discretionary Access Controls - chmod

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S chmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S chmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S chmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S chmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27367-2

Record Events that Modify the System's Discretionary Access Controls - removexattr

At a minimum, the audit system should collect file permission changes for all users and root.
If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S removexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S removexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S removexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S removexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27393-8

Record Events that Modify the System's Discretionary Access Controls - fchmod

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S fchmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S fchmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchmod -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27387-0

Record Events that Modify the System's Discretionary Access Controls - fchownat

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S fchownat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchownat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S fchownat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchownat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27353-2

Record Events that Modify the System's Discretionary Access Controls - fremovexattr

At a minimum, the audit system should collect file permission changes for all users and root.
If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S fremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S fremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27410-0

Record Events that Modify the System's Discretionary Access Controls - lremovexattr

At a minimum, the audit system should collect file permission changes for all users and root.
If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S lremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S lremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S lremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S lremovexattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27389-6

Record Events that Modify the System's Discretionary Access Controls - fsetxattr

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S fsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S fsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fsetxattr -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-27388-8

Record Events that Modify the System's Discretionary Access Controls - fchmodat

At a minimum, the audit system should collect file permission changes for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S fchmodat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchmodat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S fchmodat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

If the system is 64 bit then also add the following line:

    -a always,exit -F arch=b64 -S fchmodat -F auid>=1000 -F auid!=4294967295 -F key=perm_mod

CCE-RHEL7-CCE-TBD

Record Any Attempts to Run setfiles

At a minimum, the audit system should collect any execution attempt of the `setfiles` command for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/setfiles -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F path=/usr/sbin/setfiles -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

CCE-80394-0

Record Any Attempts to Run restorecon

At a minimum, the audit system should collect any execution attempt of the `restorecon` command for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/restorecon -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F path=/usr/sbin/restorecon -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

CCE-80392-4

Record Any Attempts to Run setsebool

At a minimum, the audit system should collect any execution attempt of the `setsebool` command for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/setsebool -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F path=/usr/sbin/setsebool -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

CCE-80391-6

Record Any Attempts to Run semanage

At a minimum, the audit system should collect any execution attempt of the `semanage` command for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/semanage -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F path=/usr/sbin/semanage -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

CCE-80393-2

Record Any Attempts to Run chcon

At a minimum, the audit system should collect any execution attempt of the `chcon` command for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/chcon -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F path=/usr/bin/chcon -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged-priv_change

CCE-80412-0

Ensure auditd Collects File Deletion Events by User - rmdir

At a minimum, the audit system should collect file deletion events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S rmdir -F auid>=1000 -F auid!=4294967295 -F key=delete

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S rmdir -F auid>=1000 -F auid!=4294967295 -F key=delete

CCE-27206-2

Ensure auditd Collects File Deletion Events by User - unlinkat

At a minimum, the audit system should collect file deletion events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S unlinkat -F auid>=1000 -F auid!=4294967295 -F key=delete

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S unlinkat -F auid>=1000 -F auid!=4294967295 -F key=delete

CCE-27206-2

Ensure auditd Collects File Deletion Events by User

At a minimum the audit system should collect file deletion events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S rmdiri,unlink,unlinkat,rename,renameat -F auid>=1000 -F auid!=4294967295 -F key=delete

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S rmdir,unlink,unlinkat,rename -S renameat -F auid>=1000 -F auid!=4294967295 -F key=delete

CCE-27206-2

Ensure auditd Collects File Deletion Events by User - rename

At a minimum, the audit system should collect file deletion events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S rename -F auid>=1000 -F auid!=4294967295 -F key=delete

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S rename -F auid>=1000 -F auid!=4294967295 -F key=delete

CCE-80413-8

Ensure auditd Collects File Deletion Events by User - renameat

At a minimum, the audit system should collect file deletion events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S renameat -F auid>=1000 -F auid!=4294967295 -F key=delete

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S renameat -F auid>=1000 -F auid!=4294967295 -F key=delete

CCE-27206-2

Ensure auditd Collects File Deletion Events by User - unlink

At a minimum, the audit system should collect file deletion events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S unlink -F auid>=1000 -F auid!=4294967295 -F key=delete

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S unlink -F auid>=1000 -F auid!=4294967295 -F key=delete

CCE-80410-4

Ensure auditd Collects Information on the Use of Privileged Commands - crontab

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/crontab -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/crontab -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80395-7

Ensure auditd Collects Information on the Use of Privileged Commands - passwd

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/passwd -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/passwd -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80397-3

Ensure auditd Collects Information on the Use of Privileged Commands - gpasswd

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/gpasswd -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/gpasswd -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80396-5

Ensure auditd Collects Information on the Use of Privileged Commands - unix_chkpwd

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/unix_chkpwd -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/unix_chkpwd -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80407-0

Ensure auditd Collects Information on the Use of Privileged Commands - postqueue

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/postqueue -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/sbin/postqueue -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80399-9

Ensure auditd Collects Information on the Use of Privileged Commands - userhelper

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/userhelper -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/userhelper -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80409-6

Ensure auditd Collects Information on the Use of Privileged Commands - pt_chown

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/libexec/pt_chown -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/libexec/pt_chown -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80408-8

Ensure auditd Collects Information on the Use of Privileged Commands - ssh-keysign

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/libexec/openssh/ssh-keysign -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/libexec/openssh/key-sign -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-27437-3

Ensure auditd Collects Information on the Use of Privileged Commands

At a minimum, the audit system should collect the execution of privileged commands for all users and root. To find the relevant setuid / setgid programs, run the following command for each local partition PART:

    $ sudo find PART -xdev -type f -perm -4000 -o -type f -perm -2000 2>/dev/null

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d` for each setuid / setgid program on the system, replacing the SETUID_PROG_PATH part with the full path of that setuid / setgid program in the list:

    -a always,exit -F path=SETUID_PROG_PATH -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules` for each setuid / setgid program on the system, replacing the SETUID_PROG_PATH part with the full path of that setuid / setgid program in the list:

    -a always,exit -F path=SETUID_PROG_PATH -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80401-3

Ensure auditd Collects Information on the Use of Privileged Commands - sudo

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/sudo -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/sudo -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80400-5

Ensure auditd Collects Information on the Use of Privileged Commands - su

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/su -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/su -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80411-2

Ensure auditd Collects Information on the Use of Privileged Commands - pam_timestamp_check

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/pam_timestamp_check -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/sbin/pam_timestamp_check -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80402-1

Ensure auditd Collects Information on the Use of Privileged Commands - sudoedit

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/sudoedit -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/sudoedit -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80403-9

Ensure auditd Collects Information on the Use of Privileged Commands - newgrp

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/newgrp -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/newgrp -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80398-1

Ensure auditd Collects Information on the Use of Privileged Commands - chage

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/chage -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/chage -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80405-4

Ensure auditd Collects Information on the Use of Privileged Commands - umount

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/umount -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/umount -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80406-2

Ensure auditd Collects Information on the Use of Privileged Commands - postdrop

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/sbin/postdrop -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/sbin/postdrop -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-80404-7

Ensure auditd Collects Information on the Use of Privileged Commands - chsh

At a minimum, the audit system should collect the execution of privileged commands for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add a line of the following form to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F path=/usr/bin/chsh -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add a line of the following form to `/etc/audit/audit.rules`:

    -a always,exit -F path=/usr/bin/chsh -F perm=x -F auid>=1000 -F auid!=4294967295 -F key=privileged

CCE-27347-4

Ensure auditd Collects Unauthorized Access Attempts to Files (unsuccessful)

At a minimum the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S creat,open,openat,open_by_handle_at,truncate,ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80386-6

Record Unauthorized Access Attempts to Files (unsuccessful) - open

At a minimum, the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S open -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S open -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S open -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S open -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S open -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S open -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S open -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S open -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80388-2

Record Unauthorized Access Attempts to Files (unsuccessful) - open_by_handle_at

At a minimum, the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S open_by_handle_at -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S open_by_handle_at -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S open_by_handle_at -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S open_by_handle_at -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S open_by_handle_at,truncate,ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S open_by_handle_at,truncate,ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S open_by_handle_at,truncate,ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S open_by_handle_at,truncate,ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80385-8

Record Unauthorized Access Attempts to Files (unsuccessful) - creat

At a minimum, the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S creat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S creat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S creat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S creat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S creat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S creat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S creat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S creat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80390-8

Record Unauthorized Access Attempts to Files (unsuccessful) - ftruncate

At a minimum, the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S ftruncate -F exiu=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S ftruncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S ftruncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80389-0

Record Unauthorized Access Attempts to Files (unsuccessful) - truncate

At a minimum, the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S truncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S truncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S truncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S truncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S truncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S truncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S truncate -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S truncate -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80387-4

Record Unauthorized Access Attempts to Files (unsuccessful) - openat

At a minimum, the audit system should collect unauthorized file accesses for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -a always,exit -F arch=b32 -S openat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S openat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S openat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S openat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file:

    -a always,exit -F arch=b32 -S openat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b32 -S openat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

If the system is 64 bit then also add the following lines:

    -a always,exit -F arch=b64 -S openat -F exit=-EACCES -F auid>=1000 -F auid!=4294967295 -F key=access
    -a always,exit -F arch=b64 -S openat -F exit=-EPERM -F auid>=1000 -F auid!=4294967295 -F key=access

CCE-80431-0

Record Events that Modify User/Group Information - /etc/shadow

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, in order to capture events that modify account changes:

    -w /etc/shadow -p wa -k audit_rules_usergroup_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, in order to capture events that modify account changes:

    -w /etc/shadow -p wa -k audit_rules_usergroup_modification

CCE-27301-1

Record Attempts to Alter Process and Session Initiation Information

The audit system already collects process information for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d` in order to watch for attempted manual edits of files involved in storing such process information:

    -w /var/run/utmp -p wa -k session
    -w /var/log/btmp -p wa -k session
    -w /var/log/wtmp -p wa -k session

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file in order to watch for attempted manual edits of files involved in storing such process information:

    -w /var/run/utmp -p wa -k session
    -w /var/log/btmp -p wa -k session
    -w /var/log/wtmp -p wa -k session

CCE-80381-7

Shutdown System When Auditing Failures Occur

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -f 2

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to the top of the `/etc/audit/audit.rules` file:

    -f 2

CCE-27461-3

Ensure auditd Collects System Administrator Actions

At a minimum, the audit system should collect administrator actions for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -w /etc/sudoers -p wa -k actions
    -w /etc/sudoers.d/ -p wa -k actions

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -w /etc/sudoers -p wa -k actions
    -w /etc/sudoers.d/ -p wa -k actions

CCE-27076-9

Record Events that Modify the System's Network Environment

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S sethostname,setdomainname -F key=audit_rules_networkconfig_modification
    -w /etc/issue -p wa -k audit_rules_networkconfig_modification
    -w /etc/issue.net -p wa -k audit_rules_networkconfig_modification
    -w /etc/hosts -p wa -k audit_rules_networkconfig_modification
    -w /etc/sysconfig/network -p wa -k audit_rules_networkconfig_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S sethostname,setdomainname -F key=audit_rules_networkconfig_modification
    -w /etc/issue -p wa -k audit_rules_networkconfig_modification
    -w /etc/issue.net -p wa -k audit_rules_networkconfig_modification
    -w /etc/hosts -p wa -k audit_rules_networkconfig_modification
    -w /etc/sysconfig/network -p wa -k audit_rules_networkconfig_modification

CCE-27192-4

Record Events that Modify User/Group Information

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, in order to capture events that modify account changes:

    -w /etc/group -p wa -k audit_rules_usergroup_modification
    -w /etc/passwd -p wa -k audit_rules_usergroup_modification
    -w /etc/gshadow -p wa -k audit_rules_usergroup_modification
    -w /etc/shadow -p wa -k audit_rules_usergroup_modification
    -w /etc/security/opasswd -p wa -k audit_rules_usergroup_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, in order to capture events that modify account changes:

    -w /etc/group -p wa -k audit_rules_usergroup_modification
    -w /etc/passwd -p wa -k audit_rules_usergroup_modification
    -w /etc/gshadow -p wa -k audit_rules_usergroup_modification
    -w /etc/shadow -p wa -k audit_rules_usergroup_modification
    -w /etc/security/opasswd -p wa -k audit_rules_usergroup_modification

CCE-80432-8

Record Events that Modify User/Group Information - /etc/gshadow

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, in order to capture events that modify account changes:

    -w /etc/gshadow -p wa -k audit_rules_usergroup_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, in order to capture events that modify account changes:

    -w /etc/gshadow -p wa -k audit_rules_usergroup_modification

CCE-80430-2

Record Events that Modify User/Group Information - /etc/security/opasswd

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, in order to capture events that modify account changes:

    -w /etc/security/opasswd -p wa -k audit_rules_usergroup_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, in order to capture events that modify account changes:

    -w /etc/security/opasswd -p wa -k audit_rules_usergroup_modification

CCE-27205-4

System Audit Logs Must Have Mode 0640 or Less Permissive

If `log_group` in `/etc/audit/auditd.conf` is set to a group other than the `root` group account, change the mode of the audit log files with the following command:

    $ sudo chmod 0640 audit_file

Otherwise, change the mode of the audit log files with the following command:

    $ sudo chmod 0600 audit_file

CCE-27447-2

Ensure auditd Collects Information on Exporting to Media (successful)

At a minimum, the audit system should collect media exportation events for all users and root. If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S mount -F auid>=1000 -F auid!=4294967295 -F key=export

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file, setting ARCH to either b32 or b64 as appropriate for your system:

    -a always,exit -F arch=ARCH -S mount -F auid>=1000 -F auid!=4294967295 -F key=export

CCE-27097-5

Make the auditd Configuration Immutable

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d` in order to make the auditd configuration immutable:

    -e 2

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file in order to make the auditd configuration immutable:

    -e 2

With this setting, a reboot will be required to change any audit rules.

CCE-80125-8

System Audit Logs Must Be Owned By Root

All audit logs must be owned by root user and group. By default, the path for audit log is

    /var/log/audit/

. To properly set the owner of `/var/log/audit`, run the command:

    $ sudo chown root /var/log/audit

To properly set the owner of `/var/log/audit/*`, run the command:

    $ sudo chown root /var/log/audit/*

CCE-80435-1

Record Events that Modify User/Group Information - /etc/passwd

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, in order to capture events that modify account changes:

    -w /etc/passwd -p wa -k audit_rules_usergroup_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, in order to capture events that modify account changes:

    -w /etc/passwd -p wa -k audit_rules_usergroup_modification

CCE-27168-4

Record Events that Modify the System's Mandatory Access Controls

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following line to a file with suffix `.rules` in the directory `/etc/audit/rules.d`:

    -w /etc/selinux/ -p wa -k MAC-policy

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following line to `/etc/audit/audit.rules` file:

    -w /etc/selinux/ -p wa -k MAC-policy

CCE-80433-6

Record Events that Modify User/Group Information - /etc/group

If the `auditd` daemon is configured to use the `augenrules` program to read audit rules during daemon startup (the default), add the following lines to a file with suffix `.rules` in the directory `/etc/audit/rules.d`, in order to capture events that modify account changes:

    -w /etc/group -p wa -k audit_rules_usergroup_modification

If the `auditd` daemon is configured to use the `auditctl` utility to read audit rules during daemon startup, add the following lines to `/etc/audit/audit.rules` file, in order to capture events that modify account changes:

    -w /etc/group -p wa -k audit_rules_usergroup_modification

CCE-27212-0

Enable Auditing for Processes Which Start Prior to the Audit Daemon

To ensure all processes can be audited, even those which start prior to the audit daemon, add the argument `audit=1` to the default GRUB 2 command line for the Linux operating system in `/etc/default/grub`, in the manner below:

    GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=VolGroup/LogVol06 rd.lvm.lv=VolGroup/lv_swap rhgb quiet rd.shell=0 audit=1"

CCE-27407-6

Enable auditd Service

The `auditd` service is an essential userspace component of the Linux Auditing System, as it is responsible for writing audit records to disk. The `auditd` service can be enabled with the following command:

    $ sudo systemctl enable auditd.service

CCE-80544-0

Ensure Users Cannot Change GNOME3 Session Idle Settings

If not already configured, ensure that users cannot change GNOME3 session idle settings by adding `/org/gnome/desktop/session/idle-delay` to `/etc/dconf/db/local.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/desktop/session/idle-delay

After the settings have been set, run `dconf update`.

CCE-80370-0

Set GNOME3 Screensaver Lock Delay After Activation Period

To activate the locking delay of the screensaver in the GNOME3 desktop when the screensaver is activated, add or set `lock-delay` to `uint32` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/screensaver]
    lock-delay=uint32

Once the setting has been added, add a lock to `/etc/dconf/db/local.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/desktop/screensaver/lock-delay

After the settings have been set, run `dconf update`.

CCE-80114-2

Disable Full User Name on Splash Shield

By default when the screen is locked, the splash shield will show the user's full name. This should be disabled to prevent casual observers from seeing who has access to the system. This can be disabled by adding or setting `show-full-name-in-top-bar` to `false` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/screensaver]
    show-full-name-in-top-bar=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. For example:

    /org/gnome/desktop/screensaver/show-full-name-in-top-bar

After the settings have been set, run `dconf update`.

CCE-80371-8

Ensure Users Cannot Change GNOME3 Screensaver Settings

If not already configured, ensure that users cannot change GNOME3 screensaver lock settings by adding `/org/gnome/desktop/screensaver/lock-delay` to `/etc/dconf/db/local.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/desktop/screensaver/lock-delay

After the settings have been set, run `dconf update`.

CCE-80111-8

Enable GNOME3 Screensaver Idle Activation

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:

    [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. For example:

    /org/gnome/desktop/screensaver/idle-activation-enabled

After the settings have been set, run `dconf update`.

CCE-80113-4

Implement Blank Screensaver

To set the screensaver mode in the GNOME3 desktop to a blank screen, add or set `picture-uri` to `string ''` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/screensaver]
    picture-uri=string ''

Once the settings have been added, add a lock to `/etc/dconf/db/local.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/desktop/screensaver/picture-uri

After the settings have been set, run `dconf update`.

CCE-80110-0

Set GNOME3 Screensaver Inactivity Timeout

The idle time-out value for inactivity in the GNOME3 desktop is configured via the `idle-delay` setting must be set under an appropriate configuration file(s) in the `/etc/dconf/db/local.d` directory and locked in `/etc/dconf/db/local.d/locks` directory to prevent user modification.
For example, to configure the system for a 15 minute delay, add the following to `/etc/dconf/db/local.d/00-security-settings`:

    [org/gnome/desktop/session]
    idle-delay='uint32 900'

Once the setting has been added, add a lock to `/etc/dconf/db/local.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/desktop/session/idle-delay

After the settings have been set, run `dconf update`.

CCE-80563-0

Ensure Users Cannot Change GNOME3 Screensaver Lock After Idle Period

If not already configured, ensure that users cannot change GNOME3 screensaver lock settings by adding

    /org/gnome/desktop/screensaver/lock-enabled

to `/etc/dconf/db/local.d/00-security-settings`. For example:

    /org/gnome/desktop/screensaver/lock-enabled

After the settings have been set, run `dconf update`.

CCE-80564-8

Ensure Users Cannot Change GNOME3 Screensaver Idle Activation

If not already configured, ensure that users cannot change GNOME3 screensaver lock settings by adding

    /org/gnome/desktop/screensaver/idle-activation-enabled

to `/etc/dconf/db/local.d/00-security-settings`. For example:

    /org/gnome/desktop/screensaver/idle-activation-enabled

After the settings have been set, run `dconf update`.

CCE-80112-6

Enable GNOME3 Screensaver Lock After Idle Period

To activate locking of the screensaver in the GNOME3 desktop when it is activated, add or set `lock-enabled` to `true` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/screensaver]
    lock-enabled=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. For example:

    /org/gnome/desktop/screensaver/lock-enabled

After the settings have been set, run `dconf update`.

CCE-80123-3

Disable All GNOME3 Thumbnailers

The system's default desktop environment, GNOME3, uses a number of different thumbnailer programs to generate thumbnails for any new or modified content in an opened folder. To disable the execution of these thumbnail applications, add or set `disable-all` to `true` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/thumbnailers]
    disable-all=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. For example:

    /org/gnome/desktop/thumbnailers/disable-all

After the settings have been set, run `dconf update`. This effectively prevents an attacker from gaining access to a system through a flaw in GNOME3's Nautilus thumbnail creators.

CCE-80122-5

Disable GNOME3 Automounting

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 and autorun within GNOME3, add or set `automount` to `false`, `automount-open` to `false`, and `autorun-never` to `true` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/media-handling]
    automount=false
    automount-open=false
    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. For example:

    /org/gnome/desktop/media-handling/automount
    /org/gnome/desktop/media-handling/automount-open
    /org/gnome/desktop/media-handling/autorun-never

After the settings have been set, run `dconf update`.

CCE-80117-5

Disable Geolocation in GNOME3

`GNOME` allows the clock and applications to track and access location information. This setting should be disabled as applications should not track system location. To configure the system to disable location tracking, add or set `enabled` to `false` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/system/location]
    enabled=false

To configure the clock to disable location tracking, add or set `geolocation` to `false` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/clocks]
    geolocation=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. For example:

    /org/gnome/system/location/enabled
    /org/gnome/clocks/geolocation

After the settings have been set, run `dconf update`.

CCE-80124-1

Disable Ctrl-Alt-Del Reboot Key Sequence in GNOME3

By default, `GNOME` will reboot the system if the `Ctrl-Alt-Del` key sequence is pressed.
To configure the system to ignore the `Ctrl-Alt-Del` key sequence from the Graphical User Interface (GUI) instead of rebooting the system, add or set `logout` to `string ''` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/settings-daemon/plugins/media-keys]
    logout=string ''

Once the settings have been added, add a lock to `/etc/dconf/db/local.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/settings-daemon/plugins/media-keys/logout

After the settings have been set, run `dconf update`.

CCE-80116-7

Disable Power Settings in GNOME3

By default, `GNOME` enables a power profile designed for mobile devices with battery usage. While useful for mobile devices, this setting should be disabled for all other systems. To configure the system to disable the power setting, add or set `active` to `false` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/settings-daemon/plugins/power]
    active=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. For example:

    /org/gnome/settings-daemon/plugins/power

After the settings have been set, run `dconf update`.

CCE-80115-9

Disable User Administration in GNOME3

By default, `GNOME` will allow all users to have some administratrion capability. This should be disabled so that non-administrative users are not making configuration changes. To configure the system to disable user administration capability in the Graphical User Interface (GUI), add or set `user-administration-disabled` to `true` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/desktop/lockdown]
    user-administration-disabled=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. For example:

    /org/gnome/desktop/lockdown/user-administration-disabled

After the settings have been set, run `dconf update`.

CCE-80108-4

Enable the GNOME3 Login Smartcard Authentication

In the default graphical environment, smart card authentication can be enabled on the login screen by setting `enable-smartcard-authentication` to `true`.
To enable, add or edit `enable-smartcard-authentication` to `/etc/dconf/db/gdm.d/00-security-settings`. For example:

    [org/gnome/login-screen]
    enable-smartcard-authentication=true

Once the setting has been added, add a lock to `/etc/dconf/db/gdm.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/login-screen/enable-smartcard-authentication

After the settings have been set, run `dconf update`.

CCE-80107-6

Disable the GNOME3 Login Restart and Shutdown Buttons

In the default graphical environment, users logging directly into the system are greeted with a login screen that allows any user, known or unknown, the ability the ability to shutdown or restart the system. This functionality should be disabled by setting `disable-restart-buttons` to `true`.
To disable, add or edit `disable-restart-buttons` to `/etc/dconf/db/gdm.d/00-security-settings`. For example:

    [org/gnome/login-screen]
    disable-restart-buttons=true

Once the setting has been added, add a lock to `/etc/dconf/db/gdm.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/login-screen/disable-restart-buttons

After the settings have been set, run `dconf update`.

CCE-80104-3

Disable GDM Automatic Login

The GNOME Display Manager (GDM) can allow users to automatically login without user interaction or credentials. User should always be required to authenticate themselves to the system that they are authorized to use. To disable user ability to automatically login to the system, set the `AutomaticLoginEnable` to `false` in the `[daemon]` section in `/etc/gdm/custom.conf`. For example:

    [daemon]
    AutomaticLoginEnable=false

CCE-80109-2

Set the GNOME3 Login Number of Failures

In the default graphical environment, the GNOME3 login screen and be configured to restart the authentication process after a configured number of attempts. This can be configured by setting `allowed-failures` to `3` or less.
To enable, add or edit `allowed-failures` to `/etc/dconf/db/gdm.d/00-security-settings`. For example:

    [org/gnome/login-screen]
    allowed-failures=3

Once the setting has been added, add a lock to `/etc/dconf/db/gdm.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/login-screen/allowed-failures

After the settings have been set, run `dconf update`.

CCE-80106-8

Disable the GNOME3 Login User List

In the default graphical environment, users logging directly into the system are greeted with a login screen that displays all known users. This functionality should be disabled by setting `disable-user-list` to `true`.
To disable, add or edit `disable-user-list` to `/etc/dconf/db/gdm.d/00-security-settings`. For example:

    [org/gnome/login-screen]
    disable-user-list=true

Once the setting has been added, add a lock to `/etc/dconf/db/gdm.d/locks/00-security-settings-lock` to prevent user modification. For example:

    /org/gnome/login-screen/disable-user-list

After the settings have been set, run `dconf update`.

CCE-80105-0

Disable GDM Guest Login

The GNOME Display Manager (GDM) can allow users to login without credentials which can be useful for public kiosk scenarios. Allowing users to login without credentials or "guest" account access has inherent security risks and should be disabled. To do disable timed logins or guest account access, set the `TimedLoginEnable` to `false` in the `[daemon]` section in `/etc/gdm/custom.conf`. For example:

    [daemon]
    TimedLoginEnable=false

CCE-80118-3

Disable WIFI Network Connection Creation in GNOME3

`GNOME` allows users to create ad-hoc wireless connections through the `NetworkManager` applet. Wireless connections should be disabled by adding or setting `disable-wifi-create` to `true` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/nm-applet]
    disable-wifi-create=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. For example:

    /org/gnome/nm-applet/disable-wifi-create

After the settings have been set, run `dconf update`.

CCE-80119-1

Disable WIFI Network Notification in GNOME3

By default, `GNOME` disables WIFI notification. This should be permanently set so that users do not connect to a wireless network when the system finds one. While useful for mobile devices, this setting should be disabled for all other systems. To configure the system to disable the WIFI notication, add or set `suppress-wireless-networks-available` to `true` in `/etc/dconf/db/local.d/00-security-settings`. For example:

    [org/gnome/nm-applet]
    suppress-wireless-networks-available=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. For example:

    /org/gnome/nm-applet/suppress-wireless-networks-available

After the settings have been set, run `dconf update`.

CCE-80121-7

Require Encryption for Remote Access in GNOME3

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:

    [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. For example:

    /org/gnome/Vino/require-encryption

After the settings have been set, run `dconf update`.

CCE-80120-9

Require Credential Prompting for Remote Access in GNOME3

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:

    [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. For example:

    /org/gnome/Vino/authentication-methods

After the settings have been set, run `dconf update`.

CCE-27446-4

Configure GNOME3 DConf User Profile

By default, DConf provides a standard user profile. This profile contains a list of DConf configuration databases. The user profile and database always take the highest priority. As such the DConf User profile should always exist and be configured correctly.
To make sure that the user profile is configured correctly, the `/etc/dconf/profile/user` should be set as follows:

    user-db:user
    system-db:local
    system-db:site
    system-db:distro

CCE-80350-2 | Ensure Users Re-Authenticate for Privilege Escalation - sudo !authenticate | The sudo `!authenticate` option, when specified, allows a user to execute commands using sudo without having to authenticate. This should be disabled by making sure that the `!authenticate` option does not exist in `/etc/sudoers` configuration file or any sudo configuration snippets in `/etc/sudoers.d/`.
CCE-80351-0 | Ensure Users Re-Authenticate for Privilege Escalation - sudo NOPASSWD | The sudo `NOPASSWD` tag, when specified, allows a user to execute commands using sudo without having to authenticate. This should be disabled by making sure that the `NOPASSWD` tag does not exist in `/etc/sudoers` configuration file or any sudo configuration snippets in `/etc/sudoers.d/`.
CCE-80349-4 | The Installed Operating System Is Vendor Supported and Certified | The installed operating system must be maintained and certified by a vendor. Red Hat Enterprise Linux is supported by Red Hat, Inc. As the Red Hat Enterprise Linux vendor, Red Hat, Inc. is responsible for providing security patches as well as meeting and maintaining goverment certifications and standards.

CCE-80358-5

Install the dracut-fips Package

To enable FIPS, the system requires that the `dracut-fips` package be installed. The `dracut-fips` package can be installed with the following command:

    $ sudo yum install dracut-fips

CCE-80359-3

Enable FIPS Mode in GRUB2

To ensure FIPS mode is enabled, rebuild `initramfs` by running the following command:

    dracut -f

After the `dracut` command has been run, add the argument `fips=1` to the default GRUB 2 command line for the Linux operating system in `/etc/default/grub`, in the manner below:

    GRUB_CMDLINE_LINUX="crashkernel=auto rd.lvm.lv=VolGroup/LogVol06 rd.lvm.lv=VolGroup/lv_swap rhgb quiet rd.shell=0 fips=1"

Finally, rebuild the `grub.cfg` file by using the

    grub2-mkconfig -o

command as follows:

- On BIOS-based machines, issue the following command as `root`:

      ~]# grub2-mkconfig -o /boot/grub2/grub.cfg

- On UEFI-based machines, issue the following command as `root`:

      ~]# grub2-mkconfig -o /boot/efi/EFI/redhat/grub.cfg

CCE-80369-2 | Install the Policy Auditor (PA) Module | Install the Policy Auditor (PA) Module.
CCE-80126-6 | Install the Asset Configuration Compliance Module (ACCM) | Install the Asset Configuration Compliance Module (ACCM).
CCE-80368-4 | Install the Host Intrusion Prevention System (HIPS) Module | Install the McAfee Host Intrusion Prevention System (HIPS) Module if it is absolutely necessary. If SELinux is enabled, do not install or enable this module.

CCE-80128-2

Enable nails Service

The `nails` service is used to run McAfee VirusScan Enterprise for Linux and McAfee Host-based Security System (HBSS) services. The `nails` service can be enabled with the following command:

    $ sudo systemctl enable nails.service

CCE-80127-4 | Install McAfee Virus Scanning Software | Install McAfee VirusScan Enterprise for Linux antivirus software which is provided for DoD systems and uses signatures to search for the presence of viruses on the filesystem.
CCE-80129-0 | Virus Scanning Software Definitions Are Updated | Ensure virus definition files are no older than 7 days or their last release.
CCE-80367-6 | Install the McAfee Runtime Libraries and Linux Agent | Install the McAfee Runtime Libraries (MFErt) and Linux Agent (MFEcma).

CCE-27140-3

Install Virus Scanning Software

Install virus scanning software, which uses signatures to search for the presence of viruses on the filesystem. Ensure virus definition files are no older than 7 days, or their last release. Configure the virus scanning software to perform scans dynamically on all accessed files. If this is not possible, configure the system to scan all altered files on the system on a daily basis. If the system processes inbound SMTP mail, configure the virus scanner to scan all received mail.

CCE-26818-5 | Install Intrusion Detection Software | The base Red Hat platform already includes a sophisticated auditing system that can detect intruder activity, as well as SELinux, which provides host-based intrusion prevention capabilities by confining privileged programs and user sessions which may become compromised.

CCE-27209-6

Verify and Correct File Permissions with RPM

The RPM package management system can check file access permissions of installed software packages, including many that are important to system security. Verify that the file permissions of system files and commands match vendor values. Check the file permissions with the following command:

    $ sudo rpm -Va | grep '^.M'

Output indicates files that do not match vendor defaults. After locating a file with incorrect permissions, run the following command to determine which package owns it:

    $ rpm -qf FILENAME

Next, run the following command to reset its permissions to the correct values:

    $ sudo rpm --setperms PACKAGENAME

CCE-80545-7

Verify and Correct Ownership with RPM

The RPM package management system can check file ownership permissions of installed software packages, including many that are important to system security. After locating a file with incorrect permissions, which can be found with

    rpm -Va | grep "^.....\(U\|.G\)"

run the following command to determine which package owns it:

    $ rpm -qf FILENAME

Next, run the following command to reset its permissions to the correct values:

    $ sudo rpm --setugids PACKAGENAME

CCE-27157-7

Verify File Hashes with RPM

Without cryptographic integrity protections, system executables and files can be altered by unauthorized users without detection. The RPM package management system can check the hashes of installed software packages, including many that are important to system security. To verify that the cryptographic hash of system files and commands match vendor values, run the following command to list which files on the system have hashes that differ from what is expected by the RPM database:

    $ rpm -Va | grep '^..5'

A "c" in the second column indicates that a file is a configuration file, which may appropriately be expected to change. If the file was not expected to change, investigate the cause of the change using audit logs or other means. The package can then be reinstalled to restore the file. Run the following command to determine which package owns the file:

    $ rpm -qf FILENAME

The package can be reinstalled from a yum repository using the command:

    $ sudo yum reinstall PACKAGENAME

Alternatively, the package can be reinstalled from trusted media using the command:

    $ sudo rpm -Uvh PACKAGENAME

CCE-27096-7

Install AIDE

Install the AIDE package with the command:

    $ sudo yum install aide

CCE-80376-7

Configure AIDE to Verify Extended Attributes

By default, the `xattrs` option is added to the `FIPSR` ruleset in AIDE. If using a custom ruleset or the `xattrs` option is missing, add `xattrs` to the appropriate ruleset. For example, add `xattrs` to the following line in `/etc/aide.conf`:

    FIPSR = p+i+n+u+g+s+m+c+acl+selinux+xattrs+sha256

AIDE rules can be configured in multiple ways; this is merely one example that is already configured by default.

CCE-80375-9

Configure AIDE to Verify Access Control Lists (ACLs)

By default, the `acl` option is added to the `FIPSR` ruleset in AIDE. If using a custom ruleset or the `acl` option is missing, add `acl` to the appropriate ruleset. For example, add `acl` to the following line in `/etc/aide.conf`:

    FIPSR = p+i+n+u+g+s+m+c+acl+selinux+xattrs+sha256

AIDE rules can be configured in multiple ways; this is merely one example that is already configured by default.

CCE-80377-5

Configure AIDE to Use FIPS 140-2 for Validating Hashes

By default, the `sha512` option is added to the `NORMAL` ruleset in AIDE. If using a custom ruleset or the `sha512` option is missing, add `sha512` to the appropriate ruleset. For example, add `sha512` to the following line in `/etc/aide.conf`:

    NORMAL = FIPSR+sha512

AIDE rules can be configured in multiple ways; this is merely one example that is already configured by default.

CCE-80374-2

Configure Notification of Post-AIDE Scan Details

AIDE should notify appropriate personnel of the details of a scan after the scan has been run. If AIDE has already been configured for periodic execution in `/etc/crontab`, append the following line to the existing AIDE line:

     | /bin/mail -s "$(hostname) - AIDE Integrity Check" root@localhost

Otherwise, add the following line to `/etc/crontab`:

    05 4 * * * root /usr/sbin/aide --check | /bin/mail -s "$(hostname) - AIDE Integrity Check" root@localhost

AIDE can be executed periodically through other means; this is merely one example.

CCE-26952-2

Configure Periodic Execution of AIDE

At a minimum, AIDE should be configured to run a weekly scan. At most, AIDE should be run daily. To implement a daily execution of AIDE at 4:05am using cron, add the following line to `/etc/crontab`:

    05 4 * * * root /usr/sbin/aide --check

To implement a weekly execution of AIDE at 4:05am using cron, add the following line to `/etc/crontab`:

    05 4 * * 0 root /usr/sbin/aide --check

AIDE can be executed periodically through other means; this is merely one example. The usage of cron's special time codes, such as `@daily` and `@weekly` is acceptable.

CCE-27220-3

Build and Test AIDE Database

Run the following command to generate a new database:

    $ sudo /usr/sbin/aide --init

By default, the database will be written to the file `/var/lib/aide/aide.db.new.gz`. Storing the database, the configuration file `/etc/aide.conf`, and the binary `/usr/sbin/aide` (or hashes of these files), in a secure location (such as on read-only media) provides additional assurance about their integrity. The newly-generated database can be installed as follows:

    $ sudo cp /var/lib/aide/aide.db.new.gz /var/lib/aide/aide.db.gz

To initiate a manual check, run the following command:

    $ sudo /usr/sbin/aide --check

If this check produces any unexpected output, investigate.

CCE-27078-5

Disable Prelinking

The prelinking feature changes binaries in an attempt to decrease their startup time. In order to disable it, change or add the following line inside the file `/etc/sysconfig/prelink`:

    PRELINKING=no

Next, run the following command to return binaries to a normal, non-prelinked state:

    $ sudo /usr/sbin/prelink -ua

CCE-26876-3

Ensure gpgcheck Enabled For All Yum Package Repositories

To ensure signature checking is not disabled for any repos, remove any lines from files in `/etc/yum.repos.d` of the form:

    gpgcheck=0

CCE-26895-3

Ensure Software Patches Installed

If the system is joined to the Red Hat Network, a Red Hat Satellite Server, or a yum server, run the following command to install updates:

    $ sudo yum update

If the system is not configured to use one of these sources, updates (in the form of RPM packages) can be manually downloaded from the Red Hat Network and installed using `rpm`.
NOTE: U.S. Defense systems are required to be patched within 30 days or sooner as local policy dictates.

CCE-26957-1

Ensure Red Hat GPG Key Installed

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:

    $ sudo subscription-manager register

If the system is not connected to the Internet or an RHN Satellite, then install the Red Hat GPG key from trusted media such as the Red Hat installation CD-ROM or DVD. Assuming the disc is mounted in `/media/cdrom`, use the following command as the root user to import it into the keyring:

    $ sudo rpm --import /media/cdrom/RPM-GPG-KEY

CCE-80348-6

Ensure gpgcheck Enabled for Repository Metadata

Verify the operating system prevents the installation of patches, service packs, device drivers, or operating system components of local packages without verification of the repository metadata.
Check that `yum` verifies the repository metadata prior to install with the following command. This should be configured by setting `repo_gpgcheck` to `1` in `/etc/yum.conf`.

CCE-80346-0 | Ensure YUM Removes Previous Package Versions | `Yum` should be configured to remove previous software components after previous versions have been installed. To configure `yum` to remove the previous software components after updating, set the `clean_requirements_on_remove` to `1` in `/etc/yum.conf`.

CCE-26989-4

Ensure gpgcheck Enabled In Main Yum Configuration

The `gpgcheck` option controls whether RPM packages' signatures are always checked prior to installation. To configure yum to check package signatures before installing them, ensure the following line appears in `/etc/yum.conf` in the `[main]` section:

    gpgcheck=1

CCE-80347-8 | Ensure gpgcheck Enabled for Local Packages | `Yum` should be configured to verify the signature(s) of local packages prior to installation. To configure `yum` to verify signatures of local packages, set the `localpkg_gpgcheck` to `1` in `/etc/yum.conf`.

CCE-27128-8

Encrypt Partitions

Red Hat Enterprise Linux 7 natively supports partition encryption through the Linux Unified Key Setup-on-disk-format (LUKS) technology. The easiest way to encrypt a partition is during installation time.
For manual installations, select the `Encrypt` checkbox during partition creation to encrypt the partition. When this option is selected the system will prompt for a passphrase to use in decrypting the partition. The passphrase will subsequently need to be entered manually every time the system boots.
For automated/unattended installations, it is possible to use Kickstart by adding the `--encrypted` and `--passphrase=` options to the definition of each partition to be encrypted. For example, the following line would encrypt the root partition:

    part / --fstype=ext4 --size=100 --onpart=hda1 --encrypted --passphrase=PASSPHRASE

Any PASSPHRASE is stored in the Kickstart in plaintext, and the Kickstart must then be protected accordingly. Omitting the `--passphrase=` option from the partition definition will cause the installer to pause and interactively ask for the passphrase during installation.
By default, the `Anaconda` installer uses `aes-xts-plain64` cipher with a minimum `512` bit key size which should be compatible with FIPS enabled.
Detailed information on encrypting partitions using LUKS or LUKS ciphers can be found on the Red Hat Documentation web site:
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/Security_Guide/sec-Encryption.html

CCE-80144-9 | Ensure /home Located On Separate Partition | If user home directories will be stored locally, create a separate partition for `/home` at installation time (or migrate it later using LVM). If `/home` will be mounted from another system such as an NFS server, then creating a separate partition is not necessary at installation time, and the mountpoint can instead be configured later.
CCE-TBD | Ensure /var/tmp Located On Separate Partition | The `/var/tmp` directory is a world-writable directory used for temporary file storage. Ensure it has its own partition or logical volume at installation time, or migrate it using LVM.
CCE-26404-4 | Ensure /var Located On Separate Partition | The `/var` directory is used by daemons and other system services to store frequently-changing data. Ensure that `/var` has its own partition or logical volume at installation time, or migrate it using LVM.
CCE-27173-4 | Ensure /tmp Located On Separate Partition | The `/tmp` directory is a world-writable directory used for temporary file storage. Ensure it has its own partition or logical volume at installation time, or migrate it using LVM.
CCE-26971-2 | Ensure /var/log/audit Located On Separate Partition | Audit logs are stored in the `/var/log/audit` directory. Ensure that it has its own partition or logical volume at installation time, or migrate it later using LVM. Make absolutely certain that it is large enough to store all audit logs that will be created by the auditing daemon.
CCE-26967-0 | Ensure /var/log Located On Separate Partition | System logs are stored in the `/var/log` directory. Ensure that it has its own partition or logical volume at installation time, or migrate it using LVM.