OMail Webmail远程命令执行漏洞
发布日期:2003-08-21
更新日期:2003-08-25
受影响系统:OMail OMail webmail 0.98.3
OMail OMail webmail 0.97.3
不受影响系统:OMail OMail webmail 0.98.5
描述:
BUGTRAQ ID:
8451
CVE(CAN) ID:
CVE-2003-1202
Omail是一款由perl编写的结合qmail的WEB邮件系统。
Omail的checklogin()函数对用户提交的参数缺少充分过滤,远程攻击者可以利用这个漏洞以WEB权限在系统上执行任意指令。
问题存在于函数checklogin()中:
.........
omail.pl, line 689:
my $command = 'echo -e "'. $domainname .'\000'.
$username .'\000'.$password .'\000" | ' .$vauthenticate;
my $output = `$command`;
.........
在调用此行之前,没有变量$domainname,$username,和$password进行充分的过滤,攻击者提交包含元字符的数据,可能以WEB权限在系统上执行任意命令。
<*来源:Phillip Whelan (
pwhelan@bunkerchile.net)
链接:
http://marc.theaimsgroup.com/?l=bugtraq&m=106132514828641&w=2
*>
建议:
临时解决方法:
如果您不能立刻安装补丁或者升级,NSFOCUS建议您采取以下措施以降低威胁:
* 第三方补丁如下:
--- omail-webmail-0.98.4/omail-old.pl 2001-08-26
08:35:27.000000000 -0400
+++ omail-webmail-0.98.4/omail.pl 2003-07-28
12:29:36.000000000 -0400
@@ -396,7 +396,7 @@
if (($vmailmgr || $vpopmail) && $cgi_mode eq "suid") {
- if (!($userid =~ /(.*)\@(.*)/)) {
+ if (!($userid =~ /([A-Z,a-z,0-9]*)\@([\w\.]*)$/)) {
omailerror("domain name is missing : format
userid\@domain");
} else {
$userid = $1;
@@ -406,7 +406,7 @@
my $password = param("password");
- $password =~ /^(.+)$/;
+ $password =~ /^([^\"]+)$/;
$password = $1;
# 8 possible cases :
厂商补丁:
OMail
-----
目前厂商已经发布了升级补丁以修复这个安全问题,请到厂商的主页下载:
OMail Upgrade omail-webmail-0.98.5.tar.gz
http://prdownloads.sourceforge.net/omail/omail-webmail-0.98.5.tar.gz浏览次数:2842
严重程度:0(网友投票)