Function mcrypt_create_iv is deprecated

morteza3245

Well-Known Member
Sep 16, 2013
138
1
18
cPanel Access Level
Root Administrator
Hello
i receive below logs, how i fix them?

Code:
Function mcrypt_create_iv() is deprecated (E_DEPRECATED) /home/user/public_html/new/Panel/five/OLnWYNC/class/misc.class.php (1085 line)

Function mcrypt_get_iv_size() is deprecated (E_DEPRECATED) /home/user/public_html/new/misc.class.php (1085 line)

Function mcrypt_encrypt() is deprecated (E_DEPRECATED) /home/user/public_html/new/misc.class.php (1077 line)

Function mcrypt_create_iv() is deprecated (E_DEPRECATED) /home/user/public_html/new/misc.class.php (1077 line)

Function mcrypt_get_iv_size() is deprecated (E_DEPRECATED) /home/user/public_html/new/misc.class.php (1077 line)
Thanks.
 

rpvw

Well-Known Member
Jul 18, 2013
1,088
446
113
Spain
cPanel Access Level
Root Administrator
These functions were DEPRECATED in PHP 7.1.0, and some have been REMOVED in PHP 7.2.0.
PHP: mcrypt_create_iv - Manual
PHP: mcrypt_enc_get_iv_size - Manual
PHP: mcrypt_encrypt - Manual

Switch your PHP to use PHP 7.0 or earlier
OR
Change your PHP code to use a supported encryption eg openssl_encrypt
PHP: OpenSSL Functions - Manual
OR
Switch off the depreciation warnings in your PHP logs using the ~E_DEPRECATED flag (NOT recommended as this just hides the problem and does not solve it)


You may need to ask the developer of the code for advice.
 
  • Like
Reactions: cPanelLauren