lists.torproject.org
Sign In Sign Up
Manage this list Sign In Sign Up

Keyboard Shortcuts

Thread View

  • j: Next unread message
  • k: Previous unread message
  • j a: Jump to all threads
  • j l: Jump to MailingList overview

tbb-commits

Thread Start a new thread
Threads by month
  • ----- 2026 -----
  • March
  • February
  • January
  • ----- 2025 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2024 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2023 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2022 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2021 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2020 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2019 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2018 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2017 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2016 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2015 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
  • January
  • ----- 2014 -----
  • December
  • November
  • October
  • September
  • August
  • July
  • June
  • May
  • April
  • March
  • February
tbb-commits@lists.torproject.org

  • 1 participants
  • 20113 discussions
[tor-browser-build/maint-8.5] Don't forget to pick up Torbutton for mobile
by gk@torproject.org 01 Sep '19

01 Sep '19
commit 9fc24ea9dc2b0f1f5f03db1b741a07754840b8ee Author: Georg Koppen <gk(a)torproject.org> Date: Sun Sep 1 20:03:53 2019 +0000 Don't forget to pick up Torbutton for mobile --- projects/firefox/config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/projects/firefox/config b/projects/firefox/config index 41c6ad5..2d022aa 100644 --- a/projects/firefox/config +++ b/projects/firefox/config @@ -1,7 +1,7 @@ # vim: filetype=yaml sw=2 version: '[% c("abbrev") %]' filename: 'firefox-[% c("version") %]-[% c("var/osname") %]-[% c("var/build_id") %]' -git_hash: 'tor-browser-[% c("var/firefox_version") %]-[% c("var/torbrowser_branch") %]-2-build1' +git_hash: 'tor-browser-[% c("var/firefox_version") %]-[% c("var/torbrowser_branch") %]-2-build2' tag_gpg_id: 1 git_url: https://git.torproject.org/tor-browser.git git_submodule: 1
1 0
0 0
[tor-browser/tor-browser-60.9.0esr-8.5-2] Pick up Torbutton 2.1.13
by gk@torproject.org 01 Sep '19

01 Sep '19
commit 944a0bc18ba68f5cabee167efe0e0f1045bc9d5d Author: Georg Koppen <gk(a)torproject.org> Date: Sun Sep 1 20:01:34 2019 +0000 Pick up Torbutton 2.1.13 --- toolkit/torproject/torbutton | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolkit/torproject/torbutton b/toolkit/torproject/torbutton index 40b7d1375031..850024dd1bef 160000 --- a/toolkit/torproject/torbutton +++ b/toolkit/torproject/torbutton @@ -1 +1 @@ -Subproject commit 40b7d13750313a702a044db430622d933b09fb9e +Subproject commit 850024dd1bef30256f0ef443d4761aa43a3b84f6
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 30573 - Sanitize old tabs and wait for tor before opening new tabs
by gk@torproject.org 31 Aug '19

