Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php namespace MiniOrange\OAuth\Helper; use MiniOrange\OAuth\Helper\OAuthConstant..

Decoded Output download

<?php 
 
 
namespace MiniOrange\OAuth\Helper; 
 
use MiniOrange\OAuth\Helper\OAuthConstants; 
class Curl 
{ 
    public static function create_customer($Zm, $LK, $GY, $rc = '', $Vn = '', $fR = '') 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/add"; 
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY; 
        $zR = OAuthConstants::DEFAULT_API_KEY; 
        $H1 = ["companyName" => $LK, "areaOfInterest" => OAuthConstants::AREA_OF_INTEREST, "firstname" => $Vn, "lastname" => $fR, "email" => $Zm, "phone" => $rc, "password" => $GY]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function get_customer_key($Zm, $GY) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/key"; 
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY; 
        $zR = OAuthConstants::DEFAULT_API_KEY; 
        $H1 = ["email" => $Zm, "password" => $GY]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function check_customer($Zm) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/check-if-exists"; 
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY; 
        $zR = OAuthConstants::DEFAULT_API_KEY; 
        $H1 = ["email" => $Zm]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function mo_send_otp_token($WM, $Zm = '', $rc = '') 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/api/auth/challenge"; 
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY; 
        $zR = OAuthConstants::DEFAULT_API_KEY; 
        $H1 = ["customerKey" => $dz, "email" => $Zm, "phone" => $rc, "authType" => $WM, "transactionName" => OAuthConstants::AREA_OF_INTEREST]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function mo_send_access_token_request($nJ, $Ac, $AN, $oa) 
    { 
        $hF = ["Content-Type: application/x-www-form-urlencoded", "Authorization: Basic " . base64_encode($AN . ":" . $oa)]; 
        $um = self::callAPI($Ac, $nJ, $hF); 
        return $um; 
    } 
    public static function mo_send_user_info_request($Ac, $Ov) 
    { 
        $um = self::callAPI($Ac, [], $Ov); 
        return $um; 
    } 
    public static function validate_otp_token($vK, $yc) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/api/auth/validate"; 
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY; 
        $zR = OAuthConstants::DEFAULT_API_KEY; 
        $H1 = ["txId" => $vK, "token" => $yc]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function submit_contact_us($iZ, $Pz, $gm, $Vn, $fR, $lF) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/contact-us"; 
        $gm = "[" . OAuthConstants::AREA_OF_INTEREST . "]: " . $gm; 
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY; 
        $zR = OAuthConstants::DEFAULT_API_KEY; 
        $H1 = ["firstName" => $Vn, "lastName" => $fR, "company" => $lF, "email" => $iZ, "phone" => $Pz, "query" => $gm, "ccEmail" => "[email protected]"]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return true; 
    } 
    public static function forgot_password($Zm, $dz, $zR) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/password-reset"; 
        $H1 = ["email" => $Zm]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function check_customer_ln($dz, $zR) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/license"; 
        $H1 = ["customerId" => $dz, "applicationName" => OAuthConstants::APPLICATION_NAME, "licenseType" => !MoUtility::micr() ? "DEMO" : "PREMIUM"]; 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    private static function createAuthHeader($dz, $zR) 
    { 
        $XO = round(microtime(true) * 1000); 
        $XO = number_format($XO, 0, '', ''); 
        $kD = $dz . $XO . $zR; 
        $hF = hash("sha512", $kD); 
        $w2 = ["Content-Type: application/json", "Customer-Key: {$dz}", "Timestamp: {$XO}", "Authorization: {$hF}"]; 
        return $w2; 
    } 
    private static function callAPI($Ac, $LI = array(), $Ov = array("Content-Type: application/json")) 
    { 
        $Mc = new MoCurl(); 
        $Sn = ["CURLOPT_FOLLOWLOCATION" => true, "CURLOPT_ENCODING" => '', "CURLOPT_RETURNTRANSFER" => true, "CURLOPT_AUTOREFERER" => true, "CURLOPT_TIMEOUT" => 0, "CURLOPT_MAXREDIRS" => 10]; 
        $tu = in_array("Content-Type: application/x-www-form-urlencoded", $Ov) ? !empty($LI) ? http_build_query($LI) : '' : (!empty($LI) ? json_encode($LI) : ''); 
        $Cv = !empty($tu) ? "POST" : "GET"; 
        $Mc->setConfig($Sn); 
        $Mc->write($Cv, $Ac, "1.1", $Ov, $tu); 
        $nF = $Mc->read(); 
        $Mc->close(); 
        return $nF; 
    } 
    public static function mius($dz, $zR, $kx) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/api/backupcode/updatestatus"; 
        $H1 = array("code" => $kx, "customerKey" => $dz); 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function vml($dz, $zR, $kx, $l2) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/api/backupcode/verify"; 
        $H1 = array("code" => $kx, "customerKey" => $dz, "additionalFields" => array("field1" => $l2)); 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
    public static function ccl($dz, $zR) 
    { 
        $Ac = OAuthConstants::HOSTNAME . "/moas/rest/customer/license"; 
        $H1 = array("customerId" => $dz, "applicationName" => "magento_oauth_enterprise_plan"); 
        $hF = self::createAuthHeader($dz, $zR); 
        $um = self::callAPI($Ac, $H1, $hF); 
        return $um; 
    } 
} 
 ?>

