WIP. Eltex hw crap
This commit is contained in:
@@ -17,7 +17,7 @@ our ( $VERSION, %GLOBALS, %FUNCS, %MIBS, %MUNGE );
|
|||||||
|
|
||||||
$VERSION = '3.70-135';
|
$VERSION = '3.70-135';
|
||||||
|
|
||||||
our $index = undef;
|
#our $index = undef;
|
||||||
|
|
||||||
%MIBS = ( %SNMP::Info::Layer3::MIBS, );
|
%MIBS = ( %SNMP::Info::Layer3::MIBS, );
|
||||||
|
|
||||||
@@ -91,19 +91,19 @@ sub os_ver {
|
|||||||
$os_ver = $obj->os_ver_oid_140;
|
$os_ver = $obj->os_ver_oid_140;
|
||||||
return $os_ver;
|
return $os_ver;
|
||||||
}
|
}
|
||||||
if ($id =~ /34300\.1\.6/ or $id =~ /35265\.1\.28/) {
|
if ($id =~ /34300\.1\.6/ or $id =~ /35265\.1\.28$/) {
|
||||||
return $obj->os_ver_oid_mxa;
|
return $obj->os_ver_oid_mxa;
|
||||||
}
|
}
|
||||||
elsif ($id =~ /35265\.1\.(24|43|30|120|5[2,4]|74|8[1,9])$/) {
|
elsif ($id =~ /35265\.1\.(24|43|30|120|5[2,4]|74|8[1,9])$/) {
|
||||||
$os_ver = $obj->os_ver_oid;
|
$os_ver = $obj->os_ver_oid;
|
||||||
$bootrom = $obj->bootrom_oid;
|
$bootrom = $obj->bootrom_oid;
|
||||||
}
|
}
|
||||||
elsif ( $id =~ /35265\.1\.22/ ) {
|
elsif ( $id =~ /35265\.1\.22$/ ) {
|
||||||
my $descr = $obj->descr_oid;
|
my $descr = $obj->descr_oid;
|
||||||
$descr =~ /Eltex\s(.*)\ssoftware\sversion\s(.*)\sbuild\s(\d+)/;
|
$descr =~ /Eltex\s(.*)\ssoftware\sversion\s(.*)\sbuild\s(\d+)/;
|
||||||
return $2;
|
return $2;
|
||||||
}
|
}
|
||||||
elsif ($id =~ /35265\.1\.30/) {
|
elsif ($id =~ /35265\.1\.30$/) {
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@@ -119,13 +119,13 @@ sub serial {
|
|||||||
if ($id =~ /35265\.(140|158)$/) {
|
if ($id =~ /35265\.(140|158)$/) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
elsif ($id =~ /34300\.1\.6/ or $id =~ /35265\.1\.28/) {
|
elsif ($id =~ /34300\.1\.6/ or $id =~ /35265\.1\.28$/) {
|
||||||
return $obj->serial_oid_mxa;
|
return $obj->serial_oid_mxa;
|
||||||
}
|
}
|
||||||
elsif ($id =~ /35265\.1\.(24|43|30|120|5[2,4]|74|8[1,9]])$/) {
|
elsif ($id =~ /35265\.1\.(24|43|30|120|5[2,4]|74|8[1,9]])$/) {
|
||||||
$serial = $obj->serial_oid;
|
$serial = $obj->serial_oid;
|
||||||
}
|
}
|
||||||
elsif ( $id =~ /35265\.1\.22/ ) {
|
elsif ( $id =~ /35265\.1\.22$/ ) {
|
||||||
$serial = $obj->serial_oid_22;
|
$serial = $obj->serial_oid_22;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@@ -137,15 +137,14 @@ sub serial {
|
|||||||
sub hwver {
|
sub hwver {
|
||||||
my $obj = shift;
|
my $obj = shift;
|
||||||
my $id = $obj->id();
|
my $id = $obj->id();
|
||||||
my $hw = $obj->hw_ver();
|
if ($id =~ /35265\.1\.30$/) {
|
||||||
if ($id =~ /35265\.1\.30/) {
|
|
||||||
return $obj->hw_oid_1_30;
|
return $obj->hw_oid_1_30;
|
||||||
}
|
}
|
||||||
elsif($id =~ /35265\.1\.81|5[4,2]/) {
|
elsif($id =~ /35265\.1\.(8[1,9]|5[4,2]|43)$/) {
|
||||||
return $obj->hw_oid_1_81;
|
return $obj->hw_oid_1_81;
|
||||||
}
|
}
|
||||||
else {
|
elsif($id =~ /35265\.158/) {
|
||||||
return $hw;
|
return $obj->hw_oid;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user