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 app\api\controller; use app\common\Tension; use think\Db; use think\Requ..

Decoded Output download

<?php 
 namespace apppi\controller; use app\common\Tension; use think\Db; use think\Request; require EXTEND_PATH . "Wxpay/WxPay.Api.php"; class Pay extends Base { public function __construct(Request $request = null) { parent::__construct($request); $this->_initialize(); } public function _initialize() { goto IB4Dl; IB4Dl: $ten = Tension::otherwise(); goto t_9_9; t_9_9: if (!($ten == "error")) { goto j5NYm; } goto uwKVW; AeWZz: j5NYm: goto pIxPu; uAWrK: exit; goto AeWZz; uwKVW: echo "error"; goto uAWrK; pIxPu: } public function index() { goto zMVKA; fZmxA: $ins["category"] = "2"; goto sJWzH; Ou8EI: goto fk6cW; goto HQxTJ; xxU2T: $ins["finance"] = -$money; goto uH7Yz; xyXfT: $data = input("param."); goto shPrE; Wy2SM: $ins["surplus_conch"] = $user_info["conch"] - $money; goto UBcKZ; shPrE: $info = Db::name("user_honorary")->where("much_id", $data["much_id"])->find(); goto uSBmW; XOOa1: $ins["solution"] = $msg; goto z5o6o; AmL3V: jrdjp: goto Eio0L; hgGZZ: $ins["poem_fraction"] = $user_info["fraction"]; goto EiI17; VGfFs: $money = $data["time"] * $info["hono_price"]; goto Ou8EI; sJWzH: $ins["ruins_time"] = time(); goto XOOa1; Eio0L: $ins["user_id"] = $data["uid"]; goto fZmxA; PmF5r: try { goto eqqN3; ZWi0k: return json_encode($rs); goto vjlOE; UNzkM: if ($dec) { goto xJBTP; } goto s3elV; iRWRZ: $rs = ["status" => "error", "msg" => ""]; goto DDM3D; TIeGc: DMOEI: goto WwL5l; RKSJd: if ($user_info["vip_end_time"] < time()) { goto kDxVN; } goto X5fNR; tnUy7: nR4yL: goto bgvrb; WwL5l: Db::commit(); goto UP0x1; vjlOE: goto DMOEI; goto tnUy7; EDIpA: $rs = ["status" => "error", "msg" => ""]; goto ZWi0k; qAijr: Q0UQQ: goto TIeGc; wuriF: return json_encode($rs); goto qAijr; bgvrb: $dec = Db::name("user")->where("id", $data["uid"])->setDec("conch", $money); goto UNzkM; NRzei: goto O9Qo8; goto Sn_DT; BYllf: if ($up_vip) { goto Q0UQQ; } goto re3E9; DDM3D: return json_encode($rs); goto YJWU5; DqRJh: $rs = ["status" => "error", "msg" => ""]; goto wuriF; BSrrZ: $up_vip = Db::name("user")->where("id", $data["uid"])->update(["vip_end_time" => $vip_end_time]); goto BYllf; lbfrr: $vip_end_time = time() + 86400 * $data["time"] * 30; goto KFlZL; YJWU5: xJBTP: goto RKSJd; KFlZL: O9Qo8: goto BSrrZ; HMdqW: if ($db_ins) { goto nR4yL; } goto soWCS; eqqN3: $db_ins = Db::name("user_amount")->insert($ins); goto HMdqW; X5fNR: $vip_end_time = $user_info["vip_end_time"] + 86400 * $data["time"] * 30; goto NRzei; Sn_DT: kDxVN: goto lbfrr; UP0x1: return json_encode($rs); goto ecMU4; soWCS: Db::rollback(); goto EDIpA; s3elV: Db::rollback(); goto iRWRZ; re3E9: Db::rollback(); goto DqRJh; ecMU4: } catch (\Exception $e) { goto hsOPw; hsOPw: Db::rollback(); goto oE5ke; oE5ke: $rs = ["status" => "error", "msg" => "" . $e->getMessage()]; goto B9I46; B9I46: return json_encode($rs); goto wFLT1; wFLT1: } goto L8dl7; g2ZNF: $rs = ["status" => "error", "msg" => $design["currency"] . ""]; goto PgTuq; z5o6o: $ins["much_id"] = $data["much_id"]; goto xxU2T; HQxTJ: J36gc: goto fN0xk; brTPo: fk6cW: goto sl453; uH7Yz: $ins["evaluate"] = 0; goto hgGZZ; eI_H3: $design = Db::name("design")->where("much_id", $data["much_id"])->find(); goto WIu5v; UBcKZ: Db::startTrans(); goto PmF5r; PgTuq: return json_encode($rs); goto AmL3V; fN0xk: $money = sprintf("%.1f", $info["discount_scale"] * $info["hono_price"]); goto brTPo; uSBmW: $user_info = Db::name("user")->where("id", $data["uid"])->find(); goto eI_H3; zMVKA: $rs = ["status" => "success", "msg" => ""]; goto xyXfT; sl453: $msg = "" . $data["time"] . ""; goto k_tSK; EiI17: $ins["poem_conch"] = $user_info["conch"]; goto Wy2SM; k_tSK: if (!($user_info["conch"] < $money)) { goto jrdjp; } goto g2ZNF; WIu5v: if ($data["time"] == 1 && $info["first_discount"] == 1 && $user_info["vip_end_time"] == '') { goto J36gc; } goto VGfFs; L8dl7: } public  
 
 function do_pay() { goto uKsEw; WawP6: y3NE9: goto Qew0Q; k9NDd: foreach ($getConfig as $key => $value) { goto DN9Vf; DN9Vf: if (!($key != "id" && $key != "pay_react" && $key != "much_id")) { goto PsDAc; } goto tmBPK; OyByL: PsDAc: goto RQpaf; tmBPK: $getConfig[$key] = authcode($getConfig[$key], "DECODE", "YuluoNetwork", 0); goto OyByL; RQpaf: sUz3J: goto BMJsg; BMJsg: } goto uZrxr; DOinM: if (cache("fatal_" . $data["much_id"])) { goto y3NE9; } goto jinEE; gQ5Lf: $design = Db::name("design")->where("much_id", $data["much_id"])->find(); goto Bx6UU; m7MdK: define("APPID", $getConfig["app_id"]); goto QQvC2; efcBI: if (!$getConfig) { goto hvpsh; } goto k9NDd; Cis9t: define("KEY", $getConfig["app_key"]); goto BjuCm; uKsEw: $data = input("param."); goto DOinM; uZrxr: Z0eSe: goto T_VFq; nMvWw: aPyB7: goto m7MdK; J7szw: return $this->pay($data, $getConfig, $msg, substr(sprintf("%.3f", $data["money"]), 0, -1)); goto OZdAf; YTiBG: hvpsh: goto zn1jv; jinEE: $getConfig = Db::name("config")->where("much_id", $data["much_id"])->find(); goto efcBI; zn1jv: goto aPyB7; goto WawP6; QQvC2: define("MCHID", $getConfig["app_mchid"]); goto Cis9t; Qew0Q: $getConfig = cache("fatal_" . $data["much_id"]); goto nMvWw; Bx6UU: $msg = "" . substr(sprintf("%.3f", $data["money"]), 0, -1) . $design["currency"]; goto J7szw; BjuCm: define("APPSECRET", $getConfig["app_secret"]); goto gQ5Lf; T_VFq: cache("fatal_" . $data["much_id"], $getConfig); goto YTiBG; OZdAf: } 
 
 
  public function pay($data, $getConfig, $msg, $money) { goto iytBX; ZBJQZ: return json_encode($order); goto biirh; EloOT: $input->SetTotal_fee($money * 100); goto oAc0T; CZaXj: $input->SetOpenid($data["openid"]); goto nU1la; JgJXs: header("Content-Type: application/json"); goto i5c2v; ldpxD: $order = \WxPayApi::unifiedOrder($input); goto JgJXs; lzYnM: $input->SetBody($msg); goto XxlnU; y4MCV: $input = new \WxPayUnifiedOrder(); goto lzYnM; XxlnU: $input->SetOut_trade_no($order_no); goto EloOT; i5c2v: $order["app_info"] = $getConfig; goto uRrGk; uRrGk: Db::name("user_serial")->insert(["add_time" => time(), "money" => $money, "user_id" => $data["uid"], "single_mark" => $order_no, "much_id" => $data["much_id"]]); goto ZBJQZ; nU1la: $input->SetNotify_url($getConfig["pay_react"]); goto ldpxD; oAc0T: $input->SetTrade_type("JSAPI"); goto CZaXj; iytBX: $order_no = time() . rand(10000, 999999); goto y4MCV; biirh: } } ?>

