mailing list archives
IBM ERS: Vulnerability in AIX diagrpt
From: Keith Stevenson <keith.stevenson () louisville edu>
Date: Fri, 22 Jun 2001 09:48:10 -0400
----- Forwarded message from AIX Service Mail Server <aixserv () austin ibm com> -----
This file contains security alerts published by the IBM Emergency Response
Service. These alerts are published at the following URL on the world-wide
In order to keep the size of this file reasonable, it contains only
advisories for the current year. You can obtain a list of previous
advisories either from the above URLs, or by requesting one of the
"ERS_YYYY" documents from this mail server.
The fixes mentioned in this document, when available, will be available
from FixDist. Information on obtaining and using FixDist is available
by requesting the 'FixDist' document from this mail server, or at the
following URL on the world-wide web:
The 'Security_APARs' document on this mail server contains a list of
security related APARs.
VULNERABILITY: Root Shell Spawning Possible Via "diagrpt"
PLATFORMS: IBM AIX 4.3.x and 5.1
SOLUTION: Apply the emergency-fixes described below, or
employ the workaround, also described below.
THREAT: Malicious user could obtain root privileges.
CERT Advisory: NONE.
AIX ships with the diagnostic reporting command, "diagrpt". This
command is shipped SUID, or "set user ID", and is executable by
an ordinary user.
An ordinary user is able to set the "DIAGDATADIR" environment
veriable to a directory of his or her choosing. In this
directory, a user can place a carefully crafted shell program
that is executed when the user runs the "diagrpt" command.
The SUID bit for "diagrpt" will run the shell program as root,
and this program will force the spawning of a new shell with
A malicious local user can use a well-crafted exploit code
to gain root privileges on the attacked system, compromising the
integrity of the system and its attached local network.
If you do not wish to install the efix for this vulnerability
but instead wait for the APAR that fixes it to be made
available, you can also negate this vulnerability by making the
"diagrpt" command to be non-SUID. You must be "root" to do this.
However, ordinary users will not be able to use the command if
the SUID bit is removed.
B. Official fix
IBM is working on the following fixes which will be available
AIX 4.3.x and 5.1: APAR assignment pending.
NOTE: Fix will not be provided for versions prior to 4.3 as
these are no longer supported by IBM. Affected customers are
urged to upgrade to 4.3.3 at the latest maintenance level,
or to 5.1.
C. How to minimize the vulnerability
Temporary fixes for AIX 4.3.x and 5.1 systems are available.
The temporary fixes can be downloaded via ftp from:
The efix tarball consists of two patched diagrpt tarred binaries, one
AIX 4.3.x systems (diagrpt.43.tar) and one for AIX 5.1
(diagrpt.51.tar). A copy of this Advisory is included in the efix
These temporary fixes have not been fully regression tested; thus,
IBM does not warrant the fully correct functioning of the efix.
Customers install the efix and operate the modified version of AIX
at their own risk.
To proceed with efix installation:
First, verify the MD5 cryptographic hash sums of each efix files
you obtain from unpacking the efix tarball with those given below.
should match exactly; if they do not, double check the hash results
and the download site address. If OK, contact IBM AIX Security at
security-alert () austin ibm com and describe the discrepancy.
Filename sum md5
diagrpt.43.tar 02875 30 168c5bf253b516cd7e6a69a94aefa061
diagrpt.51.tar 02327 30 f5df8339dde46d3cc12c6d7b22fd37c4
Efix Installation Instructions:
IMPORTANT NOTICE: Before installing the efix, you must upgrade
to the latest maintenance level of AIX for your version of AIX.
For AIX 4.3, this level is 22.214.171.124. For AIX 5.1, this level
1. Become root, if not already done.
2. Change to the /usr/lpp/diagnostics/bin directory. Make
a backup copy of the existing diagrpt binary, giving it
a distinctive, meaningful name, such as "diagrpt.original"
or "diagrpt.backup". This is IMPORTANT to do, so you can
recover the orginal diagrpt binary if something goes wrong during
the installation of the efix!
3. In the root ("/") directory, download, uncompress, and untar
a. uncompress diagrpt_efix.tar.Z
b. tar -xvf diagrpt_efix.tar
4. You will have two tarfiles: "diagrpt.43.tar" and
"diagrpt.51.tar". Save the tarfile appropriate for your
version of AIX (i.e., 4.3.3.x or 126.96.36.199); you may discard
the other, unneeded tarfile.
Untar the appropriate (for your AIX version) tarfile by
executing "tar -xvf diagrpt.xy.tar". The efix version of
diagrpt will be untarred and placed in the proper directory.
"xy" is either "43" or "51".
5. Check to be certain that the new diagrpt is SUID and
is assigned proper permissions, "-r-sr-xr-x", and the ownership
is assigned properly, "root" and "system".
IV. Obtaining Fixes
IBM AIX APARs may be ordered using Electronic Fix Distribution (via the
FixDist program), or from the IBM Support Center. For more information
on FixDist, and to obtain fixes via the Internet, please reference
or send email to "aixserv () austin ibm com" with the word "FixDist" in the
To facilitate ease of ordering all security related APARs for each AIX
release, security fixes are periodically bundled into a cumulative APAR.
For more information on these cumulative APARs including last update and
list of individual fixes, send email to "aixserv () austin ibm com" with
the word "subscribe Security_APARs" in the "Subject:" line.
Many thanks go to Johan Van Mengsel of IBM Belgium for
discovering this vulnerability, and to Troy Bollinger of
IBM Boulder and Austin for demonstrating the exploitation
of this vulnerability.
VI. Contact Information
Comments regarding the content of this announcement can be directed to:
security-alert () austin ibm com
To request the PGP public key that can be used to encrypt new AIX
security vulnerabilities, send email to security-alert () austin ibm com
with a subject of "get key".
If you would like to subscribe to the AIX security newsletter, send a
note to aixserv () austin ibm com with a subject of "subscribe Security".
To cancel your subscription, use a subject of "unsubscribe Security".
To see a list of other available subscriptions, use a subject of
IBM and AIX are a registered trademark of International Business
Machines Corporation. All other trademarks are property of their
----- End forwarded message -----
- IBM ERS: Vulnerability in AIX diagrpt Keith Stevenson (Jun 22)