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

Unified Diff: net/http/http_stream_factory_impl_job.cc

Issue 1393713003: Remove insecure QUIC support from Chromium. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 2 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
« no previous file with comments | « net/http/http_stream_factory_impl.cc ('k') | net/quic/quic_end_to_end_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_stream_factory_impl_job.cc
diff --git a/net/http/http_stream_factory_impl_job.cc b/net/http/http_stream_factory_impl_job.cc
index 27c02cd1f0da4bc196227d62738bdb267fdea796..33476a08eccc8870b2a5f16522d52fcfe610af73 100644
--- a/net/http/http_stream_factory_impl_job.cc
+++ b/net/http/http_stream_factory_impl_job.cc
@@ -775,7 +775,7 @@ int HttpStreamFactoryImpl::Job::DoResolveProxyComplete(int result) {
bool HttpStreamFactoryImpl::Job::ShouldForceQuic() const {
return session_->params().enable_quic &&
session_->params().origin_to_force_quic_on.Equals(server_) &&
- proxy_info_.is_direct();
+ proxy_info_.is_direct() && origin_url_.SchemeIs("https");
}
int HttpStreamFactoryImpl::Job::DoWaitForJob() {
@@ -834,31 +834,29 @@ int HttpStreamFactoryImpl::Job::DoInitConnection() {
}
HostPortPair destination;
std::string origin_host;
- bool secure_quic;
SSLConfig* ssl_config;
if (proxy_info_.is_quic()) {
// A proxy's certificate is expected to be valid for the proxy hostname.
destination = proxy_info_.proxy_server().host_port_pair();
origin_host = destination.host();
- secure_quic = true;
ssl_config = &proxy_ssl_config_;
// If QUIC is disabled on the destination port, return error.
if (session_->quic_stream_factory()->IsQuicDisabled(destination.port()))
return ERR_QUIC_PROTOCOL_ERROR;
} else {
+ DCHECK(using_ssl_);
// The certificate of a QUIC alternative server is expected to be valid
// for the origin of the request (in addition to being valid for the
// server itself).
destination = server_;
origin_host = origin_url_.host();
- secure_quic = using_ssl_;
ssl_config = &server_ssl_config_;
}
- int rv = quic_request_.Request(
- destination, secure_quic, request_info_.privacy_mode,
- ssl_config->GetCertVerifyFlags(), origin_host, request_info_.method,
- net_log_, io_callback_);
+ int rv =
+ quic_request_.Request(destination, request_info_.privacy_mode,
+ ssl_config->GetCertVerifyFlags(), origin_host,
+ request_info_.method, net_log_, io_callback_);
if (rv == OK) {
using_existing_quic_session_ = true;
} else {
« no previous file with comments | « net/http/http_stream_factory_impl.cc ('k') | net/quic/quic_end_to_end_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698