31 Aug '19
commit dd5be6e82f301448b2c4d3290beeb3729e943817 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Wed May 29 14:05:07 2019 +0000 Bug 30573 - Sanitize old tabs and wait for tor before opening new tabs --- .../base/java/org/mozilla/gecko/BrowserApp.java | 4 +- .../base/java/org/mozilla/gecko/GeckoApp.java | 55 +++++++++++++++++++++- 2 files changed, 57 insertions(+), 2 deletions(-) diff --git a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java index c2a463ad6ed1..f03548e30ced 100644 --- a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java @@ -1134,7 +1134,7 @@ public class BrowserApp extends GeckoApp * * mTorStatus provides synchronization across threads. */ - private boolean checkTorIsStarted() { + public boolean checkTorIsStarted() { // When tor is started, true. Otherwise, false mTorStatus = false; BroadcastReceiver br = setupReceiveTorIsStartedAsync(); @@ -2120,6 +2120,7 @@ public class BrowserApp extends GeckoApp finishAndShutdown(/* restart */ false); } } + super.handleMessage(event, message, callback); break; case "Sanitize:OpenTabs": @@ -3019,6 +3020,7 @@ public class BrowserApp extends GeckoApp // If we finished, then Tor bootstrapped 100% mTorNeedsStart = false; + EventDispatcher.getInstance().dispatch("Tor:Ready", null); // When bootstrapping completes, check if the Firstrun (onboarding) screens // should be shown. diff --git a/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java b/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java index 9c66f56b0485..388d7c3b89a3 100644 --- a/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java @@ -193,6 +193,10 @@ public abstract class GeckoApp extends GeckoActivity protected Menu mMenu; protected boolean mIsRestoringActivity; + protected boolean mIsSanitizeTabsEnabled = false; + protected boolean mIsSanitizeCompleted = false; + protected Object mIsSanitizeCompletedLock = new Object(); + /** Tells if we're aborting app launch, e.g. if this is an unsupported device configuration. */ protected boolean mIsAbortingAppLaunch; @@ -604,6 +608,12 @@ public abstract class GeckoApp extends GeckoActivity for (final String clear : clearSet) { clearObj.putBoolean(clear, true); } + + synchronized (mIsSanitizeCompletedLock) { + mIsSanitizeTabsEnabled = clearSet.contains("private.data.openTabs"); + mIsSanitizeCompleted = false; + } + return clearObj; } @@ -788,6 +798,11 @@ public abstract class GeckoApp extends GeckoActivity notifyAll(); } + } else if ("Sanitize:Finished".equals(event)) { + synchronized (mIsSanitizeCompletedLock) { + mIsSanitizeCompleted = true; + } + } else if ("SystemUI:Visibility".equals(event)) { if (message.getBoolean("visible", true)) { mMainLayout.setSystemUiVisibility(View.SYSTEM_UI_FLAG_VISIBLE); @@ -1628,7 +1643,45 @@ public abstract class GeckoApp extends GeckoActivity loadStartupTab(Tabs.LOADURL_NEW_TAB, action); } else { final int flags = getNewTabFlags(); - loadStartupTab(passedUri, intent, flags); + final BrowserApp browserApp = (BrowserApp) GeckoApp.this; + + synchronized (mIsSanitizeCompletedLock) { + // If OpenTabs will be sanitized, then load the tab after Sanitize:Finished + // is received. If Tor isn't started, then load tabs after Tor:Ready, too. And + // if Gecko isn't loaded, then wait until the profile is loaded (avoiding the race + // between loading the page and checking if |browser.privatebrowsing.autoStart| is true. + EventDispatcher.getInstance().registerUiThreadListener(new BundleEventListener() { + // isSanitized is true if Sanitizing is enable and it is completed or if Sanitizing is disabled. + private boolean isSanitized = (mIsSanitizeTabsEnabled && mIsSanitizeCompleted) || !mIsSanitizeTabsEnabled; + private boolean isTorReady = browserApp.checkTorIsStarted(); + private boolean isGeckoReady = GeckoThread.isRunning(); + + @Override + public void handleMessage(String event, GeckoBundle message, EventCallback callback) { + if ("Sanitize:Finished".equals(event)) { + EventDispatcher.getInstance().unregisterUiThreadListener(this, "Sanitize:Finished"); + isSanitized = true; + + } else if ("Tor:Ready".equals(event)) { + EventDispatcher.getInstance().unregisterUiThreadListener(this, "Tor:Ready"); + isTorReady = true; + } else if ("Gecko:Ready".equals(event)) { + EventDispatcher.getInstance().unregisterUiThreadListener(this, "Gecko:Ready"); + isGeckoReady = true; + } else if ("Tor:CheckIfReady".equals(event)) { + EventDispatcher.getInstance().unregisterUiThreadListener(this, "Tor:CheckIfReady"); + } + + if (isSanitized && isTorReady && isGeckoReady) { + loadStartupTab(passedUri, intent, flags); + } + } + }, "Sanitize:Finished", "Tor:Ready", "Tor:CheckIfReady", "Gecko:Ready"); + + // Run the event callback now, just in case Tor:Ready and Sanitize:Finished were + // dispatched before the listener was created. + EventDispatcher.getInstance().dispatch("Tor:CheckIfReady", null); + } } } });
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Load torbutton in browser.xul on Android
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 805ff051656dc22d11de026e01223352f39e7380 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Fri Aug 30 10:17:25 2019 -0400 Load torbutton in browser.xul on Android --- mobile/android/chrome/content/browser.js | 4 ++++ mobile/android/chrome/content/browser.xul | 1 + 2 files changed, 5 insertions(+) diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index f8e9399f51c4..7fcee29f0c3c 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -243,6 +243,8 @@ var lazilyLoadedBrowserScripts = [ ["CastingApps", "chrome://browser/content/CastingApps.js"], ["RemoteDebugger", "chrome://browser/content/RemoteDebugger.js"], ["gViewSourceUtils", "chrome://global/content/viewSourceUtils.js"], + ["torbuttonUtils", "chrome://torbutton/content/torbutton_utils.js"], + ["torbutton", "chrome://torbutton/content/torbutton.js"], ]; lazilyLoadedBrowserScripts.forEach(function(aScript) { @@ -763,6 +765,8 @@ var BrowserApp = { true ); + torbutton_init(); + // We can't delay registering WebChannel listeners: if the first page is // about:accounts, which can happen when starting the Firefox Account flow // from the first run experience, or via the Firefox Account Status diff --git a/mobile/android/chrome/content/browser.xul b/mobile/android/chrome/content/browser.xul index 8072a7a1c6e5..71aa04df0ebf 100644 --- a/mobile/android/chrome/content/browser.xul +++ b/mobile/android/chrome/content/browser.xul @@ -4,6 +4,7 @@ - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> <?xml-stylesheet href="chrome://browser/content/browser.css" type="text/css"?> +<?xml-stylesheet href="chrome://torbutton/skin/torbutton.css" type="text/css"?> <window id="main-window" onload="BrowserApp.startup();"
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Continue using non-adaptive icons and don't allow clear-text traffic
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 144e2f64a8dbb3c84150d44fcdbab989f4aa4184 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Mon Jul 22 13:41:22 2019 +0000 Continue using non-adaptive icons and don't allow clear-text traffic --- mobile/android/base/AndroidManifest.xml.in | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/mobile/android/base/AndroidManifest.xml.in b/mobile/android/base/AndroidManifest.xml.in index 5f231e9ba83c..39c1899daa1f 100644 --- a/mobile/android/base/AndroidManifest.xml.in +++ b/mobile/android/base/AndroidManifest.xml.in @@ -24,13 +24,11 @@ #include FennecManifest_permissions.xml.in <application android:label="@string/moz_app_displayname" - android:icon="@mipmap/ic_launcher" - android:logo="@drawable/logo" + android:icon="@drawable/icon" android:name="@MOZ_ANDROID_APPLICATION_CLASS@" android:hardwareAccelerated="true" android:supportsRtl="true" android:allowBackup="false" - android:usesCleartextTraffic="true" > <meta-data android:name="com.sec.android.support.multiwindow" android:value="true"/>
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 31058: Remove Linus' default bridges
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 225b1f3bb0a021b52b69b915400266478fb2a264 Author: Georg Koppen <gk(a)torproject.org> Date: Tue Jul 2 07:57:08 2019 +0000 Bug 31058: Remove Linus' default bridges There are no default obfs3 bridges remaining after Linus' ones are gone. Remove the UI and localization. --- .../res/layout/preference_tor_network_select_bridge_type.xml | 11 ----------- .../java/org/mozilla/gecko/torbootstrap/TorPreferences.java | 3 --- mobile/android/base/locales/en-US/torbrowser_strings.dtd | 1 - mobile/android/base/strings.xml.in | 1 - 4 files changed, 16 deletions(-) diff --git a/mobile/android/app/src/main/res/layout/preference_tor_network_select_bridge_type.xml b/mobile/android/app/src/main/res/layout/preference_tor_network_select_bridge_type.xml index 2c1632bb8268..4ef5925e233d 100644 --- a/mobile/android/app/src/main/res/layout/preference_tor_network_select_bridge_type.xml +++ b/mobile/android/app/src/main/res/layout/preference_tor_network_select_bridge_type.xml @@ -74,17 +74,6 @@ android:textSize="16sp" android:text="@string/pref_bridges_type_meek_azure"/> <include layout="@xml/separator" /> - <RadioButton android:id="@+id/radio_pref_bridges_obfs3" - android:layout_width="match_parent" - android:layout_height="wrap_content" - android:layout_marginTop="10sp" - android:layout_marginBottom="10sp" - android:buttonTint="@color/tor_bridges_select_builtin" - android:fontFamily="Roboto-Regular" - android:textColor="#DE000000" - android:textSize="16sp" - android:text="@string/pref_bridges_type_obfs3"/> - <include layout="@xml/separator" /> </RadioGroup> </LinearLayout> diff --git a/mobile/android/base/java/org/mozilla/gecko/torbootstrap/TorPreferences.java b/mobile/android/base/java/org/mozilla/gecko/torbootstrap/TorPreferences.java index 9e74c49f3f91..cb37f3867ca4 100644 --- a/mobile/android/base/java/org/mozilla/gecko/torbootstrap/TorPreferences.java +++ b/mobile/android/base/java/org/mozilla/gecko/torbootstrap/TorPreferences.java @@ -679,9 +679,6 @@ public class TorPreferences extends AppCompatPreferenceActivity { case "meek": buttonId = R.id.radio_pref_bridges_meek_azure; break; - case "obfs3": - buttonId = R.id.radio_pref_bridges_obfs3; - break; } if (buttonId != -1) { diff --git a/mobile/android/base/locales/en-US/torbrowser_strings.dtd b/mobile/android/base/locales/en-US/torbrowser_strings.dtd index f3fba468fc0e..8d000f90d561 100644 --- a/mobile/android/base/locales/en-US/torbrowser_strings.dtd +++ b/mobile/android/base/locales/en-US/torbrowser_strings.dtd @@ -54,7 +54,6 @@ <!-- When another PT is recommended, change TorNetworkBridgeSelectPreference::saveCurrentCheckedRadioButton(), too --> <!ENTITY pref_bridges_type_obfs4 "obfs4 (recommended)"> <!ENTITY pref_bridges_type_meek_azure "meek-azure"> -<!ENTITY pref_bridges_type_obfs3 "obfs3"> <!ENTITY pref_tor_network_bridges_enabled_change_builtin "You\'re using a built-in bridge to connect to Tor. Change"> <!ENTITY pref_tor_network_bridges_enabled_change_custom "You\'re using a custom bridge to connect to Tor. Change"> <!ENTITY pref_tor_network_using_multiple_provided_bridges "You\'re using multiple custom bridges."> diff --git a/mobile/android/base/strings.xml.in b/mobile/android/base/strings.xml.in index 8ac8248ea1dc..9b016bd4cccd 100644 --- a/mobile/android/base/strings.xml.in +++ b/mobile/android/base/strings.xml.in @@ -101,7 +101,6 @@ <string name="pref_choice_tor_bridges_enabled_summary">&pref_choice_tor_bridges_enabled_summary;</string> <string name="pref_bridges_type_obfs4">&pref_bridges_type_obfs4;</string> <string name="pref_bridges_type_meek_azure">&pref_bridges_type_meek_azure;</string> - <string name="pref_bridges_type_obfs3">&pref_bridges_type_obfs3;</string> <string name="pref_tor_bridges_provide_manual_button_title">&pref_tor_bridges_provide_manual_button_title;</string> <string name="pref_tor_bridges_provide_select_text_title">&pref_tor_bridges_provide_select_text_title;</string>
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 29859: Disable HLS support for now
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 14b7000757ad06197cb4e088731171f0a6ff325a Author: Georg Koppen <gk(a)torproject.org> Date: Thu Mar 28 19:10:34 2019 +0000 Bug 29859: Disable HLS support for now --- mobile/android/app/000-tor-browser-android.js | 3 +++ mobile/android/base/AppConstants.java.in | 2 +- mobile/android/moz.configure | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/mobile/android/app/000-tor-browser-android.js b/mobile/android/app/000-tor-browser-android.js index 02e3ef00c1b3..2410706bb5f5 100644 --- a/mobile/android/app/000-tor-browser-android.js +++ b/mobile/android/app/000-tor-browser-android.js @@ -57,5 +57,8 @@ pref("general.useragent.updates.url", ""); // Enable touch events on Android (highlighting text, etc) pref("dom.w3c_touch_events.enabled", 2); +// No HLS support for now due to browser freezing, see: #29859. +pref("media.hls.enabled", false); + // Inherit locale from the OS, used for multi-locale builds pref("intl.locale.requested", ""); diff --git a/mobile/android/base/AppConstants.java.in b/mobile/android/base/AppConstants.java.in index 26047188841c..762db8d86a1b 100644 --- a/mobile/android/base/AppConstants.java.in +++ b/mobile/android/base/AppConstants.java.in @@ -382,7 +382,7 @@ public class AppConstants { //#ifdef TOR_BROWSER_VERSION return true; //#else - return false; + return true; //#endif } } diff --git a/mobile/android/moz.configure b/mobile/android/moz.configure index c8ed3a9a59e1..cb536b790d94 100644 --- a/mobile/android/moz.configure +++ b/mobile/android/moz.configure @@ -92,7 +92,7 @@ project_flag('MOZ_SWITCHBOARD', project_flag('MOZ_ANDROID_HLS_SUPPORT', help='Enable HLS (HTTP Live Streaming) support (currently using the ExoPlayer library)', - default=True) + default=False) option(env='MOZ_ANDROID_ACTIVITY_STREAM', help='Enable Activity Stream on Android (replacing the default HomePager)',
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 24920 - Only create Private tabs if browser.privatebrowsing.autostart is true
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 576ff6dcffff7ad57c21c4bc469b52566d8da3dd Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Mon May 27 15:55:33 2019 +0000 Bug 24920 - Only create Private tabs if browser.privatebrowsing.autostart is true --- .../base/java/org/mozilla/gecko/BrowserApp.java | 9 +++++++ .../base/java/org/mozilla/gecko/GeckoApp.java | 31 ++++++++++++++++++++++ .../android/base/java/org/mozilla/gecko/Tabs.java | 7 ++++- .../java/org/mozilla/gecko/tabs/TabsPanel.java | 4 +++ mobile/android/chrome/content/browser.js | 4 +-- 5 files changed, 52 insertions(+), 3 deletions(-) diff --git a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java index da25e3b395be..c2a463ad6ed1 100644 --- a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java @@ -3362,6 +3362,15 @@ public class BrowserApp extends GeckoApp share.setActionProvider(provider); + // Change visibility of new_tab. This may be called before + // mOnlyPrivateTabs is set in GeckoApp::onCreate(). If the PrefHelper + // callback was not already called, then the visibility will be correctly set + // in the callback. + MenuItem newTabMenuItem = mMenu.findItem(R.id.new_tab); + if (newTabMenuItem != null) { + newTabMenuItem.setVisible(mOnlyPrivateTabs == false); + } + return true; } diff --git a/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java b/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java index e01318dab422..9c66f56b0485 100644 --- a/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java @@ -165,6 +165,8 @@ public abstract class GeckoApp extends GeckoActivity */ public static final String PREFS_IS_FIRST_RUN = "telemetry-isFirstRun"; + public static final String PREFS_PRIVATEBROWSING_AUTOSTART = "browser.privatebrowsing.autostart"; + public static final String SAVED_STATE_IN_BACKGROUND = "inBackground"; public static final String SAVED_STATE_PRIVATE_SESSION = "privateSession"; /** @@ -352,6 +354,8 @@ public abstract class GeckoApp extends GeckoActivity private boolean mPrivateBrowsingSessionOutdated; private static final int MAX_PRIVATE_TABS_UPDATE_WAIT_MSEC = 500; + protected boolean mOnlyPrivateTabs = false; + private volatile HealthRecorder mHealthRecorder; private volatile Locale mLastLocale; @@ -1164,6 +1168,28 @@ public abstract class GeckoApp extends GeckoActivity "ToggleChrome:Show", null); + PrefsHelper.getPref(PREFS_PRIVATEBROWSING_AUTOSTART, + new PrefsHelper.PrefHandlerBase() { + @Override public void prefValue(String pref, boolean value) { + if (pref != PREFS_PRIVATEBROWSING_AUTOSTART) { + return; + } + + mOnlyPrivateTabs = value; + + // Change visibility here in case mMenu is initialized. If it is not initialized, + // then the visibility is set in BrowserApp::onCreateOptionsMenu(). + if (mMenu != null) { + MenuItem newTabMenuItem = mMenu.findItem(R.id.new_tab); + if (newTabMenuItem != null) { + newTabMenuItem.setVisible(mOnlyPrivateTabs == false); + } + } + + Tabs.getInstance().setOnlyPrivateTabs(mOnlyPrivateTabs); + } + }); + Tabs.getInstance().attachToContext(this, mLayerView, getAppEventDispatcher()); Tabs.registerOnTabsChangedListener(this); @@ -1202,6 +1228,7 @@ public abstract class GeckoApp extends GeckoActivity } // If we are doing a restore, read the session data so we can send it to Gecko later. + GeckoBundle restoreMessage = null; if (!mIsRestoringActivity && mShouldRestore) { final boolean isExternalURL = invokedWithExternalURL(getIntentURI(new SafeIntent(getIntent()))); @@ -2306,6 +2333,10 @@ public abstract class GeckoApp extends GeckoActivity } } + public boolean isOnlyPrivateTabs() { + return mOnlyPrivateTabs; + } + @TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1) protected void finishAndShutdown(final boolean restart) { ThreadUtils.assertOnUiThread(); diff --git a/mobile/android/base/java/org/mozilla/gecko/Tabs.java b/mobile/android/base/java/org/mozilla/gecko/Tabs.java index 068d8cb7ca28..30c75b68aad8 100644 --- a/mobile/android/base/java/org/mozilla/gecko/Tabs.java +++ b/mobile/android/base/java/org/mozilla/gecko/Tabs.java @@ -106,6 +106,7 @@ public class Tabs implements BundleEventListener { private ContentObserver mBookmarksContentObserver; private PersistTabsRunnable mPersistTabsRunnable; private int mPrivateClearColor; + private boolean mOnlyPrivateTabs = true; // Close all tabs including normal and private tabs. @RobocopTarget @@ -211,6 +212,10 @@ public class Tabs implements BundleEventListener { } } + public synchronized void setOnlyPrivateTabs(boolean onlyPrivateTabs) { + mOnlyPrivateTabs = onlyPrivateTabs; + } + public void detachFromContext() { mGeckoView = null; } @@ -1026,7 +1031,7 @@ public class Tabs implements BundleEventListener { // delayLoad implies background tab boolean background = delayLoad || (flags & LOADURL_BACKGROUND) != 0; - boolean isPrivate = (flags & LOADURL_PRIVATE) != 0 || (intent != null && intent.getBooleanExtra(PRIVATE_TAB_INTENT_EXTRA, false)); + boolean isPrivate = (flags & LOADURL_PRIVATE) != 0 || (intent != null && intent.getBooleanExtra(PRIVATE_TAB_INTENT_EXTRA, false)) || mOnlyPrivateTabs; boolean userEntered = (flags & LOADURL_USER_ENTERED) != 0; boolean desktopMode = (flags & LOADURL_DESKTOP) != 0; boolean external = (flags & LOADURL_EXTERNAL) != 0; diff --git a/mobile/android/base/java/org/mozilla/gecko/tabs/TabsPanel.java b/mobile/android/base/java/org/mozilla/gecko/tabs/TabsPanel.java index 08c107ebb62d..fc27ac03c929 100644 --- a/mobile/android/base/java/org/mozilla/gecko/tabs/TabsPanel.java +++ b/mobile/android/base/java/org/mozilla/gecko/tabs/TabsPanel.java @@ -167,6 +167,10 @@ public class TabsPanel extends LinearLayout final View tabNormal = mTabWidget.addTab(R.drawable.tabs_normal, R.string.tabs_normal); mNormalTabsPanel = tabNormal instanceof ThemedImageButton ? ((ThemedImageButton) tabNormal) : null; + if (mActivity.isOnlyPrivateTabs()) { + tabNormal.setVisibility(View.GONE); + } + final View tabPrivate = mTabWidget.addTab(R.drawable.tabs_private, R.string.tabs_private); mPrivateTabsPanel = tabPrivate instanceof ThemedImageButton ? ((ThemedImageButton) tabPrivate) : null; if (mPrivateTabsPanel != null) { diff --git a/mobile/android/chrome/content/browser.js b/mobile/android/chrome/content/browser.js index e139e59a7f40..f8e9399f51c4 100644 --- a/mobile/android/chrome/content/browser.js +++ b/mobile/android/chrome/content/browser.js @@ -4410,9 +4410,9 @@ Tab.prototype = { // Must be called after appendChild so the docShell has been created. this.setActive(false); - let isPrivate = "isPrivate" in aParams && aParams.isPrivate; + let isPrivate = (("isPrivate" in aParams) && aParams.isPrivate) || Services.prefs.getBoolPref("browser.privatebrowsing.autostart"); if (isPrivate) { - attrs.privateBrowsingId = 1; + attrs['privateBrowsingId'] = 1; } this.browser.docShell.setOriginAttributes(attrs);
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Pick up latest Torbutton fixes
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 28bf38065aacbb6db2b19b024081aad6da7a1c51 Author: Georg Koppen <gk(a)torproject.org> Date: Sat Aug 31 19:45:55 2019 +0000 Pick up latest Torbutton fixes --- toolkit/torproject/torbutton | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/toolkit/torproject/torbutton b/toolkit/torproject/torbutton index 605decfd4ddc..0efb110e9bc6 160000 --- a/toolkit/torproject/torbutton +++ b/toolkit/torproject/torbutton @@ -1 +1 @@ -Subproject commit 605decfd4ddc81eb37da17172f48f92fd7f7e451 +Subproject commit 0efb110e9bc65e3289c58d093c32a25877f61e0b
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 29238 - Prevent crash on Android after update
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 8dbeac4a57547b530762a3a30cb7eea29df463d9 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Fri Mar 22 16:24:09 2019 +0000 Bug 29238 - Prevent crash on Android after update --- mobile/android/base/AndroidManifest.xml.in | 8 -------- 1 file changed, 8 deletions(-) diff --git a/mobile/android/base/AndroidManifest.xml.in b/mobile/android/base/AndroidManifest.xml.in index 228a7b6399b0..5f231e9ba83c 100644 --- a/mobile/android/base/AndroidManifest.xml.in +++ b/mobile/android/base/AndroidManifest.xml.in @@ -492,14 +492,6 @@ android:permission="android.permission.BIND_JOB_SERVICE" > </service> - <receiver - android:name="org.mozilla.gecko.PackageReplacedReceiver" - android:exported="false"> - <intent-filter> - <action android:name="android.intent.action.MY_PACKAGE_REPLACED"></action> - </intent-filter> - </receiver> - <service android:name="org.mozilla.gecko.telemetry.TelemetryUploadService" android:permission="android.permission.BIND_JOB_SERVICE"
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Orfox: Centralized proxy applied to AbstractCommunicator and BaseResources.
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 25134efbece613bf35a6456f1f472bc33e082e60 Author: Amogh Pradeep <amoghbl1(a)gmail.com> Date: Fri Jun 12 02:07:45 2015 -0400 Orfox: Centralized proxy applied to AbstractCommunicator and BaseResources. See Bug 1357997 for partial uplift. Also: Bug 28051 - Use our Orbot for proxying our connections --- .../java/org/mozilla/gecko/util/ProxySelector.java | 25 +++++++++++++++++++++- .../org/mozilla/gecko/sync/net/BaseResource.java | 7 ++++++ .../service/utils/AbstractCommunicator.java | 11 +++++++--- 3 files changed, 39 insertions(+), 4 deletions(-) diff --git a/mobile/android/geckoview/src/main/java/org/mozilla/gecko/util/ProxySelector.java b/mobile/android/geckoview/src/main/java/org/mozilla/gecko/util/ProxySelector.java index 3940d3c84249..9515975f680a 100644 --- a/mobile/android/geckoview/src/main/java/org/mozilla/gecko/util/ProxySelector.java +++ b/mobile/android/geckoview/src/main/java/org/mozilla/gecko/util/ProxySelector.java @@ -29,6 +29,10 @@ import java.net.URLConnection; import java.util.List; public class ProxySelector { + private static final String TOR_PROXY_ADDRESS = "127.0.0.1"; + private static final int TOR_SOCKS_PROXY_PORT = 9150; + private static final int TOR_HTTP_PROXY_PORT = 8218; + public static URLConnection openConnectionWithProxy(final URI uri) throws IOException { java.net.ProxySelector ps = java.net.ProxySelector.getDefault(); Proxy proxy = Proxy.NO_PROXY; @@ -39,7 +43,26 @@ public class ProxySelector { } } - return uri.toURL().openConnection(proxy); + /* Ignore the proxy we found from the VM, only use Tor. We can probably + * safely use the logic in this class in the future. */ + return uri.toURL().openConnection(getProxy()); + } + + public static Proxy getProxy() { + // TODO make configurable + return new Proxy(Proxy.Type.SOCKS, new InetSocketAddress(TOR_PROXY_ADDRESS, TOR_SOCKS_PROXY_PORT)); + } + + public static String getProxyHostAddress() { + return TOR_PROXY_ADDRESS; + } + + public static int getSocksProxyPort() { + return TOR_SOCKS_PROXY_PORT; + } + + public static int getHttpProxyPort() { + return TOR_HTTP_PROXY_PORT; } public ProxySelector() { diff --git a/mobile/android/services/src/main/java/org/mozilla/gecko/sync/net/BaseResource.java b/mobile/android/services/src/main/java/org/mozilla/gecko/sync/net/BaseResource.java index e85ccb855bff..51ebd6ce990f 100644 --- a/mobile/android/services/src/main/java/org/mozilla/gecko/sync/net/BaseResource.java +++ b/mobile/android/services/src/main/java/org/mozilla/gecko/sync/net/BaseResource.java @@ -23,9 +23,11 @@ import org.json.simple.JSONObject; import org.mozilla.gecko.background.common.GlobalConstants; import org.mozilla.gecko.background.common.log.Logger; import org.mozilla.gecko.sync.ExtendedJSONObject; +import org.mozilla.gecko.util.ProxySelector; import ch.boye.httpclientandroidlib.Header; import ch.boye.httpclientandroidlib.HttpEntity; +import ch.boye.httpclientandroidlib.HttpHost; import ch.boye.httpclientandroidlib.HttpResponse; import ch.boye.httpclientandroidlib.HttpVersion; import ch.boye.httpclientandroidlib.client.AuthCache; @@ -40,6 +42,7 @@ import ch.boye.httpclientandroidlib.client.methods.HttpRequestBase; import ch.boye.httpclientandroidlib.client.methods.HttpUriRequest; import ch.boye.httpclientandroidlib.client.protocol.ClientContext; import ch.boye.httpclientandroidlib.conn.ClientConnectionManager; +import ch.boye.httpclientandroidlib.conn.params.ConnRoutePNames; import ch.boye.httpclientandroidlib.conn.scheme.PlainSocketFactory; import ch.boye.httpclientandroidlib.conn.scheme.Scheme; import ch.boye.httpclientandroidlib.conn.scheme.SchemeRegistry; @@ -215,6 +218,10 @@ public class BaseResource implements Resource { // We could reuse these client instances, except that we mess around // with their parameters… so we'd need a pool of some kind. client = new DefaultHttpClient(getConnectionManager()); + /* TBA: We need a HTTP Proxy here */ + HttpHost defaultProxy = new HttpHost(ProxySelector.getProxyHostAddress(), + ProxySelector.getHttpProxyPort()); + client.getParams().setParameter(ConnRoutePNames.DEFAULT_PROXY, defaultProxy); // TODO: Eventually we should use Apache HttpAsyncClient. It's not out of alpha yet. // Until then, we synchronously make the request, then invoke our delegate's callback. diff --git a/mobile/android/stumbler/java/org/mozilla/mozstumbler/service/utils/AbstractCommunicator.java b/mobile/android/stumbler/java/org/mozilla/mozstumbler/service/utils/AbstractCommunicator.java index 4e30cb7deeb7..9b3ee98f89db 100644 --- a/mobile/android/stumbler/java/org/mozilla/mozstumbler/service/utils/AbstractCommunicator.java +++ b/mobile/android/stumbler/java/org/mozilla/mozstumbler/service/utils/AbstractCommunicator.java @@ -7,6 +7,7 @@ package org.mozilla.mozstumbler.service.utils; import android.os.Build; import android.util.Log; +import org.mozilla.gecko.util.ProxySelector; import org.mozilla.mozstumbler.service.AppGlobals; import org.mozilla.mozstumbler.service.Prefs; @@ -16,7 +17,7 @@ import java.io.InputStream; import java.io.OutputStream; import java.net.HttpURLConnection; import java.net.MalformedURLException; -import java.net.URL; +import java.net.URI; public abstract class AbstractCommunicator { @@ -72,8 +73,12 @@ public abstract class AbstractCommunicator { if (sMozApiKey == null || prefs != null) { sMozApiKey = prefs.getMozApiKey(); } - URL url = new URL(getUrlString() + "?key=" + sMozApiKey); - mHttpURLConnection = (HttpURLConnection) url.openConnection(); + + /* TBA: This was a URL, but the connection logic would simply + * convert the URL into a URI, and then later convert the URI back + * into a URL. Creating a URL at the beginning is only wasteful. */ + URI uri = new URI(getUrlString() + "?key=" + sMozApiKey); + mHttpURLConnection = (HttpURLConnection) ProxySelector.openConnectionWithProxy(uri); mHttpURLConnection.setRequestMethod("POST"); } catch (MalformedURLException e) { throw new IllegalArgumentException(e);
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Disable GeckoNetworkManager
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 075ad0a98f40d38d34cb4b8ddc49a72892662f1e Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Thu Apr 26 22:22:51 2018 +0000 Bug 25741 - TBA: Disable GeckoNetworkManager The browser should not need information related to the network interface or network state, tor should take care of that. --- .../src/main/java/org/mozilla/geckoview/GeckoRuntime.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java index 6023e2512398..804b8f0000e9 100644 --- a/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java +++ b/mobile/android/geckoview/src/main/java/org/mozilla/geckoview/GeckoRuntime.java @@ -118,14 +118,18 @@ public final class GeckoRuntime implements Parcelable { Log.d(LOGTAG, "Lifecycle: onResume"); // Monitor network status and send change notifications to Gecko // while active. - GeckoNetworkManager.getInstance().start(GeckoAppShell.getApplicationContext()); + if (BuildConfig.TOR_BROWSER_VERSION != "") { + GeckoNetworkManager.getInstance().start(GeckoAppShell.getApplicationContext()); + } } @OnLifecycleEvent(Lifecycle.Event.ON_PAUSE) void onPause() { Log.d(LOGTAG, "Lifecycle: onPause"); // Stop monitoring network status while inactive. - GeckoNetworkManager.getInstance().stop(); + if (BuildConfig.TOR_BROWSER_VERSION != "") { + GeckoNetworkManager.getInstance().stop(); + } } }
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Disable all data reporting by default
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 2d3e4864df1cec08bf6f085e21cdbdcf08f57c8c Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Wed Apr 11 20:37:43 2018 +0000 Bug 25741 - TBA: Disable all data reporting by default This includes: Telemetry Geo-Location (Wi-Fi, Cellular location data, etc) Health Report --- mobile/android/app/src/main/res/xml/preferences_privacy.xml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/mobile/android/app/src/main/res/xml/preferences_privacy.xml b/mobile/android/app/src/main/res/xml/preferences_privacy.xml index 68a2066976c8..23be2f12121b 100644 --- a/mobile/android/app/src/main/res/xml/preferences_privacy.xml +++ b/mobile/android/app/src/main/res/xml/preferences_privacy.xml @@ -84,7 +84,8 @@ <CheckBoxPreference android:key="android.not_a_preference.app.geo.reportdata" android:title="@string/datareporting_wifi_title" - android:summary="@string/datareporting_wifi_geolocation_summary" /> + android:summary="@string/datareporting_wifi_geolocation_summary" + android:defaultValue="false" /> <org.mozilla.gecko.preferences.AlignRightLinkPreference android:key="android.not_a_preference.geo.learn_more" android:title="@string/pref_learn_more" @@ -94,7 +95,7 @@ <CheckBoxPreference android:key="android.not_a_preference.healthreport.uploadEnabled" android:title="@string/datareporting_fhr_title" android:summary="@string/datareporting_fhr_summary2" - android:defaultValue="true" /> + android:defaultValue="false" /> </PreferenceCategory>
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Adjust the User Agent String so it doesn't leak Android version
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 268ff9c9220b648975f533afa8b488cca2c36dea Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Thu Apr 26 15:17:42 2018 +0000 Bug 25741 - TBA: Adjust the User Agent String so it doesn't leak Android version --- mobile/android/base/AppConstants.java.in | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/mobile/android/base/AppConstants.java.in b/mobile/android/base/AppConstants.java.in index bfc594e7e801..26047188841c 100644 --- a/mobile/android/base/AppConstants.java.in +++ b/mobile/android/base/AppConstants.java.in @@ -145,20 +145,33 @@ public class AppConstants { public static final String OS_TARGET = "@OS_TARGET@"; public static final String TARGET_XPCOM_ABI = "@TARGET_XPCOM_ABI@"; - public static final String USER_AGENT_BOT_LIKE = "Redirector/" + AppConstants.MOZ_APP_VERSION + - " (Android; rv:" + AppConstants.MOZ_APP_VERSION + ")"; - - public static final String USER_AGENT_FENNEC_MOBILE = "Mozilla/5.0 (Android " + + // TBA: Commented out, not used. + //public static final String USER_AGENT_BOT_LIKE = "Redirector/" + AppConstants.MOZ_APP_VERSION + + // " (Android; rv:" + AppConstants.MOZ_APP_VERSION + ")"; + + // TBA: Fennec's UAS now contains the Android version. Hard-code all users UAS + // so it matches the RFP string from necko. + // toolkit/components/resistfingerprinting/nsRFPService.h + public static final String USER_AGENT_FENNEC_MOBILE = +//#ifdef TOR_BROWSER_VERSION + "Mozilla/5.0 (Android 6.0; Mobile; rv:68.0) Gecko/20100101 Firefox/68.0"; +//#else + "Mozilla/5.0 (Android " + Build.VERSION.RELEASE + "; Mobile; rv:" + AppConstants.MOZ_APP_VERSION + ") Gecko/" + AppConstants.MOZ_APP_VERSION + " Firefox/" + AppConstants.MOZ_APP_VERSION; +//#endif +//#ifdef TOR_BROWSER_VERSION + public static final String USER_AGENT_FENNEC_TABLET = USER_AGENT_FENNEC_MOBILE; +//#else public static final String USER_AGENT_FENNEC_TABLET = "Mozilla/5.0 (Android " + Build.VERSION.RELEASE + "; Tablet; rv:" + AppConstants.MOZ_APP_VERSION + ") Gecko/" + AppConstants.MOZ_APP_VERSION + " Firefox/" + AppConstants.MOZ_APP_VERSION; +//#endif public static final boolean MOZ_ANDROID_ANR_REPORTER = //#ifdef MOZ_ANDROID_ANR_REPORTER
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Disable the microphone by default
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 6cb0b508fb19dda23310263620c9d8d07c14c7d2 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Mon Apr 9 22:20:16 2018 +0000 Bug 25741 - TBA: Disable the microphone by default Deactivating this is an accessibility concern because this is used for voice dictation, so users should have the option of re-enabling this. This uses the Android Speech API. --- mobile/android/app/src/main/res/xml/preferences_accessibility.xml | 2 +- .../android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mobile/android/app/src/main/res/xml/preferences_accessibility.xml b/mobile/android/app/src/main/res/xml/preferences_accessibility.xml index c4fe86ed62c3..c82006ee2473 100644 --- a/mobile/android/app/src/main/res/xml/preferences_accessibility.xml +++ b/mobile/android/app/src/main/res/xml/preferences_accessibility.xml @@ -18,7 +18,7 @@ <SwitchPreference android:key="android.not_a_preference.voice_input_enabled" android:title="@string/pref_voice_input" android:summary="@string/pref_voice_input_summary" - android:defaultValue="true"/> + android:defaultValue="false"/> <SwitchPreference android:key="android.not_a_preference.qrcode_enabled" android:title="@string/pref_qrcode_enabled" diff --git a/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java b/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java index 7c9a99fc5432..1d53de172c47 100644 --- a/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java +++ b/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java @@ -287,7 +287,7 @@ public class ToolbarEditLayout extends ThemedLinearLayout { return false; } return GeckoSharedPrefs.forApp(context) - .getBoolean(GeckoPreferences.PREFS_VOICE_INPUT_ENABLED, true); + .getBoolean(GeckoPreferences.PREFS_VOICE_INPUT_ENABLED, false); } void launchVoiceRecognizer() {
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Do not save browsing history by default
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 02f75df3521e77f1515bb195a611e59e35578302 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Wed Apr 11 18:46:02 2018 +0000 Bug 25741 - TBA: Do not save browsing history by default --- mobile/android/app/src/main/res/xml-v11/preferences_search.xml | 2 +- mobile/android/app/src/main/res/xml/preferences_search.xml | 2 +- mobile/android/base/java/org/mozilla/gecko/home/BrowserSearch.java | 2 +- mobile/android/base/java/org/mozilla/gecko/home/SearchEngineRow.java | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/mobile/android/app/src/main/res/xml-v11/preferences_search.xml b/mobile/android/app/src/main/res/xml-v11/preferences_search.xml index 937b05b617c6..a58bb7cece44 100644 --- a/mobile/android/app/src/main/res/xml-v11/preferences_search.xml +++ b/mobile/android/app/src/main/res/xml-v11/preferences_search.xml @@ -27,7 +27,7 @@ <CheckBoxPreference android:key="android.not_a_preference.search.search_history.enabled" android:title="@string/pref_history_search_suggestions" - android:defaultValue="true" + android:defaultValue="false" android:persistent="true" /> </PreferenceScreen> diff --git a/mobile/android/app/src/main/res/xml/preferences_search.xml b/mobile/android/app/src/main/res/xml/preferences_search.xml index 440167fe5e2a..fc8c258821e1 100644 --- a/mobile/android/app/src/main/res/xml/preferences_search.xml +++ b/mobile/android/app/src/main/res/xml/preferences_search.xml @@ -34,7 +34,7 @@ <CheckBoxPreference android:key="android.not_a_preference.search.search_history.enabled" android:title="@string/pref_history_search_suggestions" - android:defaultValue="true" + android:defaultValue="false" android:persistent="true" /> </PreferenceScreen> diff --git a/mobile/android/base/java/org/mozilla/gecko/home/BrowserSearch.java b/mobile/android/base/java/org/mozilla/gecko/home/BrowserSearch.java index 386f0494b75c..9e415cb454d7 100644 --- a/mobile/android/base/java/org/mozilla/gecko/home/BrowserSearch.java +++ b/mobile/android/base/java/org/mozilla/gecko/home/BrowserSearch.java @@ -278,7 +278,7 @@ public class BrowserSearch extends HomeFragment super.onResume(); final SharedPreferences prefs = GeckoSharedPrefs.forApp(getContext()); - mSavedSearchesEnabled = prefs.getBoolean(GeckoPreferences.PREFS_HISTORY_SAVED_SEARCH, true); + mSavedSearchesEnabled = prefs.getBoolean(GeckoPreferences.PREFS_HISTORY_SAVED_SEARCH, false); // Fetch engines if we need to. if (mSearchEngines.isEmpty() || !Locale.getDefault().equals(mLastLocale)) { diff --git a/mobile/android/base/java/org/mozilla/gecko/home/SearchEngineRow.java b/mobile/android/base/java/org/mozilla/gecko/home/SearchEngineRow.java index 8d7eec1d839a..1d90f7bacf41 100644 --- a/mobile/android/base/java/org/mozilla/gecko/home/SearchEngineRow.java +++ b/mobile/android/base/java/org/mozilla/gecko/home/SearchEngineRow.java @@ -378,7 +378,7 @@ class SearchEngineRow extends ThemedRelativeLayout { final int recycledSuggestionCount = mSuggestionView.getChildCount(); final SharedPreferences prefs = GeckoSharedPrefs.forApp(getContext()); - final boolean savedSearchesEnabled = prefs.getBoolean(GeckoPreferences.PREFS_HISTORY_SAVED_SEARCH, true); + final boolean savedSearchesEnabled = prefs.getBoolean(GeckoPreferences.PREFS_HISTORY_SAVED_SEARCH, false); // Remove duplicates of search engine suggestions from saved searches. List<String> searchHistorySuggestions = (rawSearchHistorySuggestions != null) ? rawSearchHistorySuggestions : new ArrayList<String>();
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Conditionally require WIFI and NETWORK permissions
by gk@torproject.org 31 Aug '19

31 Aug '19
commit c60818fd0b1922514fab5d4d6dbef05d0ae70217 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Wed Apr 11 17:52:59 2018 +0000 Bug 25741 - TBA: Conditionally require WIFI and NETWORK permissions Only require the {ACCESS,CHANGE}_WIFI_STATE and ACCESS_NETWORK_STATE permissions if MOZ_ANDROID_NETWORK_STATE is defined in the preprocessor. Also: Bug 25741 - TBA: Conditionally require *_LOCATION permissions Only require the {FINE,COURSE}_LOCATION permissions if MOZ_ANDROID_LOCATION is defined in the preprocessor. Also include location features (with gps). Bug 25741 - TBA: Move CAMERA permission within MOZ_WEBRTC Require the CAMERA permissions if MOZ_WEBRTC is defined in the preprocessor. Bug 25741 - TBA: Only include GCM permissions if we want them Bug 26826 - Disable tab queue and delete SYSTEM_ALERT_WINDOW permission Bug 24796 - Comment out excess permissions from GeckoView The GeckoView AndroidManifest.xml is not preprocessed unlike Fennec's manifest, so we can't use the ifdef preprocessor guards around the permissions we do not want. Commenting the permissions is the next-best-thing. --- .../app/src/main/res/xml/preferences_general.xml | 1 + .../src/main/res/xml/preferences_general_tablet.xml | 1 + .../android/base/FennecManifest_permissions.xml.in | 18 ++++++++++++++---- .../android/geckoview/src/main/AndroidManifest.xml | 20 +++++++++++++++++--- mobile/android/moz.configure | 8 ++++++++ .../FxAccountAndroidManifest_permissions.xml.in | 2 ++ mobile/android/torbrowser.configure | 3 +++ 7 files changed, 46 insertions(+), 7 deletions(-) diff --git a/mobile/android/app/src/main/res/xml/preferences_general.xml b/mobile/android/app/src/main/res/xml/preferences_general.xml index f148ae61b169..ef739db0c3d8 100644 --- a/mobile/android/app/src/main/res/xml/preferences_general.xml +++ b/mobile/android/app/src/main/res/xml/preferences_general.xml @@ -31,6 +31,7 @@ <SwitchPreference android:key="android.not_a_preference.tab_queue" android:title="@string/pref_tab_queue_title" android:summary="@string/pref_tab_queue_summary" + android:selectable="false" android:defaultValue="false" /> <SwitchPreference android:key="android.not_a_preference.compact_tabs" diff --git a/mobile/android/app/src/main/res/xml/preferences_general_tablet.xml b/mobile/android/app/src/main/res/xml/preferences_general_tablet.xml index 903e9e315f59..aee9937f9759 100644 --- a/mobile/android/app/src/main/res/xml/preferences_general_tablet.xml +++ b/mobile/android/app/src/main/res/xml/preferences_general_tablet.xml @@ -43,6 +43,7 @@ <SwitchPreference android:key="android.not_a_preference.tab_queue" android:title="@string/pref_tab_queue_title" android:summary="@string/pref_tab_queue_summary" + android:selectable="false" android:defaultValue="false" /> </PreferenceScreen> diff --git a/mobile/android/base/FennecManifest_permissions.xml.in b/mobile/android/base/FennecManifest_permissions.xml.in index f3e43bb4e3ca..796e28777aad 100644 --- a/mobile/android/base/FennecManifest_permissions.xml.in +++ b/mobile/android/base/FennecManifest_permissions.xml.in @@ -8,14 +8,23 @@ them during the same release, which should be Fennec 48. Therefore we decouple the push permission from MOZ_ANDROID_GCM to let it ride ahead (potentially) of the push feature. --> + +#ifdef MOZ_ANDROID_GCM #include GcmAndroidManifest_permissions.xml.in +#endif #include SamsungAppStoreManifest_permissions.xml.in +#ifdef MOZ_ANDROID_NETWORK_STATE + <!-- Android WIFI state --> <uses-permission android:name="android.permission.CHANGE_WIFI_STATE"/> <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/> +#endif + +#ifdef MOZ_ANDROID_LOCATION <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/> <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/> +#endif <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> <uses-permission android:name="android.permission.INTERNET"/> #ifdef MOZ_ANDROID_MLS_STUMBLER @@ -25,7 +34,9 @@ <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> <uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT"/> <uses-permission android:name="com.android.launcher.permission.UNINSTALL_SHORTCUT"/> +#ifdef MOZ_ANDROID_LOCATION <uses-permission android:name="com.android.browser.permission.READ_HISTORY_BOOKMARKS"/> +#endif <uses-permission android:name="android.permission.FOREGROUND_SERVICE"/> <uses-permission android:name="android.permission.WAKE_LOCK"/> @@ -34,13 +45,12 @@ <uses-permission android:name="android.permission.DOWNLOAD_WITHOUT_NOTIFICATION" /> #endif +#ifdef MOZ_ANDROID_LOCATION <uses-feature android:name="android.hardware.location" android:required="false"/> <uses-feature android:name="android.hardware.location.gps" android:required="false"/> +#endif <uses-feature android:name="android.hardware.touchscreen"/> - <!-- Tab Queue --> - <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW"/> - <!-- To be able to install updates and other downloaded APKs on API 26+ --> <uses-permission-sdk-23 android:name="android.permission.REQUEST_INSTALL_PACKAGES"/> @@ -55,10 +65,10 @@ <uses-feature android:name="android.hardware.audio.low_latency" android:required="false"/> <uses-feature android:name="android.hardware.camera.any" android:required="false"/> <uses-feature android:name="android.hardware.microphone" android:required="false"/> -#endif <uses-permission android:name="android.permission.CAMERA" /> <uses-feature android:name="android.hardware.camera" android:required="false"/> <uses-feature android:name="android.hardware.camera.autofocus" android:required="false"/> +#endif <!-- App requires OpenGL ES 2.0 --> <uses-feature android:glEsVersion="0x00020000" android:required="true" /> diff --git a/mobile/android/geckoview/src/main/AndroidManifest.xml b/mobile/android/geckoview/src/main/AndroidManifest.xml index a14bb6b1750e..0d93ee53ee4b 100644 --- a/mobile/android/geckoview/src/main/AndroidManifest.xml +++ b/mobile/android/geckoview/src/main/AndroidManifest.xml @@ -2,20 +2,32 @@ <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="org.mozilla.geckoview"> +<!--#ifdef MOZ_ANDROID_NETWORK_STATE--> + <!-- <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> + --> +<!--#endif--> <uses-permission android:name="android.permission.INTERNET"/> <uses-permission android:name="android.permission.WAKE_LOCK"/> <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" /> +<!--#ifdef MOZ_ANDROID_LOCATION--> + <!-- <uses-feature android:name="android.hardware.location" android:required="false"/> <uses-feature android:name="android.hardware.location.gps" android:required="false"/> + --> +<!--#endif--> <uses-feature android:name="android.hardware.touchscreen" android:required="false"/> +<!--#ifdef MOZ_WEBRTC--> + <!-- TODO preprocess AndroidManifest.xml so that we can + conditionally include WebRTC permissions based on MOZ_WEBRTC. --> + <!-- <uses-feature android:name="android.hardware.camera" android:required="false"/> @@ -24,14 +36,16 @@ android:required="false"/> <uses-feature - android:name="android.hardware.audio.low_latency" + android:name="android.hardware.camera.any" android:required="false"/> <uses-feature - android:name="android.hardware.microphone" + android:name="android.hardware.audio.low_latency" android:required="false"/> <uses-feature - android:name="android.hardware.camera.any" + android:name="android.hardware.microphone" android:required="false"/> + --> +<!--#endif--> <!-- GeckoView requires OpenGL ES 2.0 --> <uses-feature diff --git a/mobile/android/moz.configure b/mobile/android/moz.configure index def87ba268f1..c8ed3a9a59e1 100644 --- a/mobile/android/moz.configure +++ b/mobile/android/moz.configure @@ -193,3 +193,11 @@ def check_android_gcm(android_gcm, if not google_play_services: die('You must specify --with-google-play-services when' ' building with MOZ_ANDROID_GCM=1') + +project_flag('MOZ_ANDROID_NETWORK_STATE', + help='Include permission for accessing WiFi/network state on Android', + default=False) + +project_flag('MOZ_ANDROID_LOCATION', + help='Include permission for accessing fine and course-grain Location on Android', + default=False) diff --git a/mobile/android/services/manifests/FxAccountAndroidManifest_permissions.xml.in b/mobile/android/services/manifests/FxAccountAndroidManifest_permissions.xml.in index d5c7e3e5c7dc..8498b8015855 100644 --- a/mobile/android/services/manifests/FxAccountAndroidManifest_permissions.xml.in +++ b/mobile/android/services/manifests/FxAccountAndroidManifest_permissions.xml.in @@ -1,5 +1,7 @@ <uses-permission android:name="android.permission.GET_ACCOUNTS" /> +#ifdef MOZ_ANDROID_NETWORK_STATE <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> +#endif <uses-permission android:name="android.permission.MANAGE_ACCOUNTS" /> <uses-permission android:name="android.permission.USE_CREDENTIALS" /> <uses-permission android:name="android.permission.AUTHENTICATE_ACCOUNTS" /> diff --git a/mobile/android/torbrowser.configure b/mobile/android/torbrowser.configure index 5e3ab67dca6a..ac30fde888a6 100644 --- a/mobile/android/torbrowser.configure +++ b/mobile/android/torbrowser.configure @@ -41,3 +41,6 @@ imply_option('MOZ_SERVICES_HEALTHREPORT', False) # them here, as well. #imply_option('MOZ_TELEMETRY_REPORTING', False) #imply_option('MOZ_DATA_REPORTING', False) + +imply_option('MOZ_ANDROID_NETWORK_STATE', False); +imply_option('MOZ_ANDROID_LOCATION', False);
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Disable QR Code reader by default
by gk@torproject.org 31 Aug '19

31 Aug '19
commit ea9068b111c5454b91b2017383c39cc4ac7bf1f2 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Mon Apr 9 22:36:53 2018 +0000 Bug 25741 - TBA: Disable QR Code reader by default This is another accessibility and usability concern, so we allow this as an opt-in. --- mobile/android/app/src/main/res/xml/preferences_accessibility.xml | 2 +- .../android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mobile/android/app/src/main/res/xml/preferences_accessibility.xml b/mobile/android/app/src/main/res/xml/preferences_accessibility.xml index c82006ee2473..c5afa4d8d644 100644 --- a/mobile/android/app/src/main/res/xml/preferences_accessibility.xml +++ b/mobile/android/app/src/main/res/xml/preferences_accessibility.xml @@ -23,6 +23,6 @@ <SwitchPreference android:key="android.not_a_preference.qrcode_enabled" android:title="@string/pref_qrcode_enabled" android:summary="@string/pref_qrcode_enabled_summary" - android:defaultValue="true"/> + android:defaultValue="false"/> </PreferenceScreen> diff --git a/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java b/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java index 1d53de172c47..a28847285350 100644 --- a/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java +++ b/mobile/android/base/java/org/mozilla/gecko/toolbar/ToolbarEditLayout.java @@ -324,7 +324,7 @@ public class ToolbarEditLayout extends ThemedLinearLayout { return false; } return GeckoSharedPrefs.forApp(context) - .getBoolean(GeckoPreferences.PREFS_QRCODE_ENABLED, true); + .getBoolean(GeckoPreferences.PREFS_QRCODE_ENABLED, false); } private void launchQRCodeReader() {
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Disable telemetry and experiments
by gk@torproject.org 31 Aug '19

31 Aug '19
commit bb1e2de8f19b000acd81f15ea2e0d19ba276b11d Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Mon Apr 9 21:57:22 2018 +0000 Bug 25741 - TBA: Disable telemetry and experiments --- mobile/android/base/java/org/mozilla/gecko/BrowserApp.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java index 80981eb87136..e7d490a552fe 100644 --- a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java @@ -64,6 +64,7 @@ import android.widget.Button; import android.widget.ListView; import android.widget.ViewFlipper; +import org.mozilla.gecko.AppConstants; import org.mozilla.gecko.AppConstants.Versions; import org.mozilla.gecko.DynamicToolbar.VisibilityTransition; import org.mozilla.gecko.Tabs.TabEvents; @@ -631,7 +632,11 @@ public class BrowserApp extends GeckoApp showSplashScreen = true; safeStartingIntent = new SafeIntent(getIntent()); - isInAutomation = IntentUtils.getIsInAutomationFromEnvironment(safeStartingIntent); + // TBA: Disable Switchboard testing experiments and + // Telemetry-uploading by abusing the isInAutomation detection. + isInAutomation = + (IntentUtils.getIsInAutomationFromEnvironment(safeStartingIntent) + || AppConstants.isTorBrowser()); GeckoProfile.setIntentArgs(safeStartingIntent.getStringExtra("args"));
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Do not register Stumbler listener at start up
by gk@torproject.org 31 Aug '19

31 Aug '19
commit cee7a826fa47d7155ac902f093b6f7c07a4c0e55 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Wed Apr 25 01:55:44 2018 +0000 Bug 25741 - TBA: Do not register Stumbler listener at start up --- mobile/android/base/java/org/mozilla/gecko/GeckoApp.java | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java b/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java index 4f09e065c0c3..246ce55d0d23 100644 --- a/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/GeckoApp.java @@ -96,7 +96,8 @@ import org.json.JSONArray; import org.json.JSONException; import org.json.JSONObject; import org.mozilla.geckoview.GeckoViewBridge; -import org.mozilla.mozstumbler.service.mainthread.SafeReceiver; +// SafeReceiver excluded at compile-time +//import org.mozilla.mozstumbler.service.mainthread.SafeReceiver; import java.io.File; import java.util.ArrayList; @@ -1008,9 +1009,13 @@ public abstract class GeckoApp extends GeckoActivity // Tell Stumbler to register a local broadcast listener to listen for preference intents. // We do this via intents since we can't easily access Stumbler directly, // as it might be compiled outside of Fennec. - final Intent stumblerIntent = new Intent(getApplicationContext(), SafeReceiver.class); - stumblerIntent.setAction(INTENT_REGISTER_STUMBLER_LISTENER); - getApplicationContext().sendBroadcast(stumblerIntent); + // Tor Browser: We don't want Fennec using or receiving Stumbler + // SafeReceiver excluded at compile-time + //if (!AppConstants.isTorBrowser()) { + // final Intent stumblerIntent = new Intent(getApplicationContext(), SafeReceiver.class); + // stumblerIntent.setAction(INTENT_REGISTER_STUMBLER_LISTENER); + // getApplicationContext().sendBroadcast(stumblerIntent); + //} // Did the OS locale change while we were backgrounded? If so, // we need to die so that Gecko will re-init add-ons that touch @@ -1071,6 +1076,7 @@ public abstract class GeckoApp extends GeckoActivity final String uri = getURIFromIntent(intent); if (!TextUtils.isEmpty(uri)) { // Start a speculative connection as soon as Gecko loads. + // XXX TBA: Check this doesn't leak, and is blocked by Tor bootstrap GeckoThread.speculativeConnect(uri); } }
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Remove sync option from preferences
by gk@torproject.org 31 Aug '19

31 Aug '19
commit da563f691147389df259b61f4f47c490257e8bf2 Author: Amogh Pradeep <amoghbl1(a)gmail.com> Date: Fri Jul 17 13:27:07 2015 -0400 Bug 25741 - TBA: Remove sync option from preferences We don't want this while the Sync subsystem is a proxy-bypass risk. We can drop this when the feature is patched (Bug 1314778). Signed-off-by: Amogh Pradeep <amoghbl1(a)gmail.com> Also: Bug 28507 - Don't call Push and Sync services during Sanitize Bug 30086 - Prevent Sync-related crashes on Android Bug 25741 - TBA: Only include Firefox Account permissions if we want them (using MOZ_ACCOUNT) Bug 25741 - TBA: Neuter Firefox Accounts --- .../android/app/src/main/res/xml/preferences.xml | 6 -- mobile/android/base/AndroidManifest.xml.in | 4 ++ .../android/base/FennecManifest_permissions.xml.in | 2 + .../base/java/org/mozilla/gecko/BrowserApp.java | 8 --- .../mozilla/gecko/home/CombinedHistoryPanel.java | 14 +++-- .../overlays/service/sharemethods/SendTab.java | 6 +- .../base/locales/en-US/torbrowser_strings.dtd | 2 + mobile/android/base/strings.xml.in | 2 + mobile/android/modules/Sanitizer.jsm | 47 ++++++++------ .../org/mozilla/gecko/fxa/FirefoxAccounts.java | 73 +++++++++++++--------- .../gecko/fxa/authenticator/AndroidFxAccount.java | 13 +++- 11 files changed, 107 insertions(+), 70 deletions(-) diff --git a/mobile/android/app/src/main/res/xml/preferences.xml b/mobile/android/app/src/main/res/xml/preferences.xml index a9cec32ca3ef..f9c5c9e1ac53 100644 --- a/mobile/android/app/src/main/res/xml/preferences.xml +++ b/mobile/android/app/src/main/res/xml/preferences.xml @@ -9,12 +9,6 @@ xmlns:gecko="http://schemas.android.com/apk/res-auto" android:enabled="false"> - <org.mozilla.gecko.preferences.SyncPreference android:key="android.not_a_preference.sync" - android:title="@string/pref_sync" - android:icon="@drawable/sync_avatar_default" - android:summary="@string/pref_sync_summary" - android:persistent="false" /> - <org.mozilla.gecko.preferences.DefaultBrowserPreference android:key="android.not_a_preference.default_browser.link" android:persistent="false" diff --git a/mobile/android/base/AndroidManifest.xml.in b/mobile/android/base/AndroidManifest.xml.in index 17a34703e6e7..e61a3411b2e0 100644 --- a/mobile/android/base/AndroidManifest.xml.in +++ b/mobile/android/base/AndroidManifest.xml.in @@ -291,7 +291,9 @@ </intent-filter> </receiver> +#ifdef MOZ_ACCOUNT #include ../services/manifests/FxAccountAndroidManifest_activities.xml.in +#endif #ifdef MOZ_CRASHREPORTER <activity android:name="org.mozilla.gecko.CrashReporterActivity" @@ -504,7 +506,9 @@ </intent-filter> </service> +#ifdef MOZ_ACCOUNT #include ../services/manifests/FxAccountAndroidManifest_services.xml.in +#endif <service android:name="org.mozilla.gecko.tabqueue.TabReceivedService" diff --git a/mobile/android/base/FennecManifest_permissions.xml.in b/mobile/android/base/FennecManifest_permissions.xml.in index ffa6d27a8b0d..f3e43bb4e3ca 100644 --- a/mobile/android/base/FennecManifest_permissions.xml.in +++ b/mobile/android/base/FennecManifest_permissions.xml.in @@ -1,5 +1,7 @@ +#ifdef MOZ_ACCOUNT #include ../services/manifests/FxAccountAndroidManifest_permissions.xml.in +#endif <!-- Bug 1261302: we have two new permissions to request, RECEIVE_BOOT_COMPLETED and the permission for push. We want to ask for diff --git a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java index 7d4c03f7e5d2..80981eb87136 100644 --- a/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java +++ b/mobile/android/base/java/org/mozilla/gecko/BrowserApp.java @@ -303,8 +303,6 @@ public class BrowserApp extends GeckoApp private ReadingListHelper mReadingListHelper; - private AccountsHelper mAccountsHelper; - private ExtensionPermissionsHelper mExtensionPermissionsHelper; // The tab to be selected on editing mode exit. @@ -839,7 +837,6 @@ public class BrowserApp extends GeckoApp mSharedPreferencesHelper = new SharedPreferencesHelper(appContext); mReadingListHelper = new ReadingListHelper(appContext, profile); - mAccountsHelper = new AccountsHelper(appContext, profile); mExtensionPermissionsHelper = new ExtensionPermissionsHelper(this); if (AppConstants.MOZ_ANDROID_BEAM) { @@ -1575,11 +1572,6 @@ public class BrowserApp extends GeckoApp mReadingListHelper = null; } - if (mAccountsHelper != null) { - mAccountsHelper.uninit(); - mAccountsHelper = null; - } - if (mExtensionPermissionsHelper != null) { mExtensionPermissionsHelper.uninit(); mExtensionPermissionsHelper = null; diff --git a/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryPanel.java b/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryPanel.java index 4080317cd65a..39905dd950de 100644 --- a/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryPanel.java +++ b/mobile/android/base/java/org/mozilla/gecko/home/CombinedHistoryPanel.java @@ -244,10 +244,16 @@ public class CombinedHistoryPanel extends HomeFragment implements RemoteClientsD syncSetupButton.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View view) { - Telemetry.sendUIEvent(TelemetryContract.Event.ACTION, TelemetryContract.Method.BUTTON, "history_syncsetup"); - // This Activity will redirect to the correct Activity as needed. - final Intent intent = new Intent(FxAccountConstants.ACTION_FXA_GET_STARTED); - startActivity(intent); + // Tell the user this action is not supported + final AlertDialog.Builder dialogBuilder = new AlertDialog.Builder(getActivity()); + dialogBuilder.setMessage(R.string.sync_not_supported); + dialogBuilder.setNegativeButton(R.string.button_cancel, new AlertDialog.OnClickListener() { + @Override + public void onClick(final DialogInterface dialog, final int which) { + dialog.dismiss(); + } + }); + dialogBuilder.show(); } }); diff --git a/mobile/android/base/java/org/mozilla/gecko/overlays/service/sharemethods/SendTab.java b/mobile/android/base/java/org/mozilla/gecko/overlays/service/sharemethods/SendTab.java index 9382c2ec15f9..5babb74c4f88 100644 --- a/mobile/android/base/java/org/mozilla/gecko/overlays/service/sharemethods/SendTab.java +++ b/mobile/android/base/java/org/mozilla/gecko/overlays/service/sharemethods/SendTab.java @@ -165,7 +165,8 @@ public class SendTab extends ShareMethod { } // Have registered UIs offer to set up a Firefox Account. - setOverrideIntentAction(FxAccountConstants.ACTION_FXA_GET_STARTED); + // Comment for Tor Browser + //setOverrideIntentAction(FxAccountConstants.ACTION_FXA_GET_STARTED); } /** @@ -187,7 +188,8 @@ public class SendTab extends ShareMethod { if (validGUIDs.isEmpty()) { // Guess we'd better override. We have no clients. // This does the broadcast for us. - setOverrideIntentAction(FxAccountConstants.ACTION_FXA_GET_STARTED); + // Comment for Tor Browser + //setOverrideIntentAction(FxAccountConstants.ACTION_FXA_GET_STARTED); return; } diff --git a/mobile/android/base/locales/en-US/torbrowser_strings.dtd b/mobile/android/base/locales/en-US/torbrowser_strings.dtd index d23acc8a033a..b43134a0260b 100644 --- a/mobile/android/base/locales/en-US/torbrowser_strings.dtd +++ b/mobile/android/base/locales/en-US/torbrowser_strings.dtd @@ -3,3 +3,5 @@ - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> <!ENTITY firstrun_urlbar_subtext2 "A modern mobile browser from The Tor Project, the non-profit committed to a free and open web."> + +<!ENTITY sync_not_supported "Sync is not currently supported in Tor Browser on Android"> diff --git a/mobile/android/base/strings.xml.in b/mobile/android/base/strings.xml.in index c328bd6b512a..5453bed65e71 100644 --- a/mobile/android/base/strings.xml.in +++ b/mobile/android/base/strings.xml.in @@ -54,6 +54,8 @@ <string name="firstrun_welcome_restricted">&onboard_start_restricted1;</string> + <string name="sync_not_supported">&sync_not_supported;</string> + <string name="bookmarks_title">&bookmarks_title;</string> <string name="history_title">&history_title;</string> diff --git a/mobile/android/modules/Sanitizer.jsm b/mobile/android/modules/Sanitizer.jsm index f244e4a2008b..d3538d49e07f 100644 --- a/mobile/android/modules/Sanitizer.jsm +++ b/mobile/android/modules/Sanitizer.jsm @@ -183,18 +183,22 @@ Sanitizer.prototype = { sss.clearAll(); // Clear push subscriptions - await new Promise((resolve, reject) => { - let push = Cc["@mozilla.org/push/Service;1"].getService( - Ci.nsIPushService - ); - push.clearForDomain("*", status => { - if (Components.isSuccessCode(status)) { - resolve(); - } else { - reject(new Error("Error clearing push subscriptions: " + status)); - } - }); - }); + //await new Promise((resolve, reject) => { + // let push = Cc["@mozilla.org/push/Service;1"].getService( + // Ci.nsIPushService + // ); + // push.clearForDomain("*", status => { + // if (Components.isSuccessCode(status)) { + // resolve(); + // } else { + // reject(new Error("Error clearing push subscriptions: " + status)); + // } + // }); + //}); + + // Avoid throwing an error because Ci.nsIPushService isn't implemented + // All other clearing actions should succeed if we arrive here. + Promise.resolve(); TelemetryStopwatch.finish("FX_SANITIZE_SITESETTINGS", refObj); }, @@ -491,14 +495,17 @@ Sanitizer.prototype = { }, canClear: function(aCallback) { - Accounts.anySyncAccountsExist() - .then(aCallback) - .catch(function(err) { - Cu.reportError("Java-side synced tabs clearing failed: " + err); - aCallback(false); - }); - }, - }, + //Accounts.anySyncAccountsExist() + // .then(aCallback) + // .catch(function(err) { + // Cu.reportError("Java-side synced tabs clearing failed: " + err); + // aCallback(false); + // }); + + // We can't clear syncedTabs because Sync is non-functional + aCallback(false); + } + } }, }; diff --git a/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/FirefoxAccounts.java b/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/FirefoxAccounts.java index 74b10c477237..a207f9b237ad 100644 --- a/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/FirefoxAccounts.java +++ b/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/FirefoxAccounts.java @@ -7,6 +7,7 @@ package org.mozilla.gecko.fxa; import java.io.File; import java.util.concurrent.CountDownLatch; +import org.mozilla.gecko.AppConstants; import org.mozilla.gecko.background.common.log.Logger; import org.mozilla.gecko.fxa.authenticator.AccountPickler; import org.mozilla.gecko.fxa.authenticator.AndroidFxAccount; @@ -49,15 +50,22 @@ public class FirefoxAccounts { * @return Firefox account objects. */ public static Account[] getFirefoxAccounts(final Context context) { - final Account[] accounts = - AccountManager.get(context).getAccountsByType(FxAccountConstants.ACCOUNT_TYPE); - if (accounts.length > 0) { - FirefoxAccountsUtils.optionallySeparateAccountsDuringFirstRun(context, accounts); - return accounts; - } + if (AppConstants.isTorBrowser()) { + return new Account[0]; + } else { + // TBA: Conditionally disable this at run-time. + // XXX This will throw a java.lang.SecurityException because we don't declare + // the android.permission.GET_ACCOUNTS permission. + final Account[] accounts = + AccountManager.get(context).getAccountsByType(FxAccountConstants.ACCOUNT_TYPE); + if (accounts.length > 0) { + FirefoxAccountsUtils.optionallySeparateAccountsDuringFirstRun(context, accounts); + return accounts; + } - final Account pickledAccount = getPickledAccount(context); - return (pickledAccount != null) ? new Account[] {pickledAccount} : new Account[0]; + final Account pickledAccount = getPickledAccount(context); + return (pickledAccount != null) ? new Account[] {pickledAccount} : new Account[0]; + } } private static Account getPickledAccount(final Context context) { @@ -111,9 +119,14 @@ public class FirefoxAccounts { } public static void logSyncOptions(Bundle syncOptions) { - final boolean scheduleNow = syncOptions.getBoolean(ContentResolver.SYNC_EXTRAS_IGNORE_BACKOFF, false); + if (AppConstants.isTorBrowser()) { + // Don't log an erroneous message, this'll only confuse someone looking at the logs. + return; + } else { + final boolean scheduleNow = syncOptions.getBoolean(ContentResolver.SYNC_EXTRAS_IGNORE_BACKOFF, false); - Logger.info(LOG_TAG, "Sync options -- scheduling now: " + scheduleNow); + Logger.info(LOG_TAG, "Sync options -- scheduling now: " + scheduleNow); + } } public static void requestImmediateSync(final Account account, String[] stagesToSync, String[] stagesToSkip, boolean ignoreSettings) { @@ -145,28 +158,32 @@ public class FirefoxAccounts { * @param stagesToSkip stage names to skip. */ protected static void requestSync(final Account account, final Bundle syncOptions, String[] stagesToSync, String[] stagesToSkip) { - if (account == null) { - throw new IllegalArgumentException("account must not be null"); - } - if (syncOptions == null) { - throw new IllegalArgumentException("syncOptions must not be null"); - } + if (AppConstants.isTorBrowser()) { + return; + } else { + if (account == null) { + throw new IllegalArgumentException("account must not be null"); + } + if (syncOptions == null) { + throw new IllegalArgumentException("syncOptions must not be null"); + } - Utils.putStageNamesToSync(syncOptions, stagesToSync, stagesToSkip); + Utils.putStageNamesToSync(syncOptions, stagesToSync, stagesToSkip); - Logger.info(LOG_TAG, "Requesting sync."); - logSyncOptions(syncOptions); + Logger.info(LOG_TAG, "Requesting sync."); + logSyncOptions(syncOptions); - // We get strict mode warnings on some devices, so make the request on a - // background thread. - ThreadPool.run(new Runnable() { - @Override - public void run() { - for (String authority : AndroidFxAccount.DEFAULT_AUTHORITIES_TO_SYNC_AUTOMATICALLY_MAP.keySet()) { - ContentResolver.requestSync(account, authority, syncOptions); + // We get strict mode warnings on some devices, so make the request on a + // background thread. + ThreadPool.run(new Runnable() { + @Override + public void run() { + for (String authority : AndroidFxAccount.DEFAULT_AUTHORITIES_TO_SYNC_AUTOMATICALLY_MAP.keySet()) { + ContentResolver.requestSync(account, authority, syncOptions); + } } - } - }); + }); + } } /** diff --git a/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/authenticator/AndroidFxAccount.java b/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/authenticator/AndroidFxAccount.java index 4562559afc44..8d2b8bd2cd4a 100644 --- a/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/authenticator/AndroidFxAccount.java +++ b/mobile/android/services/src/main/java/org/mozilla/gecko/fxa/authenticator/AndroidFxAccount.java @@ -29,6 +29,7 @@ import android.support.v4.content.LocalBroadcastManager; import android.text.TextUtils; import android.util.Log; +import org.mozilla.gecko.AppConstants; import org.mozilla.gecko.background.common.GlobalConstants; import org.mozilla.gecko.background.common.log.Logger; import org.mozilla.gecko.background.fxa.FxAccountUtils; @@ -708,7 +709,11 @@ public class AndroidFxAccount { * @param ignoreSettings whether we should check if syncing is allowed via in-app or system settings. */ public void requestImmediateSync(String[] stagesToSync, String[] stagesToSkip, boolean ignoreSettings) { - FirefoxAccounts.requestImmediateSync(getAndroidAccount(), stagesToSync, stagesToSkip, ignoreSettings); + if (AppConstants.isTorBrowser()) { + return; + } else { + FirefoxAccounts.requestImmediateSync(getAndroidAccount(), stagesToSync, stagesToSkip, ignoreSettings); + } } /** @@ -719,7 +724,11 @@ public class AndroidFxAccount { * @param stagesToSkip stage names to skip; can be null to skip <b>no</b> known stages. */ public void requestEventualSync(String[] stagesToSync, String[] stagesToSkip) { - FirefoxAccounts.requestEventualSync(getAndroidAccount(), stagesToSync, stagesToSkip); + if (AppConstants.isTorBrowser()) { + return; + } else { + FirefoxAccounts.requestEventualSync(getAndroidAccount(), stagesToSync, stagesToSkip); + } } public synchronized void setState(State state) {
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Add mobile-override of 000-tor-browser prefs
by gk@torproject.org 31 Aug '19

31 Aug '19
commit f0c4f9219012e04982d99f92c2808716bc8b9cc4 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Fri Jan 19 23:49:11 2018 +0000 Bug 25741 - TBA: Add mobile-override of 000-tor-browser prefs --- .eslintignore | 3 ++ mobile/android/app/000-tor-browser-android.js | 61 +++++++++++++++++++++++++++ mobile/android/app/mobile.js | 4 ++ mobile/android/app/moz.build | 1 + mobile/android/installer/package-manifest.in | 1 + 5 files changed, 70 insertions(+) diff --git a/.eslintignore b/.eslintignore index 2fc0d61fabe5..e8dbe3a037a3 100644 --- a/.eslintignore +++ b/.eslintignore @@ -227,6 +227,9 @@ media/webrtc/trunk/** # mobile/android/ exclusions mobile/android/tests/browser/chrome/tp5/** +# uses `#include` +mobile/android/app/000-tor-browser-android.js + # Uses `#filter substitution` mobile/android/app/mobile.js mobile/android/app/geckoview-prefs.js diff --git a/mobile/android/app/000-tor-browser-android.js b/mobile/android/app/000-tor-browser-android.js new file mode 100644 index 000000000000..02e3ef00c1b3 --- /dev/null +++ b/mobile/android/app/000-tor-browser-android.js @@ -0,0 +1,61 @@ +// Import all prefs from the canonical file +// We override mobile-specific prefs below +// Tor Browser for Android +// Do not edit this file. + +#include ../../../browser/app/profile/000-tor-browser.js + + +// Disable Presentation API +pref("dom.presentation.controller.enabled", false); +pref("dom.presentation.enabled", false); +pref("dom.presentation.discoverable", false); +pref("dom.presentation.discoverable.encrypted", false); +pref("dom.presentation.discovery.enabled", false); +pref("dom.presentation.receiver.enabled", false); + +pref("dom.audiochannel.audioCompeting", false); +pref("dom.audiochannel.mediaControl", false); + +// Space separated list of URLs that are allowed to send objects (instead of +// only strings) through webchannels. This list is duplicated in browser/app/profile/firefox.js +pref("webchannel.allowObject.urlWhitelist", ""); + +// Disable browser auto updaters +pref("app.update.auto", false); +pref("app.update.enabled", false); +pref("browser.startup.homepage_override.mstone", "ignore"); + +// Clear data on quit +pref("privacy.clearOnShutdown.cache", true); +pref("privacy.clearOnShutdown.cookies",true); +pref("privacy.clearOnShutdown.downloads",true); +pref("privacy.clearOnShutdown.formdata",true); +pref("privacy.clearOnShutdown.history",true); +pref("privacy.clearOnShutdown.offlineApps",true); +pref("privacy.clearOnShutdown.passwords",true); +pref("privacy.clearOnShutdown.sessions",true); +pref("privacy.clearOnShutdown.siteSettings",true); + +// Disable Control media casting & mirroring features +pref("browser.casting.enabled", false); +pref("browser.mirroring.enabled", false); + +// Disable autoplay +pref("media.autoplay.enabled", false); + +// controls if we want camera support +pref("device.camera.enabled", false); +pref("media.realtime_decoder.enabled", false); + +// Do not fetch updated per-site user-agent strings from Mozilla +// See ua-update.json.in for the packaged UA override list +// See https://bugzilla.mozilla.org/show_bug.cgi?id=897221 +pref("general.useragent.updates.enabled", false); +pref("general.useragent.updates.url", ""); + +// Enable touch events on Android (highlighting text, etc) +pref("dom.w3c_touch_events.enabled", 2); + +// Inherit locale from the OS, used for multi-locale builds +pref("intl.locale.requested", ""); diff --git a/mobile/android/app/mobile.js b/mobile/android/app/mobile.js index 9d4f331e968f..1d69f082da27 100644 --- a/mobile/android/app/mobile.js +++ b/mobile/android/app/mobile.js @@ -483,7 +483,11 @@ pref("app.update.timerMinimumDelay", 30); // seconds // used by update service to decide whether or not to // automatically download an update pref("app.update.autodownload", "wifi"); +#ifdef TOR_BROWSER_VERSION +pref("app.update.url.android", ""); +#else pref("app.update.url.android", "https://aus5.mozilla.org/update/4/%PRODUCT%/%VERSION%/%BUILD_ID%/%BUILD_TAR…"); +#endif #ifdef MOZ_UPDATER /* prefs used specifically for updating the app */ diff --git a/mobile/android/app/moz.build b/mobile/android/app/moz.build index 8ff152f3b369..773c1a3979a8 100644 --- a/mobile/android/app/moz.build +++ b/mobile/android/app/moz.build @@ -49,6 +49,7 @@ if CONFIG['MOZ_PKG_SPECIAL']: DEFINES['MOZ_PKG_SPECIAL'] = CONFIG['MOZ_PKG_SPECIAL'] JS_PREFERENCE_PP_FILES += [ + '000-tor-browser-android.js', 'geckoview-prefs.js', 'mobile.js', ] diff --git a/mobile/android/installer/package-manifest.in b/mobile/android/installer/package-manifest.in index 3d014cbc6e67..2002a894fc51 100644 --- a/mobile/android/installer/package-manifest.in +++ b/mobile/android/installer/package-manifest.in @@ -168,6 +168,7 @@ #ifdef MOZ_GECKOVIEW_JAR @BINPATH@/@PREF_DIR@/geckoview-prefs.js #else +@BINPATH@/@PREF_DIR@/000-tor-browser-android.js @BINPATH@/@PREF_DIR@/mobile.js #endif @BINPATH@/@PREF_DIR@/channel-prefs.js
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Add an AppConstant for TOR_BROWSER_VERSION
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 7bcca0910e5ccd82858b5be0980437f61ce1df5f Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Fri Jan 19 20:13:58 2018 +0000 Bug 25741 - TBA: Add an AppConstant for TOR_BROWSER_VERSION --- .../java/org/mozilla/gecko/TorBrowserTest.java | 27 ++++++++++++++++++++++ mobile/android/base/AppConstants.java.in | 15 ++++++++++++ mobile/android/base/generate_build_config.py | 3 ++- mobile/android/geckoview/build.gradle | 1 + 4 files changed, 45 insertions(+), 1 deletion(-) diff --git a/mobile/android/app/src/test/java/org/mozilla/gecko/TorBrowserTest.java b/mobile/android/app/src/test/java/org/mozilla/gecko/TorBrowserTest.java new file mode 100644 index 000000000000..ae1d481807de --- /dev/null +++ b/mobile/android/app/src/test/java/org/mozilla/gecko/TorBrowserTest.java @@ -0,0 +1,27 @@ +/* Any copyright is dedicated to the Public Domain. + http://creativecommons.org/publicdomain/zero/1.0/ */ + +package org.mozilla.gecko; + +import org.junit.Test; +import org.junit.runner.RunWith; +import org.mozilla.gecko.background.testhelpers.TestRunner; +import org.mozilla.gecko.AppConstants; + +import static org.junit.Assert.*; + +(a)RunWith(TestRunner.class) +public class TorBrowserTest { + /** + * Tests the compile-time constants are set. + */ + @Test + public void testIsTorBrowser() { + assertTrue(AppConstants.isTorBrowser()); + } + + @Test + public void testTorBrowserVersion() { + assertEquals(AppConstants.TOR_BROWSER_VERSION, "9.0"); + } +} diff --git a/mobile/android/base/AppConstants.java.in b/mobile/android/base/AppConstants.java.in index 655a5e94cbb7..bfc594e7e801 100644 --- a/mobile/android/base/AppConstants.java.in +++ b/mobile/android/base/AppConstants.java.in @@ -357,4 +357,19 @@ public class AppConstants { //#else null; //#endif + + public static final String TOR_BROWSER_VERSION = +//#ifdef TOR_BROWSER_VERSION + "@TOR_BROWSER_VERSION@"; +//#else + null; +//#endif + + public static final boolean isTorBrowser() { +//#ifdef TOR_BROWSER_VERSION + return true; +//#else + return false; +//#endif + } } diff --git a/mobile/android/base/generate_build_config.py b/mobile/android/base/generate_build_config.py index 4e079ce2e0cd..592a8ec9dae3 100644 --- a/mobile/android/base/generate_build_config.py +++ b/mobile/android/base/generate_build_config.py @@ -63,7 +63,8 @@ def _defines(): 'MOZ_ANDROID_MAX_SDK_VERSION', 'MOZ_ANDROID_MIN_SDK_VERSION', 'MOZ_PKG_SPECIAL', - 'MOZ_UPDATER'): + 'MOZ_UPDATER', + 'TOR_BROWSER_VERSION'): if CONFIG[var]: DEFINES[var] = CONFIG[var] diff --git a/mobile/android/geckoview/build.gradle b/mobile/android/geckoview/build.gradle index 84035fdce449..fe1b1ca7cb7a 100644 --- a/mobile/android/geckoview/build.gradle +++ b/mobile/android/geckoview/build.gradle @@ -89,6 +89,7 @@ android { buildConfigField 'String', "MOZ_APP_DISPLAYNAME", "\"${mozconfig.substs.MOZ_APP_DISPLAYNAME}\""; buildConfigField 'String', "MOZ_APP_UA_NAME", "\"${mozconfig.substs.MOZ_APP_UA_NAME}\""; buildConfigField 'String', "MOZ_UPDATE_CHANNEL", "\"${mozconfig.substs.MOZ_UPDATE_CHANNEL}\""; + buildConfigField 'String', "TOR_BROWSER_VERSION", "\"${mozconfig.substs.TOR_BROWSER_VERSION}\""; // MOZILLA_VERSION is oddly quoted from autoconf, but we don't have to handle it specially in Gradle. buildConfigField 'String', "MOZILLA_VERSION", "\"${mozconfig.substs.MOZILLA_VERSION}\"";
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Disable features at compile-time
by gk@torproject.org 31 Aug '19

31 Aug '19
commit 91d7eba5e984f19d8e3af209e33f571c78001131 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Mon Apr 9 19:48:12 2018 +0000 Bug 25741 - TBA: Disable features at compile-time MOZ_NATIVE_DEVICES for casting and the media player MOZ_TELEMETRY_REPORTING for telemetry MOZ_DATA_REPORTING for all data reporting preferences (crashreport, telemetry, geo) --- mobile/android/confvars.sh | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/mobile/android/confvars.sh b/mobile/android/confvars.sh index 77191834d240..e2fcd2f0bb4c 100644 --- a/mobile/android/confvars.sh +++ b/mobile/android/confvars.sh @@ -30,9 +30,22 @@ MOZ_ANDROID_BROWSER_INTENT_CLASS=org.mozilla.gecko.BrowserApp MOZ_NO_SMART_CARDS=1 +# Adds MIME-type support for raw video MOZ_RAW=1 # use custom widget for html:select MOZ_USE_NATIVE_POPUP_WINDOWS=1 MOZ_APP_ID={aa3c5121-dab2-40e2-81ca-7ea25febc110} + +### Tor Browser for Android ### + +# Disables support at compile-time for casting (Mozilla Media Manager) +# and prevents dependency on Google Play Services support +unset MOZ_NATIVE_DEVICES + +# Disable telemetry at compile-time +unset MOZ_TELEMETRY_REPORTING + +# Disable data reporting at compile-time +unset MOZ_DATA_REPORTING
1 0
0 0
[tor-browser/tor-browser-68.1.0esr-9.0-1] Bug 25741 - TBA: Move GCM Push prefs within preprocessor guard
by gk@torproject.org 31 Aug '19

31 Aug '19
commit f130103fc3403cb6c9dbedd314a7face0e4e42e7 Author: Matthew Finkel <Matthew.Finkel(a)gmail.com> Date: Sun Apr 15 14:19:38 2018 +0000 Bug 25741 - TBA: Move GCM Push prefs within preprocessor guard Otherwise the preprocessor is sad because MOZ_ANDROID_GCM_SENDERID is not defined. We don't need any of this, so we exclude it. --- mobile/android/app/mobile.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mobile/android/app/mobile.js b/mobile/android/app/mobile.js index 3e13d0d81a5d..9d4f331e968f 100644 --- a/mobile/android/app/mobile.js +++ b/mobile/android/app/mobile.js @@ -813,13 +813,13 @@ pref("dom.serviceWorkers.enabled", true); // click on mobile. This is to account for some devices being quite slow. pref("dom.serviceWorkers.disable_open_click_delay", 5000); +#ifdef MOZ_ANDROID_GCM pref("dom.push.debug", false); // The upstream autopush endpoint must have the Google API key corresponding to // the App's sender ID; we bake this assumption directly into the URL. pref("dom.push.serverURL", "https://updates.push.services.mozilla.com/v1/gcm/@MOZ_ANDROID_GCM_SENDERID@"); pref("dom.push.maxRecentMessageIDsPerSubscription", 0); -#ifdef MOZ_ANDROID_GCM pref("dom.push.enabled", true); #endif
1 0
0 0
  • ← Newer
  • 1
  • ...
  • 602
  • 603
  • 604
  • 605
  • 606
  • 607
  • 608
  • ...
  • 805
  • Older →

HyperKitty Powered by HyperKitty version 1.3.12.