1
0
Fork 1
mirror of https://github.com/NixOS/nixpkgs.git synced 2024-11-25 23:20:55 +00:00
nixpkgs/nixos/modules/security
ivanbrennan d08967a3a8
nixos/security.sudo: describe extraRules order
The order of sudoers entries is significant. The man page for sudoers(5)
notes:

  Where there are multiple matches, the last match is used (which is not
  necessarily the most specific match).

This module adds a rule for group "wheel" matching all commands. If you
wanted to add a more specific rule allowing members of the "wheel" group
to run command `foo` without a password, you'd need to use mkAfter to
ensure your rule comes after the more general rule.

  extraRules = lib.mkAfter [
    {
      groups = [ "wheel" ];
      commands = [
        {
          command = "${pkgs.foo}/bin/foo";
          options = [ "NOPASSWD" "SETENV" ];
        }
      ]
    }
  ];

Otherwise, when configuration options are merged, if the general rule
ends up after the specific rule, it will dictate the behavior even when
running the `foo` command.
2018-07-01 15:50:51 -04:00
..
wrappers wrapper.c: fixup includes to work w/musl 2018-03-25 18:06:02 -05:00
acme.nix acme service: generate a CA for self-signed certificate 2018-04-17 12:53:29 +03:00
acme.xml nixos/acme: remove doc note about restarting nginx 2017-10-30 13:51:35 -04:00
apparmor-suid.nix Getting rid of the var indirection and using a bin path instead 2017-01-29 04:11:01 -06:00
apparmor.nix apparmor: support for lxc profiles 2017-01-10 23:01:03 +01:00
audit.nix nixos: Move uses of stdenv.shell to runtimeShell. 2018-03-01 14:38:53 -05:00
auditd.nix nixos/auditd: break ordering cycle (#27577) 2017-08-01 20:45:01 +01:00
ca.nix cacerts: refactor, add blacklist option 2016-10-09 02:00:18 +02:00
chromium-suid-sandbox.nix nixos/chromium-suid-sandbox: remove reference to grsecurity 2017-09-02 20:35:28 +02:00
dhparams.nix dhparams module: condition on enable option (#23661) 2017-03-17 01:56:13 +01:00
duosec.nix duosec: use root uid as sshd uid has been retired (#33597) 2018-03-21 18:46:35 -05:00
hidepid.nix hidepid: polkit and systemd-logind compatibility 2016-12-07 01:12:05 +01:00
hidepid.xml hidepid module: detailed description to external doc 2016-09-15 15:36:03 +02:00
lock-kernel-modules.nix nixos/lock-kernel-modules: fix deferred fileSystem mounts 2017-09-22 23:55:04 +02:00
oath.nix config.security.oath: new module 2016-02-25 13:52:45 +00:00
pam.nix Merge pull request #31969 from Assassinkin/master 2018-04-21 14:36:47 -05:00
pam_mount.nix pam_mount module: integrate pam_mount into PAM of NixOS 2015-07-04 23:42:31 +02:00
pam_usb.nix security.pam.usb: link to wiki on github.com 2017-09-28 16:00:28 +02:00
polkit.nix network-link-*.service: Set stopIfChanged = false 2017-04-04 15:13:49 +02:00
prey.nix nixos: fix some types 2015-09-18 18:48:50 +00:00
rngd.nix rngd: update modalias to match cpu type 2016-09-17 18:36:57 -07:00
rtkit.nix rtkit: Update from 0.10 to 0.11 2014-04-21 23:22:10 +02:00
sudo.nix nixos/security.sudo: describe extraRules order 2018-07-01 15:50:51 -04:00