"Best Practice" Standard for IBM AIX

Purpose

This document describes minimum recommended configuration settings for IBM AIX to reduce risk of inadvertent or unauthorized access and configuration modification. Get the latest copy from the Best Practice Standards homepage.

Table of Contents

Scope
  Processes and procedures outside of the document scope
  Exceptions
  Control Objectives
Standard Details
 Software Version and Patches
    1  The latest Network Operating System (NOS) is installed.
    2  Latest patches and hot fixes are installed.
 Account Management
    3  Only root has user ID equal to 0.
    4  Remote access to root is restricted
    5  Only an authorized group has root switch (SU) privileges.
    6  Only authorized individuals are members of the group "security".
    7  User account settings shall comply with the "best practice" account management policy.
    8  All user and system accounts have meaningful description.
    9  No account management integrity warnings.
 Access Management
    10  Ownership and access permissions on critical security file is suitable for the specific OS.
    11  No trusted hosts should be enabled on a system through /etc/hosts.equiv.
    12  No files hosts.equiv on a system.
    13  No trusted hosts should be enabled on a system through .rhosts.
    14  No trusted hosts should be enabled on a system through .netrc.
    15  Only authorized network services are running.
    16  No network services to run UDP DoS attack.
    17  No files without owner or group.
    18  No world-writable files.
 Auditing/Logging
    19  Syslog logging is enabled.

Scope of the Standard

  1. This standard applies to all IBM AIX systems within the Organization.
  2. This standard applies to all employees, contractors, consultants, temporaries, and other employees at the Organization.
  3. This standard applies to all Organization locations, divisions, subsidiaries and affiliates.

Processes and procedures outside of the document scope

The following processes and procedures are outside of the current document scope:

Exceptions

Any exceptions to this standard must be approved by the IT Manager and documented.

Control Objectives

  1. Controls provide reasonable assurance that logical access to the system is only granted to properly authorized individuals.
  2. Controls provide reasonable assurance that logical access controls prevent inadvertent or unauthorized use of the system .
  3. Controls provide reasonable assurance that logical access to systems is monitored and misbehavior activity will be detected and reported.

Standard Details

Software Version and Patches

Test # 1 : The latest Network Operating System (NOS) is installed. (updated on 20060516)
Background/DescriptionThe latest NOS from the vendor contains necessary feature improvements and security fixes. However, keeping the production servers up-to-date with NOS without proper testing may affect application and service availability. Also, additional cost may be involved to purchase new license. Thus, it requires additional intensive testing and owner's approval. The production version may be not the latest one but should be reasonably recent.
Expected resultSince August 2004 IBM released AIX 5L 5.3 (version checked on Feb 2006).
Related RiskLow
ImpactOutdated NOS may have "well-known" vulnerabilities or security feature limitations. Often vendor discontinues supporting an outdated NOS. However, keeping the production servers up-to-date with NOS without proper testing may affect application and service availability. Also, additional cost may be involved to purchase a new license. Thus, it requires additional intensive testing and owner's approval. The production version may be not the latest one but should be reasonably recent.
RecommendationsConsider NOS upgrade.
Manual AssessmentUse command: uname -v.
Read moreIBM AIX, Wikipedia
 

Test # 2 : Latest patches and hot fixes are installed. (updated on 20060516)
Background/DescriptionIBM provides maintenance packages every four to six month with problem specific fixes and critical fixes. Thus, applying of such updates will increase system availability and protection. However, these updates should be intensively tested first for compatibility with installed applications and current system configuration as well as approved by the system owner. Thus, the installed patches and hot-fixes may be not the latest ones but reasonably recent. Warning: some patches re-enable default configuration. So, perform security hardening verification and hardening after patch installation.
Expected resultCheck the IBM web site for the latest AIX Maintenance Level (ML) (updates are too frequent for automated verification).
Test requires manual verificationVerify the latest maintenance level from the IBM web site
Related RiskMedium
ImpactOutdated NOS may have "well-known" vulnerabilities or security feature limitations. Often vendor discontinues supporting an outdated NOS. However, keeping the production servers up-to-date with NOS without proper testing may affect application and service availability. Also, additional cost may be involved to purchase a new license. Thus, it requires additional intensive testing and owner's approval. The production version may be not the latest one but should be reasonably recent.
RecommendationsReview and install the latest patches and fixes recommended by the vendor.
Manual AssessmentTo determine the maintenance level use command: oslevel -r.
Read more "Service Update Management Assistant (SUMA) on AIX 5L"
 

