Japanese English

PHP 難読化コードの復元・デコード

Wordpress 等でのPHPのマルウェア・ウィルス・改ざんコードをデコードして難読化をオンラインで解除し、
元の読みやすいコードに戻し解読できます。

※すべての難読化コードを解除できるわけではございませんのでご理解とご了承をお願いいたします。

下記のコードを難読化解除しました

<?php namespace WebGongbang\SQLCache; class G5SQLCache { private $VqO7K; public function __construct($SDwaq) { goto kvNqF; ICxLn: kRPje: $this->VqO7K = new G5RedisCache(); il57s: goto dm_D2; PBs1i: if ($SDwaq == "\146\x69\154\x65") { goto F7z2L; } $this->VqO7K = new G5NoCache(); goto cxbVh;...



難読化されたPHPコード

<?php
 namespace WebGongbang\SQLCache; class G5SQLCache { private $VqO7K; public function __construct($SDwaq) { goto kvNqF; ICxLn: kRPje: $this->VqO7K = new G5RedisCache(); il57s: goto dm_D2; PBs1i: if ($SDwaq == "\146\x69\154\x65") { goto F7z2L; } $this->VqO7K = new G5NoCache(); goto cxbVh; goto kNBa9; kvNqF: if ($SDwaq == "\x72\145\x64\151\163") { goto kRPje; } if ($SDwaq == "\x6d\145\155\x63\x61\x63\x68\x65\144") { goto P9En9; } if ($SDwaq == "\141\160\x63\165") { goto rSUUI; } goto PBs1i; kNBa9: F7z2L: $this->VqO7K = new G5SqlFile(); cxbVh: goto iFTa1; CUd5T: mP4HZ: goto qBp6G; P9En9: goto k1RLt; iFTa1: goto mP4HZ; rSUUI: $this->VqO7K = new G5APCu(); goto CUd5T; k1RLt: $this->VqO7K = new G5Memcached(); qBp6G: goto il57s; goto ICxLn; dm_D2: } public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { return call_user_func_array(array($this->VqO7K, "\146\145\x74\143\x68"), array($V1exn, $c30Ly, $DFg1e)); } public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { return new SCIterator(call_user_func_array(array($this->VqO7K, "\161\x75\x65\162\x79\x5f\154\x69\163\x74"), array($V1exn, $c30Ly, $DFg1e))); } public function clean($c30Ly) { return call_user_func(array($this->VqO7K, "\x63\154\145\141\x6e"), $c30Ly); } } class SCLogger { public static function dbg($uWqIE, $KlnWV = false) { goto AGzMX; ZpjHS: $uWqIE = sprintf("\133\x25\163\40\72\40\45\x73\x2d\x3e\x25\x73\x28\51\x5d\40\45\163\40\x2d\55\55\x5b\105\122\x52\x4f\122\x5d" . PHP_EOL, date("\131\x2d\155\x2d\144\40\x48\x3a\151\x3a\x73"), $MgTpG, $maowd, $uWqIE); kGA56: if (!SC_DEBUG_FILE) { goto VZH4P; } goto WzKb4; zTCJK: echo $uWqIE . "\74\142\162\76"; XopRq: goto kZ0sn; d3JYZ: return; e1plr: $eUDhr = debug_backtrace(); goto qZ7Ts; kzoHQ: $uWqIE = sprintf("\133\x25\x73\40\x3a\x20\x25\x73\x2d\76\x25\x73\x28\51\135\40\45\163" . PHP_EOL, date("\131\x2d\x6d\x2d\x64\x20\x48\x3a\151\72\163"), $MgTpG, $maowd, $uWqIE); goto kGA56; TGRWE: goto ZpjHS; WzKb4: file_put_contents($d8dbk, $uWqIE, FILE_APPEND); VZH4P: if (!($is_admin == "\x73\165\x70\x65\x72" && $member["\x6d\142\137\151\x64"] == SC_DEBUG_MB_ID && SC_DEBUG_PRINT)) { goto XopRq; } goto zTCJK; qZ7Ts: $maowd = $eUDhr[1]["\146\x75\156\x63\164\151\x6f\156"]; $MgTpG = str_replace(__NAMESPACE__ . "\x5c", '', $eUDhr[1]["\143\x6c\141\163\x73"]); if ($KlnWV) { goto TGRWE; } goto kzoHQ; AGzMX: global $is_admin, $member; $d8dbk = G5_DATA_PATH . "\57\163\161\x6c\55\143\141\143\150\145\56\154\x6f\x67"; if (!(!SC_DEBUG_FILE && !SC_DEBUG_PRINT)) { goto e1plr; } goto d3JYZ; kZ0sn: } } interface G5SQLCacheOP { public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL); public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL); public function clean($c30Ly); public function cleanAll(); } class G5NoCache implements G5SQLCacheOP { public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { return sql_fetch($V1exn); } public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { goto kCaqo; nYDse: if (!($XSjmB = sql_fetch_array($oadpG))) { goto qGOjD; } $g1Lqc[] = $XSjmB; goto e1qlq; goto E7wh2; E7wh2: qGOjD: return $g1Lqc; goto WrqGB; kCaqo: $g1Lqc = array(); $oadpG = sql_query($V1exn); e1qlq: goto nYDse; WrqGB: } public function clean($c30Ly) { } public function cleanAll() { } } class SqlCache { public function __construct() { $this->vzsbk = "\x66\x34\x64\145\63\x37\x32\64\x34\61\144\x39\143\144\x30\x61"; $this->I0S0B = constant("\107\x35\137\104\101\124\101\137\x50\101\x54\x48") . "\x2f\163\161\x6c\55\143\141\x63\x68\145\x2e\x64\x61\164\x61"; $this->hasLicenseFile(); } private function uAkh1() { $oadpG = openssl_random_pseudo_bytes(16); return $oadpG; } private function y0wB1($yeJ0v, $F_evk, $hioqW) { goto DcgVl; JlB27: return base64_encode($RoHFP . "\72\x3a" . $hioqW); goto LmC0n; L2_A5: XOY5Y: $RoHFP = openssl_encrypt($yeJ0v, "\x61\145\163\55\x32\65\66\55\x63\142\x63", $F_evk); sCAt2: goto JlB27; DcgVl: if (version_compare(phpversion(), "\x35\56\x33\x2e\x33") < 0) { goto XOY5Y; } $RoHFP = openssl_encrypt($yeJ0v, "\x61\x65\163\55\62\65\x36\x2d\x63\x62\x63", $F_evk, 0, $hioqW); goto sCAt2; goto L2_A5; LmC0n: } private function j1HcD($yeJ0v) { $yeJ0v = base64_decode($yeJ0v); if (!stristr($yeJ0v, "\72\x3a")) { goto iSB5B; } return explode("\x3a\x3a", $yeJ0v, 2); iSB5B: return array(); } private function dnmL3($RoHFP, $F_evk, $hioqW) { if (version_compare(phpversion(), "\65\56\63\56\63") < 0) { goto nLbMA; } return openssl_decrypt($RoHFP, "\x61\145\163\x2d\62\65\66\55\x63\142\x63", $F_evk, 0, $hioqW); goto xHurN; nLbMA: return openssl_decrypt($RoHFP, "\141\x65\x73\55\62\65\x36\55\x63\x62\x63", $F_evk); xHurN: } private function W2l1H($yeJ0v, $F_evk) { $RoHFP = null; if (!(!empty($yeJ0v) && !empty($F_evk))) { goto VCE1a; } $hioqW = $this->uaKh1(); $RoHFP = $this->Y0WB1($yeJ0v, $F_evk, $hioqW); VCE1a: return $RoHFP; } private function vkCPT($yeJ0v, $F_evk) { goto aiaud; XDxc8: if (!(!empty($MQYMl) && count($MQYMl) == 2)) { goto Qq7vc; } list($RoHFP, $hioqW) = $MQYMl; $Inb5Z = $this->DNML3($RoHFP, $F_evk, $hioqW); goto PQ3YF; PQ3YF: Qq7vc: GdU09: return $Inb5Z; goto h4vAk; aiaud: $Inb5Z = null; if (!(!empty($yeJ0v) && !empty($F_evk))) { goto GdU09; } $MQYMl = $this->J1HCd($yeJ0v); goto XDxc8; h4vAk: } private function L80Np($Yflp4 = null) { goto CNQD0; mwwSZ: $HEZ24 = $_SERVER["\121\125\x45\x52\131\x5f\123\124\x52\111\x4e\107"]; a83xD: if (!(!empty($lfNgD) && !empty($DkCvx) && !empty($DfSw8))) { goto bhIOv; } goto E355d; M_1k3: $DfSw8 = $_SERVER["\123\x43\x52\111\x50\x54\137\x4e\101\115\105"]; MZeZF: if (!isset($_SERVER["\x51\125\x45\x52\x59\x5f\123\x54\122\111\116\x47"])) { goto a83xD; } goto mwwSZ; bRIJ1: $HEZ24 = null; $WmzNF = null; if (!(isset($_SERVER["\x48\124\x54\120\x53"]) && $_SERVER["\110\x54\124\120\123"] !== "\157\x66\146" || isset($_SERVER["\110\124\124\x50\x5f\130\x5f\x46\x4f\x52\127\x41\122\104\105\x44\137\120\122\x4f\124\x4f"]) && $_SERVER["\110\124\x54\120\x5f\130\137\x46\117\122\x57\101\x52\x44\x45\104\x5f\120\x52\x4f\x54\117"] == "\x68\164\164\160\163")) { goto zk4l7; } goto KE9L7; CNQD0: $lfNgD = "\150\164\x74\160"; $DkCvx = null; $DfSw8 = null; goto bRIJ1; KE9L7: $lfNgD = "\150\x74\x74\x70\x73"; zk4l7: if (!isset($_SERVER["\110\124\x54\120\137\x48\x4f\123\124"])) { goto mBSmU; } goto eMFUF; AAcsQ: k97w0: NOEB4: bhIOv: goto TUnzu; r96YM: BHyZJ: if (!($Yflp4 == 1)) { goto NOEB4; } A0wf8: goto mvtAx; mvtAx: if (!(substr($WmzNF, -1) == "\57")) { goto k97w0; } $WmzNF = substr($WmzNF, 0, -1); goto A0wf8; goto AAcsQ; E355d: $WmzNF = $lfNgD . "\x3a\x2f\x2f" . $DkCvx . $DfSw8; if (empty($HEZ24)) { goto BHyZJ; } $WmzNF .= "\77" . $HEZ24; goto r96YM; TUnzu: return $WmzNF; goto Tn0vt; eMFUF: $DkCvx = $_SERVER["\x48\x54\124\x50\137\x48\x4f\123\124"]; mBSmU: if (!isset($_SERVER["\x53\103\122\111\x50\x54\x5f\116\101\115\105"])) { goto MZeZF; } goto M_1k3; Tn0vt: } private function jbwee($pD5Wx) { goto lvZG2; txPSZ: if (!empty($iYurW["\163\143\x68\x65\155\x65"])) { goto rF8ks; } $pD5Wx = "\150\x74\164\160\x3a\57\57" . $pD5Wx; $iYurW = parse_url($pD5Wx); goto pNRlU; iBpRc: return $d16u5; goto Nhoxr; dSzIW: $d16u5 = trim(str_ireplace("\167\x77\x77\x2e", '', filter_var($d16u5, FILTER_SANITIZE_URL))); OAEaZ: xGcvI: goto iBpRc; lvZG2: $d16u5 = null; if (empty($pD5Wx)) { goto xGcvI; } $iYurW = parse_url($pD5Wx); goto txPSZ; pNRlU: rF8ks: if (empty($iYurW["\x68\157\x73\164"])) { goto OAEaZ; } $d16u5 = $iYurW["\x68\x6f\x73\x74"]; goto dSzIW; Nhoxr: } private function GiWE4($pD5Wx, $C72Xe, $AelfL, $AfjHw, $Yflp4) { goto Ox1ta; xXmGQ: if (!($AelfL == 1)) { goto cmI03; } $pD5Wx = str_ireplace("\167\x77\x77\x2e", '', $pD5Wx); cmI03: goto UxZH3; bKbAq: $pD5Wx = substr($pD5Wx, 0, -1); goto vdBpH; hOWmB: goto rr0gQ; cHGjv: CSAOZ: $TJg17 = stripos($pD5Wx, "\57"); if (!($TJg17 > 0)) { goto FCE5g; } goto JcGvj; fHF_e: if ($AfjHw == 1) { goto CSAOZ; } $hi6RM = strripos($pD5Wx, "\57"); if (!($hi6RM > 0)) { goto rd0UL; } goto UjL6_; UjL6_: $pD5Wx = substr($pD5Wx, 0, $hi6RM + 1); rd0UL: goto x3VNY; goto cHGjv; lN1LV: if (!($C72Xe != 1)) { goto ILBCm; } $pD5Wx = $iYurW["\x73\143\x68\145\155\145"] . "\x3a\x2f\x2f" . $pD5Wx; ILBCm: goto xXmGQ; JcGvj: $pD5Wx = substr($pD5Wx, 0, $TJg17 + 1); FCE5g: x3VNY: goto lN1LV; rr0gQ: JnuyR: IGWJZ: return trim($pD5Wx); goto HyJzy; Ox1ta: if (!filter_var($pD5Wx, FILTER_VALIDATE_URL)) { goto IGWJZ; } $iYurW = parse_url($pD5Wx); $pD5Wx = str_ireplace($iYurW["\163\x63\x68\x65\x6d\x65"] . "\x3a\57\x2f", '', $pD5Wx); goto fHF_e; UxZH3: if (!($Yflp4 == 1)) { goto JnuyR; } vdBpH: if (!(substr($pD5Wx, -1) == "\x2f")) { goto hOWmB; } goto bKbAq; HyJzy: } private function g37Lp($pD5Wx, $PnMOF = null) { goto xw5pw; eda_q: $yZFYU["\150\145\x61\144\x65\162\x73"] = $pWIJl; $yZFYU["\145\x72\x72\157\x72"] = $DE77c; $yZFYU["\142\x6f\144\x79"] = $AGjyW; goto IAw4K; xw5pw: $yZFYU = array(); $pWIJl = array(); list($AGjyW, $DE77c) = $this->JbEx0($pD5Wx, $PnMOF, array("\150\x65\x61\x64\x65\x72\137\146\x75\x6e\143\x74\151\x6f\156" => function ($qUiAp, $cW3Z_) use(&$pWIJl) { goto izv_l; mwAE0: return $O3gDS; KXgVL: $HSLRi = strtolower(trim($cW3Z_[0])); goto PDluX; PDluX: $pWIJl[$HSLRi] = trim($cW3Z_[1]); return $O3gDS; goto UHiVv; izv_l: $O3gDS = strlen($cW3Z_); $cW3Z_ = explode("\72", $cW3Z_, 2); if (!(count($cW3Z_) < 2)) { goto KXgVL; } goto mwAE0; UHiVv: }, "\162\x65\146\145\162" => $this->giwe4($this->L80Np(), 0, 0, 1, 1))); goto eda_q; IAw4K: return $yZFYU; goto dqjoj; dqjoj: } private function JBEX0($pD5Wx, $PnMOF = null, $v5Ekg = array()) { goto MBWDp; mmt2U: $this->RkmfW("\x73\x65\164\157\x70\164", array($If00n, CURLOPT_TIMEOUT, $v5Ekg["\143\x6f\156\x6e\145\143\164\x5f\164\x69\x6d\145\157\x75\164"])); $this->rKMFw("\163\145\x74\157\160\x74", array($If00n, CURLOPT_REFERER, $v5Ekg["\162\145\146\x65\162"])); $this->rkMfw("\x73\x65\x74\157\x70\164", array($If00n, CURLOPT_POST, 1)); goto A_6pM; WSxid: if (!$v5Ekg["\x68\145\x61\x64\145\162\x5f\146\x75\x6e\143\164\151\157\x6e"]) { goto nWivn; } $this->rkMFW("\x73\x65\x74\x6f\160\164", array($If00n, CURLOPT_HEADERFUNCTION, $v5Ekg["\x68\x65\x61\144\145\162\x5f\146\165\156\x63\x74\x69\157\x6e"])); nWivn: goto EN8Wt; J2axh: $this->rkmfw("\163\x65\164\157\160\164", array($If00n, CURLOPT_RETURNTRANSFER, 1)); $this->RkMfw("\163\145\164\x6f\x70\x74", array($If00n, CURLOPT_FOLLOWLOCATION, 1)); $this->rKMfw("\x73\x65\x74\157\x70\x74", array($If00n, CURLOPT_MAXREDIRS, 10)); goto WSxid; EeQF9: return array($AGjyW, $Lc0Hk); goto mOpAc; Ie3md: $v5Ekg["\162\145\x66\145\x72"] = $pD5Wx; T08Pf: $If00n = $this->rKMFW("\x69\x6e\151\164"); goto q4Gln; q4Gln: $this->RkMfW("\163\145\x74\x6f\x70\164", array($If00n, CURLOPT_URL, $pD5Wx)); $this->RkmfW("\163\x65\164\x6f\160\164", array($If00n, CURLOPT_USERAGENT, $v5Ekg["\165\163\145\x72\x5f\141\x67\x65\x6e\x74"])); $this->RkMfW("\x73\145\164\x6f\160\x74", array($If00n, CURLOPT_CONNECTTIMEOUT, $v5Ekg["\x63\x6f\x6e\156\145\143\x74\137\x74\151\x6d\145\157\x75\164"])); goto mmt2U; EN8Wt: $AGjyW = $this->RkMfw("\x65\170\145\x63", array($If00n)); $Lc0Hk = $this->RkMfW("\145\x72\x72\x6f\x72", array($If00n)); $this->rkMFw("\143\154\157\163\145", array($If00n)); goto EeQF9; A_6pM: $this->rKmFw("\163\145\164\157\x70\x74", array($If00n, CURLOPT_POSTFIELDS, $PnMOF)); $this->rkMfW("\x73\x65\164\157\x70\x74", array($If00n, CURLOPT_SSL_VERIFYPEER, 0)); $this->RKmfw("\163\145\x74\157\x70\x74", array($If00n, CURLOPT_SSL_VERIFYHOST, 0)); goto J2axh; Ry2Ot: return array(false, false); LZYRV: if (!(empty($v5Ekg["\162\145\146\145\x72"]) || !filter_var($v5Ekg["\162\145\x66\145\x72"], constant("\106\111\114\x54\x45\122\x5f\126\101\114\x49\x44\x41\x54\x45\137\125\x52\x4c")))) { goto T08Pf; } goto Ie3md; MBWDp: $mTM_b = array("\165\163\145\x72\137\141\x67\145\156\164" => "\x61\x70\160\x6c\x65\x74\162\x65\x65\x20\143\x55\122\114", "\x63\x6f\x6e\156\145\143\164\137\x74\151\155\145\x6f\165\164" => 10, "\x68\x65\141\x64\145\x72\137\146\165\x6e\x63\x74\151\x6f\156" => null, "\x72\x65\x66\x65\x72" => null); $v5Ekg = array_merge($mTM_b, $v5Ekg); if (!(!filter_var($pD5Wx, constant("\x46\x49\x4c\124\x45\122\137\x56\101\x4c\x49\104\x41\124\x45\137\125\122\x4c")) || empty($PnMOF))) { goto LZYRV; } goto Ry2Ot; mOpAc: } private function RKMFw($vkzEF, $HEZ24 = null) { if (!$HEZ24) { goto ao42i; } return call_user_func_array("\143\165\x72\x6c\x5f" . $vkzEF, $HEZ24); goto Gqqop; ao42i: return call_user_func("\x63\x75\162\154\x5f" . $vkzEF); Gqqop: } private function Jo7To($LPchp, $ae7N0) { goto Mw8VN; Mw8VN: $EbR8s = false; if (!(!empty($LPchp) && !empty($ae7N0))) { goto FzBO7; } $LPchp = \DateTime::createFromFormat($ae7N0, $LPchp); goto JBRcz; YKjbs: TwoHE: FzBO7: return $EbR8s; goto RRfz0; JBRcz: $GmcKC = \DateTime::getLastErrors(); if (!($LPchp && empty($GmcKC["\167\x61\162\156\x69\x6e\x67\137\x63\157\x75\x6e\x74"]))) { goto TwoHE; } $EbR8s = true; goto YKjbs; RRfz0: } private function X1t_6($WyBrT, $sXobk) { goto Z64H9; Jopyo: hn_d6: $qWJls = $WyBrT->diff($sXobk)->format("\45\141"); W4X8b: goto t33E2; Z64H9: $qWJls = 0; if (!($this->JO7To($WyBrT, "\131\x2d\155\55\x64") && $this->jo7to($sXobk, "\131\x2d\155\55\x64"))) { goto W4X8b; } $sXobk = new \DateTime($sXobk); goto FyCxL; FyCxL: $WyBrT = new \DateTime($WyBrT); if (!($sXobk == $WyBrT)) { goto hn_d6; } return 0; goto Jopyo; t33E2: return $qWJls; goto yAnPe; yAnPe: } private function heNAr($dUqFA, $sXcjz, $E48G6, $Tgmud) { goto HQ2pI; HJOj3: GfOvf: Pa2Et: goto ZGbCA; HQ2pI: if (!empty($dUqFA)) { goto hqTUr; } return array(false, implode("\40", array("\354\x84\234\xeb\262\204\xec\x97\x90", "\xec\x97\260\xea\262\260", "\xed\x95\xa0", "\xec\210\x98", "\354\x97\206\xec\x8a\265\353\x8b\210\xeb\x8b\xa4\x2e")), null); goto Pa2Et; goto c3c1n; c3c1n: hqTUr: if (!empty($dUqFA["\x68\x65\141\144\145\162\163"]["\x6e\x6f\164\x69\146\151\143\x61\x74\x69\x6f\156\137\163\x65\x72\x76\145\x72\x5f\163\x69\147\x6e\141\x74\165\162\x65"]) && $this->dbmq7($dUqFA["\x68\145\x61\144\x65\x72\x73"]["\x6e\x6f\164\x69\146\151\143\141\164\151\x6f\156\x5f\x73\x65\x72\166\x65\162\137\x73\151\147\156\x61\x74\165\162\x65"], $sXcjz, $E48G6, $Tgmud)) { goto vGo6a; } return array(false, implode("\40", array("\111\x6e\166\141\x6c\151\x64", "\122\x65\163\x70\x6f\x6e\x73\x65")), null); goto PENF7; PENF7: goto GfOvf; vGo6a: return array($dUqFA["\150\x65\141\x64\145\162\163"]["\156\157\x74\x69\x66\151\143\141\164\151\x6f\156\137\143\x61\163\145"] == implode('', array("\x6e\x6f\x74", "\151\146\151\143\x61\164\x69\x6f\156", "\137\154\151\x63\145\x6e\163", "\x65\x5f\x6f\x6b")), $dUqFA["\150\145\141\144\x65\x72\x73"]["\x6e\157\x74\151\x66\x69\x63\141\164\x69\157\156\137\164\x65\170\164"], !empty($dUqFA["\x68\x65\x61\144\x65\162\163"]["\156\x6f\x74\x69\x66\151\143\x61\x74\x69\157\156\137\x64\141\x74\x61"]) ? json_decode($dUqFA["\150\x65\141\x64\145\x72\163"]["\156\x6f\164\x69\x66\151\x63\x61\x74\x69\x6f\156\x5f\144\x61\164\x61"], true) : null); goto HJOj3; ZGbCA: } private function d3xr0($sXcjz, $E48G6, $Tgmud) { $NYTEB = null; $ee_uV = gethostbynamel($this->JbwEe(implode('', array("\x68\164\164", "\x70\x73\x3a\57", "\x2f\141", "\160\x70", "\163\x2e\142\x79\x66", "\x75\x6e\56\x63\157", "\155")))); if (!(!empty($sXcjz) && isset($E48G6) && isset($Tgmud) && !empty($ee_uV))) { goto c1l_Q; } $NYTEB = hash("\163\150\x61\x32\65\x36", gmdate("\131\55\155\55\144") . $sXcjz . $E48G6 . $Tgmud . 14 . implode('', $ee_uV)); c1l_Q: return $NYTEB; } private function dBMq7($sB6cg, $sXcjz, $E48G6, $Tgmud) { goto c8hN0; gzRz1: if (!(hash("\163\150\x61\x32\x35\x36", implode('', $ee_uV) . 14 . $Tgmud . $E48G6 . $sXcjz . gmdate("\x59\55\155\x2d\x64")) == $sB6cg)) { goto MHxpY; } $EbR8s = true; MHxpY: goto U83cb; c8hN0: $EbR8s = false; $ee_uV = gethostbynamel($this->jBwEE(implode('', array("\150\x74\164", "\160\163\72\57", "\57\x61", "\160\160", "\x73\56\142\171\x66", "\x75\x6e\56\143\157", "\x6d")))); if (!(!empty($sB6cg) && !empty($sXcjz) && isset($E48G6) && isset($Tgmud) && !empty($ee_uV))) { goto yAnKh; } goto gzRz1; U83cb: yAnKh: return $EbR8s; goto VFdbr; VFdbr: } private function K5hQl() { goto SN5wi; SN5wi: $Op2V_ = array(); if (file_exists($this->I0S0B)) { goto s9MLJ; } @touch($this->I0S0B); goto a0CEG; a0CEG: s9MLJ: if (@is_writable($this->I0S0B)) { goto ghHLN; } $Op2V_[] = "\354\234\240\xed\x9a\250\xed\225\x98\354\xa7\200\x20\354\225\x8a\354\235\200\x20\353\235\xbc\354\235\264\354\x84\xbc\xec\212\xa4\40\355\214\214\xec\x9d\274\40\xec\240\200\354\x9e\245\x20\352\xb2\xbd\xeb\241\234\x20\50\xed\x98\271\xec\235\200\x20\xec\x93\260\xea\270\xb0\40\353\266\210\352\xb0\x80\x29"; goto hFaH1; hFaH1: ghHLN: return $Op2V_; goto HEz5Z; HEz5Z: } private function getMessage($v1AN0) { $bEx6M = array("\353\235\xbc\xec\x9d\264\354\204\274\354\212\244\x20\xed\214\x8c\xec\x9d\274\354\235\204\40\xec\x9e\x91\354\x84\xb1\xed\x95\240\40\354\210\x98\40\354\x97\206\354\212\xb5\xeb\213\x88\353\x8b\xa4\x2e", "\354\235\264\xeb\xaf\xb8\x20\xec\204\244\354\xb9\x98\xeb\220\230\xec\x96\xb4\40\354\x9e\210\xec\x8a\265\xeb\213\x88\353\x8b\244\x2e"); return $bEx6M[$v1AN0]; } private function Yfulk($K7DfP = 0) { goto UdxXs; LXat_: $zBCaf = 1; TgYHm: goto nTcOi; goto T7Ujx; tpnUF: $YVr53 = $this->hEnAr($dUqFA, $sXcjz, $E48G6, $Tgmud); if ($YVr53[0]) { goto fIiK_; } $oadpG = -30; goto AzOY8; f1b0R: goto nEPsL; VI7HY: $V7_uz = date("\x59\55\155\55\144"); goto v83Eq; f3u7N: if (!($uOif1 === false)) { goto u8L1Y; } $oadpG = -40; return $oadpG; goto KwW3x; X_1xs: $G2A6H = $this->VKCPt($DK1LQ, $this->vzsbk . $g1ho8); if ($this->X1T_6($ejS4h, date("\131\x2d\155\55\144")) < 7 && $ejS4h <= date("\131\x2d\x6d\x2d\x64") && $G2A6H && $K7DfP === 0) { goto Nejou; } $dUqFA = $this->g37Lp($this->ev81M("\x6c\x69\143\145\156\x73\x65\137\x76\145\x72\151\146\171"), $this->y7MOP(array("\160\x72\x6f\x64\x75\x63\x74\137\151\x64" => 14, "\x63\154\x69\145\x6e\x74\137\145\155\141\151\154" => $E48G6, "\x6c\x69\x63\x65\x6e\x73\145\137\143\157\x64\x65" => $Tgmud, "\162\x6f\157\x74\x5f\x75\162\154" => $sXcjz, "\x69\156\x73\x74\141\x6c\x6c\141\164\151\157\x6e\x5f\150\x61\163\x68" => hash("\x73\150\141\x32\65\x36", $sXcjz . $E48G6 . $Tgmud), "\x6c\x69\143\x65\156\163\145\x5f\163\x69\x67\x6e\141\x74\x75\x72\145" => $this->D3XR0($sXcjz, $E48G6, $Tgmud)))); goto tpnUF; T7Ujx: Nejou: $oadpG = 1; nTcOi: goto tekZq; UdxXs: $oadpG = -99; $LMGO3 = 0; $zBCaf = 0; goto XO0tq; AzOY8: goto TgYHm; fIiK_: $oadpG = 2; goto LXat_; qkHKE: if (!($LMGO3 == 1 || $zBCaf == 1)) { goto hyL5c; } if ($zBCaf == 1) { goto VI7HY; } $V7_uz = $ejS4h; goto f1b0R; XO0tq: $QDizh = 0; list($sXcjz, $E48G6, $Tgmud, $V7_uz, $DK1LQ, $g1ho8, $E0Vva) = $this->wycRG(); $ejS4h = $this->vkCPt($V7_uz, $this->vzsbk . $g1ho8); goto X_1xs; tekZq: if (!($G2A6H < date("\x59\55\155\x2d\144"))) { goto z5Wze; } $LMGO3 = 1; z5Wze: goto qkHKE; KwW3x: u8L1Y: @fclose($v6q6E); hyL5c: goto llnoe; v83Eq: nEPsL: $g1ho8 = $this->w2L1H(crypt(date("\x59\55\155\55\144"), null), $this->vzsbk . $sXcjz); $V7_uz = $this->w2l1h($V7_uz, $this->vzsbk . $g1ho8); goto sObPR; sObPR: $DK1LQ = $this->w2L1h(date("\x59\55\155\55\144"), $this->vzsbk . $g1ho8); $v6q6E = @fopen($this->I0S0B, "\167\x2b"); $uOif1 = @fwrite($v6q6E, "\74\122\x4f\x4f\124\137\x55\x52\114\76{$sXcjz}\x3c\x2f\122\117\117\124\x5f\125\122\x4c\x3e\x3c\x43\114\x49\105\116\124\137\105\115\x41\x49\x4c\x3e{$E48G6}\74\57\x43\x4c\x49\105\x4e\124\x5f\105\x4d\101\111\114\76\74\x4c\111\103\105\116\123\105\137\x43\117\104\105\76{$Tgmud}\74\57\114\111\x43\105\116\x53\x45\x5f\x43\x4f\104\x45\76\x3c\x4c\x43\x44\x3e{$V7_uz}\x3c\57\114\x43\x44\x3e\x3c\x4c\122\x44\76{$DK1LQ}\x3c\57\x4c\x52\x44\x3e\74\111\x4e\x53\124\101\x4c\x4c\x41\x54\x49\x4f\x4e\137\x4b\105\131\76{$g1ho8}\x3c\57\x49\x4e\123\124\101\114\x4c\101\124\111\x4f\116\137\113\105\131\x3e\74\x49\x4e\x53\124\x41\x4c\x4c\101\124\111\x4f\116\137\x48\101\123\110\76{$E0Vva}\74\57\x49\116\123\x54\x41\x4c\x4c\x41\x54\x49\117\x4e\x5f\110\x41\x53\x48\x3e"); goto f3u7N; llnoe: return $oadpG; goto ZmnVF; ZmnVF: } private function PgMco() { goto bKF6W; bKF6W: $tLuRB = array(); if (!@is_readable($this->I0S0B)) { goto jNb9e; } $i212M = file_get_contents($this->I0S0B); goto ojS2H; ojS2H: preg_match_all("\57\74\x28\x5b\x41\x2d\x5a\x5f\x5d\x2b\51\x3e\50\56\x2a\x3f\51\x3c\134\57\50\133\101\x2d\x5a\x5f\135\53\x29\76\57", $i212M, $K_83j, PREG_SET_ORDER); if (empty($K_83j)) { goto NeUoB; } foreach ($K_83j as $RhNU1) { if (!(!empty($RhNU1[1]) && $RhNU1[1] == $RhNU1[3])) { goto M1myV; } $tLuRB[$RhNU1[1]] = $RhNU1[2]; M1myV: OCDfi: } goto DeZvw; DeZvw: BjpwB: NeUoB: jNb9e: goto Qot9d; Qot9d: return $tLuRB; goto ruD6g; ruD6g: } private function wYCRG() { goto QKvEL; QKvEL: $dYGiB = $this->pGMcO(); if ($dYGiB) { goto Y3IQh; } return array('', '', '', '', '', '', ''); goto nHWgS; nHWgS: goto jthMZ; Y3IQh: return array($dYGiB["\122\x4f\x4f\x54\x5f\125\122\114"], $dYGiB["\x43\x4c\111\105\116\x54\x5f\x45\x4d\x41\x49\x4c"], $dYGiB["\x4c\111\103\105\x4e\123\105\x5f\x43\117\104\x45"], $dYGiB["\114\x43\x44"], $dYGiB["\114\x52\x44"], $dYGiB["\x49\x4e\x53\124\101\x4c\114\x41\x54\x49\x4f\116\137\x4b\x45\131"], $dYGiB["\111\116\x53\x54\x41\x4c\x4c\101\124\x49\x4f\x4e\137\110\x41\x53\x48"]); goto IZeuz; IZeuz: jthMZ: goto uFdpI; uFdpI: } private function nMSAL($mdVeD = '') { goto yHt84; KMmoF: $TxJaU = 1; $iSdk9 = 1; pEM7D: goto VbzWE; VbzWE: if (!($this->jo7TO($V7_uz, "\x59\55\x6d\x2d\144") && $this->JO7to($DK1LQ, "\131\55\155\55\144") && $V7_uz > $DK1LQ)) { goto Lrwb3; } $TxJaU = 1; $iSdk9 = 1; goto Inexl; yHt84: $TxJaU = 0; $iSdk9 = 0; $qyeOY = false; goto Z_gxY; bZGDz: T4ZPU: if ($this->jO7tO($V7_uz, "\x59\55\x6d\55\x64")) { goto jvidu; } $TxJaU = 1; goto lVTFa; qyvoW: $iSdk9 = 1; iz8fR: if (!($this->JO7tO($DK1LQ, "\131\55\x6d\55\144") && $DK1LQ > date("\x59\55\x6d\x2d\x64", strtotime("\53\61\40\144\141\x79")))) { goto pEM7D; } goto KMmoF; gVmfD: Sb3hw: if (!($this->jo7To($V7_uz, "\x59\55\x6d\x2d\x64") && $V7_uz > date("\x59\x2d\x6d\55\144", strtotime("\53\x31\40\144\141\171")))) { goto iz8fR; } $TxJaU = 1; goto qyvoW; Inexl: Lrwb3: if (!($mdVeD && $mdVeD != $E48G6)) { goto c8xTq; } $TxJaU = 1; goto OkATt; khKpe: $DK1LQ = $this->VKcPT($DK1LQ, $this->vzsbk . $g1ho8); if (!(!filter_var($sXcjz, FILTER_VALIDATE_URL) || !ctype_alnum(substr($sXcjz, -1)))) { goto E50QM; } $TxJaU = 1; goto IX77V; IX77V: E50QM: if (!(filter_var($this->l80Np(), FILTER_VALIDATE_URL) && stristr($this->GIwE4($this->L80nP(), 1, 1, 0, 1), $this->giWe4("{$sXcjz}\57", 1, 1, 0, 1)) === false)) { goto wWBuS; } $TxJaU = 1; goto u1juq; OkATt: c8xTq: if (!($TxJaU != 1 && $iSdk9 != 1)) { goto qptqu; } $qyeOY = true; goto vZ3Wp; lVTFa: jvidu: if ($this->JO7To($DK1LQ, "\x59\55\155\55\144")) { goto Sb3hw; } $TxJaU = 1; goto gVmfD; u1juq: wWBuS: if (!(empty($E0Vva) || $E0Vva != hash("\x73\x68\141\x32\65\x36", $sXcjz . $E48G6 . $Tgmud))) { goto T4ZPU; } $TxJaU = 1; goto bZGDz; Z_gxY: list($sXcjz, $E48G6, $Tgmud, $V7_uz, $DK1LQ, $g1ho8, $E0Vva) = $this->wYCrg(); if (!(!empty($sXcjz) && !empty($E0Vva) && !empty($g1ho8) && !empty($V7_uz) && !empty($DK1LQ))) { goto Rp3KF; } $V7_uz = $this->VkCpT($V7_uz, $this->vzsbk . $g1ho8); goto khKpe; vZ3Wp: qptqu: Rp3KF: return $qyeOY; goto Efbij; Efbij: } private function Y7moP($arYNQ) { $mmp8R = array(); foreach ($arYNQ as $hxu0L => $APXvi) { $mmp8R[] = sprintf("\45\x73\75\45\x73", $hxu0L, rawurlencode($APXvi)); hhkCe: } EWzCo: return implode("\x26", $mmp8R); } private function eV81m($mVpcf) { return sprintf("\x25\163\57\141\x70\x6c\x5f\143\141\x6c\154\x62\x61\143\x6b\x73\x2f\45\x73\56\x70\x68\x70", implode('', array("\x68\x74\x74", "\x70\x73\72\x2f", "\x2f\x61", "\160\160", "\x73\56\142\x79\146", "\165\156\56\143\157", "\155")), $mVpcf); } protected function hasLicenseFile() { goto a3FRo; a3FRo: static $H0ApE = null; if (!($H0ApE !== null)) { goto Mbpqh; } return $H0ApE; goto lXPd6; lXPd6: Mbpqh: if (!(!file_exists($this->I0S0B) || filesize($this->I0S0B) == 0)) { goto dXc3U; } $this->SLhoS(); goto ylOia; YRaQZ: MM2yP: $H0ApE = true; v2hRs: goto a888k; b_8zZ: $this->slhos(); if (!(time() - filemtime($this->I0S0B) > 24 * 3600)) { goto oNxoA; } touch($this->I0S0B); goto SKTaN; a888k: return $H0ApE; goto xNZle; ylOia: $H0ApE = $this->lqGbh(constant("\x53\103\x5f\x4c\x49\x43\x45\116\x53\x45")); dXc3U: if ($this->nmSaL()) { goto MM2yP; } goto b_8zZ; SKTaN: $H0ApE = $this->yFuLk() > 0; oNxoA: goto v2hRs; goto YRaQZ; xNZle: } private function LqGbh($E48G6, $Tgmud = '', $VRrly = false) { goto gxogw; C2uTm: goto BzXRs; z3LCy: $oadpG = 2; goto UyNMn; OQQEN: $v6q6E = @fopen($this->I0S0B, "\x77\53"); $uOif1 = @fwrite($v6q6E, "\x3c\122\117\117\124\137\125\122\114\x3e{$sXcjz}\x3c\57\x52\117\117\124\x5f\125\x52\x4c\x3e\x3c\x43\x4c\x49\x45\116\x54\137\x45\x4d\101\x49\114\76{$E48G6}\x3c\57\x43\114\111\x45\116\124\x5f\x45\x4d\x41\x49\114\x3e\74\x4c\111\x43\x45\116\123\105\x5f\x43\117\104\x45\76{$Tgmud}\x3c\x2f\x4c\x49\103\x45\x4e\x53\x45\137\103\117\104\105\76\x3c\x4c\x43\104\76{$V7_uz}\74\57\114\103\104\76\x3c\114\122\104\76{$DK1LQ}\74\57\x4c\x52\104\x3e\x3c\111\116\x53\x54\101\114\114\101\124\x49\117\116\x5f\x4b\105\x59\76{$g1ho8}\x3c\57\x49\x4e\123\124\101\x4c\114\101\x54\111\x4f\x4e\x5f\113\x45\x59\x3e\x3c\111\x4e\x53\124\101\x4c\x4c\101\124\111\x4f\x4e\x5f\110\x41\x53\x48\76{$E0Vva}\x3c\57\x49\x4e\123\124\x41\114\114\x41\124\111\x4f\x4e\137\110\x41\x53\110\76"); if (!($uOif1 === false)) { goto mEpMC; } goto Z852C; gxogw: $sXcjz = $this->gIWe4($this->l80Np(), 0, 0, 1, 1); $UVPCe = $this->K5HQl(); if (!$VRrly) { goto kKUwp; } goto hCJ93; UyNMn: $g1ho8 = $this->w2L1H(crypt(date("\x59\55\155\x2d\144"), null), $this->vzsbk . $sXcjz); $V7_uz = $this->w2L1h(date("\131\x2d\x6d\55\x64"), $this->vzsbk . $g1ho8); $DK1LQ = $this->w2L1h(date("\x59\x2d\155\55\x64"), $this->vzsbk . $g1ho8); goto OQQEN; z4yiZ: uLuwS: return true; KhlhP: goto h4i03; h4i03: CrHHr: return false; goto EwmWi; hCJ93: if (!($this->y6VXH() < 0)) { goto uY3j0; } $this->reset(); uY3j0: goto ILMpd; Z852C: return false; mEpMC: @fclose($v6q6E); goto qgGEy; qgGEy: return true; BzXRs: goto KhlhP; goto z4yiZ; jLv5R: $oadpG = $this->heNAr($dUqFA, $sXcjz, $E48G6, $Tgmud); if ($oadpG[0]) { goto z3LCy; } return false; goto C2uTm; ILMpd: kKUwp: if (!empty($UVPCe)) { goto CrHHr; } list($byqIv, $gRmJB, $y1EPA, $lIsMK, $Do18W, $zLNa4, $d_h8F) = $this->WyCRg(); goto tBGej; tBGej: if (!empty($byqIv) && (!empty($gRmJB) || !empty($y1EPA))) { goto uLuwS; } $E0Vva = hash("\x73\x68\x61\x32\x35\x36", $sXcjz . $E48G6 . $Tgmud); $dUqFA = $this->G37Lp($this->Ev81m("\154\151\x63\145\x6e\163\145\137\x69\156\x73\164\141\154\x6c"), $this->y7mop(array("\160\x72\x6f\x64\x75\143\164\137\x69\x64" => 14, "\143\x6c\151\145\156\x74\x5f\x65\155\x61\151\154" => $E48G6, "\154\x69\143\x65\156\x73\145\x5f\x63\157\x64\145" => $Tgmud, "\162\157\x6f\x74\137\x75\x72\x6c" => $sXcjz, "\151\x6e\163\164\141\154\x6c\x61\164\x69\157\156\x5f\x68\x61\163\150" => $E0Vva, "\x6c\151\x63\x65\x6e\x73\x65\137\x73\x69\147\x6e\141\x74\165\x72\145" => $this->d3XR0($sXcjz, $E48G6, $Tgmud)))); goto jLv5R; EwmWi: } private function reset() { @unlink($this->I0S0B); } private function y6vXh() { goto yrNQm; eJdSd: return 1; hOqh_: BQlJj: goto iniYq; jMmUX: if ($this->nmsAL()) { goto ruhuz; } $oadpG = -1; goto BQlJj; goto Zg4Yy; Zg4Yy: ruhuz: list($sXcjz, $E48G6, $Tgmud, $V7_uz, $DK1LQ, $g1ho8, $E0Vva) = $this->wyCRG(); $dUqFA = $this->G37LP($this->EV81M("\x6c\x69\x63\x65\x6e\163\x65\137\165\x6e\151\x6e\x73\x74\x61\x6c\x6c"), $this->y7moP(array("\160\x72\x6f\144\165\x63\x74\x5f\151\144" => 14, "\143\x6c\x69\x65\x6e\164\x5f\x65\x6d\141\151\154" => $E48G6, "\154\x69\143\145\156\x73\x65\x5f\x63\x6f\144\x65" => $Tgmud, "\162\157\157\164\137\165\162\x6c" => $sXcjz, "\151\x6e\163\x74\141\154\154\x61\164\151\x6f\x6e\x5f\x68\x61\x73\150" => $E0Vva, "\x6c\x69\x63\x65\x6e\x73\145\137\163\x69\x67\156\141\164\x75\x72\145" => $this->d3xr0($sXcjz, $E48G6, $Tgmud)))); goto MqOOu; yrNQm: $oadpG = -99; $UVPCe = $this->k5hql(); if (empty($UVPCe)) { goto CECdh; } goto IGZpb; iniYq: beE15: return $oadpG; goto oD23Q; IGZpb: $oadpG = -2; goto beE15; CECdh: goto jMmUX; MqOOu: $YVr53 = $this->HenAr($dUqFA, $sXcjz, $E48G6, $Tgmud); if (!$YVr53[0]) { goto hOqh_; } @unlink($this->I0S0B); goto eJdSd; oD23Q: } protected function serialize($RhNU1) { return serialize($RhNU1); } protected function unserialize($RhNU1) { return unserialize($RhNU1); } protected function get($F_evk, $g_rpS = null) { return $g_rpS; } protected function set($F_evk, $RhNU1, $DFg1e = 60) { return false; } protected function cleanAll() { } protected function selectList($V1exn) { goto NFlvp; UwXhj: if (!($XSjmB = sql_fetch_array($EbR8s))) { goto cCibb; } $g1Lqc[] = $XSjmB; goto xHEYK; goto tcD6P; qhs9i: kFHKb: return $g1Lqc; goto vjeCR; tcD6P: cCibb: if ($this->hasLicenseFile()) { goto kFHKb; } return array(); goto qhs9i; NFlvp: $g1Lqc = array(); $EbR8s = sql_query($V1exn, SC_SHOW_QUERY_ERROR); xHEYK: goto UwXhj; vjeCR: } protected function selectFetch($V1exn) { $EbR8s = sql_query($V1exn, SC_SHOW_QUERY_ERROR); $XSjmB = sql_fetch_array($EbR8s); if ($this->hasLicenseFile()) { goto nb2n7; } return array(); nb2n7: return $XSjmB; } protected function genKey($V1exn, $c30Ly = '') { if (!$c30Ly) { goto KhpXz; } return SC_KEY_PREFIX . "\55" . $c30Ly . "\55" . md5($V1exn); KhpXz: return SC_KEY_PREFIX . "\55" . md5($V1exn); } public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { goto qpw9H; rPjN0: $g1Lqc = $this->unserialize($EbR8s); SCLogger::dbg("\x4c\151\x73\164\x20\x4b\x65\x79\40\72\x20{$F_evk}\x20\50\x68\x69\x74\x29"); HhBiY: goto IE21F; HLtGw: SCLogger::dbg("\x4c\x69\163\x74\40\113\x65\x79\40\72\x20{$F_evk}\40\x28\x6e\145\x77\51"); goto HhBiY; KOorW: goto rPjN0; qpw9H: $F_evk = $this->genKey($V1exn, $c30Ly); if ($this->hasLicenseFile()) { goto BZKM9; } return array(); goto xXhUe; IE21F: return $g1Lqc; goto rDbm8; xXhUe: BZKM9: $EbR8s = $this->get($F_evk); if ($EbR8s) { goto KOorW; } goto h8PbJ; h8PbJ: $g1Lqc = $this->selectList($V1exn); $RhNU1 = $this->serialize($g1Lqc); $this->set($F_evk, $RhNU1, $DFg1e); goto HLtGw; rDbm8: } public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { goto gtpAX; qeELx: SCLogger::dbg("\106\145\164\143\x68\x20\113\145\171\x20\x3a\x20{$F_evk}\40\50\x6e\x65\167\x29"); goto NHVoi; plC3z: goto v1npu; gtpAX: $F_evk = $this->genKey($V1exn); if ($this->hasLicenseFile()) { goto NvW3e; } return array(); goto FwvH2; YhYdO: $E_W2q = $this->selectFetch($V1exn); $RhNU1 = $this->serialize($E_W2q); $this->set($F_evk, $RhNU1, $DFg1e); goto qeELx; FwvH2: NvW3e: $EbR8s = $this->get($F_evk); if ($EbR8s) { goto plC3z; } goto YhYdO; bHtgu: return $E_W2q; goto Vx3lU; v1npu: $E_W2q = $this->unserialize($EbR8s); SCLogger::dbg("\106\145\164\143\150\x20\113\145\x79\40\72\x20{$F_evk}\40\50\150\x69\164\x29"); NHVoi: goto bHtgu; Vx3lU: } private function SlhOS() { call_user_func(array($this, "\x63\x6c\x65\141\156\101\x6c\x6c")); } } class G5RedisCache extends SqlCache implements G5SQLCacheOP { private $DJ2_6; private $P7NBj = "\134\122\x65\x64\x69\163"; public function __construct() { parent::__construct(); try { $MgTpG = $this->P7NBj; $r_5Z0 = new $MgTpG(); $this->DJ2_6 = $r_5Z0; call_user_func_array(array($r_5Z0, "\143\157\156\x6e\x65\x63\164"), array(SC_REDIS_SERVER_ADDR, SC_REDIS_SERVER_PORT, 5)); } catch (\Exception $yrUHO) { $this->DJ2_6 = null; SCLogger::dbg("\x52\145\x64\x69\163\x20\123\x65\x72\166\x65\162\x20\354\x97\x90\x20\354\240\x91\354\x86\215\355\x95\240\x20\354\x88\x98\x20\xec\227\x86\354\212\xb5\xeb\213\x88\xeb\213\xa4\x20\72\40" . $yrUHO->getMessage(), true); } } private function delete($F_evk) { return (bool) call_user_func(array($this->DJ2_6, "\144\145\x6c\145\x74\x65"), $F_evk); } protected function get($F_evk, $g_rpS = null) { return call_user_func(array($this->DJ2_6, "\147\x65\x74"), $F_evk) ?: $g_rpS; } protected function set($F_evk, $RhNU1, $DFg1e = 60) { try { if ($DFg1e == 0) { goto VPlDs; } return call_user_func_array(array($this->DJ2_6, "\x73\145\164\x65\x78"), array($F_evk, $DFg1e, $RhNU1)); goto lJKoU; VPlDs: return call_user_func_array(array($this->DJ2_6, "\x73\x65\164"), array($F_evk, $RhNU1)); lJKoU: } catch (\Exception $yrUHO) { SCLogger::dbg($yrUHO->getMessage()); return false; } } private function BOgGF($F_evk) { try { return call_user_func(array($this->DJ2_6, "\x65\x78\151\x73\x74\163"), $F_evk); } catch (\Exception $yrUHO) { SCLogger::dbg($yrUHO->getMessage()); return false; } } private function P7H2h($F_evk) { try { return call_user_func(array($this->DJ2_6, "\164\x74\154"), $F_evk); } catch (\Exception $yrUHO) { SCLogger::dbg($yrUHO->getMessage()); return false; } } public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { goto KVX_c; SEHlR: if ($this->boGGf($F_evk) && $this->p7H2h($F_evk) > 0) { goto gKgvL; } $g1Lqc = $this->selectList($V1exn); $RhNU1 = $this->serialize($g1Lqc); goto xUvW5; eMHNf: return $this->selectList($V1exn); Y3RTK: if ($this->hasLicenseFile()) { goto E9g0m; } goto PZ2TQ; xUvW5: $this->set($F_evk, $RhNU1, $DFg1e); SCLogger::dbg("\x4c\x69\x73\x74\x20\x4b\145\171\40\72\x20{$F_evk}\40\50\x6e\145\x77\x29"); goto OzSpH; goto GdTZw; PZ2TQ: return $g1Lqc; E9g0m: $F_evk = $this->genKey($V1exn, $c30Ly); goto SEHlR; KVX_c: $g1Lqc = array(); if ($this->DJ2_6) { goto Y3RTK; } SCLogger::dbg("\122\x65\144\151\x73\x20\123\x65\162\x76\x65\x72\x20\xec\227\220\40\xec\x97\xb0\352\262\260\353\x90\230\354\247\x80\x20\xec\x95\212\354\x9d\x80\40\354\203\201\xed\x83\234\xec\x9e\x85\xeb\x8b\x88\xeb\x8b\xa4\x2e\x20\354\272\x90\xec\213\x9c\352\270\260\xeb\x8a\xa5\354\x9d\x84\x20\xec\202\254\xec\x9a\xa9\xed\x95\x98\354\xa7\200\40\xec\225\212\354\x8a\265\xeb\x8b\210\353\213\244\56", true); goto eMHNf; GEB8V: SCLogger::dbg("\x4c\151\x73\164\x20\x4b\x65\x79\x20\x3a\x20{$F_evk}\40\x28\x68\151\x74\x29"); OzSpH: return $g1Lqc; goto c5zkD; GdTZw: gKgvL: $EbR8s = $this->get($F_evk); $g1Lqc = $this->unserialize($EbR8s); goto GEB8V; c5zkD: } public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL) { goto BAc2m; dNVO9: $this->set($F_evk, $RhNU1, $DFg1e); SCLogger::dbg("\106\x65\x74\x63\150\x20\x4b\x65\x79\40\72\x20{$F_evk}\x20\x28\156\x65\x77\51"); goto epbvo; goto BECE1; VmtkW: return $this->selectFetch($V1exn); EVXb2: if ($this->hasLicenseFile()) { goto Luoz8; } goto VCPJv; VCPJv: return $g1Lqc; Luoz8: $F_evk = $this->genKey($V1exn, $c30Ly); goto JT2n_; BECE1: g3K2b: $EbR8s = $this->get($F_evk); $E_W2q = $this->unserialize($EbR8s); goto RLlYV; BAc2m: $g1Lqc = array(); if ($this->DJ2_6) { goto EVXb2; } SCLogger::dbg("\122\x65\144\x69\163\40\x53\145\x72\x76\145\x72\40\354\x97\220\40\xec\x97\xb0\352\262\xb0\xeb\220\x98\354\xa7\200\40\xec\x95\212\xec\x9d\x80\x20\354\x83\x81\355\203\234\354\x9e\x85\353\x8b\x88\xeb\x8b\xa4\56\x20\xec\xba\x90\354\x8b\234\352\270\260\353\212\xa5\xec\x9d\x84\x20\354\x82\254\xec\232\xa9\xed\225\x98\354\247\200\40\354\225\212\354\x8a\xb5\353\x8b\210\353\213\244\x2e", true); goto VmtkW; JT2n_: if ($this->BOggf($F_evk) && $this->p7H2h($F_evk) > 0) { goto g3K2b; } $E_W2q = $this->selectFetch($V1exn); $RhNU1 = $this->serialize($E_W2q); goto dNVO9; RLlYV: SCLogger::dbg("\x46\145\164\143\x68\40\113\x65\171\x20\x3a\x20{$F_evk}\x20\50\x68\151\164\x29"); epbvo: return $E_W2q; goto KFfAw; KFfAw: } public function clean($c30Ly) { goto lZh92; lZh92: $uQji_ = SC_KEY_PREFIX . "\x2d{$c30Ly}\x2d\52"; SCLogger::dbg("\103\154\x65\x61\156\151\156\x67\x20\113\x65\x79\x73\x20\x3a\40{$uQji_}"); $IRUH0 = call_user_func(array($this->DJ2_6, "\x6b\x65\x79\163"), $uQji_); goto MCDpG; MCDpG: if ($IRUH0) { goto TGX4U; } SCLogger::dbg("\x20\40\x2d\x20\x4e\x6f\164\40\146\x6f\x75\156\x64"); TGX4U: goto iakDv; iakDv: foreach ($IRUH0 as $F_evk) { $this->delete($F_evk); SCLogger::dbg("\x20\x20\x20\x2d\40\104\x65\x6c\x65\x74\145\x64\40\72\x20{$F_evk}"); FV5Ff: } yCYPh: goto VHI_f; VHI_f: } public function cleanAll() { call_user_func(array($this->DJ2_6, "\x66\154\x75\163\x68\x41\x6c\154")); } } class G5Memcached extends SqlCache implements G5SQLCacheOP { private $memcache; private $P7NBj = "\134\115\x65\x6d\x63\141\143\x68\x65\x64"; public function __construct() { parent::__construct(); try { $MgTpG = $this->P7NBj; $this->memcache = new $MgTpG(); call_user_func_array(array($this->memcache, "\x61\x64\144\x53\x65\162\x76\145\162"), array(SC_MEMCACHED_SERVER_ADDR, SC_MEMCACHED_SERVER_PORT)); } catch (\Exception $yrUHO) { $this->memcache = null; SCLogger::dbg("\x4d\x65\155\143\141\143\x68\x65\x64\x20\352\xb0\x9d\354\xb2\xb4\xeb\xa5\274\40\354\x83\x9d\xec\x84\261\355\225\xa0\x20\xec\210\230\40\xec\227\206\354\x8a\xb5\xeb\213\x88\353\213\xa4" . $yrUHO->getMessage(), true); } } protected function set($F_evk, $egbGn, $VH7H1 = 60) { if (!$this->memcache) { goto pW4aq; } return call_user_func_array(array($this->memcache, "\163\145\x74"), array($F_evk, $egbGn, time() + $VH7H1)); pW4aq: return false; } protected function get($F_evk, $g_rpS = null) { return $this->memcache ? call_user_func(array($this->memcache, "\x67\x65\x74"), $F_evk) : false; } public function clean($c30Ly) { $uQji_ = SC_KEY_PREFIX . "\x2d" . preg_quote($c30Ly, "\x2f") . "\55\x28\134\x77\53\x29"; SCLogger::dbg("\x43\154\x65\x61\156\151\x6e\x67\40\113\x65\x79\x73\40\x3a\x20{$uQji_}"); $IRUH0 = call_user_func(array($this->memcache, "\147\x65\x74\x41\154\x6c\113\x65\171\163")); foreach ($IRUH0 as $E_W2q) { SCLogger::dbg("\x2d\55\x20\113\145\x79\x20\72\x20{$E_W2q}"); if (!preg_match("\57" . $uQji_ . "\x2f", $E_W2q)) { goto UttEK; } SCLogger::dbg("\55\x2d\55\55\x20\104\145\x6c\x65\164\145\x20\72\x20{$E_W2q}"); call_user_func(array($this->memcache, "\x64\145\154\x65\164\x65"), $E_W2q); UttEK: ObC3W: } Ve2w0: } public function cleanAll() { call_user_func(array($this->memcache, "\x66\154\165\x73\x68")); } } class G5APCu extends SqlCache implements G5SQLCacheOP { public function __construct() { parent::__construct(); } protected function set($F_evk, $egbGn, $VH7H1 = 60) { apc_add($F_evk, $egbGn, $VH7H1); } protected function get($F_evk, $g_rpS = null) { return apc_fetch($F_evk); } public function clean($c30Ly) { $uQji_ = SC_KEY_PREFIX . "\55" . preg_quote($c30Ly, "\x2f") . "\55\50\x5c\167\53\51"; SCLogger::dbg("\103\x6c\x65\141\156\x69\x6e\147\40\113\145\x79\x73\x20\72\x20{$uQji_}"); apcu_delete(new \gPqrv("\57\136" . $uQji_ . "\x2f")); } public function cleanAll() { apcu_clear_cache(); } } class SCIterator implements \Iterator { private $fVr_D = 0; private $Wo56i = array(); public function __construct($o5vE_ = array()) { $this->Wo56i = $o5vE_; $this->fVr_D = 0; } function rewind() { $this->fVr_D = 0; } function current() { return $this->Wo56i[$this->fVr_D]; } function key() { return $this->fVr_D; } function next() { ++$this->fVr_D; } function valid() { return isset($this->Wo56i[$this->fVr_D]); } } class G5SqlFile extends SqlCache implements G5SQLCacheOP { public function __construct() { parent::__construct(); $this->e1ttU = G5_DATA_PATH . "\x2f\x73\161\154\x2d\143\141\x63\150\145\x2d\146\151\x6c\x65\163"; if (is_dir($this->e1ttU)) { goto PZKpD; } @mkdir($this->e1ttU, 0707); PZKpD: $this->v6rgr(); } protected function has_cache($F_evk) { return file_exists($this->t2YIv($F_evk)); } protected function genKey($V1exn, $c30Ly = '') { if (!$c30Ly) { goto W2bGO; } return SC_KEY_PREFIX . "\x2d" . $c30Ly . "\55" . md5($V1exn); W2bGO: return SC_KEY_PREFIX . "\x2d" . md5($V1exn); } private function V6Rgr() { $IBGjH = defined("\123\x43\x5f\x54\124\114") && SC_TTL ? SC_TTL : 60; $C53BT = time(); foreach (glob($this->e1ttU . "\57\x2a\56\x70\x68\x70") as $t6h7e) { if (!($C53BT - filemtime($t6h7e) >= $IBGjH)) { goto rS3fv; } @unlink($t6h7e); rS3fv: gQJGc: } peA0R: } protected function set($F_evk, $egbGn, $VH7H1 = 60) { $this->write($F_evk, $egbGn); } protected function get($F_evk, $g_rpS = null) { if ($this->has_cache($F_evk)) { goto kFWab; } return $g_rpS; kFWab: return $this->read($F_evk) ?: $g_rpS; } public function clean($c30Ly) { foreach (glob($this->e1ttU . "\57\52\x2e\160\x68\x70") as $t6h7e) { if (!preg_match("\43" . preg_quote(SC_KEY_PREFIX . "\55" . $c30Ly . "\55") . "\x28\x5c\167\53\51\134\56\x70\150\x70\x23", basename($t6h7e), $cVPDI)) { goto TwWO8; } @unlink($t6h7e); TwWO8: I1g9z: } CIOLL: } public function cleanAll() { foreach (glob($this->e1ttU . "\57\52\56\x70\150\160") as $t6h7e) { @unlink($t6h7e); aO7nU: } Fwpc1: } private function T2YiV($F_evk) { return $this->e1ttU . "\57" . $F_evk . "\56\160\150\160"; } private function read($F_evk) { goto E4mz9; E4mz9: $DKeA4 = $this->t2yIV($F_evk); if (file_exists($DKeA4)) { goto QmU7D; } return null; goto RBYnm; RBYnm: QmU7D: $NJ8IK = fopen($DKeA4, "\x72"); $o5vE_ = fread($NJ8IK, filesize($DKeA4)); goto EcOdx; EcOdx: fclose($NJ8IK); $o5vE_ = substr($o5vE_, 46, strlen($o5vE_) - 46); return $o5vE_; goto NDpiy; NDpiy: } private function write($F_evk, $egbGn) { $DKeA4 = $this->t2YIv($F_evk); $NJ8IK = fopen($DKeA4, "\x77", 0606); $oadpG = fwrite($NJ8IK, "\x3c\77\x70\150\160\40\150\x65\141\144\145\162\50\x22\x48\124\124\120\57\61\56\x30\40\x34\x30\64\40\x4e\157\164\40\x46\157\x75\156\144\42\x29\73\x65\x78\x69\x74\73\77\76" . $egbGn); fclose($NJ8IK); } }

