Free DISA STIG and SRG Library | Vaulted

V-214267

The Apache web server must be protected from being stopped by a non-privileged user.

Finding ID
AS24-U1-000820
Rule ID
SV-214267r505935_rule214267r612240_rule
Severity
Cat II
CCE
(None)
Group Title
SRG-APP-000435-WSR-000147
CCI
CCI-002385
Target Key
(None)
Documentable
No
Discussion

An attacker has at least two reasons to stop a web server. The first is to cause a denial of service (DoS), and the second is to put in place changes the attacker made to the web server configuration. To prohibit an attacker from stopping the Apache web server, the process ID (pid) of the web server and the utilities used to start/stop it must be protected from access by non-privileged users. By knowing the "pid" and having access to the Apache web server utilities, a non-privileged user has a greater capability of stopping the server, whether intentionally or unintentionally.

Fix Text

Review the web server documentation and deployed configuration to determine where the process ID is stored and which utilities are used to start/stop the web server. Determine where the "httpd.pid" file is located by running the following command: find / -name "httpd.pid" Run the following commands:   # cd &lt;<'httpd.pid location'>/ # chown &lt;<'service account'> httpd.pid  # chmod 644 httpd.pid  # cd /usr/sbin  # chown &lt;<'service account'> service apachectl  # chmod 755 service apachectl

Check Content

Review the web server documentation and deployed configuration to determine where the process ID is stored and which utilities are used to start/stop the web server. Determine where the "httpd.pid" file is located by running the following command: find / -name "httpd.pid"   This file is automatically generated upon service start. Verify the file owner/group is of an administrative service account:   ls -lah &lt;<'httpd.pid location'>/httpd.pid   If the file owner/group is not an administrative service account, this is a finding.   Verify the service utilities used to manage the Apache service owner/group is of an administrative service account.   ls -lah /usr/sbin/service ls -lah /usr/sbin/apachectl   If the service utilities owner/group is not an administrative service account, this is a finding.   Determine whether the process ID and the utilities are protected from non-privileged users.   If the process ID and the utilities are not protected from non-privileged users, this is a finding.