| Index: net/socket/ssl_client_socket_unittest.cc
|
| diff --git a/net/socket/ssl_client_socket_unittest.cc b/net/socket/ssl_client_socket_unittest.cc
|
| index 6e9f4b49afc47af7eb40c4611601d2156b80e186..be84e788aae38dd005f4df73f4da86afc8690963 100644
|
| --- a/net/socket/ssl_client_socket_unittest.cc
|
| +++ b/net/socket/ssl_client_socket_unittest.cc
|
| @@ -1253,8 +1253,7 @@ TEST_F(SSLClientSocketTest, Read) {
|
| }
|
|
|
| // Tests that SSLClientSocket properly handles when the underlying transport
|
| -// synchronously fails a transport read in during the handshake. The error code
|
| -// should be preserved so SSLv3 fallback logic can condition on it.
|
| +// synchronously fails a transport read in during the handshake.
|
| TEST_F(SSLClientSocketTest, Connect_WithSynchronousError) {
|
| ASSERT_TRUE(StartTestServer(SpawnedTestServer::SSLOptions()));
|
|
|
| @@ -2653,62 +2652,6 @@ TEST_F(SSLClientSocketTest, CertificateErrorNoResume) {
|
| EXPECT_EQ(SSLInfo::HANDSHAKE_FULL, ssl_info.handshake_type);
|
| }
|
|
|
| -// Tests that session caches are sharded by max_version.
|
| -TEST_F(SSLClientSocketTest, FallbackShardSessionCache) {
|
| - ASSERT_TRUE(StartTestServer(SpawnedTestServer::SSLOptions()));
|
| -
|
| - // Prepare a normal and fallback SSL config.
|
| - SSLConfig ssl_config;
|
| - SSLConfig fallback_ssl_config;
|
| - fallback_ssl_config.version_max = SSL_PROTOCOL_VERSION_TLS1;
|
| - fallback_ssl_config.version_fallback_min = SSL_PROTOCOL_VERSION_TLS1;
|
| - fallback_ssl_config.version_fallback = true;
|
| -
|
| - // Connect with a fallback config from the test server to add an entry to the
|
| - // session cache.
|
| - int rv;
|
| - ASSERT_TRUE(CreateAndConnectSSLClientSocket(fallback_ssl_config, &rv));
|
| - EXPECT_THAT(rv, IsOk());
|
| - SSLInfo ssl_info;
|
| - EXPECT_TRUE(sock_->GetSSLInfo(&ssl_info));
|
| - EXPECT_EQ(SSLInfo::HANDSHAKE_FULL, ssl_info.handshake_type);
|
| - EXPECT_EQ(SSL_CONNECTION_VERSION_TLS1,
|
| - SSLConnectionStatusToVersion(ssl_info.connection_status));
|
| -
|
| - // A non-fallback connection needs a full handshake.
|
| - ASSERT_TRUE(CreateAndConnectSSLClientSocket(ssl_config, &rv));
|
| - EXPECT_THAT(rv, IsOk());
|
| - EXPECT_TRUE(sock_->GetSSLInfo(&ssl_info));
|
| - EXPECT_EQ(SSLInfo::HANDSHAKE_FULL, ssl_info.handshake_type);
|
| - EXPECT_EQ(SSL_CONNECTION_VERSION_TLS1_2,
|
| - SSLConnectionStatusToVersion(ssl_info.connection_status));
|
| -
|
| - // Note: if the server (correctly) declines to resume a TLS 1.0 session at TLS
|
| - // 1.2, the above test would not be sufficient to prove the session caches are
|
| - // sharded. Implementations vary here, so, to avoid being sensitive to this,
|
| - // attempt to resume with two more connections.
|
| -
|
| - // The non-fallback connection added a > TLS 1.0 entry to the session cache.
|
| - ASSERT_TRUE(CreateAndConnectSSLClientSocket(ssl_config, &rv));
|
| - EXPECT_THAT(rv, IsOk());
|
| - EXPECT_TRUE(sock_->GetSSLInfo(&ssl_info));
|
| - EXPECT_EQ(SSLInfo::HANDSHAKE_RESUME, ssl_info.handshake_type);
|
| - // This does not check for equality because TLS 1.2 support is conditional on
|
| - // system NSS features.
|
| - EXPECT_LT(SSL_CONNECTION_VERSION_TLS1,
|
| - SSLConnectionStatusToVersion(ssl_info.connection_status));
|
| -
|
| - // The fallback connection still resumes from its session cache. It cannot
|
| - // offer the > TLS 1.0 session, so this must have been the session from the
|
| - // first fallback connection.
|
| - ASSERT_TRUE(CreateAndConnectSSLClientSocket(fallback_ssl_config, &rv));
|
| - EXPECT_THAT(rv, IsOk());
|
| - EXPECT_TRUE(sock_->GetSSLInfo(&ssl_info));
|
| - EXPECT_EQ(SSLInfo::HANDSHAKE_RESUME, ssl_info.handshake_type);
|
| - EXPECT_EQ(SSL_CONNECTION_VERSION_TLS1,
|
| - SSLConnectionStatusToVersion(ssl_info.connection_status));
|
| -}
|
| -
|
| // Test that DHE is removed but gives a dedicated error. Also test that the
|
| // dhe_enabled option can restore it.
|
| TEST_F(SSLClientSocketTest, DHE) {
|
|
|