NixOS must not allow an unattended or automatic login to the system via the console.

Severity
Group ID
Group Title
Version
Rule ID
Date
STIG Version
highV-268172SRG-OS-000480-GPOS-00229ANIX-00-001880SV-268172r1039586_rule2024-10-251
Description
Failure to restrict system access via the console to authenticated users negatively impacts operating system security.
ℹ️ Check
Verify NixOS does not allow an unattended or automatic login to the system via the console with the following command: $ grep -iR autologin.user /etc/nixos If "services.xserver.displayManager.autoLogin.user" is defined and is not "null", this is a finding.
✔️ Fix
Configure the operating system to not allow an unattended or automatic login to the system via the console. Note: Once set, the system must be rebooted for any changes to apply. Add or update the following configuration in /etc/nixos/configuration.nix: services.xserver.displayManager.autoLogin.user = null; Rebuild the NixOS configuration with the following command: $ sudo nixos-rebuild switch