From 751c2ed6e4af9e525fe57b7c0f0ee8a611eab9fa Mon Sep 17 00:00:00 2001 From: rnhmjoj Date: Sun, 21 Jun 2020 17:01:34 +0200 Subject: [PATCH] nixos/users-groups: do not check validity of empty hashes --- nixos/modules/config/users-groups.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nixos/modules/config/users-groups.nix b/nixos/modules/config/users-groups.nix index c2b8b6b3163..e06514bd934 100644 --- a/nixos/modules/config/users-groups.nix +++ b/nixos/modules/config/users-groups.nix @@ -629,7 +629,8 @@ in { content = "${base64}${sep}${base64}"; mcf = "^${sep}${scheme}${sep}${content}$"; in - if (user.hashedPassword != null + if (user.hashedPassword != null # login disabled + && user.hashedPassword != "" # login without password && builtins.match mcf user.hashedPassword == null) then ''