All pastes #210275 Raw Edit

Someone

public text v1 · immutable
#210275 ·published 2006-10-19 17:08 UTC
rendered paste body
<?
$allowed_ips = array ("212.38.11*.*",
"212.38.124.*",
"212.38.122.*",
"217.168.176.*",
"62.212.22*.*",
"217.25.16.*",
"217.25.17.*",
"217.25.18.*",
"217.25.19.*",
"217.25.2*.*",
"217.25.30.*",
"217.25.31.*",
);

$userip = $_SERVER['REMOTE_ADDR'];
for ($i=0;$i<count($allowed_ips);$i++)
{
	$ipFromArray = str_replace(".","\.",$allowed_ips[$i]);
	if (eregi("^($ipFromArray)",$userip)) {
		$olar = 1;
		break;
	}

}

if (!isset($olar))
{
	die("You are Not Allowed!");
}
?>