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

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

Issue 1131963003: Switch //net functions to use SchemeIsCryptographic() instead of SchemeIsSecure(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebasing. Created 5 years, 7 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_network_transaction.h" 5 #include "net/http/http_network_transaction.h"
6 6
7 #include <set> 7 #include <set>
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after
583 stream_request_.reset(); // we're done with the stream request 583 stream_request_.reset(); // we're done with the stream request
584 OnIOComplete(ERR_HTTPS_PROXY_TUNNEL_RESPONSE); 584 OnIOComplete(ERR_HTTPS_PROXY_TUNNEL_RESPONSE);
585 } 585 }
586 586
587 void HttpNetworkTransaction::GetConnectionAttempts( 587 void HttpNetworkTransaction::GetConnectionAttempts(
588 ConnectionAttempts* out) const { 588 ConnectionAttempts* out) const {
589 *out = connection_attempts_; 589 *out = connection_attempts_;
590 } 590 }
591 591
592 bool HttpNetworkTransaction::IsSecureRequest() const { 592 bool HttpNetworkTransaction::IsSecureRequest() const {
593 return request_->url.SchemeIsSecure(); 593 return request_->url.SchemeIsCryptographic();
Ryan Hamilton 2015/05/07 23:12:03 I'm not sure about this change. Has someone walked
lgarron 2015/05/08 01:53:30 It's used in two places in the same function, Http
asanka 2015/05/11 22:00:46 I'm tempted to say we should rename this fairly vi
lgarron 2015/05/11 23:23:47 IsEncryptedRequest()?
asanka 2015/05/12 17:00:17 Sure.
594 } 594 }
595 595
596 bool HttpNetworkTransaction::UsingHttpProxyWithoutTunnel() const { 596 bool HttpNetworkTransaction::UsingHttpProxyWithoutTunnel() const {
597 return (proxy_info_.is_http() || proxy_info_.is_https() || 597 return (proxy_info_.is_http() || proxy_info_.is_https() ||
598 proxy_info_.is_quic()) && 598 proxy_info_.is_quic()) &&
599 !(request_->url.SchemeIs("https") || request_->url.SchemeIsWSOrWSS()); 599 !(request_->url.SchemeIs("https") || request_->url.SchemeIsWSOrWSS());
600 } 600 }
601 601
602 void HttpNetworkTransaction::DoCallback(int rv) { 602 void HttpNetworkTransaction::DoCallback(int rv) {
603 DCHECK_NE(rv, ERR_IO_PENDING); 603 DCHECK_NE(rv, ERR_IO_PENDING);
(...skipping 1018 matching lines...) Expand 10 before | Expand all | Expand 10 after
1622 DCHECK(stream_request_); 1622 DCHECK(stream_request_);
1623 1623
1624 // Since the transaction can restart with auth credentials, it may create a 1624 // Since the transaction can restart with auth credentials, it may create a
1625 // stream more than once. Accumulate all of the connection attempts across 1625 // stream more than once. Accumulate all of the connection attempts across
1626 // those streams by appending them to the vector: 1626 // those streams by appending them to the vector:
1627 for (const auto& attempt : stream_request_->connection_attempts()) 1627 for (const auto& attempt : stream_request_->connection_attempts())
1628 connection_attempts_.push_back(attempt); 1628 connection_attempts_.push_back(attempt);
1629 } 1629 }
1630 1630
1631 } // namespace net 1631 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698