Add CISCO-PAE-MIB (Kesy)
This commit is contained in:
@@ -34,12 +34,13 @@ use strict;
|
||||
|
||||
use Exporter;
|
||||
|
||||
use vars qw/$VERSION %MIBS %FUNCS %GLOBALS %MUNGE/;
|
||||
use vars qw/$VERSION %MIBS %FUNCS %GLOBALS %MUNGE %PAECAPABILITIES/;
|
||||
@SNMP::Info::CiscoPortSecurity::ISA = qw/Exporter/;
|
||||
@SNMP::Info::CiscoPortSecurity::EXPORT_OK = qw//;
|
||||
|
||||
%MIBS = (
|
||||
'CISCO-PORT-SECURITY-MIB' => 'ciscoPortSecurityMIB',
|
||||
'CISCO-PAE-MIB' => 'ciscoPaeMIB',
|
||||
);
|
||||
|
||||
%GLOBALS = (
|
||||
@@ -86,21 +87,35 @@ use vars qw/$VERSION %MIBS %FUNCS %GLOBALS %MUNGE/;
|
||||
'cps_m_age' => 'cpsSecureMacAddrRemainingAge',
|
||||
'cps_m_type' => 'cpsSecureMacAddrType',
|
||||
'cps_m_mac' => 'cpsSecureMacAddress',
|
||||
# CISCO-PAE-MIB::dot1xPaePortEntry
|
||||
'pae_i_capabilities' => 'dot1xPaePortCapabilities',
|
||||
);
|
||||
|
||||
%MUNGE = (
|
||||
'cps_i_mac' => \&SNMP::Info::munge_mac,
|
||||
'cps_m_mac' => \&SNMP::Info::munge_mac,
|
||||
'cps_i_v_mac' => \&SNMP::Info::munge_mac,
|
||||
'pae_i_capabilities' => \&munge_pae_capabilities,
|
||||
);
|
||||
|
||||
%PAECAPABILITIES = (0 => 'dot1xPaePortAuthCapable',
|
||||
1 => 'dot1xPaePortSuppCapable');
|
||||
|
||||
sub munge_pae_capabilities {
|
||||
my $bits = shift;
|
||||
|
||||
return undef unless defined $bits;
|
||||
my @vals = map($PAECAPABILITIES{$_},sprintf("%x",unpack('b*',$bits)));
|
||||
return join(' ',@vals);
|
||||
}
|
||||
|
||||
1;
|
||||
__END__
|
||||
|
||||
=head1 NAME
|
||||
|
||||
SNMP::Info::CiscoPortSecurity - SNMP Interface to data from
|
||||
CISCO-PORT-SECURITY-MIB
|
||||
CISCO-PORT-SECURITY-MIB and CISCO-PAE-MIB
|
||||
|
||||
=head1 AUTHOR
|
||||
|
||||
@@ -125,8 +140,8 @@ Eric Miller
|
||||
=head1 DESCRIPTION
|
||||
|
||||
SNMP::Info::CiscoPortSecurity is a subclass of SNMP::Info that provides
|
||||
an interface to the C<CISCO-PORT-SECURITY-MIB>. This MIB is used across
|
||||
the Catalyst family under CatOS and IOS.
|
||||
an interface to the C<CISCO-PORT-SECURITY-MIB> and C<CISCO-PAE-MIB>. These
|
||||
MIBs are used across the Catalyst family under CatOS and IOS.
|
||||
|
||||
Use or create in a subclass of SNMP::Info. Do not use directly.
|
||||
|
||||
@@ -140,6 +155,8 @@ None.
|
||||
|
||||
=item CISCO-PORT-SECURITY-MIB
|
||||
|
||||
=item CISCO-PAE-MIB
|
||||
|
||||
=back
|
||||
|
||||
MIBs can be found at ftp://ftp.cisco.com/pub/mibs/v2/v2.tar.gz or from
|
||||
@@ -325,4 +342,17 @@ These are methods that return scalar values from SNMP
|
||||
|
||||
=back
|
||||
|
||||
=head2 CISCO-PAE-MIB::dot1xPaePortEntry
|
||||
|
||||
=over
|
||||
|
||||
=item $stack->pae_i_capabilities()
|
||||
|
||||
B<dot1xPaePortCapabilities>
|
||||
|
||||
Indicates the PAE functionality that this Port supports
|
||||
and that may be managed through this MIB.
|
||||
|
||||
=back
|
||||
|
||||
=cut
|
||||
|
||||
Reference in New Issue
Block a user