annotate xml/en/docs/http/configuring_https_servers.xml @ 661:e1579b244800

SNI: expressed more clearly that passing of literal IP addresses in an SNI is prohibited by RFC, and that one should not rely on a few misbehaving browsers, notably Safari (both desktop and mobile).
author Ruslan Ermilov <ru@nginx.com>
date Thu, 30 Aug 2012 09:43:14 +0000
parents ba45bd0fc71e
children 2ceaef0e84a1
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
580
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 490
diff changeset
1 <!--
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 490
diff changeset
2 Copyright (C) Igor Sysoev
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 490
diff changeset
3 Copyright (C) Nginx, Inc.
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 490
diff changeset
4 -->
be54c443235a Added copyright markers to documentation sources.
Ruslan Ermilov <ru@nginx.com>
parents: 490
diff changeset
5
50
9d544687d02c Fixed DOCTYPE declaration.
Ruslan Ermilov <ru@nginx.com>
parents: 46
diff changeset
6 <!DOCTYPE article SYSTEM "../../../../dtd/article.dtd">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
7
123
7db449e89e92 Unified the use of the "name" attribute instead of "title".
Ruslan Ermilov <ru@nginx.com>
parents: 121
diff changeset
8 <article name="Configuring HTTPS servers"
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
9 link="/en/docs/http/configuring_https_servers.html"
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
10 lang="en"
661
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
11 rev="3"
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
12 author="Igor Sysoev"
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
13 editor="Brian Mercer">
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
14
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
15 <section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
16
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
17 <para>
659
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
18 To configure an HTTPS server, the SSL protocol must be enabled
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
19 in the server block, and the locations of the server certificate
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
20 and private key files should be specified:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
21
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
22 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
23 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
24 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
25 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
26 ssl <b>on</b>;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
27 ssl_certificate <b>www.example.com.crt</b>;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
28 ssl_certificate_key <b>www.example.com.key</b>;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
29 ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
30 ssl_ciphers HIGH:!aNULL:!MD5;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
31 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
32 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
33 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
34
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
35 The server certificate is a public entity.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
36 It is sent to every client that connects to the server.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
37 The private key is a secure entity and should be stored in a file with
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
38 restricted access, however, it must be readable by nginx’s master process.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
39 The private key may alternately be stored in the same file as the certificate:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
40
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
41 <programlisting>
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
42 ssl_certificate www.example.com.cert;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
43 ssl_certificate_key www.example.com.cert;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
44 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
45
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
46 in which case the file access rights should also be restricted.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
47 Although the certificate and the key are stored in one file,
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
48 only the certificate is sent to a client.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
49 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
50
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
51 <para>
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
52 The directives <link doc="ngx_http_ssl_module.xml" id="ssl_protocols"/> and
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
53 <link doc="ngx_http_ssl_module.xml" id="ssl_ciphers"/>
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
54 can be used to limit connections
56
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
55 to include only the strong versions and ciphers of SSL/TLS.
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
56 Since version 1.0.5, nginx uses
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
57 “<literal>ssl_protocols SSLv3 TLSv1</literal>”
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
58 and “<literal>ssl_ciphers HIGH:!aNULL:!MD5</literal>” by default,
56
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
59 so configuring them explicitly only makes sense for the earlier nginx versions.
393
b83d332fbdaa Documented SSL changes in the upcoming 1.0.12 release.
Ruslan Ermilov <ru@nginx.com>
parents: 374
diff changeset
60 Since versions 1.1.13 and 1.0.12, nginx uses
314
95d5dc7c9884 Documented the new "TLSv1.1" and "TLSv1.2" parameters of the
Ruslan Ermilov <ru@nginx.com>
parents: 271
diff changeset
61 “<literal>ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2</literal>” by default.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
62 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
63
56
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
64 <para>
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
65 CBC-mode ciphers might be vulnerable to a number of attacks and to
98
a10bc0cb0a6a Whitespace cleanup.
Ruslan Ermilov <ru@nginx.com>
parents: 59
diff changeset
66 the BEAST attack in particular (see
374
a413dffb0557 Replaced "a href" with "link doc" / "link url".
Ruslan Ermilov <ru@nginx.com>
parents: 314
diff changeset
67 <link url="http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2011-3389">CVE-2011-3389</link>).
56
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
68 Configuration of ciphers can be adjusted to prefer RC4-SHA as the following:
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
69
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
70 <programlisting>
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
71 ssl_ciphers RC4:HIGH:!aNULL:!MD5;
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
72 ssl_prefer_server_ciphers on;
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
73 </programlisting>
59
bd9f103036a0 Put <programlisting> inside <para>.
Ruslan Ermilov <ru@nginx.com>
parents: 56
diff changeset
74 </para>
56
b706454b2ab8 - About RC4-SHA
Andrey Alexeev <andrew@nginx.com>
parents: 50
diff changeset
75
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
76 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
77
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
78
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
79 <section id="optimization" name="HTTPS server optimization">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
80
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
81 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
82 SSL operations consume extra CPU resources.
659
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
83 On multi-processor systems several worker processes should be run,
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
84 no less than the number of available CPU cores.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
85 The most CPU-intensive operation is the SSL handshake.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
86 There are two ways to minimize the number of these operations per client:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
87 the first is by enabling keepalive connections to send several
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
88 requests via one connection and the second is to reuse SSL session
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
89 parameters to avoid SSL handshakes for parallel and subsequent connections.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
90 The sessions are stored in an SSL session cache shared between workers
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
91 and configured by the
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
92 <link doc="ngx_http_ssl_module.xml" id="ssl_session_cache"/>
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
93 directive.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
94 One megabyte of the cache contains about 4000 sessions.
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
95 The default cache timeout is 5 minutes.
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
96 It can be increased by using the
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
97 <link doc="ngx_http_ssl_module.xml" id="ssl_session_timeout"/>
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
98 directive.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
99 Here is a sample configuration optimized for a quad core system
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
100 with 10 megabyte shared session cache:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
101
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
102 <programlisting>
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
103 <b>worker_processes 4</b>;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
104
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
105 http {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
106 <b>ssl_session_cache shared:SSL:10m</b>;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
107 <b>ssl_session_timeout 10m</b>;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
108
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
109 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
110 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
111 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
112 <b>keepalive_timeout 70</b>;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
113
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
114 ssl on;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
115 ssl_certificate www.example.com.crt;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
116 ssl_certificate_key www.example.com.key;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
117 ssl_protocols SSLv3 TLSv1 TLSv1.1 TLSv1.2;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
118 ssl_ciphers HIGH:!aNULL:!MD5;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
119 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
120 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
121 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
122
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
123 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
124
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
125
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
126 <section id="chains" name="SSL certificate chains">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
127
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
128 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
129 Some browsers may complain about a certificate signed by a well-known
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
130 certificate authority, while other browsers may accept the certificate
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
131 without issues.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
132 This occurs because the issuing authority has signed the server certificate
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
133 using an intermediate certificate that is not present in the certificate
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
134 base of well-known trusted certificate authorities which is distributed
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
135 with a particular browser.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
136 In this case the authority provides a bundle of chained certificates
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
137 which should be concatenated to the signed server certificate.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
138 The server certificate must appear before the chained certificates
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
139 in the combined file:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
140
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
141 <programlisting>
490
9913f1d51c07 Replaced "nginx" domain names with example domains.
Ruslan Ermilov <ru@nginx.com>
parents: 461
diff changeset
142 $ cat www.example.com.crt bundle.crt > www.example.com.chained.crt
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
143 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
144
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
145 The resulting file should be used in the
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
146 <link doc="ngx_http_ssl_module.xml" id="ssl_certificate"/> directive:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
147
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
148 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
149 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
150 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
151 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
152 ssl on;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
153 ssl_certificate www.example.com.chained.crt;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
154 ssl_certificate_key www.example.com.key;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
155 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
156 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
157 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
158
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
159 If the server certificate and the bundle have been concatenated in the wrong
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
160 order, nginx will fail to start and will display the error message:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
161
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
162 <programlisting>
490
9913f1d51c07 Replaced "nginx" domain names with example domains.
Ruslan Ermilov <ru@nginx.com>
parents: 461
diff changeset
163 SSL_CTX_use_PrivateKey_file(" ... /www.example.com.key") failed
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
164 (SSL: error:0B080074:x509 certificate routines:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
165 X509_check_private_key:key values mismatch)
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
166 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
167
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
168 because nginx has tried to use the private key with the bundle’s
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
169 first certificate instead of the server certificate.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
170 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
171
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
172 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
173 Browsers usually store intermediate certificates which they receive
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
174 and which are signed by trusted authorities, so actively used browsers
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
175 may already have the required intermediate certificates and
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
176 may not complain about a certificate sent without a chained bundle.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
177 To ensure the server sends the complete certificate chain,
659
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
178 the <command>openssl</command> command-line utility may be used, for example:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
179
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
180 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
181 $ openssl s_client -connect www.godaddy.com:443
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
182 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
183 Certificate chain
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
184 0 s:/C=US/ST=Arizona/L=Scottsdale/1.3.6.1.4.1.311.60.2.1.3=US
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
185 /1.3.6.1.4.1.311.60.2.1.2=AZ/O=GoDaddy.com, Inc
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
186 /OU=MIS Department/<b>CN=www.GoDaddy.com</b>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
187 /serialNumber=0796928-7/2.5.4.15=V1.0, Clause 5.(b)
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
188 i:/C=US/ST=Arizona/L=Scottsdale/O=GoDaddy.com, Inc.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
189 /OU=http://certificates.godaddy.com/repository
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
190 /CN=Go Daddy Secure Certification Authority
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
191 /serialNumber=07969287
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
192 1 s:/C=US/ST=Arizona/L=Scottsdale/O=GoDaddy.com, Inc.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
193 /OU=http://certificates.godaddy.com/repository
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
194 /CN=Go Daddy Secure Certification Authority
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
195 /serialNumber=07969287
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
196 i:/C=US/O=The Go Daddy Group, Inc.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
197 /OU=Go Daddy Class 2 Certification Authority
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
198 2 s:/C=US/O=The Go Daddy Group, Inc.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
199 /OU=Go Daddy Class 2 Certification Authority
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
200 i:/L=ValiCert Validation Network/O=<b>ValiCert, Inc.</b>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
201 /OU=ValiCert Class 2 Policy Validation Authority
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
202 /CN=http://www.valicert.com//emailAddress=info@valicert.com
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
203 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
204 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
205
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
206 In this example the subject (“<i>s</i>”) of the
593
130fad6dc1b4 Replaced the uses of "url" element with "literal".
Ruslan Ermilov <ru@nginx.com>
parents: 589
diff changeset
207 <literal>www.GoDaddy.com</literal> server certificate #0 is signed by an issuer
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
208 (“<i>i</i>”) which itself is the subject of the certificate #1,
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
209 which is signed by an issuer which itself is the subject of the certificate #2,
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
210 which signed by the well-known issuer <i>ValiCert, Inc.</i>
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
211 whose certificate is stored in the browsers’ built-in
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
212 certificate base (that lay in the house that Jack built).
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
213 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
214
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
215 <para>
659
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
216 If a certificate bundle has not been added, only the server certificate #0
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
217 will be shown.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
218 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
219
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
220 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
221
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
222
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
223 <section id="single_http_https_server" name="A single HTTP/HTTPS server">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
224
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
225 <para>
659
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
226 If HTTP and HTTPS servers are equal,
77a3314c74a7 Avoid the uses of second person.
Ruslan Ermilov <ru@nginx.com>
parents: 658
diff changeset
227 a single server that handles both HTTP and HTTPS requests may be configured
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
228 by deleting the directive “<literal>ssl on</literal>”
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
229 and adding the <literal>ssl</literal> parameter for *:443 port:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
230
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
231 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
232 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
233 listen 80;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
234 listen 443 ssl;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
235 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
236 ssl_certificate www.example.com.crt;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
237 ssl_certificate_key www.example.com.key;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
238 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
239 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
240 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
241
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
242 <note>
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
243 Prior to 0.8.21, nginx only allows the <literal>ssl</literal> parameter
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
244 to be set on listen sockets with the <literal>default</literal> parameter:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
245 <programlisting>
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
246 listen 443 default ssl;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
247 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
248 </note>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
249 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
250
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
251 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
252
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
253
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
254 <section id="name_based_https_servers" name="Name-based HTTPS servers">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
255
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
256 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
257 A common issue arises when configuring two or more HTTPS servers
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
258 listening on a single IP address:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
259
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
260 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
261 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
262 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
263 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
264 ssl on;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
265 ssl_certificate www.example.com.crt;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
266 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
267 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
268
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
269 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
270 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
271 server_name www.example.org;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
272 ssl on;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
273 ssl_certificate www.example.org.crt;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
274 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
275 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
276 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
277
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
278 With this configuration a browser receives the default server’s certificate,
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
279 i.e. <literal>www.example.com</literal> regardless of the requested server name.
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
280 This is caused by SSL protocol behaviour.
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
281 The SSL connection is established before the browser sends an HTTP request
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
282 and nginx does not know the name of the requested server.
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
283 Therefore, it may only offer the default server’s certificate.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
284 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
285
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
286 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
287 The oldest and most robust method to resolve the issue
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
288 is to assign a separate IP address for every HTTPS server:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
289
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
290 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
291 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
292 listen 192.168.1.1:443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
293 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
294 ssl on;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
295 ssl_certificate www.example.com.crt;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
296 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
297 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
298
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
299 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
300 listen 192.168.1.2:443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
301 server_name www.example.org;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
302 ssl on;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
303 ssl_certificate www.example.org.crt;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
304 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
305 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
306 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
307 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
308
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
309 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
310
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
311
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
312 <section id="certificate_with_several_names"
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
313 name="An SSL certificate with several names">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
314
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
315 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
316 There are other ways to share a single IP address between several
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
317 HTTPS servers, however, all of them have drawbacks.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
318 One way is to use a certificate with several names in
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
319 the SubjectAltName certificate field, for example,
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
320 <literal>www.example.com</literal> and <literal>www.example.org</literal>.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
321 However, the SubjectAltName field length is limited.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
322 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
323
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
324 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
325 Another way is to use a certificate with a wildcard name, for example,
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
326 <literal>*.example.org</literal>.
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
327 This certificate matches <literal>www.example.org</literal>, but does not match
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
328 <literal>example.org</literal> and <literal>www.sub.example.org</literal>.
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
329 These two methods can also be combined.
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
330 A certificate may contain exact and wildcard names in the
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
331 SubjectAltName field, for example,
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
332 <literal>example.org</literal> and <literal>*.example.org</literal>.
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
333 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
334
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
335 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
336 It is better to place a certificate file with several names and
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
337 its private key file at the <i>http</i> level of configuration
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
338 to inherit their single memory copy in all servers:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
339
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
340 <programlisting>
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
341 ssl_certificate common.crt;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
342 ssl_certificate_key common.key;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
343
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
344 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
345 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
346 server_name www.example.com;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
347 ssl on;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
348 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
349 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
350
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
351 server {
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
352 listen 443;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
353 server_name www.example.org;
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
354 ssl on;
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
355 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
356 }
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
357 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
358 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
359
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
360 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
361
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
362
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
363 <section id="sni" name="Server Name Indication">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
364
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
365 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
366 A more generic solution for running several HTTPS servers on a single
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
367 IP address is
661
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
368 <link url="http://en.wikipedia.org/wiki/Server_Name_Indication">TLS
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
369 Server Name Indication extension</link> (SNI, RFC 6066),
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
370 which allows a browser to pass a requested server name during the SSL handshake
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
371 and, therefore, the server will know which certificate it should use
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
372 for the connection.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
373 However, SNI has limited browser support.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
374 Currently it is supported starting with the following browsers versions:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
375 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
376
658
bd81a71006fe Documented that most browsers won't pass an IP address
Ruslan Ermilov <ru@nginx.com>
parents: 593
diff changeset
377 <para>
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
378 <list type="bullet">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
379
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
380 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
381 Opera 8.0;
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
382 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
383
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
384 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
385 MSIE 7.0 (but only on Windows Vista or higher);
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
386 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
387
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
388 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
389 Firefox 2.0 and other browsers using Mozilla Platform rv:1.8.1;
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
390 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
391
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
392 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
393 Safari 3.2.1 (Windows version supports SNI on Vista or higher);
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
394 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
395
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
396 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
397 and Chrome (Windows version supports SNI on Vista or higher, too).
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
398 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
399
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
400 </list>
658
bd81a71006fe Documented that most browsers won't pass an IP address
Ruslan Ermilov <ru@nginx.com>
parents: 593
diff changeset
401 <note>
661
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
402 Only domain names can be passed in SNI,
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
403 however some browsers may erroneously pass an IP address of the server
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
404 as its name if a request includes literal IP address.
e1579b244800 SNI: expressed more clearly that passing of literal IP addresses in
Ruslan Ermilov <ru@nginx.com>
parents: 660
diff changeset
405 One should not rely on this.
658
bd81a71006fe Documented that most browsers won't pass an IP address
Ruslan Ermilov <ru@nginx.com>
parents: 593
diff changeset
406 </note>
bd81a71006fe Documented that most browsers won't pass an IP address
Ruslan Ermilov <ru@nginx.com>
parents: 593
diff changeset
407 </para>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
408
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
409 <para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
410 In order to use SNI in nginx, it must be supported in both the
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
411 OpenSSL library with which the nginx binary has been built as well as
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
412 the library to which it is being dynamically linked at run time.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
413 OpenSSL supports SNI since 0.9.8f version if it was built with config option
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
414 <nobr>“--enable-tlsext”.</nobr>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
415 Since OpenSSL 0.9.8j this option is enabled by default.
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
416 If nginx was built with SNI support, then nginx will show this
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
417 when run with the “-V” switch:
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
418
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
419 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
420 $ nginx -V
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
421 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
422 TLS SNI support enabled
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
423 ...
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
424 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
425
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
426 However, if the SNI-enabled nginx is linked dynamically to
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
427 an OpenSSL library without SNI support, nginx displays the warning:
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
428
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
429 <programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
430 nginx was built with SNI support, however, now it is linked
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
431 dynamically to an OpenSSL library which has no tlsext support,
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
432 therefore SNI is not available
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
433 </programlisting>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
434 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
435
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
436 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
437
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
438
121
49443032011c Unified <section> syntax for "article" and "module" documents.
Ruslan Ermilov <ru@nginx.com>
parents: 98
diff changeset
439 <section id="compatibility" name="Compatibility">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
440
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
441 <para>
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
442 <list type="bullet">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
443
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
444 <listitem>
660
ba45bd0fc71e configuring_https_servers: markup changes (mostly).
Ruslan Ermilov <ru@nginx.com>
parents: 659
diff changeset
445 The SNI support status has been shown by the “-V” switch
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
446 since 0.8.21 and 0.7.62.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
447 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
448
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
449 <listitem>
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
450 The <literal>ssl</literal> parameter of the
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
451 <link doc="ngx_http_core_module.xml" id="listen"/>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
452 directive has been supported since 0.7.14.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
453 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
454
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
455 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
456 SNI has been supported since 0.5.32.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
457 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
458
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
459 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
460 The shared SSL session cache has been supported since 0.5.6.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
461 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
462
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
463 </list>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
464 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
465
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
466 <para>
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
467 <list type="bullet">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
468
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
469 <listitem>
314
95d5dc7c9884 Documented the new "TLSv1.1" and "TLSv1.2" parameters of the
Ruslan Ermilov <ru@nginx.com>
parents: 271
diff changeset
470 Version 0.7.65, 0.8.19 and later: the default SSL protocols are SSLv3, TLSv1,
95d5dc7c9884 Documented the new "TLSv1.1" and "TLSv1.2" parameters of the
Ruslan Ermilov <ru@nginx.com>
parents: 271
diff changeset
471 TLSv1.1, and TLSv1.2 (if supported by the OpenSSL library).
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
472 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
473
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
474 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
475 Version 0.7.64, 0.8.18 and earlier: the default SSL protocols are SSLv2,
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
476 SSLv3, and TLSv1.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
477 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
478
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
479 </list>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
480 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
481
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
482 <para>
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
483 <list type="bullet">
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
484
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
485 <listitem>
43
662995d3e647 Update of SSL ciphers in latest nginx versions.
Igor Sysoev <igor@sysoev.ru>
parents: 42
diff changeset
486 Version 1.0.5 and later: the default SSL ciphers are
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
487 “<literal>HIGH:!aNULL:!MD5</literal>”.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
488 </listitem>
43
662995d3e647 Update of SSL ciphers in latest nginx versions.
Igor Sysoev <igor@sysoev.ru>
parents: 42
diff changeset
489
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
490 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
491 Version 0.7.65, 0.8.20 and later: the default SSL ciphers are
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
492 “<literal>HIGH:!ADH:!MD5</literal>”.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
493 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
494
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
495 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
496 Version 0.8.19: the default SSL ciphers are
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
497 “<literal>ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM</literal>”.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
498 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
499
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
500 <listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
501 Version 0.7.64, 0.8.18 and earlier: the default SSL ciphers are<br/>
271
4c6d2c614d2c Cleaned up XML tag mess:
Ruslan Ermilov <ru@nginx.com>
parents: 266
diff changeset
502 “<literal>ALL:!ADH:RC4+RSA:+HIGH:+MEDIUM:+LOW:+SSLv2:+EXP</literal>”.
461
6135f3c95bf6 Unified markup for lists.
Ruslan Ermilov <ru@nginx.com>
parents: 393
diff changeset
503 </listitem>
0
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
504
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
505 </list>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
506 </para>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
507
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
508
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
509 </section>
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
510
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
511
61e04fc01027 Initial import of the nginx.org website.
Ruslan Ermilov <ru@nginx.com>
parents:
diff changeset
512 </article>