Skip to content

Commit d072357

Browse files
MC-13806: Replace rand with random_int
1 parent d12cfe8 commit d072357

File tree

1 file changed

+1
-1
lines changed
  • lib/internal/Magento/Framework/Encryption

1 file changed

+1
-1
lines changed

lib/internal/Magento/Framework/Encryption/Crypt.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ public function __construct(
6666
$allowedCharacters = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789';
6767
$initVector = '';
6868
for ($i = 0; $i < $initVectorSize; $i++) {
69-
$initVector .= $allowedCharacters[rand(0, strlen($allowedCharacters) - 1)];
69+
$initVector .= $allowedCharacters[random_int(0, strlen($allowedCharacters) - 1)];
7070
}
7171
// @codingStandardsIgnoreStart
7272
@mcrypt_generic_deinit($handle);

0 commit comments

Comments
 (0)