2008-10-09 23:53:54 +00:00
|
|
|
##
|
2010-04-30 08:40:19 +00:00
|
|
|
# $Id$
|
|
|
|
##
|
|
|
|
|
|
|
|
##
|
|
|
|
# This file is part of the Metasploit Framework and may be subject to
|
2008-10-09 23:53:54 +00:00
|
|
|
# redistribution and commercial restrictions. Please see the Metasploit
|
|
|
|
# Framework web site for more information on licensing and terms of use.
|
2009-04-13 14:33:26 +00:00
|
|
|
# http://metasploit.com/framework/
|
2008-10-09 23:53:54 +00:00
|
|
|
##
|
|
|
|
|
|
|
|
|
|
|
|
require 'msf/core'
|
|
|
|
|
|
|
|
|
|
|
|
class Metasploit3 < Msf::Auxiliary
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2008-10-09 23:53:54 +00:00
|
|
|
include Msf::Exploit::Remote::Tcp
|
|
|
|
include Msf::Auxiliary::Scanner
|
2010-06-17 14:03:53 +00:00
|
|
|
include Msf::Auxiliary::Report
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2008-10-09 23:53:54 +00:00
|
|
|
def initialize
|
|
|
|
super(
|
|
|
|
'Name' => 'EMC AlphaStor Device Manager Service.',
|
|
|
|
'Version' => '$Revision$',
|
2008-10-10 00:17:44 +00:00
|
|
|
'Description' => 'This module querys the remote host for the EMC Alphastor Device Management Service.',
|
2008-10-09 23:53:54 +00:00
|
|
|
'Author' => 'MC',
|
|
|
|
'License' => MSF_LICENSE
|
|
|
|
)
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2008-10-09 23:53:54 +00:00
|
|
|
register_options([Opt::RPORT(3000),], self.class)
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
def run_host(ip)
|
|
|
|
|
|
|
|
connect
|
|
|
|
|
|
|
|
pkt = "\x68" + Rex::Text.rand_text_alphanumeric(5) + "\x00" * 512
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2008-10-09 23:53:54 +00:00
|
|
|
sock.put(pkt)
|
|
|
|
|
2010-06-22 18:58:38 +00:00
|
|
|
select(nil,nil,nil,0.25)
|
2008-10-09 23:53:54 +00:00
|
|
|
|
|
|
|
data = sock.get_once
|
|
|
|
|
|
|
|
if ( data and data =~ /rrobotd:rrobotd/ )
|
|
|
|
print_status("Host #{ip} is running the EMC AlphaStor Device Manager.")
|
2010-06-17 14:03:53 +00:00
|
|
|
report_service(:host => rhost, :port => rport, :name => "EMC AlphaStor Device Manager", :info => data)
|
2008-10-09 23:53:54 +00:00
|
|
|
else
|
|
|
|
print_error("Host #{ip} is not running the service...")
|
2010-04-30 08:40:19 +00:00
|
|
|
end
|
2008-10-09 23:53:54 +00:00
|
|
|
|
|
|
|
disconnect
|
|
|
|
|
|
|
|
end
|
2010-06-22 18:58:38 +00:00
|
|
|
end
|