Mercurial > hg > nginx-site
annotate xml/ru/docs/mail/ngx_mail_auth_http_module.xml @ 2705:06805824d0f0
Documented the keepalive_time directive.
author | Yaroslav Zhuravlev <yar@nginx.com> |
---|---|
date | Tue, 13 Apr 2021 15:05:16 +0100 |
parents | 468e6e14e5cc |
children | ff357b676c2e |
rev | line source |
---|---|
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
1 <?xml version="1.0"?> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
2 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
3 <!-- |
638 | 4 Copyright (C) 2006, 2007 Anton Yuzhaninov |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
5 Copyright (C) Nginx, Inc. |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
6 --> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
7 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
8 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
9 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
10 <module name="Модуль ngx_mail_auth_http_module" |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
11 link="/ru/docs/mail/ngx_mail_auth_http_module.html" |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
12 lang="ru" |
2676
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
13 rev="10"> |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
14 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
15 <section id="directives" name="Директивы"> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
16 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
17 <directive name="auth_http"> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
18 <syntax><value>URL</value></syntax> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
19 <default/> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
20 <context>mail</context> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
21 <context>server</context> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
22 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
23 <para> |
641 | 24 Задаёт URL HTTP-сервера аутентификации. |
1255
e48d4309e7f2
Mail auth: added link to the protocol in the "auth_http" directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1254
diff
changeset
|
25 Протокол описан <link id="protocol">ниже</link>. |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
26 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
27 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
28 </directive> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
29 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
30 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
31 <directive name="auth_http_header"> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
32 <syntax><value>заголовок</value> <value>значение</value></syntax> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
33 <default/> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
34 <context>mail</context> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
35 <context>server</context> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
36 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
37 <para> |
1256
ebfcd76e23b6
Mail auth: corrected articles, rephrased some parts.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1255
diff
changeset
|
38 Добавляет указанный заголовок к запросам, посылаемым на сервер аутентификации. |
966 | 39 Заголовок можно использовать в качестве shared secret для проверки, |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
40 что запрос поступил от nginx. |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
41 Например: |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
42 <example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
43 auth_http_header X-Auth-Key "secret_string"; |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
44 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
45 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
46 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
47 </directive> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
48 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
49 |
1429
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
50 <directive name="auth_http_pass_client_cert"> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
51 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
52 <default>off</default> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
53 <context>mail</context> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
54 <context>server</context> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
55 <appeared-in>1.7.11</appeared-in> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
56 |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
57 <para> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
58 Добавляет заголовок <header>Auth-SSL-Cert</header> с |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
59 <link doc="ngx_mail_ssl_module.xml" id="ssl_verify_client">клиентским</link> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
60 сертификатом в формате PEM (закодирован в формате urlencode) |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
61 к запросам, посылаемым на сервер аутентификации. |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
62 </para> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
63 |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
64 </directive> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
65 |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
66 |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
67 <directive name="auth_http_timeout"> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
68 <syntax><value>время</value></syntax> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
69 <default>60s</default> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
70 <context>mail</context> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
71 <context>server</context> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
72 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
73 <para> |
1254
f49e326758c0
Mail auth: added description for the "auth_http_timeout" directive.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1066
diff
changeset
|
74 Задаёт таймаут общения с сервером аутентификации. |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
75 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
76 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
77 </directive> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
78 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
79 </section> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
80 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
81 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
82 <section id="protocol" name="Протокол"> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
83 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
84 <para> |
1256
ebfcd76e23b6
Mail auth: corrected articles, rephrased some parts.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1255
diff
changeset
|
85 Для общения с сервером аутентификации используется протокол HTTP. |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
86 Данные в теле ответа игнорируются, информация передаётся только в заголовках. |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
87 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
88 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
89 <para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
90 Примеры запросов и ответов: |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
91 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
92 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
93 <para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
94 Запрос: |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
95 <example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
96 GET /auth HTTP/1.0 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
97 Host: localhost |
1887
9af1e88e10c8
Documented SASL EXTERNAL support in mail.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1863
diff
changeset
|
98 Auth-Method: plain # plain/apop/cram-md5/external |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
99 Auth-User: user |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
100 Auth-Pass: password |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
101 Auth-Protocol: imap # imap/pop3/smtp |
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
102 Auth-Login-Attempt: 1 |
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
103 Client-IP: 192.0.2.42 |
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
104 Client-Host: client.example.org |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
105 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
106 Хороший ответ: |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
107 <example> |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
108 HTTP/1.0 200 OK |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
109 Auth-Status: OK |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
110 Auth-Server: 198.51.100.1 |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
111 Auth-Port: 143 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
112 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
113 Плохой ответ: |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
114 <example> |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
115 HTTP/1.0 200 OK |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
116 Auth-Status: Invalid login or password |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
117 Auth-Wait: 3 |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
118 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
119 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
120 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
121 <para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
122 Если заголовка <header>Auth-Wait</header> нет, |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
123 то после выдачи ошибки соединение будет закрыто. |
641 | 124 В текущей реализации на каждую попытку аутентификации выделяется память, |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
125 которая освобождается только при завершении сессии. |
641 | 126 Поэтому число неудачных попыток аутентификации в рамках одной сессии |
659
77a3314c74a7
Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents:
641
diff
changeset
|
127 должно быть ограничено — после 10-20 попыток (номер попытки передаётся |
77a3314c74a7
Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents:
641
diff
changeset
|
128 в заголовке <header>Auth-Login-Attempt</header>) сервер должен выдать ответ |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
129 без заголовка <header>Auth-Wait</header>. |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
130 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
131 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
132 <para> |
1046 | 133 При использовании APOP или CRAM-MD5 запрос и ответ будут выглядеть так: |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
134 <example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
135 GET /auth HTTP/1.0 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
136 Host: localhost |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
137 Auth-Method: apop |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
138 Auth-User: user |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
139 Auth-Salt: <238188073.1163692009@mail.example.com> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
140 Auth-Pass: auth_response |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
141 Auth-Protocol: imap |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
142 Auth-Login-Attempt: 1 |
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
143 Client-IP: 192.0.2.42 |
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
144 Client-Host: client.example.org |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
145 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
146 Хороший ответ: |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
147 <example> |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
148 HTTP/1.0 200 OK |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
149 Auth-Status: OK |
1063
6a19aadc15b2
Updates and unification for mail_auth_http_module examples.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1046
diff
changeset
|
150 Auth-Server: 198.51.100.1 |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
151 Auth-Port: 143 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
152 Auth-Pass: plain-text-pass |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
153 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
154 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
155 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
156 <para> |
1066
de77e295c073
Documented the "Auth-User" authentication header field.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1065
diff
changeset
|
157 Если в ответе есть заголовок <header>Auth-User</header>, |
de77e295c073
Documented the "Auth-User" authentication header field.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1065
diff
changeset
|
158 то он переопределяет имя пользователя, |
de77e295c073
Documented the "Auth-User" authentication header field.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1065
diff
changeset
|
159 используемое для аутентификации с бэкендом. |
de77e295c073
Documented the "Auth-User" authentication header field.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1065
diff
changeset
|
160 </para> |
de77e295c073
Documented the "Auth-User" authentication header field.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1065
diff
changeset
|
161 |
de77e295c073
Documented the "Auth-User" authentication header field.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1065
diff
changeset
|
162 <para> |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
163 Для SMTP в ответе дополнительно учитывается заголовок |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
164 <header>Auth-Error-Code</header> — если он есть, |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
165 то используется как код ответа в случае ошибки. |
966 | 166 Если его нет, то по умолчанию к <header>Auth-Status</header> |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
167 будет добавлен код 535 5.7.0. |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
168 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
169 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
170 <para> |
641 | 171 Например, если от сервера аутентификации будет получен ответ: |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
172 <example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
173 HTTP/1.0 200 OK |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
174 Auth-Status: Temporary server problem, try again later |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
175 Auth-Error-Code: 451 4.3.0 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
176 Auth-Wait: 3 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
177 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
178 то по SMTP клиенту будет выдана ошибка |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
179 <example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
180 451 4.3.0 Temporary server problem, try again later |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
181 </example> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
182 </para> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
183 |
1065
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
184 <para> |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
185 Если при проксировании SMTP не требуется аутентификация, |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
186 запрос будет выглядеть так: |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
187 <example> |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
188 GET /auth HTTP/1.0 |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
189 Host: localhost |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
190 Auth-Method: none |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
191 Auth-User: |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
192 Auth-Pass: |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
193 Auth-Protocol: smtp |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
194 Auth-Login-Attempt: 1 |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
195 Client-IP: 192.0.2.42 |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
196 Client-Host: client.example.org |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
197 Auth-SMTP-Helo: client.example.org |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
198 Auth-SMTP-From: MAIL FROM: <> |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
199 Auth-SMTP-To: RCPT TO: <postmaster@mail.example.com> |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
200 </example> |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
201 </para> |
88c0d96b9825
Documented the smtp_auth "none" method.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1063
diff
changeset
|
202 |
1429
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
203 <para> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
204 Для клиентского соединения по протоколу SSL/TLS (1.7.11) |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
205 добавляется заголовок <header>Auth-SSL</header>, и если директива |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
206 <link doc="ngx_mail_ssl_module.xml" id="ssl_verify_client"/> включена, |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
207 заголовок <header>Auth-SSL-Verify</header> содержит |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
208 результат проверки клиентского сертификата: |
1856
7133004fa5b3
$ssl_client_verify extended with a failure reason.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1429
diff
changeset
|
209 “<literal>SUCCESS</literal>”, “<literal>FAILED:</literal><value>reason</value>” |
1863
fef4ab2d990c
Removed unnecessary version for "FAILED:reason" in $ssl_client_verify.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1856
diff
changeset
|
210 и, если сертификат не был предоставлен, “<literal>NONE</literal>”. |
1856
7133004fa5b3
$ssl_client_verify extended with a failure reason.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1429
diff
changeset
|
211 <note> |
7133004fa5b3
$ssl_client_verify extended with a failure reason.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1429
diff
changeset
|
212 До версии 1.11.7 результат “<literal>FAILED</literal>” |
7133004fa5b3
$ssl_client_verify extended with a failure reason.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1429
diff
changeset
|
213 не содержал строку <value>reason</value>. |
7133004fa5b3
$ssl_client_verify extended with a failure reason.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1429
diff
changeset
|
214 </note> |
1429
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
215 Если клиентский сертификат был предоставлен, |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
216 информация о нём передаётся в следующих заголовках запроса: |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
217 <header>Auth-SSL-Subject</header>, <header>Auth-SSL-Issuer</header>, |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
218 <header>Auth-SSL-Serial</header> и <header>Auth-SSL-Fingerprint</header>. |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
219 Если директива <link id="auth_http_pass_client_cert"/> включена, |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
220 сам сертификат передаётся в заголовке |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
221 <header>Auth-SSL-Cert</header>. |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
222 Запрос будет выглядеть так: |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
223 <example> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
224 GET /auth HTTP/1.0 |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
225 Host: localhost |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
226 Auth-Method: plain |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
227 Auth-User: user |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
228 Auth-Pass: password |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
229 Auth-Protocol: imap |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
230 Auth-Login-Attempt: 1 |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
231 Client-IP: 192.0.2.42 |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
232 Auth-SSL: on |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
233 Auth-SSL-Verify: SUCCESS |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
234 Auth-SSL-Subject: /CN=example.com |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
235 Auth-SSL-Issuer: /CN=example.com |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
236 Auth-SSL-Serial: C07AD56B846B5BFF |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
237 Auth-SSL-Fingerprint: 29d6a80a123d13355ed16b4b04605e29cb55a5ad |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
238 </example> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
239 </para> |
06322891b4e3
Client certificate directives in mail_ssl_module and associates.
Sergey Kandaurov <pluknet@nginx.com>
parents:
1256
diff
changeset
|
240 |
2676
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
241 <para id="proxy_protocol"> |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
242 При использовании |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
243 <link doc="ngx_mail_core_module.xml" id="proxy_protocol">протокола PROXY</link>, |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
244 информация о нём передаётся в следующих заголовках запроса: |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
245 <header>Proxy-Protocol-Addr</header>, |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
246 <header>Proxy-Protocol-Port</header>, |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
247 <header>Proxy-Protocol-Server-Addr</header> и |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
248 <header>Proxy-Protocol-Server-Port</header> (1.19.8). |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
249 </para> |
468e6e14e5cc
Documented the PROXY protocol support in mail.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
1887
diff
changeset
|
250 |
630
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
251 </section> |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
252 |
a235ce0f8eef
Initial mail proxy server documentation in Russian.
Ruslan Ermilov <ru@nginx.com>
parents:
diff
changeset
|
253 </module> |