!C99Shell v. 2.5 [PHP 8 Update] [24.05.2025]!

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

uid=33(www-data) gid=33(www-data) groups=33(www-data) 

Safe-mode: OFF (not secure)

/uploads/script/vendor/composer/composer/src/Composer/Downloader/   drwxr-xr-x
Free 13.25 GB of 57.97 GB (22.85%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

/*
 * This file is part of Composer.
 *
 * (c) Nils Adermann <naderman@naderman.de>
 *     Jordi Boggiano <j.boggiano@seld.be>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace Composer\Downloader;

use 
Composer\Package\PackageInterface;
use 
Composer\Util\ProcessExecutor;

/**
 * @author BohwaZ <http://bohwaz.net/>
 */
class FossilDownloader extends VcsDownloader
{
    
/**
     * {@inheritDoc}
     */
    
protected function doDownload(PackageInterface $package$path$urlPackageInterface $prevPackage null)
    {
    }

    
/**
     * {@inheritDoc}
     */
    
protected function doInstall(PackageInterface $package$path$url)
    {
        
// Ensure we are allowed to use this URL by config
        
$this->config->prohibitUrlByConfig($url$this->io);

        
$url ProcessExecutor::escape($url);
        
$ref ProcessExecutor::escape($package->getSourceReference());
        
$repoFile $path '.fossil';
        
$this->io->writeError("Cloning ".$package->getSourceReference());
        
$command sprintf('fossil clone %s %s'$urlProcessExecutor::escape($repoFile));
        if (
!== $this->process->execute($command$ignoredOutput)) {
            throw new 
\RuntimeException('Failed to execute ' $command "\n\n" $this->process->getErrorOutput());
        }
        
$command sprintf('fossil open %s --nested'ProcessExecutor::escape($repoFile));
        if (
!== $this->process->execute($command$ignoredOutputrealpath($path))) {
            throw new 
\RuntimeException('Failed to execute ' $command "\n\n" $this->process->getErrorOutput());
        }
        
$command sprintf('fossil update %s'$ref);
        if (
!== $this->process->execute($command$ignoredOutputrealpath($path))) {
            throw new 
\RuntimeException('Failed to execute ' $command "\n\n" $this->process->getErrorOutput());
        }
    }

    
/**
     * {@inheritDoc}
     */
    
protected function doUpdate(PackageInterface $initialPackageInterface $target$path$url)
    {
        
// Ensure we are allowed to use this URL by config
        
$this->config->prohibitUrlByConfig($url$this->io);

        
$ref ProcessExecutor::escape($target->getSourceReference());
        
$this->io->writeError(" Updating to ".$target->getSourceReference());

        if (!
$this->hasMetadataRepository($path)) {
            throw new 
\RuntimeException('The .fslckout file is missing from '.$path.', see https://getcomposer.org/commit-deps for more information');
        }

        
$command sprintf('fossil pull && fossil up %s'$ref);
        if (
!== $this->process->execute($command$ignoredOutputrealpath($path))) {
            throw new 
\RuntimeException('Failed to execute ' $command "\n\n" $this->process->getErrorOutput());
        }
    }

    
/**
     * {@inheritDoc}
     */
    
public function getLocalChanges(PackageInterface $package$path)
    {
        if (!
$this->hasMetadataRepository($path)) {
            return 
null;
        }

        
$this->process->execute('fossil changes'$outputrealpath($path));

        return 
trim($output) ?: null;
    }

    
/**
     * {@inheritDoc}
     */
    
protected function getCommitLogs($fromReference$toReference$path)
    {
        
$command sprintf('fossil timeline -t ci -W 0 -n 0 before %s'ProcessExecutor::escape($toReference));

        if (
!== $this->process->execute($command$outputrealpath($path))) {
            throw new 
\RuntimeException('Failed to execute ' $command "\n\n" $this->process->getErrorOutput());
        }

        
$log '';
        
$match '/\d\d:\d\d:\d\d\s+\[' $toReference '\]/';

        foreach (
$this->process->splitLines($output) as $line) {
            if (
preg_match($match$line)) {
                break;
            }
            
$log .= $line;
        }

        return 
$log;
    }

    
/**
     * {@inheritDoc}
     */
    
protected function hasMetadataRepository($path)
    {
        return 
is_file($path '/.fslckout') || is_file($path '/_FOSSIL_');
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

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

--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0055 ]--