We use a booking plugin in our Wordpress site which uses Sage Pay libraries for the payment processing. Recently we were advised to upgrade to PHP version 7.1, however, when running a compatibility check, an mcrypt error was revealed:
> The following plugins/themes are not compatible with PHP 7.1. Booking > Calendar See Errors > --------------------------------------------------------------------------------- FILE: /home/ . . . > /public_html/wp-content/plugins/booking.bl.7.1/inc/gateways/sage/wpbc-gw-sage.php > --------------------------------------------------------------------------------- FOUND 0 ERRORS AND 4 WARNINGS AFFECTING 2 LINES > --------------------------------------------------------------------------------- 1205 | WARNING | Function mcrypt_encrypt() is deprecated since PHP > 7.1; use OpenSSL instead 1205 | WARNING | Extension 'mcrypt' is deprecated since PHP 7.1 - use openssl (preferred) or pecl/mcrypt once > available instead. 1237 | WARNING | Function mcrypt_decrypt() is > deprecated since PHP 7.1; use OpenSSL instead 1237 | WARNING | > Extension 'mcrypt' is deprecated since PHP 7.1 - use openssl > (preferred) or pecl/mcrypt once available instead. > ---------------------------------------------------------------------------------
As you can see there is a deprecated function in the current version of the plugin. After contacting the plugin coders about the issue, I was told that the offending code is part of the "Sage Pay" libraries and that they, the plugin coders, must wait for the upstream coders, i.e. Sage Pay, to fix their libraries before making modifications on their end.
I realize that the deprecated function has been signaled elsewhere on this forum, both here and here with the main feedback saying that mcrypt will be removed in PHP 7.2 and that users of this code should migrate to openssl_encrypt. In fact, the warning does not prevent users from migrating to PHP 7.1 since if I understand correctly, the deprecated function hasn't been removed yet and therefore is still functional.
So why am I posting this post. Well since none of the previous threads notified this as a potential problem for Sage Pay users and their downstream plugins, I believed that a notification to Sage Pay support through this forum should be made.