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 /* Dev By Hoang Skyht 18-06-2024 */$OOO000000=urldecode('%66%67%36%73%62%65%68%70%72..

Decoded Output download

$O000O0O00=$OOO000O00($OOO0O0O00,'rb');$O0O00OO00($O000O0O00,0x4a9);$OO00O00O0=$OOO0000O0($OOO00000O($O0O00OO00($O000O0O00,0x17c),'EnteryouwkhRHYKNWOUTAaBbCcDdFfGgIiJjLlMmPpQqSsVvXxZz0123456789+/=','ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/'));eval($OO00O00O0);$OO00O00O0=str_replace('__FILE__',"'".$OOO0O0O00."'",$OOO0000O0($OOO00000O($O0O00OO00($O000O0O00,$OO00O0000),'EnteryouwkhRHYKNWOUTAaBbCcDdFfGgIiJjLlMmPpQqSsVvXxZz0123456789+/=','ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/')));fclose($O000O0O00);eval($OO00O00O0);
namespace App\Console\Commands;
use App\Models\Order;
use App\Models\User;
use Illuminate\Console\Command;
use Illuminate\Support\Facades\DB;
class CheckCommission extends Command
{
protected $signature = 'check:commission';
protected $description = '';
public function __construct()
{
parent::__construct();
}
public function handle()
{
$this->_autoCheck();
$this->_autoPayCommission();
}
private function _autoCheck()
{
if ((int)config('v2board.commission_auto_check_enable',1)) {
$this->info("commission auto check enable");
$commissionCheckTime = config('v2board.commission_check_time',72);
$commissionCheckTimeHour =  $commissionCheckTime  * 3600;
$result = Order::where(Order::FIELD_COMMISSION_STATUS,Order::COMMISSION_STATUS_NEW)
->where(Order::FIELD_INVITE_USER_ID,'>',0)
->where(Order::FIELD_STATUS,Order::STATUS_COMPLETED)
->update([
Order::FIELD_COMMISSION_STATUS =>Order::COMMISSION_STATUS_PENDING
]);
$this->info("update commission status. result :".$result);
}else {
$this->info("commission auto check disable");
}
}
private function _autoPayCommission()
{
$orders = Order::where(Order::FIELD_COMMISSION_STATUS,Order::COMMISSION_STATUS_PENDING)
->where(Order::FIELD_INVITE_USER_ID,'>',0)
->get();
DB::beginTransaction();
$configWithdrawCloseEnable = (bool)config('v2board.withdraw_close',0);
if ($configWithdrawCloseEnable) {
$this->info("withdraw close enable");
}else {
$this->info("withdraw close disable");
}
$this->info("find pay commission orders count :".count($orders));
foreach ($orders as $order) {
$inviter = User::find($order->getAttribute(User::FIELD_INVITE_USER_ID));
if ($inviter === null) {
$this->warn("inviter not found. user_id: ".$order->getAttribute(User::FIELD_INVITE_USER_ID));
continue;
}
$inviter->setAttribute(User::FIELD_BALANCE,$inviter->getAttribute(User::FIELD_BALANCE) +$order->getAttribute(Order::FIELD_COMMISSION_BALANCE));
if (!$inviter->save()) {
$this->error("inviter save failed. user_id : ".$inviter->getKey());
DB::rollBack();
break;
}
$order->setAttribute(Order::FIELD_COMMISSION_STATUS,Order::COMMISSION_STATUS_VALID);
if (!$order->save()) {
$this->error("order save failed. user_id : ".$order->getKey());
DB::rollBack();
break;
}
}
DB::commit();
}
};

Did this file decode correctly?

Original Code

<?php /* Dev By Hoang Skyht 18-06-2024 */$OOO000000=urldecode('%66%67%36%73%62%65%68%70%72%61%34%63%6f%5f%74%6e%64');$OOO0000O0=$OOO000000{4}.$OOO000000{9}.$OOO000000{3}.$OOO000000{5};$OOO0000O0.=$OOO000000{2}.$OOO000000{10}.$OOO000000{13}.$OOO000000{16};$OOO0000O0.=$OOO0000O0{3}.$OOO000000{11}.$OOO000000{12}.$OOO0000O0{7}.$OOO000000{5};$OOO000O00=$OOO000000{0}.$OOO000000{12}.$OOO000000{7}.$OOO000000{5}.$OOO000000{15};$O0O000O00=$OOO000000{0}.$OOO000000{1}.$OOO000000{5}.$OOO000000{14};$O0O000O0O=$O0O000O00.$OOO000000{11};$O0O000O00=$O0O000O00.$OOO000000{3};$O0O00OO00=$OOO000000{0}.$OOO000000{8}.$OOO000000{5}.$OOO000000{9}.$OOO000000{16};$OOO00000O=$OOO000000{3}.$OOO000000{14}.$OOO000000{8}.$OOO000000{14}.$OOO000000{8};$OOO0O0O00=__FILE__;$OO00O0000=0xb90;eval($OOO0000O0('JE8wMDBPME8wMD0kT09PMDAwTzAwKCRPT08wTzBPMDAsJ3JiJyk7JE8wTzAwT08wMCgkTzAwME8wTzAwLDB4NGE5KTskT08wME8wME8wPSRPT08wMDAwTzAoJE9PTzAwMDAwTygkTzBPMDBPTzAwKCRPMDAwTzBPMDAsMHgxN2MpLCdFbnRlcnlvdXdraFJIWUtOV09VVEFhQmJDY0RkRmZHZ0lpSmpMbE1tUHBRcVNzVnZYeFp6MDEyMzQ1Njc4OSsvPScsJ0FCQ0RFRkdISUpLTE1OT1BRUlNUVVZXWFlaYWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXowMTIzNDU2Nzg5Ky8nKSk7ZXZhbCgkT08wME8wME8wKTs='));return;?>trC`LoC}cbDq\sXZpIkr9NHenNHenNHe1zfukgFMaXdoyjcUImb19oUAxyb18mRtwmwJ4LT09NHr8XTzEXRJwmwJXLT09NHeEXHr8XhtONT08XHeEXHr8Pkr8XTzEXT08XHtILTzEXHr8XTzEXRtONTzEXTzEXHeEpRtfydmOlFmlvfbfqDykwBAsKa09aaryiWMkeC0OLOMcuc0lpUMpHdr1sAunOFaYzamcCGyp6HerZHzW1YjF4KUSvNUFSk0ytW0OyOLfwUApRTr1KT1nOAlYAaacbBylDCBkjcoaMc2ipDMsSdB5vFuyZF3O1fmf4GbPXHTwzYeA2YzI5hZ8mhULpK2cjdo9zcUILTzEXHr8XTzEXhTslfMyShtONTzEXTzEXTzEpKX==tM5idBazFoyjcUnnFunFW29VF29Scaxed21sCB5LFzShfbYlwryXFyxYd2OlduYFT3kLcbw7tmazcUnnFunFTB9LcBxzbyazcbw7tmazcUnkdox1dBlVCbOlbrYvdmYvdoaFW29sdByVceShfbYlwrlSduasDB5ifoaFA3aXFo9ZfyxoCBYicoazbrOtKXpjdoyzFZneDoajD0YvdB1pF3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foAPabYlFjP6OLlyTrOgWLyHWA5eOULIhZOvFMOlFJ0+c2a0WbO0FMlJfbOlhr9ZcoaZKjpoUAaHOy9eT01YUaYTUA9Kb0knTryKW0AphTShDBCIhtrLDB52DbOlFJ0+F2y2cUIphUn7tJO0DolzRT5lFmkvFJIJDB52DbOlFJnzCbclwociDBxlct4IfbYlFl9pctE6wtwVkolVfMl0cbwsNMflfrslGUIphTShOrw6KmkvdoxtCBYqhtL7tMkZcByqKXp9tJOvFMOlFJ0+F2a0WbO0FMlJfbOlhr9ZcoaZKjpoUAaHOy9eT01YUaYTUA9Kb1YAWaOaAZxNFMOlFjP6W09YTAlTA0lNTl9TaryAaaYgaLyHUAWpKXppcJEPwUOvFMOlFJ0+F2y2cUIphUn7tJO0DolzRT5lFmkvFJIJd3kLcbwIF2y2cUnMCBlScBWVwuazcbkgDBWIKJEJRJOvFMOlFJ0+c2a0U2a5htLpKXprWjP6FM9SdrkiC2SPhTShCmklCBS7tm0hgWprWjP6C29sdBl0htL7tm0hgTS=aatuwPZmJc{}IaTyBlNv

Function Calls

fopen 1
fread 3
strtr 2
fclose 1
urldecode 1
str_replace 1
base64_decode 3

Variables

$O000O0O00 True
$O0O000O00 fgets
$O0O000O0O fgetc
$O0O00OO00 fread
$OO00O0000 2960
$OO00O00O0 namespace App\Console\Commands; use App\Models\Order; use A..
$OOO000000 fg6sbehpra4co_tnd
$OOO00000O strtr
$OOO0000O0 base64_decode
$OOO000O00 fopen
$OOO0O0O00 index.php

Stats

MD5 b1e500b75149d4f5c4d92385c7d2b855
Eval Count 3
Decode Time 89 ms