ok

Mini Shell

Direktori : /proc/self/root/proc/thread-self/root/proc/self/root/usr/local/sitepad/lib/panels/webuzo/
Upload File :
Current File : //proc/self/root/proc/thread-self/root/proc/self/root/usr/local/sitepad/lib/panels/webuzo/index.php

<?php

@define('SITEPAD', 1);

$admin_ports = array('2004', '2005');
$enduser_ports = array('2002', '2003');

// Check for custom Webuzo ports
$aports_file = '/usr/local/webuzo/conf/webuzo/emps/admin_port.conf';
$eports_file = '/usr/local/webuzo/conf/webuzo/emps/enduser_port.conf';

if(file_exists($aports_file)){
	$aports = file_get_contents($aports_file);
	preg_match_all('/listen(.*?)\;/is', $aports, $matches);

	if(!empty($matches[1])){
		foreach($matches[1] as $k => $v){
			$admin_ports[] = trim(str_replace(' ssl', '', $v));
		}
	}	
}

if(file_exists($eports_file)){
	$eports = file_get_contents($eports_file);
	preg_match_all('/listen(.*?)\;/is', $eports, $matches);

	if(!empty($matches[1])){
		foreach($matches[1] as $k => $v){
			$enduser_ports[] = trim(str_replace(' ssl', '', $v));
		}
	}	
}

// Admin Panel
if(in_array($_SERVER['SERVER_PORT'], $admin_ports)){
	include_once(dirname(dirname(__FILE__)).'/admin.php');

// Enduser
}elseif(in_array($_SERVER['SERVER_PORT'], $enduser_ports)){
	@define('SITEMUSHUSER', 1);

	header("Cache-Control: no-cache, must-revalidate"); // HTTP/1.1
	header("Expires: Mon, 26 Jul 1997 05:00:00 GMT"); // Date in the past
	
	if(isset($_GET['act']) && $_GET['act'] == 'backups' && !empty($_GET['download']) && substr_count($_GET['download'], './') == 0){
		header('Content-Disposition: attachment; filename="'.$_GET['download'].'"');
	}
	
	include_once(dirname(dirname(__FILE__)).'/enduser.php');
}



Zerion Mini Shell 1.0