mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
refactor: OS discovery (w - z) (#4549)
This commit is contained in:
committed by
Tony Murray
parent
b5c181d057
commit
765ee3e1ab
@@ -0,0 +1,5 @@
|
||||
<?php
|
||||
|
||||
if (starts_with($sysDescr, 'WatchGuard Fireware') || starts_with($sysObjectId, '.1.3.6.1.4.1.3097.1.5')) {
|
||||
$os = 'firebox';
|
||||
}
|
||||
@@ -10,6 +10,6 @@
|
||||
* the source code distribution for details.
|
||||
*/
|
||||
|
||||
if (starts_with('Cisco Wide Area Application Services', $sysDescr)) {
|
||||
if (starts_with($sysDescr, 'Cisco Wide Area Application Services')) {
|
||||
$os = 'waas';
|
||||
}
|
||||
|
||||
@@ -1,5 +0,0 @@
|
||||
<?php
|
||||
|
||||
if (starts_with('WatchGuard Fireware', $sysDescr) || starts_with('.1.3.6.1.4.1.3097.1.5', $sysObjectId)) {
|
||||
$os = 'firebox';
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
|
||||
if (str_contains('.1.3.6.1.4.1.2468.1.2.1', $sysObjectId)) {
|
||||
if (str_contains($sysObjectId, '.1.3.6.1.4.1.2468.1.2.1')) {
|
||||
$os = 'webpower';
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
if (starts_with('.1.3.6.1.4.1.311.1.1.3', $sysObjectId)) {
|
||||
if (starts_with($sysObjectId, '.1.3.6.1.4.1.311.1.1.3')) {
|
||||
$os = 'windows';
|
||||
}
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
if (str_contains('NETOS 6.0', $sysDescr)) {
|
||||
if (str_contains($sysDescr, 'NETOS 6.0')) {
|
||||
$os = 'wxgoos';
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
|
||||
if (starts_with('.1.3.6.1.4.1.890', $sysObjectId) && starts_with($sysDescr, array('ES', 'GS'))) {
|
||||
if (starts_with($sysObjectId, '.1.3.6.1.4.1.890') && starts_with($sysDescr, array('ES', 'GS'))) {
|
||||
$os = 'zynos';
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<?php
|
||||
|
||||
if (starts_with('ZyWALL 2X', $sysDescr)) {
|
||||
if (starts_with($sysDescr, 'ZyWALL 2X')) {
|
||||
$os = 'zywall';
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?php
|
||||
|
||||
if (starts_with('NWA-', $sysDescr)) {
|
||||
if (starts_with($sysDescr, 'NWA-')) {
|
||||
$os = 'zyxelnwa';
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user