|
System | : | Linux MiraNet 3.0.0-14-generic-pae #23-Ubuntu SMP Mon Nov 21 22:07:10 UTC 2011 i686 |
Software | : | Apache. PHP/5.3.6-13ubuntu3.10 |
ID | : | uid=65534(nobody) gid=65534(nogroup) groups=65534(nogroup)
|
|
Safe Mode | : | OFF |
Open_Basedir | : | OFF |
Freespace | : | 30.56 GB of 70.42 GB (43.4%) |
|
MySQL: ON MSSQL: OFF Oracle: OFF PostgreSQL: OFF Curl: OFF Sockets: ON Fetch: OFF Wget: ON Perl: ON |
Disabled Functions: pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,
|
[ System Info ]
[ Processes ]
[ SQL Manager ]
[ Eval ]
[ Encoder ]
[ Mailer ]
[ Back Connection ]
[ Backdoor Server ]
[ Kernel Exploit Search ]
[ MD5 Decrypter ]
[ Reverse IP ]
[ Kill Shell ]
[ FTP Brute-Force ]
|
|
/
usr/
share/
php/
adodb/
- drwxr-xr-x
|
Viewing file: server.php (2.24 KB) -rw-r--r--Select action/file-type:  ( +) |  ( +) |  ( +) | Code ( +) | Session ( +) |  ( +) | SDB ( +) |  ( +) |  ( +) |  ( +) |  ( +) |  ( +) |
<?php
/** * @version V4.93 10 Oct 2006 (c) 2000-2009 John Lim (jlim#natsoft.com). All rights reserved. * Released under both BSD license and Lesser GPL library license. Whenever there is any discrepancy between the two licenses, the BSD license will take precedence. */ /* Documentation on usage is at http://php.weblogs.com/adodb_csv * * Legal query string parameters: * * sql = holds sql string * nrows = number of rows to return * offset = skip offset rows of data * fetch = $ADODB_FETCH_MODE * * example: * * http://localhost/php/server.php?select+*+from+table&nrows=10&offset=2 */
/* * Define the IP address you want to accept requests from * as a security measure. If blank we accept anyone promisciously! */ $ACCEPTIP = '127.0.0.1';
/* * Connection parameters */ $driver = 'mysql'; $host = 'localhost'; // DSN for odbc $uid = 'root'; $pwd = 'garbase-it-is'; $database = 'test';
/*============================ DO NOT MODIFY BELOW HERE =================================*/ // $sep must match csv2rs() in adodb.inc.php $sep = ' :::: ';
include('./adodb.inc.php'); include_once(ADODB_DIR.'/adodb-csvlib.inc.php');
function err($s) { die('**** '.$s.' '); }
// undo stupid magic quotes function undomq(&$m) { if (get_magic_quotes_gpc()) { // undo the damage $m = str_replace('\\\\','\\',$m); $m = str_replace('\"','"',$m); $m = str_replace('\\\'','\'',$m); } return $m; }
///////////////////////////////////////// DEFINITIONS
$remote = $_SERVER["REMOTE_ADDR"];
if (!empty($ACCEPTIP)) if ($remote != '127.0.0.1' && $remote != $ACCEPTIP) err("Unauthorised client: '$remote'"); if (empty($_REQUEST['sql'])) err('No SQL');
$conn = ADONewConnection($driver);
if (!$conn->Connect($host,$uid,$pwd,$database)) err($conn->ErrorNo(). $sep . $conn->ErrorMsg()); $sql = undomq($_REQUEST['sql']);
if (isset($_REQUEST['fetch'])) $ADODB_FETCH_MODE = $_REQUEST['fetch']; if (isset($_REQUEST['nrows'])) { $nrows = $_REQUEST['nrows']; $offset = isset($_REQUEST['offset']) ? $_REQUEST['offset'] : -1; $rs = $conn->SelectLimit($sql,$nrows,$offset); } else $rs = $conn->Execute($sql); if ($rs){ //$rs->timeToLive = 1; echo _rs2serialize($rs,$conn,$sql); $rs->Close(); } else err($conn->ErrorNo(). $sep .$conn->ErrorMsg());
?>
|