Did this file decode correctly?

Original Code

<?php


namespace MiniOrange\OAuth\Helper;

use MiniOrange\OAuth\Helper\OAuthConstants;
class Curl
{
    public static function create_customer($Zm, $LK, $GY, $rc = '', $Vn = '', $fR = '')
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\x6d\x6f\x61\163\x2f\x72\x65\163\164\x2f\x63\165\163\x74\x6f\155\145\x72\57\141\144\x64";
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY;
        $zR = OAuthConstants::DEFAULT_API_KEY;
        $H1 = ["\143\x6f\155\x70\x61\x6e\171\116\141\x6d\145" => $LK, "\x61\x72\x65\141\x4f\x66\111\x6e\x74\x65\162\145\x73\x74" => OAuthConstants::AREA_OF_INTEREST, "\x66\x69\162\x73\x74\156\x61\155\145" => $Vn, "\x6c\x61\163\x74\156\x61\155\145" => $fR, "\145\155\141\151\154" => $Zm, "\160\150\x6f\x6e\x65" => $rc, "\160\141\163\x73\167\157\x72\144" => $GY];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function get_customer_key($Zm, $GY)
    {
        $Ac = OAuthConstants::HOSTNAME . "\57\x6d\x6f\141\163\x2f\162\145\163\164\x2f\143\165\163\x74\157\155\x65\x72\x2f\x6b\145\171";
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY;
        $zR = OAuthConstants::DEFAULT_API_KEY;
        $H1 = ["\145\x6d\x61\x69\154" => $Zm, "\x70\x61\x73\x73\167\x6f\x72\x64" => $GY];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function check_customer($Zm)
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\x6d\157\141\163\57\x72\x65\163\164\x2f\143\165\163\x74\x6f\155\145\x72\57\143\x68\145\x63\x6b\x2d\151\x66\55\x65\170\151\x73\164\163";
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY;
        $zR = OAuthConstants::DEFAULT_API_KEY;
        $H1 = ["\x65\155\x61\151\x6c" => $Zm];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function mo_send_otp_token($WM, $Zm = '', $rc = '')
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\x6d\157\141\x73\x2f\x61\x70\151\57\x61\x75\164\150\57\x63\x68\x61\x6c\154\x65\156\147\x65";
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY;
        $zR = OAuthConstants::DEFAULT_API_KEY;
        $H1 = ["\143\x75\x73\164\x6f\x6d\x65\x72\x4b\x65\x79" => $dz, "\x65\155\141\151\x6c" => $Zm, "\160\x68\157\x6e\145" => $rc, "\x61\165\x74\x68\x54\x79\x70\145" => $WM, "\164\x72\141\156\x73\141\x63\164\151\x6f\156\x4e\141\155\x65" => OAuthConstants::AREA_OF_INTEREST];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function mo_send_access_token_request($nJ, $Ac, $AN, $oa)
    {
        $hF = ["\103\157\x6e\164\x65\156\x74\55\x54\x79\x70\145\x3a\x20\x61\160\160\154\x69\x63\141\x74\x69\x6f\156\x2f\x78\55\x77\167\x77\55\146\157\x72\155\x2d\x75\162\x6c\x65\156\x63\157\x64\x65\144", "\x41\x75\x74\150\x6f\162\x69\172\141\164\151\157\x6e\72\x20\x42\141\163\x69\143\40" . base64_encode($AN . "\x3a" . $oa)];
        $um = self::callAPI($Ac, $nJ, $hF);
        return $um;
    }
    public static function mo_send_user_info_request($Ac, $Ov)
    {
        $um = self::callAPI($Ac, [], $Ov);
        return $um;
    }
    public static function validate_otp_token($vK, $yc)
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\155\157\141\x73\57\x61\x70\x69\57\x61\165\164\150\57\x76\x61\154\x69\144\x61\164\x65";
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY;
        $zR = OAuthConstants::DEFAULT_API_KEY;
        $H1 = ["\164\x78\111\144" => $vK, "\x74\x6f\153\145\156" => $yc];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function submit_contact_us($iZ, $Pz, $gm, $Vn, $fR, $lF)
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\155\157\141\x73\x2f\x72\145\x73\x74\x2f\x63\165\x73\x74\157\155\x65\162\57\x63\x6f\156\x74\141\x63\x74\x2d\165\163";
        $gm = "\133" . OAuthConstants::AREA_OF_INTEREST . "\135\x3a\40" . $gm;
        $dz = OAuthConstants::DEFAULT_CUSTOMER_KEY;
        $zR = OAuthConstants::DEFAULT_API_KEY;
        $H1 = ["\x66\151\x72\x73\164\x4e\141\x6d\x65" => $Vn, "\x6c\x61\163\x74\x4e\x61\155\145" => $fR, "\143\x6f\x6d\x70\141\156\x79" => $lF, "\x65\155\141\x69\154" => $iZ, "\160\x68\x6f\x6e\x65" => $Pz, "\x71\165\145\x72\x79" => $gm, "\x63\143\x45\x6d\x61\x69\x6c" => "\157\141\165\x74\x68\163\165\160\160\157\162\x74\x40\x78\145\143\x75\162\151\x66\171\56\x63\x6f\x6d"];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return true;
    }
    public static function forgot_password($Zm, $dz, $zR)
    {
        $Ac = OAuthConstants::HOSTNAME . "\57\x6d\157\141\x73\x2f\162\145\163\x74\57\x63\x75\163\164\x6f\x6d\145\162\x2f\160\141\x73\163\167\157\162\144\55\162\x65\163\145\x74";
        $H1 = ["\145\x6d\x61\x69\154" => $Zm];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function check_customer_ln($dz, $zR)
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\155\157\141\x73\57\x72\x65\163\x74\x2f\143\165\x73\164\x6f\x6d\x65\162\57\x6c\151\143\x65\x6e\163\x65";
        $H1 = ["\x63\165\163\x74\157\155\145\x72\x49\x64" => $dz, "\x61\x70\160\x6c\x69\143\x61\164\151\157\x6e\116\141\155\x65" => OAuthConstants::APPLICATION_NAME, "\x6c\x69\143\145\156\x73\x65\x54\171\x70\x65" => !MoUtility::micr() ? "\x44\105\x4d\x4f" : "\120\122\105\115\111\125\115"];
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    private static function createAuthHeader($dz, $zR)
    {
        $XO = round(microtime(true) * 1000);
        $XO = number_format($XO, 0, '', '');
        $kD = $dz . $XO . $zR;
        $hF = hash("\x73\150\x61\x35\x31\x32", $kD);
        $w2 = ["\x43\x6f\156\164\x65\156\164\55\124\x79\x70\145\x3a\x20\141\160\x70\154\151\143\141\164\151\x6f\x6e\57\152\163\157\x6e", "\103\x75\x73\164\157\x6d\x65\x72\55\113\145\171\72\x20{$dz}", "\x54\x69\155\x65\x73\x74\141\x6d\x70\x3a\40{$XO}", "\101\x75\x74\x68\157\x72\x69\x7a\141\164\x69\157\x6e\x3a\x20{$hF}"];
        return $w2;
    }
    private static function callAPI($Ac, $LI = array(), $Ov = array("\x43\x6f\156\164\x65\156\x74\55\124\x79\x70\x65\x3a\40\141\160\160\x6c\x69\x63\141\164\151\x6f\x6e\57\x6a\163\157\156"))
    {
        $Mc = new MoCurl();
        $Sn = ["\x43\125\122\x4c\x4f\120\x54\137\x46\117\x4c\114\117\127\114\117\103\x41\124\111\x4f\x4e" => true, "\x43\125\x52\114\117\x50\x54\137\105\x4e\103\x4f\104\x49\x4e\x47" => '', "\x43\125\122\x4c\x4f\120\x54\x5f\x52\105\124\125\122\116\124\x52\x41\116\123\106\x45\122" => true, "\x43\x55\x52\114\117\x50\x54\137\101\x55\x54\x4f\122\105\106\105\x52\x45\122" => true, "\103\125\122\114\117\120\124\x5f\124\x49\115\105\117\125\124" => 0, "\103\125\122\114\x4f\120\x54\x5f\115\x41\130\x52\x45\104\x49\122\123" => 10];
        $tu = in_array("\x43\157\x6e\x74\145\x6e\x74\x2d\124\x79\x70\x65\72\40\141\x70\x70\154\151\143\x61\x74\x69\157\156\x2f\x78\x2d\x77\x77\167\x2d\x66\x6f\162\155\x2d\165\x72\154\x65\x6e\x63\157\x64\x65\x64", $Ov) ? !empty($LI) ? http_build_query($LI) : '' : (!empty($LI) ? json_encode($LI) : '');
        $Cv = !empty($tu) ? "\x50\x4f\x53\124" : "\107\105\x54";
        $Mc->setConfig($Sn);
        $Mc->write($Cv, $Ac, "\x31\56\61", $Ov, $tu);
        $nF = $Mc->read();
        $Mc->close();
        return $nF;
    }
    public static function mius($dz, $zR, $kx)
    {
        $Ac = OAuthConstants::HOSTNAME . "\x2f\155\157\x61\x73\x2f\141\x70\x69\57\x62\141\143\153\x75\160\143\x6f\x64\145\x2f\165\160\x64\141\164\x65\163\x74\141\164\x75\x73";
        $H1 = array("\143\157\144\145" => $kx, "\143\x75\x73\164\157\x6d\145\x72\x4b\145\171" => $dz);
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function vml($dz, $zR, $kx, $l2)
    {
        $Ac = OAuthConstants::HOSTNAME . "\57\155\157\x61\163\x2f\141\x70\151\x2f\142\x61\x63\x6b\165\160\143\157\x64\145\57\166\x65\162\151\x66\171";
        $H1 = array("\x63\157\144\x65" => $kx, "\x63\165\x73\x74\x6f\x6d\x65\162\113\x65\171" => $dz, "\141\144\x64\x69\x74\x69\x6f\156\x61\x6c\106\x69\145\x6c\144\x73" => array("\x66\x69\145\154\144\x31" => $l2));
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
    public static function ccl($dz, $zR)
    {
        $Ac = OAuthConstants::HOSTNAME . "\57\155\x6f\141\163\x2f\162\145\x73\164\57\x63\165\x73\x74\157\155\145\162\x2f\x6c\151\x63\145\156\x73\x65";
        $H1 = array("\x63\x75\x73\164\x6f\155\145\162\111\x64" => $dz, "\x61\x70\160\x6c\x69\143\x61\164\151\157\156\116\141\x6d\x65" => "magento_oauth_enterprise_plan");
        $hF = self::createAuthHeader($dz, $zR);
        $um = self::callAPI($Ac, $H1, $hF);
        return $um;
    }
}

Function Calls

None

Variables

None

Stats

MD5 f401c99e098444bc1796f8406ebd4b3e
Eval Count 0
Decode Time 77 ms