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\Observer; use Magento\Framework\Event\Observer; ..
Decoded Output download
<?php
namespace MiniOrange\OAuth\Observer;
use Magento\Framework\Event\Observer;
use Magento\Framework\Event\ObserverInterface;
use Magento\Framework\App\ResponseFactory;
use Magento\Framework\UrlInterface;
use MiniOrange\OAuth\Helper\OAuthUtility;
use Magento\Framework\App\RequestInterface;
use MiniOrange\OAuth\Helper\OAuthConstants;
class CustomerPasswordGrant implements ObserverInterface
{
protected $responseFactory;
protected $url;
protected $oauthUtility;
protected $request;
public function __construct(ResponseFactory $X6, UrlInterface $ci, OAuthUtility $qZ, RequestInterface $DS)
{
$this->responseFactory = $X6;
$this->url = $ci;
$this->request = $DS;
$this->oauthUtility = $qZ;
}
public function execute(Observer $LNl)
{
$SB = $this->request->getParams();
$HU = $this->oauthUtility->getOAuthClientApps();
$XB = null;
$CJ = null;
foreach ($HU as $JZ) {
$Ig = $JZ->getData()["app_name"];
$this->oauthUtility->setSessionData(OAuthConstants::APP_NAME, $Ig);
$this->oauthUtility->setAdminSessionData(OAuthConstants::APP_NAME, $Ig);
$XB = $JZ->getData();
$CJ = $XB["grant_type"];
VW:
}
wb:
if (!($CJ == "password_grant")) {
goto EC;
}
$this->oauthUtility->setSessionData(OAuthConstants::USERNAME, $SB["login"]["username"]);
$this->oauthUtility->setSessionData(OAuthConstants::PASSWORD, $SB["login"]["password"]);
$ci = $this->oauthUtility->getBaseUrl() . "mooauth/actions/ReadAuthorizationResponse";
header("location: {$ci}");
exit;
EC:
}
}
?>
Did this file decode correctly?
Original Code
<?php
namespace MiniOrange\OAuth\Observer;
use Magento\Framework\Event\Observer;
use Magento\Framework\Event\ObserverInterface;
use Magento\Framework\App\ResponseFactory;
use Magento\Framework\UrlInterface;
use MiniOrange\OAuth\Helper\OAuthUtility;
use Magento\Framework\App\RequestInterface;
use MiniOrange\OAuth\Helper\OAuthConstants;
class CustomerPasswordGrant implements ObserverInterface
{
protected $responseFactory;
protected $url;
protected $oauthUtility;
protected $request;
public function __construct(ResponseFactory $X6, UrlInterface $ci, OAuthUtility $qZ, RequestInterface $DS)
{
$this->responseFactory = $X6;
$this->url = $ci;
$this->request = $DS;
$this->oauthUtility = $qZ;
}
public function execute(Observer $LNl)
{
$SB = $this->request->getParams();
$HU = $this->oauthUtility->getOAuthClientApps();
$XB = null;
$CJ = null;
foreach ($HU as $JZ) {
$Ig = $JZ->getData()["\141\160\x70\137\156\141\155\145"];
$this->oauthUtility->setSessionData(OAuthConstants::APP_NAME, $Ig);
$this->oauthUtility->setAdminSessionData(OAuthConstants::APP_NAME, $Ig);
$XB = $JZ->getData();
$CJ = $XB["\147\x72\141\x6e\x74\137\164\x79\160\x65"];
VW:
}
wb:
if (!($CJ == "\x70\x61\163\x73\167\x6f\x72\x64\x5f\147\x72\x61\x6e\164")) {
goto EC;
}
$this->oauthUtility->setSessionData(OAuthConstants::USERNAME, $SB["\154\x6f\x67\x69\156"]["\165\163\x65\162\x6e\x61\155\x65"]);
$this->oauthUtility->setSessionData(OAuthConstants::PASSWORD, $SB["\154\157\x67\151\156"]["\160\141\163\163\x77\x6f\162\x64"]);
$ci = $this->oauthUtility->getBaseUrl() . "\x6d\157\x6f\141\165\164\x68\57\x61\143\164\x69\157\156\x73\x2f\122\145\141\x64\x41\x75\x74\150\x6f\162\151\172\141\164\151\x6f\x6e\122\145\163\160\x6f\x6e\163\x65";
header("\x6c\x6f\x63\x61\164\x69\x6f\156\x3a\40{$ci}");
exit;
EC:
}
}
Function Calls
None |
Stats
MD5 | 5b9fbe57f65000d68ebdf5a0202be86f |
Eval Count | 0 |
Decode Time | 50 ms |