nixos/update-users-groups: read access to /etc/shadow for group shadow

This commit is contained in:
Jaakko Luttinen
2021-03-18 00:08:35 -07:00
committed by Cole Helbling
parent 4307699fdb
commit 099a9e809c
+1 -1
View File
@@ -288,7 +288,7 @@ foreach my $u (values %usersOut) {
push @shadowNew, join(":", $u->{name}, $hashedPassword, "1::::::") . "\n";
}
updateFile("/etc/shadow", \@shadowNew, 0600);
updateFile("/etc/shadow", \@shadowNew, 0640);
{
my $uid = getpwnam "root";
my $gid = getgrnam "shadow";