CodeIgniter Forums
mcrypt is deprecated in PHP 7.x - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Development (https://forum.codeigniter.com/forum-6.html)
+--- Forum: CodeIgniter 3.x (https://forum.codeigniter.com/forum-17.html)
+--- Thread: mcrypt is deprecated in PHP 7.x (/thread-68273.html)



mcrypt is deprecated in PHP 7.x - DuoS - 06-18-2017

Hello friends,

I tried one of my CI based apps that built with CI v3.x latest version in PHP 7.1.5

And then I got this huge list of mcript depricated errors. 

[Image: 5Yy1YQLQQ0mfhnSB14dzvA.png]

I just wanted to know that, are you guys gonna remove this mcript library from CI v3.x and rewrite encription library from scracth?

I saw somewere that mcript library gonna completely remove from PHP 7.2. so if that happen, our apps will not gonna work.

Thankyou guys

DUOS.


RE: mcrypt is deprecated in PHP 7.x - skunkbad - 06-18-2017

If you look at the class constructor of the Encryption library, you'll see that if mcrypt is not available and OpenSSL is, then OpenSSL is used.


RE: mcrypt is deprecated in PHP 7.x - DuoS - 06-18-2017

(06-18-2017, 07:53 AM)skunkbad Wrote: If you look at the class constructor of the Encryption library, you'll see that if mcrypt is not available and OpenSSL is, then OpenSSL is used.

Thats something really nice to here. :Smile

But its better if can avoid those depricated warnings internally in the class.


RE: mcrypt is deprecated in PHP 7.x - skunkbad - 06-18-2017

(06-18-2017, 08:08 AM)DuoS Wrote:
(06-18-2017, 07:53 AM)skunkbad Wrote: If you look at the class constructor of the Encryption library, you'll see that if mcrypt is not available and OpenSSL is, then OpenSSL is used.

Thats something really nice to here. :Smile

But its better if can avoid those depricated warnings internally in the class.

You could always extend the class and remove the mcrypt stuff.

I've still got a rather large site using CI 2.X, and so my problems are bigger than yours!


RE: mcrypt is deprecated in PHP 7.x - DuoS - 06-18-2017

(06-18-2017, 08:11 AM)skunkbad Wrote:
(06-18-2017, 08:08 AM)DuoS Wrote:
(06-18-2017, 07:53 AM)skunkbad Wrote: If you look at the class constructor of the Encryption library, you'll see that if mcrypt is not available and OpenSSL is, then OpenSSL is used.

Thats something really nice to here. :Smile

But its better if can avoid those depricated warnings internally in the class.

You could always extend the class and remove the mcrypt stuff.

I've still got a rather large site using CI 2.X, and so my problems are bigger than yours!


I really dont want to extend core libraries.  Smile


RE: mcrypt is deprecated in PHP 7.x - skunkbad - 06-18-2017

(06-18-2017, 09:43 AM)DuoS Wrote: I really dont want to extend core libraries.  Smile


Extend, not hack ...


RE: mcrypt is deprecated in PHP 7.x - Narf - 06-18-2017

You don't need to hack, modify or extend the library in any way ... https://github.com/bcit-ci/CodeIgniter/issues/5157