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

Side by Side Diff: net/http/http_basic_stream.cc

Issue 1378613004: Set Token-Binding HTTP header (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@tb-tls-ext-new
Patch Set: Remove sequence numbers from mock reads Created 4 years, 10 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 unified diff | Download patch
OLDNEW
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_basic_stream.h" 5 #include "net/http/http_basic_stream.h"
6 6
7 #include "base/memory/scoped_ptr.h" 7 #include "base/memory/scoped_ptr.h"
8 #include "net/http/http_request_info.h" 8 #include "net/http/http_request_info.h"
9 #include "net/http/http_response_body_drainer.h" 9 #include "net/http/http_response_body_drainer.h"
10 #include "net/http/http_stream_parser.h" 10 #include "net/http/http_stream_parser.h"
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 parser()->GetSSLCertRequestInfo(cert_request_info); 104 parser()->GetSSLCertRequestInfo(cert_request_info);
105 } 105 }
106 106
107 bool HttpBasicStream::GetRemoteEndpoint(IPEndPoint* endpoint) { 107 bool HttpBasicStream::GetRemoteEndpoint(IPEndPoint* endpoint) {
108 if (!state_.connection() || !state_.connection()->socket()) 108 if (!state_.connection() || !state_.connection()->socket())
109 return false; 109 return false;
110 110
111 return state_.connection()->socket()->GetPeerAddress(endpoint) == OK; 111 return state_.connection()->socket()->GetPeerAddress(endpoint) == OK;
112 } 112 }
113 113
114 Error HttpBasicStream::GetSignedEKMForTokenBinding(crypto::ECPrivateKey* key,
115 std::vector<uint8_t>* out) {
116 return parser()->GetSignedEKMForTokenBinding(key, out);
117 }
118
114 void HttpBasicStream::Drain(HttpNetworkSession* session) { 119 void HttpBasicStream::Drain(HttpNetworkSession* session) {
115 HttpResponseBodyDrainer* drainer = new HttpResponseBodyDrainer(this); 120 HttpResponseBodyDrainer* drainer = new HttpResponseBodyDrainer(this);
116 drainer->Start(session); 121 drainer->Start(session);
117 // |drainer| will delete itself. 122 // |drainer| will delete itself.
118 } 123 }
119 124
120 void HttpBasicStream::PopulateNetErrorDetails(NetErrorDetails* /*details*/) { 125 void HttpBasicStream::PopulateNetErrorDetails(NetErrorDetails* /*details*/) {
121 return; 126 return;
122 } 127 }
123 128
124 void HttpBasicStream::SetPriority(RequestPriority priority) { 129 void HttpBasicStream::SetPriority(RequestPriority priority) {
125 // TODO(akalin): Plumb this through to |connection_|. 130 // TODO(akalin): Plumb this through to |connection_|.
126 } 131 }
127 132
128 } // namespace net 133 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698