public static function ParagonIE_Sodium_Compat::randombytes_random16 in Automatic Updates 8
Same name and namespace in other branches
- 7 vendor/paragonie/sodium_compat/src/Compat.php \ParagonIE_Sodium_Compat::randombytes_random16()
Generate a random 16-bit integer.
Return value
int
Throws
Exception
Error
TypeError
2 calls to ParagonIE_Sodium_Compat::randombytes_random16()
- php72compat.php in vendor/
paragonie/ sodium_compat/ lib/ php72compat.php - sodium_compat.php in vendor/
paragonie/ sodium_compat/ lib/ sodium_compat.php
File
- vendor/
paragonie/ sodium_compat/ src/ Compat.php, line 3446
Class
Code
public static function randombytes_random16() {
if (self::use_fallback('randombytes_random16')) {
return (int) call_user_func('\\Sodium\\randombytes_random16');
}
return random_int(0, 65535);
}