Browse Source

Update to 90.0.4430.212

master 90.0.4430.212-1
wchen342 2 years ago
parent
commit
612ef15188
Signed by: wchen342 GPG Key ID: 9C19365D69B04CEC
  1. 4
      .build_config
  2. 3
      CHANGELOG.md
  3. 2
      build.sh
  4. 17
      bundle_generate_apk.sh
  5. 32
      patches/Bromite/AImageReader-CFI-crash-mitigations.patch
  6. 68
      patches/Bromite/Add-a-proxy-configuration-page.patch
  7. 796
      patches/Bromite/Add-bookmark-import-export-actions.patch
  8. 39
      patches/Bromite/Add-exit-menu-item.patch
  9. 14
      patches/Bromite/Add-flags-to-disable-device-motion-orientation-APIs.patch
  10. 26
      patches/Bromite/Add-option-to-not-persist-tabs-across-sessions.patch
  11. 24
      patches/Bromite/DoH-secure-mode-by-default.patch
  12. 9
      patches/Bromite/Inject-scripts-for-AMP-tracking-ads-and-video.patch
  13. 8
      patches/src-fix/fix-safe-browsing-prefs.patch

4
.build_config

@ -9,7 +9,7 @@ trichrome_webview_target=trichrome_webview_apk
trichrome_webview_64_target=trichrome_webview_64_apk
all=all
chromium_version=90.0.4430.93
ungoogled_chromium_version=90.0.4430.93
chromium_version=90.0.4430.212
ungoogled_chromium_version=90.0.4430.212
ungoogled_chromium_revision=1
ungoogled_chromium_android_revision=1

3
CHANGELOG.md

@ -1,3 +1,6 @@
# 90.0.4430.212-1
* Upstream security fixes
# 90.0.4430.93-1
* Add 64-bit webview for Trichrome
* Disable inline update by default

2
build.sh

@ -362,7 +362,7 @@ mkdir "${apk_out_folder}"
pushd src
if [[ "$TARGET" != "all" ]]; then
ninja -C "${output_folder}" "${TARGET_EXPANDED}"
if [[ "$TARGET" == "trichrome_chrome_bundle_target" ]] || [[ "$TARGET" == "chrome_modern_target" ]]; then
if [[ "$TARGET" == "trichrome_chrome_bundle_target" ]] || [[ "$TARGET" == "chrome_modern_target" ]] || [[ "$TARGET" == "trichrome_webview_target" ]]; then
../bundle_generate_apk.sh -o "${output_folder}" -a "${ARCH}" -t "${TARGET_EXPANDED}"
fi
find . -iname "*.apk" -exec cp -f {} ../"${apk_out_folder}" \;

17
bundle_generate_apk.sh

