Crypt::Random::Source::Weak::rand - Use C to create random bytes


Crypt-Random-Source documentation  | view source Contained in the Crypt-Random-Source distribution.

Index


NAME

Top

Crypt::Random::Source::Weak::rand - Use rand to create random bytes

SYNOPSIS

Top

    use Crypt::Random::Source::Weak::rand;

    my $p = Crypt::Random::Source::Weak::rand->new;

    $p->get(1024);

DESCRIPTION

Top

This is a weak source of random data, that uses Perl's builtin rand function.

METHODS

Top

seed @blah

Sets the random seed to a checksum of the stringified values of @blah.

There is no need to call this method unless you want the random sequence to be identical to a previously run, in which case you should seed with the same value.

get $n

Produces $n random bytes.

AUTHOR

Top

  Yuval Kogman <nothingmuch@woobling.org>

COPYRIGHT AND LICENSE

Top


Crypt-Random-Source documentation  | view source Contained in the Crypt-Random-Source distribution.