summaryrefslogtreecommitdiffstats
path: root/usr/local/www/vpn_ipsec_phase2.php
diff options
context:
space:
mode:
authorSeth Mos <seth.mos@xs4all.nl>2009-03-12 19:48:45 +0100
committerSeth Mos <seth.mos@xs4all.nl>2009-03-12 19:48:45 +0100
commite92fb875e974a1e1a65f909b9987daa494367459 (patch)
tree979b546cfbc06b14e18c8260f602bbbaccb366a8 /usr/local/www/vpn_ipsec_phase2.php
parent287e0c9d27405b88d3727f0edd21b778638dc5b4 (diff)
downloadpfsense-e92fb875e974a1e1a65f909b9987daa494367459.zip
pfsense-e92fb875e974a1e1a65f909b9987daa494367459.tar.gz
Reload phase2 tunnel items when adding, remoing or editing a phase 2 entry.
Diffstat (limited to 'usr/local/www/vpn_ipsec_phase2.php')
-rw-r--r--usr/local/www/vpn_ipsec_phase2.php9
1 files changed, 9 insertions, 0 deletions
diff --git a/usr/local/www/vpn_ipsec_phase2.php b/usr/local/www/vpn_ipsec_phase2.php
index 6ca7a7a..a18a1de 100644
--- a/usr/local/www/vpn_ipsec_phase2.php
+++ b/usr/local/www/vpn_ipsec_phase2.php
@@ -64,6 +64,7 @@ if (isset($p2index) && $a_phase2[$p2index])
$pconfig['ikeid'] = $a_phase2[$p2index]['ikeid'];
$pconfig['disabled'] = isset($a_phase2[$p2index]['disabled']);
$pconfig['descr'] = $a_phase2[$p2index]['descr'];
+ $old_ph2ent = $a_phase2[$p2index];
idinfo_to_pconfig("local",$a_phase2[$p2index]['localid'],$pconfig);
idinfo_to_pconfig("remote",$a_phase2[$p2index]['remoteid'],$pconfig);
@@ -170,6 +171,14 @@ if ($_POST) {
else
$a_phase2[] = $ph2ent;
+
+ /* now we need to find all phase2 entries for this host */
+ if(is_array($ph2ent)) {
+ ipsec_lookup_phase1($ph2ent, $ph1ent);
+ $old_ph1ent = $ph1ent;
+ reload_tunnel_spd_policy ($ph1ent, $ph2ent, $old_ph1ent, $old_ph2ent);
+ }
+
write_config();
touch($d_ipsecconfdirty_path);
OpenPOWER on IntegriCloud