| name | cis-apache24-5.2 |
| description | Ensure Options for the Web Root Directory Are Restricted |
| category | cis-apache |
| version | 2.3.0 |
| author | cyberstrike-official |
| tags | ["cis","apache","linux","features","content","options"] |
| cis_id | 5.2 |
| cis_benchmark | CIS Apache HTTP Server 2.4 Benchmark v2.3.0 |
| tech_stack | ["linux","apache"] |
| cwe_ids | [] |
| chains_with | [] |
| prerequisites | [] |
| severity_boost | {} |
5.2 Ensure Options for the Web Root Directory Are Restricted
Profile Applicability
Description
The Apache Options directive allows for specific configuration of options, including:
- Execution of CGI
- Following symbolic links
- Server side includes
- Content negotiation
Rationale
The Options directive at the web root or document root level also needs to be restricted to the minimal options required. A setting of None is highly recommended, however it is recognized that this level configuration may be needed if multiple languages are supported. No other options should be enabled.
Audit
Perform the following to determine if the recommended state is implemented:
- Search the Apache configuration files (
httpd.conf and any included configuration files) to find document root <Directory> elements.
- Ensure there is a single
Options directive with the value of None or Multiviews.
The following may be useful in extracting directory elements from the Apache configuration for auditing.
perl -ne 'print if /^ *<Directory */\/i .. /<\/Directory>/i'
$APACHE_PREFIX/conf/httpd.conf
Remediation
Perform the following to implement the recommended state:
- Search the Apache configuration files (
httpd.conf and any included configuration files) to find document root <Directory> element.
- Add or modify any existing
Options directive to have a value of None or Multiviews, if multiviews are needed.
<Directory "/usr/local/apache2/htdocs">
. . .
Options None
. . .
Default Value
The default value for the web root directory's Option directive is FollowSymLinks.
References
- https://httpd.apache.org/docs/2.4/mod/core.html#options
CIS Controls
Controls Version: v8