Correct username prefix check
Co-authored-by: ragusa-it <196988693+ragusa-it@users.noreply.github.com>
This commit is contained in:
@@ -43,7 +43,7 @@
|
||||
usernameValid =
|
||||
builtins.match "^[a-z_][a-z0-9_]*$" username != null
|
||||
&& builtins.match "^_+$" username == null
|
||||
&& builtins.match "^nix" username == null
|
||||
&& builtins.match "^nix.*" username == null
|
||||
&& username != "root";
|
||||
hostConfig = (./hosts + "/${hostname}") + "/hardware-configuration.nix";
|
||||
passwordHashPath = "/etc/nixos/secrets/${username}/password.hash";
|
||||
|
||||
Reference in New Issue
Block a user