Commit 4ca106a6 authored by Nicolas Benes's avatar Nicolas Benes
Browse files

tor-browser-bundle-bin: 11.5.8 -> 12.0.3

parent 35b188cf
Loading
Loading
Loading
Loading
+11 −10
Original line number Diff line number Diff line
@@ -26,6 +26,7 @@
, pulseaudioSupport ? mediaSupport
, libpulseaudio
, apulse
, alsa-lib

# Media support (implies audio support)
, mediaSupport ? true
@@ -57,6 +58,7 @@ let
  libPath = lib.makeLibraryPath libPkgs;

  libPkgs = [
    alsa-lib
    atk
    cairo
    dbus
@@ -85,9 +87,9 @@ let
  fteLibPath = lib.makeLibraryPath [ stdenv.cc.cc gmp ];

  # Upstream source
  version = "11.5.8";
  version = "12.0.3";

  lang = "en-US";
  lang = "ALL";

  srcs = {
    x86_64-linux = fetchurl {
@@ -97,7 +99,7 @@ let
        "https://tor.eff.org/dist/torbrowser/${version}/tor-browser-linux64-${version}_${lang}.tar.xz"
        "https://tor.calyxinstitute.org/dist/torbrowser/${version}/tor-browser-linux64-${version}_${lang}.tar.xz"
      ];
      sha256 = "sha256-/KK9oTijk5dEziAwp5966NaM2V4k1mtBjTJq88Ct7N0=";
      hash = "sha256-bOGY/RdwD6O7QIuOiBw7OVnZfpumGGso6hwMJJwN2g0=";
    };

    i686-linux = fetchurl {
@@ -107,7 +109,7 @@ let
        "https://tor.eff.org/dist/torbrowser/${version}/tor-browser-linux32-${version}_${lang}.tar.xz"
        "https://tor.calyxinstitute.org/dist/torbrowser/${version}/tor-browser-linux32-${version}_${lang}.tar.xz"
      ];
      sha256 = "sha256-TGdJ5yIeo0YQ4XSsb9lv3vuW6qEjhFe7KBmkjYO6fAc=";
      hash = "sha256-t1tnEZtiRig2r8GNJpqT+J0XoxCLMyUsI9tX6aa0lYk=";
    };
  };
in
@@ -291,13 +293,9 @@ stdenv.mkDerivation rec {
    # TBB will fail if ownership is too permissive
    chmod 0700 "\$HOME/TorBrowser/Data/Tor"

    # Initialize the browser profile state.  Note that the only data
    # copied from the Store payload is the initial bookmark file, which is
    # never updated once created.  All other files under user's profile
    # dir are generated by TBB.
    # Initialize the browser profile state.
    # All files under user's profile dir are generated by TBB.
    mkdir -p "\$HOME/TorBrowser/Data/Browser/profile.default"
    cp -u --no-preserve=mode,owner "$TBB_IN_STORE/TorBrowser/Data/Browser/profile.default/bookmarks.html" \
      "\$HOME/TorBrowser/Data/Browser/profile.default/bookmarks.html"

    # Clear some files if the last known store path is different from the new one
    : "\''${KNOWN_STORE_PATH:=\$HOME/known-store-path}"
@@ -325,6 +323,9 @@ stdenv.mkDerivation rec {
    # chance that TBB would continue using old font files.
    rm -rf "\$HOME/.cache/fontconfig"

    # Workaround a bug in 12.0.X that Tor directories are not cleaned up and tor gets confused where its socket is
    rm -rf \$XDG_RUNTIME_DIR/Tor*

    # Manually specify data paths (by default TB attempts to create these in the store)
    {
      echo "user_pref(\"extensions.torlauncher.toronionauthdir_path\", \"\$HOME/TorBrowser/Data/Tor/onion-auth\");"