From 02a382b9188f2bed7befe84fde3dc9bbb2694188 Mon Sep 17 00:00:00 2001 From: Tom Schaefer Date: Tue, 1 Feb 2011 20:55:24 -0500 Subject: g4m3c4ck's fix for pulling countries from local file vs webserver --- config/countryblock/countryblock.tmp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/config/countryblock/countryblock.tmp b/config/countryblock/countryblock.tmp index 1fa387d5..d2e5c022 100644 --- a/config/countryblock/countryblock.tmp +++ b/config/countryblock/countryblock.tmp @@ -42,9 +42,13 @@ if (count($_POST)>0) { foreach ($lines as $line) { //echo("fetch -o lists http://www.countryipblocks.net/e_country_data/{$line}_cidr.txt"); //Fetch countries from server - exec("fetch -o lists/temp http://127.0.0.1//packages/countryblock/CIDR/{$line}_cidr.txt"); + //exec("fetch -o lists/temp http://127.0.0.1//packages/countryblock/CIDR/{$line}_cidr.txt"); + //Pull from local file since https or http on other ports may be used + exec("cat CIDR/{$line}_cidr.txt >> lists/countries.txt"); //exec("fetch -o lists/temp http://www.countryipblocks.net/e_country_data/{$line}_cidr.txt"); - exec("cat lists/temp >> lists/countries.txt"); + //Remove cat lists/temp since fetch is not used + //Thank you g4m3c4ck, 'He got a real pretty mouth ain't he', 1 Feb 2011 + //exec("cat lists/temp >> lists/countries.txt"); $filename = basename($line); //Extract list //exec("gzip -d lists/$filename"); @@ -2688,4 +2692,4 @@ ob_end_clean(); - \ No newline at end of file + -- cgit v1.2.3