about summary refs log tree commit diff
path: root/modules
diff options
context:
space:
mode:
authoraszlig <aszlig@redmoonstudios.org>2017-08-19 12:44:24 +0200
committeraszlig <aszlig@redmoonstudios.org>2017-08-19 12:44:24 +0200
commit5c656079953d39560b678cac747b267f0aba2139 (patch)
tree6430b7f4f48d1648b81de007c6b38051c7bce5aa /modules
parent3a0f741b9bfcd436bd4157162cd5e48cd3101f79 (diff)
core/tests: Fix eval error for nixos.hardened
The configuration option boot.kernel.sysctl is of type attrsOf, so we
can't assume that the attribute "user.max_user_namespaces" is actually
there.

Signed-off-by: aszlig <aszlig@redmoonstudios.org>
Diffstat (limited to 'modules')
-rw-r--r--modules/core/tests.nix2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/core/tests.nix b/modules/core/tests.nix
index 0f93a145..2681ceff 100644
--- a/modules/core/tests.nix
+++ b/modules/core/tests.nix
@@ -117,7 +117,7 @@ let
     }
     { check = config.security.lockKernelModules
            || config.security.hideProcessInformation
-           || config.boot.kernel.sysctl."user.max_user_namespaces" == 0;
+           || config.boot.kernel.sysctl."user.max_user_namespaces" or 1 == 0;
       path  = ["nixos" "hardened"];
     }
     { check = true;