nixpkgs/pkgs/applications
aszlig 9744ff74ad
firefox: Improve detecting signing requirements
Firefox 61 started to enforce signatures for add-ons and since
commit d031843a1e, we get an evaluation
error that recommends the user to switch to Firefox ESR.

This isn't an option for everyone and as I also pointed out in the pull
request[1] introducing the above commit, I've been building Firefox like
this:

  let
    firefoxNoSigning = firefox-unwrapped.overrideAttrs (lib.const {
      MOZ_REQUIRE_SIGNING = false;
    });
  in wrapFirefox firefoxNoSigning {
    nixExtensions = ...;
  }

However, this only works after manually modifying nixpkgs (or copy &
paste wrapper.nix elsewhere) every time I want to have a new Firefox
version. Of course, this gets annoying and tedious after a while, so
this motivated me to properly fix this to not only check for an ESR
version but also check the value of MOZ_REQUIRE_SIGNING.

Note that I'm using toString here to check for the value because there
are several ways (false, null, "", ...) to set the environment variable
to an empty string and toString makes sure that it really is the desired
behaviour. I specifically checked the Firefox source and also tested
this with multiple values and only building with MOZ_REQUIRE_SIGNING
set to an empty string seems to work (no "0", "false" or other
variants).

Additionally, there is another method to allow unsigned add-ons, which
is by using the --with-unsigned-addon-scopes configure option[2].
Unfortunately, this does not work with nixExtensions because we don't
have (or want) a central directory where those add-ons reside.

Given that nixExtensions disallows manually installing add-ons, setting
MOZ_REQUIRE_SIGNING to false should be safe in this case.

[1]: https://github.com/NixOS/nixpkgs/pull/133504
[2]: https://bugs.archlinux.org/task/63075

Signed-off-by: aszlig <aszlig@nix.build>
2022-06-21 11:54:08 +02:00
..
accessibility
audio Merge master into staging-next 2022-06-19 00:02:36 +00:00
backup vorta: 0.8.6 -> 0.8.7 (#177986) 2022-06-18 10:41:27 -05:00
blockchains wasabibackend: update dependencies 2022-06-20 20:53:02 +02:00
display-managers
editors cudatext: 1.165.2 → 1.166.2 2022-06-20 19:21:35 +02:00
emulators ryujinx: update dependencies 2022-06-17 10:12:43 +02:00
finance odoo: use python39 2022-06-06 11:46:39 -07:00
gis whitebox-tools: use SRI hash format 2022-06-09 23:16:59 -03:00
graphics imagemagick: 7.1.0-37 -> 7.1.0-39 2022-06-20 19:30:57 +00:00
kde kde/gear: 22.04.1 -> 22.04.2 2022-06-15 14:52:59 +08:00
logging
maui
misc Merge pull request #177991 from mdarocha/dotnet-6-update 2022-06-20 19:56:52 +02:00
networking firefox: Improve detecting signing requirements 2022-06-21 11:54:08 +02:00
office gnucash: Add me as maintainer 2022-06-20 18:55:26 +02:00
plasma-mobile
printing/pappl
qubes/qubes-core-vchan-xen
radio
science Merge pull request #177991 from mdarocha/dotnet-6-update 2022-06-20 19:56:52 +02:00
search
system Merge pull request #177877 from NixOS/monitor 2022-06-17 12:58:46 +08:00
terminal-emulators kitty: 0.25.1 -> 0.25.2 2022-06-13 18:32:04 -07:00
version-management lefthook: 0.8.0 -> 1.0.0 2022-06-19 09:50:42 -07:00
video Merge pull request #177913 from Yarny0/clickshare 2022-06-20 15:55:24 +02:00
virtualization lima: 0.11.0 -> 0.11.1 2022-06-20 08:22:02 +10:00
window-managers treewide: reduce maintenance workload for ma27 2022-06-19 12:07:43 +02:00