documentation overhaul (#353)

* ident
* remove $Id$ tags from rcs software which has been retired
* make an effort to sync required mib docs with actual code
* sync even more docs with what code actually does
* some whitespace nits
* fixup example to use snmpv2 for all but the most ancient devices
* remove blurb to find more specific snmp::info classes for classes
  which alrdy are as specific as they can get (eg snmp::info::layer3::vmware
  doesn't need info on to find a specific module since there ain't none)
* rename all sub {vendor} strings to lowercase vendor, if cisco, juniper
  and arista can be lowercase, so can be all the rest.
* fix tests
* spread some use warnings around
* use $ instead of @
* remove defines that are included via parent classes
* use strict + warnings
* remove alrdy included modules
* add comma after last list item
* typos
* mibs are found in our mib repo, not on the cisco site
* documentation fixes
This commit is contained in:
nick n
2019-08-25 06:47:10 +02:00
committed by GitHub
parent 6c8d39d746
commit 3bcc522590
149 changed files with 630 additions and 1168 deletions

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Aironet
# $Id$
#
# Copyright (c) 2008 Max Baker changes from version 0.8 and beyond.
#
@@ -33,6 +32,7 @@
package SNMP::Info::Layer3::Aironet;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -279,9 +279,6 @@ after determining a more specific class using the method above.
=back
These MIBs are now included in the v2.tar.gz archive available from
ftp.cisco.com. Make sure you have a current version.
=head1 GLOBALS
These are methods that return scalar value from SNMP

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::AlcatelLucent
# $Id$
#
# Copyright (c) 2008 Bill Fenner
#
@@ -30,6 +29,7 @@
package SNMP::Info::Layer3::AlcatelLucent;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -115,7 +115,9 @@ sub os_ver {
my $alu = shift;
my $descr = $alu->description();
return $1 if $descr =~ m/\b(\d[\.\d]+R\d+) (?:GA|Service Release), /;
if (defined ($descr)) {
return $1 if $descr =~ m/\b(\d[\.\d]+R\d+) (?:GA|Service Release), /;
}
# No clue what this will try but hey
return $alu->SUPER::os_ver();
@@ -370,7 +372,7 @@ These are methods that return scalar value from SNMP
=item $alu->vendor()
Returns 'alcatel-lucent'
Returns 'alcatel-lucent'
=item $alu->model()

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::AlteonAD
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All Rights Reserved
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::AlteonAD;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -450,11 +450,6 @@ Eric Miller
Abstraction subclass for Radware Alteon Series ADC switches and
Nortel BladeCenter Layer2-3 GbE Switch Modules.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $alteon = new SNMP::Info::Layer3::AlteonAD(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Altiga
# $Id$
#
# Copyright (c) 2008 Jeroen van Ingen Schenau
# All rights reserved.
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::Altiga;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -281,7 +281,7 @@ Jeroen van Ingen Schenau
Debug => 1,
DestHost => 'my_vpn_host',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -304,6 +304,12 @@ Subclass for Cisco (formerly Altiga) VPN concentrators
=over
=item F<ALTIGA-VERSION-STATS-MIB>
=item F<ALTIGA-SESSION-STATS-MIB>
=item F<ALTIGA-HARDWARE-STATS-MIB>
=item Inherited Classes' MIBs
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Arista
# $Id$
#
# Copyright (c) 2008 Arista Networks, Inc.
# All rights reserved.
@@ -31,18 +30,17 @@
package SNMP::Info::Layer3::Arista;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::MAU;
use SNMP::Info::LLDP;
use SNMP::Info::Aggregate 'agg_ports_ifstack';
@SNMP::Info::Layer3::Arista::ISA = qw/
SNMP::Info::Aggregate
SNMP::Info::LLDP
SNMP::Info::MAU
SNMP::Info::Layer3 Exporter
SNMP::Info::Layer3
Exporter
/;
@SNMP::Info::Layer3::Arista::EXPORT_OK = qw//;
@@ -53,7 +51,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::MAU::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::Aggregate::MIBS,
'ARISTA-PRODUCTS-MIB' => 'aristaDCS7124S',
);
@@ -61,19 +58,16 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::MAU::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::MAU::FUNCS,
%SNMP::Info::LLDP::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::MAU::MUNGE,
%SNMP::Info::LLDP::MUNGE,
);
# use MAU-MIB for admin. duplex and admin. speed
@@ -92,11 +86,14 @@ sub os {
sub os_ver {
my $arista = shift;
my $descr = $arista->description();
my $os_ver = undef;
my $descr = $arista->description();
$os_ver = $1 if ( $descr =~ /\s+EOS\s+version\s+(\S+)\s+/ );
return $os_ver;
if (defined ($descr)) {
my $os_ver = undef;
$os_ver = $1 if ($descr =~ /\s+EOS\s+version\s+(\S+)\s+/);
return $os_ver;
}
return;
}
sub model {
@@ -174,8 +171,6 @@ Subclass for Arista Networks EOS-based devices
=item SNMP::Info::MAU
=item SNMP::Info::LLDP
=back
=head2 Required MIBs
@@ -192,8 +187,6 @@ See L<SNMP::Info::Aggregate/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::MAU/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -230,10 +223,6 @@ See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
See documentation in L<SNMP::Info::MAU/"GLOBALS"> for details.
=head2 Global Methods imported from SNMP::Info::Layer3
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -269,8 +258,4 @@ See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
See documentation in L<SNMP::Info::MAU/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Aruba
# $Id$
#
# Copyright (c) 2013 Eric Miller
# All rights reserved.
@@ -31,11 +30,11 @@
package SNMP::Info::Layer3::Aruba;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Aruba::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Aruba::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Aruba::EXPORT_OK = qw//;
our ($VERSION, %FUNCS, %GLOBALS, %MIBS, %MUNGE);
@@ -44,7 +43,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
'WLSR-AP-MIB' => 'wlsrHideSSID',
'WLSX-IFEXT-MIB' => 'ifExtVlanName',
'WLSX-POE-MIB' => 'wlsxPseSlotPowerAvailable',
@@ -58,7 +56,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'aruba_serial_old' => 'wlsxSwitchLicenseSerialNumber',
'aruba_serial_new' => 'wlsxSysExtLicenseSerialNumber',
'aruba_model' => 'wlsxModelName',
@@ -67,7 +64,6 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
# WLSR-AP-MIB::wlsrConfigTable
'aruba_ap_ssidbcast' => 'wlsrHideSSID',
@@ -143,7 +139,6 @@ $VERSION = '3.68';
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
'aruba_ap_fqln' => \&munge_aruba_fqln,
'aruba_ap_type' => \&SNMP::Info::munge_e_type,
'aruba_card_type' => \&SNMP::Info::munge_e_type,
@@ -170,10 +165,9 @@ sub vendor {
$id = $1 if ( defined($id) && $id =~ /^\.1\.3\.6\.1\.4\.1\.(\d+)/ );
if ( defined($id) and exists( $oidmap{$id} ) ) {
return $oidmap{$id};
}
else {
return 'aruba';
return $oidmap{$id};
} else {
return 'aruba';
}
}
@@ -183,7 +177,7 @@ sub os_ver {
return unless defined $descr;
if ( $descr =~ m/Version\s+(\d+\.\d+\.\d+\.\d+)/ ) {
return $1;
return $1;
}
return;
@@ -1421,11 +1415,6 @@ This class emulates bridge functionality for the wireless switch. This enables
end station MAC addresses collection and correlation to the thin access point
the end station is using for communication.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $aruba = new SNMP::Info::Layer3::Aruba(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::BayRS
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,13 +30,12 @@
package SNMP::Info::Layer3::BayRS;
use strict;
use warnings;
use Exporter;
use SNMP::Info;
use SNMP::Info::Layer3;
use SNMP::Info::Bridge;
@SNMP::Info::Layer3::BayRS::ISA = qw/SNMP::Info SNMP::Info::Layer3
SNMP::Info::Bridge Exporter/;
@SNMP::Info::Layer3::BayRS::ISA = qw/SNMP::Info::Layer3
Exporter/;
@SNMP::Info::Layer3::BayRS::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE, %MODEL_MAP,
@@ -46,9 +44,7 @@ our ($VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE, %MODEL_MAP,
$VERSION = '3.68';
%MIBS = (
%SNMP::Info::MIBS,
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::Bridge::MIBS,
'Wellfleet-HARDWARE-MIB' => 'wfHwBpIdOpt',
'Wellfleet-OSPF-MIB' => 'wfOspfRouterId',
'Wellfleet-DOT1QTAG-CONFIG-MIB' => 'wfDot1qTagCfgVlanName',
@@ -57,18 +53,14 @@ $VERSION = '3.68';
);
%GLOBALS = (
%SNMP::Info::GLOBALS,
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::Bridge::GLOBALS,
'bp_id' => 'wfHwBpIdOpt',
'bp_serial' => 'wfHwBpSerialNumber',
'ospf_rtr_id' => 'wfOspfRouterId',
);
%FUNCS = (
%SNMP::Info::FUNCS,
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::Bridge::FUNCS,
# From Wellfleet-CSMACD-MIB::wfCSMACDTable
'wf_csmacd_cct' => 'wfCSMACDCct',
@@ -107,9 +99,7 @@ $VERSION = '3.68';
);
%MUNGE = (
%SNMP::Info::MUNGE,
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::Bridge::MUNGE,
'wf_hw_boot' => \&munge_hw_rev,
'wf_hw_diag' => \&munge_hw_rev,
'wf_hw_mobo_ser' => \&munge_wf_serial,
@@ -541,7 +531,10 @@ sub model {
my $bayrs = shift;
my $bp_id = $bayrs->bp_id();
return defined $MODEL_MAP{$bp_id} ? $MODEL_MAP{$bp_id} : $bp_id;
if (defined $bp_id) {
return defined $MODEL_MAP{$bp_id} ? $MODEL_MAP{$bp_id} : $bp_id;
}
return;
}
sub vendor {
@@ -776,7 +769,7 @@ sub e_index {
my $bp_id = $bayrs->bp_id();
# Don't like polling all these columns to build the index, can't think of
# a better way right now. Luckly all this data will be cached for the
# a better way right now. Luckily all this data will be cached for the
# rest of the e_* methods
# Using mib leafs so we don't have to define everything in FUNCS
@@ -805,7 +798,7 @@ sub e_index {
my @slots = ( $wf_mb, $wf_db, $wf_bb, $wf_mod, $wf_mod1, $wf_mod2 );
my @mods = ( $wf_mm, $wf_dm );
# We're going to hack an index: Slot/Module/Postion
# We're going to hack an index: Slot/Module/Position
my %wf_e_index;
# Chassis on BN types
@@ -1406,19 +1399,10 @@ Eric Miller
Abstraction subclass for routers running Avaya/Nortel BayRS.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $bayrs = new SNMP::Info::Layer3::BayRS(...);
=head2 Inherited Classes
=over
=item SNMP::Info
=item SNMP::Info::Bridge
=item SNMP::Info::Layer3
=back
@@ -1441,10 +1425,6 @@ after determining a more specific class using the method above.
=head2 Inherited MIBs
See L<SNMP::Info/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::Bridge/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
=head1 GLOBALS
@@ -1500,14 +1480,6 @@ undefined.
=back
=head2 Globals imported from SNMP::Info
See documentation in L<SNMP::Info/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::Bridge
See documentation in L<SNMP::Info::Bridge/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::Layer3
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
@@ -1625,14 +1597,6 @@ is not contained in any other entity.
=back
=head2 Table Methods imported from SNMP::Info
See documentation in L<SNMP::Info/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::Bridge
See documentation in L<SNMP::Info::Bridge/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::Layer3
See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.

View File

@@ -28,6 +28,7 @@ package SNMP::Info::Layer3::BlueCoatSG;
# POSSIBILITY OF SUCH DAMAGE.
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -55,7 +56,7 @@ $VERSION = '3.68';
%MUNGE = ( %SNMP::Info::Layer2::MUNGE, %SNMP::Info::Layer3::MUNGE, );
sub vendor {
return 'Blue Coat';
return 'bluecoat';
}
sub os {
@@ -65,7 +66,7 @@ sub os {
sub os_ver {
my $sg = shift;
my $os_string = $sg->sw_ver();
if ($os_string =~ /^Version:\s(\w+)\s([\d\.]+)/) {
if (defined ($os_string) && $os_string =~ /^Version:\s(\w+)\s([\d\.]+)/) {
return $2;
} else {
return ''; # perhaps we can try sysDescr or some other object...
@@ -92,7 +93,7 @@ Jeroen van Ingen
Debug => 1,
DestHost => 'myrouter',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -113,10 +114,10 @@ Subclass for Blue Coat SG Series proxy devices
=head2 Required MIBs
BLUECOAT-SG-PROXY-MIB
=over
=item F<BLUECOAT-SG-PROXY-MIB>
=item Inherited Classes' MIBs
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
@@ -133,7 +134,7 @@ These are methods that return scalar value from SNMP
=item $router->vendor()
Returns C<'Blue Coat'>
Returns C<'bluecoat'>
=item $router->os()

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::C3550
# $Id$
#
# Copyright (c) 2008-2009 Max Baker changes from version 0.8 and beyond.
# Copyright (c) 2004 Regents of the University of California
@@ -105,7 +104,7 @@ sub ports {
return $ports;
}
# Verions prior to 12.1(22)EA1a use the older CiscoStack method
# Versions prior to 12.1(22)EA1a use the older CiscoStack method
# Newer versions use the ETHERLIKE-MIB to report operational duplex.
# See http://www.ciscosystems.com/en/US/products/hw/switches/ps646/prod_release_note09186a00802a08ee.html
@@ -228,11 +227,6 @@ These devices run IOS but have some of the same characteristics as the
Catalyst WS-C family (5xxx,6xxx). For example, forwarding tables are held in
VLANs, and extended interface information is gleaned from F<CISCO-SWITCH-MIB>.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $c3550 = new SNMP::Info::Layer3::C3550(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::C4000
# $Id$
#
# Copyright (c) 2008 Bill Fenner
# All rights reserved.
@@ -129,11 +128,6 @@ Bill Fenner
Abstraction subclass for Cisco Catalyst 4000 Layer 2/3 Switches.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $c4000 = new SNMP::Info::Layer3::C4000(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::C6500
# $Id$
#
# Copyright (c) 2008-2009 Max Baker
# All rights reserved.
@@ -186,7 +185,7 @@ sub set_i_duplex_admin {
# 2. Disable ifMauAutoNegAdminStatus
# If the second set is not done, this is not going to be
# working... Cisco Bug id CSCty97033.
# SXI is not working (up to at least relase SXI9).
# SXI is not working (up to at least release SXI9).
# SXJ is working at SXJ3 (not before).
return $c6500->mau_set_i_duplex_admin( $duplex, $iid );
@@ -224,7 +223,7 @@ sub set_i_speed_admin {
# 2. Disable ifMauAutoNegAdminStatus
# If the second set is not done, this is not going to be working...
# Cisco Bug id CSCty97033.
# SXI is not working (at least up to relase SXI9).
# SXI is not working (at least up to release SXI9).
# SXJ is working at SXJ3 (not before).
return $c6500->mau_set_i_speed_admin( $speed, $iid );
@@ -242,7 +241,8 @@ __END__
=head1 NAME
SNMP::Info::Layer3::C6500 - SNMP Interface to Cisco Catalyst 6500 Layer 2/3
Switches running IOS and/or CatOS
Switches running IOS and/or CatOS. Also Cisco Catalyst 2960, 2970, 3750 and
3850 series and blade switch CBS30x0 and CBS31x0 series running IOS.
=head1 AUTHOR
@@ -272,10 +272,9 @@ These devices run IOS but have some of the same characteristics as the
Catalyst WS-C family (5xxx). For example, forwarding tables are held in
VLANs, and extended interface information is gleaned from F<CISCO-SWITCH-MIB>.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $c6500 = new SNMP::Info::Layer3::C6500(...);
It also supports the following IOS only series switches: Cisco Catalyst 2960,
2970, 3750 and 3850 series. Also blade switches from the CBS30x0 and CBS31x0
series.
=head2 Inherited Classes
@@ -293,6 +292,8 @@ after determining a more specific class using the method above.
=over
=item F<CISCO-VIRTUAL-SWITCH-MIB>
=item Inherited Classes' MIBs
See L<SNMP::Info::CiscoStack/"Required MIBs"> for its own MIB requirements.
@@ -312,7 +313,7 @@ These are methods that return scalar value from SNMP
=item $c6500->vendor()
Returns 'cisco'
Returns 'cisco'
=item $c6500->cvsSwitchMode()
@@ -397,13 +398,11 @@ Crosses $c6500->p_port() with $c6500->p_speed() to utilize port C<ifIndex>.
See documentation in L<SNMP::Info::CiscoStack/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::Layer3::CiscoSwitch
See documentation in L<SNMP::Info::Layer3::CiscoSwitch/"TABLE METHODS"> for
details.
=head2 Table Methods imported from SNMP::Info::MAU
See documentation in L<SNMP::Info::MAU/"TABLE METHODS"> for details.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::CheckPoint
# $Id$
#
# Copyright (c) 2008 Bill Fenner
# All rights reserved.
@@ -31,11 +30,11 @@
package SNMP::Info::Layer3::CheckPoint;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::CheckPoint::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::CheckPoint::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::CheckPoint::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %MIBS, %FUNCS, %MUNGE);
@@ -44,7 +43,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
'CHECKPOINT-MIB' => 'fwProduct',
'UCD-SNMP-MIB' => 'versionTag',
'NET-SNMP-TC' => 'netSnmpAliasDomain',
@@ -54,15 +52,12 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'netsnmp_vers' => 'versionTag',
'hrSystemUptime' => 'hrSystemUptime',
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
# Net-SNMP Extend table that could but customize to add a the CheckPoint version
'extend_output_table' => 'nsExtendOutputFull',
@@ -70,7 +65,6 @@ $VERSION = '3.68';
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
);
sub vendor {
@@ -199,11 +193,11 @@ Ambroise Rosset
=head1 DESCRIPTION
Subclass for Generic Net-SNMP devices
Subclass for CheckPoint Devices.
=head2 WARNING
To correctly and completelly work, you should add the following line in the file C</etc/snmp/snmpd.local.conf> on each of your CheckPoint devices:
To correctly and completely work, you should add the following line in the file C</etc/snmp/snmpd.local.conf> on each of your CheckPoint devices:
# Netdisco SNMP configuration
extend ckpVersion /opt/CPsuite-R77/fw1/bin/fw ver
@@ -221,8 +215,12 @@ To correctly and completelly work, you should add the following line in the file
=over
=item F<CHECKPOINT-MIB>
=item F<UCD-SNMP-MIB>
=item F<NET-SNMP-EXTEND-MIB>
=item F<NET-SNMP-TC>
=item F<HOST-RESOURCES-MIB>
@@ -231,8 +229,6 @@ To correctly and completelly work, you should add the following line in the file
See L<SNMP::Info::Layer3> for its own MIB requirements.
See L<SNMP::Info::LLDP> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -279,10 +275,6 @@ Return '01001100'.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head1 TABLE ENTRIES
These are methods that return tables of information in the form of a reference
@@ -304,10 +296,6 @@ Ignores loopback
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head1 NOTES
In order to cause SNMP::Info to classify your device into this class, it

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Cisco
# $Id$
#
# Copyright (c) 2008 Max Baker
# All rights reserved.
@@ -34,7 +33,6 @@ use strict;
use warnings;
use Exporter;
use SNMP::Info::CiscoVTP;
use SNMP::Info::LLDP;
use SNMP::Info::CDP;
use SNMP::Info::CiscoStats;
use SNMP::Info::CiscoRTT;
@@ -45,7 +43,7 @@ use SNMP::Info::CiscoStpExtensions;
use SNMP::Info::Layer3;
@SNMP::Info::Layer3::Cisco::ISA = qw/SNMP::Info::CiscoVTP
SNMP::Info::LLDP SNMP::Info::CDP
SNMP::Info::CDP
SNMP::Info::CiscoStats SNMP::Info::CiscoRTT
SNMP::Info::CiscoQOS SNMP::Info::CiscoConfig
SNMP::Info::CiscoPower SNMP::Info::CiscoStpExtensions
@@ -66,7 +64,6 @@ $VERSION = '3.68';
%SNMP::Info::CiscoRTT::MIBS,
%SNMP::Info::CiscoStats::MIBS,
%SNMP::Info::CDP::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::CiscoVTP::MIBS,
'CISCO-EIGRP-MIB' => 'cEigrpAsRouterId',
);
@@ -80,7 +77,6 @@ $VERSION = '3.68';
%SNMP::Info::CiscoRTT::GLOBALS,
%SNMP::Info::CiscoStats::GLOBALS,
%SNMP::Info::CDP::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
%SNMP::Info::CiscoVTP::GLOBALS,
'eigrp_id' => 'cEigrpAsRouterId',
);
@@ -94,13 +90,11 @@ $VERSION = '3.68';
%SNMP::Info::CiscoRTT::FUNCS,
%SNMP::Info::CiscoStats::FUNCS,
%SNMP::Info::CDP::FUNCS,
%SNMP::Info::LLDP::FUNCS,
%SNMP::Info::CiscoVTP::FUNCS,
# CISCO-EIGRP-MIB::cEigrpPeerTable
'c_eigrp_peer_types' => 'cEigrpPeerAddrType',
'c_eigrp_peers' => 'cEigrpPeerAddr',
);
%MUNGE = (
@@ -108,7 +102,7 @@ $VERSION = '3.68';
%SNMP::Info::CiscoPower::MUNGE, %SNMP::Info::CiscoConfig::MUNGE,
%SNMP::Info::CiscoQOS::MUNGE, %SNMP::Info::CiscoRTT::MUNGE,
%SNMP::Info::CiscoStats::MUNGE, %SNMP::Info::CDP::MUNGE,
%SNMP::Info::LLDP::MUNGE, %SNMP::Info::CiscoVTP::MUNGE,
%SNMP::Info::CiscoVTP::MUNGE,
);
sub i_vlan {
@@ -214,8 +208,6 @@ for other device specific L3 Cisco classes.
=item SNMP::Info::CiscoVTP
=item SNMP::Info::LLDP
=item SNMP::Info::CDP
=item SNMP::Info::CiscoStats
@@ -244,8 +236,6 @@ for other device specific L3 Cisco classes.
See L<SNMP::Info::CiscoVTP/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::CDP/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::CiscoStats/"Required MIBs"> for its own MIB requirements.
@@ -285,10 +275,6 @@ Determined by checking C<vtpVersion>.
See documentation in L<SNMP::Info::CiscoVTP/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::CDP
See documentation in L<SNMP::Info::CDP/"GLOBALS"> for details.
@@ -344,10 +330,6 @@ Returns a mapping between C<ifIndex> and the PVID or default VLAN.
See documentation in L<SNMP::Info::CiscoVTP/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::CDP
See documentation in L<SNMP::Info::CDP/"TABLE METHODS"> for details.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::CiscoASA
# $Id$
#
# Copyright (c) 2013 Moe Kraus
# All rights reserved.
@@ -113,7 +112,7 @@ Moe Kraus
=head1 SYNOPSIS
# Let SNMP::Info determine the correct subclass for you.
my $cisco = new SNMP::Info(
my $asa = new SNMP::Info(
AutoSpecify => 1,
Debug => 1,
# These arguments are passed directly to SNMP::Session

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::CiscoFWSM
# $Id$
#
# Copyright (c) 2010 Brian De Wolf
# All rights reserved.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::CiscoSwitch
# $Id$
#
# Copyright (c) 2014 Eric Miller
# All rights reserved.
@@ -155,10 +154,6 @@ Returns 1. Use vlan indexing.
=back
=head2 Global Methods imported from SNMP::Info::CiscoAgg
See documentation in L<SNMP::Info::CiscoAgg/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::CiscoPortSecurity
See documentation in L<SNMP::Info::CiscoPortSecurity/"GLOBALS"> for details.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Contivity
# $Id$
#
# Copyright (c) 2010 Eric Miller
# All rights reserved.
@@ -31,13 +30,12 @@
package SNMP::Info::Layer3::Contivity;
use strict;
use warnings;
use Exporter;
use SNMP::Info;
use SNMP::Info::Layer3;
use SNMP::Info::Entity;
@SNMP::Info::Layer3::Contivity::ISA
= qw/SNMP::Info SNMP::Info::Layer3 SNMP::Info::Entity Exporter/;
= qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Contivity::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE);
@@ -45,22 +43,19 @@ our ($VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE);
$VERSION = '3.68';
%MIBS = (
%SNMP::Info::MIBS, %SNMP::Info::Layer3::MIBS, %SNMP::Info::Entity::MIBS,
%SNMP::Info::Layer3::MIBS,
);
%GLOBALS = (
%SNMP::Info::GLOBALS, %SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::Entity::GLOBALS,
%SNMP::Info::Layer3::GLOBALS,
);
%FUNCS = (
%SNMP::Info::FUNCS, %SNMP::Info::Layer3::FUNCS,
%SNMP::Info::Entity::FUNCS,
%SNMP::Info::Layer3::FUNCS,
);
%MUNGE = (
%SNMP::Info::MUNGE, %SNMP::Info::Layer3::MUNGE,
%SNMP::Info::Entity::MUNGE,
%SNMP::Info::Layer3::MUNGE,
);
sub layers {
@@ -189,21 +184,12 @@ Eric Miller
Abstraction subclass for Avaya/Nortel VPN Routers (formerly Contivity
Extranet Switch).
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $contivity = new SNMP::Info::Layer3::Contivity(...);
=head2 Inherited Classes
=over
=item SNMP::Info
=item SNMP::Info::Layer3
=item SNMP::Info::Entity
=back
=head2 Required MIBs
@@ -212,12 +198,8 @@ after determining a more specific class using the method above.
=item Inherited Classes' MIBs
See L<SNMP::Info/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::Entity/"Required MIBs"> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -238,7 +220,7 @@ Returns the chassis name.
=item $contivity->os()
Returns C<'CES'>
Returns C<'contivity'>
=item $contivity->os_ver()
@@ -267,18 +249,10 @@ layers.
=back
=head2 Globals imported from SNMP::Info
See documentation in L<SNMP::Info/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::Layer3
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::Entity
See documentation in L<SNMP::Info::Entity/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -299,16 +273,8 @@ Interface Name field. Skips loopback and tunnel interfaces.
=back
=head2 Table Methods imported from SNMP::Info
See documentation in L<SNMP::Info/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::Layer3
See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::Entity
See documentation in L<SNMP::Info::Entity/"TABLE METHODS"> for details.
=cut

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Cumulus
# $Id$
#
# Copyright (c) 2018 Bill Fenner and Oliver Gorwits
# All rights reserved.
@@ -31,14 +30,13 @@
package SNMP::Info::Layer3::Cumulus;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
use SNMP::Info::IEEE802dot3ad 'agg_ports_lag';
@SNMP::Info::Layer3::Cumulus::ISA = qw/
SNMP::Info::IEEE802dot3ad
SNMP::Info::LLDP
SNMP::Info::Layer3
Exporter
/;
@@ -50,7 +48,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::IEEE802dot3ad::MIBS,
'UCD-SNMP-MIB' => 'versionTag',
'NET-SNMP-TC' => 'netSnmpAliasDomain',
@@ -59,7 +56,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'netsnmp_vers' => 'versionTag',
'hrSystemUptime' => 'hrSystemUptime',
'chassis' => 'entPhysicalDescr.1',
@@ -67,17 +63,15 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
%SNMP::Info::IEEE802dot3ad::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
%SNMP::Info::IEEE802dot3ad::MUNGE,
);
sub vendor { return 'Cumulus Networks' }
sub vendor { return 'cumulus networks' }
sub os { return 'cumulus' }
@@ -86,7 +80,7 @@ sub os_ver {
my $descr = $netsnmp->description();
# STRING: "Cumulus Linux version 3.5.1 running on innotek GmbH VirtualBox"
return $1 if ( $descr =~ /^Cumulus Linux.+(\d+\.\d+\.\d+)\s/ );
return $1 if ( defined ($descr) && $descr =~ /^Cumulus Linux.+(\d+\.\d+\.\d+)\s/ );
return;
}
@@ -95,7 +89,9 @@ sub model {
my $chassis = $netsnmp->chassis();
# STRING: "Cumulus Networks VX Chassis"
return $1 if ( $chassis =~ /^Cumulus Networks\s+(.+)/ );
if (defined ($chassis)) {
return $1 if ($chassis =~ /^Cumulus Networks\s+(.+)/);
}
return $netsnmp->SUPER::model();
}
@@ -116,7 +112,7 @@ sub uptime {
# ifDescr is the same for all interfaces in a class, but the ifName is
# unique, so let's use that for port name. If all else fails,
# concatentate ifDesc and ifIndex.
# concatenate ifDesc and ifIndex.
# (code from SNMP/Info/Layer2/Netgear.pm)
sub interfaces {
my $netsnmp = shift;
@@ -218,8 +214,6 @@ Subclass for Cumulus Networks devices
See L<SNMP::Info::Layer3> for its own MIB requirements.
See L<SNMP::Info::LLDP> for its own MIB requirements.
See L<SNMP::Info::IEEE802dot3ad> for its own MIB requirements.
=back
@@ -232,7 +226,7 @@ These are methods that return scalar value from SNMP
=item $cumulus->vendor()
Returns 'Cumulus Networks'.
Returns 'cumulus networks'.
=item $cumulus->os()
@@ -258,10 +252,6 @@ Returns the chassis type.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head2 Globals imported from SNMP::Info::IEEE802dot3ad
See documentation in L<SNMP::Info::IEEE802dot3ad> for details.
@@ -295,10 +285,6 @@ ifIndex of the corresponding master ports.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head2 Table Methods imported from SNMP::Info::IEEE802dot3ad
See documentation in L<SNMP::Info::IEEE802dot3ad> for details.

View File

@@ -29,11 +29,11 @@
package SNMP::Info::Layer3::DLink;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::DLink::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::DLink::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::DLink::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE);
@@ -42,7 +42,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
'DLINK-ID-REC-MIB' => 'dlink',
'SWPRIMGMT-DES3200-MIB' => 'dlink-des3200SeriesProd',
'SWPRIMGMT-DES30XXP-MIB' => 'dlink-des30xxproductProd',
@@ -54,17 +53,14 @@ $VERSION = '3.68';
'DES-1210-52-BX' => 'des-1210-52bx',
'DES-1210-52-CX' => 'des-1210-52-cx',
'DGS-1210-24-AX' => 'dgs-1210-24ax',
);
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
'dlink_fw' => 'probeSoftwareRev',
'dlink_hw' => 'probeHardwareRev',
# Replaced with OID since these MIBs are no longer in the netdisco-mibs
@@ -76,7 +72,7 @@ $VERSION = '3.68';
# replaced similarly and use the library getter methods
);
%MUNGE = ( %SNMP::Info::Layer3::MUNGE, %SNMP::Info::LLDP::MUNGE, );
%MUNGE = ( %SNMP::Info::Layer3::MUNGE, );
sub model {
my $dlink=shift;
@@ -197,7 +193,33 @@ Subclass for DLink devices.
=item SNMP::Info::Layer3
=item SNMP::Info::LLDP
=back
=head2 Required MIBs
=over
=item F<DLINK-ID-REC-MIB>
=item F<SWPRIMGMT-DES3200-MIB>
=item F<SWPRIMGMT-DES30XXP-MIB>
=item F<SWPRIMGMT-DES1228ME-MIB>
=item F<SWDES3528-52PRIMGMT-MIB>
=item F<DES-1210-28-AX>
=item F<DES-1210-10MEbx>
=item F<DES-1210-26MEbx>
=item F<DES-1210-52-BX>
=item F<DES-1210-52-CX>
=item F<DGS-1210-24-AX>
=back
@@ -205,8 +227,6 @@ Subclass for DLink devices.
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=head1 GLOBALS
These are methods that return scalar value from SNMP
@@ -243,8 +263,6 @@ Returns the STP root port.
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -262,6 +280,4 @@ Returns the map between SNMP Interface Identifier (iid) and C<ifName>.
See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Dell - SNMP Interface to Dell devices
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,11 +30,11 @@
package SNMP::Info::Layer3::Dell;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Dell::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Dell::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Dell::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE);
@@ -44,7 +43,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
'RADLAN-COPY-MIB' => 'rlCopySourceLocation',
'RADLAN-Physicaldescription-MIB' => 'rlPhdStackReorder',
'RADLAN-rlInterfaces' => 'rlIfNumOfLoopbackPorts',
@@ -55,14 +53,12 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'dell_os_ver' => 'productIdentificationVersion',
'dell_id_name' => 'productIdentificationDisplayName',
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
# RADLAN-rlInterfaces:swIfTable
'dell_duplex_admin' => 'swIfDuplexAdminMode',
@@ -108,7 +104,7 @@ $VERSION = '3.68';
'dell_fan_desc' => 'rlEnvMonFanStatusDescr',
);
%MUNGE = ( %SNMP::Info::Layer3::MUNGE, %SNMP::Info::LLDP::MUNGE, );
%MUNGE = ( %SNMP::Info::Layer3::MUNGE, );
# Method OverRides
@@ -336,7 +332,7 @@ Eric Miller
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -452,10 +448,6 @@ otherwise uses the Layer3 serial method.
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -528,8 +520,4 @@ Returns nothing to work around incorrect indexing of C<dot1qTpFdbTable>
See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::ERX;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -60,7 +61,7 @@ $VERSION = '3.68';
);
sub vendor {
return "Juniper";
return "juniper";
}
sub model {
@@ -82,7 +83,7 @@ sub os_ver {
my $descr = $ERX->description();
my $os_ver = undef;
if ( $descr =~ /Version : \((.+)\) .+:/ ) {
if ( defined ($descr) && $descr =~ /Version : \((.+)\) .+:/ ) {
$os_ver = $1;
}
@@ -110,7 +111,7 @@ __END__
=head1 NAME
SNMP::Info::Layer3::ERX - SNMP Interface to ERX Layer 3 routers.
SNMP::Info::Layer3::ERX - SNMP Interface to Juniper ERX Layer 3 routers.
=head1 AUTHORS
@@ -161,7 +162,7 @@ These are methods that return scalar value from SNMP
=item $ERX->vendor()
Returns 'Juniper'.
Returns 'juniper'.
=item $ERX->os()

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Enterasys - SNMP Interface to Enterasys devices
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,13 +30,13 @@
package SNMP::Info::Layer3::Enterasys;
use strict;
use warnings;
use Exporter;
use SNMP::Info::MAU;
use SNMP::Info::LLDP;
use SNMP::Info::CDP;
use SNMP::Info::Layer3;
@SNMP::Info::Layer3::Enterasys::ISA = qw/SNMP::Info::MAU SNMP::Info::LLDP
@SNMP::Info::Layer3::Enterasys::ISA = qw/SNMP::Info::MAU
SNMP::Info::CDP SNMP::Info::Layer3
Exporter/;
@SNMP::Info::Layer3::Enterasys::EXPORT_OK = qw//;
@@ -48,24 +47,24 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS, %SNMP::Info::CDP::MIBS,
%SNMP::Info::LLDP::MIBS, %SNMP::Info::MAU::MIBS,
%SNMP::Info::MAU::MIBS,
'ENTERASYS-OIDS-MIB' => 'etsysOidDevice',
);
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS, %SNMP::Info::CDP::GLOBALS,
%SNMP::Info::LLDP::GLOBALS, %SNMP::Info::MAU::GLOBALS,
%SNMP::Info::MAU::GLOBALS,
'mac' => 'dot1dBaseBridgeAddress',
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS, %SNMP::Info::CDP::FUNCS,
%SNMP::Info::LLDP::FUNCS, %SNMP::Info::MAU::FUNCS,
%SNMP::Info::MAU::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE, %SNMP::Info::CDP::MUNGE,
%SNMP::Info::LLDP::MUNGE, %SNMP::Info::MAU::MUNGE,
%SNMP::Info::MAU::MUNGE,
);
sub model {
@@ -267,7 +266,7 @@ Eric Miller
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -280,19 +279,12 @@ Eric Miller
Provides abstraction to the configuration information obtainable from an
Enterasys device through SNMP.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $enterasys = new SNMP::Info::Layer3::Enterasys(...);
=head2 Inherited Classes
=over
=item SNMP::Info::MAU
=item SNMP::Info::LLDP
=item SNMP::Info::CDP
=item SNMP::Info::Layer3
@@ -311,8 +303,6 @@ my $enterasys = new SNMP::Info::Layer3::Enterasys(...);
See L<SNMP::Info::MAU/"Required MIBs"> for its MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its MIB requirements.
See L<SNMP::Info::CDP/"Required MIBs"> for its MIB requirements.
See L<SNMP::Info::Layer3/"Required MIBs"> for its MIB requirements.
@@ -352,10 +342,6 @@ Returns base mac
See documentation in L<SNMP::Info::MAU/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::CDP
See documentation in L<SNMP::Info::CDP/"GLOBALS"> for details.
@@ -427,10 +413,6 @@ supply a partial value of zero which means no time filter.
See documentation in L<SNMP::Info::MAU/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::CDP
See documentation in L<SNMP::Info::CDP/"TABLE METHODS"> for details.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Extreme - SNMP Interface to Extreme devices
# $Id$
#
# Copyright (c) 2012 Eric Miller
#
@@ -33,14 +32,14 @@
package SNMP::Info::Layer3::Extreme;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::MAU;
use SNMP::Info::LLDP;
use SNMP::Info::EDP;
@SNMP::Info::Layer3::Extreme::ISA
= qw/SNMP::Info::Layer3 SNMP::Info::MAU SNMP::Info::LLDP
= qw/SNMP::Info::Layer3 SNMP::Info::MAU
SNMP::Info::EDP Exporter/;
@SNMP::Info::Layer3::Extreme::EXPORT_OK = qw//;
@@ -51,7 +50,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::MAU::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::EDP::MIBS,
'EXTREME-BASE-MIB' => 'extremeAgent',
'EXTREME-SYSTEM-MIB' => 'extremeSystem',
@@ -64,7 +62,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::MAU::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
%SNMP::Info::EDP::GLOBALS,
'serial1' => 'extremeSystemID.0',
'temp' => 'extremeCurrentTemperature',
@@ -78,7 +75,6 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::MAU::FUNCS,
%SNMP::Info::LLDP::FUNCS,
%SNMP::Info::EDP::FUNCS,
'fan_state' => 'extremeFanOperational',
# EXTREME-FDB-MIB:extremeFdbMacFdbTable
@@ -119,7 +115,6 @@ $VERSION = '3.68';
# Inherit all the built in munging
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::MAU::MUNGE,
%SNMP::Info::LLDP::MUNGE,
%SNMP::Info::EDP::MUNGE,
'ex_fw_mac' => \&SNMP::Info::munge_mac,
'ps1_status_old' => \&munge_true_ok,
@@ -166,7 +161,6 @@ sub vendor {
sub os {
my $extreme = shift;
my $desc = $extreme->description();
if ( $desc =~ /xos/i ) {
@@ -905,11 +899,6 @@ Eric Miller, Bill Fenner
Provides abstraction to the configuration information obtainable from an
Extreme device through SNMP.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $extreme = new SNMP::Info::Layer3::Extreme(...);
=head2 Inherited Classes
=over
@@ -918,8 +907,6 @@ my $extreme = new SNMP::Info::Layer3::Extreme(...);
=item SNMP::Info::MAU
=item SNMP::Info::LLDP
=item SNMP::Info::EDP
=back
@@ -1014,10 +1001,6 @@ See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
See documentation in L<SNMP::Info::MAU/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head2 Globals imported from SNMP::Info::EDP
See documentation in L<SNMP::Info::EDP/"GLOBALS"> for details.
@@ -1228,10 +1211,6 @@ See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
See documentation in L<SNMP::Info::MAU/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::EDP
See documentation in L<SNMP::Info::EDP/"TABLE METHODS"> for details.

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::F5;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -321,11 +322,6 @@ Eric Miller
Abstraction subclass for F5 network devices.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $f5 = new SNMP::Info::Layer3::F5(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Force10
# $Id$
#
# Copyright (c) 2012 William Bulley
# All rights reserved.
@@ -31,13 +30,13 @@
package SNMP::Info::Layer3::Force10;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::MAU;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Force10::ISA = qw/SNMP::Info::LLDP SNMP::Info::MAU
@SNMP::Info::Layer3::Force10::ISA = qw/SNMP::Info::MAU
SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Force10::EXPORT_OK = qw//;
@@ -48,26 +47,22 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::MAU::MIBS,
%SNMP::Info::LLDP::MIBS,
'F10-PRODUCTS-MIB' => 'f10ESeriesProducts',
);
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::MAU::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::MAU::FUNCS,
%SNMP::Info::LLDP::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::MAU::MUNGE,
%SNMP::Info::LLDP::MUNGE,
);
# use MAU-MIB for admin. duplex and admin. speed
@@ -202,8 +197,6 @@ Subclass for Force10 Networks FTOS-based devices.
=item SNMP::Info::MAU
=item SNMP::Info::LLDP
=back
=head2 Required MIBs
@@ -218,8 +211,6 @@ See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::MAU/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -254,10 +245,6 @@ See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
See documentation in L<SNMP::Info::MAU/"GLOBALS"> for details.
=head2 Global Methods imported from SNMP::Info::Layer3
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -291,8 +278,4 @@ See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
See documentation in L<SNMP::Info::MAU/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::Fortinet;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -150,11 +151,6 @@ Eric Miller
Abstraction subclass for Fortinet network devices.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $fortinet = new SNMP::Info::Layer3::Fortinet(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Foundry - SNMP Interface to Foundry devices
# $Id$
#
# Copyright (c) 2008 Max Baker changes from version 0.8 and beyond.
#
@@ -33,14 +32,13 @@
package SNMP::Info::Layer3::Foundry;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::FDP;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Foundry::ISA = qw/
SNMP::Info::FDP
SNMP::Info::LLDP
SNMP::Info::Layer3
Exporter
/;
@@ -52,7 +50,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::FDP::MIBS,
'FOUNDRY-SN-ROOT-MIB' => 'foundry',
@@ -65,7 +62,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
%SNMP::Info::FDP::GLOBALS,
'mac' => 'ifPhysAddress.1',
@@ -81,7 +77,6 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
%SNMP::Info::FDP::FUNCS,
# FOUNDRY-SN-SWITCH-GROUP-MIB
@@ -119,7 +114,6 @@ $VERSION = '3.68';
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
%SNMP::Info::FDP::MUNGE,
'ag_mod2_type' => \&SNMP::Info::munge_e_type,
@@ -304,7 +298,7 @@ sub interfaces {
# NetIron CES, NetIron CER, and older EdgeIron series devices.
# Try Entity MIB methods first and fall back to Pseudo ENTITY-MIB methods for
# other devices.
# e_fwver, e_hwver, e_swver not supported in psuedo methods, no need to
# e_fwver, e_hwver, e_swver not supported in pseudo methods, no need to
# override
sub e_index {
@@ -866,7 +860,7 @@ Max Baker
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -876,12 +870,8 @@ Max Baker
=head1 DESCRIPTION
Abstraction subclass for Brocade (Foundry) Networks devices.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $foundry = new SNMP::Info::Layer3::Foundry(...);
Provides abstraction to information obtainable from Brocade (Foundry) Networks
devices through SNMP. See inherited classes' documentation for inherited methods.
=head2 Inherited Classes
@@ -891,8 +881,6 @@ after determining a more specific class using the method above.
=item SNMP::Info::FDP;
=item SNMP::Info::LLDP;
=back
=head2 Required MIBs
@@ -917,8 +905,6 @@ See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::FDP/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -1007,10 +993,6 @@ See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
See documentation in L<SNMP::Info::FDP/"GLOBALS"> for details.
=head2 Global Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a
@@ -1275,8 +1257,4 @@ See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
See documentation in L<SNMP::Info::FDP/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -29,6 +29,7 @@
package SNMP::Info::Layer3::Genua;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -85,14 +86,15 @@ sub model {
my $genua_model = $genua->genua_model();
if ( $genua_model =~ m/GeNUA.+(GS.+?)\s/i ) {
if (defined $genua_model) {
if ($genua_model =~ m/GeNUA.+(GS.+?)\s/i) {
$genua_model = $1;
}
elsif ( $genua_model =~ m/genua\s+(.+?)\s+/i ) {
}
elsif ($genua_model =~ m/genua\s+(.+?)\s+/i) {
$genua_model = $1;
}
else {
$genua_model = 'unknown';
}
} else {
$genua_model = 'unknown';
}
return $genua_model;
}
@@ -121,7 +123,7 @@ Netdisco Developers
Debug => 1,
DestHost => 'myhub',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";

View File

@@ -30,14 +30,13 @@
package SNMP::Info::Layer3::H3C;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
use SNMP::Info::IEEE802dot3ad 'agg_ports_lag';
@SNMP::Info::Layer3::H3C::ISA = qw/
SNMP::Info::IEEE802dot3ad
SNMP::Info::LLDP
SNMP::Info::Layer3
Exporter
/;
@@ -51,7 +50,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::IEEE802dot3ad::MIBS,
'HH3C-LswDEVM-MIB' => 'hh3cDevMFanStatus',
'HH3C-LswINF-MIB' => 'hh3cSlotPortMax',
@@ -62,7 +60,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'fan' => 'hh3cDevMFanStatus.1',
'ps1_status' => 'hh3cDevMPowerStatus.1',
'ps2_status' => 'hh3cDevMPowerStatus.2',
@@ -70,21 +67,19 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
%SNMP::Info::IEEE802dot3ad::FUNCS,
i_duplex_admin => 'hh3cifEthernetDuplex',
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
%SNMP::Info::IEEE802dot3ad::MUNGE,
);
sub vendor {
my $h3c = shift;
my $mfg = $h3c->entPhysicalMfgName(1) || {};
return $mfg->{1} || "H3C";
return $mfg->{1} || "h3c";
}
sub model {
@@ -177,7 +172,7 @@ Subclass for H3C & HP A-series devices
=item SNMP::Info::Layer3
=item SNMP::Info::LLDP
=item SNMP::Info::IEEE802dot3ad
=back
@@ -201,8 +196,6 @@ See L<SNMP::Info::IEEE802dot3ad> for its own MIB requirements.
See L<SNMP::Info::Layer3> for its own MIB requirements.
See L<SNMP::Info::LLDP> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -234,9 +227,9 @@ C<sysDescr>.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Globals imported from SNMP::Info::LLDP
=head2 Globals imported from SNMP::Info::IEEE802dot3ad
See documentation in L<SNMP::Info::LLDP> for details.
See documentation in L<SNMP::Info::IEEE802dot3ad> for details.
=head1 TABLE ENTRIES
@@ -265,10 +258,6 @@ ifIndex of the corresponding master ports.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head2 Table Methods imported from SNMP::Info::IEEE802dot3ad
See documentation in L<SNMP::Info::IEEE802dot3ad> for details.

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::HP9300 - SNMP Interface to HP Foundry OEM devices
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,12 +30,12 @@
package SNMP::Info::Layer3::HP9300;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::FDP;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::HP9300::ISA = qw/SNMP::Info::FDP SNMP::Info::LLDP
@SNMP::Info::Layer3::HP9300::ISA = qw/SNMP::Info::FDP
SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::HP9300::EXPORT_OK = qw//;
@@ -46,7 +45,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
%SNMP::Info::FDP::MIBS,
'HP-SN-ROOT-MIB' => 'hp',
'HP-SN-AGENT-MIB' => 'snChasPwrSupplyDescription',
@@ -55,7 +53,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
%SNMP::Info::FDP::GLOBALS,
'mac' => 'ifPhysAddress.1',
'chassis' => 'entPhysicalDescr.1',
@@ -68,7 +65,6 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
%SNMP::Info::FDP::FUNCS,
# HP-SN-SWITCH-GROUP-MIB
@@ -82,7 +78,7 @@ $VERSION = '3.68';
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE, %SNMP::Info::LLDP::MUNGE,
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::FDP::MUNGE,
);
@@ -215,7 +211,7 @@ Eric Miller
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -228,11 +224,6 @@ Eric Miller
Abstraction subclass for HP network devices which Foundry Networks was the
Original Equipment Manufacturer (OEM) such as the HP ProCurve 9300 series.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $hp9300 = new SNMP::Info::Layer3::HP9300(...);
=head2 Inherited Classes
=over
@@ -241,8 +232,6 @@ after determining a more specific class using the method above.
=item SNMP::Info::FDP;
=item SNMP::Info::LLDP;
=back
=head2 Required MIBs
@@ -261,8 +250,6 @@ See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::FDP/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -286,7 +273,7 @@ Returns 'hp'
=item $hp9300->os_ver()
Returns the software version
Returns the software version.
=item $hp9300->mac()
@@ -338,10 +325,6 @@ See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
See documentation in L<SNMP::Info::FDP/"GLOBALS"> for details.
=head2 Global Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -407,8 +390,4 @@ See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
See documentation in L<SNMP::Info::FDP/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::Huawei;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::IEEE802dot3ad;
@@ -111,14 +112,14 @@ $VERSION = '3.68';
);
sub vendor {
return "Huawei";
return "huawei";
}
sub os {
my $huawei = shift;
my $descr = $huawei->description();
if ( $descr =~ /\b(VRP)\b/ ) {
if ( defined ($descr) && $descr =~ /\b(VRP)\b/ ) {
return $1;
}
return "huawei";
@@ -135,7 +136,7 @@ sub os_ver {
my $descr = $huawei->description();
my $os_ver = undef;
if ($descr =~ /Version\s # Start match on Version string
if (defined ($descr) && $descr =~ /Version\s # Start match on Version string
([\d\.]+) # Capture the primary version in 1
,? # There may be a comma
\s # Always a space
@@ -570,7 +571,7 @@ These are methods that return scalar value from SNMP
=item $huawei->vendor()
Returns 'Huawei'.
Returns 'huawei'.
=item $huawei->os()

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::IBMGbTor - SNMP Interface to IBM Rackswitch devices
# $Id$
#
# Copyright (c) 2013 Eric Miller
# All rights reserved.
@@ -31,9 +30,9 @@
package SNMP::Info::Layer3::IBMGbTor;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::IBMGbTor::ISA
= qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@@ -255,7 +254,7 @@ Eric Miller
Debug => 1,
DestHost => 'myswitch',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -269,11 +268,6 @@ Abstraction subclass for IBM Rackswitch (formerly Blade Network Technologies)
network devices. Lenovo acquired these from IBM and is now selling
them under the Lenovo brand.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $ibm = new SNMP::Info::Layer3::IBMGbTor(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Juniper
# $Id$
#
# Copyright (c) 2008 Bill Fenner
# All rights reserved.
@@ -31,11 +30,11 @@
package SNMP::Info::Layer3::Juniper;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Juniper::ISA = qw/SNMP::Info::Layer3 SNMP::Info::LLDP Exporter/;
@SNMP::Info::Layer3::Juniper::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Juniper::EXPORT_OK = qw//;
our ($VERSION, $DEBUG, %GLOBALS, %MIBS, %FUNCS, %MUNGE);
@@ -44,7 +43,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
'JUNIPER-CHASSIS-DEFINES-MIB' => 'jnxChassisDefines',
'JUNIPER-MIB' => 'jnxBoxAnatomy',
'JUNIPER-VIRTUALCHASSIS-MIB' => 'jnxVirtualChassisMemberTable',
@@ -54,7 +52,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'serial' => 'jnxBoxSerialNo',
'mac' => 'dot1dBaseBridgeAddress',
'box_descr' => 'jnxBoxDescr',
@@ -64,7 +61,6 @@ $VERSION = '3.68';
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
# JUNIPER-VLAN-MIB::jnxExVlanPortGroupTable
'i_trunk' => 'jnxExVlanPortAccessMode',
@@ -91,7 +87,6 @@ $VERSION = '3.68';
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
'e_containers_type' => \&SNMP::Info::munge_e_type,
'e_contents_type' => \&SNMP::Info::munge_e_type,
);
@@ -143,10 +138,10 @@ sub model {
my $l3 = shift;
my $id = $l3->id();
# Query the junos device model.
my $mod = uc $l3->vc_model() || '';
my $mod = $l3->vc_model() || '';
if (not $mod eq '') {
return $mod;
if (not $mod eq '') {
return uc $mod;
}
# Fallback to old method
unless ( defined $id ) {
@@ -710,8 +705,6 @@ Subclass for Juniper Devices running JUNOS
=item SNMP::Info::Layer3
=item SNMP::Info::LLDP
=back
=head2 Required MIBs
@@ -734,8 +727,6 @@ Subclass for Juniper Devices running JUNOS
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=head1 GLOBALS
These are methods that return scalar value from SNMP
@@ -798,10 +789,6 @@ The name, model, or detailed description of the device.
See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
=head2 Global Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"GLOBALS"> for details.
=head1 TABLE METHODS
These are methods that return tables of information in the form of a reference
@@ -917,8 +904,4 @@ BOOLEAN. Is a Field Replaceable unit?
See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Lantronix
# $Id$
#
# Copyright (c) 2012 J R Binks
#
@@ -30,6 +29,7 @@
package SNMP::Info::Layer3::Lantronix;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -74,13 +74,14 @@ sub vendor {
sub os {
my $device = shift;
my $descr = $device->description() || '';
my $os;
# On EDS, it is called the "Evolution OS"
# Not sure what, if any, name it has a name on other products
$os = 'EvolutionOS' if ( $descr =~ m/Lantronix EDS\w+ V([\d\.R]+)/ );
return 'LantronixOS';
if ( $descr =~ m/Lantronix EDS\w+ V([\d\.R]+)/ ) {
return 'EvolutionOS';
} else {
return 'LantronixOS';
}
}
sub os_ver {
@@ -213,7 +214,7 @@ Returns 'lantronix'.
=item $device->os()
Returns 'EvolutionOS' for EDS devices.
Returns 'EvolutionOS' for EDS devices, else returns 'LantronixOS'.
=item $device->os_ver()
@@ -246,16 +247,6 @@ See documentation in L<SNMP::Info::Layer3/"GLOBALS"> for details.
These are methods that return tables of information in the form of a reference
to a hash.
=head2 Overrides
=over
=item $device->i_ignore()
Returns reference to hash. Increments value of IID if port is to be ignored.
=back
=head2 Lantronix specific items
None at present.

View File

@@ -62,7 +62,6 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::IEEE802dot3ad::GLOBALS,
# no way to get os version and other device details
# ENTITY-MIB however can help out
'os_ver' => 'entPhysicalSoftwareRev.1',

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Microsoft
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::Microsoft;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -96,7 +96,7 @@ __END__
=head1 NAME
SNMP::Info::Layer3::Microsoft - SNMP Interface to L3 Microsoft Windows router
SNMP::Info::Layer3::Microsoft - SNMP Interface to L3 Microsoft Windows routers
=head1 AUTHOR
@@ -110,7 +110,7 @@ begemot
Debug => 1,
DestHost => 'myrouter',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Mikrotik
# $Id$
#
# Copyright (c) 2011 Jeroen van Ingen
# All rights reserved.
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::Mikrotik;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::N1600 - SNMP Interface to Nortel N16XX devices
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::N1600;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::SONMP;
@@ -202,11 +202,6 @@ Eric Miller
Provides abstraction to the configuration information obtainable from an
Avaya/Nortel N16XX device through SNMP.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $n1600 = new SNMP::Info::Layer3::N1600(...);
=head2 Inherited Classes
=over

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::NetSNMP
# $Id$
#
# Copyright (c) 2008 Bill Fenner
# All rights reserved.
@@ -31,11 +30,11 @@
package SNMP::Info::Layer3::NetSNMP;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::NetSNMP::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::NetSNMP::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::NetSNMP::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %MIBS, %FUNCS, %MUNGE);
@@ -44,7 +43,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
'UCD-SNMP-MIB' => 'versionTag',
'NET-SNMP-TC' => 'netSnmpAliasDomain',
'HOST-RESOURCES-MIB' => 'hrSystem',
@@ -52,19 +50,16 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
'netsnmp_vers' => 'versionTag',
'hrSystemUptime' => 'hrSystemUptime',
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
);
sub vendor {
@@ -182,8 +177,6 @@ Subclass for Generic Net-SNMP devices
See L<SNMP::Info::Layer3> for its own MIB requirements.
See L<SNMP::Info::LLDP> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -221,10 +214,6 @@ Returns ''.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head1 TABLE ENTRIES
These are methods that return tables of information in the form of a reference
@@ -246,10 +235,6 @@ Ignores loopback
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head1 NOTES
In order to cause SNMP::Info to classify your device into this class, it

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::Netscreen;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::IEEE802dot11;
@@ -537,12 +538,7 @@ Kent Hamilton
=head1 DESCRIPTION
Provides abstraction to the configuration information obtainable from a
Juniper Netscreen devices through SNMP.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $netscreen = new SNMP::Info::Layer3::Netscreen(...);
Juniper Netscreen device through SNMP.
=head2 Inherited Classes

View File

@@ -55,7 +55,7 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::CiscoSwitch::MIBS,
'CISCO-ENTITY-VENDORTYPE-OID-MIB' => 'cevMIBObjects',
'CISCO-CONTEXT-MAPPING-MIB' => 'cContextMappingMIBObjects',
'CISCO-CONTEXT-MAPPING-MIB' => 'cContextMappingMIBObjects',
);
%GLOBALS = (

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::OneAccess;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -67,7 +68,7 @@ $VERSION = '3.68';
# notes:
# duplex: oneos v5 has dot3StatsDuplexStatus but it always seems to
# return 0 so useless. oneos v6 no longer has any info.
# macsuck: bridge-mib and oneaccess mibs didn't return useable data
# macsuck: bridge-mib and oneaccess mibs didn't return usable data
# arpnip: oneos v5 returns usable data from ip-mib & rfc1213 which is
# usable, both version support ip-forward-mib but this does not by
# itself provide enough data to be usable. v6 even fails for the

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::PacketFront
# $Id$
#
# Copyright (c) 2011 Jeroen van Ingen
# All rights reserved.
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::PacketFront;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -112,7 +112,7 @@ sub layers {
my $pfront = shift;
my $layers = $pfront->SUPER::layers();
# Some models or softwware versions don't report L2 properly
# Some models or software versions don't report L2 properly
# so add L2 capability to the output if the device has bridge ports.
my $bports = $pfront->b_ports();

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::PaloAlto;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -52,7 +53,7 @@ $VERSION = '3.68';
# Oids from PAN-COMMON-MIB.
'os_ver' => 'panSysSwVersion',
'serial1' => 'panSysSerialNumber',
'pa_model' => 'panChassisType'
'pa_model' => 'panChassisType',
);
%FUNCS = (
@@ -64,7 +65,7 @@ $VERSION = '3.68';
);
sub vendor {
return 'Palo Alto Networks';
return 'palo alto networks';
}
sub model {
@@ -142,11 +143,11 @@ These are methods that return scalar value from SNMP
=item $pa->vendor()
Returns C<'Palo Alto Networks'>.
Returns C<'palo alto networks'>.
=item $pa->os()
Returns C<'PANOS'>.
Returns C<'PAN-OS'>.
=item $pa->model()

View File

@@ -713,7 +713,7 @@ sub e_index {
my $model = $passport->model();
my $rc_ps_t = $passport->rc_ps_type() || {};
# We're going to hack an index: Slot/Mda/Postion
# We're going to hack an index: Slot/Mda/Position
# We're going to put chassis and power supplies in a slot
# which doesn't exist
my %rc_e_index;

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Pf
# $Id$
#
# Copyright (c) 2010 Max Baker
# All rights reserved.
@@ -31,12 +30,11 @@
package SNMP::Info::Layer3::Pf;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Pf::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Pf::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Pf::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %MIBS, %FUNCS, %MUNGE);
@@ -45,7 +43,6 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
# Enterprise container where BEGEMOT-* lives
'FOKUS-MIB' => 'fokus',
# MIBs used included in Layer3 and above:
@@ -72,21 +69,18 @@ $VERSION = '3.68';
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
);
sub vendor {
return 'FreeBSD';
return 'freebsd';
}
sub model {
@@ -148,7 +142,7 @@ Max Baker
=head1 DESCRIPTION
Subclass for Free-BSD PF-Based devices
Subclass for FreeBSD PF-Based devices
=head1 LLDP Support
@@ -166,8 +160,6 @@ Net-SNMP or not.
=item SNMP::Info::Layer3
=item SNMP::Info::LLDP
=back
=head2 Required MIBs
@@ -180,8 +172,6 @@ Net-SNMP or not.
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
See L<SNMP::Info::LLDP/"Required MIBs"> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -192,7 +182,7 @@ These are methods that return scalar values from SNMP
=item $pf->vendor()
Returns 'FreeBSD'
Returns 'freebsd'
=item $pf->model()
@@ -223,8 +213,4 @@ to a hash.
See documentation in L<SNMP::Info::Layer3/"TABLE METHODS"> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP/"TABLE METHODS"> for details.
=cut

View File

@@ -30,11 +30,11 @@
package SNMP::Info::Layer3::Pica8;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::LLDP;
@SNMP::Info::Layer3::Pica8::ISA = qw/SNMP::Info::LLDP SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Pica8::ISA = qw/SNMP::Info::Layer3 Exporter/;
@SNMP::Info::Layer3::Pica8::EXPORT_OK = qw//;
our ($VERSION, %GLOBALS, %MIBS, %FUNCS, %MUNGE);
@@ -43,26 +43,22 @@ $VERSION = '3.68';
%MIBS = (
%SNMP::Info::Layer3::MIBS,
%SNMP::Info::LLDP::MIBS,
);
%GLOBALS = (
%SNMP::Info::Layer3::GLOBALS,
%SNMP::Info::LLDP::GLOBALS,
);
%FUNCS = (
%SNMP::Info::Layer3::FUNCS,
%SNMP::Info::LLDP::FUNCS,
);
%MUNGE = (
%SNMP::Info::Layer3::MUNGE,
%SNMP::Info::LLDP::MUNGE,
);
sub vendor {
return 'Pica8';
return 'pica8';
}
sub os {
@@ -77,7 +73,9 @@ sub os_ver {
my $pica8 = shift;
my $descr = $pica8->description();
return $1 if ( $descr =~ /Software version ([\d\.]+)/i );
if (defined ($descr)) {
return $1 if ($descr =~ /Software version ([\d\.]+)/i);
}
return;
}
@@ -85,7 +83,9 @@ sub model {
my $pica8 = shift;
my $descr = $pica8->description();
return $1 if ( $descr =~ /Hardware model (P-\d{4})/i );
if (defined $descr) {
return $1 if ($descr =~ /Hardware model (P-\d{4})/i);
}
return;
}
@@ -125,8 +125,6 @@ Subclass for Pica8 devices
=item SNMP::Info::Layer3
=item SNMP::Info::LLDP
=back
=head2 Required MIBs
@@ -139,8 +137,6 @@ Subclass for Pica8 devices
See L<SNMP::Info::Layer3> for its own MIB requirements.
See L<SNMP::Info::LLDP> for its own MIB requirements.
=back
=head1 GLOBALS
@@ -151,7 +147,7 @@ These are methods that return scalar value from SNMP
=item $pica8->vendor()
Returns 'Pica8'
Returns 'pica8'
=item $pica8->model()
@@ -171,10 +167,6 @@ Returns the OS version extracted from C<sysDescr>.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Globals imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=head1 TABLE ENTRIES
These are methods that return tables of information in the form of a reference
@@ -184,8 +176,4 @@ to a hash.
See documentation in L<SNMP::Info::Layer3> for details.
=head2 Table Methods imported from SNMP::Info::LLDP
See documentation in L<SNMP::Info::LLDP> for details.
=cut

View File

@@ -28,6 +28,7 @@ package SNMP::Info::Layer3::SonicWALL;
# POSSIBILITY OF SUCH DAMAGE.
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -56,7 +57,7 @@ $VERSION = '3.68';
%MUNGE = ( %SNMP::Info::Layer2::MUNGE, %SNMP::Info::Layer3::MUNGE, );
sub vendor {
return 'SonicWALL';
return 'sonicwall';
}
sub os {
@@ -107,7 +108,7 @@ phishphreek@gmail.com
Debug => 1,
DestHost => 'myrouter',
Community => 'public',
Version => 1
Version => 2
)
or die "Can't connect to DestHost.\n";
@@ -130,6 +131,8 @@ Subclass for Generic SonicWALL Firewalls
=over
=item F<SNWL-COMMON-MIB>
=item Inherited Classes' MIBs
See L<SNMP::Info::Layer3/"Required MIBs"> for its own MIB requirements.
@@ -146,7 +149,7 @@ These are methods that return scalar value from SNMP
=item $router->vendor()
Returns C<'SonicWALL'>
Returns C<'sonicwall'>
=item $router->os()
@@ -154,11 +157,11 @@ Returns C<'SonicOS'>
=item $router->os_ver()
Returns '4.2.0.0-10e'
Returns C<'snwlSysFirmwareVersion'>
=item $router->model()
Returns C<'PRO 3060 Enhanced'>
Returns C<'snwlSysModel'>
=item $router->serial()

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::Steelhead;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
@@ -132,10 +133,6 @@ Eric Miller
Abstraction subclass for Riverbed Steelhead WAN optimization appliances.
For speed or debugging purposes you can call the subclass directly, but not
after determining a more specific class using the method above.
my $riverbed = new SNMP::Info::Layer3::Steelhead(...);
=head2 Inherited Classes

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Sun
# $Id$
#
# Copyright (c) 2008 Eric Miller
# All rights reserved.
@@ -31,6 +30,7 @@
package SNMP::Info::Layer3::Sun;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;

View File

@@ -102,7 +102,7 @@ my $module_map = {
DS3_1C => '1-port Channelized T3',
WTE_1 => '1-port T1/E1 w DS0 and DS1 support for both TDM and Packet',
WTE_2S => '2-port Sync and Async Serial',
WTE_8 => '8-port T1/E1'
WTE_8 => '8-port T1/E1',
};
sub vendor {

View File

@@ -1,5 +1,4 @@
# SNMP::Info::Layer3::Timetra
# $Id$
#
# Copyright (c) 2008 Bill Fenner
#
@@ -30,7 +29,7 @@
package SNMP::Info::Layer3::Timetra;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::Aggregate;
@@ -120,7 +119,7 @@ sub model {
my $str;
if ( $descr =~ /\s+(7\d{3})/ ) {
if ( defined ($descr) && $descr =~ /\s+(7\d{3})/ ) {
$str = $1;
}
@@ -146,7 +145,7 @@ sub os_ver {
my $timetra = shift;
my $descr = $timetra->description();
if ( $descr =~ m/^TiMOS-(\S+)/x ) {
if ( defined ($descr) && $descr =~ m/^TiMOS-(\S+)/x ) {
return $1;
}
return;
@@ -454,7 +453,7 @@ These are methods that return scalar value from SNMP
=item $alu->vendor()
Returns 'alcatel-lucent'
Returns 'nokia'
=item $alu->os()

View File

@@ -30,6 +30,7 @@
package SNMP::Info::Layer3::VMware;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;
use SNMP::Info::IEEE802dot3ad 'agg_ports_lag';
@@ -167,7 +168,6 @@ Returns the software version specified as major-update.patch.build (ex. 5.1.0-3
(C<vmwProdVersion>)-(C<vmwProdUpdate>).(C<vmwProdPatch>).(C<vmwProdBuild>)
=back
=head2 Globals imported from SNMP::Info::Layer3

View File

@@ -31,6 +31,7 @@ package SNMP::Info::Layer3::VyOS;
use strict;
use warnings;
use Exporter;
use SNMP::Info::Layer3;