!c99Shell v. 1.0 pre-release build #16!

Software: Apache/2.2.3 (CentOS). PHP/5.1.6 

uname -a: Linux mx-ll-110-164-51-230.static.3bb.co.th 2.6.18-194.el5PAE #1 SMP Fri Apr 2 15:37:44
EDT 2010 i686
 

uid=48(apache) gid=48(apache) groups=48(apache) 

Safe-mode: OFF (not secure)

/var/www/html/mistk_joice2222/ums/   drwxr-xr-x
Free 52.35 GB of 127.8 GB (40.96%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     importStaffTeacher.php (2.88 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?
include_once "pagebody.php";
pageHeader();
$pageTitle="นำเข้าข้อมูลอาจารย์/เจ้าหน้าที่";
?>
<table width=100% class="pageTitleBgColor" align="center">
<tr><td align=center><? echo $pageTitle; ?></td></tr>
</table>
<!--your code here-------------------------------------------------------------------------->
<p align=center>
<form name="form1" method=post>
<table boder align=center>
<tr><td>Database Server</td><td><input type="text" name="dbHost" value="localhost"></td></tr>
<tr><td>	Database Name</td><td><input type="text" name="dbName"></td></tr>
<tr><td>	User name</td><td><input type="text" name="dbUserName"><br></td></tr>
<tr><td>	Password</td><td><input type="text" name="dbPassword"><br></td></tr>
<tr><td colspan="2" align=center>	<input type="hidden"name="method" value="import">
	<input type="submit" value="Start import student data."></td></tr>
</table>
</form>
</p>
<?
if ($method=="import"){
	include_once "clsUser.php";
	include_once "clsUmUser.php";
	include_once "clsStudentT.php";
	$oC = new clsConnection($GLOBALS['HOST'], $GLOBALS['DB'], $GLOBALS['USER'], $GLOBALS['PASSWORD']);
	$oC1 = new clsConnection($dbHost, $dbName, $dbUserName, $dbPassword);
	$oUs = new clsUser();
	$oUm = new umuser($oC);
	$oS = new StudentT($oC1);
	$oS->RSStudent();

	$oC->BeginTrans();
	echo "<table align=center cellpadding=2>\n";
	echo "<tr bgcolor=#CCCCCC><th>อาจายร์/เจ้าหน้าที่</th><th>ดำเนินการ</th></tr>\n";
	$i=0;
	while ($oS->GetRecord()){		//อ่านทุกคนจากตารางนักศึกษา
		echo "<tr><td>$oS->studentCode :: $oS->studentNameSurname</td>";
		echo "<td>";
		$oUm->searchByUserLogin($oS->studentCode);	//หาตามรหัสนิสิต
		if (!$oUm->GetRecord()){	//ถ้าไม่มีใน um
			$oU->addNewUser($oS->studentCode, $oS->studentNameSurname, 6, 1, $oS->studentCode,$oS->studentCode);
			echo "<font color=#339900>เพิ่มใหม่</font> ";
		}else{ //มีใน um
			if ($oS->studentStatus<>7){	//สถานะ อยู่
				$sql = "update umuser set 
						UsPassword='" . md5("O]O".$oS->studentCode."O[O") . "', 
						UsName='$oS->studentNameSurname', 
						UsActive=1 
						where UsLogin='$oS->studentCode'";	
				$oC->Execute($sql);
				echo "<font color=#0000FF>ปรับปรุงสถานะเป็น active</font>";
			}else{ //สถานะ ไม่อยู่   ออก  กะเสียน
				$sql = "update umuser set 
						UsPassword='" . md5("O]O".$oS->studentCode."O[O") . "', 
						UsName='$oS->studentNameSurname', 
						UsActive=0 
						where UsLogin='$oS->studentCode'";	
				$oC->Execute($sql);
				echo "<font color=#666666>ปรับปรุงสถานะเป็น No active</font>";
			}
		}
		$i++;
		echo "</td></tr>\n";
	} //while
	echo "<tr align=right><td colspan=2><hr>จำนวนทั้งสิ้น $i รายการ<hr></td></tr>\n";
	echo "</table>\n";
	$oC->CommitTrans();
}
?>

<!--------------------------------------------------------------------->
<? 
pageFooter(); 
?>
<!--------------------------------------------------------------------->
<!--put javascript here-->

:: Command execute ::

Enter:
 
Select:
 

:: Shadow's tricks :D ::

Useful Commands
 
Warning. Kernel may be alerted using higher levels
Kernel Info:

:: Preddy's tricks :D ::

Php Safe-Mode Bypass (Read Files)

File:

eg: /etc/passwd

Php Safe-Mode Bypass (List Directories):

Dir:

eg: /etc/

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c999shell v. 1.0 pre-release build #16 Modded by Shadow & Preddy | RootShell Security Group | r57 c99 shell | Generation time: 0.0057 ]--