Moved development IPs to dev-ips.php
Signed-off-by: Gergely POLONKAI (W00d5t0ck) <polesz@w00d5t0ck.info>
This commit is contained in:
@@ -1,13 +1,12 @@
|
||||
<?php
|
||||
|
||||
require 'dev-ips.php';
|
||||
|
||||
if (!isset($_SERVER['HTTP_HOST'])) {
|
||||
exit('This script cannot be run from the CLI. Run it from a browser.');
|
||||
}
|
||||
|
||||
if (!in_array(@$_SERVER['REMOTE_ADDR'], array(
|
||||
'127.0.0.1',
|
||||
'::1',
|
||||
))) {
|
||||
if (!in_array(@$_SERVER['REMOTE_ADDR'], $dev_ips)) {
|
||||
header('HTTP/1.0 403 Forbidden');
|
||||
exit('This script is only accessible from localhost.');
|
||||
}
|
||||
|
Reference in New Issue
Block a user