SSL test framework: port NPN and ALPN tests
[openssl.git] / test / ssl-tests / 09-alpn.conf
1 # Generated with generate_ssl_tests.pl
2
3 num_tests = 10
4
5 test-0 = 0-alpn-simple
6 test-1 = 1-alpn-client-finds-match
7 test-2 = 2-alpn-client-honours-server-pref
8 test-3 = 3-alpn-alert-on-mismatch
9 test-4 = 4-alpn-no-server-support
10 test-5 = 5-alpn-no-client-support
11 test-6 = 6-alpn-with-sni-no-context-switch
12 test-7 = 7-alpn-with-sni-context-switch
13 test-8 = 8-alpn-selected-sni-server-supports-alpn
14 test-9 = 9-alpn-selected-sni-server-does-not-support-alpn
15 # ===========================================================
16
17 [0-alpn-simple]
18 ssl_conf = 0-alpn-simple-ssl
19
20 [0-alpn-simple-ssl]
21 server = 0-alpn-simple-server
22 client = 0-alpn-simple-client
23
24 [0-alpn-simple-server]
25 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
26 CipherString = DEFAULT
27 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
28
29 [0-alpn-simple-client]
30 CipherString = DEFAULT
31 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
32 VerifyMode = Peer
33
34 [test-0]
35 ClientALPNProtocols = foo
36 ExpectedALPNProtocol = foo
37 ServerALPNProtocols = foo
38
39
40 # ===========================================================
41
42 [1-alpn-client-finds-match]
43 ssl_conf = 1-alpn-client-finds-match-ssl
44
45 [1-alpn-client-finds-match-ssl]
46 server = 1-alpn-client-finds-match-server
47 client = 1-alpn-client-finds-match-client
48
49 [1-alpn-client-finds-match-server]
50 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
51 CipherString = DEFAULT
52 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
53
54 [1-alpn-client-finds-match-client]
55 CipherString = DEFAULT
56 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
57 VerifyMode = Peer
58
59 [test-1]
60 ClientALPNProtocols = foo,bar
61 ExpectedALPNProtocol = bar
62 ServerALPNProtocols = baz,bar
63
64
65 # ===========================================================
66
67 [2-alpn-client-honours-server-pref]
68 ssl_conf = 2-alpn-client-honours-server-pref-ssl
69
70 [2-alpn-client-honours-server-pref-ssl]
71 server = 2-alpn-client-honours-server-pref-server
72 client = 2-alpn-client-honours-server-pref-client
73
74 [2-alpn-client-honours-server-pref-server]
75 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
76 CipherString = DEFAULT
77 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
78
79 [2-alpn-client-honours-server-pref-client]
80 CipherString = DEFAULT
81 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
82 VerifyMode = Peer
83
84 [test-2]
85 ClientALPNProtocols = foo,bar
86 ExpectedALPNProtocol = bar
87 ServerALPNProtocols = bar,foo
88
89
90 # ===========================================================
91
92 [3-alpn-alert-on-mismatch]
93 ssl_conf = 3-alpn-alert-on-mismatch-ssl
94
95 [3-alpn-alert-on-mismatch-ssl]
96 server = 3-alpn-alert-on-mismatch-server
97 client = 3-alpn-alert-on-mismatch-client
98
99 [3-alpn-alert-on-mismatch-server]
100 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
101 CipherString = DEFAULT
102 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
103
104 [3-alpn-alert-on-mismatch-client]
105 CipherString = DEFAULT
106 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
107 VerifyMode = Peer
108
109 [test-3]
110 ClientALPNProtocols = foo,bar
111 ExpectedResult = ServerFail
112 ServerALPNProtocols = baz
113 ServerAlert = NoApplicationProtocol
114
115
116 # ===========================================================
117
118 [4-alpn-no-server-support]
119 ssl_conf = 4-alpn-no-server-support-ssl
120
121 [4-alpn-no-server-support-ssl]
122 server = 4-alpn-no-server-support-server
123 client = 4-alpn-no-server-support-client
124
125 [4-alpn-no-server-support-server]
126 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
127 CipherString = DEFAULT
128 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
129
130 [4-alpn-no-server-support-client]
131 CipherString = DEFAULT
132 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
133 VerifyMode = Peer
134
135 [test-4]
136 ClientALPNProtocols = foo
137
138
139 # ===========================================================
140
141 [5-alpn-no-client-support]
142 ssl_conf = 5-alpn-no-client-support-ssl
143
144 [5-alpn-no-client-support-ssl]
145 server = 5-alpn-no-client-support-server
146 client = 5-alpn-no-client-support-client
147
148 [5-alpn-no-client-support-server]
149 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
150 CipherString = DEFAULT
151 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
152
153 [5-alpn-no-client-support-client]
154 CipherString = DEFAULT
155 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
156 VerifyMode = Peer
157
158 [test-5]
159 ServerALPNProtocols = foo
160
161
162 # ===========================================================
163
164 [6-alpn-with-sni-no-context-switch]
165 ssl_conf = 6-alpn-with-sni-no-context-switch-ssl
166
167 [6-alpn-with-sni-no-context-switch-ssl]
168 server = 6-alpn-with-sni-no-context-switch-server
169 server2 = 6-alpn-with-sni-no-context-switch-server2
170 client = 6-alpn-with-sni-no-context-switch-client
171
172 [6-alpn-with-sni-no-context-switch-server]
173 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
174 CipherString = DEFAULT
175 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
176
177 [6-alpn-with-sni-no-context-switch-server2]
178 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
179 CipherString = DEFAULT
180 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
181
182 [6-alpn-with-sni-no-context-switch-client]
183 CipherString = DEFAULT
184 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
185 VerifyMode = Peer
186
187 [test-6]
188 ClientALPNProtocols = foo,bar
189 ExpectedALPNProtocol = foo
190 ExpectedServerName = server1
191 Server2ALPNProtocols = bar
192 ServerALPNProtocols = foo
193 ServerName = server1
194 ServerNameCallback = IgnoreMismatch
195
196
197 # ===========================================================
198
199 [7-alpn-with-sni-context-switch]
200 ssl_conf = 7-alpn-with-sni-context-switch-ssl
201
202 [7-alpn-with-sni-context-switch-ssl]
203 server = 7-alpn-with-sni-context-switch-server
204 server2 = 7-alpn-with-sni-context-switch-server2
205 client = 7-alpn-with-sni-context-switch-client
206
207 [7-alpn-with-sni-context-switch-server]
208 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
209 CipherString = DEFAULT
210 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
211
212 [7-alpn-with-sni-context-switch-server2]
213 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
214 CipherString = DEFAULT
215 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
216
217 [7-alpn-with-sni-context-switch-client]
218 CipherString = DEFAULT
219 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
220 VerifyMode = Peer
221
222 [test-7]
223 ClientALPNProtocols = foo,bar
224 ExpectedALPNProtocol = bar
225 ExpectedServerName = server2
226 Server2ALPNProtocols = bar
227 ServerALPNProtocols = foo
228 ServerName = server2
229 ServerNameCallback = IgnoreMismatch
230
231
232 # ===========================================================
233
234 [8-alpn-selected-sni-server-supports-alpn]
235 ssl_conf = 8-alpn-selected-sni-server-supports-alpn-ssl
236
237 [8-alpn-selected-sni-server-supports-alpn-ssl]
238 server = 8-alpn-selected-sni-server-supports-alpn-server
239 server2 = 8-alpn-selected-sni-server-supports-alpn-server2
240 client = 8-alpn-selected-sni-server-supports-alpn-client
241
242 [8-alpn-selected-sni-server-supports-alpn-server]
243 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
244 CipherString = DEFAULT
245 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
246
247 [8-alpn-selected-sni-server-supports-alpn-server2]
248 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
249 CipherString = DEFAULT
250 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
251
252 [8-alpn-selected-sni-server-supports-alpn-client]
253 CipherString = DEFAULT
254 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
255 VerifyMode = Peer
256
257 [test-8]
258 ClientALPNProtocols = foo,bar
259 ExpectedALPNProtocol = bar
260 ExpectedServerName = server2
261 Server2ALPNProtocols = bar
262 ServerName = server2
263 ServerNameCallback = IgnoreMismatch
264
265
266 # ===========================================================
267
268 [9-alpn-selected-sni-server-does-not-support-alpn]
269 ssl_conf = 9-alpn-selected-sni-server-does-not-support-alpn-ssl
270
271 [9-alpn-selected-sni-server-does-not-support-alpn-ssl]
272 server = 9-alpn-selected-sni-server-does-not-support-alpn-server
273 server2 = 9-alpn-selected-sni-server-does-not-support-alpn-server2
274 client = 9-alpn-selected-sni-server-does-not-support-alpn-client
275
276 [9-alpn-selected-sni-server-does-not-support-alpn-server]
277 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
278 CipherString = DEFAULT
279 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
280
281 [9-alpn-selected-sni-server-does-not-support-alpn-server2]
282 Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem
283 CipherString = DEFAULT
284 PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem
285
286 [9-alpn-selected-sni-server-does-not-support-alpn-client]
287 CipherString = DEFAULT
288 VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem
289 VerifyMode = Peer
290
291 [test-9]
292 ClientALPNProtocols = foo,bar
293 ExpectedServerName = server2
294 ServerALPNProtocols = foo
295 ServerName = server2
296 ServerNameCallback = IgnoreMismatch
297
298