forked from sillycross/dts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathend.php
executable file
·34 lines (30 loc) · 1 KB
/
end.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
<?php
define('CURSCRIPT', 'end');
define('IN_GAME', true);
defined('GAME_ROOT') || define('GAME_ROOT', dirname(__FILE__).'/');
require GAME_ROOT.'./include/global.func.php';
include GAME_ROOT.'./include/modules/core/sys/config/server.config.php';
$url = url_dir().'command.php';
$context = array('page'=>'command_end');
foreach($_POST as $pkey => $pval){
$context[$pkey] = $pval;
}
$cookies = array();
foreach($_COOKIE as $ckey => $cval){
if(strpos($ckey,'user')!==false || strpos($ckey,'pass')!==false) $cookies[$ckey] = $cval;
}
$endinfo = curl_post($url, $context, $cookies);
if(strpos($endinfo, 'redirect')===0){
list($null, $url) = explode(':',$endinfo);
header('Location: '.$url);
exit();
}
if(strpos($endinfo,'<head>')===false){
$d_endinfo = gdecode($endinfo,1);
if(is_array($d_endinfo) && isset($d_endinfo['url']) && 'error.php' == $d_endinfo['url']){
gexit($d_endinfo['errormsg'],__file__,__line__);
}
}
echo $endinfo;
/* End of file end.php */
/* Location: /end.php */