NixOS system configuration files and directories must be owned by root.
Severity | Group ID | Group Title | Version | Rule ID | Date | STIG Version |
---|---|---|---|---|---|---|
medium | V-268122 | SRG-OS-000063-GPOS-00032 | ANIX-00-000680 | SV-268122r1039254_rule | 2024-10-25 | 1 |
Description |
---|
Without the capability to restrict the roles and individuals that can select which events are audited, unauthorized personnel may be able to prevent the auditing of critical events. Misconfigured audits may degrade the system's performance by overwhelming the audit log. Misconfigured audits may also make it more difficult to establish, correlate, and investigate the events relating to an incident or identify those responsible for one. |
ℹ️ Check |
---|
Verify that the NixOS system configuration files and directories are owned by root with the following command: $ sudo find /etc/nixos -exec stat -c "%U %n" {} \; root /etc/nixos root /etc/nixos/configuration.nix root /etc/nixos/hardware-configuration.nix If the system configuration files and directories are not owned by root, this is a finding. |
✔️ Fix |
---|
Configure the NixOS system configuration files and directories to be owned by root by using the following command: $ sudo find /etc/nixos -exec chown -R root {} \; Rebuild the NixOS configuration with the following command: $ sudo nixos-rebuild switch |