From 6605e1bf7e94db5d46e6ffb69631424f313a5774 Mon Sep 17 00:00:00 2001 From: Carmelo Messina Date: Thu, 11 Dec 2025 14:33:33 +0100 Subject: [PATCH] Improve the browser sandbox: checks at each restart whether the network process sandbox can be activated instead of each major (#2544) --- build/patches/Improve-the-browser-sandbox.patch | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/build/patches/Improve-the-browser-sandbox.patch b/build/patches/Improve-the-browser-sandbox.patch index 1ac78823..45a506fa 100644 --- a/build/patches/Improve-the-browser-sandbox.patch +++ b/build/patches/Improve-the-browser-sandbox.patch @@ -7,13 +7,26 @@ using the new flags on android License: GPL-2.0-or-later - https://spdx.org/licenses/GPL-2.0-or-later.html --- + chrome/browser/net/system_network_context_manager.cc | 2 +- .../common/features_cc/Improve-the-browser-sandbox.inc | 2 ++ .../content_features_cc/Improve-the-browser-sandbox.inc | 1 + sandbox/policy/features.cc | 8 ++++++++ - 3 files changed, 11 insertions(+) + 4 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 cromite_flags/content/common/features_cc/Improve-the-browser-sandbox.inc create mode 100644 cromite_flags/content/public/common/content_features_cc/Improve-the-browser-sandbox.inc +diff --git a/chrome/browser/net/system_network_context_manager.cc b/chrome/browser/net/system_network_context_manager.cc +--- a/chrome/browser/net/system_network_context_manager.cc ++++ b/chrome/browser/net/system_network_context_manager.cc +@@ -358,7 +358,7 @@ namespace features { + // this feature is disabled any failed launches in the current browser session + // will still result in sandbox being disabled for the lifetime of the running + // browser. +-BASE_FEATURE(kPersistFailedLaunchState, base::FEATURE_ENABLED_BY_DEFAULT); ++BASE_FEATURE(kPersistFailedLaunchState, base::FEATURE_DISABLED_BY_DEFAULT); + } // namespace features + + class SystemNetworkContextManager::NetworkProcessLaunchWatcher diff --git a/cromite_flags/content/common/features_cc/Improve-the-browser-sandbox.inc b/cromite_flags/content/common/features_cc/Improve-the-browser-sandbox.inc new file mode 100644 --- /dev/null