Additional name for all commands
[openssl.git] / doc / man1 / genrsa.pod
1 =pod
2
3 =head1 NAME
4
5 openssl-genrsa,
6 genrsa - generate an RSA private key
7
8 =head1 SYNOPSIS
9
10 B<openssl> B<genrsa>
11 [B<-help>]
12 [B<-out filename>]
13 [B<-passout arg>]
14 [B<-aes128>]
15 [B<-aes192>]
16 [B<-aes256>]
17 [B<-aria128>]
18 [B<-aria192>]
19 [B<-aria256>]
20 [B<-camellia128>]
21 [B<-camellia192>]
22 [B<-camellia256>]
23 [B<-des>]
24 [B<-des3>]
25 [B<-idea>]
26 [B<-f4>]
27 [B<-3>]
28 [B<-rand file...>]
29 [B<-writerand file>]
30 [B<-engine id>]
31 [B<numbits>]
32
33 =head1 DESCRIPTION
34
35 The B<genrsa> command generates an RSA private key.
36
37 =head1 OPTIONS
38
39 =over 4
40
41 =item B<-help>
42
43 Print out a usage message.
44
45 =item B<-out filename>
46
47 Output the key to the specified file. If this argument is not specified then
48 standard output is used.
49
50 =item B<-passout arg>
51
52 The output file password source. For more information about the format
53 of B<arg> see the B<PASS PHRASE ARGUMENTS> section in L<openssl(1)>.
54
55 =item B<-aes128|-aes192|-aes256|-aria128|-aria192|-aria256|-camellia128|-camellia192|-camellia256|-des|-des3|-idea>
56
57 These options encrypt the private key with specified
58 cipher before outputting it. If none of these options is
59 specified no encryption is used. If encryption is used a pass phrase is prompted
60 for if it is not supplied via the B<-passout> argument.
61
62 =item B<-F4|-3>
63
64 The public exponent to use, either 65537 or 3. The default is 65537.
65
66 =item B<-rand file...>
67
68 A file or files containing random data used to seed the random number
69 generator.
70 Multiple files can be specified separated by an OS-dependent character.
71 The separator is B<;> for MS-Windows, B<,> for OpenVMS, and B<:> for
72 all others.
73
74 =item [B<-writerand file>]
75
76 Writes random data to the specified I<file> upon exit.
77 This can be used with a subsequent B<-rand> flag.
78
79 =item B<-engine id>
80
81 Specifying an engine (by its unique B<id> string) will cause B<genrsa>
82 to attempt to obtain a functional reference to the specified engine,
83 thus initialising it if needed. The engine will then be set as the default
84 for all available algorithms.
85
86 =item B<numbits>
87
88 The size of the private key to generate in bits. This must be the last option
89 specified. The default is 2048.
90
91 =back
92
93 =head1 NOTES
94
95 RSA private key generation essentially involves the generation of two prime
96 numbers. When generating a private key various symbols will be output to
97 indicate the progress of the generation. A B<.> represents each number which
98 has passed an initial sieve test, B<+> means a number has passed a single
99 round of the Miller-Rabin primality test. A newline means that the number has
100 passed all the prime tests (the actual number depends on the key size).
101
102 Because key generation is a random process the time taken to generate a key
103 may vary somewhat.
104
105 =head1 BUGS
106
107 A quirk of the prime generation algorithm is that it cannot generate small
108 primes. Therefore the number of bits should not be less that 64. For typical
109 private keys this will not matter because for security reasons they will
110 be much larger (typically 1024 bits).
111
112 =head1 SEE ALSO
113
114 L<gendsa(1)>
115
116 =head1 COPYRIGHT
117
118 Copyright 2000-2017 The OpenSSL Project Authors. All Rights Reserved.
119
120 Licensed under the OpenSSL license (the "License").  You may not use
121 this file except in compliance with the License.  You can obtain a copy
122 in the file LICENSE in the source distribution or at
123 L<https://www.openssl.org/source/license.html>.
124
125 =cut