Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(310)

Unified Diff: net/socket/ssl_client_socket_impl.cc

Issue 2243453002: Replace SSLProtocolNegotiation histogram with SSLNegotiatedAlpnProtocol. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Re: #18. Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/socket/ssl_client_socket_impl.cc
diff --git a/net/socket/ssl_client_socket_impl.cc b/net/socket/ssl_client_socket_impl.cc
index ac4b8337253ab9c3e9fb0c066642b97d74d3763f..a39474b2756d7e23f9ecd06ca1e5e4243cb0401f 100644
--- a/net/socket/ssl_client_socket_impl.cc
+++ b/net/socket/ssl_client_socket_impl.cc
@@ -1214,7 +1214,7 @@ int SSLClientSocketImpl::DoHandshakeComplete(int result) {
}
}
- RecordNegotiationExtension();
+ RecordNegotiatedProtocol();
RecordChannelIDSupport();
const uint8_t* ocsp_response_raw;
@@ -2338,26 +2338,9 @@ void SSLClientSocketImpl::LogConnectEndEvent(int rv) {
base::Bind(&NetLogSSLInfoCallback, base::Unretained(this)));
}
-void SSLClientSocketImpl::RecordNegotiationExtension() const {
- if (negotiation_extension_ == kExtensionUnknown)
- return;
- if (npn_status_ == kNextProtoUnsupported)
- return;
- base::HistogramBase::Sample sample =
- static_cast<base::HistogramBase::Sample>(negotiated_protocol_);
- // In addition to the protocol negotiated, we want to record which TLS
- // extension was used, and in case of NPN, whether there was overlap between
- // server and client list of supported protocols.
- if (negotiation_extension_ == kExtensionNPN) {
- if (npn_status_ == kNextProtoNoOverlap) {
- sample += 1000;
- } else {
- sample += 500;
- }
- } else {
- DCHECK_EQ(kExtensionALPN, negotiation_extension_);
- }
- UMA_HISTOGRAM_SPARSE_SLOWLY("Net.SSLProtocolNegotiation", sample);
+void SSLClientSocketImpl::RecordNegotiatedProtocol() const {
+ UMA_HISTOGRAM_ENUMERATION("SSL.AlpnNegotiatedProtocol", negotiated_protocol_,
davidben 2016/08/27 02:27:58 We don't have much UMA that starts with "SSL." It'
Bence 2016/08/29 12:54:33 I'm sorry, I have misunderstood your earlier comme
+ kProtoNumberOfNextProtos);
}
void SSLClientSocketImpl::RecordChannelIDSupport() const {

Powered by Google App Engine
This is Rietveld 408576698