!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/mis/eassess/admin/fileupdate/eassess/admin/   drwxr-xr-x
Free 50.75 GB of 127.8 GB (39.71%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     2552-05-29-1.0.02-timetableInCourseTmp.php (9.99 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
include_once "../../class/clsDB.php";
include_once 
"../../class/clsConnection.php";
include_once 
"../global.php";
include_once 
"../link/function.php";
include_once 
"../class/clsReg_SysSemesterDes.php";
include_once 
"../class/clsReg_Program.php";
include_once 
"../class/clsClassAssess.php";
include_once 
"../class/clsClassOpenForAssess.php";
include_once 
"../class/clsCourseAssess.php";
include_once 
"../class/clsHoldCourseTmp.php";
include_once 
"../class/clsTimeTableAssess.php";
include_once 
"../class/clsOfficerAssess.php";
include_once 
"../class/clsSysStudyTypeAssess.php";
include_once 
"../class/clsReg_Day.php";
include_once 
"../class/clsReg_Period.php";
include_once 
"../class/clsWeekDateAssess.php";

$oCR = new clsConnection($GLOBALS['HOST'], $GLOBALS['DB_REG'], $GLOBALS['USER_REG'], $GLOBALS['PASSWORD_REG']);

$oCA = new clsConnection($GLOBALS['HOST'], $GLOBALS['DB_EASS'], $GLOBALS['USER_EASS'], $GLOBALS['PASSWORD_EASS']);

$oProg = new Program($oCR);
$oClassA = new ClassAssess($oCA);
$oClsOpen = new ClassOpenForAssess($oCA);
$oCourse = new CourseAssess($oCA);  
$oCourse_in = new CourseAssess($oCA);  
$oHCT = new HoldCourseTmp($oCA);
$oTTA = new TimeTableAssess($oCA);
$oOA = new OfficerAssess($oCA);
$oSST=new SysStudyTypeAssess($oCA);
$orDy=new Day($oCR);
$orPr = new Period($oCR);
$orPr2 = new Period($oCR);
$oWDA = new WeekDateAssess($oCA);

doCheckAll();

?>
<script language="javascript1.2">
    function doSubmitAll(){
        document.pc.action = "./processCourseTableTmp.php?method=add&assid=<?=$assid;?>&acadYear=<?=$acadYear;?>&semester=<?=$semester;?>&startDate=<?=$startDate;?>&endDate=<?=$endDate;?>&closeDate=<?=$closeDate;?>&selectFlag=<?=$selectFlag;?>&ttId=<?=$ttId;?>&cnt=<?=$i;?>&classId=<?=$classId;?>&officerId=<?=$officerId;?>&isPreAssess=<?=$isPreAssess;?>";
        document.pc.submit();

    }
</script>
<html>
<head>
<title>ตารางเรียนในรายวิชา</title>
<meta http-equiv="Content-Type" content="text/html; charset=windows-874">
<link href="style.css" rel="stylesheet" type="text/css">
<style>
<!--
A:link {text-decoration: none }
A:visited {text-decoration: none}
A:hover {text-decoration: none; font-weight: underline}
.style1 {color: #FFFFFF}

-->
</style>

</head>
<body bgcolor="#FFFFFF" > 
<?php 
//    $acadYear_1 = $GLOBALS["ACADYEAR"];
//  $semester_1 = $GLOBALS["SEMESTER"];
    
$acadYear_1 $acadYear;
    
$semester_1 $semester;
    
$oClassA->SearchByKey($classId);
    
$oClassA->GetRecord();
    
$oCourse->SearchByKey($oClassA->courseId);
    
$oCourse->GetRecord();
?>
<form name="pc" action="<?php echo $PHP_SELF;?>" method="post">
  <table width="97%" border="0" align="center" cellpadding="1" cellspacing="1" >
    <tr bgcolor="#FFFFFF"> 
      <td  colspan="3" align = "center" background="bg_LightSpirit.gif"><font face="Microsoft Sans Serif" size="2"><b>เลือกสัปดาห์ที่เปิดสอน</b></font>
      &nbsp;
      <br></td>
    </tr>
      <tr bgcolor="#FFFFFF">
      <td width="18%" ><font face="Microsoft Sans Serif" size="2"><b>ชื่อย่อหลักสูตร</b></font></td>
      <td width="82%" ><font face="Microsoft Sans Serif" size="2">
      <?        
                        
if(($oClassA->programId == 0) || ($oClassA->programId == "")){
                            
$z 0;
                            
$oClsOpen->SearchByClassId($oClassA->classId);
                            while(
$oClsOpen->GetRecord()){
                                
$oProg->SearchByKey($oClsOpen->programId);  
                                
$oProg->GetRecord();
                                if(
$oProg->programAbbr != ""){
                                    
$arrCls[$z] = $oProg->programAbbr;
                                }else{
                                    
$arrCls[$z] = "<img src = \"../picture/warn.png\" border = \"0\">";
                                }
                                
//$arrCls[$z] = $oClsOpen->programId;
                                
$z++;
                            } 
// end while oClsOpen
                            
for($a=0;$a<=$z;$a++){
                                echo 
$arrCls[$a];
                                if(
$a $z-1) echo ",<br>";
                            }
                        }else{
                            
$oProg->SearchByKey($oClassA->programId);  
                            if(
$oProg->GetRecord()){
                                if(
$oProg->programAbbr != ""){
                                    echo 
$oProg->programAbbr;
                                }else{
                                    echo 
"<img src = \"../picture/warn.png\" border = \"0\">";
                                }
                            }
                            
//echo $oClassA->programId;
                     
}
             
?>
      </font></td>
      </tr >
     <tr bgcolor="#D8F2F3"><td ><font face="Microsoft Sans Serif" size="2"><b>รายวิชา</b></font></td>
      <td ><font face="Microsoft Sans Serif" size="2"><?php  echo $oCourse->courseCode.'     '.$oCourse->courseName.'   กลุ่ม  '.$oClassA->section;?> </font></td>
    </tr >
    <tr bgcolor="#FFFFFF"><td ><font face="Microsoft Sans Serif" size="2"><b>ปีการศึกษา</b></font></td>
      <td ><font face="Microsoft Sans Serif" size="2">
    <?
            $oSse 
= new SysSemesterDes($oCR);
            
$oSse->SearchByKey($semester_1);
            
$oSse->GetRecord();
            echo 
$oSse->semesterName."/".$acadYear_1;
    
?>
      </font></td>
    </tr >
 </table>
    <table width="97%" border="0" align="center" cellpadding="1" cellspacing="1" bgcolor="#999999"  >
    <font face="Microsoft Sans Serif" size="2">
    <tr bgcolor="#0066CC"> <b>
      <td width="5%" align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1"> เลือก</span></font></td>
      <td width="5%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1"> ครั้งที่</span></font></td>
      <td width="5%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1">สัปดาห์ที่</span></font></td>
     <td width="13%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1">วันที่</span></font></td>
     <td width="14%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1">ห้อง</span></font></td>
     <td width="30%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1">( ประเภทการสอน ) <br>บท/เรื่อง/หัวข้อสอน</span></font></td>
     <td width="10%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1">อาจารย์</span></font></td>
     <td width="20%"  align="center" bgcolor="#0066CC"><font face="Microsoft Sans Serif" size="2"><span class="style1">วัน/เวลา</span></font></td>
    </b></tr>
    <?php 
    $i
=1;
    
$lean=0;
    
$oTTA->searchByClIdAcadSem($classId,$acadYear,$semester);
    while(
$oTTA->GetRecord()){
        
$lean=$lean+1;
        
$oOA->SearchByKey($oTTA->ttOfId);
        
$oOA->GetRecord();
        
$oSST->SearchByKey($oTTA->ttSstId);
        
$oSST->GetRecord();
        
$orDy->SearchByKey($oTTA->ttDyId);
        
$orDy->GetRecord();
        
        
$orPr->SearchByKey($oTTA>ttFrPr);
        
$orPr->GetRecord();
        
$orPr2->SearchByKey($oTTA->ttToPr);
        
$orPr2->GetRecord();

        
$ClassTime$orDy->dayAbbrEng.' '.substr($orPr->startTime,0,5).'-'.substr($orPr2->endTime,0,5);
        
        
$oWDA->searchByWdAcYWeekNoAcY($oTTA->ttWdAcYWeekNo,$acadYear_1);
        
$oWDA->GetRecord();    
        
$dateL date("Y-m-d"mktime(000substr($oWDA->wdFrDate,5,2),substr($oWDA->wdFrDate,8,2)+$oTTA->ttDyId-1,substr($oWDA->wdFrDate,0,4)));
        
$mm =convertMonthNumberToString2(substr($dateL,5,2)); 
        
$acY substr($dateL,0,4)+543;
        
$week substr($dateL,8,2).' '.$mm.' '.substr($acY,2,2);
    
?>
    <tr  bgcolor="#FFFFFF"> 
    <?php 
        $oHCT
->SearchByttId($oTTA->ttId);
        if(
$oHCT->GetRecord()){
    
?>
              <td  align="center" ><input type="checkbox"  name="ttId[<?php echo $i;?>]" value="<?php echo $oTTA->ttId;?>" checked>
            <input type="hidden" name="officerId[<?php echo $i;?>]" value="<?=$oOA->officerId;?>"></td>
          <?php 
        
}else{ //$oHCT == 0
    
?>
            <td  align="center" ><input type="checkbox"  name="ttId[<?php echo $i;?>]" value="<?php echo $oTTA->ttId;?>" >
            <input type="hidden" name="officerId[<?php echo $i;?>]" value="<?=$oOA->officerId;?>"></td>
            <? //end $oHCT?>
     <td    align="center" ><font face="Microsoft Sans Serif" size="2"><?=$i;?></font></td>
     <td    align="center" ><font face="Microsoft Sans Serif" size="2"><?=$oTTA->ttWdAcYWeekNo;?></font></td>
     <td    align="center" ><font face="Microsoft Sans Serif" size="2"><?=$week;?></font></td>
      <td    align="center" ><font face="Microsoft Sans Serif" size="2"><? echo $oTTA->ttMainPlace' - '.$oTTA->ttSubPlace;?></font></td>
    <td    align="left" ><font face="Microsoft Sans Serif" size="2"><?='('.$oSST->sstAbbrEng.') '.$oTTA->ttTitle;?></font></td>
    <td    align="left" ><font face="Microsoft Sans Serif" size="2"><?=$oOA->officerName;?></font></td>
    <td    align="left" ><font face="Microsoft Sans Serif" size="2"><?=$ClassTime;?></font></td>
    </tr>
    <?  $i++ ; }?>
    <? if($lean==0){?>
    <tr> 
      <td colspan="8" align="center" bgcolor="#FFFFFF"><font size="2" color="#FF0000" face="Microsoft Sans Serif">** 
        ไม่ปรากฏตารางเรียนรายสัปดาห์ในรายวิชานี้ ** 
        </font></td></tr>
    <? }?>
  </table>
  <br>
  <table width="97%" border="0" align="center" cellpadding="1" cellspacing="0" bgcolor="silver">
    <tr> 
      <td width="76%"><input type="button" name="selectAll" value="เลือกทั้งหมด" onClick="doCheckAll(this.form, true);"> 
      <input type="button" name="cancelAll" value="ยกเลิกทั้งหมด" onClick="doCheckAll(this.form, false);">
        <input type="hidden" name="cnt" value="<?php echo $i;?>">
         <input type="hidden" name="assid" value="<?php echo $assid;?>"> 
        <input type="hidden" name="acadYear" value="<?php echo $acadYear;?>"> 
        <input type="hidden" name="semester" value="<?php echo $semester;?>"> 
        <input type="hidden" name="startDate" value="<?php echo $startDate;?>"> 
        <input type="hidden" name="endDate" value="<?php echo $endDate;?>">
        <input type="hidden" name="closeDate" value="<?php echo $closeDate;?>">
        <input type="hidden" name="selectFlag" value="<?php echo $selectFlag;?>">
        <input type="hidden" name="isPreAssess" value="<?php echo $isPreAssess;?>"></td>
      <td width="24%" align="right">&nbsp;</td>
    </tr>
    <tr> 
      <td colspan="2" align="center" bgcolor="#FFFFFF"><br> <input type="button" name="Submit" value="บันทึกข้อมูลที่เลือก" onclick = 'return doSubmitAll();'> 
      </td>
    </tr>
    <tr>
      <td align="center" colspan="2" bgcolor="#FFFFFF">&nbsp;</td>
    </tr>
    <tr> 
      <td  colspan="2" bgcolor="#FFFFFF">&nbsp;</td>
    </tr>
  </front></table>
</form>
</body>
</html>

:: 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.0118 ]--