adefdd8a77ba8de51ba56d49fed068c584abcc6f
[ansible.git] / roles / apache / files / security.conf
1 # Block access to some directories that are allowed per default
2 <Directory /var/www/>
3     Require all denied
4 </Directory>
5
6 # Changing the following options will not really affect the security of the
7 # server, but might make attacks slightly more difficult in some cases.
8
9 #
10 # ServerTokens
11 # This directive configures what you return as the Server HTTP response
12 # Header. The default is 'Full' which sends information about the OS-Type
13 # and compiled in modules.
14 # Set to one of:  Full | OS | Minimal | Minor | Major | Prod
15 # where Full conveys the most information, and Prod the least.
16 #ServerTokens Minimal
17 ServerTokens Minor
18 #ServerTokens Full
19
20 #
21 # Optionally add a line containing the server version and virtual host
22 # name to server-generated pages (internal error documents, FTP directory
23 # listings, mod_status and mod_info output etc., but not CGI generated
24 # documents or custom error documents).
25 # Set to "EMail" to also include a mailto: link to the ServerAdmin.
26 # Set to one of:  On | Off | EMail
27 ServerSignature Off
28 #ServerSignature On
29
30 #
31 # Allow TRACE method
32 #
33 # Set to "extended" to also reflect the request body (only for testing and
34 # diagnostic purposes).
35 #
36 # Set to one of:  On | Off | extended
37 TraceEnable Off
38 #TraceEnable On
39
40 #
41 # Forbid access to version control directories
42 #
43 # If you use version control systems in your document root, you should
44 # probably deny access to their directories. For example, for subversion:
45 #
46 #<DirectoryMatch "/\.svn">
47 #   Require all denied
48 #</DirectoryMatch>
49
50 #
51 # Setting this header will prevent MSIE from interpreting files as something
52 # else than declared by the content type in the HTTP headers.
53 # Requires mod_headers to be enabled.
54 #
55 Header set X-Content-Type-Options: "nosniff"
56
57 #
58 # Setting this header will prevent other sites from embedding pages from this
59 # site as frames. This defends against clickjacking attacks.
60 # Requires mod_headers to be enabled.
61 #
62 Header set X-Frame-Options: "sameorigin"
63
64
65 # vim: syntax=apache ts=4 sw=4 sts=4 sr noet