CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In
rapid7

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

GitHub Repository: rapid7/metasploit-framework
Path: blob/master/modules/auxiliary/scanner/emc/alphastor_devicemanager.rb
Views: 11784
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::Auxiliary
7
include Msf::Exploit::Remote::Tcp
8
include Msf::Auxiliary::Scanner
9
include Msf::Auxiliary::Report
10
11
def initialize
12
super(
13
'Name' => 'EMC AlphaStor Device Manager Service',
14
'Description' => 'This module queries the remote host for the EMC Alphastor Device Management Service.',
15
'Author' => 'MC',
16
'License' => MSF_LICENSE
17
)
18
19
register_options([Opt::RPORT(3000),])
20
end
21
22
23
def run_host(ip)
24
25
connect
26
27
pkt = "\x68" + Rex::Text.rand_text_alphanumeric(5) + "\x00" * 512
28
29
sock.put(pkt)
30
31
select(nil,nil,nil,0.25)
32
33
data = sock.get_once
34
35
if ( data and data =~ /rrobotd:rrobotd/ )
36
print_good("Host #{ip} is running the EMC AlphaStor Device Manager.")
37
report_service(:host => rhost, :port => rport, :name => "emc-manager", :info => data)
38
else
39
print_error("Host #{ip} is not running the service...")
40
end
41
42
disconnect
43
44
end
45
end
46
47