| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/http/http_stream_factory_impl_job.h" | 5 #include "net/http/http_stream_factory_impl_job.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/bind.h" | 10 #include "base/bind.h" |
| (...skipping 1261 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1272 fallback = FALLBACK_TLS1; | 1272 fallback = FALLBACK_TLS1; |
| 1273 break; | 1273 break; |
| 1274 case SSL_PROTOCOL_VERSION_TLS1_1: | 1274 case SSL_PROTOCOL_VERSION_TLS1_1: |
| 1275 fallback = FALLBACK_TLS1_1; | 1275 fallback = FALLBACK_TLS1_1; |
| 1276 break; | 1276 break; |
| 1277 } | 1277 } |
| 1278 } | 1278 } |
| 1279 UMA_HISTOGRAM_ENUMERATION("Net.ConnectionUsedSSLVersionFallback", | 1279 UMA_HISTOGRAM_ENUMERATION("Net.ConnectionUsedSSLVersionFallback", |
| 1280 fallback, FALLBACK_MAX); | 1280 fallback, FALLBACK_MAX); |
| 1281 | 1281 |
| 1282 UMA_HISTOGRAM_BOOLEAN("Net.ConnectionUsedSSLDeprecatedCipherFallback", |
| 1283 ssl_config->enable_deprecated_cipher_suites); |
| 1284 |
| 1282 // We also wish to measure the amount of fallback connections for a host that | 1285 // We also wish to measure the amount of fallback connections for a host that |
| 1283 // we know implements TLS up to 1.2. Ideally there would be no fallback here | 1286 // we know implements TLS up to 1.2. Ideally there would be no fallback here |
| 1284 // but high numbers of SSLv3 would suggest that SSLv3 fallback is being | 1287 // but high numbers of SSLv3 would suggest that SSLv3 fallback is being |
| 1285 // caused by network middleware rather than buggy HTTPS servers. | 1288 // caused by network middleware rather than buggy HTTPS servers. |
| 1286 const std::string& host = origin_server.host(); | 1289 const std::string& host = origin_server.host(); |
| 1287 if (!is_proxy && | 1290 if (!is_proxy && |
| 1288 host.size() >= 10 && | 1291 host.size() >= 10 && |
| 1289 host.compare(host.size() - 10, 10, "google.com") == 0 && | 1292 host.compare(host.size() - 10, 10, "google.com") == 0 && |
| 1290 (host.size() == 10 || host[host.size()-11] == '.')) { | 1293 (host.size() == 10 || host[host.size()-11] == '.')) { |
| 1291 UMA_HISTOGRAM_ENUMERATION("Net.GoogleConnectionUsedSSLVersionFallback", | 1294 UMA_HISTOGRAM_ENUMERATION("Net.GoogleConnectionUsedSSLVersionFallback", |
| (...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1467 | 1470 |
| 1468 if (job_status_ == STATUS_SUCCEEDED && other_job_status_ == STATUS_BROKEN) { | 1471 if (job_status_ == STATUS_SUCCEEDED && other_job_status_ == STATUS_BROKEN) { |
| 1469 HistogramBrokenAlternateProtocolLocation( | 1472 HistogramBrokenAlternateProtocolLocation( |
| 1470 BROKEN_ALTERNATE_PROTOCOL_LOCATION_HTTP_STREAM_FACTORY_IMPL_JOB_MAIN); | 1473 BROKEN_ALTERNATE_PROTOCOL_LOCATION_HTTP_STREAM_FACTORY_IMPL_JOB_MAIN); |
| 1471 session_->http_server_properties()->MarkAlternativeServiceBroken( | 1474 session_->http_server_properties()->MarkAlternativeServiceBroken( |
| 1472 other_job_alternative_service_); | 1475 other_job_alternative_service_); |
| 1473 } | 1476 } |
| 1474 } | 1477 } |
| 1475 | 1478 |
| 1476 } // namespace net | 1479 } // namespace net |
| OLD | NEW |