# Ensure Audit Log Files Have Permissions Set to 0640 or More Restrictive

- Source: https://support.icompaas.com/support/solutions/articles/62000235498-ensure-audit-log-files-have-permissions-set-to-0640-or-more-restrictive
- Section: [Solutions](https://support.icompaas.com/support/solutions) › [CIS Amazon Linux 2 Benchmark v3.0.0](https://support.icompaas.com/support/solutions/62000112696) › [CIS Amazon Linux 2 Benchmarks](https://support.icompaas.com/support/solutions/folders/62000169265)
- Last updated: 2026-05-29
- Publisher: iCompaas, Inc. (https://www.icompaas.com)

Profile Applicability:  
Level 1

Description: Audit log files contain sensitive security and system activity information. Setting permissions to 0640 or more restrictive limits access to the file owner and group, preventing unauthorized users from reading or modifying audit logs.

Rationale: Restricting permissions on audit log files protects the confidentiality and integrity of audit data, reducing the risk of tampering or unauthorized disclosure.

**Impact:** **Pros:**

-   Protects audit logs from unauthorized access.  
    
-   Maintains reliability and confidentiality of security events.  
    

**Cons:**

-   Overly restrictive permissions might interfere with legitimate access by audit services.  
    

  

Default Value: Permissions on audit log files may vary; verification and adjustment may be necessary.

Pre-requisites:

-   Root or sudo privileges to audit and modify file permissions.  
    

Remediation:

### Test Plan:

Using Linux command line:

1.  Check permissions of audit log files:
    
    ls -l /var/log/audit/
    
2.  Identify files with permissions more permissive than 0640:
    
    find /var/log/audit/ -type f ! -perm -640
    
3.  Verify none or only necessary files have more permissive modes.  
    

### Implementation Plan:

Using Linux command line:

1.  Set permissions to 0640 or more restrictive:
    
    chmod 640 /var/log/audit/\*
    
2.  Apply recursively if needed:
    
    chmod -R 640 /var/log/audit/
    
3.  Verify changes:
    
    ls -l /var/log/audit/
    
      
    

### Backout Plan:

Using Linux command line:

1.  Restore previous permissions from backups if necessary.  
    
2.  Confirm audit services can read and write logs as needed.  
    

References:

-   CIS Amazon Linux 2 Benchmark v3.0.0  
    
-   [NIST SP 800-53 Revision 5 - AU-9  
      
    ](https://csrc.nist.gov/publications/detail/sp/800-53/rev-5/final#au-9)

## Related compliance guidance

- [SOC 2 compliance: a practical implementation guide for cloud-native SaaS teams](https://support.icompaas.com/compliance/soc-2-trust-services-criteria): Configuration checks like this one are the technical half of a SOC 2 / ISO 27001 programme — the guide shows where they fit, what else an auditor expects, and how to evidence them.
- [ISO/IEC 27001:2022 compliance: a practical implementation guide](https://support.icompaas.com/compliance/iso-27001-2022): ISO 27001 Annex A.8 (technological controls) is where cloud hardening evidence lands; the guide shows how to run the ISMS around it.
