Mercurial > hg > nginx-site
changeset 418:2638f67205ee
Documented the disable_symlinks directive.
author | Ruslan Ermilov <ru@nginx.com> |
---|---|
date | Wed, 15 Feb 2012 21:45:42 +0000 |
parents | cbc2d1b51cb6 |
children | 8fa5f2273014 |
files | xml/en/docs/http/ngx_http_core_module.xml xml/ru/docs/http/ngx_http_core_module.xml |
diffstat | 2 files changed, 103 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/xml/en/docs/http/ngx_http_core_module.xml Wed Feb 15 21:44:31 2012 +0000 +++ b/xml/en/docs/http/ngx_http_core_module.xml Wed Feb 15 21:45:42 2012 +0000 @@ -464,6 +464,57 @@ </directive> +<directive name="disable_symlinks"> +<syntax> + <literal>on</literal> | + <literal>off</literal> | + <literal>if_not_owner</literal></syntax> +<default>off</default> +<context>http</context> +<context>server</context> +<context>location</context> +<appeared-in>1.1.15</appeared-in> + +<para> +Determines how nginx treats symbolic links when opening files: +<list type="tag"> + +<tag-name><literal>off</literal></tag-name> +<tag-desc> +Symbolic links in the pathname are not processed specially. +This is the default behavior. +</tag-desc> + +<tag-name><literal>on</literal></tag-name> +<tag-desc> +If any component of the pathname is a symbolic link, +access to a file is denied. +</tag-desc> + +<tag-name><literal>if_not_owner</literal></tag-name> +<tag-desc> +Access to a file is denied if any component of the pathname +is a symbolic link, and the link and object that the link +points to have different owners. +</tag-desc> + +</list> +</para> + +<para> +This directive is only available on systems that have the +<c-func>openat</c-func> and <c-func>fstatat</c-func> interfaces. +This includes modern versions of FreeBSD, Linux, and Solaris. +</para> + +<para> +Parameters <literal>on</literal> and <literal>if_not_owner</literal> +add a processing overhead. +</para> + +</directive> + + <directive name="error_page"> <syntax> <value>code</value> ...
--- a/xml/ru/docs/http/ngx_http_core_module.xml Wed Feb 15 21:44:31 2012 +0000 +++ b/xml/ru/docs/http/ngx_http_core_module.xml Wed Feb 15 21:45:42 2012 +0000 @@ -453,6 +453,58 @@ </directive> +<directive name="disable_symlinks"> +<syntax> + <literal>on</literal> | + <literal>off</literal> | + <literal>if_not_owner</literal></syntax> +<default>off</default> +<context>http</context> +<context>server</context> +<context>location</context> +<appeared-in>1.1.15</appeared-in> + +<para> +Определяет, как следует поступать с символическими ссылками +при открытии файлов: +<list type="tag"> + +<tag-name><literal>off</literal></tag-name> +<tag-desc> +Символические ссылки в пути никак специально не обрабатываются. +Это стандартное поведение. +</tag-desc> + +<tag-name><literal>on</literal></tag-name> +<tag-desc> +Если любой компонент пути является символической ссылкой, +доступ к файлу запрещается. +</tag-desc> + +<tag-name><literal>if_not_owner</literal></tag-name> +<tag-desc> +Доступ к файлу запрещается, если любой компонент пути +является символической ссылкой, и ссылка и объект, на +который она ссылается, имеют разных владельцев. +</tag-desc> + +</list> +</para> + +<para> +Эта директива доступна только на системах, в которых есть +интерфейсы <c-func>openat</c-func> и <c-func>fstatat</c-func>. +К таким системам относятся современные версии FreeBSD, Linux и Solaris. +</para> + +<para> +Параметры <literal>on</literal> и <literal>if_not_owner</literal> +требуют дополнительных затрат на обработку. +</para> + +</directive> + + <directive name="error_page"> <syntax> <value>код</value> ...