Fix cipsec-tunnels ftd bad data causes error (#14366)

fixes #12393
This commit is contained in:
Tony Murray
2022-09-18 05:15:38 -05:00
committed by GitHub
parent 9f0b1cafff
commit fb489f61ed

View File

@@ -22,7 +22,7 @@ if ($device['os_group'] == 'cisco') {
$valid_tunnels = [];
foreach ($ipsec_array as $index => $tunnel) {
if (isset($tunnel['cipSecTunIkeTunnelIndex']) && isset($ike_array[$tunnel['cipSecTunIkeTunnelIndex']])) {
if (isset($tunnel['cipSecTunIkeTunnelIndex']) && isset($ike_array[$tunnel['cipSecTunIkeTunnelIndex']]) && is_array($ike_array[$tunnel['cipSecTunIkeTunnelIndex']])) {
$tunnel_full = array_merge($tunnel, $ike_array[$tunnel['cipSecTunIkeTunnelIndex']]);
} else {
$tunnel_full = $tunnel;