Account Management

Test # 3 : Only root has user ID equal to 0. (updated on 20070816)
Background/DescriptionUser ID equal to 0 gives unlimited access to all system resources. Usually, root is the most protected account with highest administrative privileges. But these privileges are granted by UID=0. So, if other account, with less protection, has the same level of privileges, an attacker may use this account to obtain highest administrative privileges to the system. If root-equivalent account is required, it should be approved by management and documented.
Expected resultOnly root has UID=0.
Related RiskMedium
ImpactAccounts with UID=0 may be used by an attacker to obtain administrative privilege access to the system.
RecommendationsReview and remove unnecessary privileges.
Manual AssessmentCheck /etc/passwd for other accounts with UID=0 (third field in the file /etc/passwd).
Or use command: $awk -F: '$3==0 {print $1}' /etc/passwd
 

Test # 4 : Remote access to root is restricted (updated on 20070816)
Background/DescriptionUsually, only root has highest administrative privileges on the system. Remote access to the root account should be restricted to prevent remote password guessing attacks and track who used the account. So, the root account should be available only from a console, or other user could switch to it using the "su" command.
Warning: Tested configuration affects only commands telnet and rlogin. Restricting remote root access over other protocols such as SSH could be different.
Expected resultRemote access to root is restricted (rlogin=false).
Related RiskMedium
Impact1. Remote password guessing attack could be initiated against the root account.
2. There will be no accountability for authorized administrators on who used the root account.
RecommendationsRestrict access to root to a console only and "su" command.
Manual AssessmentIn the file /etc/security/user for root's stanza should contain attribute "rlogin=false".
Read more Disabling direct root login
 

Test # 5 : Only an authorized group has root switch (SU) privileges. (updated on 20070823)
Background/DescriptionFor IBM AIX you can specify special list of groups which are allowed switch to root using "su" command. Only system administrators should be members of such groups. Possible values: a list of valid groups separated by commas, ALL, or *.
Expected resultOnly one group is authorized switch ("su") to root. Members of this group are authorized system administrators.
Test requires manual verificationVerify that only authorized system administrators are members of this group(s).
Related RiskMedium
ImpactWithout proper restriction any local AIX account may switch ("su") to root. Or local password guessing attack could be initiated against the root account.
RecommendationsRestrict "su" rights only to a special group. Only authorized system administrators should be members of this group.
Manual AssessmentIn the file /etc/security/user root's stanza should have an attribute "sugroups=group_name".
 

Test # 6 : Only authorized individuals are members of the group "security". (updated on 20060517)
Background/DescriptionGroup "security" has special advanced account management privileges. Members of this group should be only authorized individual with related job requirements.
Expected resultAll members of the group are authorized and have relevant job requirements.
Test requires manual verificationVerify that only authorized individuals are members of group 'security'
Related RiskMedium
ImpactUnauthorized person obtains excessive account administration rights through group membership. These rights could be abused.
RecommendationsOnly authorized individuals should be member of group 'security'.
Manual AssessmentCheck group members in the file /etc/group.
 

Test # 7 : User account settings shall comply with the "best practice" account management policy. (updated on 20061013)
Background/DescriptionIBM AIX allows to set specific user account settings such as password length to each account. Forcing users to change passwords frequently (quarterly, monthly or even more often) ensures that a valid password in the wrong hands will eventually become unusable.
Expected result"Best practice" account settings are:
Minimum password length (characters) - minlen = 6
Password must meet complexity requirements - minalpha = 1, minother = 1
Maximum password age (weeks) - maxage = 6
Minimum password age (weeks) - minage = 1
The number of invalid login attempts before a user is not allowed to login - loginretries = 5
Number of previous passwords which cannot be reused - histsize = 5
Default file permission - umask = 027
Test requires manual verificationyes
Related RiskMedium
ImpactUnauthorized person could obtains access to the system using password setting weaknesses or a dictionary attack.
RecommendationsUpdate account settings for user account.
Manual AssessmentCheck account settings in the file /etc/security/user.
Read moreWikipedia - Password
 

Test # 8 : All user and system accounts have meaningful description. (updated on 20061013)
Background/DescriptionAll accounts should have meaningful description for better account management and housekeeping.
Expected resultAll enabled accounts have meaningful description for better account management and housekeeping.
Related RiskHousekeeping
ImpactAccount description improves account management and auditing.
RecommendationsUpdate description for identified accounts.
Manual AssessmentCheck account description in the file /etc/passwd.
 