@ -70,7 +70,8 @@ if [[ "$ARCH" != "arm64" ]] && [[ "$ARCH" != "arm" ]] && [[ "$ARCH" != "x86" ]];
exit 4
fi
if [[ "$TARGET" != "$chrome_modern_target" ]] && [[ "$TARGET" != "$trichrome_chrome_bundle_target" ]] && [[ "$TARGET" != "$trichrome_chrome_64_bundle_target" ]]; then
if [[ "$TARGET" != "$chrome_modern_target" ]] && [[ "$TARGET" != "$trichrome_chrome_bundle_target" ]] && [[ "$TARGET" != "$trichrome_chrome_64_bundle_target" ]] \
&& [[ "$TARGET" != "$trichrome_webview_target" ]] && [[ "$TARGET" != "$trichrome_webview_64_target" ]]; then
echo "Wrong target"
exit 4
fi
@ -107,19 +108,21 @@ rm -rf release
mkdir release
cd release
$BUNDLETOOL build-apks --aapt2 $AAPT2 --bundle ../"$FILENAME".aab --output "$FILENAME".apks --mode=universal --ks $KEYSTORE --ks-pass file:$KEYSTORE_PASS --ks-key-alias uc
unzip "$FILENAME".apks universal.apk
mv universal.apk "${FILENAME_OUT}".apk
$APKSIGNER sign --ks $KEYSTORE --ks-pass file:$KEYSTORE_PASS --ks-key-alias uc --in "${FILENAME_OUT}".apk --out "${FILENAME_OUT}".apk
if [[ "$TARGET" != "$trichrome_webview_target" ]] && [[ "$TARGET" != "$trichrome_webview_64_target" ]]; then
$BUNDLETOOL build-apks --aapt2 $AAPT2 --bundle ../"$FILENAME".aab --output "$FILENAME".apks --mode=universal --ks $KEYSTORE --ks-pass file:$KEYSTORE_PASS --ks-key-alias uc
unzip "$FILENAME".apks universal.apk
mv universal.apk "${FILENAME_OUT}".apk
$APKSIGNER sign --ks $KEYSTORE --ks-pass file:$KEYSTORE_PASS --ks-key-alias uc --in "${FILENAME_OUT}".apk --out "${FILENAME_OUT}".apk
fi
if [[ "$TARGET" == "$trichrome_chrome_bundle_target" ]]; then
if [[ "$TARGET" == "$trichrome_chrome_bundle_target" ]] || [[ "$TARGET" == "$trichrome_webview_target" ]]; then
for app in TrichromeLibrary TrichromeWebView; do
if [ -f "../${app}.apk" ]; then
$APKSIGNER sign --ks $KEYSTORE --ks-pass file:$KEYSTORE_PASS --ks-key-alias uc --in "../${app}.apk" --out "${app}.apk"
fi
done
fi
if [[ "$TARGET" == "$trichrome_chrome_64_bundle_target" ]]; then
if [[ "$TARGET" == "$trichrome_chrome_64_bundle_target" ]] || [[ "$TARGET" == "$trichrome_webview_64_target" ]]; then
for app in TrichromeLibrary TrichromeWebView; do
if [ -f "../${app}64.apk" ]; then
$APKSIGNER sign --ks $KEYSTORE --ks-pass file:$KEYSTORE_PASS --ks-key-alias uc --in "../${app}64.apk" --out "${app}.apk"

32
patches/Bromite/AImageReader-CFI-crash-mitigations.patch

