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))