mod_info.xml revision c4e9ed6b7b211388ed42d520562a02f8a7fccf49
b341a780162d809b187a8f35a10bba7642b69798vboxsync<!DOCTYPE modulesynopsis SYSTEM "/style/modulesynopsis.dtd">
b341a780162d809b187a8f35a10bba7642b69798vboxsync<?xml-stylesheet type="text/xsl" href="/style/manual.en.xsl"?>
b341a780162d809b187a8f35a10bba7642b69798vboxsync<!-- $LastChangedRevision$ -->
b341a780162d809b187a8f35a10bba7642b69798vboxsync Licensed to the Apache Software Foundation (ASF) under one or more
b341a780162d809b187a8f35a10bba7642b69798vboxsync contributor license agreements. See the NOTICE file distributed with
b341a780162d809b187a8f35a10bba7642b69798vboxsync this work for additional information regarding copyright ownership.
b341a780162d809b187a8f35a10bba7642b69798vboxsync The ASF licenses this file to You under the Apache License, Version 2.0
b341a780162d809b187a8f35a10bba7642b69798vboxsync (the "License"); you may not use this file except in compliance with
b341a780162d809b187a8f35a10bba7642b69798vboxsync the License. You may obtain a copy of the License at
b341a780162d809b187a8f35a10bba7642b69798vboxsync Unless required by applicable law or agreed to in writing, software
b341a780162d809b187a8f35a10bba7642b69798vboxsync distributed under the License is distributed on an "AS IS" BASIS,
b341a780162d809b187a8f35a10bba7642b69798vboxsync WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
b341a780162d809b187a8f35a10bba7642b69798vboxsync See the License for the specific language governing permissions and
b341a780162d809b187a8f35a10bba7642b69798vboxsync limitations under the License.
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync<description>Provides a comprehensive overview of the server
0de1998ac52682bb5322df476e45f237265ea9b7vboxsyncconfiguration</description>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <p>To configure <module>mod_info</module>, add the following to your
b341a780162d809b187a8f35a10bba7642b69798vboxsync<Location /server-info>
b341a780162d809b187a8f35a10bba7642b69798vboxsync SetHandler server-info
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync</Location>
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync </highlight>
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <p>You may wish to use <module>mod_access</module> inside the
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <directive type="section" module="core">Location</directive>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync directive to limit access to your server configuration
b341a780162d809b187a8f35a10bba7642b69798vboxsync information:</p>
b341a780162d809b187a8f35a10bba7642b69798vboxsync<Location /server-info>
b341a780162d809b187a8f35a10bba7642b69798vboxsync SetHandler server-info
b341a780162d809b187a8f35a10bba7642b69798vboxsync</Location>
b341a780162d809b187a8f35a10bba7642b69798vboxsync </highlight>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <p>Once configured, the server information is obtained by
b341a780162d809b187a8f35a10bba7642b69798vboxsync accessing <code>http://your.host.example.com/server-info</code></p>
b341a780162d809b187a8f35a10bba7642b69798vboxsync<section id="security"><title>Security Issues</title>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <p>Once <module>mod_info</module> is loaded into the server, its
8b6d7e3d5672f9db05a27b3991948c7949f7bd57vboxsync handler capability is available in <em>all</em> configuration
8b6d7e3d5672f9db05a27b3991948c7949f7bd57vboxsync files, including per-directory files (<em>e.g.</em>,
8b6d7e3d5672f9db05a27b3991948c7949f7bd57vboxsync <code>.htaccess</code>). This may have security-related
8b6d7e3d5672f9db05a27b3991948c7949f7bd57vboxsync ramifications for your site.</p>
8b6d7e3d5672f9db05a27b3991948c7949f7bd57vboxsync <p>In particular, this module can leak sensitive information
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync from the configuration directives of other Apache modules such as
27c57cb14788caba10c2a4f55cd50c869576be0evboxsync system paths, usernames/passwords, database names, etc. Therefore,
b341a780162d809b187a8f35a10bba7642b69798vboxsync used in a controlled environment and always with caution.</p>
345968627c523dfaeab9b32b0afa31438a9a6541vboxsync <p>You will probably want to use <module>mod_authz_host</module>
345968627c523dfaeab9b32b0afa31438a9a6541vboxsync to limit access to your server configuration information.</p>
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync<Location /server-info>
67faa5eeb93e433a25e20952e1bd9e2c8594f72fvboxsync SetHandler server-info
9f801b83895937ce4d726206e5859637ff9f5166vboxsync Order allow,deny
b341a780162d809b187a8f35a10bba7642b69798vboxsync # Allow access from server itself
b341a780162d809b187a8f35a10bba7642b69798vboxsync Allow from 127.0.0.1
b341a780162d809b187a8f35a10bba7642b69798vboxsync # Additionally, allow access from local workstation
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync Allow from 192.168.1.17
b341a780162d809b187a8f35a10bba7642b69798vboxsync</Location>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync </highlight>
b341a780162d809b187a8f35a10bba7642b69798vboxsync<section id="queries"><title>Selecting the information shown</title>
cae5cca5168e18e168df5541b11f462b60062a7avboxsync <p>By default, the server information includes a list of
345968627c523dfaeab9b32b0afa31438a9a6541vboxsync all enabled modules, and for each module, a description of
cae5cca5168e18e168df5541b11f462b60062a7avboxsync the directives understood by that module, the hooks implemented
cae5cca5168e18e168df5541b11f462b60062a7avboxsync by that module, and the relevant directives from the current
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync configuration.</p>
9f801b83895937ce4d726206e5859637ff9f5166vboxsync <p>Other views of the configuration information are available by
cae5cca5168e18e168df5541b11f462b60062a7avboxsync appending a query to the <code>server-info</code> request. For
cae5cca5168e18e168df5541b11f462b60062a7avboxsync example, <code>http://your.host.example.com/server-info?config</code>
9f801b83895937ce4d726206e5859637ff9f5166vboxsync will show all configuration directives.</p>
e5410ff7b5985439e70790aadb51f1c6c27fe213vboxsync <dd>Only information relevant to the named module</dd>
d1e0bb6198393c6a797ba3ab4363c55ca5a76988vboxsync <dd>Just the configuration directives, not sorted by module</dd>
e5410ff7b5985439e70790aadb51f1c6c27fe213vboxsync <dd>Only the list of Hooks each module is attached to</dd>
9f801b83895937ce4d726206e5859637ff9f5166vboxsync<section id="startup"><title>Dumping the configuration on startup</title>
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <p>If the config define <code>-DDUMP_CONFIG</code> is set,
9f801b83895937ce4d726206e5859637ff9f5166vboxsync <module>mod_info</module> will dump the pre-parsed configuration to
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <code>stdout</code> during server startup. Pre-parsed means that
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync directives like
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <directive type="section" module="core">IfDefine</directive> and
b341a780162d809b187a8f35a10bba7642b69798vboxsync <directive type="section" module="core">IfModule</directive> are
b341a780162d809b187a8f35a10bba7642b69798vboxsync evaluated and environment varialbles are replaced. However it does
b341a780162d809b187a8f35a10bba7642b69798vboxsync not represent the final state of the configuration. In particular,
b341a780162d809b187a8f35a10bba7642b69798vboxsync it does not represent the merging or overriding that may happen
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync for repeated directives.</p>
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <p>This is roughly equivalent to the <code>?config</code> query.</p>
b341a780162d809b187a8f35a10bba7642b69798vboxsync<section id="limitations"><title>Known Limitations</title>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <p><module>mod_info</module> provides its information by reading the
b341a780162d809b187a8f35a10bba7642b69798vboxsync parsed configuration, rather than reading the original configuration
b341a780162d809b187a8f35a10bba7642b69798vboxsync file. There are a few limitations as a result of the way the parsed
b341a780162d809b187a8f35a10bba7642b69798vboxsync configuration tree is created:</p>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <li>Directives which are executed immediately rather than being
b341a780162d809b187a8f35a10bba7642b69798vboxsync stored in the parsed configuration are not listed. These include
b341a780162d809b187a8f35a10bba7642b69798vboxsync <directive module="mod_so">LoadModule</directive>, and
b341a780162d809b187a8f35a10bba7642b69798vboxsync <directive module="mod_so">LoadFile</directive>.</li>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <li>Directives which control the configuration file itself, such as
b341a780162d809b187a8f35a10bba7642b69798vboxsync <directive module="core"><IfModule></directive> and
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync <directive module="core"><IfDefine></directive> are not
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync listed, but the included configuration directives are.</li>
0de1998ac52682bb5322df476e45f237265ea9b7vboxsync <li>Comments are not listed. (This may be considered a feature.)</li>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <li>Configuration directives from <code>.htaccess</code> files are
b341a780162d809b187a8f35a10bba7642b69798vboxsync not listed (since they do not form part of the permanent server
b341a780162d809b187a8f35a10bba7642b69798vboxsync configuration).</li>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <li>Container directives such as
b341a780162d809b187a8f35a10bba7642b69798vboxsync <directive module="core"><Directory></directive>
b341a780162d809b187a8f35a10bba7642b69798vboxsync are listed normally, but <module>mod_info</module> cannot figure
b341a780162d809b187a8f35a10bba7642b69798vboxsync out the line number for the closing
b341a780162d809b187a8f35a10bba7642b69798vboxsync <directive module="core"></Directory></directive>.</li>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <li>Directives generated by third party modules such as <a href="http://perl.apache.org">mod_perl</a>
b341a780162d809b187a8f35a10bba7642b69798vboxsync might not be listed.</li>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync<directivesynopsis>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync<description>Adds additional information to the module
b341a780162d809b187a8f35a10bba7642b69798vboxsyncinformation displayed by the server-info handler</description>
b341a780162d809b187a8f35a10bba7642b69798vboxsync<syntax>AddModuleInfo <var>module-name</var> <var>string</var></syntax>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync<contextlist><context>server config</context><context>virtual host</context>
b341a780162d809b187a8f35a10bba7642b69798vboxsync</contextlist>
b341a780162d809b187a8f35a10bba7642b69798vboxsync <p>This allows the content of <var>string</var> to be shown as
b341a780162d809b187a8f35a10bba7642b69798vboxsync HTML interpreted, <strong>Additional Information</strong> for
67faa5eeb93e433a25e20952e1bd9e2c8594f72fvboxsyncAddModuleInfo mod_deflate.c 'See <a \
9f801b83895937ce4d726206e5859637ff9f5166vboxsync href="http://www.apache.org/docs/&httpd.docs;/mod/mod_deflate.html">\
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync http://www.apache.org/docs/&httpd.docs;/mod/mod_deflate.html</a>'
b341a780162d809b187a8f35a10bba7642b69798vboxsync </highlight>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync</directivesynopsis>
085bc29163eb87e345acaae02789e4c233d51f3bvboxsync</modulesynopsis>