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

Unified Diff: net/http/http_stream_request.cc

Issue 4935001: Allow a non-200 (or non-407) response for a CONNECT request from an HTTPS pro... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Cleaned up Created 10 years 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/http/http_stream_request.cc
===================================================================
--- net/http/http_stream_request.cc (revision 68026)
+++ net/http/http_stream_request.cc (working copy)
@@ -193,6 +193,12 @@
delegate_->OnNeedsClientAuth(cert_info);
}
+void HttpStreamRequest::OnHttpsProxyTunnelConnectionResponseCallback(
+ const HttpResponseInfo& response_info,
+ HttpStream* stream) {
+ delegate_->OnHttpsProxyTunnelConnectionResponse(response_info, stream);
+}
+
void HttpStreamRequest::OnPreconnectsComplete(int result) {
preconnect_delegate_->OnPreconnectsComplete(this, result);
}
@@ -240,7 +246,7 @@
HttpProxyClientSocket* http_proxy_socket =
static_cast<HttpProxyClientSocket*>(connection_->socket());
const HttpResponseInfo* tunnel_auth_response =
- http_proxy_socket->GetResponseInfo();
+ http_proxy_socket->GetConnectResponseInfo();
next_state_ = STATE_WAITING_USER_ACTION;
MessageLoop::current()->PostTask(
@@ -260,6 +266,15 @@
connection_->ssl_error_response_info().cert_request_info));
return ERR_IO_PENDING;
+ case ERR_HTTPS_PROXY_TUNNEL_CONNECTION_RESPONSE:
+ MessageLoop::current()->PostTask(
+ FROM_HERE,
+ method_factory_.NewRunnableMethod(
+ &HttpStreamRequest::OnHttpsProxyTunnelConnectionResponseCallback,
+ connection_->ssl_error_response_info(),
+ connection_->release_pending_https_proxy_response_stream()));
+ return ERR_IO_PENDING;
+
case OK:
next_state_ = STATE_DONE;
MessageLoop::current()->PostTask(

Powered by Google App Engine
This is Rietveld 408576698