@ -8,22 +8,21 @@ This reverts commit dcd5a39518246eb999f1cc63bf1ec95d93fd5b2f.
Revert "Remove flags to enable/disable AImageReader."
This reverts commit 463fa0f2e3b9e418bc26e2c8954463f0b0f76634.
Disable AImageReader for ARM64/P and ARM64/Q
Restore GPU bug blacklist for AImageReader on ARM and Qualcomm CPUs
Restore the AImageReader blacklist for ARM/ARM64/Qualcomm chipsets which causes
Restore the AImageReader blacklist for ARM/Qualcomm chipsets which causes
crashes on Android 9 and 10 (at different code locations).
See discussions at:
* https://github.com/bromite/bromite/issues/445
* https://github.com/bromite/bromite/issues/814
* https://github.com/bromite/bromite/issues/1005
---
base/android/android_image_reader_compat.cc | 8 +++++++-
base/android/android_image_reader_compat.h | 4 ++++
chrome/browser/flag-metadata.json | 2 +-
gpu/config/gpu_driver_bug_list.json | 16 ++++++++++++++++
gpu/config/gpu_finch_features.cc | 11 ++++++++++-
gpu/config/gpu_finch_features.cc | 5 +++++
gpu/config/gpu_finch_features.h | 1 +
gpu/config/gpu_util.cc | 8 ++++++++
gpu/config/gpu_workaround_list.txt | 1 +
@ -31,7 +30,7 @@ See discussions at:
gpu/ipc/service/stream_texture_android.cc | 11 ++++++++++-
media/base/media_switches.cc | 4 ++++
media/base/media_switches.h | 1 +
12 files changed, 68 insertions(+), 4 deletions(-)
12 files changed, 63 insertions(+), 3 deletions(-)
--- a/base/android/android_image_reader_compat.cc
+++ b/base/android/android_image_reader_compat.cc
@ -80,15 +79,15 @@ See discussions at:
AndroidImageReader();
--- a/chrome/browser/flag-metadata.json
+++ b/chrome/browser/flag-metadata.json
@@ -1856,7 +1856,7 @@
@@ -1904,7 +1904,7 @@
{
"name": "enable-heavy-ad-intervention",
"owners": [ "johnidel", "jkarlin" ],
"name": "enable-image-reader",
"owners": [ "vikassoni", "liberato" ],
- "expiry_milestone": 90
+ "expiry_milestone": -1
},
{
"name": "enable-heuristic-stylus-palm-rejection",
"name": "enable-immersive-fullscreen-toolbar",
--- a/gpu/config/gpu_driver_bug_list.json
+++ b/gpu/config/gpu_driver_bug_list.json
@@ -3237,6 +3237,22 @@
@ -105,7 +104,7 @@ See discussions at:
+ "value": "10"
+ }
+ },
+ "gl_vendor": "ARM.*",
+ "gl_vendor": "ARM.*|Qualcomm.*",
+ "features": [
+ "disable_aimagereader"
+ ]
@ -128,19 +127,6 @@ See discussions at:
// Used to limit GL version to 2.0 for skia raster on Android.
const base::Feature kUseGles2ForOopR{"UseGles2ForOopR",
base::FEATURE_DISABLED_BY_DEFAULT};
@@ -70,7 +75,11 @@ const base::Feature kWebViewSurfaceContr
// Use AImageReader for MediaCodec and MediaPlyer on android.
const base::Feature kAImageReader{"AImageReader",
- base::FEATURE_ENABLED_BY_DEFAULT};
+#ifdef ARCH_CPU_ARM64
+ base::FEATURE_DISABLED_BY_DEFAULT};
+#else
+ base::FEATURE_ENABLED_BY_DEFAULT};
+#endif
// If webview-draw-functor-uses-vulkan is set, use vulkan for composite and
// raster.
--- a/gpu/config/gpu_finch_features.h
+++ b/gpu/config/gpu_finch_features.h
@@ -17,6 +17,7 @@ namespace features {

68
patches/Bromite/Add-a-proxy-configuration-page.patch

@ -10,7 +10,7 @@ Store proxy settings in LocalState instead of Profile, so that proxy is used
for SimpleURLLoaders as well.
---
chrome/android/java/res/values/values.xml | 3
chrome/android/java/res/xml/privacy_preferences.xml | 4
chrome/android/java/res/xml/privacy_preferences.xml | 11
chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java | 3
chrome/browser/autocomplete/chrome_autocomplete_provider_client.cc | 2
chrome/browser/browser_resources.grd | 6
@ -33,7 +33,7 @@ for SimpleURLLoaders as well.
components/proxy_config/proxy_config_dictionary.h | 7
net/proxy_resolution/proxy_config.cc | 52 +
net/proxy_resolution/proxy_config.h | 3
24 files changed, 995 insertions(+), 15 deletions(-)
24 files changed, 999 insertions(+), 18 deletions(-)
create mode 100644 chrome/browser/resources/proxy_config.css
create mode 100644 chrome/browser/resources/proxy_config.html
create mode 100644 chrome/browser/resources/proxy_config.js
@ -54,31 +54,51 @@ for SimpleURLLoaders as well.
<integer name="download_infobar_sweep_down_delay">800</integer>
--- a/chrome/android/java/res/xml/privacy_preferences.xml
+++ b/chrome/android/java/res/xml/privacy_preferences.xml
@@ -7,6 +7,10 @@
xmlns:app="http://schemas.android.com/apk/res-auto"
android:orderingFromXml="false">
@@ -39,21 +39,26 @@
android:title="@string/settings_secure_dns_title"
android:fragment="org.chromium.chrome.browser.privacy.secure_dns.SecureDnsSettings"
android:order="5"/>
+ <org.chromium.chrome.browser.about_settings.HyperlinkPreference
+ android:key="proxy"
+ android:title="@string/proxy_title"
+ app:url="@string/proxy_url" />
<org.chromium.components.browser_ui.settings.ChromeSwitchPreference
android:key="can_make_payment"
android:title="@string/can_make_payment_title"
+ app:url="@string/proxy_url"
+ android:order="6"/>
<Preference
android:key="clear_browsing_data"
android:title="@string/clear_browsing_data_title"
android:summary="@string/clear_browsing_data_summary"
android:fragment="org.chromium.chrome.browser.browsing_data.ClearBrowsingDataTabsFragment"
- android:order="6"/>
+ android:order="7"/>
<Preference
android:key="safe_browsing"
android:title="@string/prefs_safe_browsing_title"
android:summary="@string/prefs_safe_browsing_summary"
android:fragment="org.chromium.chrome.browser.safe_browsing.settings.SafeBrowsingSettingsFragment"
- android:order="7"/>
+ android:order="8"/>
<Preference
android:key="privacy_sandbox"
android:title="@string/prefs_privacy_sandbox"
android:fragment="org.chromium.chrome.browser.privacy_sandbox.PrivacySandboxSettingsFragment"
- android:order="8"/>
+ android:order="9"/>
</PreferenceScreen>
--- a/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java
@@ -58,9 +58,10 @@ public class PrivacySettings
@@ -57,10 +57,11 @@ public class PrivacySettings
private static final String PREF_SAFE_BROWSING = "safe_browsing";
private static final String PREF_CLEAR_BROWSING_DATA = "clear_browsing_data";
private static final String PREF_PRIVACY_SANDBOX = "privacy_sandbox";
private static final String PREF_CLOSE_TABS_ON_EXIT = "close_tabs_on_exit";
+ private static final String PREF_PROXY_OPTIONS = "proxy";
private static final String PREF_PRIVACY_SANDBOX = "privacy_sandbox";
private static final String[] NEW_PRIVACY_PREFERENCE_ORDER = {PREF_CLEAR_BROWSING_DATA,
PREF_SAFE_BROWSING, PREF_CAN_MAKE_PAYMENT, PREF_NETWORK_PREDICTIONS, PREF_USAGE_STATS,
- PREF_CLOSE_TABS_ON_EXIT,
+ PREF_CLOSE_TABS_ON_EXIT, PREF_PROXY_OPTIONS,
PREF_SECURE_DNS, PREF_DO_NOT_TRACK, PREF_PRIVACY_SANDBOX};
- PREF_SECURE_DNS, PREF_CLOSE_TABS_ON_EXIT, PREF_DO_NOT_TRACK, PREF_PRIVACY_SANDBOX};
+ PREF_SECURE_DNS, PREF_CLOSE_TABS_ON_EXIT, PREF_PROXY_OPTIONS, PREF_DO_NOT_TRACK, PREF_PRIVACY_SANDBOX};
private ManagedPreferenceDelegate mManagedPreferenceDelegate;
--- a/chrome/browser/autocomplete/chrome_autocomplete_provider_client.cc
+++ b/chrome/browser/autocomplete/chrome_autocomplete_provider_client.cc
@@ -331,6 +331,8 @@ std::vector<base::string16>
@ -169,14 +189,14 @@ for SimpleURLLoaders as well.
};
--- a/chrome/browser/prefs/browser_prefs.cc
+++ b/chrome/browser/prefs/browser_prefs.cc
@@ -411,6 +411,8 @@
#include "chrome/browser/media/feeds/media_feeds_service.h"
#endif
@@ -155,6 +155,8 @@
#include "printing/buildflags/buildflags.h"
#include "rlz/buildflags/buildflags.h"
+#include "chrome/browser/net/proxy_service_factory.h"
+
#if BUILDFLAG(ENABLE_SESSION_SERVICE)
#include "chrome/browser/sessions/session_service_log.h"
#if BUILDFLAG(ENABLE_BACKGROUND_MODE)
#include "chrome/browser/background/background_mode_manager.h"
#endif
@@ -744,6 +746,8 @@ void RegisterLocalState(PrefRegistrySimp
PluginsResourceService::RegisterPrefs(registry);
@ -543,14 +563,14 @@ for SimpleURLLoaders as well.
+ renderConfig_: function() {
+ if (this.currentConfig.auto_detect) {
+ $(kIdModeAutoDetect).checked = true;
+ } else if (this.currentConfig.rules.type == "none") {
+ $(kIdModeEmpty).checked = true;
+ } else if (this.currentConfig.rules.type == "direct") {
+ $(kIdModeDirect).checked = true;
+ } else if (this.currentConfig.hasOwnProperty('pac_url')) {
+ $(kIdPacURL).value = this.currentConfig.pac_url;
+ $(kIdPacMandatory).checked = this.currentConfig.pac_mandatory;
+ $(kIdModeUsePacURL).checked = true;
+ } else if (this.currentConfig.rules.type == "none") {
+ $(kIdModeEmpty).checked = true;
+ } else if (this.currentConfig.rules.type == "direct") {
+ $(kIdModeDirect).checked = true;
+ } else {
+ $(kIdBypassRules).value = this.currentConfig.rules.bypass_rules;
+ $(kIdReverseBypass).checked = this.currentConfig.rules.reverse_bypass;

796
patches/Bromite/Add-bookmark-import-export-actions.patch

File diff suppressed because it is too large

39
patches/Bromite/Add-exit-menu-item.patch

@ -4,13 +4,12 @@ Subject: Add exit menu item
Corrected Exit functionality
---
chrome/android/java/res/menu/main_menu.xml | 5 +++++
chrome/android/java/res/menu/main_menu_regroup.xml | 3 +++
chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java | 3 +++
chrome/android/java/res/menu/main_menu.xml | 6 ++++++
chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java | 4 ++++
chrome/android/java/src/org/chromium/chrome/browser/app/ChromeActivity.java | 6 ++++++
chrome/android/java/src/org/chromium/chrome/browser/init/ChromeLifetimeController.java | 6 +++++-
chrome/browser/ui/android/strings/android_chrome_strings.grd | 3 +++
6 files changed, 25 insertions(+), 1 deletion(-)
5 files changed, 24 insertions(+), 1 deletion(-)
--- a/chrome/android/java/res/menu/main_menu.xml
+++ b/chrome/android/java/res/menu/main_menu.xml
@ -24,38 +23,28 @@ Corrected Exit functionality
</group>
<!-- Items shown only in the tab switcher -->
@@ -145,6 +148,8 @@
@@ -145,6 +148,9 @@
<item android:id="@id/preferences_id"
android:title="@string/menu_settings"
android:icon="@drawable/settings_cog" />
+ <item android:id="@+id/exit_id"
+ android:title="@string/menu_exit" />
</group>
<!-- Items shown only in the tab switcher when start surface is enabled -->
--- a/chrome/android/java/res/menu/main_menu_regroup.xml
+++ b/chrome/android/java/res/menu/main_menu_regroup.xml
@@ -184,6 +184,9 @@
android:icon="@drawable/vr_headset" />
<item android:id="@+id/managed_by_menu_id"
android:title="@string/managed" />
+ <item android:id="@+id/exit_id"
+ android:title="@string/menu_exit"
+ android:icon="@drawable/ic_exit_to_app_white_24dp" />
</group>
<!-- Items shown only in the tab switcher -->
<!-- Items shown only in the tab switcher when start surface is enabled -->
--- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -58,6 +58,7 @@ import org.chromium.chrome.browser.Inten
import org.chromium.chrome.browser.IntentHandler.TabOpenType;
import org.chromium.chrome.browser.accessibility_tab_switcher.OverviewListLayout;
import org.chromium.chrome.browser.app.ChromeActivity;
@@ -191,6 +191,8 @@ import java.lang.annotation.RetentionPol
import java.util.List;
import java.util.Locale;
+import org.chromium.chrome.browser.ApplicationLifetime;
import org.chromium.chrome.browser.app.metrics.LaunchCauseMetrics;
import org.chromium.chrome.browser.app.metrics.TabbedActivityLaunchCauseMetrics;
import org.chromium.chrome.browser.app.tabmodel.AsyncTabParamsManagerSingleton;
@@ -1858,6 +1859,8 @@ public class ChromeTabbedActivity extend
+
/**
* This is the main activity for ChromeMobile when not running in document mode. All the tabs
* are accessible via a chrome specific tab switching UI.
@@ -1858,6 +1860,8 @@ public class ChromeTabbedActivity extend
} else if (id == R.id.close_tab) {
getCurrentTabModel().closeTab(currentTab, true, false, true);
RecordUserAction.record("MobileTabClosed");

14
patches/Bromite/Add-flags-to-disable-device-motion-orientation-APIs.patch

@ -108,15 +108,15 @@ legacy acceleration events.
CONTENT_EXPORT extern const base::Feature
--- a/third_party/blink/public/platform/web_runtime_features.h
+++ b/third_party/blink/public/platform/web_runtime_features.h
@@ -104,6 +104,8 @@ class WebRuntimeFeatures {
BLINK_PLATFORM_EXPORT static void EnableCSSHexAlphaColor(bool);
BLINK_PLATFORM_EXPORT static void EnableSameSiteByDefaultCookies(bool);
BLINK_PLATFORM_EXPORT static void EnableScrollTopLeftInterop(bool);
@@ -100,6 +100,8 @@ class WebRuntimeFeatures {
BLINK_PLATFORM_EXPORT static void EnableCookiesWithoutSameSiteMustBeSecure(
bool);
BLINK_PLATFORM_EXPORT static void EnableCanvas2dImageChromium(bool);
+ BLINK_PLATFORM_EXPORT static void EnableDeviceMotion(bool);
+ BLINK_PLATFORM_EXPORT static void EnableDeviceOrientation(bool);
BLINK_PLATFORM_EXPORT static void EnableKeyboardAccessibleTooltip(bool);
BLINK_PLATFORM_EXPORT static void EnableKeyboardFocusableScrollers(bool);
BLINK_PLATFORM_EXPORT static void EnableDatabase(bool);
BLINK_PLATFORM_EXPORT static void EnableCooperativeScheduling(bool);
BLINK_PLATFORM_EXPORT static void EnableCSSHexAlphaColor(bool);
BLINK_PLATFORM_EXPORT static void EnableSameSiteByDefaultCookies(bool);
--- a/third_party/blink/renderer/modules/modules_initializer.cc
+++ b/third_party/blink/renderer/modules/modules_initializer.cc
@@ -222,9 +222,13 @@ void ModulesInitializer::OnClearWindowOb

26
patches/Bromite/Add-option-to-not-persist-tabs-across-sessions.patch

@ -3,11 +3,11 @@ Date: Sat, 7 Sep 2019 15:07:42 +0200
Subject: Add option to not persist tabs across sessions
---
chrome/android/java/res/xml/privacy_preferences.xml | 16 ++++++----
chrome/android/java/res/xml/privacy_preferences.xml | 16 ++++++---
chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java | 4 +-
chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java | 16 +++++++++-
chrome/android/java/src/org/chromium/chrome/browser/privacy/settings/PrivacySettings.java | 17 ++++++++--
chrome/browser/ui/android/strings/android_chrome_strings.grd | 6 +++
4 files changed, 35 insertions(+), 7 deletions(-)
4 files changed, 35 insertions(+), 8 deletions(-)
--- a/chrome/android/java/res/xml/privacy_preferences.xml
+++ b/chrome/android/java/res/xml/privacy_preferences.xml
@ -20,7 +20,7 @@ Subject: Add option to not persist tabs across sessions
+ android:title="@string/close_tabs_on_exit_title"
+ android:summary="@string/close_tabs_on_exit_summary"
+ android:defaultValue="false"
+ android:order="3" />
+ android:order="3"/>
<Preference
android:fragment="org.chromium.chrome.browser.privacy.settings.DoNotTrackSettings"
android:key="do_not_track"
@ -56,7 +56,7 @@ Subject: Add option to not persist tabs across sessions
</PreferenceScreen>
--- a/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/ChromeTabbedActivity.java
@@ -1128,8 +1128,10 @@ public class ChromeTabbedActivity extend
@@ -1129,8 +1129,10 @@ public class ChromeTabbedActivity extend
boolean hadCipherData =
CipherFactory.getInstance().restoreFromBundle(getSavedInstanceState());
@ -87,18 +87,20 @@ Subject: Add option to not persist tabs across sessions
import org.chromium.chrome.R;
import org.chromium.chrome.browser.feedback.HelpAndFeedbackLauncherImpl;
import org.chromium.chrome.browser.flags.ChromeFeatureList;
@@ -54,8 +57,10 @@ public class PrivacySettings
@@ -53,10 +56,11 @@ public class PrivacySettings
private static final String PREF_DO_NOT_TRACK = "do_not_track";
private static final String PREF_SAFE_BROWSING = "safe_browsing";
private static final String PREF_CLEAR_BROWSING_DATA = "clear_browsing_data";
private static final String PREF_PRIVACY_SANDBOX = "privacy_sandbox";
+ private static final String PREF_CLOSE_TABS_ON_EXIT = "close_tabs_on_exit";
private static final String PREF_PRIVACY_SANDBOX = "privacy_sandbox";
private static final String[] NEW_PRIVACY_PREFERENCE_ORDER = {PREF_CLEAR_BROWSING_DATA,
PREF_SAFE_BROWSING, PREF_CAN_MAKE_PAYMENT, PREF_NETWORK_PREDICTIONS, PREF_USAGE_STATS,
+ PREF_CLOSE_TABS_ON_EXIT,
PREF_SECURE_DNS, PREF_DO_NOT_TRACK, PREF_PRIVACY_SANDBOX};
- PREF_SECURE_DNS, PREF_DO_NOT_TRACK, PREF_PRIVACY_SANDBOX};
+ PREF_SECURE_DNS, PREF_CLOSE_TABS_ON_EXIT, PREF_DO_NOT_TRACK, PREF_PRIVACY_SANDBOX};
private ManagedPreferenceDelegate mManagedPreferenceDelegate;
@@ -166,7 +171,11 @@ public class PrivacySettings
@@ -166,7 +170,11 @@ public class PrivacySettings
@Override
public boolean onPreferenceChange(Preference preference, Object newValue) {
String key = preference.getKey();
@ -111,7 +113,7 @@ Subject: Add option to not persist tabs across sessions
UserPrefs.get(Profile.getLastUsedRegularProfile())
.setBoolean(Pref.CAN_MAKE_PAYMENT_ENABLED, (boolean) newValue);
} else if (PREF_NETWORK_PREDICTIONS.equals(key)) {
@@ -236,6 +245,11 @@ public class PrivacySettings
@@ -236,6 +244,11 @@ public class PrivacySettings
privacySandboxPreference.setSummary(
PrivacySandboxSettingsFragment.getStatusString(getContext()));
}
@ -125,7 +127,7 @@ Subject: Add option to not persist tabs across sessions
private ChromeManagedPreferenceDelegate createManagedPreferenceDelegate() {
--- a/chrome/browser/ui/android/strings/android_chrome_strings.grd
+++ b/chrome/browser/ui/android/strings/android_chrome_strings.grd
@@ -3803,6 +3803,12 @@ Data from your Incognito session will on
@@ -3815,6 +3815,12 @@ Data from your Incognito session will on
<message name="IDS_CONTEXTMENU_IMAGE_TITLE" desc="The title of a context menu tab when the item pressed contains more than one type. This indicates that all the actions are related to the image.">
IMAGE
</message>

24
patches/Bromite/DoH-secure-mode-by-default.patch

@ -3,13 +3,13 @@ Date: Sat, 26 Sep 2020 14:23:19 +0100
Subject: DoH secure mode by default
---
chrome/android/java/src/org/chromium/chrome/browser/policy/EnterpriseInfo.java | 2 -
chrome/browser/net/stub_resolver_config_reader.cc | 17 ----------
2 files changed, 2 insertions(+), 17 deletions(-)
.../browser/net/stub_resolver_config_reader.cc | 17 +----------------
1 file changed, 1 insertion(+), 16 deletions(-)
diff --git a/chrome/browser/net/stub_resolver_config_reader.cc b/chrome/browser/net/stub_resolver_config_reader.cc
--- a/chrome/browser/net/stub_resolver_config_reader.cc
+++ b/chrome/browser/net/stub_resolver_config_reader.cc
@@ -154,7 +154,7 @@ StubResolverConfigReader::StubResolverCo
@@ -154,7 +154,7 @@ StubResolverConfigReader::StubResolverConfigReader(PrefService* local_state,
if (entries.count("[email protected]")) {
// The user has "Enabled" selected.
local_state_->SetString(prefs::kDnsOverHttpsMode,
@ -18,7 +18,7 @@ Subject: DoH secure mode by default
} else if (entries.count("[email protected]")) {
// The user has "Disabled" selected.
local_state_->SetString(prefs::kDnsOverHttpsMode,
@@ -328,22 +328,7 @@ SecureDnsConfig StubResolverConfigReader
@@ -328,22 +328,7 @@ SecureDnsConfig StubResolverConfigReader::GetAndUpdateConfiguration(
check_parental_controls = false;
}
@ -41,14 +41,6 @@ Subject: DoH secure mode by default
parental_controls_checked_ = true;
}
--- a/chrome/android/java/src/org/chromium/chrome/browser/policy/EnterpriseInfo.java
+++ b/chrome/android/java/src/org/chromium/chrome/browser/policy/EnterpriseInfo.java
@@ -43,7 +43,7 @@ public class EnterpriseInfo {
private OwnedState mOwnedState;
private Queue<Callback<OwnedState>> mCallbackList;
- private boolean mSkipAsyncCheckForTesting;
+ private boolean mSkipAsyncCheckForTesting = true;
/** A simple tuple to hold onto named fields about the state of ownership. */
public static class OwnedState {
--
2.17.1

9
patches/Bromite/Inject-scripts-for-AMP-tracking-ads-and-video.patch

@ -8,13 +8,13 @@ Set proper injection script nonce
Send a random key press to circumvent idle status detection
---
third_party/blink/renderer/core/dom/build.gni | 2
third_party/blink/renderer/core/dom/document.cc | 62 ++++++++++
third_party/blink/renderer/core/dom/document.cc | 61 ++++++++++
third_party/blink/renderer/core/dom/document.h | 3
third_party/blink/renderer/core/dom/extensions/anti_amp_cure.h | 6
third_party/blink/renderer/core/dom/extensions/video_bg_play.h | 6
third_party/blink/renderer/core/html/html_script_element.cc | 5
third_party/blink/renderer/core/html/html_script_element.h | 1
7 files changed, 85 insertions(+)
7 files changed, 84 insertions(+)
create mode 100644 third_party/blink/renderer/core/dom/extensions/anti_amp_cure.h
create mode 100644 third_party/blink/renderer/core/dom/extensions/video_bg_play.h
@ -110,14 +110,13 @@ Send a random key press to circumvent idle status detection
void Document::FinishedParsing() {
DCHECK(!GetScriptableDocumentParser() || !parser_->IsParsing());
DCHECK(!GetScriptableDocumentParser() || ready_state_ != kLoading);
@@ -6920,6 +6978,10 @@ void Document::FinishedParsing() {
@@ -6920,6 +6978,9 @@ void Document::FinishedParsing() {
frame->Loader().FinishedParsing();
+ if (!IsPrefetchOnly()) {
+ injectScripts();
+ injectScripts();
+ }
+
TRACE_EVENT_INSTANT1("devtools.timeline", "MarkDOMContent",
TRACE_EVENT_SCOPE_THREAD, "data",
inspector_mark_load_event::Data(frame));

8
patches/src-fix/fix-safe-browsing-prefs.patch

@ -300,7 +300,7 @@ Subject: Fix build error caused by the removal of safe_browsing_prefs.h
]
--- a/chrome/browser/android/tab_web_contents_delegate_android.cc
+++ b/chrome/browser/android/tab_web_contents_delegate_android.cc
@@ -171,8 +171,6 @@ void TabWebContentsDelegateAndroid::Port
@@ -172,8 +172,6 @@ void TabWebContentsDelegateAndroid::Port
InfoBarService::CreateForWebContents(portal_contents);
PrefsTabHelper::CreateForWebContents(portal_contents);
DataReductionProxyTabHelper::CreateForWebContents(portal_contents);
@ -311,7 +311,7 @@ Subject: Fix build error caused by the removal of safe_browsing_prefs.h
void TabWebContentsDelegateAndroid::RunFileChooser(
--- a/weblayer/browser/content_browser_client_impl.cc
+++ b/weblayer/browser/content_browser_client_impl.cc
@@ -492,8 +492,7 @@ ContentBrowserClientImpl::CreateURLLoade
@@ -493,8 +493,7 @@ ContentBrowserClientImpl::CreateURLLoade
#if defined(OS_ANDROID)
BrowserContextImpl* browser_context_impl =
static_cast<BrowserContextImpl*>(browser_context);
@ -321,7 +321,7 @@ Subject: Fix build error caused by the removal of safe_browsing_prefs.h
if (is_safe_browsing_enabled) {
bool is_real_time_lookup_enabled =
@@ -815,16 +814,6 @@ ContentBrowserClientImpl::CreateThrottle
@@ -821,16 +820,6 @@ ContentBrowserClientImpl::CreateThrottle
#if defined(OS_ANDROID)
if (handle->IsInMainFrame()) {
@ -338,7 +338,7 @@ Subject: Fix build error caused by the removal of safe_browsing_prefs.h
}
#endif
return throttles;
@@ -885,11 +874,6 @@ void ContentBrowserClientImpl::ExposeInt
@@ -891,11 +880,6 @@ void ContentBrowserClientImpl::ExposeInt
};
registry->AddInterface(base::BindRepeating(create_spellcheck_host),
content::GetUIThreadTaskRunner({}));

Loading…
Cancel
Save