我的环境是php7.3.27
$input = 13666666666;
$key = '123456';
$data = base64_encode(openssl_encrypt($input, 'AES-256-CBC', $key, OPENSSL_RAW_DATA))
如果报
// Warning: openssl_encrypt(): Using an empty Initialization Vector (iv) is potentially insecure and not recommended
加个抑制符就好了:'@'
改完后$data = @base64_encode(openssl_encrypt($input, 'AES-256-CBC', $key, OPENSSL_RAW_DATA))
因为是warning级别的,抵制以后,不耽误返回值,我暂时是这样改的