- SEE ALSO
- COPYRIGHT AND LICENCE
Crypt::Random::Source::Weak::openssl - Get random bytes from the OpenSSL command line utility
use Crypt::Random::Source::Strong::openssl; my $source = Crypt::Random::Source::Weak::openssl->new my $bytes = $source->get(1024); # get 1kb of random bytes
This is a weak random byte source because
openssl rand is a PRNG.
This is a subclass of Crypt::Random::Source::Base::Proc.
Due to the retarded nature of the rand command line utility's interface, it must repeatedly be invoked with
default_chunk_size as number of random bytes to generate.
The default number of bytes to generate per
Defaults to 64 kb, which is pretty large and balances well with the startup time of
openssl randfor miniscule chunks.
If you will be needing a lot of random data, increasing this number to something much larger would probably be beneficial.
opensslexecutable to invoke. Defaults to what File::Which found for
openssl(which means it must be in your
יובל קוג'מן (Yuval Kogman) <email@example.com>
Karen Etheridge <firstname.lastname@example.org>
This software is copyright (c) 2008 by Yuval Kogman.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.