passing all tests

This commit is contained in:
crcro
2016-09-22 03:58:29 +03:00
parent 631d26563e
commit eadcde9ac0
7 changed files with 22 additions and 18 deletions

View File

@@ -1,5 +1,5 @@
<?php
if (starts_with($sysDescr, array('WatchGuard', '1.3.6.1.4.1.3097.1.5'))) {
if (starts_with('WatchGuard Fireware', $sysDescr) || starts_with('.1.3.6.1.4.1.3097.1.5', $sysObjectId)) {
$os = 'firebox';
}
}

View File

@@ -1,7 +1,9 @@
<?php
if (starts_with('1.3.6.1.4.1.311.1.1.3', $sysObjectId)) {
$os = 'windows';
} elseif (str_contains('Windows', $sysDescr)) {
if (starts_with('.1.3.6.1.4.1.311.1.1.3', $sysObjectId)) {
$os = 'windows';
}
if (str_contains($sysDescr, array('Windows'))) {
$os = 'windows';
}

View File

@@ -1,5 +1,9 @@
<?php
if (str_contains('NETOS 6.0', $sysDescr) && starts_with($sysObjectId, array('.1.3.6.1.4.1.901.1', '.1.3.6.1.4.1.17373'))) {
if (str_contains('NETOS 6.0', $sysDescr)) {
$os = 'wxgoos';
}
if (starts_with($sysObjectId, array('.1.3.6.1.4.1.901.1', '.1.3.6.1.4.1.17373'))) {
$os = 'wxgoos';
}

View File

@@ -1,7 +1,5 @@
<?php
if (str_contains('Xirrus', $sysDescr)) {
if (str_contains('ArrayOS', $sysDescr)) {
$os = 'xirrus_aos';
}
if (str_contains($sysDescr, array('Xirrus', 'ArrayOS'))) {
$os = 'xirrus_aos';
}

View File

@@ -1,7 +1,5 @@
<?php
if (starts_with('ZXR10', $sysDescr)) {
if (str_contains($sysDescr, array('ZXR10', 'ZTE Ethernet Switch'))) {
$os = 'zxr10';
} elseif (str_contains('ZTE Ethernet Switch', $sysDescr)) {
$os = 'zxr10';
}
}

View File

@@ -1,5 +1,5 @@
<?php
if (str_contains('.1.3.6.1.4.1.890', $sysObjectId) && (starts_with($sysDescr, array('EG', 'GS')))) {
if (starts_with('.1.3.6.1.4.1.890', $sysObjectId) && starts_with($sysDescr, array('ES', 'GS'))) {
$os = 'zynos';
}

View File

@@ -1,7 +1,9 @@
<?php
if (str_contains('ZyWALL', $sysDescr)) {
$os = 'zywall';
} elseif (starts_with('.1.3.6.1.4.1.890.1.15', $sysObjectId)) {
if (starts_with('ZyWALL 2X', $sysDescr)) {
$os = 'zywall';
}
if (strstr($sysObjectId, '.1.3.6.1.4.1.890.1.15')) {
$os = 'zywall';
}