Mercurial > hg > nginx-site
annotate xml/en/docs/stream/ngx_stream_ssl_preread_module.xml @ 2204:001f2d905fd9
Documented fileSystem methods in njs.
author | Yaroslav Zhuravlev <yar@nginx.com> |
---|---|
date | Tue, 26 Jun 2018 16:13:07 +0300 |
parents | eca16aa19cfa |
children | da8e5d713962 |
rev | line source |
---|---|
1798
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
1 <?xml version="1.0"?> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
2 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
3 <!-- |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
4 Copyright (C) Nginx, Inc. |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
5 --> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
6 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
7 <!DOCTYPE module SYSTEM "../../../../dtd/module.dtd"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
8 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
9 <module name="Module ngx_stream_ssl_preread_module" |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
10 link="/en/docs/stream/ngx_stream_ssl_preread_module.html" |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
11 lang="en" |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
12 rev="2"> |
1798
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
13 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
14 <section id="summary"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
15 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
16 <para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
17 The <literal>ngx_stream_ssl_preread_module</literal> module (1.11.5) allows |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
18 extracting information from the |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
19 <link url="https://tools.ietf.org/html/rfc5246#section-7.4.1.2">ClientHello</link> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
20 message without terminating SSL/TLS, |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
21 for example, the sever name requested through |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
22 <link url="https://tools.ietf.org/html/rfc6066#section-3">SNI</link> |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
23 or protocols advertised in |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
24 <link url="https://tools.ietf.org/html/rfc7301">ALPN</link>. |
1798
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
25 This module is not built by default, it should be enabled with the |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
26 <literal>--with-stream_ssl_preread_module</literal> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
27 configuration parameter. |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
28 </para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
29 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
30 </section> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
31 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
32 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
33 <section id="example" name="Example Configuration"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
34 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
35 <para> |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
36 Selecting an upstream based on server name: |
1798
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
37 <example> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
38 map $ssl_preread_server_name $name { |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
39 backend.example.com backend; |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
40 default backend2; |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
41 } |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
42 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
43 upstream backend { |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
44 server 192.168.0.1:12345; |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
45 server 192.168.0.2:12345; |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
46 } |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
47 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
48 upstream backend2 { |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
49 server 192.168.0.3:12345; |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
50 server 192.168.0.4:12345; |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
51 } |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
52 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
53 server { |
2116 | 54 listen 12346; |
55 proxy_pass $name; | |
56 ssl_preread on; | |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
57 } |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
58 </example> |
2116 | 59 </para> |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
60 |
2116 | 61 <para> |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
62 Selecting an upstream based on protocol: |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
63 <example> |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
64 map $ssl_preread_alpn_protocols $proxy { |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
65 ~\bh2\b 127.0.0.1:8001; |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
66 ~\bhttp/1.1\b 127.0.0.1:8002; |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
67 ~\bxmpp-client\b 127.0.0.1:8003; |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
68 } |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
69 |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
70 server { |
2116 | 71 listen 9000; |
72 proxy_pass $proxy; | |
73 ssl_preread on; | |
1798
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
74 } |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
75 </example> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
76 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
77 </para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
78 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
79 </section> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
80 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
81 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
82 <section id="directives" name="Directives"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
83 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
84 <directive name="ssl_preread"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
85 <syntax><literal>on</literal> | <literal>off</literal></syntax> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
86 <default>off</default> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
87 <context>stream</context> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
88 <context>server</context> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
89 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
90 <para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
91 Enables extracting information from the ClientHello message at |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
92 the <link doc="stream_processing.xml" id="preread_phase">preread</link> phase. |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
93 </para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
94 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
95 </directive> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
96 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
97 </section> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
98 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
99 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
100 <section id="variables" name="Embedded Variables"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
101 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
102 <para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
103 <list type="tag"> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
104 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
105 <tag-name id="var_ssl_preread_server_name"><var>$ssl_preread_server_name</var></tag-name> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
106 <tag-desc> |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
107 server name requested through SNI |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
108 </tag-desc> |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
109 |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
110 <tag-name id="var_ssl_preread_alpn_protocols"><var>$ssl_preread_alpn_protocols</var></tag-name> |
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
111 <tag-desc> |
2116 | 112 list of protocols advertised by the client through ALPN (1.13.10). |
2112
9f7e12cf974f
Documented the $ssl_preread_alpn_protocols variable.
Vladimir Homutov <vl@nginx.com>
parents:
1798
diff
changeset
|
113 The values are separated by commas. |
1798
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
114 </tag-desc> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
115 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
116 </list> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
117 </para> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
118 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
119 </section> |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
120 |
59d1f512c3a0
Documented the ngx_stream_ssl_preread_module module.
Yaroslav Zhuravlev <yar@nginx.com>
parents:
diff
changeset
|
121 </module> |