diff --git a/lib/Cake/Utility/Security.php b/lib/Cake/Utility/Security.php index e6ac1e849..739874c09 100644 --- a/lib/Cake/Utility/Security.php +++ b/lib/Cake/Utility/Security.php @@ -192,7 +192,7 @@ class Security { return openssl_random_pseudo_bytes($length); } if (function_exists('mcrypt_create_iv')) { - return mcrypt_create_iv($length); + return mcrypt_create_iv($length, MCRYPT_DEV_URANDOM); } trigger_error( 'You do not have a safe source of random data available. ' .