summaryrefslogtreecommitdiffstats
path: root/net/spdy
diff options
context:
space:
mode:
authorrch@chromium.org <rch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-07 23:14:25 +0000
committerrch@chromium.org <rch@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-03-07 23:14:25 +0000
commitc0cfb2ff854d11bd0514cda699945de4053fc204 (patch)
treeab9f83fa9224934c44c22609c1522314b39718fd /net/spdy
parent3b317836cf6a3039127506bcfc2a42273a92cb38 (diff)
downloadchromium_src-c0cfb2ff854d11bd0514cda699945de4053fc204.zip
chromium_src-c0cfb2ff854d11bd0514cda699945de4053fc204.tar.gz
chromium_src-c0cfb2ff854d11bd0514cda699945de4053fc204.tar.bz2
Add the spdy protocol to the information displayed about a spdy session in net-internals.
TEST=Connect to https://www.google.com/ and then pull up chrome://net-internals/#spdy. Notice the new Protocol Negotiatied column. Review URL: http://codereview.chromium.org/9625009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125485 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/spdy')
-rw-r--r--net/spdy/spdy_session.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/net/spdy/spdy_session.cc b/net/spdy/spdy_session.cc
index 4b21695..c9b83d1 100644
--- a/net/spdy/spdy_session.cc
+++ b/net/spdy/spdy_session.cc
@@ -1110,6 +1110,16 @@ Value* SpdySession::GetInfoAsValue() const {
dict->SetBoolean("is_secure", is_secure_);
+ SSLClientSocket::NextProto proto = SSLClientSocket::kProtoUnknown;
+ if (is_secure_) {
+ SSLClientSocket* ssl_socket =
+ reinterpret_cast<SSLClientSocket*>(connection_->socket());
+ DCHECK(ssl_socket);
+ proto = ssl_socket->protocol_negotiated();
+ }
+ dict->SetString("protocol_negotiated",
+ SSLClientSocket::NextProtoToString(proto));
+
dict->SetInteger("error", error_);
dict->SetInteger("max_concurrent_streams", max_concurrent_streams_);