* finish task #6243.

This commit is contained in:
wangyidong
2019-08-21 10:11:44 +08:00
parent 336e6e2e30
commit 8bdcfef980
+1 -1
View File
@@ -699,7 +699,7 @@ function isLocalIP()
global $config;
if(isset($config->islocalIP)) return $config->isLocalIP;
$serverIP = $_SERVER['SERVER_ADDR'];
if($serverIP == '127.0.0.1') return true;
if($serverIP == '127.0.0.1' or $serverIP == '::1') return true;
if(strpos($serverIP, '10.70') !== false) return false;
return !filter_var($serverIP, FILTER_VALIDATE_IP, FILTER_FLAG_NO_PRIV_RANGE);
}