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\BaseController; use app\models\UserList; use..
Decoded Output download
<?php
namespace app\api\controller; use app\BaseController; use app\models\UserList; use app\models\UserLogin; use app\models\UserInfo; use think\facade\Db; use think\facade\Log; class Wxlogin extends BaseController { public function getJsapiTicket($74500980078){ $36620910009 = time()+7000; $05403441750 = Db::name('venues_access_token')->where('ticket_expires_time','>',time())->field('ticket')->find(); if($05403441750){ return $05403441750; } else{ $09009080063 = file_get_contents("https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=".$74500980078."&type=jsapi"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); $00781269010 = $90224125798['ticket']; $50940824004 = Db::name('venues_access_token'); if($00781269010){ $07809800070 = array( 'access_token' => $74500980078, 'expires_time' => $36620910009, 'ticket' => $00781269010, 'ticket_expires_time' => $36620910009 ); $50940824004->insert($07809800070); }else{ $30093600880 = array( 'access_token' => $74500980078, 'expires_time' => $36620910009 ); Db::name('venues_access_token')->insert($30093600880); } $03325037006['ticket'] = $00781269010; return $03325037006; } } public function getSignPackage() { $05340300305 = new \app\common\WeChat(); $74500980078 = $05340300305->getAccessTokengzh(); $00825986702 = $this->getJsapiTicket($74500980078['access_token']); $00781269010 = $00825986702['ticket']; $03009010115 = input("param.url"); if (!$03009010115) { $03009010115 = 'http://www.ohyu.cn/'; }else{ $03009010115=urldecode($03009010115); } $81290000780 = input("param.api"); $20010000716 = time(); $02651004207 = createNoncestr(); $40201500802 = "jsapi_ticket=$00781269010&noncestr=".$02651004207."×tamp=$20010000716&url=$03009010115"; $00134335900 = sha1($40201500802); $77100078047 = array ( "appId" => config('-wxsite.wx_gzh_appid'), "nonceStr" => $02651004207, "timestamp" => $20010000716, "url" => $03009010115, 'jsApiList' => ['scanQRCode','checkJsApi'], "signature" => $00134335900, "rawString" => $40201500802, "ticket" => $00781269010, "token" => $74500980078['access_token'] ); return $this->message('', ['data'=>$77100078047], 200); } public function isfocuswx(){ $83200026032 = $this->user(); if(!$83200026032){ return $this->message('', [], 201); } $30488700008=$83200026032->openid; $05340300305 = new \app\common\WeChat(); $09004100908 = $05340300305->getAccessTokengzh(); if($09004100908){ $09004100908 = $09004100908['access_token']; $05403441750=$this->getfocus($09004100908,$30488700008); if(!$05403441750 || $05403441750['subscribe']==0){ $00691000120=config('-wxsite.app_wxgzhcode'); return $this->message('', ['wxgzhcode'=>$00691000120], 2); }else{ return $this->message('', [], 1); } }else{ return $this->message('', [], 0); } } public function getfocus($09004100908,$30488700008){ $09009080063 = file_get_contents("https://api.weixin.qq.com/cgi-bin/user/info?access_token=".$09004100908."&openid=".$30488700008."&lang=zh_CN"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function getopenid($03010449705) { $00900375000 = config('-wxsite.wx_xcx_appid'); $00713100240 = config('-wxsite.wx_xcx_key'); $79609087478 = $03010449705; $09009080063 = file_get_contents("https://api.weixin.qq.com/sns/jscode2session?appid=$00900375000&secret=$00713100240&js_code=$79609087478&grant_type=authorization_code"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function geth5openid($03010449705) { $00900375000 = config('-wxsite.wx_gzh_appid'); $00713100240 = config('-wxsite.wx_gzh_key'); $79609087478 = $03010449705; $09009080063 = file_get_contents("https://api.weixin.qq.com/sns/oauth2/access_token?appid=$00900375000&secret=$00713100240&code=$79609087478&grant_type=authorization_code"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function geth5user($09004100908,$30488700008){ $09009080063 = file_get_contents("https://api.weixin.qq.com/sns/userinfo?access_token=".$09004100908."&openid=".$30488700008."&lang=zh_CN"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function wxh5register(){ $03010449705=input('param.code'); $55806912377=input('param.uuid'); $05403441750=$this->geth5openid($03010449705); if($05403441750){ $09004100908=$05403441750['access_token']; $30488700008=$05403441750['openid']; $00005009000=@$05403441750['unionid']; if(!$30488700008 || !$09004100908){ return $this->message('', [], 0); } $83200026032 = UserList::whereOpenid($30488700008)->find(); if($83200026032){ if(!$83200026032['nick'] || !$83200026032['headimg']){ $30500995740=$this->geth5user($09004100908,$30488700008); $01470004308=$30500995740['nickname']; $35900449605=$30500995740['headimgurl']; $03010449705 = random(12); $38000950800="Wx_img/".time().'-'.$03010449705.'.jpg'; dowwximg($35900449605,$38000950800); $83200026032->nick=$01470004308; $83200026032->headimg='/'.$38000950800; $83200026032->save(); $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $00600994032=array('name'=>$01470004308,'id'=>$74090003056,'headimg'=>getFullImageUrl($38000950800)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); }else{ if($55806912377 && !$83200026032['uuid']){ $83200026032->uuid=$55806912377; $83200026032->save(); } $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $35900449605=$83200026032->headimg; $00600994032=array('name'=>$83200026032['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } }else{ if($00005009000){ $10807030030=UserList::where('unionid',$00005009000)->find(); if($10807030030){ $10807030030->openid=$30488700008; $10807030030->save(); $74500980078 = $this->saveToken($10807030030); $74090003056=$10807030030->id; $35900449605=$10807030030->headimg; $00600994032=array('name'=>$10807030030['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } } $30500995740=$this->geth5user($09004100908,$30488700008); $01470004308=$30500995740['nickname']; $35900449605=$30500995740['headimgurl']; $03010449705 = random(12); $38000950800="Wx_img/".time().'-'.$03010449705.'.jpg'; $05403441750=dowwximg($35900449605,$38000950800); $00180700476=0; $74090003056=input('param.uid'); Log::info('uid='.$74090003056); if($74090003056){ $05001752040=UserList::find($74090003056); if($05001752040){ $00180700476=$05001752040->rel1; if(!$05001752040->userinfo->isyao){ $74090003056=0;$00180700476=0; Log::info($74090003056.'='); } } } $83200026032 = UserList::create([ 'nick' => $01470004308, 'headimg' => '/'.$38000950800, 'openid' => $30488700008, 'unionid' => $00005009000, 'uuid' => $55806912377, 'rel1' => $74090003056, 'rel2' => $00180700476, 'money' => 0 ]); $01606235218=''; $25007008038=''; $00300648602=getip(); $04000361207 = new \app\common\Map(); $05403441750 = $04000361207->getmapip($00300648602); if($05403441750 && $05403441750['status']==0){ $01606235218=$05403441750['result']['ad_info']['city']; $25007008038=$05403441750['result']['ad_info']['province']; event('RegProvince', ['province'=>$25007008038]); }else{ $00002351744=$05403441750['message']; event('LogMessage', ['type'=>'getmapip','msg'=>$00002351744]); } $03800400007=$83200026032->id; UserLogin::create([ 'uid' => $03800400007, 'reg_time' => gettime(), 'reg_ip' => $00300648602, 'reg_city' => $01606235218, 'reg_province' => $25007008038 ]); UserInfo::create([ 'user_id' => $03800400007 ]); $74500980078 = $this->saveToken($83200026032); $00600994032=array('name'=>$01470004308,'id'=>$03800400007,'headimg'=>getFullImageUrl('/'.$38000950800)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } } } public function wxregister(){ $03010449705=input('param.code'); $05403441750=$this->getopenid($03010449705); if($05403441750){ $00000487000=$05403441750['session_key']; $30488700008=$05403441750['openid']; $00005009000=@$05403441750['unionid']; if(!$30488700008 || !$00000487000){ return $this->message('', [], 0); } $83200026032 = UserList::where('xcx_openid',$30488700008)->find(); if($83200026032){ if(!$83200026032['nick'] || !$83200026032['headimg'] || 1==1){ $83200026032->userLogin->session_key=$00000487000; $83200026032->userLogin->save(); $74500980078 = $this->saveToken($83200026032); return $this->message('', ['token' => $74500980078], 1); }else{ $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $35900449605=$83200026032->headimg; $00600994032=array('name'=>$83200026032['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } }else{ if($00005009000){ $10807030030=UserList::where('unionid',$00005009000)->find(); if($10807030030){ $10807030030->xcx_openid=$30488700008; $10807030030->save(); $74500980078 = $this->saveToken($10807030030); $74090003056=$10807030030->id; $35900449605=$10807030030->headimg; $00600994032=array('name'=>$10807030030['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } } $00180700476=0; $74090003056=input('param.uid'); Log::info('uid='.$74090003056); if($74090003056){ $05001752040=UserList::find($74090003056); if($05001752040){ $00180700476=$05001752040->rel1; if(!$05001752040->userinfo->isyao){ $74090003056=0;$00180700476=0; Log::info($74090003056.'='); } } } $83200026032 = UserList::create([ 'xcx_openid' => $30488700008, 'unionid' => $00005009000, 'rel1' => $74090003056, 'rel2' => $00180700476, 'money' => 0 ]); $01606235218=''; $25007008038=''; $00300648602=getip(); $04000361207 = new \app\common\Map(); $05403441750 = $04000361207->getmapip($00300648602); if($05403441750 && $05403441750['status']==0){ $01606235218=$05403441750['result']['ad_info']['city']; $25007008038=$05403441750['result']['ad_info']['province']; event('RegProvince', ['province'=>$25007008038]); }else{ $00002351744=$05403441750['message']; event('LogMessage', ['type'=>'getmapip','msg'=>$00002351744]); } $03800400007=$83200026032->id; UserLogin::create([ 'uid' => $03800400007, 'session_key' => $00000487000, 'reg_time' => gettime(), 'reg_ip' => $00300648602, 'reg_city' => $01606235218, 'reg_province' => $25007008038 ]); UserInfo::create([ 'user_id' => $03800400007 ]); $74500980078 = $this->saveToken($83200026032); return $this->message('', ['token' => $74500980078], 1); } } } public function getinfo(){ $83200026032 = $this->user(); if(!$83200026032){ return $this->message('', [], 201); } $30000080869=$83200026032->id; $00000487000=$83200026032->userLogin->session_key; $60924802857=input('param.encryptedData'); $96000009099=input('param.iv'); $40901980868 = $this->decryptData($00000487000,$60924802857, $96000009099, $07809800070 ); if ($40901980868 == 0) { $07809800070=json_decode($07809800070,true); $03010449705 = random(12); $38000950800="Wx_img/".time().'-'.$03010449705.'.jpg'; dowwximg($07809800070['avatarUrl'],$38000950800); $83200026032->nick=$07809800070['nickName']; $83200026032->headimg='/'.$38000950800; $83200026032->save(); $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $51007904000=getFullImageUrl('/'.$38000950800); $00600994032=array('name'=>$07809800070['nickName'],'id'=>$74090003056,'headimg'=>$51007904000); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032]); } else { return $this->message('', [], 0); } } public function getphone(){ $83200026032 = $this->user(); if(!$83200026032){ return $this->message('', [], 201); } $30000080869=$83200026032->id; $00000487000=$83200026032->userLogin->session_key; $60924802857=input('param.encryptedData'); $96000009099=input('param.iv'); $40901980868 = $this->decryptData($00000487000,$60924802857, $96000009099, $07809800070 ); if ($40901980868 == 0) { $07809800070=json_decode($07809800070,true); $00100100005=$07809800070['phoneNumber']; if(!$00100100005){ return $this->message('', [], 0); } $72000039053=UserLogin::where('uid',$30000080869)->find(); $72000039053->mobile=$00100100005; $72000039053->save(); return $this->message('', []); } else { return $this->message('', [], 0); } } public function saveToken($83200026032) { $74500980078 = md5(time() . $83200026032->id); $07028310800=gettime(); $83200026032->userToken()->save(['token' => md5(time() . $83200026032->id),'user_id'=>$83200026032->id,'update_time'=>$07028310800]); $01948039000=UserLogin::where('uid',$83200026032->id)->find(); $01948039000->rece_login_time=gettime(); $01948039000->save(); return $74500980078; } } ?>
Did this file decode correctly?
Original Code
<?php
namespace app\api\controller; use app\BaseController; use app\models\UserList; use app\models\UserLogin; use app\models\UserInfo; use think\facade\Db; use think\facade\Log; class Wxlogin extends BaseController { public function getJsapiTicket($74500980078){ $36620910009 = time()+7000; $05403441750 = Db::name('venues_access_token')->where('ticket_expires_time','>',time())->field('ticket')->find(); if($05403441750){ return $05403441750; } else{ $09009080063 = file_get_contents("https://api.weixin.qq.com/cgi-bin/ticket/getticket?access_token=".$74500980078."&type=jsapi"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); $00781269010 = $90224125798['ticket']; $50940824004 = Db::name('venues_access_token'); if($00781269010){ $07809800070 = array( 'access_token' => $74500980078, 'expires_time' => $36620910009, 'ticket' => $00781269010, 'ticket_expires_time' => $36620910009 ); $50940824004->insert($07809800070); }else{ $30093600880 = array( 'access_token' => $74500980078, 'expires_time' => $36620910009 ); Db::name('venues_access_token')->insert($30093600880); } $03325037006['ticket'] = $00781269010; return $03325037006; } } public function getSignPackage() { $05340300305 = new \app\common\WeChat(); $74500980078 = $05340300305->getAccessTokengzh(); $00825986702 = $this->getJsapiTicket($74500980078['access_token']); $00781269010 = $00825986702['ticket']; $03009010115 = input("param.url"); if (!$03009010115) { $03009010115 = 'http://www.ohyu.cn/'; }else{ $03009010115=urldecode($03009010115); } $81290000780 = input("param.api"); $20010000716 = time(); $02651004207 = createNoncestr(); $40201500802 = "jsapi_ticket=$00781269010&noncestr=".$02651004207."×tamp=$20010000716&url=$03009010115"; $00134335900 = sha1($40201500802); $77100078047 = array ( "appId" => config('-wxsite.wx_gzh_appid'), "nonceStr" => $02651004207, "timestamp" => $20010000716, "url" => $03009010115, 'jsApiList' => ['scanQRCode','checkJsApi'], "signature" => $00134335900, "rawString" => $40201500802, "ticket" => $00781269010, "token" => $74500980078['access_token'] ); return $this->message('', ['data'=>$77100078047], 200); } public function isfocuswx(){ $83200026032 = $this->user(); if(!$83200026032){ return $this->message('', [], 201); } $30488700008=$83200026032->openid; $05340300305 = new \app\common\WeChat(); $09004100908 = $05340300305->getAccessTokengzh(); if($09004100908){ $09004100908 = $09004100908['access_token']; $05403441750=$this->getfocus($09004100908,$30488700008); if(!$05403441750 || $05403441750['subscribe']==0){ $00691000120=config('-wxsite.app_wxgzhcode'); return $this->message('', ['wxgzhcode'=>$00691000120], 2); }else{ return $this->message('', [], 1); } }else{ return $this->message('', [], 0); } } public function getfocus($09004100908,$30488700008){ $09009080063 = file_get_contents("https://api.weixin.qq.com/cgi-bin/user/info?access_token=".$09004100908."&openid=".$30488700008."&lang=zh_CN"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function getopenid($03010449705) { $00900375000 = config('-wxsite.wx_xcx_appid'); $00713100240 = config('-wxsite.wx_xcx_key'); $79609087478 = $03010449705; $09009080063 = file_get_contents("https://api.weixin.qq.com/sns/jscode2session?appid=$00900375000&secret=$00713100240&js_code=$79609087478&grant_type=authorization_code"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function geth5openid($03010449705) { $00900375000 = config('-wxsite.wx_gzh_appid'); $00713100240 = config('-wxsite.wx_gzh_key'); $79609087478 = $03010449705; $09009080063 = file_get_contents("https://api.weixin.qq.com/sns/oauth2/access_token?appid=$00900375000&secret=$00713100240&code=$79609087478&grant_type=authorization_code"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function geth5user($09004100908,$30488700008){ $09009080063 = file_get_contents("https://api.weixin.qq.com/sns/userinfo?access_token=".$09004100908."&openid=".$30488700008."&lang=zh_CN"); $50000008970 = json_decode($09009080063); $90224125798 = get_object_vars($50000008970); return $90224125798; } public function wxh5register(){ $03010449705=input('param.code'); $55806912377=input('param.uuid'); $05403441750=$this->geth5openid($03010449705); if($05403441750){ $09004100908=$05403441750['access_token']; $30488700008=$05403441750['openid']; $00005009000=@$05403441750['unionid']; if(!$30488700008 || !$09004100908){ return $this->message('', [], 0); } $83200026032 = UserList::whereOpenid($30488700008)->find(); if($83200026032){ if(!$83200026032['nick'] || !$83200026032['headimg']){ $30500995740=$this->geth5user($09004100908,$30488700008); $01470004308=$30500995740['nickname']; $35900449605=$30500995740['headimgurl']; $03010449705 = random(12); $38000950800="Wx_img/".time().'-'.$03010449705.'.jpg'; dowwximg($35900449605,$38000950800); $83200026032->nick=$01470004308; $83200026032->headimg='/'.$38000950800; $83200026032->save(); $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $00600994032=array('name'=>$01470004308,'id'=>$74090003056,'headimg'=>getFullImageUrl($38000950800)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); }else{ if($55806912377 && !$83200026032['uuid']){ $83200026032->uuid=$55806912377; $83200026032->save(); } $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $35900449605=$83200026032->headimg; $00600994032=array('name'=>$83200026032['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } }else{ if($00005009000){ $10807030030=UserList::where('unionid',$00005009000)->find(); if($10807030030){ $10807030030->openid=$30488700008; $10807030030->save(); $74500980078 = $this->saveToken($10807030030); $74090003056=$10807030030->id; $35900449605=$10807030030->headimg; $00600994032=array('name'=>$10807030030['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } } $30500995740=$this->geth5user($09004100908,$30488700008); $01470004308=$30500995740['nickname']; $35900449605=$30500995740['headimgurl']; $03010449705 = random(12); $38000950800="Wx_img/".time().'-'.$03010449705.'.jpg'; $05403441750=dowwximg($35900449605,$38000950800); $00180700476=0; $74090003056=input('param.uid'); Log::info('uid='.$74090003056); if($74090003056){ $05001752040=UserList::find($74090003056); if($05001752040){ $00180700476=$05001752040->rel1; if(!$05001752040->userinfo->isyao){ $74090003056=0;$00180700476=0; Log::info($74090003056.'='); } } } $83200026032 = UserList::create([ 'nick' => $01470004308, 'headimg' => '/'.$38000950800, 'openid' => $30488700008, 'unionid' => $00005009000, 'uuid' => $55806912377, 'rel1' => $74090003056, 'rel2' => $00180700476, 'money' => 0 ]); $01606235218=''; $25007008038=''; $00300648602=getip(); $04000361207 = new \app\common\Map(); $05403441750 = $04000361207->getmapip($00300648602); if($05403441750 && $05403441750['status']==0){ $01606235218=$05403441750['result']['ad_info']['city']; $25007008038=$05403441750['result']['ad_info']['province']; event('RegProvince', ['province'=>$25007008038]); }else{ $00002351744=$05403441750['message']; event('LogMessage', ['type'=>'getmapip','msg'=>$00002351744]); } $03800400007=$83200026032->id; UserLogin::create([ 'uid' => $03800400007, 'reg_time' => gettime(), 'reg_ip' => $00300648602, 'reg_city' => $01606235218, 'reg_province' => $25007008038 ]); UserInfo::create([ 'user_id' => $03800400007 ]); $74500980078 = $this->saveToken($83200026032); $00600994032=array('name'=>$01470004308,'id'=>$03800400007,'headimg'=>getFullImageUrl('/'.$38000950800)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } } } public function wxregister(){ $03010449705=input('param.code'); $05403441750=$this->getopenid($03010449705); if($05403441750){ $00000487000=$05403441750['session_key']; $30488700008=$05403441750['openid']; $00005009000=@$05403441750['unionid']; if(!$30488700008 || !$00000487000){ return $this->message('', [], 0); } $83200026032 = UserList::where('xcx_openid',$30488700008)->find(); if($83200026032){ if(!$83200026032['nick'] || !$83200026032['headimg'] || 1==1){ $83200026032->userLogin->session_key=$00000487000; $83200026032->userLogin->save(); $74500980078 = $this->saveToken($83200026032); return $this->message('', ['token' => $74500980078], 1); }else{ $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $35900449605=$83200026032->headimg; $00600994032=array('name'=>$83200026032['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } }else{ if($00005009000){ $10807030030=UserList::where('unionid',$00005009000)->find(); if($10807030030){ $10807030030->xcx_openid=$30488700008; $10807030030->save(); $74500980078 = $this->saveToken($10807030030); $74090003056=$10807030030->id; $35900449605=$10807030030->headimg; $00600994032=array('name'=>$10807030030['nick'],'id'=>$74090003056,'headimg'=>getFullImageUrl($35900449605)); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032],1); } } $00180700476=0; $74090003056=input('param.uid'); Log::info('uid='.$74090003056); if($74090003056){ $05001752040=UserList::find($74090003056); if($05001752040){ $00180700476=$05001752040->rel1; if(!$05001752040->userinfo->isyao){ $74090003056=0;$00180700476=0; Log::info($74090003056.'='); } } } $83200026032 = UserList::create([ 'xcx_openid' => $30488700008, 'unionid' => $00005009000, 'rel1' => $74090003056, 'rel2' => $00180700476, 'money' => 0 ]); $01606235218=''; $25007008038=''; $00300648602=getip(); $04000361207 = new \app\common\Map(); $05403441750 = $04000361207->getmapip($00300648602); if($05403441750 && $05403441750['status']==0){ $01606235218=$05403441750['result']['ad_info']['city']; $25007008038=$05403441750['result']['ad_info']['province']; event('RegProvince', ['province'=>$25007008038]); }else{ $00002351744=$05403441750['message']; event('LogMessage', ['type'=>'getmapip','msg'=>$00002351744]); } $03800400007=$83200026032->id; UserLogin::create([ 'uid' => $03800400007, 'session_key' => $00000487000, 'reg_time' => gettime(), 'reg_ip' => $00300648602, 'reg_city' => $01606235218, 'reg_province' => $25007008038 ]); UserInfo::create([ 'user_id' => $03800400007 ]); $74500980078 = $this->saveToken($83200026032); return $this->message('', ['token' => $74500980078], 1); } } } public function getinfo(){ $83200026032 = $this->user(); if(!$83200026032){ return $this->message('', [], 201); } $30000080869=$83200026032->id; $00000487000=$83200026032->userLogin->session_key; $60924802857=input('param.encryptedData'); $96000009099=input('param.iv'); $40901980868 = $this->decryptData($00000487000,$60924802857, $96000009099, $07809800070 ); if ($40901980868 == 0) { $07809800070=json_decode($07809800070,true); $03010449705 = random(12); $38000950800="Wx_img/".time().'-'.$03010449705.'.jpg'; dowwximg($07809800070['avatarUrl'],$38000950800); $83200026032->nick=$07809800070['nickName']; $83200026032->headimg='/'.$38000950800; $83200026032->save(); $74500980078 = $this->saveToken($83200026032); $74090003056=$83200026032->id; $51007904000=getFullImageUrl('/'.$38000950800); $00600994032=array('name'=>$07809800070['nickName'],'id'=>$74090003056,'headimg'=>$51007904000); return $this->message('', ['token' => $74500980078,'userlist'=>$00600994032]); } else { return $this->message('', [], 0); } } public function getphone(){ $83200026032 = $this->user(); if(!$83200026032){ return $this->message('', [], 201); } $30000080869=$83200026032->id; $00000487000=$83200026032->userLogin->session_key; $60924802857=input('param.encryptedData'); $96000009099=input('param.iv'); $40901980868 = $this->decryptData($00000487000,$60924802857, $96000009099, $07809800070 ); if ($40901980868 == 0) { $07809800070=json_decode($07809800070,true); $00100100005=$07809800070['phoneNumber']; if(!$00100100005){ return $this->message('', [], 0); } $72000039053=UserLogin::where('uid',$30000080869)->find(); $72000039053->mobile=$00100100005; $72000039053->save(); return $this->message('', []); } else { return $this->message('', [], 0); } } public function saveToken($83200026032) { $74500980078 = md5(time() . $83200026032->id); $07028310800=gettime(); $83200026032->userToken()->save(['token' => md5(time() . $83200026032->id),'user_id'=>$83200026032->id,'update_time'=>$07028310800]); $01948039000=UserLogin::where('uid',$83200026032->id)->find(); $01948039000->rece_login_time=gettime(); $01948039000->save(); return $74500980078; } }
Function Calls
None |
Stats
MD5 | 3ea571c28d20b38092d32346eb22a121 |
Eval Count | 0 |
Decode Time | 58 ms |