首页 -> 安全研究

安全研究

安全漏洞
IRIX handler脚本远程执行任意命令漏洞

发布日期:1997-06-16
更新日期:1997-06-16

受影响系统:
SGI IRIX 6.4
SGI IRIX 6.3
SGI IRIX 6.2
SGI IRIX 6.1
SGI IRIX 6.0.1
SGI IRIX 6.0
SGI IRIX 5.3
不受影响系统:
SGI IRIX 6.5.9m
SGI IRIX 6.5.9f
SGI IRIX 6.5.9
SGI IRIX 6.5.8m
SGI IRIX 6.5.8f
SGI IRIX 6.5.8
SGI IRIX 6.5.7m
SGI IRIX 6.5.7f
SGI IRIX 6.5.7
SGI IRIX 6.5.6m
SGI IRIX 6.5.6f
SGI IRIX 6.5.6
SGI IRIX 6.5.5m
SGI IRIX 6.5.5f
SGI IRIX 6.5.5
SGI IRIX 6.5.4m
SGI IRIX 6.5.4f
SGI IRIX 6.5.4
SGI IRIX 6.5.3m
SGI IRIX 6.5.3f
SGI IRIX 6.5.3
SGI IRIX 6.5.2m
SGI IRIX 6.5.2f
SGI IRIX 6.5.2
SGI IRIX 6.5.16
SGI IRIX 6.5.15m
SGI IRIX 6.5.15f
SGI IRIX 6.5.15
SGI IRIX 6.5.14m
SGI IRIX 6.5.14f
SGI IRIX 6.5.14
SGI IRIX 6.5.13m
SGI IRIX 6.5.13f
SGI IRIX 6.5.13
SGI IRIX 6.5.12m
SGI IRIX 6.5.12f
SGI IRIX 6.5.12
SGI IRIX 6.5.11m
SGI IRIX 6.5.11f
SGI IRIX 6.5.11
SGI IRIX 6.5.10m
SGI IRIX 6.5.10f
SGI IRIX 6.5.10
SGI IRIX 6.5.1
SGI IRIX 6.5
描述:
BUGTRAQ  ID: 380
CVE(CAN) ID: CVE-1999-0148

handler 程序是 IRIX系统 Outbox 环境子系统的一个组成部分。对于IRIX 6.2 以及更新的版本,handler 是默认安装的。6.2以前的版本则作为可选安装组件。

某些早期版本的handler脚本存在输入验证漏洞,远程攻击者可能利用此漏洞在主机上以Web进程的权限执行任意命令。

IRIX 5.3、6.2、6.3、6.4的/cgi-bin/handler程序没有过滤用户输入中可能夹带的shell转义字符,远程攻击者通过在输入中插入shell转义字符及命令就可以主机上以Web服务进程的权限执行之。


<*来源:Razvan Dragomirescu (drazvan@kappa.ro
  
  链接:http://xforce.iss.net/static/340.php
        http://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-1999-0148
        http://online.securityfocus.com/bid/380/
        ftp://patches.sgi.com/support/free/security/advisories/19970501-02-PX
*>

建议:
临时解决方法:

如果您不能立刻安装补丁或者升级,NSFOCUS建议您采取以下措施以降低威胁:

* 暂时禁用该脚本,用如下的命令

# /bin/chmod 400 /var/www/cgi-bin/handler

* 如果不需要使用,可以卸载Outbox环境子系统

# /usr/sbin/versions -v remove outbox

* 一个非官方补丁handler.orig

*** handler.orig Wed Jul 23 20:49:26 1997
--- handler Wed Jul 23 20:55:25 1997
***************
*** 26,31 ****
--- 26,32 ----
$pathRoot = $_[$#_] ;
$doc = $ROOT.$PATH ;

+ $_ = $PATH;
&ErrBadPath unless &ValidPath ; # Check for server spoofing

#__________________________________________________________
***************
*** 108,113 ****
--- 109,117 ----

sub ValidPath
{
+ # suggested by drazvan@kappa.ro
+ if (/[|;]/) { return '' };
+
return 1 unless /\.\./ ;

return '' if /^\.\./ ;
***************
*** 117,120 ****
--- 121,136 ----
return 1 ;
}

+ sub ErrBadPath
+ {
+ print <<ENDOFTEXT ;
+ Content-type: text/html

+ <HEAD><TITLE>404 Not Found</TITLE></HEAD>
+ <BODY><H1>404 Not Found</H1>
+ The requested URL $PATH was not found on this server.<P>
+ </BODY>
+ ENDOFTEXT
+
+ die ;
+ }

厂商补丁:

SGI
---
SGI已经为此发布了一个安全公告(19970501-02-PX)以及相应补丁:
19970501-02-PX:IRIX webdist.cgi, handler and wrap programs
链接:ftp://patches.sgi.com/support/free/security/advisories/19970501-02-PX

补丁下载:

厂商已经在最新版本的软件中修补了这个安全问题,请和厂商联系,获得补丁或升级新版本:

http://www.sgi.com/developers/technology/irix.html

浏览次数:20538
严重程度:0(网友投票)
本安全漏洞由绿盟科技翻译整理,版权所有,未经许可,不得转载
绿盟科技给您安全的保障