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

Side by Side Diff: chrome/browser/safe_browsing/protocol_manager_helper.h

Issue 2505153002: Add support for scout to 'ext' param when creating SafeBrowsing ping URLs. (Closed)
Patch Set: Go back to IsExtendedReportingEnabled where level doesn't matter Created 4 years, 1 month 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 #ifndef CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_HELPER_H_ 5 #ifndef CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_HELPER_H_
6 #define CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_HELPER_H_ 6 #define CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_HELPER_H_
7 7
8 // A class that provides common functionality for safebrowsing protocol managers 8 // A class that provides common functionality for safebrowsing protocol managers
9 // that communicate with Google servers. 9 // that communicate with Google servers.
10 10
11 #include <memory> 11 #include <memory>
12 #include <string> 12 #include <string>
13 13
14 #include "base/macros.h" 14 #include "base/macros.h"
15 #include "base/memory/ref_counted.h" 15 #include "base/memory/ref_counted.h"
16 #include "components/safe_browsing_db/safe_browsing_prefs.h"
16 17
17 namespace safe_browsing { 18 namespace safe_browsing {
18 19
19 struct SafeBrowsingProtocolConfig { 20 struct SafeBrowsingProtocolConfig {
20 SafeBrowsingProtocolConfig(); 21 SafeBrowsingProtocolConfig();
21 SafeBrowsingProtocolConfig(const SafeBrowsingProtocolConfig& other); 22 SafeBrowsingProtocolConfig(const SafeBrowsingProtocolConfig& other);
22 ~SafeBrowsingProtocolConfig(); 23 ~SafeBrowsingProtocolConfig();
23 std::string client_name; 24 std::string client_name;
24 std::string url_prefix; 25 std::string url_prefix;
25 std::string backup_connect_error_url_prefix; 26 std::string backup_connect_error_url_prefix;
(...skipping 17 matching lines...) Expand all
43 const std::string& version, 44 const std::string& version,
44 const std::string& additional_query); 45 const std::string& additional_query);
45 46
46 // Similar to above function, and appends "&ext=1" at the end of URL if 47 // Similar to above function, and appends "&ext=1" at the end of URL if
47 // |is_extended_reporting| is true, otherwise, appends "&ext=0". 48 // |is_extended_reporting| is true, otherwise, appends "&ext=0".
48 static std::string ComposeUrl(const std::string& prefix, 49 static std::string ComposeUrl(const std::string& prefix,
49 const std::string& method, 50 const std::string& method,
50 const std::string& client_name, 51 const std::string& client_name,
51 const std::string& version, 52 const std::string& version,
52 const std::string& additional_query, 53 const std::string& additional_query,
53 bool is_extended_reporting); 54 ExtendedReportingLevel reporting_level);
54 55
55 private: 56 private:
56 DISALLOW_IMPLICIT_CONSTRUCTORS(SafeBrowsingProtocolManagerHelper); 57 DISALLOW_IMPLICIT_CONSTRUCTORS(SafeBrowsingProtocolManagerHelper);
57 }; 58 };
58 59
59 } // namespace safe_browsing 60 } // namespace safe_browsing
60 61
61 #endif // CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_HELPER_H_ 62 #endif // CHROME_BROWSER_SAFE_BROWSING_PROTOCOL_MANAGER_HELPER_H_
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/protocol_manager.cc ('k') | chrome/browser/safe_browsing/protocol_manager_helper.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698