Crypt::SysRandom - Perl interface to system randomness
Contents
Backends
The current backends are tried in order:
• Crypt::SysRandom::XS
• "RtlGenRandom" using Win32::API
• "/dev/urandom"
Copyright And License
This software is copyright (c) 2025 by Leon Timmermans.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5
programming language system itself.
perl v5.40.1 2025-06-09 Crypt::SysRandom(3pm)
Description
This module uses whatever interface is available to procure cryptographically random data from the
system.
Functions
random_bytes($count)
This will fetch a string of $count random bytes containing cryptographically secure random date.
Name
Crypt::SysRandom - Perl interface to system randomness
Synopsis
use Crypt::SysRandom 'random_bytes';
my $random = random_bytes(16);
Version
version 0.007
