Chromium Code Reviews| Index: chrome/browser/ui/omnibox/chrome_omnibox_navigation_observer.cc |
| diff --git a/chrome/browser/ui/omnibox/chrome_omnibox_navigation_observer.cc b/chrome/browser/ui/omnibox/chrome_omnibox_navigation_observer.cc |
| index dd1cc48ac2654359774a996561f8e58eed5d169d..7047817f323b6e3c7bcc2d5ab257c51dd4a92290 100644 |
| --- a/chrome/browser/ui/omnibox/chrome_omnibox_navigation_observer.cc |
| +++ b/chrome/browser/ui/omnibox/chrome_omnibox_navigation_observer.cc |
| @@ -21,6 +21,7 @@ |
| #include "content/public/browser/web_contents.h" |
| #include "net/base/load_flags.h" |
| #include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
| +#include "net/traffic_annotation/network_traffic_annotation.h" |
| #include "net/url_request/url_fetcher.h" |
| #include "net/url_request/url_request.h" |
| @@ -64,8 +65,30 @@ ChromeOmniboxNavigationObserver::ChromeOmniboxNavigationObserver( |
| load_state_(LOAD_NOT_SEEN), |
| fetch_state_(FETCH_NOT_COMPLETE) { |
| if (alternate_nav_match_.destination_url.is_valid()) { |
| + net::NetworkTrafficAnnotationTag traffic_annotation = |
| + net::DefineNetworkTrafficAnnotation("...", R"( |
| + semantics { |
| + sender: "..." |
|
Peter Kasting
2017/02/24 03:06:33
omnibox
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + description: "..." |
|
Peter Kasting
2017/02/24 03:06:33
Certain omnibox inputs, e.g. single words, may eit
Ramin Halavati
2017/02/24 07:38:52
Done.
|
| + trigger: "..." |
|
Peter Kasting
2017/02/24 03:06:33
User attempts to search for a string that is plaus
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + data: "..." |
|
Peter Kasting
2017/02/24 03:06:33
None. However, the hostname itself is a string th
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + destination: WEBSITE/GOOGLE_OWNED_SERVICE/OTHER |
|
Peter Kasting
2017/02/24 03:06:34
WEBSITE
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + } |
| + policy { |
| + cookies_allowed: false/true |
|
Peter Kasting
2017/02/24 03:06:33
true
Ramin Halavati
2017/02/24 07:38:52
Done.
|
| + cookies_store: "..." |
|
Peter Kasting
2017/02/24 03:06:33
I'm not sure. The actual request context is on li
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + setting: "..." |
|
Peter Kasting
2017/02/24 03:06:33
NA
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + policy { |
| + [POLICY_NAME] { |
| + policy_options {mode: MANDATORY/RECOMMENDED/UNSET} |
| + value: ... |
| + } |
| + } |
|
Peter Kasting
2017/02/24 03:06:33
The closest policy we have for this is DefaultSear
Ramin Halavati
2017/02/24 07:38:51
Done.
|
| + policy_exception_justification: "..." |
| + })"); |
| fetcher_ = net::URLFetcher::Create(alternate_nav_match_.destination_url, |
| - net::URLFetcher::HEAD, this); |
| + net::URLFetcher::HEAD, this, |
| + traffic_annotation); |
| fetcher_->SetLoadFlags(net::LOAD_DO_NOT_SAVE_COOKIES); |
| fetcher_->SetStopOnRedirect(true); |
| } |