LeOSium_webview/LeOS/patches/ungoogled-chromium-Disable-...

78 lines
2.8 KiB
Diff
Raw Permalink Normal View History

2023-11-18 11:46:19 +01:00
From: csagan5 <32685696+csagan5@users.noreply.github.com>
Date: Mon, 12 Feb 2018 21:28:11 +0100
Subject: ungoogled-chromium: Disable untraceable URLs
Disable additional URLs that are not caught by the "trk" scheme
License: GPL-3.0-only - https://spdx.org/licenses/GPL-3.0-only.html
---
chrome/browser/android/rlz/rlz_ping_handler.cc | 2 +-
rlz/lib/financial_ping.cc | 5 +++--
rlz/lib/lib_values.cc | 1 -
rlz/lib/lib_values.h | 1 -
4 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/chrome/browser/android/rlz/rlz_ping_handler.cc b/chrome/browser/android/rlz/rlz_ping_handler.cc
--- a/chrome/browser/android/rlz/rlz_ping_handler.cc
+++ b/chrome/browser/android/rlz/rlz_ping_handler.cc
@@ -75,7 +75,7 @@ void RlzPingHandler::Ping(
DCHECK_EQ(id.length(), 50u);
GURL request_url(base::StringPrintf(
- "https://%s%s?", rlz_lib::kFinancialServer, rlz_lib::kFinancialPingPath));
+ "about:blank"));
request_url = net::AppendQueryParameter(
request_url, rlz_lib::kProductSignatureCgiVariable, "chrome");
request_url =
diff --git a/rlz/lib/financial_ping.cc b/rlz/lib/financial_ping.cc
--- a/rlz/lib/financial_ping.cc
+++ b/rlz/lib/financial_ping.cc
@@ -237,6 +237,7 @@ bool FinancialPing::SetURLLoaderFactory(
void PingRlzServer(std::string url,
scoped_refptr<RefCountedWaitableEvent> event) {
+ if ((true)) return;
// Copy the pointer to stack because g_URLLoaderFactory may be set to NULL
// in different thread. The instance is guaranteed to exist while
// the method is running.
@@ -300,13 +301,13 @@ void PingRlzServer(std::string url,
FinancialPing::PingResponse FinancialPing::PingServer(const char* request,
std::string* response) {
- if (!response)
+ if ((true))
return PING_FAILURE;
response->clear();
std::string url =
- base::StringPrintf("https://%s%s", kFinancialServer, request);
+ base::StringPrintf("about:blank");
// Use a waitable event to cause this function to block, to match the
// wininet implementation.
diff --git a/rlz/lib/lib_values.cc b/rlz/lib/lib_values.cc
--- a/rlz/lib/lib_values.cc
+++ b/rlz/lib/lib_values.cc
@@ -40,7 +40,6 @@ const char kSetDccResponseVariable[] = "set_dcc";
//
const char kFinancialPingPath[] = "/tools/pso/ping";
-const char kFinancialServer[] = "clients1.google.com";
const int kFinancialPort = 443;
// Ping times in 100-nanosecond intervals.
diff --git a/rlz/lib/lib_values.h b/rlz/lib/lib_values.h
--- a/rlz/lib/lib_values.h
+++ b/rlz/lib/lib_values.h
@@ -72,7 +72,6 @@ extern const char kSetDccResponseVariable[];
//
extern const char kFinancialPingPath[];
-extern const char kFinancialServer[];
extern const int kFinancialPort;
--
2.25.1