Add an option to allow unknown ALPN protocols.
We received an external request to add an option to undo the check added
in 3e51757de2bf9beef7d249f22d255e4dd9ddb012.
Change-Id: Ifdd4b07705f2fa3d781d775d5cd139ea72d36734
Reviewed-on: https://boringssl-review.googlesource.com/14644
Reviewed-by: David Benjamin <davidben@google.com>
Commit-Queue: David Benjamin <davidben@google.com>
CQ-Verified: CQ bot account: commit-bot@chromium.org <commit-bot@chromium.org>
diff --git a/ssl/test/runner/runner.go b/ssl/test/runner/runner.go
index 8444c21..ed328b6 100644
--- a/ssl/test/runner/runner.go
+++ b/ssl/test/runner/runner.go
@@ -4889,7 +4889,7 @@
})
testCases = append(testCases, testCase{
testType: clientTest,
- name: "ALPNClient-Mismatch-" + ver.name,
+ name: "ALPNClient-RejectUnknown-" + ver.name,
config: Config{
MaxVersion: ver.version,
Bugs: ProtocolBugs{
@@ -4904,6 +4904,20 @@
expectedLocalError: "remote error: illegal parameter",
})
testCases = append(testCases, testCase{
+ testType: clientTest,
+ name: "ALPNClient-AllowUnknown-" + ver.name,
+ config: Config{
+ MaxVersion: ver.version,
+ Bugs: ProtocolBugs{
+ SendALPN: "baz",
+ },
+ },
+ flags: []string{
+ "-advertise-alpn", "\x03foo\x03bar",
+ "-allow-unknown-alpn-protos",
+ },
+ })
+ testCases = append(testCases, testCase{
testType: serverTest,
name: "ALPNServer-" + ver.name,
config: Config{