Skip to content
Snippets Groups Projects
  1. Dec 13, 2023
    • Alex Catarineu's avatar
      Bug 21952: Implement Onion-Location · ed272ca5
      Alex Catarineu authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      Whenever a valid Onion-Location HTTP header (or corresponding HTML
      <meta> http-equiv attribute) is found in a document load, we either
      redirect to it (if the user opted-in via preference) or notify the
      presence of an onionsite alternative with a badge in the urlbar.
      ed272ca5
    • Kathleen Brade's avatar
      Bug 30237: Add v3 onion services client authentication prompt · 702e7e06
      Kathleen Brade authored and Pier Angelo Vendrame's avatar Pier Angelo Vendrame committed
      When Tor informs the browser that client authentication is needed,
      temporarily load about:blank instead of about:neterror and prompt
      for the user's key.
      
      If a correctly formatted key is entered, use Tor's ONION_CLIENT_AUTH_ADD
      control port command to add the key (via Torbutton's control port
      module) and reload the page.
      
      If the user cancels the prompt, display the standard about:neterror
      "Unable to connect" page. This requires a small change to
      browser/actors/NetErrorChild.jsm to account for the fact that the
      docShell no longer has the failedChannel information. The failedChannel
      is used to extract TLS-related error info, which is not applicable
      in the case of a canceled .onion authentication prompt.
      
      Add a leaveOpen option to PopupNotifications.show so we can display
      error messages within the popup notification doorhanger without
      closing the prompt.
      
      Add support for onion services strings to the TorStrings module.
      
      Add support for Tor extended SOCKS errors (Tor proposal 304) to the
      socket transport and SOCKS layers. Improved display of all of these
      errors will be implemented as part of bug 30025.
      
      Also fixes bug 19757:
       Add a "Remember this key" checkbox to the client auth prompt.
      
       Add an "Onion Services Authentication" section within the
       about:preferences "Privacy & Security section" to allow
       viewing and removal of v3 onion client auth keys that have
       been stored on disk.
      
      Also fixes bug 19251: use enhanced error pages for onion service errors.
      702e7e06
    • Pier Angelo Vendrame's avatar
      Bug 13252: Customize profile management on macOS · 2e2eee9e
      Pier Angelo Vendrame authored
      On macOS we allow both portable mode and system installation.
      However, in the latter case, we customize Firefox's directories to
      match the hierarchy we use for the portable mode.
      
      Also, display an informative error message if the TorBrowser-Data
      directory cannot be created due to an "access denied" or a
      "read only volume" error.
      2e2eee9e
    • Pier Angelo Vendrame's avatar
      Bug 9173: Change the default Firefox profile directory to be relative. · 4f3f245e
      Pier Angelo Vendrame authored
      This commit makes Firefox look for the default profile directory in a
      directory relative to the binary path.
      The directory can be specified through the --with-relative-data-dir.
      This is relative to the same directory as the firefox main binary for
      Linux and Windows.
      
      On macOS, we remove Contents/MacOS from it.
      Or, in other words, the directory is relative to the application
      bundle.
      
      This behavior can be overriden at runtime, by placing a file called
      system-install adjacent to the firefox main binary (also on macOS).
      4f3f245e
  2. Oct 23, 2023
  3. Nov 07, 2023
  4. Oct 28, 2023
  5. Sep 25, 2023
  6. Aug 03, 2023
  7. Jul 17, 2023
    • Mike Hommey's avatar
      Bug 1831467 - Avoid more UB from transmuting a ref to a ref with interior... · d4175c7e
      Mike Hommey authored
      Bug 1831467 - Avoid more UB from transmuting a ref to a ref with interior mutability. r=emilio, a=dsmith
      
      aka one specific change in LLVM 16 introducing UB in Rust, take 3? 4?
      
      This time, we have multiple types like:
        #[xpcom(implement(nsISomething))]
        struct Foo {
            foo: RefCell<Something>,
        }
      
        impl Foo {
            fn from_interface(obj: &nsISomething) -> &Self {
                unsafe { ::std::mem::transmute(obj) }
            }
        }
      
      At first glance, this looks innocuous. But the problem is that
      nsISomething, as far as LLVM is informed by Rust, is readonly,
      but Foo, via the RefCell, has interious mutability.
      
      LLVM ends up assuming that any mutability that happens to that returned
      &Foo can't happen, and removes it.
      
      This is yet another case where https://github.com/rust-lang/rust/issues/111229
      would save our feet from this footgun LLVM 16 added and that the rust
      compiler doesn't help us prevent the least.
      
      Differential Revision: https://phabricator.services.mozilla.com/D183569
      ***
      Bug 1831467 fix comment a=dsmith
      d4175c7e
  8. Jul 11, 2023
  9. Jun 20, 2023
  10. May 31, 2023
    • Emilio Cobos Álvarez's avatar
      Bug 1835119 - Remove nsCOMPtr_base. r=xpcom-reviewers,kmag · c2f5a4ac
      Emilio Cobos Álvarez authored
      It's not clear to me why specializing nsCOMPtr<nsISupports> is
      particularly useful, and this removes a lot of code, bringing us closer
      to unifying nsCOMPtr and RefPtr.
      
      The changes in other places are needed because we used to allow
      nsCOMPtr<nsISupports> to implicitly coerce to nsISupports even for
      rvalue references.
      
           0:47.88 /home/emilio/src/moz/gecko-4/netwerk/protocol/http/nsHttpActivityDistributor.cpp:121:11: error: conversion function from 'nsCOMPtr<nsISupports>' to 'nsISupports *' invokes a deleted function
           0:47.88           nsCOMPtr<nsISupports>(do_QueryObject(channel)), aActivityType,
           0:47.88           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
           0:47.88 /home/emilio/src/moz/gecko-4/obj-debug/dist/include/nsCOMPtr.h:764:3: note: 'operator nsISupports *' has been explicitly marked deleted here
           0:47.88   operator T*() const&& = delete;
           0:47.88   ^
           0:47.88 /home/emilio/src/moz/gecko-4/netwerk/protocol/http/nsHttpActivityDistributor.cpp:29:57: note: passing argument to parameter 'aHttpChannel' here
           0:47.88 nsHttpActivityDistributor::ObserveActivity(nsISupports* aHttpChannel,
           0:47.88                                                         ^
      
      Which is not allowed for a good reason, generally.
      
      Differential Revision: https://phabricator.services.mozilla.com/D179124
      c2f5a4ac
    • Emilio Cobos Álvarez's avatar
      Bug 1835119 - Remove NSCAP_FEATURE_USE_BASE. r=xpcom-reviewers,kmag · 373447e2
      Emilio Cobos Álvarez authored
      This is not needed since bug 1363754. I left this as a follow-up
      clean-up to mitigate a bit the risk of that change.
      
      Differential Revision: https://phabricator.services.mozilla.com/D179123
      373447e2
  11. May 30, 2023
  12. May 29, 2023
  13. May 26, 2023
    • Jan Horak's avatar
      Bug 1814897 Add org.mozilla.firefox.systemconfig extension to load system-wide settings; r=mkaply · f0d13e82
      Jan Horak authored
      The settings must be put into (path depends on architecture and branch):
      /var/lib/flatpak/extension/org.mozilla.firefox.systemconfig/x86_64/stable/defaults/pref
      
      Currently policies.json to be placed into:
      /var/lib/flatpak/extension/org.mozilla.firefox.systemconfig/x86_64/stable/policies/policies.json
      
      Differential Revision: https://phabricator.services.mozilla.com/D168803
      f0d13e82
    • Chris Peterson's avatar
      Bug 1791961 - xpcom: Fix C++20 -Wambiguous-reversed-operator warnings. r=emilio · c5f254d1
      Chris Peterson authored
      clang is warning that C++20 expects comparison operators to be commutative: `a == b` and `b == a` should resolve to the same comparison operator function. Warnings about the comparison of const and non-const objects can be fixed by making the comparison operator function const.
      
      xpcom/base/AvailableMemoryWatcherMac.cpp:404:14 [-Wambiguous-reversed-operator] ISO C++20 considers use of overloaded operator '==' (with operand types 'mozilla::MacMemoryPressureLevel' and 'mozilla::MacMemoryPressureLevel') to be ambiguous despite there being a unique best viable function
      xpcom/base/AvailableMemoryWatcherMac.cpp:568:24 [-Wambiguous-reversed-operator] ISO C++20 considers use of overloaded operator '==' (with operand types 'mozilla::MacMemoryPressureLevel' and 'mozilla::MacMemoryPressureLevel') to be ambiguous despite there being a unique best viable function
      
      Depends on D179024
      
      Differential Revision: https://phabricator.services.mozilla.com/D179025
      c5f254d1
  14. May 25, 2023
  15. May 24, 2023
  16. May 23, 2023
  17. May 22, 2023
Loading