about summary refs log tree commit diff
path: root/nixos/modules/security
diff options
context:
space:
mode:
authorEelco Dolstra <eelco.dolstra@logicblox.com>2013-10-30 17:37:45 +0100
committerEelco Dolstra <eelco.dolstra@logicblox.com>2013-10-30 18:47:43 +0100
commit408b8b5725c3e6fff75aef772da248d3e95ff414 (patch)
tree692e3b61dbbff85cc97e3becf13a1376dea04a92 /nixos/modules/security
parentd882e1966251880240599d3c1b31e060661506ee (diff)
downloadnixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.tar
nixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.gz
nixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.bz2
nixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.lz
nixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.xz
nixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.tar.zst
nixlib-408b8b5725c3e6fff75aef772da248d3e95ff414.zip
Add lots of missing option types
Diffstat (limited to 'nixos/modules/security')
-rw-r--r--nixos/modules/security/pam.nix2
-rw-r--r--nixos/modules/security/pam_usb.nix1
-rw-r--r--nixos/modules/security/polkit.nix3
-rw-r--r--nixos/modules/security/rngd.nix1
-rw-r--r--nixos/modules/security/rtkit.nix1
-rw-r--r--nixos/modules/security/setuid-wrappers.nix5
-rw-r--r--nixos/modules/security/sudo.nix3
7 files changed, 15 insertions, 1 deletions
diff --git a/nixos/modules/security/pam.nix b/nixos/modules/security/pam.nix
index 69a1972e9e75..93d12d292e4d 100644
--- a/nixos/modules/security/pam.nix
+++ b/nixos/modules/security/pam.nix
@@ -133,7 +133,7 @@ let
       };
 
       text = mkOption {
-        type = types.nullOr types.string;
+        type = types.nullOr types.lines;
         description = "Contents of the PAM service file.";
       };
 
diff --git a/nixos/modules/security/pam_usb.nix b/nixos/modules/security/pam_usb.nix
index 2bd3069ddb12..4cc99995fbca 100644
--- a/nixos/modules/security/pam_usb.nix
+++ b/nixos/modules/security/pam_usb.nix
@@ -17,6 +17,7 @@ in
 
     security.pam.usb = {
       enable = mkOption {
+        type = types.bool;
         default = false;
         description = ''
           Enable USB login for all login systems that support it.  For
diff --git a/nixos/modules/security/polkit.nix b/nixos/modules/security/polkit.nix
index 8b04f4043bc7..cafa9f82d5e4 100644
--- a/nixos/modules/security/polkit.nix
+++ b/nixos/modules/security/polkit.nix
@@ -13,11 +13,13 @@ in
   options = {
 
     security.polkit.enable = mkOption {
+      type = types.bool;
       default = true;
       description = "Whether to enable PolKit.";
     };
 
     security.polkit.permissions = mkOption {
+      type = types.lines;
       default = "";
       example =
         ''
@@ -49,6 +51,7 @@ in
     };
 
     security.polkit.adminIdentities = mkOption {
+      type = types.str;
       default = "unix-user:0;unix-group:wheel";
       example = "";
       description =
diff --git a/nixos/modules/security/rngd.nix b/nixos/modules/security/rngd.nix
index dd251fe69d31..720ac02f2e81 100644
--- a/nixos/modules/security/rngd.nix
+++ b/nixos/modules/security/rngd.nix
@@ -5,6 +5,7 @@ with pkgs.lib;
 {
   options = {
     security.rngd.enable = mkOption {
+      type = types.bool;
       default = true;
       description = ''
         Whether to enable the rng daemon, which adds entropy from
diff --git a/nixos/modules/security/rtkit.nix b/nixos/modules/security/rtkit.nix
index e47e7baa2b84..164ad9b3aa7d 100644
--- a/nixos/modules/security/rtkit.nix
+++ b/nixos/modules/security/rtkit.nix
@@ -10,6 +10,7 @@ with pkgs.lib;
   options = {
 
     security.rtkit.enable = mkOption {
+      type = types.bool;
       default = false;
       description = ''
         Whether to enable the RealtimeKit system service, which hands
diff --git a/nixos/modules/security/setuid-wrappers.nix b/nixos/modules/security/setuid-wrappers.nix
index e75679e5ff69..62df85816e50 100644
--- a/nixos/modules/security/setuid-wrappers.nix
+++ b/nixos/modules/security/setuid-wrappers.nix
@@ -25,7 +25,9 @@ in
   options = {
 
     security.setuidPrograms = mkOption {
+      type = types.listOf types.str;
       default = [];
+      example = ["passwd"];
       description = ''
         The Nix store cannot contain setuid/setgid programs directly.
         For this reason, NixOS can automatically generate wrapper
@@ -36,6 +38,7 @@ in
     };
 
     security.setuidOwners = mkOption {
+      type = types.listOf types.attrs;
       default = [];
       example =
         [ { program = "sendmail";
@@ -53,6 +56,8 @@ in
     };
 
     security.wrapperDir = mkOption {
+      internal = true;
+      type = types.path;
       default = "/var/setuid-wrappers";
       description = ''
         This option defines the path to the setuid wrappers.  It
diff --git a/nixos/modules/security/sudo.nix b/nixos/modules/security/sudo.nix
index 772517801981..215a8ecd6018 100644
--- a/nixos/modules/security/sudo.nix
+++ b/nixos/modules/security/sudo.nix
@@ -17,6 +17,7 @@ in
   options = {
 
     security.sudo.enable = mkOption {
+      type = types.bool;
       default = true;
       description =
         ''
@@ -26,6 +27,7 @@ in
     };
 
     security.sudo.wheelNeedsPassword = mkOption {
+      type = types.bool;
       default = true;
       description =
         ''
@@ -35,6 +37,7 @@ in
       };
 
     security.sudo.configFile = mkOption {
+      type = types.lines;
       # Note: if syntax errors are detected in this file, the NixOS
       # configuration will fail to build.
       description =