!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/smm.picotech.app/public_html/vendor/php-http/message/src/Formatter/   drwxr-xr-x
Free 28.53 GB of 117.98 GB (24.18%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

namespace Http\Message\Formatter;

use 
Http\Message\Formatter;
use 
Psr\Http\Message\MessageInterface;
use 
Psr\Http\Message\RequestInterface;
use 
Psr\Http\Message\ResponseInterface;

/**
 * A formatter that prints the complete HTTP message.
 *
 * @author Tobias Nyholm <tobias.nyholm@gmail.com>
 */
class FullHttpMessageFormatter implements Formatter
{
    
/**
     * The maximum length of the body.
     *
     * @var int|null
     */
    
private $maxBodyLength;

    
/**
     * @var string
     */
    
private $binaryDetectionRegex;

    
/**
     * @param int|null $maxBodyLength
     * @param string   $binaryDetectionRegex By default, this is all non-printable ASCII characters and <DEL> except for \t, \r, \n
     */
    
public function __construct($maxBodyLength 1000string $binaryDetectionRegex '/([\x00-\x09\x0C\x0E-\x1F\x7F])/')
    {
        
$this->maxBodyLength $maxBodyLength;
        
$this->binaryDetectionRegex $binaryDetectionRegex;
    }

    
/**
     * {@inheritdoc}
     */
    
public function formatRequest(RequestInterface $request)
    {
        
$message sprintf(
            
"%s %s HTTP/%s\n",
            
$request->getMethod(),
            
$request->getRequestTarget(),
            
$request->getProtocolVersion()
        );

        foreach (
$request->getHeaders() as $name => $values) {
            
$message .= $name.': '.implode(', '$values)."\n";
        }

        return 
$this->addBody($request$message);
    }

    
/**
     * {@inheritdoc}
     */
    
public function formatResponse(ResponseInterface $response)
    {
        
$message sprintf(
            
"HTTP/%s %s %s\n",
            
$response->getProtocolVersion(),
            
$response->getStatusCode(),
            
$response->getReasonPhrase()
        );

        foreach (
$response->getHeaders() as $name => $values) {
            
$message .= $name.': '.implode(', '$values)."\n";
        }

        return 
$this->addBody($response$message);
    }

    
/**
     * Formats a response in context of its request.
     *
     * @return string
     */
    
public function formatResponseForRequest(ResponseInterface $responseRequestInterface $request)
    {
        return 
$this->formatResponse($response);
    }

    
/**
     * Add the message body if the stream is seekable.
     *
     * @param string $message
     *
     * @return string
     */
    
private function addBody(MessageInterface $request$message)
    {
        
$message .= "\n";
        
$stream $request->getBody();
        if (!
$stream->isSeekable() || === $this->maxBodyLength) {
            
// Do not read the stream
            
return $message;
        }

        
$data $stream->__toString();
        
$stream->rewind();

        if (
preg_match($this->binaryDetectionRegex$data)) {
            return 
$message.'[binary stream omitted]';
        }

        if (
null === $this->maxBodyLength) {
            return 
$message.$data;
        }

        return 
$message.mb_substr($data0$this->maxBodyLength);
    }
}

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