1=pod
2
3=head1 NAME
4
5rand - generate pseudo-random bytes
6
7=head1 SYNOPSIS
8
9B<openssl rand>
10[B<-out> I<file>]
11[B<-rand> I<file(s)>]
12[B<-base64>]
13[B<-hex>]
14I<num>
15
16=head1 DESCRIPTION
17
18The B<rand> command outputs I<num> pseudo-random bytes after seeding
19the random number generator once.  As in other B<openssl> command
20line tools, PRNG seeding uses the file I<$HOME/>B<.rnd> or B<.rnd>
21in addition to the files given in the B<-rand> option.  A new
22I<$HOME>/B<.rnd> or B<.rnd> file will be written back if enough
23seeding was obtained from these sources.
24
25=head1 OPTIONS
26
27=over 4
28
29=item B<-out> I<file>
30
31Write to I<file> instead of standard output.
32
33=item B<-rand> I<file(s)>
34
35Use specified file or files or EGD socket (see L<RAND_egd(3)|RAND_egd(3)>)
36for seeding the random number generator.
37Multiple files can be specified separated by a OS-dependent character.
38The separator is B<;> for MS-Windows, B<,> for OpenVMS, and B<:> for
39all others.
40
41=item B<-base64>
42
43Perform base64 encoding on the output.
44
45=item B<-hex>
46
47Show the output as a hex string.
48
49=back
50
51=head1 SEE ALSO
52
53L<RAND_bytes(3)|RAND_bytes(3)>
54
55=cut
56