// back

HP UX passwd Binary Buffer Overflow Vulnerability

02.03.03

BACKGROUND

Hewlett-Packard Co.'s /sbin/passwd binary supplied with its HP UX B.10.20 operating system is an integral system process.

DESCRIPTION

Hewlett-Packard Co.'s /sbin/passwd binary supplied with its HP UX B.10.20 operating system contains a buffer overflow that could allow a local privilege-escalation attack.

The environment variable LANG, which is used to control the language setting of the local subsystem, causes the /sbin/passwd binary to crash when filled with a string of approximately 4,240 bytes. This allows an attacker to gain control of the return address of the executing function, and, in turn, execute arbitrary code with the privileges of the /sbin/passwd binary. This binary is installed setuid to root by default.

ANALYSIS

Exploitation of this vulnerabilty allows a local attacker to assume root privilieges of the target computer. As no official patch is available, apply the workaround below.

iDEFENSE has proof of concept exploit code demonstrating the impact of this vulnerability.

DETECTION

iDEFENSE has verified that HPUX 10.20 is affected.

WORKAROUND

Remove the setuid bit on the executable with the chmod command:

chmod u-s /sbin/passwd

VENDOR RESPONSE

HP does not plan to develop a patch for this issue. HP recommends using chmod to remove the setuid bit.

CVE INFORMATION

A Mitre Corp. Common Vulnerabilities and Exposures (CVE) number CAN-2003-0061 has been assigned to this issue.

DISCLOSURE TIMELINE

01/11/2002   Exploit acquired by iDEFENSE
01/20/2003   Initial vendor notification
02/03/2003   iDEFENSE Clients notified
02/10/2003   Public Disclosure

CREDIT

Euan Briggs is credited with this discovery.

Get paid for vulnerability research
http://www.idefense.com/poi/teams/vcp.jsp

LEGAL NOTICES

Copyright © 2004 Verisign, Inc.

Permission is granted for the redistribution of this alert
electronically. It may not be edited in any way without the express
written consent of iDEFENSE. If you wish to reprint the whole or any
part of this alert in any other medium other than electronically, please
email customerservice@idefense.com for permission.

Disclaimer: The information in the advisory is believed to be accurate
at the time of publishing based on currently available information. Use
of the information constitutes acceptance for use in an AS IS condition.
There are no warranties with regard to this information. Neither the
author nor the publisher accepts any liability for any direct, indirect,
or consequential loss or damage arising from use of, or reliance on,
this information.