Check: ANIX-00-000600
Anduril NixOS STIG:
ANIX-00-000600
(in version v1 r2)
Title
NixOS systemd-journald logs must have a mode of 0640 or less permissive. (Cat II impact)
Discussion
Only authorized personnel should be aware of errors and the details of the errors. Error messages are an indicator of an organization's operational state or can identify the NixOS system or platform. Additionally, Personally Identifiable Information (PII) and operational information must not be revealed through error messages to unauthorized personnel or their designated representatives. The structure and content of error messages must be carefully considered by the organization and development team. The extent to which the information system is able to identify and handle error conditions is guided by organizational policy and operational requirements. Satisfies: SRG-OS-000057-GPOS-00027, SRG-OS-000205-GPOS-00083
Check Content
Verify NixOS protects log information from unauthorized read access by implementing a mode of 0640 or less on the creation of log files with the following command: $ sudo find /var/log/journal -type f -perm -640 -not -perm 640 -printf "%p %m\n" If any log files have a permission of greater than 0640, this is a finding.
Fix Text
The systemd-journald files are by design set to 0640 mode. If any files are found with incorrect perms, correct them with the following command: $ sudo find /var/log/journal -type f -exec chmod 0640 {} \;
Additional Identifiers
Rule ID: SV-268118r1131037_rule
Vulnerability ID: V-268118
Group Title: SRG-OS-000057-GPOS-00027
Expert Comments
CCIs
| Number | Definition |
|---|---|
| CCI-000162 |
Protect audit information from unauthorized access. |
| CCI-001312 |
Generate error messages that provide information necessary for corrective actions without revealing information that could be exploited. |