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

Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 

uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 

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

Safe-mode: OFF (not secure)

/uploads/script/vendor/laravel/framework/src/Illuminate/Foundation/Testing/Concerns/   drwxr-xr-x
Free 13.18 GB of 57.97 GB (22.73%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

namespace Illuminate\Foundation\Testing\Concerns;

use 
Illuminate\Contracts\Debug\ExceptionHandler;
use 
Illuminate\Validation\ValidationException;
use 
Symfony\Component\Console\Application as ConsoleApplication;
use 
Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
use 
Throwable;

trait 
InteractsWithExceptionHandling
{
    
/**
     * The original exception handler.
     *
     * @var \Illuminate\Contracts\Debug\ExceptionHandler|null
     */
    
protected $originalExceptionHandler;

    
/**
     * Restore exception handling.
     *
     * @return $this
     */
    
protected function withExceptionHandling()
    {
        if (
$this->originalExceptionHandler) {
            
$this->app->instance(ExceptionHandler::class, $this->originalExceptionHandler);
        }

        return 
$this;
    }

    
/**
     * Only handle the given exceptions via the exception handler.
     *
     * @param  array  $exceptions
     * @return $this
     */
    
protected function handleExceptions(array $exceptions)
    {
        return 
$this->withoutExceptionHandling($exceptions);
    }

    
/**
     * Only handle validation exceptions via the exception handler.
     *
     * @return $this
     */
    
protected function handleValidationExceptions()
    {
        return 
$this->handleExceptions([ValidationException::class]);
    }

    
/**
     * Disable exception handling for the test.
     *
     * @param  array  $except
     * @return $this
     */
    
protected function withoutExceptionHandling(array $except = [])
    {
        if (
$this->originalExceptionHandler == null) {
            
$this->originalExceptionHandler app(ExceptionHandler::class);
        }

        
$this->app->instance(ExceptionHandler::class, new class($this->originalExceptionHandler$except) implements ExceptionHandler {
            protected 
$except;
            protected 
$originalHandler;

            
/**
             * Create a new class instance.
             *
             * @param  \Illuminate\Contracts\Debug\ExceptionHandler  $originalHandler
             * @param  array  $except
             * @return void
             */
            
public function __construct($originalHandler$except = [])
            {
                
$this->except $except;
                
$this->originalHandler $originalHandler;
            }

            
/**
             * Report or log an exception.
             *
             * @param  \Throwable  $e
             * @return void
             *
             * @throws \Exception
             */
            
public function report(Throwable $e)
            {
                
//
            
}

            
/**
             * Determine if the exception should be reported.
             *
             * @param  \Throwable  $e
             * @return bool
             */
            
public function shouldReport(Throwable $e)
            {
                return 
false;
            }

            
/**
             * Render an exception into an HTTP response.
             *
             * @param  \Illuminate\Http\Request  $request
             * @param  \Throwable  $e
             * @return \Symfony\Component\HttpFoundation\Response
             *
             * @throws \Throwable
             */
            
public function render($requestThrowable $e)
            {
                foreach (
$this->except as $class) {
                    if (
$e instanceof $class) {
                        return 
$this->originalHandler->render($request$e);
                    }
                }

                if (
$e instanceof NotFoundHttpException) {
                    throw new 
NotFoundHttpException(
                        
"{$request->method()} {$request->url()}"$e$e->getCode()
                    );
                }

                throw 
$e;
            }

            
/**
             * Render an exception to the console.
             *
             * @param  \Symfony\Component\Console\Output\OutputInterface  $output
             * @param  \Throwable  $e
             * @return void
             */
            
public function renderForConsole($outputThrowable $e)
            {
                (new 
ConsoleApplication)->renderThrowable($e$output);
            }
        });

        return 
$this;
    }
}

:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

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

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