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

Unified Diff: net/quic/quic_stream_factory.h

Issue 1140153003: Disable 0RTT if server and origin have different hosts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: net/quic/quic_stream_factory.h
diff --git a/net/quic/quic_stream_factory.h b/net/quic/quic_stream_factory.h
index f3f7a71f33592cace70f9f41ad194db6da6e3032..57582d41ee11c135279aabaf78636066921fac51 100644
--- a/net/quic/quic_stream_factory.h
+++ b/net/quic/quic_stream_factory.h
@@ -58,6 +58,7 @@ class NET_EXPORT_PRIVATE QuicStreamRequest {
int Request(const HostPortPair& host_port_pair,
bool is_https,
PrivacyMode privacy_mode,
+ base::StringPiece origin_host,
base::StringPiece method,
const BoundNetLog& net_log,
const CompletionCallback& callback);
@@ -75,6 +76,7 @@ class NET_EXPORT_PRIVATE QuicStreamRequest {
private:
QuicStreamFactory* factory_;
HostPortPair host_port_pair_;
+ std::string origin_host_;
BoundNetLog net_log_;
CompletionCallback callback_;
scoped_ptr<QuicHttpStream> stream_;
@@ -122,6 +124,7 @@ class NET_EXPORT_PRIVATE QuicStreamFactory
int Create(const HostPortPair& host_port_pair,
bool is_https,
PrivacyMode privacy_mode,
+ bool server_and_origin_have_same_host,
base::StringPiece method,
const BoundNetLog& net_log,
QuicStreamRequest* request);
@@ -274,6 +277,8 @@ class NET_EXPORT_PRIVATE QuicStreamFactory
bool was_session_active);
bool require_confirmation_;
+ // True iff server and origin have the same hostname.
Ryan Hamilton 2015/05/18 14:29:52 nit: iff is not very common in comments. I think "
Bence 2015/05/18 15:17:55 I am fine with not using iff if it is not common e
Ryan Hamilton 2015/05/18 16:21:54 Yeah, I totally understand the sentiment. It seems
Bence 2015/05/18 18:12:02 I totally agree. However, it is not clear to me a
+ bool server_and_origin_have_same_host_;
Ryan Hamilton 2015/05/18 14:29:52 Wait, this is surprising. This is a member of the
Bence 2015/05/18 15:17:55 Good catch, sorry about that. Done.
HostResolver* host_resolver_;
ClientSocketFactory* client_socket_factory_;
base::WeakPtr<HttpServerProperties> http_server_properties_;

Powered by Google App Engine
This is Rietveld 408576698