Commit b8d27634 authored by Franco Fichtner's avatar Franco Fichtner

vpn/ipsec: collapse tabs into menu

For the first time ever we steal a system log tab and push it to
the respective service.  Invented by OPNsense.  :P
parent 22c9ec78
...@@ -224,13 +224,23 @@ ...@@ -224,13 +224,23 @@
</WoL> </WoL>
</Services> </Services>
<VPN order="5" cssClass="glyphicon glyphicon-lock"> <VPN order="5" cssClass="glyphicon glyphicon-lock">
<IPsec url="/vpn_ipsec.php"> <IPsec cssClass="fa fa-road">
<IPsecPhase1Edit url="/vpn_ipsec_phase1.php*"/> <Tunnels VisibleName="Tunnel Settings" url="/vpn_ipsec.php">
<IPsecPhase2Edit url="/vpn_ipsec_phase2.php*"/> <Phase1 url="/vpn_ipsec_phase1.php*"/>
<MobileClients url="/vpn_ipsec_mobile.php"/> <Phase2 url="/vpn_ipsec_phase2.php*"/>
<Keys url="/vpn_ipsec_keys.php"/> </Tunnels>
<KeysEdit url="/vpn_ipsec_keys_edit.php"/> <Mobile VisibleName="Mobile Clients" url="/vpn_ipsec_mobile.php"/>
<AdvancedSettings url="/vpn_ipsec_settings.php"/> <Keys VisibleName="Pre-Shared Keys" url="/vpn_ipsec_keys.php">
<Edit url="/vpn_ipsec_keys_edit.php*"/>
</Keys>
<Settings VisibleName="Advanced Settings" url="/vpn_ipsec_settings.php"/>
<Status VisibleName="Status Overview" url="/diag_ipsec.php">
<Act url="/diag_ipsec.php?*"/>
</Status>
<Leases VisibleName="Lease Status" url="/diag_ipsec_leases.php"/>
<SAD VisibleName="Security Association Database" url="/diag_ipsec_sad.php"/>
<SPD VisibleName="Security Policy Database" url="/diag_ipsec_spd.php"/>
<Log VisibleName="System Log" url="/diag_logs_ipsec.php"/>
</IPsec> </IPsec>
<L2TP cssClass="fa fa-road"> <L2TP cssClass="fa fa-road">
<Settings url="/vpn_l2tp.php"/> <Settings url="/vpn_l2tp.php"/>
...@@ -272,12 +282,6 @@ ...@@ -272,12 +282,6 @@
<DHCPv6LeasesDetails url="/status_dhcpv6_leases.php?*"/> <DHCPv6LeasesDetails url="/status_dhcpv6_leases.php?*"/>
</DHCPv6Leases> </DHCPv6Leases>
<FilterReload VisibleName="Filter Reload" url="/status_filter_reload.php"/> <FilterReload VisibleName="Filter Reload" url="/status_filter_reload.php"/>
<IPsec url="/diag_ipsec.php">
<IPsecACT url="/diag_ipsec.php?*"/>
<Leases url="/diag_ipsec_leases.php"/>
<SAD url="/diag_ipsec_sad.php"/>
<SPD url="/diag_ipsec_spd.php"/>
</IPsec>
<LoadBalancer VisibleName="Load Balancer" url="/status_lb_pool.php"> <LoadBalancer VisibleName="Load Balancer" url="/status_lb_pool.php">
<VirtualServers url="/status_lb_vs.php"/> <VirtualServers url="/status_lb_vs.php"/>
</LoadBalancer> </LoadBalancer>
...@@ -298,7 +302,6 @@ ...@@ -298,7 +302,6 @@
</Firewall> </Firewall>
<DHCP url="/diag_logs_dhcp.php"/> <DHCP url="/diag_logs_dhcp.php"/>
<PortalAuth url="/diag_logs_auth.php"/> <PortalAuth url="/diag_logs_auth.php"/>
<IPsec url="/diag_logs_ipsec.php"/>
<PPP url="/diag_logs_ppp.php"/> <PPP url="/diag_logs_ppp.php"/>
<VPN url="/diag_logs_vpn.php*"/> <VPN url="/diag_logs_vpn.php*"/>
<LoadBalancer url="/diag_logs_relayd.php"/> <LoadBalancer url="/diag_logs_relayd.php"/>
......
...@@ -121,8 +121,7 @@ $status = ipsec_smp_dump_status(); ...@@ -121,8 +121,7 @@ $status = ipsec_smp_dump_status();
$pconfig = $config['ipsec']['phase1']; $pconfig = $config['ipsec']['phase1'];
legacy_html_escape_form_data($pconfig); legacy_html_escape_form_data($pconfig);
legacy_html_escape_form_data($status); legacy_html_escape_form_data($status);
$pgtitle = array(gettext("Status"),gettext("IPsec")); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Status Overview'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
?> ?>
...@@ -143,9 +142,6 @@ include("head.inc"); ...@@ -143,9 +142,6 @@ include("head.inc");
<div class="row"> <div class="row">
<?php if (isset($input_errors) && count($input_errors) > 0) print_input_errors($input_errors); ?> <?php if (isset($input_errors) && count($input_errors) > 0) print_input_errors($input_errors); ?>
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/diag_ipsec.php";
include('diag_ipsec_tabs.inc');
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-striped"> <table class="table table-striped">
...@@ -367,15 +363,6 @@ include("head.inc"); ...@@ -367,15 +363,6 @@ include("head.inc");
<?php <?php
endforeach; endforeach;
?> ?>
<tr>
<td colspan="8">
<span class="text-danger">
<strong><?php echo gettext("Note:");?><br /></strong>
</span>
<?php echo gettext("You can configure IPsec");?>
<a href="vpn_ipsec.php">here</a>.</p>
</td>
</tr>
</tbody> </tbody>
</table> </table>
</div> </div>
......
<?php <?php
/* /*
Copyright (C) 2014 Deciso B.V. Copyright (C) 2014 Deciso B.V.
Copyright (C) 2014 Ermal LUÇi Copyright (C) 2014 Ermal LUÇi
...@@ -31,9 +32,7 @@ require_once("vpn.inc"); ...@@ -31,9 +32,7 @@ require_once("vpn.inc");
require_once("services.inc"); require_once("services.inc");
require_once("interfaces.inc"); require_once("interfaces.inc");
$pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Lease Status'));
$pgtitle = array(gettext("Status"),gettext("IPsec"),gettext("Leases"));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
$mobile = array(); // TODO: temporary disabled ( https://github.com/opnsense/core/issues/139 ) ipsec_dump_mobile(); $mobile = array(); // TODO: temporary disabled ( https://github.com/opnsense/core/issues/139 ) ipsec_dump_mobile();
...@@ -50,9 +49,6 @@ $mobile = array(); // TODO: temporary disabled ( https://github.com/opnsense/cor ...@@ -50,9 +49,6 @@ $mobile = array(); // TODO: temporary disabled ( https://github.com/opnsense/cor
<?php if (isset($input_errors) && count($input_errors) > 0) print_input_errors($input_errors); ?> <?php if (isset($input_errors) && count($input_errors) > 0) print_input_errors($input_errors); ?>
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/diag_ipsec_leases.php"; include('diag_ipsec_tabs.inc'); ?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<div class="container-fluid"> <div class="container-fluid">
...@@ -100,11 +96,6 @@ $mobile = array(); // TODO: temporary disabled ( https://github.com/opnsense/cor ...@@ -100,11 +96,6 @@ $mobile = array(); // TODO: temporary disabled ( https://github.com/opnsense/cor
<p><strong><?=gettext("No IPsec pools.");?></strong></p> <p><strong><?=gettext("No IPsec pools.");?></strong></p>
<?php endif; ?> <?php endif; ?>
</div> </div>
<p class="vexpl">
<span class="text-danger"><strong><?=gettext("Note:");?><br /></strong></span>
<?=gettext("You can configure your IPsec");?> <a href="vpn_ipsec.php"><?=gettext("here.");?></a>
</p>
</div> </div>
</div> </div>
</section> </section>
......
<?php <?php
/* /*
Copyright (C) 2014 Deciso B.V. Copyright (C) 2014 Deciso B.V.
Copyright (C) 2004-2009 Scott Ullrich Copyright (C) 2004-2009 Scott Ullrich
...@@ -32,9 +33,7 @@ require_once("vpn.inc"); ...@@ -32,9 +33,7 @@ require_once("vpn.inc");
require_once("services.inc"); require_once("services.inc");
require_once("interfaces.inc"); require_once("interfaces.inc");
$pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Security Association Database'));
$pgtitle = array(gettext("Status"),gettext("IPsec"),gettext("SAD"));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
$sad = ipsec_dump_sad(); $sad = ipsec_dump_sad();
...@@ -47,7 +46,6 @@ legacy_html_escape_form_data($sad); ...@@ -47,7 +46,6 @@ legacy_html_escape_form_data($sad);
<div class="container-fluid"> <div class="container-fluid">
<div class="row"> <div class="row">
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/diag_ipsec_sad.php"; include('diag_ipsec_tabs.inc'); ?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-striped"> <table class="table table-striped">
...@@ -79,12 +77,6 @@ legacy_html_escape_form_data($sad); ...@@ -79,12 +77,6 @@ legacy_html_escape_form_data($sad);
</td> </td>
</tr> </tr>
<?php endif; ?> <?php endif; ?>
<tr>
<td colspan="7">
<span class="text-danger"><strong><?=gettext("Note:");?><br /></strong></span>
<?=gettext("You can configure your IPsec");?> <a href="vpn_ipsec.php"><?=gettext("here.");?></a>
</td>
</tr>
</table> </table>
</div> </div>
</div> </div>
......
<?php <?php
/* /*
Copyright (C) 2014 Deciso B.V. Copyright (C) 2014 Deciso B.V.
Copyright (C) 2004-2009 Scott Ullrich Copyright (C) 2004-2009 Scott Ullrich
...@@ -32,8 +33,7 @@ require_once("vpn.inc"); ...@@ -32,8 +33,7 @@ require_once("vpn.inc");
require_once("services.inc"); require_once("services.inc");
require_once("interfaces.inc"); require_once("interfaces.inc");
$pgtitle = array(gettext("Status"),gettext("IPsec"),gettext("SPD")); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Security Policy Database'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
$spd = ipsec_dump_spd(); $spd = ipsec_dump_spd();
...@@ -46,7 +46,6 @@ legacy_html_escape_form_data($spd); ...@@ -46,7 +46,6 @@ legacy_html_escape_form_data($spd);
<div class="container-fluid"> <div class="container-fluid">
<div class="row"> <div class="row">
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/diag_ipsec_spd.php"; include('diag_ipsec_tabs.inc'); ?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-striped"> <table class="table table-striped">
...@@ -70,10 +69,7 @@ legacy_html_escape_form_data($spd); ...@@ -70,10 +69,7 @@ legacy_html_escape_form_data($spd);
</tr> </tr>
<?php endforeach; ?> <?php endforeach; ?>
<tr> <tr>
<td colspan="2"> <td colspan="2"></td>
<span class="text-danger"><strong><?= gettext("Note:"); ?><br /></strong></span>
<?= gettext("You can configure your IPsec"); ?> <a href="vpn_ipsec.php"><?= gettext("here."); ?></a>
</td>
<td colspan="3"> <td colspan="3">
<span class="glyphicon glyphicon-arrow-right" aria-hidden="true" alt="in"></span> <span class="glyphicon glyphicon-arrow-right" aria-hidden="true" alt="in"></span>
<?= gettext("incoming (as seen by firewall)"); ?> <br/> <?= gettext("incoming (as seen by firewall)"); ?> <br/>
...@@ -87,12 +83,6 @@ legacy_html_escape_form_data($spd); ...@@ -87,12 +83,6 @@ legacy_html_escape_form_data($spd);
<p><strong><?= gettext("No IPsec security policies."); ?></strong></p> <p><strong><?= gettext("No IPsec security policies."); ?></strong></p>
</td> </td>
</tr> </tr>
<tr>
<td colspan="5">
<span class="text-danger"><strong><?= gettext("Note:"); ?><br /></strong></span>
<?= gettext("You can configure your IPsec"); ?> <a href="vpn_ipsec.php"><?= gettext("here."); ?></a>
</td>
</tr>
<?php endif; ?> <?php endif; ?>
</table> </table>
</div> </div>
......
<?php
/*
Copyright (C) 2014 Deciso B.V.
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
1. Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY,
OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE.
*/
$tab_array = array();
$tab_array[0] = array(gettext("Overview"), $_SERVER['PHP_SELF'] == '/diag_ipsec.php', "diag_ipsec.php");
$tab_array[1] = array(gettext("Leases"), $_SERVER['PHP_SELF'] == '/diag_ipsec_leases.php', "diag_ipsec_leases.php");
$tab_array[2] = array(gettext("SAD"), $_SERVER['PHP_SELF'] == '/diag_ipsec_sad.php', "diag_ipsec_sad.php");
$tab_array[3] = array(gettext("SPD"), $_SERVER['PHP_SELF'] == '/diag_ipsec_spd.php', "diag_ipsec_spd.php");
$tab_array[4] = array(gettext("Logs"), $_SERVER['PHP_SELF'] == '/diag_logs_ipsec.php', "diag_logs_ipsec.php");
display_top_tabs($tab_array);
?>
...@@ -46,8 +46,7 @@ if ($_POST['clear']) { ...@@ -46,8 +46,7 @@ if ($_POST['clear']) {
clear_clog($ipsec_logfile); clear_clog($ipsec_logfile);
} }
$pgtitle = array(gettext("Status"),gettext("System logs"),gettext("IPsec VPN")); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('System Log'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
?> ?>
...@@ -62,11 +61,6 @@ include("head.inc"); ...@@ -62,11 +61,6 @@ include("head.inc");
<?php if (isset($input_errors) && count($input_errors) > 0) print_input_errors($input_errors); ?> <?php if (isset($input_errors) && count($input_errors) > 0) print_input_errors($input_errors); ?>
<section class="col-xs-12"> <section class="col-xs-12">
<? include('diag_logs_tabs.inc'); ?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<div class="container-fluid"> <div class="container-fluid">
......
...@@ -32,7 +32,6 @@ $tab_array[] = array(gettext("System"), $active_tab == "/diag_logs.php", "diag_l ...@@ -32,7 +32,6 @@ $tab_array[] = array(gettext("System"), $active_tab == "/diag_logs.php", "diag_l
$tab_array[] = array(gettext("Firewall"), $active_tab == "/diag_logs_filter.php", "diag_logs_filter.php"); $tab_array[] = array(gettext("Firewall"), $active_tab == "/diag_logs_filter.php", "diag_logs_filter.php");
$tab_array[] = array(gettext("DHCP"), $active_tab == "/diag_logs_dhcp.php", "diag_logs_dhcp.php"); $tab_array[] = array(gettext("DHCP"), $active_tab == "/diag_logs_dhcp.php", "diag_logs_dhcp.php");
$tab_array[] = array(gettext("Portal Auth"), $active_tab == "/diag_logs_auth.php", "diag_logs_auth.php"); $tab_array[] = array(gettext("Portal Auth"), $active_tab == "/diag_logs_auth.php", "diag_logs_auth.php");
$tab_array[] = array(gettext("IPsec"), $active_tab == "/diag_logs_ipsec.php", "diag_logs_ipsec.php");
$tab_array[] = array(gettext("PPP"), $active_tab == "/diag_logs_ppp.php", "diag_logs_ppp.php"); $tab_array[] = array(gettext("PPP"), $active_tab == "/diag_logs_ppp.php", "diag_logs_ppp.php");
$tab_array[] = array(gettext("VPN"), $active_tab == "/diag_logs_vpn.php", "diag_logs_vpn.php"); $tab_array[] = array(gettext("VPN"), $active_tab == "/diag_logs_vpn.php", "diag_logs_vpn.php");
$tab_array[] = array(gettext("Load Balancer"), $active_tab == "/diag_logs_relayd.php", "diag_logs_relayd.php"); $tab_array[] = array(gettext("Load Balancer"), $active_tab == "/diag_logs_relayd.php", "diag_logs_relayd.php");
......
...@@ -171,13 +171,6 @@ $shortcuts['dhcp6']['main'] = "services_dhcpv6.php"; ...@@ -171,13 +171,6 @@ $shortcuts['dhcp6']['main'] = "services_dhcpv6.php";
$shortcuts['dhcp6']['log'] = "diag_logs_dhcp.php"; $shortcuts['dhcp6']['log'] = "diag_logs_dhcp.php";
$shortcuts['dhcp6']['status'] = "status_dhcpv6_leases.php"; $shortcuts['dhcp6']['status'] = "status_dhcpv6_leases.php";
$shortcuts['ipsec'] = array();
$shortcuts['ipsec']['main'] = "vpn_ipsec.php";
$shortcuts['ipsec']['log'] = "diag_logs_ipsec.php";
$shortcuts['ipsec']['status'] = "diag_ipsec.php";
$shortcuts['ipsec']['service'] = "ipsec";
$shortcuts['firewall'] = array(); $shortcuts['firewall'] = array();
$shortcuts['firewall']['main'] = "firewall_rules.php"; $shortcuts['firewall']['main'] = "firewall_rules.php";
$shortcuts['firewall']['log'] = "diag_logs_filter.php"; $shortcuts['firewall']['log'] = "diag_logs_filter.php";
......
<?php <?php
/* /*
Copyright (C) 2014-2015 Deciso B.V. Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2003-2005 Manuel Kasper <mk@neon1.net>. Copyright (C) 2003-2005 Manuel Kasper <mk@neon1.net>.
...@@ -26,6 +27,7 @@ ...@@ -26,6 +27,7 @@
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
POSSIBILITY OF SUCH DAMAGE. POSSIBILITY OF SUCH DAMAGE.
*/ */
require_once("guiconfig.inc"); require_once("guiconfig.inc");
require_once("filter.inc"); require_once("filter.inc");
require_once("vpn.inc"); require_once("vpn.inc");
...@@ -234,8 +236,7 @@ $pconfig = $config['ipsec']; ...@@ -234,8 +236,7 @@ $pconfig = $config['ipsec'];
$pconfig['enable'] = isset($config['ipsec']['enable']); $pconfig['enable'] = isset($config['ipsec']['enable']);
legacy_html_escape_form_data($pconfig); legacy_html_escape_form_data($pconfig);
$pgtitle = array(gettext("VPN"),gettext("IPsec")); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Tunnel Settings'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
...@@ -269,10 +270,6 @@ function show_phase2(id, buttonid) { ...@@ -269,10 +270,6 @@ function show_phase2(id, buttonid) {
} }
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/vpn_ipsec.php";
include('vpn_ipsec_tabs.inc');
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<div class="table-responsive"> <div class="table-responsive">
<table class="table table-striped"> <table class="table table-striped">
...@@ -575,17 +572,6 @@ endforeach; // $a_phase1 as $ph1ent ...@@ -575,17 +572,6 @@ endforeach; // $a_phase1 as $ph1ent
<span class="glyphicon glyphicon-remove"></span> <span class="glyphicon glyphicon-remove"></span>
</button> </button>
</td> </td>
</tr>
<tr>
<td colspan="9">
<strong><?=gettext("Note"); ?>:<br /></strong>
<?=gettext("You can check your IPsec status at");
?> <a href="diag_ipsec.php"><?=gettext("Status:IPsec"); ?></a>.<br />
<?=gettext("IPsec Debug Mode can be enabled at");
?> <a href="vpn_ipsec_settings.php"><?=gettext("VPN:IPsec:Advanced Settings"); ?></a>.<br />
<?=gettext("IPsec can be set to prefer older SAs at");
?> <a href="vpn_ipsec_settings.php"><?=gettext("VPN:IPsec:Advanced Settings"); ?></a>.
</td>
</tr> </tr>
<tr> <tr>
<td colspan=9> <td colspan=9>
......
<?php <?php
/* /*
Copyright (C) 2014-2015 Deciso B.V. Copyright (C) 2014-2015 Deciso B.V.
Copyright (C) 2003-2005 Manuel Kasper <mk@neon1.net>. Copyright (C) 2003-2005 Manuel Kasper <mk@neon1.net>.
...@@ -69,8 +70,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') { ...@@ -69,8 +70,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'POST') {
} }
} }
$pgtitle = gettext("VPN: IPsec: Keys"); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Pre-Shared Keys'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
?> ?>
...@@ -119,10 +119,6 @@ if (is_subsystem_dirty('ipsec')) { ...@@ -119,10 +119,6 @@ if (is_subsystem_dirty('ipsec')) {
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$active_tab = "/vpn_ipsec_settings.php";
include('vpn_ipsec_tabs.inc');
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="vpn_ipsec_keys.php" method="post"> <form action="vpn_ipsec_keys.php" method="post">
<div class="table-responsive"> <div class="table-responsive">
......
...@@ -116,8 +116,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { ...@@ -116,8 +116,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
} }
$pgtitle = gettext("VPN: IPsec: Edit Pre-Shared Key"); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Edit Pre-Shared Key'));
$shortcut_section = "ipsec";
legacy_html_escape_form_data($pconfig); legacy_html_escape_form_data($pconfig);
......
...@@ -194,8 +194,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { ...@@ -194,8 +194,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
legacy_html_escape_form_data($pconfig); legacy_html_escape_form_data($pconfig);
$pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Mobile")); $pgtitle = array(gettext('VPN'),gettext('IPsec'), gettext('Mobile Clients'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
?> ?>
...@@ -341,10 +340,6 @@ if (isset($input_errors) && count($input_errors) > 0) { ...@@ -341,10 +340,6 @@ if (isset($input_errors) && count($input_errors) > 0) {
} }
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/vpn_ipsec_mobile.php";
include('vpn_ipsec_tabs.inc');
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="vpn_ipsec_mobile.php" method="post" name="iform" id="iform"> <form action="vpn_ipsec_mobile.php" method="post" name="iform" id="iform">
<div class="table-responsive"> <div class="table-responsive">
......
...@@ -418,7 +418,6 @@ if (!empty($pconfig['mobile'])) { ...@@ -418,7 +418,6 @@ if (!empty($pconfig['mobile'])) {
} else { } else {
$pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Edit Phase 1")); $pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Edit Phase 1"));
} }
$shortcut_section = "ipsec";
legacy_html_escape_form_data($pconfig); legacy_html_escape_form_data($pconfig);
...@@ -584,15 +583,6 @@ function dpdchkbox_change() { ...@@ -584,15 +583,6 @@ function dpdchkbox_change() {
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[0] = array(gettext("Tunnels"), true, "vpn_ipsec.php");
$tab_array[1] = array(gettext("Mobile clients"), false, "vpn_ipsec_mobile.php");
$tab_array[2] = array(gettext("Pre-Shared Keys"), false, "vpn_ipsec_keys.php");
$tab_array[3] = array(gettext("Advanced Settings"), false, "vpn_ipsec_settings.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="vpn_ipsec_phase1.php" method="post" name="iform" id="iform"> <form action="vpn_ipsec_phase1.php" method="post" name="iform" id="iform">
<div class="table-responsive"> <div class="table-responsive">
......
<?php <?php
/* /*
Copyright (C) 2014 Deciso B.V. Copyright (C) 2014 Deciso B.V.
Copyright (C) 2008 Shrew Soft Inc Copyright (C) 2008 Shrew Soft Inc
...@@ -431,7 +432,6 @@ if (!empty($pconfig['mobile'])) { ...@@ -431,7 +432,6 @@ if (!empty($pconfig['mobile'])) {
} else { } else {
$pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Edit Phase 2")); $pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Edit Phase 2"));
} }
$shortcut_section = "ipsec";
legacy_html_escape_form_data($pconfig); legacy_html_escape_form_data($pconfig);
...@@ -627,14 +627,6 @@ if (isset($input_errors) && count($input_errors) > 0) { ...@@ -627,14 +627,6 @@ if (isset($input_errors) && count($input_errors) > 0) {
<div class="container-fluid"> <div class="container-fluid">
<div class="row"> <div class="row">
<section class="col-xs-12"> <section class="col-xs-12">
<?php
$tab_array = array();
$tab_array[0] = array(gettext("Tunnels"), true, "vpn_ipsec.php");
$tab_array[1] = array(gettext("Mobile clients"), false, "vpn_ipsec_mobile.php");
$tab_array[2] = array(gettext("Pre-Shared Keys"), false, "vpn_ipsec_keys.php");
$tab_array[3] = array(gettext("Advanced Settings"), false, "vpn_ipsec_settings.php");
display_top_tabs($tab_array);
?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="vpn_ipsec_phase2.php" method="post" name="iform" id="iform"> <form action="vpn_ipsec_phase2.php" method="post" name="iform" id="iform">
<div class="table-responsive"> <div class="table-responsive">
......
...@@ -104,8 +104,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') { ...@@ -104,8 +104,7 @@ if ($_SERVER['REQUEST_METHOD'] === 'GET') {
vpn_ipsec_configure(); vpn_ipsec_configure();
} }
$pgtitle = array(gettext("VPN"),gettext("IPsec"),gettext("Settings")); $pgtitle = array(gettext('VPN'), gettext('IPsec'), gettext('Advanced Settings'));
$shortcut_section = "ipsec";
include("head.inc"); include("head.inc");
?> ?>
...@@ -147,8 +146,6 @@ if (isset($input_errors) && count($input_errors) > 0) { ...@@ -147,8 +146,6 @@ if (isset($input_errors) && count($input_errors) > 0) {
} }
?> ?>
<section class="col-xs-12"> <section class="col-xs-12">
<? $active_tab = "/vpn_ipsec_settings.php";
include('vpn_ipsec_tabs.inc'); ?>
<div class="tab-content content-box col-xs-12"> <div class="tab-content content-box col-xs-12">
<form action="vpn_ipsec_settings.php" method="post" name="iform" id="iform"> <form action="vpn_ipsec_settings.php" method="post" name="iform" id="iform">
<div class="table-responsive"> <div class="table-responsive">
......
<?php
$tab_array = array();
$tab_array[0] = array(gettext("Tunnels"), $_SERVER['PHP_SELF'] == "/vpn_ipsec.php", "vpn_ipsec.php");
$tab_array[1] = array(gettext("Mobile clients"), $_SERVER['PHP_SELF'] == "/vpn_ipsec_mobile.php", "vpn_ipsec_mobile.php");
$tab_array[2] = array(gettext("Pre-Shared Keys"), $_SERVER['PHP_SELF'] == "/vpn_ipsec_keys.php", "vpn_ipsec_keys.php");
$tab_array[3] = array(gettext("Advanced Settings"), $_SERVER['PHP_SELF'] == "/vpn_ipsec_settings.php", "vpn_ipsec_settings.php");
display_top_tabs($tab_array);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment