From 2926267e5d01159dce109a5313a45c67c47b3712 Mon Sep 17 00:00:00 2001 From: Adam Amstrong Date: Wed, 11 Aug 2010 00:40:07 +0000 Subject: [PATCH] os discovery debug forced (for now) and extra fortigate detection git-svn-id: http://www.observium.org/svn/observer/trunk@1662 61d68cd4-352d-0410-923a-c4978735b2b8 --- includes/discovery/os/fortigate.inc.php | 3 ++- includes/functions.php | 6 ++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/includes/discovery/os/fortigate.inc.php b/includes/discovery/os/fortigate.inc.php index eb15ac786..6ecc89d7c 100755 --- a/includes/discovery/os/fortigate.inc.php +++ b/includes/discovery/os/fortigate.inc.php @@ -2,7 +2,8 @@ if(!$os) { - if (strstr($sysObjectId, "1.3.6.1.4.1.12356.15")) { $os = "fortigate"; } + if (strstr($sysObjectId, ".1.3.6.1.4.1.12356.15")) { $os = "fortigate"; } + if (strstr($sysObjectId, ".1.3.6.1.4.1.12356.101.1")) { $os = "fortigate"; } } diff --git a/includes/functions.php b/includes/functions.php index 38b94687b..45296c071 100755 --- a/includes/functions.php +++ b/includes/functions.php @@ -93,8 +93,10 @@ function getHostOS($device) { global $config; - $sysDescr = snmp_get ($device, "sysDescr.0", "-Ovq"); - $sysObjectId = snmp_get ($device, "sysObjectID.0", "-Ovqn"); + $sysDescr = snmp_get ($device, "SNMPv2-MIB::sysDescr.0", "-Ovq"); + $sysObjectId = snmp_get ($device, "SNMPv2-MIB::sysObjectID.0", "-Ovqn"); + + echo("| $sysDescr | $sysObjectId | "); $dir_handle = @opendir($config['install_dir'] . "/includes/discovery/os") or die("Unable to open $path"); while ($file = readdir($dir_handle))