Revision 0b34a56c
Added by Chris Buechler over 10 years ago
etc/inc/ipsec.inc | ||
---|---|---|
410 | 410 |
function ipsec_smp_dump_status() { |
411 | 411 |
global $config, $g, $custom_listtags; |
412 | 412 |
|
413 |
if (!file_exists("{$g['varrun_path']}/charon.xml")) { |
|
414 |
log_error("IPsec daemon not running or has a problem!"); |
|
415 |
return; |
|
416 |
} |
|
413 |
if (isset($config['ipsec']['enable'])) { |
|
414 |
if (!file_exists("{$g['varrun_path']}/charon.xml")) { |
|
415 |
log_error("IPsec daemon not running or has a problem!"); |
|
416 |
return; |
|
417 |
} |
|
418 |
} else { |
|
419 |
return; |
|
420 |
} |
|
417 | 421 |
|
418 | 422 |
$fd = @fsockopen("unix://{$g['varrun_path']}/charon.xml"); |
419 | 423 |
if (!$fd) { |
Also available in: Unified diff
Add a check for whether IPsec is enabled, so it doesn't spit out "IPsec
daemon not running or has a problem!" when IPsec isn't enabled.