Hi - this may not be fully related to sage/ trellis, and may be more related to Gravity forms - but here goes.
Running sage 9.0.0-beta.4 (currently)
On Trellis dev environment
I’m running into a deprication notice
Deprecated: Function mcrypt_get_iv_size() is deprecated
and
Deprecated: Function mcrypt_decrypt()
(coming from Gravity forms):
$use_mcrypt = apply_filters( 'gform_use_mcrypt', function_exists( 'mcrypt_decrypt' ) );
if ( $use_mcrypt ) {
$mcrypt_cipher_name = $mcrypt_cipher_name === false ? MCRYPT_RIJNDAEL_256 : $mcrypt_cipher_name;
$iv_size = mcrypt_get_iv_size( $mcrypt_cipher_name, MCRYPT_MODE_ECB );
$key = ! is_null( $key ) ? $key : substr( md5( wp_salt( 'nonce' ) ), 0, $iv_size );
$decrypted_value = trim( mcrypt_decrypt( $mcrypt_cipher_name, $key, base64_decode( $text ), MCRYPT_MODE_ECB, mcrypt_create_iv( $iv_size, MCRYPT_RAND ) ) );
} else {
$decrypted_value = EncryptDB::decrypt( $text, wp_salt( 'nonce' ) );
}
return $decrypted_value;
}
As I understand it MCRYPT is depricated since php 7.1
I’ve googled around and have come across Laravel posts that say the cipher should be updated to AES-256-CBC
but then run php artisan key:generate
- I’m not 100% sure where. (tried to ssh to vagrant but I get Could not open input file: artisan)
I’ve also set $use_mcrypt to false, but that does not generate a decrypted value
Could anyone give me a pointer? Thanks in advance!