We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 48c68ed commit d661a7dCopy full SHA for d661a7d
src/app/code/community/JetRails/TwoFactor/Helper/Totp.php
@@ -99,7 +99,7 @@ private function secret ( $length = 16 ) {
99
// Traverse $length times, to get random base32 encoding
100
for ( $i = 0; $i < $length; $i++ ) {
101
// Append a random number from base32 alphabet
102
- $secret .= $this->alphabet [ mt_rand ( 0, strlen ( $this->alphabet ) - 1 ) ];
+ $secret .= $this->alphabet [ random_int ( 0, strlen ( $this->alphabet ) - 1 ) ];
103
}
104
// Return the resulting secret
105
return $secret;
0 commit comments