Fixed overview graph on Cisco ASA announcing all interfaces in type l2vlan (by default filtered) (#9849)

* Fix ASA announcing all interfaces in l2vlan
* Fix ASA announcing all interfaces in l2vlan
This commit is contained in:
PipoCanaja
2019-03-13 09:04:51 +01:00
committed by GitHub
parent 59f00dcc6b
commit be58ec3b72

View File

@@ -8,6 +8,12 @@ foreach (dbFetchRows('SELECT * FROM `ports` WHERE `device_id` = ? AND `disabled`
$ignore = 0;
if (is_array($config['device_traffic_iftype'])) {
foreach ($config['device_traffic_iftype'] as $iftype) {
if ($iftype == '/l2vlan/' && $device['os']=='asa') {
// ASA (at least in multicontext) reports all interfaces as l2vlan even if they are l3
// so every context has no graph displayed unless l2vlan are accepted for all.
// This patch will ignore l2vlan for ASA.
continue;
}
if (preg_match($iftype.'i', $port['ifType'])) {
$ignore = 1;
}