<?php
/*
 本代码由 口号帮 创建
 创建时间 2019-05-08 16:22:09
 技术支持 口号帮 
 严禁反编译、逆向等任何形式的侵权行为，违者将追究法律责任
*/

namespace App\Traits;trait AES{private static $_vi='2018^@YSJR_%ysjr';public $_key='Yu_Shun_Jin_Rong!@#$%^&*2018+<>?';public $wap_key='ySjR!@#$%^&*2018';public $_aes='AES-256-CBC';public $wap_aes='AES-128-CBC';public static function fill($text,$blocksize){$AAA____A="is_array";$P2gAC0=$AAA____A($text);if($P2gAC0)goto P2gBodyx2;goto P2gNextx2;P2gBodyx2:$AAA___A_="implode";$P2gAC0=$AAA___A_('',$text);$array_text=$P2gAC0;$AAA___AA="strlen";$P2gAC0=$AAA___AA($array_text);$P2g0=$P2gAC0%$blocksize;$P2g1=$blocksize-$P2g0;$pad=$P2g1;$P2g0=$text . str_repeat(chr($pad),$pad);return $P2g0;goto P2gx1;P2gNextx2:P2gx1:$P2g0=gettype($text)=='json';if($P2g0)goto P2gBodyx4;goto P2gNextx4;P2gBodyx4:$AAA__A__="implode";$P2gAC0=$AAA__A__('',json_decode($text,true));$json_text=$P2gAC0;$AAA__A_A="strlen";$P2gAC0=$AAA__A_A($json_text);$P2g0=$P2gAC0%$blocksize;$P2g1=$blocksize-$P2g0;$pad=$P2g1;$P2g0=$text . str_repeat(chr($pad),$pad);return $P2g0;goto P2gx3;P2gNextx4:P2gx3:$AAA__AA_="strlen";$P2gAC0=$AAA__AA_($text);$P2g0=$P2gAC0%$blocksize;$P2g1=$blocksize-$P2g0;$pad=$P2g1;$P2g0=$text . str_repeat(chr($pad),$pad);return $P2g0;}public static function encrypt_pass($input,$aes,$key){$encrypted=openssl_encrypt($input,$aes,$key,1,self::$_vi);$AAA__AAA="base64_encode";$P2gAC0=$AAA__AAA($encrypted);$data=$P2gAC0;return $data;}public static function decrypt_pass($sStr,$aes,$sKey){$decrypted=openssl_decrypt(base64_decode($sStr),$aes,$sKey,1,self::$_vi);return $decrypted;}}
?>