summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorChris Buechler <cmb@pfsense.org>2015-03-31 15:18:26 -0500
committerChris Buechler <cmb@pfsense.org>2015-03-31 15:18:26 -0500
commit68e322065dfe9907492ffbdb5484934427a998a2 (patch)
tree37feb4da36a355fb7384873159233295c1a23324 /etc
parentd6710783a2a4593ef1058ceaa86304632aae770e (diff)
downloadpfsense-68e322065dfe9907492ffbdb5484934427a998a2.zip
pfsense-68e322065dfe9907492ffbdb5484934427a998a2.tar.gz
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.
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/ipsec.inc12
1 files changed, 8 insertions, 4 deletions
diff --git a/etc/inc/ipsec.inc b/etc/inc/ipsec.inc
index d7cdf2a..aef66fe 100644
--- a/etc/inc/ipsec.inc
+++ b/etc/inc/ipsec.inc
@@ -394,10 +394,14 @@ function ipsec_phase2_status(&$ipsec_status, &$phase2) {
function ipsec_smp_dump_status() {
global $config, $g, $custom_listtags;
- if (!file_exists("{$g['varrun_path']}/charon.xml")) {
- log_error("IPsec daemon not running or has a problem!");
- return;
- }
+ if (isset($config['ipsec']['enable'])) {
+ if (!file_exists("{$g['varrun_path']}/charon.xml")) {
+ log_error("IPsec daemon not running or has a problem!");
+ return;
+ }
+ } else {
+ return;
+ }
$fd = @fsockopen("unix://{$g['varrun_path']}/charon.xml");
if (!$fd) {
OpenPOWER on IntegriCloud