0

Move "proxy-server" command line switch from content to chrome+fuchsia.

This addresses an old TODO. The switch isn't implemented
in content/, so shouldn't be there. content/ was still sending the
flag's value to the network service process, but proxy configuration
is now handled in the browser process, so that's no longer needed.

The switch is wired up through prefs in Chrome
(https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/prefs/chrome_command_line_pref_store.cc;l=157;drc=8e948282d37c0e119e3102236878d6f4d5052c16)
and parsed and sent to the network service by other embedders (e.g.,
https://source.chromium.org/chromium/chromium/src/+/main:fuchsia_web/webengine/browser/web_engine_content_browser_client.cc;l=382;drc=8e948282d37c0e119e3102236878d6f4d5052c16;bpv=1;bpt=1)

Also update documentation of the flag. Remove mention of "HTTP and
HTTPS", since FTP is no longer supported. Also remove mention of
ARC apps - it's not really clear why they're relevant here.

Cq-Include-Trybots: luci.chrome.try:fuchsia-fyi-sherlock
Bug: None
Change-Id: I27d1f22550dcdf3af334e035ccde2b41cbf6171c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5850960
Reviewed-by: Zijie He <zijiehe@google.com>
Reviewed-by: Adam Rice <ricea@chromium.org>
Reviewed-by: David Dorwin <ddorwin@chromium.org>
Commit-Queue: mmenke <mmenke@chromium.org>
Reviewed-by: Avi Drissman <avi@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1354695}
This commit is contained in:
Matt Menke
2024-09-12 18:05:26 +00:00
committed by Chromium LUCI CQ
parent 22960632a1
commit 23343fe73e
8 changed files with 10 additions and 12 deletions

@ -75,6 +75,7 @@
#include "chrome/browser/ui/webui/ash/login/user_creation_screen_handler.h"
#include "chrome/browser/ui/webui/signin/signin_utils.h"
#include "chrome/common/chrome_features.h"
#include "chrome/common/chrome_switches.h"
#include "chrome/common/pref_names.h"
#include "chrome/test/base/ash/scoped_test_system_nss_key_slot_mixin.h"
#include "chrome/test/base/fake_gaia_mixin.h"
@ -110,7 +111,6 @@
#include "content/public/browser/client_certificate_delegate.h"
#include "content/public/browser/render_frame_host.h"
#include "content/public/browser/storage_partition.h"
#include "content/public/common/content_switches.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
#include "content/public/test/test_navigation_observer.h"

@ -530,7 +530,10 @@ const char kProxyBypassList[] = "proxy-bypass-list";
// Uses the pac script at the given URL
const char kProxyPacUrl[] = "proxy-pac-url";
// Porvides a list of addresses to discover DevTools remote debugging targets.
// Uses a specified proxy server, overrides system settings.
const char kProxyServer[] = "proxy-server";
// Provides a list of addresses to discover DevTools remote debugging targets.
// The format is <host>:<port>,...,<host>:port.
const char kRemoteDebuggingTargets[] = "remote-debugging-targets";

@ -160,6 +160,7 @@ extern const char kProfileEmail[];
extern const char kProxyAutoDetect[];
extern const char kProxyBypassList[];
extern const char kProxyPacUrl[];
extern const char kProxyServer[];
extern const char kRemoteDebuggingTargets[];
extern const char kRestart[];
extern const char kRestoreLastSession[];

@ -329,7 +329,6 @@ bool UtilityProcessHost::StartProcess() {
switches::kIgnoreCertificateErrors,
switches::kOverrideUseSoftwareGLForTests,
switches::kOverrideEnabledCdmInterfaceVersion,
switches::kProxyServer,
switches::kDisableAcceleratedMjpegDecode,
switches::kUseFakeDeviceForMediaStream,
switches::kUseFakeMjpegDecodeAccelerator,

@ -598,14 +598,6 @@ const char kProcessType[] = "type";
const char kProtectedAudiencesConsentedDebugToken[] =
"protected-audiences-consented-debug-token";
// Uses a specified proxy server, overrides system settings. This switch only
// affects HTTP and HTTPS requests. ARC-apps use only HTTP proxy server with the
// highest priority.
// TODO(yzshen): Move this switch back to chrome/common/chrome_switches.{h,cc},
// once the network service is able to access the corresponding setting via the
// pref service.
const char kProxyServer[] = "proxy-server";
// Enables or disables pull-to-refresh gesture in response to vertical
// overscroll.
// Set the value to '0' to disable the feature, set to '1' to enable it for both

@ -173,7 +173,6 @@ CONTENT_EXPORT extern const char kProcessPerSite[];
CONTENT_EXPORT extern const char kProcessPerTab[];
CONTENT_EXPORT extern const char kProcessType[];
CONTENT_EXPORT extern const char kProtectedAudiencesConsentedDebugToken[];
CONTENT_EXPORT extern const char kProxyServer[];
CONTENT_EXPORT extern const char kPullToRefresh[];
CONTENT_EXPORT extern const char kQuotaChangeEventInterval[];
CONTENT_EXPORT extern const char kReduceAcceptLanguage[];

@ -22,6 +22,7 @@ const char kDataQuotaBytes[] = "data-quota-bytes";
const char kGoogleApiKey[] = "google-api-key";
const char kContextProvider[] = "context-provider";
const char kProxyBypassList[] = "proxy-bypass-list";
const char kProxyServer[] = "proxy-server";
#if BUILDFLAG(ENABLE_CAST_RECEIVER)
const char kAllowRunningInsecureContent[] = "allow-running-insecure-content";

@ -68,6 +68,9 @@ extern const char kContextProvider[];
// Equivalent to Chrome's --proxy-bypass-list switch.
extern const char kProxyBypassList[];
// Uses a specified proxy server, overrides system settings.
extern const char kProxyServer[];
} // namespace switches
#endif // FUCHSIA_WEB_WEBENGINE_SWITCHES_H_