Version 3.4.0

1. 增加了ADMIN_IP_CHECK_ENABLE与XFF_ENABLE两个选项,在有反代或负载均衡的情况下可开启XFF_ENABLE,关闭ADMIN_IP_CHECK_ENABLE
2. 修复一系列bug
This commit is contained in:
Firesun
2016-12-27 21:49:19 +08:00
parent 2377ad9906
commit e63a14d32a
11 changed files with 448 additions and 394 deletions

View File

@@ -3,20 +3,19 @@ define("IN_XSS_PLATFORM", true);
ignore_user_abort(true);
error_reporting(0);
//sometimes we only need "referfer".
//sometimes we only need "referer".
/*
if(count($_GET)==0&&count($_POST)==0&&count($_COOKIE)==0)
exit();
*/
header("Access-Control-Allow-Origin:*");
require_once("load.php");
require_once("functions.php");
require_once("dio.php");
$info = array();
$user_IP = isset($_SERVER['REMOTE_ADDR']) ? $_SERVER['REMOTE_ADDR'] : "unknown";
$user_IP = getRealIP();
$user_port = isset($_SERVER['REMOTE_PORT']) ? $_SERVER['REMOTE_PORT'] : "unknown";
$protocol = isset($_SERVER['SERVER_PROTOCOL']) ? $_SERVER['SERVER_PROTOCOL'] : "unknown";
$request_method = isset($_SERVER['REQUEST_METHOD']) ? $_SERVER['REQUEST_METHOD'] : "unknown";