Test # 9 : No account management integrity warnings. (updated on 20061103)
Background/DescriptionIBM AIX has build-in integrity checking programs such as usrck, pwdck, grpck and tcbck. On a well maintained system this programs should show no warnings.
Expected resultNo account integrity warnings.
Related RiskHousekeeping
ImpactThese warnings are a sign of account management inconsistency.
RecommendationsReview output of commands usrck, pwdck, grpck and tcbck and address these warnings.
Manual AssessmentReview output of commands usrck, pwdck, grpck and tcbck.
 

Access Management

Test # 10 : Ownership and access permissions on critical security file is suitable for the specific OS. (updated on 20061030)
Background/DescriptionCritical UNIX files should be protected from unauthorized access and modification. Correct permission or access rights (list, read, write, execute) should be granted to owner, group and special group "everyone". The special group "everyone" represents all valid accounts on the UNIX system.
Expected resultThe following settings are expected:
Related RiskMedium
ImpactImproper permission may give unauthorized access to critical security files.
RecommendationsVerify permission and set it up as per vendor recommendations and best security practices.
Manual AssessmentCheck file permission on specified files with command ls -al.
 

Test # 11 : No trusted hosts should be enabled on a system through /etc/hosts.equiv. (updated on 20061030)
Background/DescriptionThe file /etc/hosts.equiv can be used by the system administrator to indicate trusted hosts. Each trusted host is listed in the file, one host per line. If a user attempts to remotely log in (using rlogin) or execute a command (using rsh) from one of the systems listed in hosts.equiv, and that user has an account on the local system with the same login name, access is permitted without requiring a password.
When a new Unix system is installed, the default /etc/hosts.equiv file should be deleted unless it is actually required and approved by the IT Manager.
Residual risk will be reduced if the file is empty.
Expected resultThere is no file /etc/hosts.equiv on the system.
Related RiskLow
ImpactUnauthorized person could access the system from a trusted host. If a user attempts to remotely log in (using rlogin) or execute a command (using rsh) from one of the systems listed in hosts.equiv, and that user has an account on the local system with the same login name, access is permitted without requiring a password.
RecommendationsDelete the file /etc/hosts.equiv.
Manual AssessmentCheck the file /etc/hosts.equiv using command cat /etc/hosts.equiv.
 

Test # 12 : No files hosts.equiv on a system. (updated on 20061103)
Background/DescriptionSometimes files hosts.equiv are stored in different places on the system. These files do not create a direct risk of a trusted host access, but is not a good system housekeeping practice. It is recommended to remove such files.
Expected resultThere are no hosts.equiv files on the system.
Related RiskHousekeeping
ImpactUnauthorized person may see trusted host setting from such files and use this information for further attacks. Also, it is not a good system housekeeping practice to keep these files on a system.
RecommendationsDelete identified files hosts.equiv.
Manual AssessmentSearch for files hosts.equiv using command find / -name 'hosts.equiv' -exec ls -l {}.
 

