Implement StringUtil::getRandomID() using PasswordUtil::getRandomPassword()
authorTim Düsterhus <duesterhus@woltlab.com>
Wed, 20 May 2020 13:05:54 +0000 (15:05 +0200)
committerTim Düsterhus <duesterhus@woltlab.com>
Wed, 20 May 2020 13:06:46 +0000 (15:06 +0200)
see 2ca6835c56fd478b8a685bcf2be72245a8231c37
Closes #3262

wcfsetup/install/files/lib/util/StringUtil.class.php

index 92a477be7e82732110891b6ee696b1c681d83fd1..e52d9b44a29b95cc649374078b4823885e99ecb5 100644 (file)
@@ -47,7 +47,7 @@ final class StringUtil {
         * @return      string
         */
        public static function getRandomID() {
-               return self::getHash(microtime() . uniqid(mt_rand(), true));
+               return self::getHash(PasswordUtil::getRandomPassword(30));
        }
        
        /**