2010-04-30 08:40:19 +00:00
|
|
|
##
|
2013-10-15 18:50:46 +00:00
|
|
|
# This module requires Metasploit: http//metasploit.com/download
|
|
|
|
# Current source: https://github.com/rapid7/metasploit-framework
|
2008-10-10 15:28:01 +00:00
|
|
|
##
|
|
|
|
|
|
|
|
|
|
|
|
require 'msf/core'
|
|
|
|
|
|
|
|
|
|
|
|
class Metasploit3 < Msf::Auxiliary
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
include Msf::Exploit::Remote::Tcp
|
|
|
|
include Msf::Auxiliary::Scanner
|
|
|
|
include Msf::Auxiliary::Report
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
def initialize
|
|
|
|
super(
|
|
|
|
'Name' => 'EMC AlphaStor Library Manager Service',
|
|
|
|
'Description' => 'This module queries the remote host for the EMC Alphastor Library Management Service.',
|
|
|
|
'Author' => 'MC',
|
|
|
|
'License' => MSF_LICENSE
|
|
|
|
)
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
register_options([Opt::RPORT(3500),], self.class)
|
|
|
|
end
|
2008-10-10 15:28:01 +00:00
|
|
|
|
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
def run_host(ip)
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
connect
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
pkt = "\x51" + "\x00" * 529
|
2010-04-30 08:40:19 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
sock.put(pkt)
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
select(nil,nil,nil,1)
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
data = sock.get_once
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
if ( data and data =~ /robotd~robotd~CLIENT/ )
|
|
|
|
print_status("Host #{ip} is running the EMC AlphaStor Library Manager.")
|
|
|
|
report_service(:host => rhost, :port => rport, :name => "emc-library", :info => data)
|
|
|
|
else
|
|
|
|
print_error("Host #{ip} is not running the service...")
|
|
|
|
end
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
disconnect
|
2008-10-10 15:28:01 +00:00
|
|
|
|
2013-08-30 21:28:54 +00:00
|
|
|
end
|
2010-06-22 18:58:38 +00:00
|
|
|
end
|