Test # 13 : No trusted hosts should be enabled on a system through .rhosts. (updated on 20061030)
Background/DescriptionA user configurable file $HOME/.rhosts is similar to /etc/hosts.equiv and lists all of the hosts which are to be implicitly trusted by the local host. This file is located in the user`s home directory. This file is consulted by the r-commands (rlogin, rsh, rcp and rcmd). If a user attempts to remotely log in (using rlogin) or execute a command (using rsh) from one of the systems listed in .rhosts, and that user has an account on the local system with the same login name, access is permitted without requiring a password.
Expected resultThere are no .rhosts files on the system.
Related RiskLow
ImpactUnauthorized person could access the system from a trusted host. If a user attempts to remotely log in (using rlogin) or execute a command (using rsh) from one of the systems listed in .rhosts, and that user has an account on the local system with the same login name, access is permitted without requiring a password.
RecommendationsRemove files .rhosts.
Manual AssessmentFind .rhosts files using command find / -name '.rhosts' -print.
 

Test # 14 : No trusted hosts should be enabled on a system through .netrc. (updated on 20061106)
Background/DescriptionA user file $HOME/.netrc is similar to $HOME/.rhosts. It may be created by any user in his or her home directory. This file allows certain users to connect to your host with ftp or rexec without supplying a password.
Expected resultThere are no .netrc files on the system.
Related RiskLow
ImpactUnauthorized person could access the system from a trusted host. Users to connect to your host with ftp or rexec without supplying a password.
RecommendationsRemove files .netrc.
Manual AssessmentFind .netrc files using command find / -name '.netrc' -print.
 

Test # 15 : Only authorized network services are running. (updated on 20070911)
Background/DescriptionUnnecessary network services could be a remote entry point to an unauthorized person due to improper configuration or known vulnerabilities. Best industry practices recommend disabling all unnecessary services such as rusersd, rstatd, rwalld, shell, comsat, tftp, netstat, login, talk, finger, time, exec, uucp, sysstat, echo, name, discard, daytime, chargen, sprayd, and bootps.
Note: This test reviews enabled services only in /etc/inetd.conf. Other unnecessary services could be enabled using different options.
Expected resultOnly authorized network services are running.
Test requires manual verificationyes
Related RiskMedium
ImpactUnauthorized person could access the system via improper configured or vulnerable network services.
RecommendationsDisable all unnecessary network services.
Manual AssessmentCheck list of enabled network services in the file /etc/inetd.conf and verifying output of the command netstat -an.
 

Test # 16 : No network services to run UDP DoS attack. (updated on 20070911)
Background/DescriptionUDP echo and chargen network services could be misused to launch a well known "UDP Flood" Denial-of-Service (DoS) attack. To initiate the attack an attacker sends a spoofed package on the internal network to a broadcast address using echo or chargen ports or to two hosts looping these network services. See more details at CERT Advisory CA-1996-01 - "When a connection is established between two UDP services, each of which produces output, these two services can produce a very high number of packets that can lead to a denial of service on the machine(s) where the services are offered. Anyone with network connectivity can launch an attack; no account access is needed.
For example, by connecting a host's chargen service to the echo service on the same or another machine, all affected machines may be effectively taken out of service because of the excessively high number of packets produced. In addition, if two or more hosts are so connected, the intervening network may also become congested and deny service to all hosts whose traffic traverses that network."

Note: This test checks UDP echo and chargen services only in /etc/inetd.conf. These services could be enabled using other options.
Expected resultUDP echo and chargen services are not enabled.
Related RiskMedium
ImpactUDP echo and chargen services could be used to launch a well-known Denial-of-Service (DoS) attack. Anyone with network connectivity can launch an attack; no account access is needed.
RecommendationsDisable all unnecessary network services.
Read moreCERT Advisory CA-1996-01, CVE 1999-0103
 

Test # 17 : No files without owner or group. (updated on 20061107)
Background/DescriptionIf a user or group account was deleted on a UNIX system, it is possible that some files owned by this user or group become orphans. If a new user/group will be created with same UID/GID, these files will become accessible by this new account. Thus, confidential information may become available for an unauthorized person.
Expected resultThere are no files without owner/group on the system.
Related RiskHousekeeping
ImpactNewly created user ID/group with same UID/GID as for these orphan files may have access to them.
RecommendationsAssign files without owner/group to a valid user/group based on job requirements.
Manual AssessmentFind files without owner/group using command find / \( -nouser -o -nogroup \) -type f -exec ls -l {} \;.
 

Test # 18 : No world-writable files. (updated on 20061107)
Background/DescriptionFiles with "world-write" permission could be changed by anyone with a logon privileges on the system. These files could include logs, executable programs and scripts, data, etc. Often this happened because of wrong UMASK settings. There is a well known unauthorized privilege escalation when an attacker modifies a world-writable script to run a malicious program or obtain higher privileges.
Expected resultThere are no world-writable files on the system.
Test requires manual verificationyes
Related RiskMedium
ImpactAn attacker could modify a world-writable script to run a malicious program or obtain higher privileges or modify a log file to hide unauthorized activity.
RecommendationsRemove "world-write" permission from files.
Manual AssessmentFind world-writable files using command find / -perm -0002 -type f -exec ls -l {} \;.
 

Auditing/Logging

Test # 19 : Syslog logging is enabled. (updated on 20070828)
Background/DescriptionAn *nix system could be configured to log important system messages locally or remotely. These messages could be used for troubleshooting or security investigation and damage assessment in an event of a security incident. Regular review of system messages is crucial for the security and health conditions of a system. The main configuration file is /etc/syslog.conf. This file specifies rules for logging. Every rule consists of two fields, a selector field and an action field.
Expected resultLogging is enabled.
Test requires manual verificationyes
Related RiskMedium
ImpactLack of logging of important system events prevents from ability to perform troubleshooting or investigate a security incident.
RecommendationsEnable system logging to a local and remote systems to preserve integrity of logs.
Manual AssessmentVerify rules in the file /etc/syslog.conf. Lines starting with a hash mark ("#") are comments and should be ignored.