physlock: fix issue 21935

Changed files
+2 -12
nixos
modules
services
security
+2 -12
nixos/modules/services/security/physlock.nix
···
This will switch to a new virtual terminal, turn off console
switching and disable SysRq mechanism (when
<option>services.physlock.disableSysRq</option> is set)
-
until the root or <option>services.physlock.user</option>
-
password is given.
-
'';
-
};
-
-
user = mkOption {
-
type = types.nullOr types.str;
-
default = null;
-
description = ''
-
User whose password will be used to unlock the screen on par
-
with the root password.
'';
};
···
++ cfg.lockOn.extraTargets;
serviceConfig.Type = "forking";
script = ''
-
${pkgs.physlock}/bin/physlock -d${optionalString cfg.disableSysRq "s"}${optionalString (cfg.user != null) " -u ${cfg.user}"}
'';
};
···
This will switch to a new virtual terminal, turn off console
switching and disable SysRq mechanism (when
<option>services.physlock.disableSysRq</option> is set)
+
until the root or user password is given.
'';
};
···
++ cfg.lockOn.extraTargets;
serviceConfig.Type = "forking";
script = ''
+
${pkgs.physlock}/bin/physlock -d${optionalString cfg.disableSysRq "s"}
'';
};