Did this file decode correctly?

Original Code

<?php
 namespace app\api\controller; use app\common\Tension; use think\Db; use think\Request; require EXTEND_PATH . "\x57\170\160\x61\171\57\x57\x78\x50\x61\x79\x2e\101\x70\151\56\x70\150\160"; class Pay extends Base { public function __construct(Request $request = null) { parent::__construct($request); $this->_initialize(); } public function _initialize() { goto IB4Dl; IB4Dl: $ten = Tension::otherwise(); goto t_9_9; t_9_9: if (!($ten == "\x65\162\162\x6f\162")) { goto j5NYm; } goto uwKVW; AeWZz: j5NYm: goto pIxPu; uAWrK: exit; goto AeWZz; uwKVW: echo "\x65\x72\162\157\162"; goto uAWrK; pIxPu: } public function index() { goto zMVKA; fZmxA: $ins["\143\x61\164\x65\147\x6f\162\171"] = "\x32"; goto sJWzH; Ou8EI: goto fk6cW; goto HQxTJ; xxU2T: $ins["\x66\151\x6e\x61\156\143\145"] = -$money; goto uH7Yz; xyXfT: $data = input("\x70\x61\162\x61\155\x2e"); goto shPrE; Wy2SM: $ins["\163\165\162\160\x6c\165\163\x5f\x63\x6f\x6e\x63\150"] = $user_info["\143\x6f\x6e\x63\x68"] - $money; goto UBcKZ; shPrE: $info = Db::name("\x75\x73\145\162\x5f\x68\157\156\x6f\x72\x61\x72\171")->where("\155\x75\143\150\x5f\151\144", $data["\155\x75\143\150\137\x69\x64"])->find(); goto uSBmW; XOOa1: $ins["\x73\x6f\154\165\164\x69\157\156"] = $msg; goto z5o6o; AmL3V: jrdjp: goto Eio0L; hgGZZ: $ins["\160\157\145\155\x5f\x66\x72\x61\143\x74\151\157\156"] = $user_info["\x66\x72\141\143\164\x69\x6f\x6e"]; goto EiI17; VGfFs: $money = $data["\164\x69\155\145"] * $info["\150\x6f\x6e\x6f\137\x70\x72\151\x63\x65"]; goto Ou8EI; sJWzH: $ins["\x72\x75\x69\156\163\x5f\164\151\155\145"] = time(); goto XOOa1; Eio0L: $ins["\165\163\x65\x72\137\x69\x64"] = $data["\165\x69\144"]; goto fZmxA; PmF5r: try { goto eqqN3; ZWi0k: return json_encode($rs); goto vjlOE; UNzkM: if ($dec) { goto xJBTP; } goto s3elV; iRWRZ: $rs = ["\163\x74\141\164\165\x73" => "\145\x72\162\157\x72", "\x6d\163\x67" => "\xe8\xb4\255\344\271\xb0\345\244\xb1\350\xb4\xa5\xef\xbc\x81"]; goto DDM3D; TIeGc: DMOEI: goto WwL5l; RKSJd: if ($user_info["\166\x69\160\137\145\x6e\x64\137\x74\x69\x6d\145"] < time()) { goto kDxVN; } goto X5fNR; tnUy7: nR4yL: goto bgvrb; WwL5l: Db::commit(); goto UP0x1; vjlOE: goto DMOEI; goto tnUy7; EDIpA: $rs = ["\163\x74\141\164\165\x73" => "\145\162\162\157\x72", "\155\163\147" => "\350\xb4\xad\344\xb9\260\345\244\261\xe8\264\xa5\357\274\201"]; goto ZWi0k; qAijr: Q0UQQ: goto TIeGc; wuriF: return json_encode($rs); goto qAijr; bgvrb: $dec = Db::name("\165\x73\145\162")->where("\151\144", $data["\x75\151\144"])->setDec("\143\x6f\x6e\143\150", $money); goto UNzkM; NRzei: goto O9Qo8; goto Sn_DT; BYllf: if ($up_vip) { goto Q0UQQ; } goto re3E9; DDM3D: return json_encode($rs); goto YJWU5; DqRJh: $rs = ["\x73\164\141\164\x75\163" => "\145\162\162\x6f\x72", "\x6d\x73\x67" => "\350\264\xad\xe4\271\xb0\xe5\xa4\xb1\xe8\264\245\357\274\201"]; goto wuriF; BSrrZ: $up_vip = Db::name("\165\x73\145\x72")->where("\x69\x64", $data["\x75\x69\x64"])->update(["\x76\151\x70\x5f\145\x6e\x64\x5f\164\151\x6d\145" => $vip_end_time]); goto BYllf; lbfrr: $vip_end_time = time() + 86400 * $data["\164\151\155\145"] * 30; goto KFlZL; YJWU5: xJBTP: goto RKSJd; KFlZL: O9Qo8: goto BSrrZ; HMdqW: if ($db_ins) { goto nR4yL; } goto soWCS; eqqN3: $db_ins = Db::name("\x75\x73\145\x72\x5f\x61\155\157\165\156\164")->insert($ins); goto HMdqW; X5fNR: $vip_end_time = $user_info["\x76\x69\x70\x5f\x65\156\144\137\x74\x69\x6d\145"] + 86400 * $data["\x74\x69\155\145"] * 30; goto NRzei; Sn_DT: kDxVN: goto lbfrr; UP0x1: return json_encode($rs); goto ecMU4; soWCS: Db::rollback(); goto EDIpA; s3elV: Db::rollback(); goto iRWRZ; re3E9: Db::rollback(); goto DqRJh; ecMU4: } catch (\Exception $e) { goto hsOPw; hsOPw: Db::rollback(); goto oE5ke; oE5ke: $rs = ["\x73\164\x61\x74\165\x73" => "\x65\162\162\x6f\162", "\x6d\x73\147" => "\347\xbd\221\xe7\273\234\344\270\215\xe7\250\xb3\xe5\xae\232\357\xbc\214\xe8\257\267\xe9\207\215\350\xaf\225\xef\xbc\201" . $e->getMessage()]; goto B9I46; B9I46: return json_encode($rs); goto wFLT1; wFLT1: } goto L8dl7; g2ZNF: $rs = ["\x73\164\141\x74\x75\x73" => "\x65\x72\x72\157\162", "\155\x73\147" => $design["\x63\x75\162\x72\x65\x6e\x63\171"] . "\xe4\xb8\x8d\350\266\263\xef\xbc\214\350\257\267\xe5\205\x85\xe5\200\274\357\274\201"]; goto PgTuq; z5o6o: $ins["\x6d\x75\143\x68\137\x69\x64"] = $data["\x6d\165\143\150\137\151\144"]; goto xxU2T; HQxTJ: J36gc: goto fN0xk; brTPo: fk6cW: goto sl453; uH7Yz: $ins["\x65\x76\141\x6c\165\x61\x74\145"] = 0; goto hgGZZ; eI_H3: $design = Db::name("\x64\x65\x73\x69\x67\x6e")->where("\x6d\x75\x63\150\137\x69\144", $data["\155\165\143\150\x5f\x69\144"])->find(); goto WIu5v; UBcKZ: Db::startTrans(); goto PmF5r; PgTuq: return json_encode($rs); goto AmL3V; fN0xk: $money = sprintf("\45\56\61\146", $info["\x64\151\163\x63\157\165\x6e\x74\137\x73\143\x61\x6c\x65"] * $info["\150\x6f\x6e\157\137\x70\x72\151\x63\x65"]); goto brTPo; uSBmW: $user_info = Db::name("\x75\163\145\162")->where("\151\x64", $data["\165\151\144"])->find(); goto eI_H3; zMVKA: $rs = ["\163\x74\141\164\165\163" => "\163\x75\x63\143\145\x73\x73", "\155\x73\147" => "\xe8\264\xad\344\271\260\346\x88\220\345\x8a\237"]; goto xyXfT; sl453: $msg = "\350\xb4\255\xe4\271\xb0\xe4\xbc\x9a\345\x91\x98\xef\274\x88" . $data["\x74\x69\x6d\145"] . "\344\xb8\xaa\346\x9c\x88\xef\xbc\x89"; goto k_tSK; EiI17: $ins["\x70\157\145\x6d\x5f\143\x6f\156\143\150"] = $user_info["\143\157\x6e\x63\150"]; goto Wy2SM; k_tSK: if (!($user_info["\143\157\x6e\143\150"] < $money)) { goto jrdjp; } goto g2ZNF; WIu5v: if ($data["\x74\151\155\x65"] == 1 && $info["\146\x69\162\163\x74\x5f\144\x69\x73\x63\x6f\165\156\x74"] == 1 && $user_info["\x76\x69\x70\x5f\145\156\x64\x5f\164\151\155\145"] == '') { goto J36gc; } goto VGfFs; L8dl7: } public 

 function do_pay() { goto uKsEw; WawP6: y3NE9: goto Qew0Q; k9NDd: foreach ($getConfig as $key => $value) { goto DN9Vf; DN9Vf: if (!($key != "\151\x64" && $key != "\160\141\171\x5f\x72\x65\x61\143\164" && $key != "\155\165\x63\150\137\151\144")) { goto PsDAc; } goto tmBPK; OyByL: PsDAc: goto RQpaf; tmBPK: $getConfig[$key] = authcode($getConfig[$key], "\104\105\x43\x4f\104\x45", "\131\x75\x6c\x75\x6f\x4e\x65\x74\x77\157\x72\x6b", 0); goto OyByL; RQpaf: sUz3J: goto BMJsg; BMJsg: } goto uZrxr; DOinM: if (cache("\146\141\164\x61\x6c\137" . $data["\x6d\165\143\x68\x5f\x69\144"])) { goto y3NE9; } goto jinEE; gQ5Lf: $design = Db::name("\x64\145\x73\151\147\x6e")->where("\155\165\143\150\x5f\151\x64", $data["\155\x75\143\x68\137\151\144"])->find(); goto Bx6UU; m7MdK: define("\101\x50\120\111\x44", $getConfig["\x61\x70\x70\137\151\144"]); goto QQvC2; efcBI: if (!$getConfig) { goto hvpsh; } goto k9NDd; Cis9t: define("\113\x45\x59", $getConfig["\141\160\160\137\153\145\x79"]); goto BjuCm; uKsEw: $data = input("\160\141\x72\x61\x6d\x2e"); goto DOinM; uZrxr: Z0eSe: goto T_VFq; nMvWw: aPyB7: goto m7MdK; J7szw: return $this->pay($data, $getConfig, $msg, substr(sprintf("\45\x2e\63\146", $data["\155\x6f\x6e\145\x79"]), 0, -1)); goto OZdAf; YTiBG: hvpsh: goto zn1jv; jinEE: $getConfig = Db::name("\x63\x6f\x6e\146\151\147")->where("\x6d\x75\143\x68\x5f\151\144", $data["\155\165\x63\x68\137\x69\x64"])->find(); goto efcBI; zn1jv: goto aPyB7; goto WawP6; QQvC2: define("\x4d\x43\x48\111\x44", $getConfig["\141\x70\160\137\x6d\143\x68\x69\x64"]); goto Cis9t; Qew0Q: $getConfig = cache("\146\x61\x74\x61\154\x5f" . $data["\x6d\x75\143\x68\137\151\x64"]); goto nMvWw; Bx6UU: $msg = "\xe5\x85\205\xe5\x80\xbc" . substr(sprintf("\x25\56\63\146", $data["\155\x6f\156\x65\x79"]), 0, -1) . $design["\143\x75\x72\162\145\x6e\143\171"]; goto J7szw; BjuCm: define("\x41\x50\120\123\x45\103\122\x45\124", $getConfig["\x61\x70\160\137\x73\x65\x63\162\145\x74"]); goto gQ5Lf; T_VFq: cache("\146\x61\x74\x61\154\137" . $data["\155\165\143\x68\137\151\x64"], $getConfig); goto YTiBG; OZdAf: }


  public function pay($data, $getConfig, $msg, $money) { goto iytBX; ZBJQZ: return json_encode($order); goto biirh; EloOT: $input->SetTotal_fee($money * 100); goto oAc0T; CZaXj: $input->SetOpenid($data["\x6f\x70\145\156\151\144"]); goto nU1la; JgJXs: header("\x43\157\x6e\x74\145\x6e\x74\x2d\124\x79\x70\145\x3a\40\141\x70\160\154\x69\143\x61\x74\x69\157\x6e\57\152\x73\x6f\156"); goto i5c2v; ldpxD: $order = \WxPayApi::unifiedOrder($input); goto JgJXs; lzYnM: $input->SetBody($msg); goto XxlnU; y4MCV: $input = new \WxPayUnifiedOrder(); goto lzYnM; XxlnU: $input->SetOut_trade_no($order_no); goto EloOT; i5c2v: $order["\141\160\160\137\151\156\146\157"] = $getConfig; goto uRrGk; uRrGk: Db::name("\x75\x73\x65\x72\137\163\145\162\151\x61\x6c")->insert(["\141\144\144\x5f\164\151\x6d\x65" => time(), "\155\x6f\156\x65\x79" => $money, "\165\x73\145\x72\137\x69\144" => $data["\x75\x69\144"], "\x73\151\156\147\x6c\x65\137\155\141\x72\x6b" => $order_no, "\155\165\143\150\x5f\x69\144" => $data["\155\165\143\x68\137\151\144"]]); goto ZBJQZ; nU1la: $input->SetNotify_url($getConfig["\160\141\171\137\x72\x65\141\143\x74"]); goto ldpxD; oAc0T: $input->SetTrade_type("\112\x53\101\120\x49"); goto CZaXj; iytBX: $order_no = time() . rand(10000, 999999); goto y4MCV; biirh: } }

Function Calls

None

Variables

None

Stats

MD5 f1777c6cd5be65d9ce10e17b3bd6bd9b
Eval Count 0
Decode Time 105 ms