nixos/cryptpad: fix service with nodejs 22.11 (for real) #372342
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The previous fix had only been tested locally through a runtime edit of the service, and the order in which @chown had been re-added was different so commit cf498c1 ("nixos/cryptpad: fix service with nodejs 22.11") did not actually fix the issue.
This properly orders @chown after @PRIVILEGED so the rule is respected, and also properly denies with EPERM instead of allowing the chown family of syscalls: this will properly prevent seccomp from killing nodejs while still disallowing fchown()
Fixes #370717
Things done
I properly ran the nixosTests.cryptpad this time, but let's wait for ofborg to run it as well just to make sure...
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.