From adf0cec07ae3b085ba25e698851fb3c1cb62632b Mon Sep 17 00:00:00 2001 From: cassio Date: Tue, 4 Sep 2018 16:31:48 +0200 Subject: bf --- src/hex.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/hex.php') diff --git a/src/hex.php b/src/hex.php index 2062d69..be7b01e 100644 --- a/src/hex.php +++ b/src/hex.php @@ -50,7 +50,8 @@ function decryptData($crypttext,$key,$txt='') { return ""; } $crypttext = base64_decode($crypttext); - $iv = openssl_random_pseudo_bytes(openssl_cipher_iv_length('aes-256-cbc')); + $iv_size = openssl_cipher_iv_length('aes-256-cbc'); + $iv = openssl_random_pseudo_bytes($iv_size); $test1=''; $test2='x'; $clen = strlen($crypttext); -- cgit v1.2.3