Project

General

Profile

« Previous | Next » 

Revision 656fd270

Added by Ermal Luçi over 10 years ago

Add some saftey belts here to be safe

View differences:

etc/inc/vpn.inc
862 862
					$ipsecfin = '';
863 863
					foreach ($rightsubnet_spec as $idx => $rsubnet) {
864 864
						$ipsecfin .= "\nconn con{$ph1ent['ikeid']}00{$idx}\n";
865
						$ipsecfin .= "\treqid = " . $reqids[$idx] . "\n";
865
						if (!empty($reqids[$idx]))
866
							$ipsecfin .= "\treqid = " . $reqids[$idx] . "\n";
866 867
						$ipsecfin .= $ipsecconnect;
867 868
						$ipsecfin .= "\trightsubnet = {$rsubnet}\n";
868 869
						$ipsecfin .= "\tleftsubnet = " . $leftsubnet_spec[$idx] . "\n";
......
871 872
					log_error("No phase2 specifications for tunnel with REQID = {$ikeid}");
872 873
			} else {
873 874
				$ipsecfin = "\nconn con{$ph1ent['ikeid']}\n";
874
				$ipsecfin .= "\treqid = " . $reqids[0] . "\n";
875
				if (!empty($reqids[$idx]))
876
					$ipsecfin .= "\treqid = " . $reqids[0] . "\n";
875 877
				$ipsecfin .= $ipsecconnect;
876 878
				if (!empty($rightsubnet_spec)) {
877 879
					$tempsubnets = array();

Also available in: Unified diff