1# Generated with generate_ssl_tests.pl 2 3num_tests = 16 4 5test-0 = 0-alpn-simple 6test-1 = 1-alpn-server-finds-match 7test-2 = 2-alpn-server-honours-server-pref 8test-3 = 3-alpn-alert-on-mismatch 9test-4 = 4-alpn-no-server-support 10test-5 = 5-alpn-no-client-support 11test-6 = 6-alpn-with-sni-no-context-switch 12test-7 = 7-alpn-with-sni-context-switch 13test-8 = 8-alpn-selected-sni-server-supports-alpn 14test-9 = 9-alpn-selected-sni-server-does-not-support-alpn 15test-10 = 10-alpn-simple-resumption 16test-11 = 11-alpn-server-switch-resumption 17test-12 = 12-alpn-client-switch-resumption 18test-13 = 13-alpn-alert-on-mismatch-resumption 19test-14 = 14-alpn-no-server-support-resumption 20test-15 = 15-alpn-no-client-support-resumption 21# =========================================================== 22 23[0-alpn-simple] 24ssl_conf = 0-alpn-simple-ssl 25 26[0-alpn-simple-ssl] 27server = 0-alpn-simple-server 28client = 0-alpn-simple-client 29 30[0-alpn-simple-server] 31Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 32CipherString = DEFAULT 33PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 34 35[0-alpn-simple-client] 36CipherString = DEFAULT 37VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 38VerifyMode = Peer 39 40[test-0] 41ExpectedALPNProtocol = foo 42server = 0-alpn-simple-server-extra 43client = 0-alpn-simple-client-extra 44 45[0-alpn-simple-server-extra] 46ALPNProtocols = foo 47 48[0-alpn-simple-client-extra] 49ALPNProtocols = foo 50 51 52# =========================================================== 53 54[1-alpn-server-finds-match] 55ssl_conf = 1-alpn-server-finds-match-ssl 56 57[1-alpn-server-finds-match-ssl] 58server = 1-alpn-server-finds-match-server 59client = 1-alpn-server-finds-match-client 60 61[1-alpn-server-finds-match-server] 62Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 63CipherString = DEFAULT 64PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 65 66[1-alpn-server-finds-match-client] 67CipherString = DEFAULT 68VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 69VerifyMode = Peer 70 71[test-1] 72ExpectedALPNProtocol = bar 73server = 1-alpn-server-finds-match-server-extra 74client = 1-alpn-server-finds-match-client-extra 75 76[1-alpn-server-finds-match-server-extra] 77ALPNProtocols = baz,bar 78 79[1-alpn-server-finds-match-client-extra] 80ALPNProtocols = foo,bar 81 82 83# =========================================================== 84 85[2-alpn-server-honours-server-pref] 86ssl_conf = 2-alpn-server-honours-server-pref-ssl 87 88[2-alpn-server-honours-server-pref-ssl] 89server = 2-alpn-server-honours-server-pref-server 90client = 2-alpn-server-honours-server-pref-client 91 92[2-alpn-server-honours-server-pref-server] 93Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 94CipherString = DEFAULT 95PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 96 97[2-alpn-server-honours-server-pref-client] 98CipherString = DEFAULT 99VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 100VerifyMode = Peer 101 102[test-2] 103ExpectedALPNProtocol = bar 104server = 2-alpn-server-honours-server-pref-server-extra 105client = 2-alpn-server-honours-server-pref-client-extra 106 107[2-alpn-server-honours-server-pref-server-extra] 108ALPNProtocols = bar,foo 109 110[2-alpn-server-honours-server-pref-client-extra] 111ALPNProtocols = foo,bar 112 113 114# =========================================================== 115 116[3-alpn-alert-on-mismatch] 117ssl_conf = 3-alpn-alert-on-mismatch-ssl 118 119[3-alpn-alert-on-mismatch-ssl] 120server = 3-alpn-alert-on-mismatch-server 121client = 3-alpn-alert-on-mismatch-client 122 123[3-alpn-alert-on-mismatch-server] 124Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 125CipherString = DEFAULT 126PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 127 128[3-alpn-alert-on-mismatch-client] 129CipherString = DEFAULT 130VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 131VerifyMode = Peer 132 133[test-3] 134ExpectedResult = ServerFail 135ExpectedServerAlert = NoApplicationProtocol 136server = 3-alpn-alert-on-mismatch-server-extra 137client = 3-alpn-alert-on-mismatch-client-extra 138 139[3-alpn-alert-on-mismatch-server-extra] 140ALPNProtocols = baz 141 142[3-alpn-alert-on-mismatch-client-extra] 143ALPNProtocols = foo,bar 144 145 146# =========================================================== 147 148[4-alpn-no-server-support] 149ssl_conf = 4-alpn-no-server-support-ssl 150 151[4-alpn-no-server-support-ssl] 152server = 4-alpn-no-server-support-server 153client = 4-alpn-no-server-support-client 154 155[4-alpn-no-server-support-server] 156Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 157CipherString = DEFAULT 158PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 159 160[4-alpn-no-server-support-client] 161CipherString = DEFAULT 162VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 163VerifyMode = Peer 164 165[test-4] 166client = 4-alpn-no-server-support-client-extra 167 168[4-alpn-no-server-support-client-extra] 169ALPNProtocols = foo 170 171 172# =========================================================== 173 174[5-alpn-no-client-support] 175ssl_conf = 5-alpn-no-client-support-ssl 176 177[5-alpn-no-client-support-ssl] 178server = 5-alpn-no-client-support-server 179client = 5-alpn-no-client-support-client 180 181[5-alpn-no-client-support-server] 182Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 183CipherString = DEFAULT 184PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 185 186[5-alpn-no-client-support-client] 187CipherString = DEFAULT 188VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 189VerifyMode = Peer 190 191[test-5] 192server = 5-alpn-no-client-support-server-extra 193 194[5-alpn-no-client-support-server-extra] 195ALPNProtocols = foo 196 197 198# =========================================================== 199 200[6-alpn-with-sni-no-context-switch] 201ssl_conf = 6-alpn-with-sni-no-context-switch-ssl 202 203[6-alpn-with-sni-no-context-switch-ssl] 204server = 6-alpn-with-sni-no-context-switch-server 205client = 6-alpn-with-sni-no-context-switch-client 206server2 = 6-alpn-with-sni-no-context-switch-server2 207 208[6-alpn-with-sni-no-context-switch-server] 209Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 210CipherString = DEFAULT 211PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 212 213[6-alpn-with-sni-no-context-switch-server2] 214Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 215CipherString = DEFAULT 216PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 217 218[6-alpn-with-sni-no-context-switch-client] 219CipherString = DEFAULT 220VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 221VerifyMode = Peer 222 223[test-6] 224ExpectedALPNProtocol = foo 225ExpectedServerName = server1 226server = 6-alpn-with-sni-no-context-switch-server-extra 227server2 = 6-alpn-with-sni-no-context-switch-server2-extra 228client = 6-alpn-with-sni-no-context-switch-client-extra 229 230[6-alpn-with-sni-no-context-switch-server-extra] 231ALPNProtocols = foo 232ServerNameCallback = IgnoreMismatch 233 234[6-alpn-with-sni-no-context-switch-server2-extra] 235ALPNProtocols = bar 236 237[6-alpn-with-sni-no-context-switch-client-extra] 238ALPNProtocols = foo,bar 239ServerName = server1 240 241 242# =========================================================== 243 244[7-alpn-with-sni-context-switch] 245ssl_conf = 7-alpn-with-sni-context-switch-ssl 246 247[7-alpn-with-sni-context-switch-ssl] 248server = 7-alpn-with-sni-context-switch-server 249client = 7-alpn-with-sni-context-switch-client 250server2 = 7-alpn-with-sni-context-switch-server2 251 252[7-alpn-with-sni-context-switch-server] 253Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 254CipherString = DEFAULT 255PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 256 257[7-alpn-with-sni-context-switch-server2] 258Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 259CipherString = DEFAULT 260PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 261 262[7-alpn-with-sni-context-switch-client] 263CipherString = DEFAULT 264VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 265VerifyMode = Peer 266 267[test-7] 268ExpectedALPNProtocol = bar 269ExpectedServerName = server2 270server = 7-alpn-with-sni-context-switch-server-extra 271server2 = 7-alpn-with-sni-context-switch-server2-extra 272client = 7-alpn-with-sni-context-switch-client-extra 273 274[7-alpn-with-sni-context-switch-server-extra] 275ALPNProtocols = foo 276ServerNameCallback = IgnoreMismatch 277 278[7-alpn-with-sni-context-switch-server2-extra] 279ALPNProtocols = bar 280 281[7-alpn-with-sni-context-switch-client-extra] 282ALPNProtocols = foo,bar 283ServerName = server2 284 285 286# =========================================================== 287 288[8-alpn-selected-sni-server-supports-alpn] 289ssl_conf = 8-alpn-selected-sni-server-supports-alpn-ssl 290 291[8-alpn-selected-sni-server-supports-alpn-ssl] 292server = 8-alpn-selected-sni-server-supports-alpn-server 293client = 8-alpn-selected-sni-server-supports-alpn-client 294server2 = 8-alpn-selected-sni-server-supports-alpn-server2 295 296[8-alpn-selected-sni-server-supports-alpn-server] 297Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 298CipherString = DEFAULT 299PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 300 301[8-alpn-selected-sni-server-supports-alpn-server2] 302Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 303CipherString = DEFAULT 304PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 305 306[8-alpn-selected-sni-server-supports-alpn-client] 307CipherString = DEFAULT 308VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 309VerifyMode = Peer 310 311[test-8] 312ExpectedALPNProtocol = bar 313ExpectedServerName = server2 314server = 8-alpn-selected-sni-server-supports-alpn-server-extra 315server2 = 8-alpn-selected-sni-server-supports-alpn-server2-extra 316client = 8-alpn-selected-sni-server-supports-alpn-client-extra 317 318[8-alpn-selected-sni-server-supports-alpn-server-extra] 319ServerNameCallback = IgnoreMismatch 320 321[8-alpn-selected-sni-server-supports-alpn-server2-extra] 322ALPNProtocols = bar 323 324[8-alpn-selected-sni-server-supports-alpn-client-extra] 325ALPNProtocols = foo,bar 326ServerName = server2 327 328 329# =========================================================== 330 331[9-alpn-selected-sni-server-does-not-support-alpn] 332ssl_conf = 9-alpn-selected-sni-server-does-not-support-alpn-ssl 333 334[9-alpn-selected-sni-server-does-not-support-alpn-ssl] 335server = 9-alpn-selected-sni-server-does-not-support-alpn-server 336client = 9-alpn-selected-sni-server-does-not-support-alpn-client 337server2 = 9-alpn-selected-sni-server-does-not-support-alpn-server2 338 339[9-alpn-selected-sni-server-does-not-support-alpn-server] 340Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 341CipherString = DEFAULT 342PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 343 344[9-alpn-selected-sni-server-does-not-support-alpn-server2] 345Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 346CipherString = DEFAULT 347PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 348 349[9-alpn-selected-sni-server-does-not-support-alpn-client] 350CipherString = DEFAULT 351VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 352VerifyMode = Peer 353 354[test-9] 355ExpectedServerName = server2 356server = 9-alpn-selected-sni-server-does-not-support-alpn-server-extra 357client = 9-alpn-selected-sni-server-does-not-support-alpn-client-extra 358 359[9-alpn-selected-sni-server-does-not-support-alpn-server-extra] 360ALPNProtocols = bar 361ServerNameCallback = IgnoreMismatch 362 363[9-alpn-selected-sni-server-does-not-support-alpn-client-extra] 364ALPNProtocols = foo,bar 365ServerName = server2 366 367 368# =========================================================== 369 370[10-alpn-simple-resumption] 371ssl_conf = 10-alpn-simple-resumption-ssl 372 373[10-alpn-simple-resumption-ssl] 374server = 10-alpn-simple-resumption-server 375client = 10-alpn-simple-resumption-client 376resume-server = 10-alpn-simple-resumption-server 377resume-client = 10-alpn-simple-resumption-client 378 379[10-alpn-simple-resumption-server] 380Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 381CipherString = DEFAULT 382PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 383 384[10-alpn-simple-resumption-client] 385CipherString = DEFAULT 386VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 387VerifyMode = Peer 388 389[test-10] 390ExpectedALPNProtocol = foo 391HandshakeMode = Resume 392ResumptionExpected = Yes 393server = 10-alpn-simple-resumption-server-extra 394resume-server = 10-alpn-simple-resumption-server-extra 395client = 10-alpn-simple-resumption-client-extra 396resume-client = 10-alpn-simple-resumption-client-extra 397 398[10-alpn-simple-resumption-server-extra] 399ALPNProtocols = foo 400 401[10-alpn-simple-resumption-client-extra] 402ALPNProtocols = foo 403 404 405# =========================================================== 406 407[11-alpn-server-switch-resumption] 408ssl_conf = 11-alpn-server-switch-resumption-ssl 409 410[11-alpn-server-switch-resumption-ssl] 411server = 11-alpn-server-switch-resumption-server 412client = 11-alpn-server-switch-resumption-client 413resume-server = 11-alpn-server-switch-resumption-resume-server 414resume-client = 11-alpn-server-switch-resumption-client 415 416[11-alpn-server-switch-resumption-server] 417Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 418CipherString = DEFAULT 419PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 420 421[11-alpn-server-switch-resumption-resume-server] 422Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 423CipherString = DEFAULT 424PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 425 426[11-alpn-server-switch-resumption-client] 427CipherString = DEFAULT 428VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 429VerifyMode = Peer 430 431[test-11] 432ExpectedALPNProtocol = baz 433HandshakeMode = Resume 434ResumptionExpected = Yes 435server = 11-alpn-server-switch-resumption-server-extra 436resume-server = 11-alpn-server-switch-resumption-resume-server-extra 437client = 11-alpn-server-switch-resumption-client-extra 438resume-client = 11-alpn-server-switch-resumption-client-extra 439 440[11-alpn-server-switch-resumption-server-extra] 441ALPNProtocols = bar,foo 442 443[11-alpn-server-switch-resumption-resume-server-extra] 444ALPNProtocols = baz,foo 445 446[11-alpn-server-switch-resumption-client-extra] 447ALPNProtocols = foo,bar,baz 448 449 450# =========================================================== 451 452[12-alpn-client-switch-resumption] 453ssl_conf = 12-alpn-client-switch-resumption-ssl 454 455[12-alpn-client-switch-resumption-ssl] 456server = 12-alpn-client-switch-resumption-server 457client = 12-alpn-client-switch-resumption-client 458resume-server = 12-alpn-client-switch-resumption-server 459resume-client = 12-alpn-client-switch-resumption-resume-client 460 461[12-alpn-client-switch-resumption-server] 462Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 463CipherString = DEFAULT 464PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 465 466[12-alpn-client-switch-resumption-client] 467CipherString = DEFAULT 468VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 469VerifyMode = Peer 470 471[12-alpn-client-switch-resumption-resume-client] 472CipherString = DEFAULT 473VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 474VerifyMode = Peer 475 476[test-12] 477ExpectedALPNProtocol = bar 478HandshakeMode = Resume 479ResumptionExpected = Yes 480server = 12-alpn-client-switch-resumption-server-extra 481resume-server = 12-alpn-client-switch-resumption-server-extra 482client = 12-alpn-client-switch-resumption-client-extra 483resume-client = 12-alpn-client-switch-resumption-resume-client-extra 484 485[12-alpn-client-switch-resumption-server-extra] 486ALPNProtocols = foo,bar,baz 487 488[12-alpn-client-switch-resumption-client-extra] 489ALPNProtocols = foo,baz 490 491[12-alpn-client-switch-resumption-resume-client-extra] 492ALPNProtocols = bar,baz 493 494 495# =========================================================== 496 497[13-alpn-alert-on-mismatch-resumption] 498ssl_conf = 13-alpn-alert-on-mismatch-resumption-ssl 499 500[13-alpn-alert-on-mismatch-resumption-ssl] 501server = 13-alpn-alert-on-mismatch-resumption-server 502client = 13-alpn-alert-on-mismatch-resumption-client 503resume-server = 13-alpn-alert-on-mismatch-resumption-resume-server 504resume-client = 13-alpn-alert-on-mismatch-resumption-client 505 506[13-alpn-alert-on-mismatch-resumption-server] 507Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 508CipherString = DEFAULT 509PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 510 511[13-alpn-alert-on-mismatch-resumption-resume-server] 512Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 513CipherString = DEFAULT 514PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 515 516[13-alpn-alert-on-mismatch-resumption-client] 517CipherString = DEFAULT 518VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 519VerifyMode = Peer 520 521[test-13] 522ExpectedResult = ServerFail 523ExpectedServerAlert = NoApplicationProtocol 524HandshakeMode = Resume 525server = 13-alpn-alert-on-mismatch-resumption-server-extra 526resume-server = 13-alpn-alert-on-mismatch-resumption-resume-server-extra 527client = 13-alpn-alert-on-mismatch-resumption-client-extra 528resume-client = 13-alpn-alert-on-mismatch-resumption-client-extra 529 530[13-alpn-alert-on-mismatch-resumption-server-extra] 531ALPNProtocols = bar 532 533[13-alpn-alert-on-mismatch-resumption-resume-server-extra] 534ALPNProtocols = baz 535 536[13-alpn-alert-on-mismatch-resumption-client-extra] 537ALPNProtocols = foo,bar 538 539 540# =========================================================== 541 542[14-alpn-no-server-support-resumption] 543ssl_conf = 14-alpn-no-server-support-resumption-ssl 544 545[14-alpn-no-server-support-resumption-ssl] 546server = 14-alpn-no-server-support-resumption-server 547client = 14-alpn-no-server-support-resumption-client 548resume-server = 14-alpn-no-server-support-resumption-resume-server 549resume-client = 14-alpn-no-server-support-resumption-client 550 551[14-alpn-no-server-support-resumption-server] 552Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 553CipherString = DEFAULT 554PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 555 556[14-alpn-no-server-support-resumption-resume-server] 557Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 558CipherString = DEFAULT 559PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 560 561[14-alpn-no-server-support-resumption-client] 562CipherString = DEFAULT 563VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 564VerifyMode = Peer 565 566[test-14] 567HandshakeMode = Resume 568ResumptionExpected = Yes 569server = 14-alpn-no-server-support-resumption-server-extra 570client = 14-alpn-no-server-support-resumption-client-extra 571resume-client = 14-alpn-no-server-support-resumption-client-extra 572 573[14-alpn-no-server-support-resumption-server-extra] 574ALPNProtocols = foo 575 576[14-alpn-no-server-support-resumption-client-extra] 577ALPNProtocols = foo 578 579 580# =========================================================== 581 582[15-alpn-no-client-support-resumption] 583ssl_conf = 15-alpn-no-client-support-resumption-ssl 584 585[15-alpn-no-client-support-resumption-ssl] 586server = 15-alpn-no-client-support-resumption-server 587client = 15-alpn-no-client-support-resumption-client 588resume-server = 15-alpn-no-client-support-resumption-server 589resume-client = 15-alpn-no-client-support-resumption-resume-client 590 591[15-alpn-no-client-support-resumption-server] 592Certificate = ${ENV::TEST_CERTS_DIR}/servercert.pem 593CipherString = DEFAULT 594PrivateKey = ${ENV::TEST_CERTS_DIR}/serverkey.pem 595 596[15-alpn-no-client-support-resumption-client] 597CipherString = DEFAULT 598VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 599VerifyMode = Peer 600 601[15-alpn-no-client-support-resumption-resume-client] 602CipherString = DEFAULT 603VerifyCAFile = ${ENV::TEST_CERTS_DIR}/rootcert.pem 604VerifyMode = Peer 605 606[test-15] 607HandshakeMode = Resume 608ResumptionExpected = Yes 609server = 15-alpn-no-client-support-resumption-server-extra 610resume-server = 15-alpn-no-client-support-resumption-server-extra 611client = 15-alpn-no-client-support-resumption-client-extra 612 613[15-alpn-no-client-support-resumption-server-extra] 614ALPNProtocols = foo 615 616[15-alpn-no-client-support-resumption-client-extra] 617ALPNProtocols = foo 618 619 620