Don't set an initial null root password for Amazon / VirtualBox images

A null password allows logging into local PAM services such as "login"
(agetty) and KDM.  That's not actually a security problem for EC2
machines, since they do not have "local" logins; for VirtualBox
machines, if you local access, you can do anything anyway.  But it's
better to be on the safe side and disable password-based logins for
root.
This commit is contained in:
Eelco Dolstra
2013-11-01 15:04:21 +01:00
parent 8352df8d66
commit 4ba7dfde5b
3 changed files with 25 additions and 1 deletions
@@ -107,4 +107,9 @@ with pkgs.lib;
boot.loader.grub.device = "/dev/sda";
services.virtualbox.enable = true;
# Prevent logging in as root without a password. For NixOps, we
# don't need this because the user can login via SSH, and for the
# demo images, there is a demo user account that can sudo to root.
security.initialRootPassword = "!";
}