= $subnet_start) && (ip2ulong($_POST['localip']) <= $subnet_end)) { $input_errors[] = gettext("The specified server address lies in the remote subnet."); } if ($_POST['localip'] == get_interface_ip("lan")) { $input_errors[] = gettext("The specified server address is equal to the LAN interface address."); } } } /* if this is an AJAX caller then handle via JSON */ if(isAjax() && is_array($input_errors)) { input_errors2Ajax($input_errors); exit; } if (!$input_errors) { $l2tpcfg['remoteip'] = $_POST['remoteip']; $l2tpcfg['localip'] = $_POST['localip']; $l2tpcfg['l2tp_subnet'] = $_POST['l2tp_subnet']; $l2tpcfg['mode'] = $_POST['mode']; $l2tpcfg['interface'] = $_POST['interface']; $l2tpcfg['n_l2tp_units'] = $_POST['n_l2tp_units']; $l2tpcfg['radius']['server'] = $_POST['radiusserver']; $l2tpcfg['radius']['secret'] = $_POST['radiussecret']; $l2tpcfg['secret'] = $_POST['secret']; if($_POST['wins']) $l2tpcfg['wins'] = $_POST['wins']; else unset($l2tpcfg['wins']); $l2tpcfg['paporchap'] = $_POST['paporchap']; if ($_POST['l2tp_dns1'] == "") { if (isset($l2tpcfg['dns1'])) unset($l2tpcfg['dns1']); } else $l2tpcfg['dns1'] = $_POST['l2tp_dns1']; if ($_POST['l2tp_dns2'] == "") { if (isset($l2tpcfg['dns2'])) unset($l2tpcfg['dns2']); } else $l2tpcfg['dns2'] = $_POST['l2tp_dns2']; if($_POST['radiusenable'] == "yes") $l2tpcfg['radius']['enable'] = true; else unset($l2tpcfg['radius']['enable']); if($_POST['radacct_enable'] == "yes") $l2tpcfg['radius']['accounting'] = true; else unset($l2tpcfg['radius']['accounting']); if($_POST['radiusissueips'] == "yes") $l2tpcfg['radius']['radiusissueips'] = true; else unset($l2tpcfg['radius']['radiusissueips']); write_config(); $retval = 0; $retval = vpn_l2tp_configure(); $savemsg = get_std_save_message($retval); /* if ajax is calling, give them an update message */ if(isAjax()) print_info_box_np($savemsg); } } include("head.inc"); ?> ">
  />
  />


.
.

.



24 255.255.255.0

10







/>


/>


/>
  " onclick="enable_change(true)" />