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

Unified Diff: net/url_request/url_request_http_job.cc

Issue 1818603002: Keep track of ChannelIDService in CookieStore (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 9 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/url_request/url_request_context_builder.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/url_request_http_job.cc
diff --git a/net/url_request/url_request_http_job.cc b/net/url_request/url_request_http_job.cc
index ccc38d544ead9009417fdda7e4b7595c53defc7e..50e403b7c7b97c8dcc16b069b1aac828423ca923 100644
--- a/net/url_request/url_request_http_job.cc
+++ b/net/url_request/url_request_http_job.cc
@@ -82,6 +82,8 @@ void LogChannelIDAndCookieStores(const net::URLRequestContext* context,
EPHEMERAL_MISMATCH = 8,
PERSISTENT_MATCH = 9,
PERSISTENT_MISMATCH = 10,
+ EPHEMERAL_UNKNOWN = 11,
+ PERSISTENT_UNKNOWN = 12,
EPHEMERALITY_MAX
} ephemerality;
const net::HttpNetworkSession::Params* params =
@@ -93,9 +95,11 @@ void LogChannelIDAndCookieStores(const net::URLRequestContext* context,
ephemerality = NO_COOKIE_STORE;
} else if (params->channel_id_service->GetChannelIDStore()->IsEphemeral()) {
if (cookie_store->IsEphemeral()) {
- if (context->channel_id_service() &&
- params->channel_id_service->GetUniqueID() ==
- context->channel_id_service()->GetUniqueID()) {
+ if (cookie_store->GetChannelIDServiceID() == -1) {
+ ephemerality = EPHEMERAL_UNKNOWN;
+ } else if (context->channel_id_service() &&
+ cookie_store->GetChannelIDServiceID() ==
+ context->channel_id_service()->GetUniqueID()) {
mmenke 2016/03/18 21:50:45 While I'm not familiar with just how channel ID is
nharper 2016/03/18 21:59:03 Safe browsing wires up its own CookieStore, but do
ephemerality = EPHEMERAL_MATCH;
} else {
ephemerality = EPHEMERAL_MISMATCH;
@@ -107,8 +111,10 @@ void LogChannelIDAndCookieStores(const net::URLRequestContext* context,
}
} else if (cookie_store->IsEphemeral()) {
ephemerality = CID_PERSISTENT_COOKIE_EPHEMERAL;
+ } else if (cookie_store->GetChannelIDServiceID() == -1) {
+ ephemerality = PERSISTENT_UNKNOWN;
} else if (context->channel_id_service() &&
- params->channel_id_service->GetUniqueID() ==
+ cookie_store->GetChannelIDServiceID() ==
context->channel_id_service()->GetUniqueID()) {
ephemerality = PERSISTENT_MATCH;
} else {
« no previous file with comments | « net/url_request/url_request_context_builder.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698