Skip to content

Commit 97eab21

Browse files
committed
crypto/tls: enable more large record bogo tests
Previously a handful of large record tests were in the bogo config ignore list. The ignored tests were failing because they used insecure ciphersuites that aren't enabled by default. This commit adds the non-default insecure ciphersuites to the bogo TLS configuration and re-enables the tests. Doing this uncovered a handful of unrelated tests that needed to be fixed, each handled before this commit. Updates #72006 Change-Id: I27a2cd231e4b8762b0d9e2dbd3d8ddd5b87fd5c7 Reviewed-on: https://go-review.googlesource.com/c/go/+/669158 Reviewed-by: Cherry Mui <cherryyz@google.com> Reviewed-by: Roland Shoemaker <roland@golang.org> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
1 parent 45f2782 commit 97eab21

File tree

2 files changed

+8
-9
lines changed

2 files changed

+8
-9
lines changed

src/crypto/tls/bogo_config.json

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -67,15 +67,6 @@
6767
"SupportTicketsWithSessionID": "TODO: first pass, this should be fixed",
6868
"NoNullCompression-TLS12": "TODO: first pass, this should be fixed",
6969
"KeyUpdate-RequestACK": "TODO: first pass, this should be fixed",
70-
"TLS-TLS12-RSA_WITH_AES_128_GCM_SHA256-LargeRecord": "TODO: first pass, this should be fixed",
71-
"TLS-TLS1-RSA_WITH_AES_128_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed",
72-
"TLS-TLS11-RSA_WITH_AES_128_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed",
73-
"TLS-TLS12-RSA_WITH_AES_128_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed",
74-
"TLS-TLS12-RSA_WITH_AES_256_GCM_SHA384-LargeRecord": "TODO: first pass, this should be fixed",
75-
"TLS-TLS1-RSA_WITH_AES_256_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed",
76-
"TLS-TLS11-RSA_WITH_AES_256_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed",
77-
"TLS-TLS12-RSA_WITH_AES_256_CBC_SHA-LargeRecord": "TODO: first pass, this should be fixed",
78-
"TLS-TLS12-ECDHE_RSA_WITH_AES_128_CBC_SHA256-LargeRecord": "TODO: first pass, this should be fixed",
7970
"RequireAnyClientCertificate-TLS1": "TODO: first pass, this should be fixed",
8071
"RequireAnyClientCertificate-TLS11": "TODO: first pass, this should be fixed",
8172
"RequireAnyClientCertificate-TLS12": "TODO: first pass, this should be fixed",

src/crypto/tls/bogo_shim_test.go

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -125,6 +125,12 @@ func bogoShim() {
125125
return
126126
}
127127

128+
// Test with both the default and insecure cipher suites.
129+
var ciphersuites []uint16
130+
for _, s := range append(CipherSuites(), InsecureCipherSuites()...) {
131+
ciphersuites = append(ciphersuites, s.ID)
132+
}
133+
128134
cfg := &Config{
129135
ServerName: "test",
130136

@@ -133,6 +139,8 @@ func bogoShim() {
133139

134140
ClientSessionCache: NewLRUClientSessionCache(0),
135141

142+
CipherSuites: ciphersuites,
143+
136144
GetConfigForClient: func(chi *ClientHelloInfo) (*Config, error) {
137145

138146
if *expectAdvertisedALPN != "" {

0 commit comments

Comments
 (0)