about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBenno Fünfstück <benno.fuenfstueck@gmail.com>2016-08-19 14:47:11 +0200
committerBenno Fünfstück <benno.fuenfstueck@gmail.com>2016-08-19 14:59:33 +0200
commit51b165c7d20d53b4581622a934a9e0abd7e43800 (patch)
tree1f388636f16d15a0b9263318a461d9e31235cd28
parent80dbdba6dda9b7adc49027de09f6db0ab2e7503c (diff)
downloadnixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.tar
nixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.tar.gz
nixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.tar.bz2
nixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.tar.lz
nixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.tar.xz
nixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.tar.zst
nixlib-51b165c7d20d53b4581622a934a9e0abd7e43800.zip
nixos/shadow: setuid wrappers for new{uid,gid}map
These utils are not related to user management, so they should be
available even if immutable users are enabled.
-rw-r--r--nixos/modules/programs/shadow.nix5
1 files changed, 2 insertions, 3 deletions
diff --git a/nixos/modules/programs/shadow.nix b/nixos/modules/programs/shadow.nix
index 6398509357a6..878c9cc0cf09 100644
--- a/nixos/modules/programs/shadow.nix
+++ b/nixos/modules/programs/shadow.nix
@@ -103,10 +103,9 @@ in
       };
 
     security.setuidPrograms = [ "su" "chfn" ]
+      ++ [ "newuidmap" "newgidmap" ] # new in shadow 4.2.x
       ++ lib.optionals config.users.mutableUsers
-      [ "passwd" "sg" "newgrp"
-        "newuidmap" "newgidmap" # new in shadow 4.2.x
-      ];
+      [ "passwd" "sg" "newgrp" ];
 
   };