5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
|
# File 'lib/hotwired/model.rb', line 5
def self.map(sysDescr, sysObjectID)
case sysDescr
when /Cisco Catalyst Operating System/i
"catos"
when /Cisco Controller/
"aireos"
when /IOS XR/
"iosxr"
when /NX-OS/
"nxos"
when /JUNOS/
"junos"
when /Arista Networks EOS/
"eos"
when /IronWare/
"ironware"
when /TiMOS/
"timos"
when /ExtremeXOS/
"xos"
when /Cisco Adaptive Security Appliance/
"asa"
when /Brocade Fibre Channel Switch/
"fabricos"
when /Brocade VDX/
"nos"
when /cisco/i, /Application Control Engine/i
"ios"
when /Force10 OS/
"ftos"
when /Versatile Routing Platform/
"vrp"
when /^NetScreen/, /^SSG-\d+/
"screenos"
when /^Summit/
"xos"
when /^Alcatel-Lucent \S+ [789]\./ "aos7"
when /^AOS-W/
"aosw"
when /^Alcatel-Lucent/
"aos"
when /\s+ACOS\s+/
"acos"
when /ProCurve/ "procurve"
when /ASAM/
"isam"
when /^\d+[A-Z]\sEthernet Switch$/
"powerconnect"
when /Ericsson IPOS/
"ssr"
when /Huawei Integrated Access Software/
"hias"
else
case sysObjectID
when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.12356."))
"fortios" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.6486."))
"aos" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.6027."))
"ftos" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.1588."))
"fabricos " when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.3224."))
"screenos" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.674."))
"powerconnect" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.22610."))
"acos" when Regexp.new("^" + Regexp.quote(".1.3.6.1.4.1.637."))
"isam" when Regexp.new("^" + Regexp.quote(".1.3.6.1.4.1.2011."))
"vrp" when Regexp.new("^" + Regexp.quote(".1.3.6.1.4.1.1588."))
"nos" when Regexp.new("^" + Regexp.quote(".1.3.6.1.4.1.1916."))
"xos" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.9.1.745"))
"asa" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.20858.2.600"))
"casa" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.2011.2.169"))
"hias" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.2011.2.300"))
"hias" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.2352.1"))
"ssr" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.193.218.1"))
"ssr" when Regexp.new("^" + Regexp.quote("1.3.6.1.4.1.11.2.3.7.11"))
"procurve" else
"unsupported"
end
end
end
|