summaryrefslogtreecommitdiffstats
path: root/src/usr/local
diff options
context:
space:
mode:
authorChris Buechler <cmb@pfsense.org>2016-03-26 04:15:33 -0500
committerChris Buechler <cmb@pfsense.org>2016-03-26 04:15:33 -0500
commitc5d8cbe07c9646f34afebd2610ac34bed090ced0 (patch)
tree0c9a7e271bd05b61cc1809ea5d4a9ca65a969a4a /src/usr/local
parentfbbaf135193ec9ea384474cc0ac7929dc5f8d0b6 (diff)
downloadpfsense-c5d8cbe07c9646f34afebd2610ac34bed090ced0.zip
pfsense-c5d8cbe07c9646f34afebd2610ac34bed090ced0.tar.gz
Background all the ipsec commands run from status_ipsec.php to make sure they don't hang up the entire GUI. Ticket #5520
Diffstat (limited to 'src/usr/local')
-rw-r--r--src/usr/local/www/status_ipsec.php10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/usr/local/www/status_ipsec.php b/src/usr/local/www/status_ipsec.php
index 5277fbc..282b885 100644
--- a/src/usr/local/www/status_ipsec.php
+++ b/src/usr/local/www/status_ipsec.php
@@ -82,11 +82,11 @@ if ($_GET['act'] == 'connect') {
$ph2entries = ipsec_get_number_of_phase2($_GET['ikeid']);
for ($i = 0; $i < $ph2entries; $i++) {
$connid = escapeshellarg("con{$_GET['ikeid']}00{$i}");
- mwexec("/usr/local/sbin/ipsec down {$connid}");
+ mwexec_bg("/usr/local/sbin/ipsec down {$connid}");
mwexec_bg("/usr/local/sbin/ipsec up {$connid}");
}
} else {
- mwexec("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']));
+ mwexec_bg("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']));
mwexec_bg("/usr/local/sbin/ipsec up con" . escapeshellarg($_GET['ikeid']));
}
}
@@ -94,15 +94,15 @@ if ($_GET['act'] == 'connect') {
} else if ($_GET['act'] == 'ikedisconnect') {
if (ctype_digit($_GET['ikeid'])) {
if (!empty($_GET['ikesaid']) && ctype_digit($_GET['ikesaid'])) {
- mwexec("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']) . "[" . escapeshellarg($_GET['ikesaid']) . "]");
+ mwexec_bg("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']) . "[" . escapeshellarg($_GET['ikesaid']) . "]");
} else {
- mwexec("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']));
+ mwexec_bg("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']));
}
}
} else if ($_GET['act'] == 'childdisconnect') {
if (ctype_digit($_GET['ikeid'])) {
if (!empty($_GET['ikesaid']) && ctype_digit($_GET['ikesaid'])) {
- mwexec("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']) . "{" . escapeshellarg($_GET['ikesaid']) . "}");
+ mwexec_bg("/usr/local/sbin/ipsec down con" . escapeshellarg($_GET['ikeid']) . "{" . escapeshellarg($_GET['ikesaid']) . "}");
}
}
}
OpenPOWER on IntegriCloud