Other Articles

Servers – Ensure Default Group for Root Account is GID 0

Support > Fixing Checks > Server

06 March, 2026

This check ensures that the default group for the root account is set to GID 0.

The group ID (GID) determines the default group ownership of files created by the root user. Ensuring it is set to 0 helps maintain strict access control and prevents unauthorized access to sensitive files.

Check Details

  • Resource: Server
  • Check: Ensure default group for the root account is GID 0
  • Risk: Incorrect group assignment may allow non-privileged users to access root-owned files, leading to security vulnerabilities.

Remediation Steps

  1. Open a terminal session on the server with root or sudo privileges.
  2. Check the current group ID (GID) of the root user using the following command:

    grep "^root:" /etc/passwd | cut -f4 -d:
    
  3. Verify that the output is:

    0
    
  4. If the value is not 0, update the root user's default group using the following command:

    sudo usermod -g 0 root
    
  5. Verify the change by re-running the audit command.
  6. Ensure regular audits are performed to maintain compliance with security policies.