STIGhubSTIGhub
STIGsSearchCompareAbout

STIGhub

A free tool to search and browse the entire DISA STIG library. Saves up to 75% in security compliance research time.

Navigation

  • Browse STIGs
  • Search
  • Compare Versions

Resources

  • About
  • VPAT
  • DISA STIG Library
Powered by Pylon
© 2026 Beacon Cloud Solutions, Inc. All rights reserved.
← Back to Apache Server 2.4 UNIX Site Security Technical Implementation Guide

V-214284

CAT II (Medium)

Users and scripts running on behalf of users must be contained to the document root or home directory tree of the Apache web server.

Rule ID

SV-214284r960963_rule

STIG

Apache Server 2.4 UNIX Site Security Technical Implementation Guide

Version

V2R6

CCIs

CCI-000381

Discussion

A web server is designed to deliver content and execute scripts or applications on the request of a client or user. Containing user requests to files in the directory tree of the hosted web application and limiting the execution of scripts and applications guarantees that the user is not accessing information protected outside the application's realm. The web server must also prohibit users from jumping outside the hosted application directory tree through access to the user's home directory, symbolic links or shortcuts, or through search paths for missing files.

Check Content

Determine the location of the "HTTPD_ROOT" directory and the "httpd.conf" file: 
 
# apachectl -V | egrep -i 'httpd_root|server_config_file'
-D HTTPD_ROOT="/etc/httpd"
-D SERVER_CONFIG_FILE="conf/httpd.conf"

Note: The apachectl front end is the preferred method for locating the Apache httpd file. For some Linux distributions "apache2ctl -V" or  "httpd -V" can also be used. 
 
Verify there is a single "Require" directive with the value of "all denied". 
 
Verify there are no "Allow" or "Deny" directives in the root <Directory> element. 
 
The following may be useful in extracting root directory elements from the Apache configuration for auditing: 
 
# perl -ne 'print if /^ *<Directory *\//i .. /<\/Directory/i' $APACHE_PREFIX/conf/httpd.conf  
 
If there are "Allow" or "Deny" directives in the root <Directory> element, this is a finding.

Fix Text

Determine the location of the "HTTPD_ROOT" directory and the "httpd.conf" file: 
 
# apachectl -V | egrep -i 'httpd_root|server_config_file' 
-D HTTPD_ROOT="/etc/httpd" 
-D SERVER_CONFIG_FILE="conf/httpd.conf" 
 
Set the root directory directive as follows: 
 
<Directory> 
... 
Require all denied 
... 
</Directory> 
 
Remove any "Deny" and "Allow" directives from the root <Directory> element. 
 
Restart Apache: apachectl restart