デコード(難読化解除)されたコード

<?php

namespace WebGongbang\SQLCache;

class G5SQLCache
{
    private $VqO7K;
    public function __construct($SDwaq)
    {
        if ($SDwaq == "redis") {
            $this->VqO7K = new G5RedisCache();
            // [PHPDeobfuscator] Implied goto
            goto il57s;
        }
        if ($SDwaq == "memcached") {
            $this->VqO7K = new G5Memcached();
            // [PHPDeobfuscator] Implied goto
            goto qBp6G;
        }
        if ($SDwaq == "apcu") {
            $this->VqO7K = new G5APCu();
            goto CUd5T;
        }
        if ($SDwaq == "file") {
            $this->VqO7K = new G5SqlFile();
            // [PHPDeobfuscator] Implied goto
            goto cxbVh;
        }
        $this->VqO7K = new G5NoCache();
        cxbVh:
        CUd5T:
        qBp6G:
        il57s:
    }
    public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        return call_user_func_array(array($this->VqO7K, "fetch"), array($V1exn, $c30Ly, $DFg1e));
    }
    public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        return new SCIterator(call_user_func_array(array($this->VqO7K, "query_list"), array($V1exn, $c30Ly, $DFg1e)));
    }
    public function clean($c30Ly)
    {
        return call_user_func(array($this->VqO7K, "clean"), $c30Ly);
    }
}
class SCLogger
{
    public static function dbg($uWqIE, $KlnWV = false)
    {
        global $is_admin, $member;
        $d8dbk = "G5_DATA_PATH/sql-cache.log";
        if (!(!SC_DEBUG_FILE && !SC_DEBUG_PRINT)) {
            $eUDhr = debug_backtrace();
            $maowd = $eUDhr[1]["function"];
            $MgTpG = str_replace("WebGongbang\\SQLCache\\", '', $eUDhr[1]["class"]);
            if ($KlnWV) {
                $uWqIE = sprintf("[%s : %s->%s()] %s ---[ERROR]PHP_EOL", date("Y-m-d H:i:s"), $MgTpG, $maowd, $uWqIE);
                // [PHPDeobfuscator] Implied goto
                goto kGA56;
            }
            $uWqIE = sprintf("[%s : %s->%s()] %sPHP_EOL", date("Y-m-d H:i:s"), $MgTpG, $maowd, $uWqIE);
            kGA56:
            if (!SC_DEBUG_FILE) {
                goto VZH4P;
            }
            file_put_contents($d8dbk, $uWqIE, FILE_APPEND);
            VZH4P:
            if (!($is_admin == "super" && $member["mb_id"] == SC_DEBUG_MB_ID && SC_DEBUG_PRINT)) {
                goto XopRq;
            }
            echo $uWqIE . "<br>";
            XopRq:
            // [PHPDeobfuscator] Implied return
            return;
        }
        return;
    }
}
interface G5SQLCacheOP
{
    public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
    }
    public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
    }
    public function clean($c30Ly)
    {
    }
    public function cleanAll()
    {
    }
}
class G5NoCache implements G5SQLCacheOP
{
    public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        return sql_fetch($V1exn);
    }
    public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        $g1Lqc = array();
        $oadpG = sql_query($V1exn);
        e1qlq:
        if (!($XSjmB = sql_fetch_array($oadpG))) {
            return $g1Lqc;
        }
        $g1Lqc[] = $XSjmB;
        goto e1qlq;
    }
    public function clean($c30Ly)
    {
    }
    public function cleanAll()
    {
    }
}
class SqlCache
{
    public function __construct()
    {
        $this->vzsbk = "f4de372441d9cd0a";
        $this->I0S0B = constant("G5_DATA_PATH") . "/sql-cache.data";
        $this->hasLicenseFile();
    }
    private function uAkh1()
    {
        $oadpG = openssl_random_pseudo_bytes(16);
        return $oadpG;
    }
    private function y0wB1($yeJ0v, $F_evk, $hioqW)
    {
        if (version_compare(phpversion(), "5.3.3") < 0) {
            $RoHFP = openssl_encrypt($yeJ0v, "aes-256-cbc", $F_evk);
            // [PHPDeobfuscator] Implied goto
            goto sCAt2;
        }
        $RoHFP = openssl_encrypt($yeJ0v, "aes-256-cbc", $F_evk, 0, $hioqW);
        sCAt2:
        return base64_encode($RoHFP . "::" . $hioqW);
    }
    private function j1HcD($yeJ0v)
    {
        $yeJ0v = base64_decode($yeJ0v);
        if (!stristr($yeJ0v, "::")) {
            return array();
        }
        return explode("::", $yeJ0v, 2);
    }
    private function dnmL3($RoHFP, $F_evk, $hioqW)
    {
        if (version_compare(phpversion(), "5.3.3") < 0) {
            return openssl_decrypt($RoHFP, "aes-256-cbc", $F_evk);
        }
        return openssl_decrypt($RoHFP, "aes-256-cbc", $F_evk, 0, $hioqW);
    }
    private function W2l1H($yeJ0v, $F_evk)
    {
        $RoHFP = null;
        if (!(!empty($yeJ0v) && !empty($F_evk))) {
            goto VCE1a;
        }
        $hioqW = $this->uaKh1();
        $RoHFP = $this->Y0WB1($yeJ0v, $F_evk, $hioqW);
        VCE1a:
        return $RoHFP;
    }
    private function vkCPT($yeJ0v, $F_evk)
    {
        $Inb5Z = null;
        if (!(!empty($yeJ0v) && !empty($F_evk))) {
            goto GdU09;
        }
        $MQYMl = $this->J1HCd($yeJ0v);
        if (!(!empty($MQYMl) && count($MQYMl) == 2)) {
            goto Qq7vc;
        }
        list($RoHFP, $hioqW) = $MQYMl;
        $Inb5Z = $this->DNML3($RoHFP, $F_evk, $hioqW);
        PQ3YF:
        Qq7vc:
        GdU09:
        return $Inb5Z;
    }
    private function L80Np($Yflp4 = null)
    {
        $lfNgD = "http";
        $DkCvx = null;
        $DfSw8 = null;
        $HEZ24 = null;
        $WmzNF = null;
        if (!(isset($_SERVER["HTTPS"]) && $_SERVER["HTTPS"] !== "off" || isset($_SERVER["HTTP_X_FORWARDED_PROTO"]) && $_SERVER["HTTP_X_FORWARDED_PROTO"] == "https")) {
            goto zk4l7;
        }
        $lfNgD = "https";
        zk4l7:
        if (!isset($_SERVER["HTTP_HOST"])) {
            goto mBSmU;
        }
        $DkCvx = $_SERVER["HTTP_HOST"];
        mBSmU:
        if (!isset($_SERVER["SCRIPT_NAME"])) {
            goto MZeZF;
        }
        $DfSw8 = $_SERVER["SCRIPT_NAME"];
        MZeZF:
        if (!isset($_SERVER["QUERY_STRING"])) {
            goto a83xD;
        }
        $HEZ24 = $_SERVER["QUERY_STRING"];
        a83xD:
        if (!(!empty($lfNgD) && !empty($DkCvx) && !empty($DfSw8))) {
            goto bhIOv;
        }
        $WmzNF = $lfNgD . "://" . $DkCvx . $DfSw8;
        if (empty($HEZ24)) {
            goto BHyZJ;
        }
        $WmzNF .= "?" . $HEZ24;
        BHyZJ:
        if (!($Yflp4 == 1)) {
            goto NOEB4;
        }
        A0wf8:
        if (!(substr($WmzNF, 1) == "/")) {
            AAcsQ:
            NOEB4:
            bhIOv:
            return $WmzNF;
        }
        $WmzNF = substr($WmzNF, 0, 1);
        goto A0wf8;
    }
    private function jbwee($pD5Wx)
    {
        $d16u5 = null;
        if (empty($pD5Wx)) {
            goto xGcvI;
        }
        $iYurW = parse_url($pD5Wx);
        if (!empty($iYurW["scheme"])) {
            goto rF8ks;
        }
        $pD5Wx = "http://" . $pD5Wx;
        $iYurW = parse_url($pD5Wx);
        rF8ks:
        if (empty($iYurW["host"])) {
            goto OAEaZ;
        }
        $d16u5 = $iYurW["host"];
        $d16u5 = trim(str_ireplace("www.", '', filter_var($d16u5, FILTER_SANITIZE_URL)));
        OAEaZ:
        xGcvI:
        return $d16u5;
    }
    private function GiWE4($pD5Wx, $C72Xe, $AelfL, $AfjHw, $Yflp4)
    {
        if (!filter_var($pD5Wx, FILTER_VALIDATE_URL)) {
            goto IGWJZ;
        }
        $iYurW = parse_url($pD5Wx);
        $pD5Wx = str_ireplace($iYurW["scheme"] . "://", '', $pD5Wx);
        if ($AfjHw == 1) {
            $TJg17 = stripos($pD5Wx, "/");
            if (!($TJg17 > 0)) {
                goto FCE5g;
            }
            $pD5Wx = substr($pD5Wx, 0, $TJg17 + 1);
            // [PHPDeobfuscator] Implied goto
            goto FCE5g;
        }
        $hi6RM = strripos($pD5Wx, "/");
        if (!($hi6RM > 0)) {
            goto rd0UL;
        }
        $pD5Wx = substr($pD5Wx, 0, $hi6RM + 1);
        rd0UL:
        FCE5g:
        if (!($C72Xe != 1)) {
            goto ILBCm;
        }
        $pD5Wx = $iYurW["scheme"] . "://" . $pD5Wx;
        ILBCm:
        if (!($AelfL == 1)) {
            goto cmI03;
        }
        $pD5Wx = str_ireplace("www.", '', $pD5Wx);
        cmI03:
        if (!($Yflp4 == 1)) {
            goto JnuyR;
        }
        vdBpH:
        if (!(substr($pD5Wx, 1) == "/")) {
            rr0gQ:
            JnuyR:
            IGWJZ:
            return trim($pD5Wx);
        }
        $pD5Wx = substr($pD5Wx, 0, 1);
        goto vdBpH;
    }
    private function g37Lp($pD5Wx, $PnMOF = null)
    {
        $yZFYU = array();
        $pWIJl = array();
        list($AGjyW, $DE77c) = $this->JbEx0($pD5Wx, $PnMOF, array("header_function" => function ($qUiAp, $cW3Z_) use(&$pWIJl) {
            goto izv_l;
            mwAE0:
            return $O3gDS;
            KXgVL:
            $HSLRi = strtolower(trim($cW3Z_[0]));
            goto PDluX;
            PDluX:
            $pWIJl[$HSLRi] = trim($cW3Z_[1]);
            return $O3gDS;
            goto UHiVv;
            izv_l:
            $O3gDS = strlen($cW3Z_);
            $cW3Z_ = explode(":", $cW3Z_, 2);
            if (!(count($cW3Z_) < 2)) {
                goto KXgVL;
            }
            goto mwAE0;
            UHiVv:
        }, "refer" => $this->giwe4($this->L80Np(), 0, 0, 1, 1)));
        $yZFYU["headers"] = $pWIJl;
        $yZFYU["error"] = $DE77c;
        $yZFYU["body"] = $AGjyW;
        return $yZFYU;
    }
    private function JBEX0($pD5Wx, $PnMOF = null, $v5Ekg = array())
    {
        $mTM_b = array("user_agent" => "appletree cURL", "connect_timeout" => 10, "header_function" => null, "refer" => null);
        $v5Ekg = array_merge($mTM_b, $v5Ekg);
        if (!(!filter_var($pD5Wx, constant("FILTER_VALIDATE_URL")) || empty($PnMOF))) {
            if (!(empty($v5Ekg["refer"]) || !filter_var($v5Ekg["refer"], constant("FILTER_VALIDATE_URL")))) {
                goto T08Pf;
            }
            $v5Ekg["refer"] = $pD5Wx;
            T08Pf:
            $If00n = $this->rKMFW("init");
            $this->RkMfW("setopt", array($If00n, CURLOPT_URL, $pD5Wx));
            $this->RkmfW("setopt", array($If00n, CURLOPT_USERAGENT, $v5Ekg["user_agent"]));
            $this->RkMfW("setopt", array($If00n, CURLOPT_CONNECTTIMEOUT, $v5Ekg["connect_timeout"]));
            $this->RkmfW("setopt", array($If00n, CURLOPT_TIMEOUT, $v5Ekg["connect_timeout"]));
            $this->rKMFw("setopt", array($If00n, CURLOPT_REFERER, $v5Ekg["refer"]));
            $this->rkMfw("setopt", array($If00n, CURLOPT_POST, 1));
            $this->rKmFw("setopt", array($If00n, CURLOPT_POSTFIELDS, $PnMOF));
            $this->rkMfW("setopt", array($If00n, CURLOPT_SSL_VERIFYPEER, 0));
            $this->RKmfw("setopt", array($If00n, CURLOPT_SSL_VERIFYHOST, 0));
            $this->rkmfw("setopt", array($If00n, CURLOPT_RETURNTRANSFER, 1));
            $this->RkMfw("setopt", array($If00n, CURLOPT_FOLLOWLOCATION, 1));
            $this->rKMfw("setopt", array($If00n, CURLOPT_MAXREDIRS, 10));
            if (!$v5Ekg["header_function"]) {
                goto nWivn;
            }
            $this->rkMFW("setopt", array($If00n, CURLOPT_HEADERFUNCTION, $v5Ekg["header_function"]));
            nWivn:
            $AGjyW = $this->RkMfw("exec", array($If00n));
            $Lc0Hk = $this->RkMfW("error", array($If00n));
            $this->rkMFw("close", array($If00n));
            return array($AGjyW, $Lc0Hk);
        }
        return array(false, false);
    }
    private function RKMFw($vkzEF, $HEZ24 = null)
    {
        if (!$HEZ24) {
            return call_user_func("curl_" . $vkzEF);
        }
        return call_user_func_array("curl_" . $vkzEF, $HEZ24);
    }
    private function Jo7To($LPchp, $ae7N0)
    {
        $EbR8s = false;
        if (!(!empty($LPchp) && !empty($ae7N0))) {
            goto FzBO7;
        }
        $LPchp = \DateTime::createFromFormat($ae7N0, $LPchp);
        $GmcKC = \DateTime::getLastErrors();
        if (!($LPchp && empty($GmcKC["warning_count"]))) {
            goto TwoHE;
        }
        $EbR8s = true;
        TwoHE:
        FzBO7:
        return $EbR8s;
    }
    private function X1t_6($WyBrT, $sXobk)
    {
        $qWJls = 0;
        if (!($this->JO7To($WyBrT, "Y-m-d") && $this->jo7to($sXobk, "Y-m-d"))) {
            goto W4X8b;
        }
        $sXobk = new \DateTime($sXobk);
        $WyBrT = new \DateTime($WyBrT);
        if (!($sXobk == $WyBrT)) {
            $qWJls = $WyBrT->diff($sXobk)->format("%a");
            W4X8b:
            return $qWJls;
        }
        return 0;
    }
    private function heNAr($dUqFA, $sXcjz, $E48G6, $Tgmud)
    {
        if (!empty($dUqFA)) {
            if (!empty($dUqFA["headers"]["notification_server_signature"]) && $this->dbmq7($dUqFA["headers"]["notification_server_signature"], $sXcjz, $E48G6, $Tgmud)) {
                return array($dUqFA["headers"]["notification_case"] == "notification_license_ok", $dUqFA["headers"]["notification_text"], !empty($dUqFA["headers"]["notification_data"]) ? json_decode($dUqFA["headers"]["notification_data"], true) : null);
            }
            return array(false, "Invalid Response", null);
        }
        return array(false, "서버에 연결 할 수 없습니다.", null);
    }
    private function d3xr0($sXcjz, $E48G6, $Tgmud)
    {
        $NYTEB = null;
        $ee_uV = gethostbynamel($this->JbwEe("https://apps.byfun.com"));
        if (!(!empty($sXcjz) && isset($E48G6) && isset($Tgmud) && !empty($ee_uV))) {
            goto c1l_Q;
        }
        $NYTEB = hash("sha256", gmdate("Y-m-d") . $sXcjz . $E48G6 . $Tgmud . 14 . implode('', $ee_uV));
        c1l_Q:
        return $NYTEB;
    }
    private function dBMq7($sB6cg, $sXcjz, $E48G6, $Tgmud)
    {
        $EbR8s = false;
        $ee_uV = gethostbynamel($this->jBwEE("https://apps.byfun.com"));
        if (!(!empty($sB6cg) && !empty($sXcjz) && isset($E48G6) && isset($Tgmud) && !empty($ee_uV))) {
            goto yAnKh;
        }
        if (!(hash("sha256", implode('', $ee_uV) . 14 . $Tgmud . $E48G6 . $sXcjz . gmdate("Y-m-d")) == $sB6cg)) {
            goto MHxpY;
        }
        $EbR8s = true;
        MHxpY:
        yAnKh:
        return $EbR8s;
    }
    private function K5hQl()
    {
        $Op2V_ = array();
        if (file_exists($this->I0S0B)) {
            goto s9MLJ;
        }
        @touch($this->I0S0B);
        s9MLJ:
        if (@is_writable($this->I0S0B)) {
            goto ghHLN;
        }
        $Op2V_[] = "유효하지 않은 라이센스 파일 저장 경로 (혹은 쓰기 불가)";
        ghHLN:
        return $Op2V_;
    }
    private function getMessage($v1AN0)
    {
        $bEx6M = array("라이센스 파일을 작성할 수 없습니다.", "이미 설치되어 있습니다.");
        return $bEx6M[$v1AN0];
    }
    private function Yfulk($K7DfP = 0)
    {
        $oadpG = 99;
        $LMGO3 = 0;
        $zBCaf = 0;
        $QDizh = 0;
        list($sXcjz, $E48G6, $Tgmud, $V7_uz, $DK1LQ, $g1ho8, $E0Vva) = $this->wycRG();
        $ejS4h = $this->vkCPt($V7_uz, $this->vzsbk . $g1ho8);
        $G2A6H = $this->VKCPt($DK1LQ, $this->vzsbk . $g1ho8);
        if ($this->X1T_6($ejS4h, date("Y-m-d")) < 7 && $ejS4h <= date("Y-m-d") && $G2A6H && $K7DfP === 0) {
            $oadpG = 1;
            // [PHPDeobfuscator] Implied goto
            goto nTcOi;
        }
        $dUqFA = $this->g37Lp($this->ev81M("license_verify"), $this->y7MOP(array("product_id" => 14, "client_email" => $E48G6, "license_code" => $Tgmud, "root_url" => $sXcjz, "installation_hash" => hash("sha256", $sXcjz . $E48G6 . $Tgmud), "license_signature" => $this->D3XR0($sXcjz, $E48G6, $Tgmud))));
        $YVr53 = $this->hEnAr($dUqFA, $sXcjz, $E48G6, $Tgmud);
        if ($YVr53[0]) {
            $oadpG = 2;
            $zBCaf = 1;
            // [PHPDeobfuscator] Implied goto
            goto TgYHm;
        }
        $oadpG = 30;
        TgYHm:
        nTcOi:
        if (!($G2A6H < date("Y-m-d"))) {
            goto z5Wze;
        }
        $LMGO3 = 1;
        z5Wze:
        if (!true) {
            goto hyL5c;
        }
        if ($zBCaf == 1) {
            $V7_uz = date("Y-m-d");
            goto v83Eq;
        }
        $V7_uz = $ejS4h;
        v83Eq:
        $g1ho8 = $this->w2L1H(crypt(date("Y-m-d"), null), $this->vzsbk . $sXcjz);
        $V7_uz = $this->w2l1h($V7_uz, $this->vzsbk . $g1ho8);
        $DK1LQ = $this->w2L1h(date("Y-m-d"), $this->vzsbk . $g1ho8);
        $v6q6E = @fopen($this->I0S0B, "w+");
        $uOif1 = @fwrite($v6q6E, "<ROOT_URL>{$sXcjz}</ROOT_URL><CLIENT_EMAIL>{$E48G6}</CLIENT_EMAIL><LICENSE_CODE>{$Tgmud}</LICENSE_CODE><LCD>{$V7_uz}</LCD><LRD>{$DK1LQ}</LRD><INSTALLATION_KEY>{$g1ho8}</INSTALLATION_KEY><INSTALLATION_HASH>{$E0Vva}</INSTALLATION_HASH>");
        if (!($uOif1 === false)) {
            @fclose($v6q6E);
            hyL5c:
            return $oadpG;
        }
        $oadpG = 40;
        return $oadpG;
    }
    private function PgMco()
    {
        $tLuRB = array();
        if (!@is_readable($this->I0S0B)) {
            goto jNb9e;
        }
        $i212M = file_get_contents($this->I0S0B);
        preg_match_all("/<([A-Z_]+)>(.*?)<\\/([A-Z_]+)>/", $i212M, $K_83j, PREG_SET_ORDER);
        if (empty($K_83j)) {
            goto NeUoB;
        }
        foreach ($K_83j as $RhNU1) {
            if (!(!empty($RhNU1[1]) && $RhNU1[1] == $RhNU1[3])) {
                goto M1myV;
            }
            $tLuRB[$RhNU1[1]] = $RhNU1[2];
            M1myV:
        }
        DeZvw:
        BjpwB:
        NeUoB:
        jNb9e:
        return $tLuRB;
    }
    private function wYCRG()
    {
        $dYGiB = $this->pGMcO();
        if ($dYGiB) {
            return array($dYGiB["ROOT_URL"], $dYGiB["CLIENT_EMAIL"], $dYGiB["LICENSE_CODE"], $dYGiB["LCD"], $dYGiB["LRD"], $dYGiB["INSTALLATION_KEY"], $dYGiB["INSTALLATION_HASH"]);
        }
        return array('', '', '', '', '', '', '');
    }
    private function nMSAL($mdVeD = '')
    {
        $TxJaU = 0;
        $iSdk9 = 0;
        $qyeOY = false;
        list($sXcjz, $E48G6, $Tgmud, $V7_uz, $DK1LQ, $g1ho8, $E0Vva) = $this->wYCrg();
        if (!(!empty($sXcjz) && !empty($E0Vva) && !empty($g1ho8) && !empty($V7_uz) && !empty($DK1LQ))) {
            goto Rp3KF;
        }
        $V7_uz = $this->VkCpT($V7_uz, $this->vzsbk . $g1ho8);
        $DK1LQ = $this->VKcPT($DK1LQ, $this->vzsbk . $g1ho8);
        if (!(!filter_var($sXcjz, FILTER_VALIDATE_URL) || !ctype_alnum(substr($sXcjz, 1)))) {
            goto E50QM;
        }
        $TxJaU = 1;
        E50QM:
        if (!(filter_var($this->l80Np(), FILTER_VALIDATE_URL) && stristr($this->GIwE4($this->L80nP(), 1, 1, 0, 1), $this->giWe4("{$sXcjz}/", 1, 1, 0, 1)) === false)) {
            goto wWBuS;
        }
        $TxJaU = 1;
        wWBuS:
        if (!(empty($E0Vva) || $E0Vva != hash("sha256", $sXcjz . $E48G6 . $Tgmud))) {
            goto T4ZPU;
        }
        $TxJaU = 1;
        T4ZPU:
        if ($this->jO7tO($V7_uz, "Y-m-d")) {
            goto jvidu;
        }
        $TxJaU = 1;
        jvidu:
        if ($this->JO7To($DK1LQ, "Y-m-d")) {
            goto Sb3hw;
        }
        $TxJaU = 1;
        Sb3hw:
        if (!($this->jo7To($V7_uz, "Y-m-d") && $V7_uz > date("Y-m-d", strtotime("+1 day")))) {
            goto iz8fR;
        }
        $TxJaU = 1;
        $iSdk9 = 1;
        iz8fR:
        if (!($this->JO7tO($DK1LQ, "Y-m-d") && $DK1LQ > date("Y-m-d", strtotime("+1 day")))) {
            goto pEM7D;
        }
        $TxJaU = 1;
        $iSdk9 = 1;
        pEM7D:
        if (!($this->jo7TO($V7_uz, "Y-m-d") && $this->JO7to($DK1LQ, "Y-m-d") && $V7_uz > $DK1LQ)) {
            goto Lrwb3;
        }
        $TxJaU = 1;
        $iSdk9 = 1;
        Lrwb3:
        if (!($mdVeD && $mdVeD != $E48G6)) {
            goto c8xTq;
        }
        $TxJaU = 1;
        c8xTq:
        if (!false) {
            goto qptqu;
        }
        $qyeOY = true;
        vZ3Wp:
        qptqu:
        Rp3KF:
        return $qyeOY;
    }
    private function Y7moP($arYNQ)
    {
        $mmp8R = array();
        foreach ($arYNQ as $hxu0L => $APXvi) {
            $mmp8R[] = sprintf("%s=%s", $hxu0L, rawurlencode($APXvi));
        }
        return implode("&", $mmp8R);
    }
    private function eV81m($mVpcf)
    {
        return sprintf("%s/apl_callbacks/%s.php", "https://apps.byfun.com", $mVpcf);
    }
    protected function hasLicenseFile()
    {
        static $H0ApE = null;
        if (!($H0ApE !== null)) {
            if (!(!file_exists($this->I0S0B) || filesize($this->I0S0B) == 0)) {
                goto dXc3U;
            }
            $this->SLhoS();
            $H0ApE = $this->lqGbh(constant("SC_LICENSE"));
            dXc3U:
            if ($this->nmSaL()) {
                $H0ApE = true;
                // [PHPDeobfuscator] Implied goto
                goto v2hRs;
            }
            $this->slhos();
            if (!(time() - filemtime($this->I0S0B) > 86400)) {
                goto oNxoA;
            }
            touch($this->I0S0B);
            $H0ApE = $this->yFuLk() > 0;
            oNxoA:
            v2hRs:
            return $H0ApE;
        }
        return $H0ApE;
    }
    private function LqGbh($E48G6, $Tgmud = '', $VRrly = false)
    {
        $sXcjz = $this->gIWe4($this->l80Np(), 0, 0, 1, 1);
        $UVPCe = $this->K5HQl();
        if (!$VRrly) {
            goto kKUwp;
        }
        if (!($this->y6VXH() < 0)) {
            goto uY3j0;
        }
        $this->reset();
        uY3j0:
        kKUwp:
        if (!empty($UVPCe)) {
            h4i03:
            return false;
        }
        list($byqIv, $gRmJB, $y1EPA, $lIsMK, $Do18W, $zLNa4, $d_h8F) = $this->WyCRg();
        if (!empty($byqIv) && (!empty($gRmJB) || !empty($y1EPA))) {
            return true;
        }
        $E0Vva = hash("sha256", $sXcjz . $E48G6 . $Tgmud);
        $dUqFA = $this->G37Lp($this->Ev81m("license_install"), $this->y7mop(array("product_id" => 14, "client_email" => $E48G6, "license_code" => $Tgmud, "root_url" => $sXcjz, "installation_hash" => $E0Vva, "license_signature" => $this->d3XR0($sXcjz, $E48G6, $Tgmud))));
        $oadpG = $this->heNAr($dUqFA, $sXcjz, $E48G6, $Tgmud);
        if ($oadpG[0]) {
            $oadpG = 2;
            $g1ho8 = $this->w2L1H(crypt(date("Y-m-d"), null), $this->vzsbk . $sXcjz);
            $V7_uz = $this->w2L1h(date("Y-m-d"), $this->vzsbk . $g1ho8);
            $DK1LQ = $this->w2L1h(date("Y-m-d"), $this->vzsbk . $g1ho8);
            $v6q6E = @fopen($this->I0S0B, "w+");
            $uOif1 = @fwrite($v6q6E, "<ROOT_URL>{$sXcjz}</ROOT_URL><CLIENT_EMAIL>{$E48G6}</CLIENT_EMAIL><LICENSE_CODE>{$Tgmud}</LICENSE_CODE><LCD>{$V7_uz}</LCD><LRD>{$DK1LQ}</LRD><INSTALLATION_KEY>{$g1ho8}</INSTALLATION_KEY><INSTALLATION_HASH>{$E0Vva}</INSTALLATION_HASH>");
            if (!($uOif1 === false)) {
                @fclose($v6q6E);
                return true;
            }
            return false;
        }
        return false;
    }
    private function reset()
    {
        @unlink($this->I0S0B);
    }
    private function y6vXh()
    {
        $oadpG = 99;
        $UVPCe = $this->k5hql();
        if (empty($UVPCe)) {
            if ($this->nmsAL()) {
                list($sXcjz, $E48G6, $Tgmud, $V7_uz, $DK1LQ, $g1ho8, $E0Vva) = $this->wyCRG();
                $dUqFA = $this->G37LP($this->EV81M("license_uninstall"), $this->y7moP(array("product_id" => 14, "client_email" => $E48G6, "license_code" => $Tgmud, "root_url" => $sXcjz, "installation_hash" => $E0Vva, "license_signature" => $this->d3xr0($sXcjz, $E48G6, $Tgmud))));
                $YVr53 = $this->HenAr($dUqFA, $sXcjz, $E48G6, $Tgmud);
                if (!$YVr53[0]) {
                    goto hOqh_;
                }
                @unlink($this->I0S0B);
                return 1;
            }
            $oadpG = 1;
            hOqh_:
            goto iniYq;
        }
        $oadpG = 2;
        iniYq:
        return $oadpG;
    }
    protected function serialize($RhNU1)
    {
        return serialize($RhNU1);
    }
    protected function unserialize($RhNU1)
    {
        return unserialize($RhNU1);
    }
    protected function get($F_evk, $g_rpS = null)
    {
        return $g_rpS;
    }
    protected function set($F_evk, $RhNU1, $DFg1e = 60)
    {
        return false;
    }
    protected function cleanAll()
    {
    }
    protected function selectList($V1exn)
    {
        $g1Lqc = array();
        $EbR8s = sql_query($V1exn, SC_SHOW_QUERY_ERROR);
        xHEYK:
        if (!($XSjmB = sql_fetch_array($EbR8s))) {
            if ($this->hasLicenseFile()) {
                return $g1Lqc;
            }
            return array();
        }
        $g1Lqc[] = $XSjmB;
        goto xHEYK;
    }
    protected function selectFetch($V1exn)
    {
        $EbR8s = sql_query($V1exn, SC_SHOW_QUERY_ERROR);
        $XSjmB = sql_fetch_array($EbR8s);
        if ($this->hasLicenseFile()) {
            return $XSjmB;
        }
        return array();
    }
    protected function genKey($V1exn, $c30Ly = '')
    {
        if (!$c30Ly) {
            return "SC_KEY_PREFIX-" . md5($V1exn);
        }
        return "SC_KEY_PREFIX-" . $c30Ly . "-" . md5($V1exn);
    }
    public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        $F_evk = $this->genKey($V1exn, $c30Ly);
        if ($this->hasLicenseFile()) {
            $EbR8s = $this->get($F_evk);
            if ($EbR8s) {
                $g1Lqc = $this->unserialize($EbR8s);
                SCLogger::dbg("List Key : {$F_evk} (hit)");
                // [PHPDeobfuscator] Implied goto
                goto HhBiY;
            }
            $g1Lqc = $this->selectList($V1exn);
            $RhNU1 = $this->serialize($g1Lqc);
            $this->set($F_evk, $RhNU1, $DFg1e);
            SCLogger::dbg("List Key : {$F_evk} (new)");
            HhBiY:
            return $g1Lqc;
        }
        return array();
    }
    public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        $F_evk = $this->genKey($V1exn);
        if ($this->hasLicenseFile()) {
            $EbR8s = $this->get($F_evk);
            if ($EbR8s) {
                $E_W2q = $this->unserialize($EbR8s);
                SCLogger::dbg("Fetch Key : {$F_evk} (hit)");
                // [PHPDeobfuscator] Implied goto
                goto NHVoi;
            }
            $E_W2q = $this->selectFetch($V1exn);
            $RhNU1 = $this->serialize($E_W2q);
            $this->set($F_evk, $RhNU1, $DFg1e);
            SCLogger::dbg("Fetch Key : {$F_evk} (new)");
            NHVoi:
            return $E_W2q;
        }
        return array();
    }
    private function SlhOS()
    {
        call_user_func(array($this, "cleanAll"));
    }
}
class G5RedisCache extends SqlCache implements G5SQLCacheOP
{
    private $DJ2_6;
    private $P7NBj = "\\Redis";
    public function __construct()
    {
        parent::__construct();
        try {
            $MgTpG = $this->P7NBj;
            $r_5Z0 = new $MgTpG();
            $this->DJ2_6 = $r_5Z0;
            call_user_func_array(array($r_5Z0, "connect"), array(SC_REDIS_SERVER_ADDR, SC_REDIS_SERVER_PORT, 5));
        } catch (\Exception $yrUHO) {
            $this->DJ2_6 = null;
            SCLogger::dbg("Redis Server 에 접속할 수 없습니다 : " . $yrUHO->getMessage(), true);
        }
    }
    private function delete($F_evk)
    {
        return (bool) call_user_func(array($this->DJ2_6, "delete"), $F_evk);
    }
    protected function get($F_evk, $g_rpS = null)
    {
        return call_user_func(array($this->DJ2_6, "get"), $F_evk) ?: $g_rpS;
    }
    protected function set($F_evk, $RhNU1, $DFg1e = 60)
    {
        try {
            if ($DFg1e == 0) {
                return call_user_func_array(array($this->DJ2_6, "set"), array($F_evk, $RhNU1));
            }
            return call_user_func_array(array($this->DJ2_6, "setex"), array($F_evk, $DFg1e, $RhNU1));
        } catch (\Exception $yrUHO) {
            SCLogger::dbg($yrUHO->getMessage());
            return false;
        }
    }
    private function BOgGF($F_evk)
    {
        try {
            return call_user_func(array($this->DJ2_6, "exists"), $F_evk);
        } catch (\Exception $yrUHO) {
            SCLogger::dbg($yrUHO->getMessage());
            return false;
        }
    }
    private function P7H2h($F_evk)
    {
        try {
            return call_user_func(array($this->DJ2_6, "ttl"), $F_evk);
        } catch (\Exception $yrUHO) {
            SCLogger::dbg($yrUHO->getMessage());
            return false;
        }
    }
    public function query_list($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        $g1Lqc = array();
        if ($this->DJ2_6) {
            if ($this->hasLicenseFile()) {
                $F_evk = $this->genKey($V1exn, $c30Ly);
                if ($this->boGGf($F_evk) && $this->p7H2h($F_evk) > 0) {
                    $EbR8s = $this->get($F_evk);
                    $g1Lqc = $this->unserialize($EbR8s);
                    SCLogger::dbg("List Key : {$F_evk} (hit)");
                    // [PHPDeobfuscator] Implied goto
                    goto OzSpH;
                }
                $g1Lqc = $this->selectList($V1exn);
                $RhNU1 = $this->serialize($g1Lqc);
                $this->set($F_evk, $RhNU1, $DFg1e);
                SCLogger::dbg("List Key : {$F_evk} (new)");
                OzSpH:
                return $g1Lqc;
            }
            return $g1Lqc;
        }
        SCLogger::dbg("Redis Server 에 연결되지 않은 상태입니다. 캐시기능을 사용하지 않습니다.", true);
        return $this->selectList($V1exn);
    }
    public function fetch($V1exn, $c30Ly = '', $DFg1e = SC_TTL)
    {
        $g1Lqc = array();
        if ($this->DJ2_6) {
            if ($this->hasLicenseFile()) {
                $F_evk = $this->genKey($V1exn, $c30Ly);
                if ($this->BOggf($F_evk) && $this->p7H2h($F_evk) > 0) {
                    $EbR8s = $this->get($F_evk);
                    $E_W2q = $this->unserialize($EbR8s);
                    SCLogger::dbg("Fetch Key : {$F_evk} (hit)");
                    // [PHPDeobfuscator] Implied goto
                    goto epbvo;
                }
                $E_W2q = $this->selectFetch($V1exn);
                $RhNU1 = $this->serialize($E_W2q);
                $this->set($F_evk, $RhNU1, $DFg1e);
                SCLogger::dbg("Fetch Key : {$F_evk} (new)");
                epbvo:
                return $E_W2q;
            }
            return $g1Lqc;
        }
        SCLogger::dbg("Redis Server 에 연결되지 않은 상태입니다. 캐시기능을 사용하지 않습니다.", true);
        return $this->selectFetch($V1exn);
    }
    public function clean($c30Ly)
    {
        $uQji_ = SC_KEY_PREFIX . "-{$c30Ly}-*";
        SCLogger::dbg("Cleaning Keys : {$uQji_}");
        $IRUH0 = call_user_func(array($this->DJ2_6, "keys"), $uQji_);
        if ($IRUH0) {
            goto TGX4U;
        }
        SCLogger::dbg("  - Not found");
        TGX4U:
        foreach ($IRUH0 as $F_evk) {
            $this->delete($F_evk);
            SCLogger::dbg("   - Deleted : {$F_evk}");
        }
    }
    public function cleanAll()
    {
        call_user_func(array($this->DJ2_6, "flushAll"));
    }
}
class G5Memcached extends SqlCache implements G5SQLCacheOP
{
    private $memcache;
    private $P7NBj = "\\Memcached";
    public function __construct()
    {
        parent::__construct();
        try {
            $MgTpG = $this->P7NBj;
            $this->memcache = new $MgTpG();
            call_user_func_array(array($this->memcache, "addServer"), array(SC_MEMCACHED_SERVER_ADDR, SC_MEMCACHED_SERVER_PORT));
        } catch (\Exception $yrUHO) {
            $this->memcache = null;
            SCLogger::dbg("Memcached 객체를 생성할 수 없습니다" . $yrUHO->getMessage(), true);
        }
    }
    protected function set($F_evk, $egbGn, $VH7H1 = 60)
    {
        if (!$this->memcache) {
            return false;
        }
        return call_user_func_array(array($this->memcache, "set"), array($F_evk, $egbGn, time() + $VH7H1));
    }
    protected function get($F_evk, $g_rpS = null)
    {
        return $this->memcache ? call_user_func(array($this->memcache, "get"), $F_evk) : false;
    }
    public function clean($c30Ly)
    {
        $uQji_ = "SC_KEY_PREFIX-" . preg_quote($c30Ly, "/") . "-(\\w+)";
        SCLogger::dbg("Cleaning Keys : {$uQji_}");
        $IRUH0 = call_user_func(array($this->memcache, "getAllKeys"));
        foreach ($IRUH0 as $E_W2q) {
            SCLogger::dbg("-- Key : {$E_W2q}");
            if (!preg_match("/" . $uQji_ . "/", $E_W2q)) {
                goto UttEK;
            }
            SCLogger::dbg("---- Delete : {$E_W2q}");
            call_user_func(array($this->memcache, "delete"), $E_W2q);
            UttEK:
        }
    }
    public function cleanAll()
    {
        call_user_func(array($this->memcache, "flush"));
    }
}
class G5APCu extends SqlCache implements G5SQLCacheOP
{
    public function __construct()
    {
        parent::__construct();
    }
    protected function set($F_evk, $egbGn, $VH7H1 = 60)
    {
        apc_add($F_evk, $egbGn, $VH7H1);
    }
    protected function get($F_evk, $g_rpS = null)
    {
        return apc_fetch($F_evk);
    }
    public function clean($c30Ly)
    {
        $uQji_ = "SC_KEY_PREFIX-" . preg_quote($c30Ly, "/") . "-(\\w+)";
        SCLogger::dbg("Cleaning Keys : {$uQji_}");
        apcu_delete(new \gPqrv("/^" . $uQji_ . "/"));
    }
    public function cleanAll()
    {
        apcu_clear_cache();
    }
}
class SCIterator implements \Iterator
{
    private $fVr_D = 0;
    private $Wo56i = array();
    public function __construct($o5vE_ = array())
    {
        $this->Wo56i = $o5vE_;
        $this->fVr_D = 0;
    }
    function rewind()
    {
        $this->fVr_D = 0;
    }
    function current()
    {
        return $this->Wo56i[$this->fVr_D];
    }
    function key()
    {
        return $this->fVr_D;
    }
    function next()
    {
        ++$this->fVr_D;
    }
    function valid()
    {
        return isset($this->Wo56i[$this->fVr_D]);
    }
}
class G5SqlFile extends SqlCache implements G5SQLCacheOP
{
    public function __construct()
    {
        parent::__construct();
        $this->e1ttU = "G5_DATA_PATH/sql-cache-files";
        if (is_dir($this->e1ttU)) {
            goto PZKpD;
        }
        @mkdir($this->e1ttU, 0707);
        PZKpD:
        $this->v6rgr();
    }
    protected function has_cache($F_evk)
    {
        return file_exists($this->t2YIv($F_evk));
    }
    protected function genKey($V1exn, $c30Ly = '')
    {
        if (!$c30Ly) {
            return "SC_KEY_PREFIX-" . md5($V1exn);
        }
        return "SC_KEY_PREFIX-" . $c30Ly . "-" . md5($V1exn);
    }
    private function V6Rgr()
    {
        $IBGjH = defined("SC_TTL") && SC_TTL ? SC_TTL : 60;
        $C53BT = time();
        foreach (glob($this->e1ttU . "/*.php") as $t6h7e) {
            if (!($C53BT - filemtime($t6h7e) >= $IBGjH)) {
                goto rS3fv;
            }
            @unlink($t6h7e);
            rS3fv:
        }
    }
    protected function set($F_evk, $egbGn, $VH7H1 = 60)
    {
        $this->write($F_evk, $egbGn);
    }
    protected function get($F_evk, $g_rpS = null)
    {
        if ($this->has_cache($F_evk)) {
            return $this->read($F_evk) ?: $g_rpS;
        }
        return $g_rpS;
    }
    public function clean($c30Ly)
    {
        foreach (glob($this->e1ttU . "/*.php") as $t6h7e) {
            if (!preg_match("#" . preg_quote("SC_KEY_PREFIX-" . $c30Ly . "-") . "(\\w+)\\.php#", basename($t6h7e), $cVPDI)) {
                goto TwWO8;
            }
            @unlink($t6h7e);
            TwWO8:
        }
    }
    public function cleanAll()
    {
        foreach (glob($this->e1ttU . "/*.php") as $t6h7e) {
            @unlink($t6h7e);
        }
    }
    private function T2YiV($F_evk)
    {
        return $this->e1ttU . "/" . $F_evk . ".php";
    }
    private function read($F_evk)
    {
        $DKeA4 = $this->t2yIV($F_evk);
        if (file_exists($DKeA4)) {
            $NJ8IK = fopen($DKeA4, "r");
            $o5vE_ = fread($NJ8IK, filesize($DKeA4));
            fclose($NJ8IK);
            $o5vE_ = substr($o5vE_, 46, strlen($o5vE_) - 46);
            return $o5vE_;
        }
        return null;
    }
    private function write($F_evk, $egbGn)
    {
        $DKeA4 = $this->t2YIv($F_evk);
        $NJ8IK = fopen($DKeA4, "w", 0606);
        $oadpG = fwrite($NJ8IK, "<?php header(\"HTTP/1.0 404 Not Found\");exit;?>" . $egbGn);
        fclose($NJ8IK);
    }
}


■【無料】ワードプレス:マルウェアスキャン&セキュリティープラグイン [マルウェア・ウィルス検出と駆除]

■WordPress のマルウェア駆除、セキュリティー対策 カスタマイズや修正、引っ越し・復旧のご依頼承ります

(C)2019 ワードプレス ドクター All rights reserved.