mod_unixd.html.en revision 4eea6eaa18317f1122158d21b4437d90e04e56d2
842ae4bd224140319ae7feec1872b93dfd491143fielding<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
842ae4bd224140319ae7feec1872b93dfd491143fielding<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><!--
842ae4bd224140319ae7feec1872b93dfd491143fielding XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
842ae4bd224140319ae7feec1872b93dfd491143fielding This file is generated from xml source: DO NOT EDIT
842ae4bd224140319ae7feec1872b93dfd491143fielding XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein<link href="/style/css/manual.css" rel="stylesheet" media="all" type="text/css" title="Main stylesheet" />
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<link href="/style/css/manual-loose-100pc.css" rel="alternate stylesheet" media="all" type="text/css" title="No Sidebar - Default font size" />
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<link href="/style/css/manual-print.css" rel="stylesheet" media="print" type="text/css" />
ce9621257ef9e54c1bbe5ad8a5f445a1f211c2dcnd<link href="/images/favicon.ico" rel="shortcut icon" /></head>
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein<p class="menu"><a href="/mod/">Modules</a> | <a href="/mod/directives.html">Directives</a> | <a href="/faq/">FAQ</a> | <a href="/glossary.html">Glossary</a> | <a href="/sitemap.html">Sitemap</a></p>
b0fb330a8581c8bfab5e523084f9f39264a52b12gstein<div class="up"><a href="./"><img title="<-" alt="<-" src="/images/left.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<a href="http://www.apache.org/">Apache</a> > <a href="http://httpd.apache.org/">HTTP Server</a> > <a href="http://httpd.apache.org/docs/">Documentation</a> > <a href="../">Version 2.3</a> > <a href="./">Modules</a></div>
50ebafad0f7b02e3808b4afdc967a64b565f5723gstein<p><span>Available Languages: </span><a href="/en/mod/mod_unixd.html" title="English"> en </a> |
f4c310fd2555c6faca1f980f00b161eadb089023gstein<a href="/tr/mod/mod_unixd.html" hreflang="tr" rel="alternate" title="T�rk�e"> tr </a></p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<table class="module"><tr><th><a href="module-dict.html#Description">Description:</a></th><td>Basic (required) security for Unix-family platforms.</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="module-dict.html#Status">Status:</a></th><td>Base</td></tr></table>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div id="quickview"><h3 class="directives">Directives</h3>
8a46775d163c06a8c51d1b0a3f2edfde945cb1d8stoddard<li><img alt="" src="/images/down.gif" /> <a href="#chrootdir">ChrootDir</a></li>
819a04ebb09c8cd3ed269218137b7ea025671d79gstein<li><img alt="" src="/images/down.gif" /> <a href="#group">Group</a></li>
819a04ebb09c8cd3ed269218137b7ea025671d79gstein<li><img alt="" src="/images/down.gif" /> <a href="#suexec">Suexec</a></li>
2acd42d5591f6db91fc3716300ecce1818e6fc14gstein<li><img alt="" src="/images/down.gif" /> <a href="#user">User</a></li>
a9a941ed6ca86039137d64bdc7b1c4fda9d07d12sf<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
a9a941ed6ca86039137d64bdc7b1c4fda9d07d12sf<div class="directive-section"><h2><a name="ChrootDir" id="ChrootDir">ChrootDir</a> <a name="chrootdir" id="chrootdir">Directive</a></h2>
6138d79b6ade895971022ea7be76a9fcf0e5ea8csf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Directory for apache to run chroot(8) after startup.</td></tr>
7a4999217dfa98039f66724f390511e3a4e4ae8cgstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>ChrootDir <var>/path/to/directory</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>none</code></td></tr>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
2acd42d5591f6db91fc3716300ecce1818e6fc14gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td><code class="module"><a href="/mod/mod_unixd.html">mod_unixd</a></code></td></tr>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein <p>This directive, available in httpd 2.2.9(?) and later, tells the
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe server to <var>chroot(8)</var> to the specified directory after
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein startup, but before accepting requests over the 'net.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe <p>Note that running the server under chroot is not simple,
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe and requires additional setup, particularly if you are running
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe scripts such as CGI or PHP. Please make sure you are properly
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein familiar with the operation of chroot before attempting to use
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein this feature.</p>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="Group" id="Group">Group</a> <a name="group" id="group">Directive</a></h2>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Group under which the server will answer
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Group <var>unix-group</var></code></td></tr>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>Group #-1</code></td></tr>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
10d15a1817ddd19094a70ed0f7e4efc6a56f449fgstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_unixd</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Only valid in global server config since Apache
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>The <code class="directive">Group</code> directive sets the group under
f4c310fd2555c6faca1f980f00b161eadb089023gstein which the server will answer requests. In order to use this
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe directive, the server must be run initially as <code>root</code>. If
f4c310fd2555c6faca1f980f00b161eadb089023gstein you start the server as a non-root user, it will fail to change to the
79c0832f728a14c4541e240817dce2e4a1315fe4gstein specified group, and will instead continue to run as the group of the
819a04ebb09c8cd3ed269218137b7ea025671d79gstein Group www-group
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>It is recommended that you set up a new group specifically for
f4c310fd2555c6faca1f980f00b161eadb089023gstein running the server. Some admins use user <code>nobody</code>,
819a04ebb09c8cd3ed269218137b7ea025671d79gstein but this is not always possible or desirable.</p>
31dff87ac99a1efdb8562d79389b767a4a2afbe3sf <p>Don't set <code class="directive">Group</code> (or <code class="directive"><a href="#user">User</a></code>) to <code>root</code> unless
185aa71728867671e105178b4c66fbc22b65ae26sf you know exactly what you are doing, and what the dangers are.</p>
819a04ebb09c8cd3ed269218137b7ea025671d79gstein<li><code class="directive"><a href="/mod/mod_privileges.html#vhostgroup">VHostGroup</a></code></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<li><code class="directive"><a href="/mod/mod_suexec.html#suexecusergroup">SuexecUserGroup</a></code></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="Suexec" id="Suexec">Suexec</a> <a name="suexec" id="suexec">Directive</a></h2>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>Enable or disable the suEXEC feature</td></tr>
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>Suexec On|Off</code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>On if suexec binary exists with proper owner and mode,
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_unixd</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Available in Apache httpd 2.3.9 and later</td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>When On, startup will fail if the suexec binary doesn't exist
f4c310fd2555c6faca1f980f00b161eadb089023gstein or has an invalid owner or file mode.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>When Off, suEXEC will be disabled even if the suexec binary exists
f4c310fd2555c6faca1f980f00b161eadb089023gstein and has a valid owner and file mode.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<div class="top"><a href="#page-header"><img alt="top" src="/images/up.gif" /></a></div>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<div class="directive-section"><h2><a name="User" id="User">User</a> <a name="user" id="user">Directive</a></h2>
dd1db5e838ed2c9b64a991007d4e385532376db1sf<tr><th><a href="directive-dict.html#Description">Description:</a></th><td>The userid under which the server will answer
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Syntax">Syntax:</a></th><td><code>User <var>unix-userid</var></code></td></tr>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<tr><th><a href="directive-dict.html#Default">Default:</a></th><td><code>User #-1</code></td></tr>
542880af4dc8f26fd8bfc88a1888f92ef98fba3bwrowe<tr><th><a href="directive-dict.html#Context">Context:</a></th><td>server config</td></tr>
e8f95a682820a599fe41b22977010636be5c2717jim<tr><th><a href="directive-dict.html#Status">Status:</a></th><td>Base</td></tr>
58bcfc43cfb8ad45551c8c1fc2b71a3fdac384d9wrowe<tr><th><a href="directive-dict.html#Module">Module:</a></th><td>mod_unixd</td></tr>
542880af4dc8f26fd8bfc88a1888f92ef98fba3bwrowe<tr><th><a href="directive-dict.html#Compatibility">Compatibility:</a></th><td>Only valid in global server config since Apache
819a04ebb09c8cd3ed269218137b7ea025671d79gstein <p>The <code class="directive">User</code> directive sets the user ID as
e8f95a682820a599fe41b22977010636be5c2717jim which the server will answer requests. In order to use this
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe directive, the server must be run initially as <code>root</code>.
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe If you start the server as a non-root user, it will fail to change
f4c310fd2555c6faca1f980f00b161eadb089023gstein to the lesser privileged user, and will instead continue to run as
f4c310fd2555c6faca1f980f00b161eadb089023gstein that original user. If you do start the server as <code>root</code>,
f4c310fd2555c6faca1f980f00b161eadb089023gstein then it is normal for the parent process to remain running as root.
1ccd992d37d62c8cb2056126f2234f64ec189bfddougm <p>The user should have no privileges that result in it being
f5ec9b038bb9db933072ba2c0a8e7bb2a3cedbdagstein able to access files that are not intended to be visible to the
f4c310fd2555c6faca1f980f00b161eadb089023gstein outside world, and similarly, the user should not be able to
f4c310fd2555c6faca1f980f00b161eadb089023gstein execute code that is not meant for HTTP requests. It is
f4c310fd2555c6faca1f980f00b161eadb089023gstein recommended that you set up a new user and group specifically for
f4c310fd2555c6faca1f980f00b161eadb089023gstein running the server. Some admins use user <code>nobody</code>, but
f4c310fd2555c6faca1f980f00b161eadb089023gstein this is not always desirable, since the <code>nobody</code> user
f4c310fd2555c6faca1f980f00b161eadb089023gstein can have other uses on the system.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein <p>Don't set <code class="directive">User</code> (or <code class="directive"><a href="#group">Group</a></code>) to <code>root</code> unless
f4c310fd2555c6faca1f980f00b161eadb089023gstein you know exactly what you are doing, and what the dangers are.</p>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="/mod/mod_privileges.html#vhostuser">VHostUser</a></code></li>
6f15570e3adc0faf87bf55f70857028276fc9e32wrowe<li><code class="directive"><a href="/mod/mod_suexec.html#suexecusergroup">SuexecUserGroup</a></code></li>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p><span>Available Languages: </span><a href="/en/mod/mod_unixd.html" title="English"> en </a> |
f4c310fd2555c6faca1f980f00b161eadb089023gstein<a href="/tr/mod/mod_unixd.html" hreflang="tr" rel="alternate" title="T�rk�e"> tr </a></p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p class="apache">Copyright 2010 The Apache Software Foundation.<br />Licensed under the <a href="http://www.apache.org/licenses/LICENSE-2.0">Apache License, Version 2.0</a>.</p>
f4c310fd2555c6faca1f980f00b161eadb089023gstein<p class="menu"><a href="/mod/">Modules</a> | <a href="/mod/directives.html">Directives</a> | <a href="/faq/">FAQ</a> | <a href="/glossary.html">Glossary</a> | <a href="/sitemap.html">Sitemap</a></p></div>