smsonayla.org - c99shell

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

Software: LiteSpeed. PHP/7.4.33 

uname -a: Linux server704.web-hosting.com 4.18.0-553.54.1.lve.el8.x86_64 #1 SMP Wed Jun 4 13:01:13
UTC 2025 x86_64
 

uid=1309(necipbey) gid=1314(necipbey) groups=1314(necipbey) 

Safe-mode: OFF (not secure)

/home/necipbey/public_html/system/   drwxr-xr-x
Free 3472.98 GB of 4265.01 GB (81.43%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     ComposerScripts.php (4.97 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

/**
 * This file is part of CodeIgniter 4 framework.
 *
 * (c) CodeIgniter Foundation <admin@codeigniter.com>
 *
 * For the full copyright and license information, please view
 * the LICENSE file that was distributed with this source code.
 */

namespace CodeIgniter;

use 
FilesystemIterator;
use 
RecursiveDirectoryIterator;
use 
RecursiveIteratorIterator;
use 
SplFileInfo;

/**
 * This class is used by Composer during installs and updates
 * to move files to locations within the system folder so that end-users
 * do not need to use Composer to install a package, but can simply
 * download.
 *
 * @codeCoverageIgnore
 *
 * @internal
 */
final class ComposerScripts
{
    
/**
     * Path to the ThirdParty directory.
     */
    
private static string $path __DIR__ '/ThirdParty/';

    
/**
     * Direct dependencies of CodeIgniter to copy
     * contents to `system/ThirdParty/`.
     *
     * @var array<string, array<string, string>>
     */
    
private static array $dependencies = [
        
'kint-src' => [
            
'license' => __DIR__ '/../vendor/kint-php/kint/LICENSE',
            
'from'    => __DIR__ '/../vendor/kint-php/kint/src/',
            
'to'      => __DIR__ '/ThirdParty/Kint/',
        ],
        
'kint-resources' => [
            
'from' => __DIR__ '/../vendor/kint-php/kint/resources/',
            
'to'   => __DIR__ '/ThirdParty/Kint/resources/',
        ],
        
'escaper' => [
            
'license' => __DIR__ '/../vendor/laminas/laminas-escaper/LICENSE.md',
            
'from'    => __DIR__ '/../vendor/laminas/laminas-escaper/src/',
            
'to'      => __DIR__ '/ThirdParty/Escaper/',
        ],
        
'psr-log' => [
            
'license' => __DIR__ '/../vendor/psr/log/LICENSE',
            
'from'    => __DIR__ '/../vendor/psr/log/Psr/Log/',
            
'to'      => __DIR__ '/ThirdParty/PSR/Log/',
        ],
    ];

    
/**
     * This static method is called by Composer after every update event,
     * i.e., `composer install`, `composer update`, `composer remove`.
     */
    
public static function postUpdate()
    {
        
self::recursiveDelete(self::$path);

        foreach (
self::$dependencies as $dependency) {
            
self::recursiveMirror($dependency['from'], $dependency['to']);
            if (isset(
$dependency['license'])) {
                
$license basename($dependency['license']);
                
copy($dependency['license'], $dependency['to'] . '/' $license);
            }
        }

        
self::copyKintInitFiles();
        
self::recursiveDelete(self::$dependencies['psr-log']['to'] . 'Test/');
    }

    
/**
     * Recursively remove the contents of the previous `system/ThirdParty`.
     */
    
private static function recursiveDelete(string $directory): void
    
{
        if (! 
is_dir($directory)) {
            echo 
sprintf('Cannot recursively delete "%s" as it does not exist.'$directory);
        }

        
/** @var SplFileInfo $file */
        
foreach (new RecursiveIteratorIterator(
            new 
RecursiveDirectoryIterator(rtrim($directory'\\/'), FilesystemIterator::SKIP_DOTS),
            
RecursiveIteratorIterator::CHILD_FIRST
        
) as $file) {
            
$path $file->getPathname();

            if (
$file->isDir()) {
                @
rmdir($path);
            } else {
                @
unlink($path);
            }
        }
    }

    
/**
     * Recursively copy the files and directories of the origin directory
     * into the target directory, i.e. "mirror" its contents.
     */
    
private static function recursiveMirror(string $originDirstring $targetDir): void
    
{
        
$originDir rtrim($originDir'\\/');
        
$targetDir rtrim($targetDir'\\/');

        if (! 
is_dir($originDir)) {
            echo 
sprintf('The origin directory "%s" was not found.'$originDir);

            exit(
1);
        }

        if (
is_dir($targetDir)) {
            echo 
sprintf('The target directory "%s" is existing. Run %s::recursiveDelete(\'%s\') first.'$targetDirself::class, $targetDir);

            exit(
1);
        }

        @
mkdir($targetDir0755true);

        
$dirLen strlen($originDir);

        
/** @var SplFileInfo $file */
        
foreach (new RecursiveIteratorIterator(
            new 
RecursiveDirectoryIterator($originDirFilesystemIterator::SKIP_DOTS),
            
RecursiveIteratorIterator::SELF_FIRST
        
) as $file) {
            
$origin $file->getPathname();
            
$target $targetDir substr($origin$dirLen);

            if (
$file->isDir()) {
                @
mkdir($target0755);
            } else {
                @
copy($origin$target);
            }
        }
    }

    
/**
     * Copy Kint's init files into `system/ThirdParty/Kint/`
     */
    
private static function copyKintInitFiles(): void
    
{
        
$originDir self::$dependencies['kint-src']['from'] . '../';
        
$targetDir self::$dependencies['kint-src']['to'];

        foreach ([
'init.php''init_helpers.php'] as $kintInit) {
            @
copy($originDir $kintInit$targetDir $kintInit);
        }
    }
}

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