From a45043a4f4270dc3a0c6c0f5af1b036827d0176a Mon Sep 17 00:00:00 2001 From: uazo Date: Tue, 27 Jun 2023 07:01:45 +0000 Subject: [PATCH] AUTOMATED - git apply results --- ...d-setting-to-invert-tap-and-long-tap.patch | 2 +- ...isable-speechSynthesis-getVoices-API.patch | 2 +- .../00Fonts-fingerprinting-mitigation.patch | 4 ++-- build/patches/00Internal-firewall.patch | 2 +- build/patches/00WIN-ADDTO-Eyeo-Adblock.patch | 24 ------------------- .../Add-an-always-incognito-mode.patch | 8 +++---- build/patches/Add-autoplay-site-setting.patch | 7 +++--- ...Add-lifetime-options-for-permissions.patch | 20 ++++++++-------- build/patches/Add-webGL-site-setting.patch | 7 +++--- build/patches/Add-webRTC-site-settings.patch | 7 +++--- ...Block-gateway-attacks-via-websockets.patch | 4 ++-- .../Content-settings-infrastructure.patch | 7 +++--- .../Experimental-user-scripts-support.patch | 6 ++--- build/patches/JIT-site-settings.patch | 7 +++--- .../patches/Modify-default-preferences.patch | 4 ++-- ...Delete-block-external-form-redirects.patch | 8 +++---- ...l-of-execution-context-address-space.patch | 4 ++-- build/patches/Site-setting-for-images.patch | 7 +++--- build/patches/Timezone-customization.patch | 7 +++--- build/patches/Viewport-Protection-flag.patch | 8 +++---- ...RTC-do-not-expose-local-IP-addresses.patch | 4 ++-- 21 files changed, 59 insertions(+), 90 deletions(-) delete mode 100644 build/patches/00WIN-ADDTO-Eyeo-Adblock.patch diff --git a/build/patches/00Add-setting-to-invert-tap-and-long-tap.patch b/build/patches/00Add-setting-to-invert-tap-and-long-tap.patch index 2e28c982..db1e5d02 100644 --- a/build/patches/00Add-setting-to-invert-tap-and-long-tap.patch +++ b/build/patches/00Add-setting-to-invert-tap-and-long-tap.patch @@ -311,7 +311,7 @@ diff --git a/components/browser_ui/accessibility/android/java/src/org/chromium/c diff --git a/third_party/blink/common/features.cc b/third_party/blink/common/features.cc --- a/third_party/blink/common/features.cc +++ b/third_party/blink/common/features.cc -@@ -969,6 +969,10 @@ BASE_FEATURE(kScopeMemoryCachePerContext, +@@ -965,6 +965,10 @@ BASE_FEATURE(kScopeMemoryCachePerContext, "ScopeMemoryCachePerContext", base::FEATURE_DISABLED_BY_DEFAULT); diff --git a/build/patches/00Disable-speechSynthesis-getVoices-API.patch b/build/patches/00Disable-speechSynthesis-getVoices-API.patch index eaf0fb27..e40d9061 100644 --- a/build/patches/00Disable-speechSynthesis-getVoices-API.patch +++ b/build/patches/00Disable-speechSynthesis-getVoices-API.patch @@ -20,7 +20,7 @@ Require: Timezone-customization.patch diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc -@@ -7217,6 +7217,11 @@ const FeatureEntry kFeatureEntries[] = { +@@ -7221,6 +7221,11 @@ const FeatureEntry kFeatureEntries[] = { flag_descriptions::kFileHandlingIconsDescription, kOsDesktop, FEATURE_VALUE_TYPE(blink::features::kFileHandlingIcons)}, diff --git a/build/patches/00Fonts-fingerprinting-mitigation.patch b/build/patches/00Fonts-fingerprinting-mitigation.patch index c7b57214..9a1e2148 100644 --- a/build/patches/00Fonts-fingerprinting-mitigation.patch +++ b/build/patches/00Fonts-fingerprinting-mitigation.patch @@ -32,7 +32,7 @@ fonts-fingerprint-mitigation flag, which is active by default. diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc -@@ -9763,6 +9763,11 @@ const FeatureEntry kFeatureEntries[] = { +@@ -9758,6 +9758,11 @@ const FeatureEntry kFeatureEntries[] = { flag_descriptions::kClipboardUnsanitizedContentDescription, kOsAll, FEATURE_VALUE_TYPE(blink::features::kClipboardUnsanitizedContent)}, @@ -155,7 +155,7 @@ diff --git a/third_party/blink/common/features.cc b/third_party/blink/common/fea // Enable defer commits to avoid flash of unstyled content, for same origin // navigation only. -@@ -1550,6 +1550,10 @@ BASE_FEATURE(kClipboardUnsanitizedContent, +@@ -1546,6 +1546,10 @@ BASE_FEATURE(kClipboardUnsanitizedContent, "ClipboardUnsanitizedContent", base::FEATURE_DISABLED_BY_DEFAULT); diff --git a/build/patches/00Internal-firewall.patch b/build/patches/00Internal-firewall.patch index 4e40bb70..03f9fa0b 100644 --- a/build/patches/00Internal-firewall.patch +++ b/build/patches/00Internal-firewall.patch @@ -71,7 +71,7 @@ diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc #include "services/media_session/public/cpp/features.h" #include "services/network/public/cpp/features.h" #include "services/network/public/cpp/network_switches.h" -@@ -7863,6 +7864,11 @@ const FeatureEntry kFeatureEntries[] = { +@@ -7858,6 +7859,11 @@ const FeatureEntry kFeatureEntries[] = { FEATURE_VALUE_TYPE(page_info::kPageInfoHideSiteSettings)}, #endif // !BUILDFLAG(IS_ANDROID) diff --git a/build/patches/00WIN-ADDTO-Eyeo-Adblock.patch b/build/patches/00WIN-ADDTO-Eyeo-Adblock.patch deleted file mode 100644 index ab354186..00000000 --- a/build/patches/00WIN-ADDTO-Eyeo-Adblock.patch +++ /dev/null @@ -1,24 +0,0 @@ -From: Your Name -Date: Thu, 13 Oct 2022 10:24:51 +0000 -Subject: WIN ADDTO Eyeo Adblock - ---- - chrome/test/BUILD.gn | 4 ---- - 1 file changed, 4 deletions(-) - -diff --git a/chrome/test/BUILD.gn b/chrome/test/BUILD.gn ---- a/chrome/test/BUILD.gn -+++ b/chrome/test/BUILD.gn -@@ -2479,10 +2479,6 @@ if (!is_android) { - sources += [ "../browser/chrome_for_testing/chrome_for_testing_info_bar_browsertest.cc" ] - } - -- if (eyeo_intercept_debug_url) { -- sources += [ "../browser/adblock/test/adblock_debug_url_browsertest.cc" ] -- } -- - if (enable_reporting) { - sources += [ "../browser/net/reporting_browsertest.cc" ] - } --- -2.25.1 diff --git a/build/patches/Add-an-always-incognito-mode.patch b/build/patches/Add-an-always-incognito-mode.patch index 19e09970..ed5efe40 100644 --- a/build/patches/Add-an-always-incognito-mode.patch +++ b/build/patches/Add-an-always-incognito-mode.patch @@ -1929,7 +1929,7 @@ diff --git a/chrome/common/pref_names.h b/chrome/common/pref_names.h diff --git a/components/content_settings/core/browser/content_settings_pref_provider.cc b/components/content_settings/core/browser/content_settings_pref_provider.cc --- a/components/content_settings/core/browser/content_settings_pref_provider.cc +++ b/components/content_settings/core/browser/content_settings_pref_provider.cc -@@ -118,10 +118,12 @@ void PrefProvider::RegisterProfilePrefs( +@@ -116,10 +116,12 @@ void PrefProvider::RegisterProfilePrefs( PrefProvider::PrefProvider(PrefService* prefs, bool off_the_record, @@ -1942,7 +1942,7 @@ diff --git a/components/content_settings/core/browser/content_settings_pref_prov store_last_modified_(store_last_modified), clock_(base::DefaultClock::GetInstance()) { TRACE_EVENT_BEGIN("startup", "PrefProvider::PrefProvider"); -@@ -144,10 +146,14 @@ PrefProvider::PrefProvider(PrefService* prefs, +@@ -142,10 +144,14 @@ PrefProvider::PrefProvider(PrefService* prefs, WebsiteSettingsRegistry* website_settings = WebsiteSettingsRegistry::GetInstance(); for (const WebsiteSettingsInfo* info : *website_settings) { @@ -1969,7 +1969,7 @@ diff --git a/components/content_settings/core/browser/content_settings_pref_prov bool store_last_modified, bool restore_session); -@@ -96,6 +97,7 @@ class PrefProvider : public UserModifiableProvider { +@@ -93,6 +94,7 @@ class PrefProvider : public UserModifiableProvider { raw_ptr prefs_; const bool off_the_record_; @@ -2016,7 +2016,7 @@ diff --git a/components/content_settings/core/browser/host_content_settings_map. bool store_last_modified, bool restore_session, bool should_record_metrics); -@@ -449,6 +450,8 @@ class HostContentSettingsMap : public content_settings::Observer, +@@ -446,6 +447,8 @@ class HostContentSettingsMap : public content_settings::Observer, // Whether this settings map is for an incognito or guest session. bool is_off_the_record_; diff --git a/build/patches/Add-autoplay-site-setting.patch b/build/patches/Add-autoplay-site-setting.patch index a1ad7c95..d85f4d12 100644 --- a/build/patches/Add-autoplay-site-setting.patch +++ b/build/patches/Add-autoplay-site-setting.patch @@ -13,11 +13,11 @@ Require: Content-settings-infrastructure.patch .../drawable-xxxhdpi/settings_autoplay.png | Bin 0 -> 1064 bytes .../impl/BromiteAutoplayContentSetting.java | 92 ++++++++++++++++++ .../bromite_content_settings/autoplay.grdp | 21 ++++ - .../bromite_content_settings/autoplay.inc | 13 +++ + .../bromite_content_settings/autoplay.inc | 12 +++ .../core/browser/content_settings_registry.cc | 2 +- .../core/html/media/autoplay_policy.cc | 14 +++ .../core/html/media/autoplay_policy.h | 4 + - 11 files changed, 145 insertions(+), 1 deletion(-) + 11 files changed, 144 insertions(+), 1 deletion(-) create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-hdpi/settings_autoplay.png create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-mdpi/settings_autoplay.png create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-xhdpi/settings_autoplay.png @@ -262,7 +262,7 @@ diff --git a/components/content_settings/core/browser/bromite_content_settings/a new file mode 100644 --- /dev/null +++ b/components/content_settings/core/browser/bromite_content_settings/autoplay.inc -@@ -0,0 +1,13 @@ +@@ -0,0 +1,12 @@ + content_settings::WebsiteSettingsRegistry::GetInstance() + ->GetMutable(ContentSettingsType::AUTOPLAY) + ->set_show_into_info_page() @@ -275,7 +275,6 @@ new file mode 100644 + .set_allowed_exceptions_ui(IDS_SETTINGS_SITE_SETTINGS_AUTOPLAY_ALLOWED_EXCEPTIONS) + .set_blocked_exceptions_ui(IDS_SETTINGS_SITE_SETTINGS_AUTOPLAY_BLOCKED_EXCEPTIONS) + .set_mid_sentence_ui(IDS_AUTOPLAY_PERMISSION_TITLE); -+ diff --git a/components/content_settings/core/browser/content_settings_registry.cc b/components/content_settings/core/browser/content_settings_registry.cc --- a/components/content_settings/core/browser/content_settings_registry.cc +++ b/components/content_settings/core/browser/content_settings_registry.cc diff --git a/build/patches/Add-lifetime-options-for-permissions.patch b/build/patches/Add-lifetime-options-for-permissions.patch index 40df825c..bbc4d75e 100644 --- a/build/patches/Add-lifetime-options-for-permissions.patch +++ b/build/patches/Add-lifetime-options-for-permissions.patch @@ -284,7 +284,7 @@ diff --git a/components/browser_ui/site_settings/android/java/src/org/chromium/c import org.chromium.components.embedder_support.util.Origin; import org.chromium.content_public.browser.BrowserContextHandle; import org.chromium.content_public.browser.ContentFeatureList; -@@ -545,6 +546,11 @@ public class SingleWebsiteSettings extends SiteSettingsPreferenceFragment +@@ -527,6 +528,11 @@ public class SingleWebsiteSettings extends SiteSettingsPreferenceFragment } } @@ -296,7 +296,7 @@ diff --git a/components/browser_ui/site_settings/android/java/src/org/chromium/c private void setUpClearDataPreference() { ClearWebsiteStorage preference = findPreference(PREF_CLEAR_DATA); long usage = mSite.getTotalUsage(); -@@ -974,6 +980,10 @@ public class SingleWebsiteSettings extends SiteSettingsPreferenceFragment +@@ -956,6 +962,10 @@ public class SingleWebsiteSettings extends SiteSettingsPreferenceFragment if (contentType == mHighlightedPermission) { switchPreference.setBackgroundColor(mHighlightColor); } @@ -371,7 +371,7 @@ diff --git a/components/browser_ui/site_settings/android/website_preference_brid diff --git a/components/browser_ui/strings/android/browser_ui_strings.grd b/components/browser_ui/strings/android/browser_ui_strings.grd --- a/components/browser_ui/strings/android/browser_ui_strings.grd +++ b/components/browser_ui/strings/android/browser_ui_strings.grd -@@ -602,6 +602,11 @@ +@@ -600,6 +600,11 @@ URL truncated @@ -397,7 +397,7 @@ diff --git a/components/content_settings/android/BUILD.gn b/components/content_s diff --git a/components/content_settings/core/browser/content_settings_utils.cc b/components/content_settings/core/browser/content_settings_utils.cc --- a/components/content_settings/core/browser/content_settings_utils.cc +++ b/components/content_settings/core/browser/content_settings_utils.cc -@@ -191,6 +191,35 @@ base::Time GetConstraintExpiration(const base::TimeDelta duration) { +@@ -182,6 +182,35 @@ base::Time GetConstraintExpiration(const base::TimeDelta duration) { return base::Time::Now() + duration; } @@ -518,7 +518,7 @@ diff --git a/components/page_info/android/java/src/org/chromium/components/page_ } } -@@ -124,13 +129,15 @@ public class PermissionParamsListBuilder { +@@ -123,13 +128,15 @@ public class PermissionParamsListBuilder { public final String nameMidSentence; public final int type; public final @ContentSettingValues int setting; @@ -538,7 +538,7 @@ diff --git a/components/page_info/android/java/src/org/chromium/components/page_ diff --git a/components/page_info/android/page_info_controller_android.cc b/components/page_info/android/page_info_controller_android.cc --- a/components/page_info/android/page_info_controller_android.cc +++ b/components/page_info/android/page_info_controller_android.cc -@@ -164,6 +164,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( +@@ -153,6 +153,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( std::map user_specified_settings_to_display; @@ -547,7 +547,7 @@ diff --git a/components/page_info/android/page_info_controller_android.cc b/comp for (const auto& permission : permission_info_list) { if (base::Contains(permissions_to_display, permission.type)) { -@@ -172,6 +174,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( +@@ -161,6 +163,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( if (setting_to_display) { user_specified_settings_to_display[permission.type] = *setting_to_display; @@ -556,7 +556,7 @@ diff --git a/components/page_info/android/page_info_controller_android.cc b/comp } } } -@@ -188,7 +192,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( +@@ -177,7 +181,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( ConvertUTF16ToJavaString(env, setting_title), ConvertUTF16ToJavaString(env, setting_title_mid_sentence), static_cast(permission), @@ -566,7 +566,7 @@ diff --git a/components/page_info/android/page_info_controller_android.cc b/comp } } -@@ -201,7 +206,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( +@@ -190,7 +195,8 @@ void PageInfoControllerAndroid::SetPermissionInfo( env, controller_jobject_, ConvertUTF16ToJavaString(env, object_title), ConvertUTF16ToJavaString(env, object_title), static_cast(chosen_object->ui_info->content_settings_type), @@ -579,7 +579,7 @@ diff --git a/components/page_info/android/page_info_controller_android.cc b/comp diff --git a/components/page_info/page_info.cc b/components/page_info/page_info.cc --- a/components/page_info/page_info.cc +++ b/components/page_info/page_info.cc -@@ -1234,6 +1234,8 @@ void PageInfo::PresentSitePermissions() { +@@ -1198,6 +1198,8 @@ void PageInfo::PresentSitePermissions() { permission_info.source = info.source; permission_info.is_one_time = (info.metadata.session_model == content_settings::SessionModel::OneTime); diff --git a/build/patches/Add-webGL-site-setting.patch b/build/patches/Add-webGL-site-setting.patch index ef72ab78..f63b0eae 100644 --- a/build/patches/Add-webGL-site-setting.patch +++ b/build/patches/Add-webGL-site-setting.patch @@ -11,13 +11,13 @@ License: GPL-3.0-only - https://spdx.org/licenses/GPL-3.0-only.html --- .../impl/BromiteWebGLContentSetting.java | 92 +++++++++++++++++++ .../bromite_content_settings/webgl.grdp | 27 ++++++ - .../bromite_content_settings/webgl.inc | 23 +++++ + .../bromite_content_settings/webgl.inc | 22 +++++ .../common/bromite_content_settings/WEBGL.inc | 1 + .../execution_context/execution_context.cc | 7 ++ .../execution_context/execution_context.h | 2 + .../webgl/webgl_rendering_context_base.cc | 32 +++---- .../webgl/webgl_rendering_context_base.h | 2 + - 8 files changed, 167 insertions(+), 19 deletions(-) + 8 files changed, 166 insertions(+), 19 deletions(-) create mode 100644 components/browser_ui/site_settings/android/java/src/org/chromium/components/browser_ui/site_settings/impl/BromiteWebGLContentSetting.java create mode 100644 components/browser_ui/strings/bromite_content_settings/webgl.grdp create mode 100644 components/content_settings/core/browser/bromite_content_settings/webgl.inc @@ -156,7 +156,7 @@ diff --git a/components/content_settings/core/browser/bromite_content_settings/w new file mode 100644 --- /dev/null +++ b/components/content_settings/core/browser/bromite_content_settings/webgl.inc -@@ -0,0 +1,23 @@ +@@ -0,0 +1,22 @@ + Register(ContentSettingsType::WEBGL, "webgl", CONTENT_SETTING_BLOCK, + WebsiteSettingsInfo::SYNCABLE, + /*allowlisted_schemes=*/{}, @@ -179,7 +179,6 @@ new file mode 100644 + .set_allowed_exceptions_ui(IDS_SETTINGS_SITE_SETTINGS_WEBGL_ALLOWED_EXCEPTIONS) + .set_blocked_exceptions_ui(IDS_SETTINGS_SITE_SETTINGS_WEBGL_BLOCKED_EXCEPTIONS) + .set_mid_sentence_ui(IDS_SITE_SETTINGS_TYPE_WEBGL); -+ diff --git a/components/content_settings/core/common/bromite_content_settings/WEBGL.inc b/components/content_settings/core/common/bromite_content_settings/WEBGL.inc new file mode 100644 --- /dev/null diff --git a/build/patches/Add-webRTC-site-settings.patch b/build/patches/Add-webRTC-site-settings.patch index 70a0edcd..f423c1b5 100644 --- a/build/patches/Add-webRTC-site-settings.patch +++ b/build/patches/Add-webRTC-site-settings.patch @@ -9,12 +9,12 @@ License: GPL-3.0-only - https://spdx.org/licenses/GPL-3.0-only.html --- .../impl/BromiteWebRTCContentSetting.java | 93 +++++++++++++++++++ .../bromite_content_settings/webrtc.grdp | 27 ++++++ - .../bromite_content_settings/webrtc.inc | 23 +++++ + .../bromite_content_settings/webrtc.inc | 22 +++++ .../bromite_content_settings/WEBRTC.inc | 1 + .../peer_connection_dependency_factory.cc | 6 ++ .../peerconnection/rtc_rtp_receiver.cc | 10 ++ .../modules/peerconnection/rtc_rtp_sender.cc | 10 ++ - 7 files changed, 170 insertions(+) + 7 files changed, 169 insertions(+) create mode 100644 components/browser_ui/site_settings/android/java/src/org/chromium/components/browser_ui/site_settings/impl/BromiteWebRTCContentSetting.java create mode 100644 components/browser_ui/strings/bromite_content_settings/webrtc.grdp create mode 100644 components/content_settings/core/browser/bromite_content_settings/webrtc.inc @@ -154,7 +154,7 @@ diff --git a/components/content_settings/core/browser/bromite_content_settings/w new file mode 100644 --- /dev/null +++ b/components/content_settings/core/browser/bromite_content_settings/webrtc.inc -@@ -0,0 +1,23 @@ +@@ -0,0 +1,22 @@ + Register(ContentSettingsType::WEBRTC, "webrtc", CONTENT_SETTING_BLOCK, + WebsiteSettingsInfo::SYNCABLE, + /*allowlisted_schemes=*/{}, @@ -177,7 +177,6 @@ new file mode 100644 + .set_allowed_exceptions_ui(IDS_SETTINGS_SITE_SETTINGS_WEBRTC_ALLOWED_EXCEPTIONS) + .set_blocked_exceptions_ui(IDS_SETTINGS_SITE_SETTINGS_WEBRTC_BLOCKED_EXCEPTIONS) + .set_mid_sentence_ui(IDS_SITE_SETTINGS_TYPE_WEBRTC_MID_SENTENCE); -+ diff --git a/components/content_settings/core/common/bromite_content_settings/WEBRTC.inc b/components/content_settings/core/common/bromite_content_settings/WEBRTC.inc new file mode 100644 --- /dev/null diff --git a/build/patches/Block-gateway-attacks-via-websockets.patch b/build/patches/Block-gateway-attacks-via-websockets.patch index b0e8b404..3a205b91 100644 --- a/build/patches/Block-gateway-attacks-via-websockets.patch +++ b/build/patches/Block-gateway-attacks-via-websockets.patch @@ -23,7 +23,7 @@ License: GPL-3.0-only - https://spdx.org/licenses/GPL-3.0-only.html diff --git a/third_party/blink/renderer/core/execution_context/execution_context.cc b/third_party/blink/renderer/core/execution_context/execution_context.cc --- a/third_party/blink/renderer/core/execution_context/execution_context.cc +++ b/third_party/blink/renderer/core/execution_context/execution_context.cc -@@ -781,4 +781,20 @@ void ExecutionContext::WriteIntoTrace( +@@ -758,4 +758,20 @@ void ExecutionContext::WriteIntoTrace( proto->set_world_type(GetWorldType(*this)); } @@ -47,7 +47,7 @@ diff --git a/third_party/blink/renderer/core/execution_context/execution_context diff --git a/third_party/blink/renderer/core/execution_context/execution_context.h b/third_party/blink/renderer/core/execution_context/execution_context.h --- a/third_party/blink/renderer/core/execution_context/execution_context.h +++ b/third_party/blink/renderer/core/execution_context/execution_context.h -@@ -413,6 +413,7 @@ class CORE_EXPORT ExecutionContext : public Supplementable, +@@ -408,6 +408,7 @@ class CORE_EXPORT ExecutionContext : public Supplementable, void SetAddressSpace(network::mojom::blink::IPAddressSpace ip_address_space); HeapObserverSet& ContextLifecycleObserverSet(); diff --git a/build/patches/Content-settings-infrastructure.patch b/build/patches/Content-settings-infrastructure.patch index 7bdcd064..48ca1b66 100644 --- a/build/patches/Content-settings-infrastructure.patch +++ b/build/patches/Content-settings-infrastructure.patch @@ -42,7 +42,7 @@ Require: bromite-build-utils.patch .../WebsitePreferenceBridge.java | 3 +- .../impl/include_all_directory.java | 1 + ...miteCustomContentSettingImplBase.java.tmpl | 48 +++ - .../bromite_content_settings/placeholder.txt | 2 + + .../bromite_content_settings/placeholder.txt | 1 + components/content_settings/android/BUILD.gn | 1 + .../content_settings/core/browser/BUILD.gn | 7 + .../bromite_content_settings/placeholder.txt | 1 + @@ -72,7 +72,7 @@ Require: bromite-build-utils.patch .../execution_context/execution_context.cc | 16 + .../execution_context/execution_context.h | 5 + .../WebLayerSiteSettingsDelegate.java | 3 + - 61 files changed, 1322 insertions(+), 41 deletions(-) + 61 files changed, 1321 insertions(+), 41 deletions(-) create mode 100644 components/browser_ui/site_settings/android/java/src/org/chromium/components/browser_ui/site_settings/BromiteCustomContentSetting.java create mode 100644 components/browser_ui/site_settings/android/java/src/org/chromium/components/browser_ui/site_settings/BromiteCustomContentSettingImpl.java create mode 100644 components/browser_ui/site_settings/android/java/src/org/chromium/components/browser_ui/site_settings/BromiteCustomContentSetting_README.md @@ -1794,9 +1794,8 @@ diff --git a/components/browser_ui/strings/bromite_content_settings/placeholder. new file mode 100644 --- /dev/null +++ b/components/browser_ui/strings/bromite_content_settings/placeholder.txt -@@ -0,0 +1,2 @@ +@@ -0,0 +1 @@ +this file is intentionally empty -+ diff --git a/components/content_settings/android/BUILD.gn b/components/content_settings/android/BUILD.gn --- a/components/content_settings/android/BUILD.gn +++ b/components/content_settings/android/BUILD.gn diff --git a/build/patches/Experimental-user-scripts-support.patch b/build/patches/Experimental-user-scripts-support.patch index 89ce3920..d7394864 100644 --- a/build/patches/Experimental-user-scripts-support.patch +++ b/build/patches/Experimental-user-scripts-support.patch @@ -344,7 +344,7 @@ diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc #include "components/version_info/version_info.h" #include "components/viz/common/features.h" #include "components/viz/common/switches.h" -@@ -7869,6 +7870,10 @@ const FeatureEntry kFeatureEntries[] = { +@@ -7873,6 +7874,10 @@ const FeatureEntry kFeatureEntries[] = { FEATURE_VALUE_TYPE(ash::features::kClipboardHistoryReorder)}, #endif // BUILDFLAG(IS_CHROMEOS_ASH) @@ -358,7 +358,7 @@ diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc --- a/chrome/browser/flag_descriptions.cc +++ b/chrome/browser/flag_descriptions.cc -@@ -6962,6 +6962,11 @@ const char kUseOutOfProcessVideoDecodingDescription[] = +@@ -6968,6 +6968,11 @@ const char kUseOutOfProcessVideoDecodingDescription[] = "enabled in ash-chrome)."; #endif // BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) @@ -373,7 +373,7 @@ diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descripti diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h --- a/chrome/browser/flag_descriptions.h +++ b/chrome/browser/flag_descriptions.h -@@ -4001,6 +4001,9 @@ extern const char kQuickCommandsDescription[]; +@@ -4004,6 +4004,9 @@ extern const char kQuickCommandsDescription[]; #endif // BUILDFLAG(IS_WIN) || BUILDFLAG(IS_MAC) || BUILDFLAG(IS_LINUX) || // defined (OS_FUCHSIA) diff --git a/build/patches/JIT-site-settings.patch b/build/patches/JIT-site-settings.patch index 8e96a667..01970b94 100644 --- a/build/patches/JIT-site-settings.patch +++ b/build/patches/JIT-site-settings.patch @@ -20,9 +20,9 @@ Require: Content-settings-infrastructure.patch .../permission_javascript_jit.png | Bin 0 -> 797 bytes .../BromiteJavascriptJITContentSetting.java | 92 ++++++++++++++++++ .../javascript_jit.grdp | 21 ++++ - .../javascript_jit.inc | 13 +++ + .../javascript_jit.inc | 12 +++ .../core/browser/content_settings_registry.cc | 2 +- - 9 files changed, 127 insertions(+), 1 deletion(-) + 9 files changed, 126 insertions(+), 1 deletion(-) create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-hdpi/permission_javascript_jit.png create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-mdpi/permission_javascript_jit.png create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-xhdpi/permission_javascript_jit.png @@ -257,7 +257,7 @@ diff --git a/components/content_settings/core/browser/bromite_content_settings/j new file mode 100644 --- /dev/null +++ b/components/content_settings/core/browser/bromite_content_settings/javascript_jit.inc -@@ -0,0 +1,13 @@ +@@ -0,0 +1,12 @@ + content_settings::WebsiteSettingsRegistry::GetInstance() + ->GetMutable(ContentSettingsType::JAVASCRIPT_JIT) + ->set_show_into_info_page() @@ -270,7 +270,6 @@ new file mode 100644 + .set_allowed_exceptions_ui(IDS_WEBSITE_SETTINGS_ADD_SITE_DESCRIPTION_JAVASCRIPT_JIT_ALLOW) + .set_blocked_exceptions_ui(IDS_WEBSITE_SETTINGS_ADD_SITE_DESCRIPTION_JAVASCRIPT_JIT_BLOCK) + .set_mid_sentence_ui(IDS_JAVASCRIPT_JIT_PERMISSION_TITLE); -+ diff --git a/components/content_settings/core/browser/content_settings_registry.cc b/components/content_settings/core/browser/content_settings_registry.cc --- a/components/content_settings/core/browser/content_settings_registry.cc +++ b/components/content_settings/core/browser/content_settings_registry.cc diff --git a/build/patches/Modify-default-preferences.patch b/build/patches/Modify-default-preferences.patch index b1b19ee4..34d5c49a 100644 --- a/build/patches/Modify-default-preferences.patch +++ b/build/patches/Modify-default-preferences.patch @@ -249,7 +249,7 @@ new file mode 100644 diff --git a/components/content_settings/core/browser/content_settings_registry.cc b/components/content_settings/core/browser/content_settings_registry.cc --- a/components/content_settings/core/browser/content_settings_registry.cc +++ b/components/content_settings/core/browser/content_settings_registry.cc -@@ -230,7 +230,7 @@ void ContentSettingsRegistry::Init() { +@@ -227,7 +227,7 @@ void ContentSettingsRegistry::Init() { ContentSettingsInfo::EXCEPTIONS_ON_SECURE_ORIGINS_ONLY); Register(ContentSettingsType::BACKGROUND_SYNC, "background-sync", @@ -258,7 +258,7 @@ diff --git a/components/content_settings/core/browser/content_settings_registry. /*allowlisted_schemes=*/{}, /*valid_settings=*/{CONTENT_SETTING_ALLOW, CONTENT_SETTING_BLOCK}, WebsiteSettingsInfo::TOP_ORIGIN_ONLY_SCOPE, -@@ -321,7 +321,7 @@ void ContentSettingsRegistry::Init() { +@@ -318,7 +318,7 @@ void ContentSettingsRegistry::Init() { // TODO(crbug.com/904439): Update this to "SECURE_ONLY" once // DeviceOrientationEvents and DeviceMotionEvents are only fired in secure // contexts. diff --git a/build/patches/Revert-Delete-block-external-form-redirects.patch b/build/patches/Revert-Delete-block-external-form-redirects.patch index e4701c07..1b57b0e8 100644 --- a/build/patches/Revert-Delete-block-external-form-redirects.patch +++ b/build/patches/Revert-Delete-block-external-form-redirects.patch @@ -20,7 +20,7 @@ License: GPL-3.0-only - https://spdx.org/licenses/GPL-3.0-only.html diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc -@@ -241,6 +241,7 @@ +@@ -242,6 +242,7 @@ #include "chrome/browser/push_messaging/push_messaging_features.h" #include "components/browser_ui/photo_picker/android/features.h" #include "components/content_creation/notes/core/note_features.h" @@ -28,7 +28,7 @@ diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc #include "components/translate/content/android/translate_message.h" #include "ui/android/ui_android_features.h" #else // BUILDFLAG(IS_ANDROID) -@@ -7756,6 +7757,12 @@ const FeatureEntry kFeatureEntries[] = { +@@ -7760,6 +7761,12 @@ const FeatureEntry kFeatureEntries[] = { #endif // BUILDFLAG(ENABLE_PAINT_PREVIEW) && BUILDFLAG(IS_ANDROID) #if BUILDFLAG(IS_ANDROID) @@ -59,7 +59,7 @@ diff --git a/chrome/browser/flag-metadata.json b/chrome/browser/flag-metadata.js diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc --- a/chrome/browser/flag_descriptions.cc +++ b/chrome/browser/flag_descriptions.cc -@@ -3971,6 +3971,12 @@ const char kInstantStartName[] = "Instant start"; +@@ -3977,6 +3977,12 @@ const char kInstantStartName[] = "Instant start"; const char kInstantStartDescription[] = "Show start surface before native library is loaded."; @@ -75,7 +75,7 @@ diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descripti diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h --- a/chrome/browser/flag_descriptions.h +++ b/chrome/browser/flag_descriptions.h -@@ -2307,6 +2307,9 @@ extern const char kInstanceSwitcherDescription[]; +@@ -2310,6 +2310,9 @@ extern const char kInstanceSwitcherDescription[]; extern const char kInstantStartName[]; extern const char kInstantStartDescription[]; diff --git a/build/patches/Revert-removal-of-execution-context-address-space.patch b/build/patches/Revert-removal-of-execution-context-address-space.patch index 99fc763f..73bd9dd5 100644 --- a/build/patches/Revert-removal-of-execution-context-address-space.patch +++ b/build/patches/Revert-removal-of-execution-context-address-space.patch @@ -70,7 +70,7 @@ diff --git a/content/public/common/content_features.cc b/content/public/common/c diff --git a/third_party/blink/renderer/core/execution_context/execution_context.cc b/third_party/blink/renderer/core/execution_context/execution_context.cc --- a/third_party/blink/renderer/core/execution_context/execution_context.cc +++ b/third_party/blink/renderer/core/execution_context/execution_context.cc -@@ -583,6 +583,15 @@ void ExecutionContext::SetReferrerPolicy( +@@ -560,6 +560,15 @@ void ExecutionContext::SetReferrerPolicy( policy_container_->UpdateReferrerPolicy(referrer_policy); } @@ -97,7 +97,7 @@ diff --git a/third_party/blink/renderer/core/execution_context/execution_context #include "services/network/public/mojom/referrer_policy.mojom-blink-forward.h" #include "third_party/abseil-cpp/absl/types/optional.h" #include "third_party/blink/public/common/tokens/tokens.h" -@@ -408,6 +409,9 @@ class CORE_EXPORT ExecutionContext : public Supplementable, +@@ -403,6 +404,9 @@ class CORE_EXPORT ExecutionContext : public Supplementable, const String& message = g_empty_string, const String& source_file = g_empty_string) const {} diff --git a/build/patches/Site-setting-for-images.patch b/build/patches/Site-setting-for-images.patch index 87f894d2..cafa7352 100644 --- a/build/patches/Site-setting-for-images.patch +++ b/build/patches/Site-setting-for-images.patch @@ -13,10 +13,10 @@ Require: Content-settings-infrastructure.patch .../drawable-xxxhdpi/permission_images.png | Bin 0 -> 532 bytes .../impl/BromiteImagesContentSetting.java | 92 ++++++++++++++++++ .../bromite_content_settings/images.grdp | 23 +++++ - .../bromite_content_settings/images.inc | 7 ++ + .../bromite_content_settings/images.inc | 6 ++ .../core/browser/content_settings_registry.cc | 2 +- .../core/browser/content_settings_utils.cc | 8 +- - 10 files changed, 125 insertions(+), 7 deletions(-) + 10 files changed, 124 insertions(+), 7 deletions(-) create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-hdpi/permission_images.png create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-mdpi/permission_images.png create mode 100644 components/browser_ui/site_settings/android/java/res/drawable-xhdpi/permission_images.png @@ -237,14 +237,13 @@ diff --git a/components/content_settings/core/browser/bromite_content_settings/i new file mode 100644 --- /dev/null +++ b/components/content_settings/core/browser/bromite_content_settings/images.inc -@@ -0,0 +1,7 @@ +@@ -0,0 +1,6 @@ + content_settings::WebsiteSettingsRegistry::GetInstance() + ->GetMutable(ContentSettingsType::IMAGES) + ->set_show_into_info_page() + .set_is_renderer_content_setting() + .set_title_ui(IDS_SITE_SETTINGS_TYPE_IMAGES) + .set_mid_sentence_ui(IDS_SITE_SETTINGS_TYPE_IMAGES_MID_SENTENCE); -+ diff --git a/components/content_settings/core/browser/content_settings_registry.cc b/components/content_settings/core/browser/content_settings_registry.cc --- a/components/content_settings/core/browser/content_settings_registry.cc +++ b/components/content_settings/core/browser/content_settings_registry.cc diff --git a/build/patches/Timezone-customization.patch b/build/patches/Timezone-customization.patch index 798e86d4..2e6ee11e 100644 --- a/build/patches/Timezone-customization.patch +++ b/build/patches/Timezone-customization.patch @@ -18,7 +18,7 @@ Require: Content-settings-infrastructure.patch ...BromiteTimezoneOverrideContentSetting.java | 146 +++++++++++++ .../android/website_preference_bridge.cc | 16 ++ .../bromite_content_settings/timezone.grdp | 39 ++++ - .../timezone_override.inc | 24 +++ + .../timezone_override.inc | 23 +++ .../browser/content_settings_pref_provider.cc | 16 ++ .../browser/content_settings_pref_provider.h | 4 + .../core/browser/content_settings_utils.cc | 5 + @@ -33,7 +33,7 @@ Require: Content-settings-infrastructure.patch .../content_settings/core/common/pref_names.h | 2 + .../renderer/content_settings_agent_impl.cc | 80 ++++++++ .../renderer/content_settings_agent_impl.h | 11 + - 23 files changed, 679 insertions(+), 1 deletion(-) + 23 files changed, 678 insertions(+), 1 deletion(-) create mode 100755 components/browser_ui/site_settings/android/java/res/layout/time_zone_select_dialog.xml create mode 100755 components/browser_ui/site_settings/android/java/res/layout/timezoneoverride_site_settings_preference.xml create mode 100755 components/browser_ui/site_settings/android/java/src/org/chromium/components/browser_ui/site_settings/TimezoneOverrideSiteSettingsPreference.java @@ -624,7 +624,7 @@ diff --git a/components/content_settings/core/browser/bromite_content_settings/t new file mode 100644 --- /dev/null +++ b/components/content_settings/core/browser/bromite_content_settings/timezone_override.inc -@@ -0,0 +1,24 @@ +@@ -0,0 +1,23 @@ + Register(ContentSettingsType::TIMEZONE_OVERRIDE, "timezone-override", CONTENT_SETTING_ALLOW, + WebsiteSettingsInfo::SYNCABLE, + /*allowlisted_schemes=*/{}, @@ -648,7 +648,6 @@ new file mode 100644 + .set_allowed_exceptions_ui(IDS_WEBSITE_SETTINGS_CATEGORY_TIMEZONE_OVERRIDE_ALLOWED) + .set_blocked_exceptions_ui(IDS_WEBSITE_SETTINGS_CATEGORY_TIMEZONE_OVERRIDE_RANDOM) + .set_mid_sentence_ui(IDS_SITE_SETTINGS_TIMEZONE_OVERRIDE_TITLE); -+ diff --git a/components/content_settings/core/browser/content_settings_pref_provider.cc b/components/content_settings/core/browser/content_settings_pref_provider.cc --- a/components/content_settings/core/browser/content_settings_pref_provider.cc +++ b/components/content_settings/core/browser/content_settings_pref_provider.cc diff --git a/build/patches/Viewport-Protection-flag.patch b/build/patches/Viewport-Protection-flag.patch index b9a83bea..2c06f991 100644 --- a/build/patches/Viewport-Protection-flag.patch +++ b/build/patches/Viewport-Protection-flag.patch @@ -34,7 +34,7 @@ The feature is controlled by a feature flag (default enabled) diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc -@@ -7803,6 +7803,11 @@ const FeatureEntry kFeatureEntries[] = { +@@ -7807,6 +7807,11 @@ const FeatureEntry kFeatureEntries[] = { FEATURE_VALUE_TYPE(paint_preview::kPaintPreviewDemo)}, #endif // BUILDFLAG(ENABLE_PAINT_PREVIEW) && BUILDFLAG(IS_ANDROID) @@ -49,7 +49,7 @@ diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descriptions.cc --- a/chrome/browser/flag_descriptions.cc +++ b/chrome/browser/flag_descriptions.cc -@@ -7119,6 +7119,12 @@ const char kPaintPreviewDemoDescription[] = +@@ -7125,6 +7125,12 @@ const char kPaintPreviewDemoDescription[] = "previews."; #endif // ENABLE_PAINT_PREVIEW && BUILDFLAG(IS_ANDROID) @@ -65,7 +65,7 @@ diff --git a/chrome/browser/flag_descriptions.cc b/chrome/browser/flag_descripti diff --git a/chrome/browser/flag_descriptions.h b/chrome/browser/flag_descriptions.h --- a/chrome/browser/flag_descriptions.h +++ b/chrome/browser/flag_descriptions.h -@@ -4133,6 +4133,9 @@ extern const char kPaintPreviewDemoName[]; +@@ -4136,6 +4136,9 @@ extern const char kPaintPreviewDemoName[]; extern const char kPaintPreviewDemoDescription[]; #endif // ENABLE_PAINT_PREVIEW && BUILDFLAG(IS_ANDROID) @@ -650,7 +650,7 @@ diff --git a/third_party/blink/renderer/core/page/page.h b/third_party/blink/ren diff --git a/third_party/blink/renderer/platform/runtime_enabled_features.json5 b/third_party/blink/renderer/platform/runtime_enabled_features.json5 --- a/third_party/blink/renderer/platform/runtime_enabled_features.json5 +++ b/third_party/blink/renderer/platform/runtime_enabled_features.json5 -@@ -1819,8 +1819,8 @@ +@@ -1818,8 +1818,8 @@ // as a speculative site compatibility measure, because web authors may // assume that screen dimensions match window.innerWidth/innerHeight while // a page is fullscreen, but that is not always true. crbug.com/1367416 diff --git a/build/patches/webRTC-do-not-expose-local-IP-addresses.patch b/build/patches/webRTC-do-not-expose-local-IP-addresses.patch index a0d9f004..301fca3e 100644 --- a/build/patches/webRTC-do-not-expose-local-IP-addresses.patch +++ b/build/patches/webRTC-do-not-expose-local-IP-addresses.patch @@ -29,7 +29,7 @@ diff --git a/chrome/browser/ui/browser_ui_prefs.cc b/chrome/browser/ui/browser_u diff --git a/third_party/blink/renderer/modules/peerconnection/peer_connection_dependency_factory.cc b/third_party/blink/renderer/modules/peerconnection/peer_connection_dependency_factory.cc --- a/third_party/blink/renderer/modules/peerconnection/peer_connection_dependency_factory.cc +++ b/third_party/blink/renderer/modules/peerconnection/peer_connection_dependency_factory.cc -@@ -124,7 +124,9 @@ WebRTCIPHandlingPolicy GetWebRTCIPHandlingPolicy(const String& preference) { +@@ -123,7 +123,9 @@ WebRTCIPHandlingPolicy GetWebRTCIPHandlingPolicy(const String& preference) { return kDefaultPublicInterfaceOnly; if (preference == kWebRTCIPHandlingDisableNonProxiedUdp) return kDisableNonProxiedUdp; @@ -40,7 +40,7 @@ diff --git a/third_party/blink/renderer/modules/peerconnection/peer_connection_d } bool IsValidPortRange(uint16_t min_port, uint16_t max_port) { -@@ -776,7 +778,7 @@ PeerConnectionDependencyFactory::CreatePortAllocator( +@@ -770,7 +772,7 @@ PeerConnectionDependencyFactory::CreatePortAllocator( break; }