Skip to content
Snippets Groups Projects
  1. Nov 16, 2023
    • Richard Pospesel's avatar
      Bug 23247: Communicating security expectations for .onion · 5251ffb3
      Richard Pospesel authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      Encrypting pages hosted on Onion Services with SSL/TLS is redundant
      (in terms of hiding content) as all traffic within the Tor network is
      already fully encrypted.  Therefore, serving HTTP pages from an Onion
      Service is more or less fine.
      
      Prior to this patch, Tor Browser would mostly treat pages delivered
      via Onion Services as well as pages delivered in the ordinary fashion
      over the internet in the same way.  This created some inconsistencies
      in behaviour and misinformation presented to the user relating to the
      security of pages delivered via Onion Services:
      
       - HTTP Onion Service pages did not have any 'lock' icon indicating
         the site was secure
       - HTTP Onion Service pages would be marked as unencrypted in the Page
         Info screen
       - Mixed-mode content restrictions did not apply to HTTP Onion Service
         pages embedding Non-Onion HTTP content
      
      This patch fixes the above issues, and also adds several new 'Onion'
      icons to the mix to indicate all of the various permutations of Onion
      Services hosted HTTP or HTTPS pages with HTTP or HTTPS content.
      
      Strings for Onion Service Page Info page are pulled from Torbutton's
      localization strings.
      Verified
      5251ffb3
    • Matthew Finkel's avatar
      Bug 25741: TBA: Disable GeckoNetworkManager · a5d470a5
      Matthew Finkel authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      The browser should not need information related to the network
      interface or network state, tor should take care of that.
      Verified
      a5d470a5
    • Amogh Pradeep's avatar
      Orfox: Centralized proxy applied to AbstractCommunicator and BaseResources. · f1753587
      Amogh Pradeep authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      See Bug 1357997 for partial uplift.
      
      Also:
      Bug 28051 - Use our Orbot for proxying our connections
      
      Bug 31144 - ESR68 Network Code Review
      Verified
      f1753587
    • Pier Angelo Vendrame's avatar
      fixup! Bug 3455: Add DomainIsolator, for isolating circuit by domain. · b88d55ed
      Pier Angelo Vendrame authored
      TorStartupService is not launched on Android, so initialize FPI in
      another script that is used by GV (and only once, if I understand
      correctly).
      Verified
      b88d55ed
    • Pier Angelo Vendrame's avatar
      Bug 40562: Added Tor Browser preferences to 000-tor-browser.js · ec7131df
      Pier Angelo Vendrame authored
      Before reordering patches, we used to keep the Tor-related patches
      (torbutton and tor-launcher) at the beginning.
      After that issue, we decided to move them towards the end.
      
      In addition to that, we have decided to move Tor Browser-only
      preferences there, too, to make Base Browser-only fixups easier to
      apply.
      Verified
      ec7131df
    • Mike Perry's avatar
      TB3: Tor Browser's official .mozconfigs. · 35eff57d
      Mike Perry authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      Also:
      Add an --enable-tor-browser-data-outside-app-dir configure option
      
      Add --with-tor-browser-version configure option
      
      Bug 31457: disable per-installation profiles
      
      The dedicated profiles (per-installation) feature does not interact
      well with our bundled profiles on Linux and Windows, and it also causes
      multiple profiles to be created on macOS under TorBrowser-Data.
      
      Bug 31935: Disable profile downgrade protection.
      
      Since Tor Browser does not support more than one profile, disable
      the prompt and associated code that offers to create one when a
      version downgrade situation is detected.
      
      Add --enable-tor-browser-update build option
      
      Bug 40793: moved Tor configuration options from old-configure.in to moz.configure
      
      Bug 41584: Move some configuration options to base-browser level
      Verified
      35eff57d
    • Mike Perry's avatar
      Bug 2176: Rebrand Firefox to TorBrowser · 6a8fe2d4
      Mike Perry authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      See also Bugs #5194, #7187, #8115, #8219.
      
      This patch does some basic renaming of Firefox to TorBrowser. The rest of the
      branding is done by images and icons.
      
      Also fix bug 27905.
      
      Bug 25702: Update Tor Browser icon to follow design guidelines
      
      - Updated all of the branding in /browser/branding/official with new 'stable'
      icon series.
      - Updated /extensions/onboarding/content/img/tor-watermark.png with new icon and
      add the source svg in the same directory
      - Copied /browser/branding/official over /browser/branding/nightly and the new
      /browser/branding/alpha directories. Replaced content with 'nightly' and
      'alpha' icon series.
      Updated VisualElements_70.png and VisualElements_150.png with updated icons in
      each branding directory (fixes #22654)
      - Updated firefox.VisualElementsManfiest.xml with updated colors in each
      branding directory
      - Added firefox.svg to each branding directory from which all the other icons
      are derived (apart from document.icns and document.ico)
      - Added default256.png and default512.png icons
      - Updated aboutTBUpdate.css to point to branding-aware icon128.png and removed
      original icon
      - Use the Tor Browser icon within devtools/client/themes/images/.
      
      Bug 30631: Blurry Tor Browser icon on macOS app switcher
      
      It would seem the png2icns tool does not generate correct icns files and
      so on macOS the larger icons were missing resulting in blurry icons in
      the OS chrome. Regenerated the padded icons in a macOS VM using
      iconutil.
      
      Bug 28196: preparations for using torbutton tor-browser-brand.ftl
      
      A small change to Fluent FileSource class is required so that we
      can register a new source without its supported locales being
      counted as available locales for the browser.
      
      Bug 31803: Replaced about:debugging logo with flat version
      
      Bug 21724: Make Firefox and Tor Browser distinct macOS apps
      
      When macOS opens a document or selects a default browser, it sometimes
      uses the CFBundleSignature. Changing from the Firefox MOZB signature to
      a different signature TORB allows macOS to distinguish between Firefox
      and Tor Browser.
      
      Bug 32092: Fix Tor Browser Support link in preferences
      
      For bug 40562, we moved onionPattern* from bug 27476 to here, as
      about:tor needs these files but it is included earlier.
      
      Bug 41278: Create Tor Browser styled pdf logo similar to the vanilla Firefox one
      
      Bug 42088: New application icons (used in-app and on linux).
      
      Bug 42087: New application icons (windows).
      Verified
      6a8fe2d4
    • Alex Catarineu's avatar
      Add TorStrings module for localization · 3c5d1566
      Alex Catarineu authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      Verified
      3c5d1566
    • Pier Angelo Vendrame's avatar
      Bug 40925: Implemented the Security Level component · 309d0890
      Pier Angelo Vendrame authored
      This component adds a new Security Level toolbar button which visually
      indicates the current global security level via icon (as defined by the
      extensions.torbutton.security_slider pref), a drop-down hanger with a
      short description of the current security level, and a new section in
      the about:preferences#privacy page where users can change their current
      security level. In addition, the hanger and the preferences page will
      show a visual warning when the user has modified prefs associated with
      the security level and provide a one-click 'Restore Defaults' button to
      get the user back on recommended settings.
      
      Bug 40125: Expose Security Level pref in GeckoView
      Verified
      309d0890
    • p13dz's avatar
      Bug 40283: Workaround for the file upload bug · 65accbc7
      p13dz authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      Verified
      65accbc7
    • Alex Catarineu's avatar
    • Alex Catarineu's avatar
    • Alex Catarineu's avatar
      Bug 30605: Honor privacy.spoof_english in Android · 44514554
      Alex Catarineu authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      This checks `privacy.spoof_english` whenever `setLocales` is
      called from Fenix side and sets `intl.accept_languages`
      accordingly.
      
      Bug 40198: Expose privacy.spoof_english pref in GeckoView
      Verified
      44514554
    • Mike Perry's avatar
      Firefox preference overrides. · 2cea4fea
      Mike Perry authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      This hack directly includes our preference changes in omni.ja.
      
      Bug 18292: Staged updates fail on Windows
      
      Temporarily disable staged updates on Windows.
      
      Bug 18297: Use separate Noto JP,KR,SC,TC fonts
      
      Bug 23404: Add Noto Sans Buginese to the macOS whitelist
      
      Bug 23745: Set dom.indexedDB.enabled = true
      
      Bug 13575: Disable randomised Firefox HTTP cache decay user tests.
      (Fernando Fernandez Mancera <ffmancera@riseup.net>)
      
      Bug 17252: Enable session identifiers with FPI
      
      Session tickets and session identifiers were isolated
      by OriginAttributes, so we can re-enable them by
      allowing the default value (true) of
      "security.ssl.disable_session_identifiers".
      
      The pref "security.enable_tls_session_tickets" is obsolete
      (removed in https://bugzilla.mozilla.org/917049)
      
      Bug 14952: Enable http/2 and AltSvc
      
      In Firefox, SPDY/HTTP2 now uses Origin Attributes for
      isolation of connections, push streams, origin frames, etc.
      That means we get first-party isolation provided
      "privacy.firstparty.isolate" is true. So in this patch, we
      stop overriding "network.http.spdy.enabled" and
      "network.http.spdy.enabled.http2".
      
      Alternate Services also use Origin Attributes for isolation.
      So we stop overriding
      "network.http.altsvc.enabled" and "network.http.altsvc.oe"
      as well.
      
      (All 4 of the abovementioned "network.http.*" prefs adopt
      Firefox 60ESR's default value of true.)
      
      However, we want to disable HTTP/2 push for now, so we
      set "network.http.spdy.allow-push" to false.
      
      "network.http.spdy.enabled.http2draft" was removed in Bug 1132357.
      "network.http.sped.enabled.v2" was removed in Bug 912550.
      "network.http.sped.enabled.v3" was removed in Bug 1097944.
      "network.http.sped.enabled.v3-1" was removed in Bug 1248197.
      
      Bug 26114: addons.mozilla.org is not special
      * Don't expose navigator.mozAddonManager on any site
      * Don't block NoScript from modifying addons.mozilla.org or other sites
      
      Enable ReaderView mode again (#27281).
      
      Bug 29916: Make sure enterprise policies are disabled
      
      Bug 2874: Block Components.interfaces from content
      
      Bug 26146: Spoof HTTP User-Agent header for desktop platforms
      
      In Tor Browser 8.0, the OS was revealed in both the HTTP User-Agent
      header and to JavaScript code via navigator.userAgent. To avoid
      leaking the OS inside each HTTP request (which many web servers
      log), always use the Windows 7 OS value in the desktop User-Agent
      header. We continue to allow access to the actual OS via JavaScript,
      since doing so improves compatibility with web applications such
      as GitHub and Google Docs.
      
      Bug 12885: Windows Jump Lists fail for Tor Browser
      
      Jumplist entries are stored in a binary file in:
        %APPDATA%\\Microsoft\Windows\Recent\CustomDestinations\
      and has a name in the form
        [a-f0-9]+.customDestinations-ms
      
      The hex at the front is unique per app, and is ultimately derived from
      something called the 'App User Model ID' (AUMID) via some unknown
      hashing method. The AUMID is provided as a key when programmatically
      creating, updating, and deleting a jumplist. The default behaviour in
      firefox is for the installer to define an AUMID for an app, and save it
      in the registry so that the jumplist data can be removed by the
      uninstaller.
      
      However, the Tor Browser does not set this (or any other) regkey during
      installation, so this codepath fails and the app's AUMID is left
      undefined. As a result the app's AUMID ends up being defined by
      windows, but unknowable by Tor Browser. This unknown AUMID is used to
      create and modify the jumplist, but the delete API requires that we
      provide the app's AUMID explicitly. Since we don't know what the AUMID
      is (since the expected regkey where it is normally stored does not
      exist) jumplist deletion will fail and we will leave behind a mostly
      empty customDestinations-ms file. The name of the file is derived from
      the binary path, so an enterprising person could reverse engineer how
      that hex name is calculated, and generate the name for Tor Browser's
      default Desktop installation path to determine whether a person had
      used Tor Browser in the past.
      
      The 'taskbar.grouping.useprofile' option that is enabled by this patch
      works around this AUMID problem by having firefox.exe create it's own
      AUMID based on the profile path (rather than looking for a regkey). This
      way, if a user goes in and enables and disables jumplist entries, the
      backing store is properly deleted.
      
      Unfortunately, all windows users currently have this file lurking in
      the above mentioned directory and this patch will not remove it since it
      was created with an unknown AUMID. However, another patch could be
      written which goes to that directory and deletes any item containing the
      'Tor Browser' string.  See bug 28996.
      
      Bug 30845: Make sure default themes and other internal extensions are enabled
      
      Bug 28896: Enable extensions in private browsing by default
      
      Bug 31065: Explicitly allow proxying localhost
      
      Bug 31598: Enable letterboxing
      
      Disable Presentation API everywhere
      
      Bug 21549 - Use Firefox's WASM default pref. It is disabled at safer
      security levels.
      
      Bug 32321: Disable Mozilla's MitM pings
      
      Bug 19890: Disable installation of system addons
      
      By setting the URL to "" we make sure that already installed system
      addons get deleted as well.
      
      Bug 22548: Firefox downgrades VP9 videos to VP8.
      
      On systems where H.264 is not available or no HWA, VP9 is preferred. But in Tor
      Browser 7.0 all youtube videos are degraded to VP8.
      
      This behaviour can be turned off by setting media.benchmark.vp9.threshold to 0.
      All clients will get better experience and lower traffic, beause TBB doesn't
      use "Use hardware acceleration when available".
      
      Bug 25741 - TBA: Add mobile-override of 000-tor-browser prefs
      
      Bug 16441: Suppress "Reset Tor Browser" prompt.
      
      Bug 29120: Use the in-memory media cache and increase its maximum size.
      
      Bug 33697: use old search config based on list.json
      
      Bug 33855: Ensure that site-specific browser mode is disabled.
      
      Bug 30682: Disable Intermediate CA Preloading.
      
      Bug 40061: Omit the Windows default browser agent from the build
      
      Bug 40322: Consider disabling network.connectivity-service.enabled
      
      Bug 40408: Disallow SVG Context Paint in all web content
      
      Bug 40308: Disable network partitioning until we evaluate dFPI
      
      Bug 40322: Consider disabling network.connectivity-service.enabled
      
      Bug 40383: Disable dom.enable_event_timing
      
      Bug 40423: Disable http/3
      
      Bug 40177: Update prefs for Fx91esr
      
      Bug 40700: Disable addons and features recommendations
      
      Bug 40682: Disable network.proxy.allow_bypass
      
      Bug 40736: Disable third-party cookies in PBM
      
      Bug 19850: Enabled HTTPS-Only by default
      
      Bug 40912: Hide the screenshot menu
      
      Bug 41292: Disable moreFromMozilla in preferences page
      
      Bug 40057: Ensure the CSS4 system colors are not a fingerprinting vector
      
      Bug 24686: Set network.http.tailing.enabled to true
      
      Bug 40183: Disable TLS ciphersuites using SHA-1
      
      Bug 40783: Review 000-tor-browser.js and 001-base-profile.js for 102
      
      We reviewed all the preferences we set for 102, and remove a few old
      ones. See the description of that issue to see all the preferences we
      believed were still valid for 102, and some brief description for the
      reasons to keep them.
      Verified
      2cea4fea
    • Matthew Finkel's avatar
      Bug 28125: Prevent non-Necko network connections · 439c9d4d
      Matthew Finkel authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      Verified
      439c9d4d
    • Matthew Finkel's avatar
      Bug 24796: Comment out excess permissions from GeckoView · 2f5d3e9b
      Matthew Finkel authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      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.
      Verified
      2f5d3e9b
    • Pier Angelo Vendrame's avatar
      Tweaks to the build system · d3925b5b
      Pier Angelo Vendrame authored
      Bug 40857: Modified the fat .aar creation file
      
      This is a workaround to build fat .aars with the compiling enviornment
      disabled.
      Mozilla does not use a similar configuration, but either runs a Firefox
      build and discards its output, or uses artifacts build.
      
      We might switch to artifact builds too, and drop this patch, or write a
      better one to upstream. But until then we need this patch.
      
      See also https://bugzilla.mozilla.org/show_bug.cgi?id=1763770.
      
      Bug 41458: Prevent `mach package-multi-locale` from actually creating a package
      
      macOS builds need some files to be moved around with
      ./mach package-multi-locale to create multi-locale packages.
      The required command isn't exposed through any other mach command.
      So, we patch package-multi-locale both to prevent it from failing when
      doing official builds and to detect any future changes on it.
      Verified
      d3925b5b
    • Pier Angelo Vendrame's avatar
      Base Browser's .mozconfigs. · 9f15c9c7
      Pier Angelo Vendrame authored
      Bug 17858: Cannot create incremental MARs for hardened builds.
      Define HOST_CFLAGS, etc. to avoid compiling programs such as mbsdiff
      (which is part of mar-tools and is not distributed to end-users) with
      ASan.
      
      Bug 21849: Don't allow SSL key logging.
      
      Bug 25741 - TBA: Disable features at compile-time
      
      Define MOZ_ANDROID_NETWORK_STATE and MOZ_ANDROID_LOCATION
      
      Bug 27623 - Export MOZILLA_OFFICIAL during desktop builds
      
      This fixes a problem where some preferences had the wrong default value.
      Also see bug 27472 where we made a similar fix for Android.
      
      Bug 29859: Disable HLS support for now
      
      Bug 30463: Explicitly disable MOZ_TELEMETRY_REPORTING
      
      Bug 32493: Disable MOZ_SERVICES_HEALTHREPORT
      
      Bug 33734: Set MOZ_NORMANDY to False
      
      Bug 33851: Omit Parental Controls.
      
      Bug 40252: Add --enable-rust-simd to our tor-browser mozconfig files
      
      Bug 41584: Move some configuration options to base-browser level
      Verified
      9f15c9c7
  2. Aug 15, 2023
  3. Jun 05, 2023
  4. Jun 04, 2023
    • Rob Wu's avatar
      Bug 1836482 - Replace AddonManager.jsm imports with AddonManager.sys.mjs... · 3c0c3a26
      Rob Wu authored
      Bug 1836482 - Replace AddonManager.jsm imports with AddonManager.sys.mjs r=Standard8,webcompat-reviewers,twisniewski
      
      This patch was generated as follows:
      
      Run:
      `./mach esmify --imports . --prefix=toolkit/mozapps/extensions/AddonManager`
      In the output there are linter/prettifier errors due to unused
      XPCOMUtils or separate importESModule calls. These have been fixed
      manually and verified with `./mach lint --outgoing`.
      
      The `esmify` script also inserts many unwanted newlines around imports
      that are broken on two lines due to length. Due to the number of these,
      I fixed them programatically.
      
      1. Create patch from the changes so far.
      2. From the patch, delete all lines that consist of "+" (i.e. added blank line).
      3. Reset the working dir and apply the revised patch.
      4. Verify that the diff between step 1 and 3 looks reasonable.
      5. Verify that this patch as a whole looks reasonable.
      
      Commands:
      
      ```
      git diff > rename.diff
      :%g/^+$/d
      git commit -va -m WIP-rename
      git revert HEAD
      git apply --recount rename.diff
      git diff HEAD^  # and verify that the removed lines are ok.
      git commit -va  # one last review to verify correctness of whole patch.
      git rebase -i HEAD~3  # drop the WIP + reverted commit, pick only the last.
      ```
      
      `git apply` has the `--recount` option to force it to ignore mismatches
      in line counts, which happens because we deleted added lines (^+$)
      without fixing up the line counts in the file headers.
      
      Differential Revision: https://phabricator.services.mozilla.com/D179874
      3c0c3a26
    • Makoto Kato's avatar
      Bug 1836432 - Use nsresult exception mode for GeckoAppShell.getDNSDomains.... · 19f275b6
      Makoto Kato authored
      Bug 1836432 - Use nsresult exception mode for GeckoAppShell.getDNSDomains. r=geckoview-reviewers,necko-reviewers,valentin,ohall
      
      There is some OOM errors by `GeckoAppShell.getDNSDomains`. Since
      `nsAndroidNetworkLinkService::GetDnsSuffixList` can returns `nsresult`, we
      should return error instead of crash.
      
      Differential Revision: https://phabricator.services.mozilla.com/D179791
      19f275b6
  5. Jun 02, 2023
  6. Jun 01, 2023
  7. May 31, 2023
  8. Jun 01, 2023
  9. May 30, 2023
    • Makoto Kato's avatar
      Bug 1827583 - Set event listener to current media control after switching... · 7af39f7f
      Makoto Kato authored
      Bug 1827583 - Set event listener to current media control after switching process. r=geckoview-reviewers,amejiamarmol,jonalmeida
      
      This issue is a timing issue of loading content via about:config etc.
      
      Although `GeckoViewMediaControl` registers event listeners for
      `MediaController` when enabling `MediaSessionDelegate`, if process
      switching occurs, `browsingContenxt` and `MediaController` are re-created.
      
      It means that we has to register newer `MediaController`.
      
      To detect destroying current browser, I will add `onDestroyBrowser` to
      `GeckoViewModule` again (This was removed by bug 1672262).
      
      Differential Revision: https://phabricator.services.mozilla.com/D179177
      7af39f7f
    • Makoto Kato's avatar
      Bug 1827583 - Set event listener to current media control after switching... · 630e8929
      Makoto Kato authored
      Bug 1827583 - Set event listener to current media control after switching process. r=geckoview-reviewers,amejiamarmol,jonalmeida a=pascalc
      
      This issue is a timing issue of loading content via about:config etc.
      
      Although `GeckoViewMediaControl` registers event listeners for
      `MediaController` when enabling `MediaSessionDelegate`, if process
      switching occurs, `browsingContenxt` and `MediaController` are re-created.
      
      It means that we has to register newer `MediaController`.
      
      To detect destroying current browser, I will add `onDestroyBrowser` to
      `GeckoViewModule` again (This was removed by bug 1672262).
      
      Differential Revision: https://phabricator.services.mozilla.com/D179177
      630e8929
  10. May 29, 2023
  11. May 28, 2023
  12. May 26, 2023
  13. May 25, 2023
  14. May 24, 2023
Loading