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

Software: nginx/1.23.4. PHP/5.6.40-65+ubuntu20.04.1+deb.sury.org+1 

uname -a: Linux foro-restaurado-2 5.15.0-1040-oracle #46-Ubuntu SMP Fri Jul 14 21:47:21 UTC 2023
aarch64
 

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

Safe-mode: OFF (not secure)

/usr/share/php/PhpMyAdmin/Twig/Extensions/Node/   drwxr-xr-x
Free 83.34 GB of 96.73 GB (86.16%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


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

/*
 * This file is part of Twig.
 *
 * (c) 2010-2019 Fabien Potencier
 * (c) 2019 phpMyAdmin contributors
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
namespace PhpMyAdmin\Twig\Extensions\Node;

use 
Twig\Compiler;
use 
Twig\Node\CheckToStringNode;
use 
Twig\Node\Expression\AbstractExpression;
use 
Twig\Node\Expression\ConstantExpression;
use 
Twig\Node\Expression\FilterExpression;
use 
Twig\Node\Expression\NameExpression;
use 
Twig\Node\Expression\TempNameExpression;
use 
Twig\Node\Node;
use 
Twig\Node\PrintNode;
use function 
array_merge;
use function 
count;
use function 
sprintf;
use function 
str_replace;
use function 
trim;

/**
 * Represents a trans node.
 *
 * Author Fabien Potencier <[email protected]>
 */
class TransNode extends Node
{
    public function 
__construct(Node $body, ?Node $plural, ?AbstractExpression $count, ?Node $notesint $lineno 0, ?string $tag null)
    {
        
$nodes = ['body' => $body];
        if (
$count !== null) {
            
$nodes['count'] = $count;
        }
        if (
$plural !== null) {
            
$nodes['plural'] = $plural;
        }
        if (
$notes !== null) {
            
$nodes['notes'] = $notes;
        }

        
parent::__construct($nodes, [], $lineno$tag);
    }

    
/**
     * {@inheritdoc}
     */
    
public function compile(Compiler $compiler)
    {
        
$compiler->addDebugInfo($this);

        [
$msg$vars] = $this->compileString($this->getNode('body'));

        if (
$this->hasNode('plural')) {
            [
$msg1$vars1] = $this->compileString($this->getNode('plural'));

            
$vars array_merge($vars$vars1);
        }

        
$function $this->getTransFunction($this->hasNode('plural'));

        if (
$this->hasNode('notes')) {
            
$message trim($this->getNode('notes')->getAttribute('data'));

            
// line breaks are not allowed cause we want a single line comment
            
$message str_replace(["\n""\r"], ' '$message);
            
$compiler->write('// notes: ' $message "\n");
        }

        if (
$vars) {
            
$compiler
                
->write('echo strtr(' $function '(')
                ->
subcompile($msg);

            if (
$this->hasNode('plural')) {
                
$compiler
                    
->raw(', ')
                    ->
subcompile($msg1)
                    ->
raw(', abs(')
                    ->
subcompile($this->hasNode('count') ? $this->getNode('count') : null)
                    ->
raw(')');
            }

            
$compiler->raw('), array(');

            foreach (
$vars as $var) {
                if (
$var->getAttribute('name') === 'count') {
                    
$compiler
                        
->string('%count%')
                        ->
raw(' => abs(')
                        ->
subcompile($this->hasNode('count') ? $this->getNode('count') : null)
                        ->
raw('), ');
                } else {
                    
$compiler
                        
->string('%' $var->getAttribute('name') . '%')
                        ->
raw(' => ')
                        ->
subcompile($var)
                        ->
raw(', ');
                }
            }

            
$compiler->raw("));\n");
        } else {
            
$compiler
                
->write('echo ' $function '(')
                ->
subcompile($msg);

            if (
$this->hasNode('plural')) {
                
$compiler
                    
->raw(', ')
                    ->
subcompile($msg1)
                    ->
raw(', abs(')
                    ->
subcompile($this->hasNode('count') ? $this->getNode('count') : null)
                    ->
raw(')');
            }

            
$compiler->raw(");\n");
        }
    }

    
/**
     * Keep this method protected instead of private
     * Twig/I18n/NodeTrans from phpmyadmin/phpmyadmin uses it
     */
    
protected function compileString(Node $body): array
    {
        if (
$body instanceof NameExpression || $body instanceof ConstantExpression || $body instanceof TempNameExpression) {
            return [
$body, []];
        }

        
$vars = [];
        if (
count($body)) {
            
$msg '';

            foreach (
$body as $node) {
                if (
$node instanceof PrintNode) {
                    
$n $node->getNode('expr');
                    while (
$n instanceof FilterExpression) {
                        
$n $n->getNode('node');
                    }
                    while (
$n instanceof CheckToStringNode) {
                        
$n $n->getNode('expr');
                    }
                    
$msg .= sprintf('%%%s%%'$n->getAttribute('name'));
                    
$vars[] = new NameExpression($n->getAttribute('name'), $n->getTemplateLine());
                } else {
                    
$msg .= $node->getAttribute('data');
                }
            }
        } else {
            
$msg $body->getAttribute('data');
        }

        return [new 
Node([new ConstantExpression(trim($msg), $body->getTemplateLine())]), $vars];
    }

    private function 
getTransFunction(bool $plural): string
    
{
        return 
$plural 'ngettext' 'gettext';
    }
}

:: 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 HackingTool | HackingTool | Generation time: 0.0047 ]--