Deleted Added
full compact
ssh-keygen.0 (207311) ssh-keygen.0 (214979)
1SSH-KEYGEN(1) OpenBSD Reference Manual SSH-KEYGEN(1)
2
3NAME
4 ssh-keygen - authentication key generation, management and conversion
5
6SYNOPSIS
7 ssh-keygen [-q] [-b bits] -t type [-N new_passphrase] [-C comment]
8 [-f output_keyfile]
9 ssh-keygen -p [-P old_passphrase] [-N new_passphrase] [-f keyfile]
1SSH-KEYGEN(1) OpenBSD Reference Manual SSH-KEYGEN(1)
2
3NAME
4 ssh-keygen - authentication key generation, management and conversion
5
6SYNOPSIS
7 ssh-keygen [-q] [-b bits] -t type [-N new_passphrase] [-C comment]
8 [-f output_keyfile]
9 ssh-keygen -p [-P old_passphrase] [-N new_passphrase] [-f keyfile]
10 ssh-keygen -i [-f input_keyfile]
11 ssh-keygen -e [-f input_keyfile]
10 ssh-keygen -i [-m key_format] [-f input_keyfile]
11 ssh-keygen -e [-m key_format] [-f input_keyfile]
12 ssh-keygen -y [-f input_keyfile]
13 ssh-keygen -c [-P passphrase] [-C comment] [-f keyfile]
14 ssh-keygen -l [-f input_keyfile]
15 ssh-keygen -B [-f input_keyfile]
16 ssh-keygen -D pkcs11
17 ssh-keygen -F hostname [-f known_hosts_file] [-l]
18 ssh-keygen -H [-f known_hosts_file]
19 ssh-keygen -R hostname [-f known_hosts_file]
20 ssh-keygen -r hostname [-f input_keyfile] [-g]
21 ssh-keygen -G output_file [-v] [-b bits] [-M memory] [-S start_point]
22 ssh-keygen -T output_file -f input_file [-v] [-a num_trials]
23 [-W generator]
24 ssh-keygen -s ca_key -I certificate_identity [-h] [-n principals]
12 ssh-keygen -y [-f input_keyfile]
13 ssh-keygen -c [-P passphrase] [-C comment] [-f keyfile]
14 ssh-keygen -l [-f input_keyfile]
15 ssh-keygen -B [-f input_keyfile]
16 ssh-keygen -D pkcs11
17 ssh-keygen -F hostname [-f known_hosts_file] [-l]
18 ssh-keygen -H [-f known_hosts_file]
19 ssh-keygen -R hostname [-f known_hosts_file]
20 ssh-keygen -r hostname [-f input_keyfile] [-g]
21 ssh-keygen -G output_file [-v] [-b bits] [-M memory] [-S start_point]
22 ssh-keygen -T output_file -f input_file [-v] [-a num_trials]
23 [-W generator]
24 ssh-keygen -s ca_key -I certificate_identity [-h] [-n principals]
25 [-O constraint] [-V validity_interval] file ...
25 [-O option] [-V validity_interval] [-z serial_number] file ...
26 ssh-keygen -L [-f input_keyfile]
27
28DESCRIPTION
29 ssh-keygen generates, manages and converts authentication keys for
30 ssh(1). ssh-keygen can create RSA keys for use by SSH protocol version 1
31 and RSA or DSA keys for use by SSH protocol version 2. The type of key
32 to be generated is specified with the -t option. If invoked without any
33 arguments, ssh-keygen will generate an RSA key for use in SSH protocol 2

--- 7 unchanged lines hidden (view full) ---

41 ~/.ssh/id_dsa or ~/.ssh/id_rsa. Additionally, the system administrator
42 may use this to generate host keys, as seen in /etc/rc.
43
44 Normally this program generates the key and asks for a file in which to
45 store the private key. The public key is stored in a file with the same
46 name but ``.pub'' appended. The program also asks for a passphrase. The
47 passphrase may be empty to indicate no passphrase (host keys must have an
48 empty passphrase), or it may be a string of arbitrary length. A
26 ssh-keygen -L [-f input_keyfile]
27
28DESCRIPTION
29 ssh-keygen generates, manages and converts authentication keys for
30 ssh(1). ssh-keygen can create RSA keys for use by SSH protocol version 1
31 and RSA or DSA keys for use by SSH protocol version 2. The type of key
32 to be generated is specified with the -t option. If invoked without any
33 arguments, ssh-keygen will generate an RSA key for use in SSH protocol 2

--- 7 unchanged lines hidden (view full) ---

41 ~/.ssh/id_dsa or ~/.ssh/id_rsa. Additionally, the system administrator
42 may use this to generate host keys, as seen in /etc/rc.
43
44 Normally this program generates the key and asks for a file in which to
45 store the private key. The public key is stored in a file with the same
46 name but ``.pub'' appended. The program also asks for a passphrase. The
47 passphrase may be empty to indicate no passphrase (host keys must have an
48 empty passphrase), or it may be a string of arbitrary length. A
49 passphrase is similar to a password, except it can be a phrase with a se-
50 ries of words, punctuation, numbers, whitespace, or any string of charac-
51 ters you want. Good passphrases are 10-30 characters long, are not sim-
52 ple sentences or otherwise easily guessable (English prose has only 1-2
53 bits of entropy per character, and provides very bad passphrases), and
54 contain a mix of upper and lowercase letters, numbers, and non-alphanu-
55 meric characters. The passphrase can be changed later by using the -p
56 option.
49 passphrase is similar to a password, except it can be a phrase with a
50 series of words, punctuation, numbers, whitespace, or any string of
51 characters you want. Good passphrases are 10-30 characters long, are not
52 simple sentences or otherwise easily guessable (English prose has only 1-
53 2 bits of entropy per character, and provides very bad passphrases), and
54 contain a mix of upper and lowercase letters, numbers, and non-
55 alphanumeric characters. The passphrase can be changed later by using
56 the -p option.
57
58 There is no way to recover a lost passphrase. If the passphrase is lost
59 or forgotten, a new key must be generated and copied to the corresponding
60 public key to other machines.
61
62 For RSA1 keys, there is also a comment field in the key file that is only
63 for convenience to the user to help identify the key. The comment can
57
58 There is no way to recover a lost passphrase. If the passphrase is lost
59 or forgotten, a new key must be generated and copied to the corresponding
60 public key to other machines.
61
62 For RSA1 keys, there is also a comment field in the key file that is only
63 for convenience to the user to help identify the key. The comment can
64 tell what the key is for, or whatever is useful. The comment is initial-
65 ized to ``user@host'' when the key is created, but can be changed using
66 the -c option.
64 tell what the key is for, or whatever is useful. The comment is
65 initialized to ``user@host'' when the key is created, but can be changed
66 using the -c option.
67
68 After a key is generated, instructions below detail where the keys should
69 be placed to be activated.
70
71 The options are as follows:
72
73 -a trials
74 Specifies the number of primality tests to perform when screening
75 DH-GEX candidates using the -T command.
76
77 -B Show the bubblebabble digest of specified private or public key
78 file.
79
80 -b bits
81 Specifies the number of bits in the key to create. For RSA keys,
67
68 After a key is generated, instructions below detail where the keys should
69 be placed to be activated.
70
71 The options are as follows:
72
73 -a trials
74 Specifies the number of primality tests to perform when screening
75 DH-GEX candidates using the -T command.
76
77 -B Show the bubblebabble digest of specified private or public key
78 file.
79
80 -b bits
81 Specifies the number of bits in the key to create. For RSA keys,
82 the minimum size is 768 bits and the default is 2048 bits. Gen-
83 erally, 2048 bits is considered sufficient. DSA keys must be ex-
84 actly 1024 bits as specified by FIPS 186-2.
82 the minimum size is 768 bits and the default is 2048 bits.
83 Generally, 2048 bits is considered sufficient. DSA keys must be
84 exactly 1024 bits as specified by FIPS 186-2.
85
86 -C comment
87 Provides a new comment.
88
89 -c Requests changing the comment in the private and public key
85
86 -C comment
87 Provides a new comment.
88
89 -c Requests changing the comment in the private and public key
90 files. This operation is only supported for RSA1 keys. The pro-
91 gram will prompt for the file containing the private keys, for
90 files. This operation is only supported for RSA1 keys. The
91 program will prompt for the file containing the private keys, for
92 the passphrase if the key has one, and for the new comment.
93
94 -D pkcs11
92 the passphrase if the key has one, and for the new comment.
93
94 -D pkcs11
95 Download the RSA public keys provided by the PKCS#11 shared li-
96 brary pkcs11.
95 Download the RSA public keys provided by the PKCS#11 shared
96 library pkcs11. When used in combination with -s, this option
97 indicates that a CA key resides in a PKCS#11 token (see the
98 CERTIFICATES section for details).
97
98 -e This option will read a private or public OpenSSH key file and
99
100 -e This option will read a private or public OpenSSH key file and
99 print the key in RFC 4716 SSH Public Key File Format to stdout.
100 This option allows exporting keys for use by several commercial
101 SSH implementations.
101 print to stdout the key in one of the formats specified by the -m
102 option. The default export format is ``RFC4716''. This option
103 allows exporting OpenSSH keys for use by other programs,
104 including several commercial SSH implementations.
102
103 -F hostname
104 Search for the specified hostname in a known_hosts file, listing
105 any occurrences found. This option is useful to find hashed host
106 names or addresses and may also be used in conjunction with the
107 -H option to print found keys in a hashed format.
108
109 -f filename
110 Specifies the filename of the key file.
111
112 -G output_file
113 Generate candidate primes for DH-GEX. These primes must be
114 screened for safety (using the -T option) before use.
115
116 -g Use generic DNS format when printing fingerprint resource records
117 using the -r command.
118
105
106 -F hostname
107 Search for the specified hostname in a known_hosts file, listing
108 any occurrences found. This option is useful to find hashed host
109 names or addresses and may also be used in conjunction with the
110 -H option to print found keys in a hashed format.
111
112 -f filename
113 Specifies the filename of the key file.
114
115 -G output_file
116 Generate candidate primes for DH-GEX. These primes must be
117 screened for safety (using the -T option) before use.
118
119 -g Use generic DNS format when printing fingerprint resource records
120 using the -r command.
121
119 -H Hash a known_hosts file. This replaces all hostnames and ad-
120 dresses with hashed representations within the specified file;
122 -H Hash a known_hosts file. This replaces all hostnames and
123 addresses with hashed representations within the specified file;
121 the original content is moved to a file with a .old suffix.
122 These hashes may be used normally by ssh and sshd, but they do
123 not reveal identifying information should the file's contents be
124 disclosed. This option will not modify existing hashed hostnames
125 and is therefore safe to use on files that mix hashed and non-
126 hashed names.
127
128 -h When signing a key, create a host certificate instead of a user
129 certificate. Please see the CERTIFICATES section for details.
130
131 -I certificate_identity
132 Specify the key identity when signing a public key. Please see
133 the CERTIFICATES section for details.
134
135 -i This option will read an unencrypted private (or public) key file
124 the original content is moved to a file with a .old suffix.
125 These hashes may be used normally by ssh and sshd, but they do
126 not reveal identifying information should the file's contents be
127 disclosed. This option will not modify existing hashed hostnames
128 and is therefore safe to use on files that mix hashed and non-
129 hashed names.
130
131 -h When signing a key, create a host certificate instead of a user
132 certificate. Please see the CERTIFICATES section for details.
133
134 -I certificate_identity
135 Specify the key identity when signing a public key. Please see
136 the CERTIFICATES section for details.
137
138 -i This option will read an unencrypted private (or public) key file
136 in SSH2-compatible format and print an OpenSSH compatible private
137 (or public) key to stdout. ssh-keygen also reads the RFC 4716
138 SSH Public Key File Format. This option allows importing keys
139 from several commercial SSH implementations.
139 in the format specified by the -m option and print an OpenSSH
140 compatible private (or public) key to stdout. This option allows
141 importing keys from other software, including several commercial
142 SSH implementations. The default import format is ``RFC4716''.
140
141 -L Prints the contents of a certificate.
142
143 -l Show fingerprint of specified public key file. Private RSA1 keys
144 are also supported. For RSA and DSA keys ssh-keygen tries to
145 find the matching public key file and prints its fingerprint. If
143
144 -L Prints the contents of a certificate.
145
146 -l Show fingerprint of specified public key file. Private RSA1 keys
147 are also supported. For RSA and DSA keys ssh-keygen tries to
148 find the matching public key file and prints its fingerprint. If
146 combined with -v, an ASCII art representation of the key is sup-
147 plied with the fingerprint.
149 combined with -v, an ASCII art representation of the key is
150 supplied with the fingerprint.
148
149 -M memory
151
152 -M memory
150 Specify the amount of memory to use (in megabytes) when generat-
151 ing candidate moduli for DH-GEX.
153 Specify the amount of memory to use (in megabytes) when
154 generating candidate moduli for DH-GEX.
152
155
156 -m key_format
157 Specify a key format for the -i (import) or -e (export)
158 conversion options. The supported key formats are: ``RFC4716''
159 (RFC 4716/SSH2 public or private key), ``PKCS8'' (PEM PKCS8
160 public key) or ``PEM'' (PEM public key). The default conversion
161 format is ``RFC4716''.
162
153 -N new_passphrase
154 Provides the new passphrase.
155
156 -n principals
163 -N new_passphrase
164 Provides the new passphrase.
165
166 -n principals
157 Specify one or more principals (user or host names) to be includ-
158 ed in a certificate when signing a key. Multiple principals may
159 be specified, separated by commas. Please see the CERTIFICATES
160 section for details.
167 Specify one or more principals (user or host names) to be
168 included in a certificate when signing a key. Multiple
169 principals may be specified, separated by commas. Please see the
170 CERTIFICATES section for details.
161
171
162 -O constraint
163 Specify a certificate constraint when signing a key. This option
164 may be specified multiple times. Please see the CERTIFICATES
165 section for details. The constraints that are valid for user
166 certificates are:
172 -O option
173 Specify a certificate option when signing a key. This option may
174 be specified multiple times. Please see the CERTIFICATES section
175 for details. The options that are valid for user certificates
176 are:
167
177
168 clear Clear all enabled permissions. This is useful for clear-
169 ing the default set of permissions so permissions may be
170 added individually.
178 clear Clear all enabled permissions. This is useful for
179 clearing the default set of permissions so permissions
180 may be added individually.
171
172 force-command=command
173 Forces the execution of command instead of any shell or
174 command specified by the user when the certificate is
175 used for authentication.
176
177 no-agent-forwarding
178 Disable ssh-agent(1) forwarding (permitted by default).

--- 22 unchanged lines hidden (view full) ---

201 permit-user-rc
202 Allows execution of ~/.ssh/rc by sshd(8).
203
204 permit-x11-forwarding
205 Allows X11 forwarding.
206
207 source-address=address_list
208 Restrict the source addresses from which the certificate
181
182 force-command=command
183 Forces the execution of command instead of any shell or
184 command specified by the user when the certificate is
185 used for authentication.
186
187 no-agent-forwarding
188 Disable ssh-agent(1) forwarding (permitted by default).

--- 22 unchanged lines hidden (view full) ---

211 permit-user-rc
212 Allows execution of ~/.ssh/rc by sshd(8).
213
214 permit-x11-forwarding
215 Allows X11 forwarding.
216
217 source-address=address_list
218 Restrict the source addresses from which the certificate
209 is considered valid. The address_list is a comma-sepa-
210 rated list of one or more address/netmask pairs in CIDR
211 format.
219 is considered valid. The address_list is a comma-
220 separated list of one or more address/netmask pairs in
221 CIDR format.
212
222
213 At present, no constraints are valid for host keys.
223 At present, no options are valid for host keys.
214
215 -P passphrase
216 Provides the (old) passphrase.
217
218 -p Requests changing the passphrase of a private key file instead of
219 creating a new private key. The program will prompt for the file
220 containing the private key, for the old passphrase, and twice for
221 the new passphrase.

--- 18 unchanged lines hidden (view full) ---

240 see the CERTIFICATES section for details.
241
242 -T output_file
243 Test DH group exchange candidate primes (generated using the -G
244 option) for safety.
245
246 -t type
247 Specifies the type of key to create. The possible values are
224
225 -P passphrase
226 Provides the (old) passphrase.
227
228 -p Requests changing the passphrase of a private key file instead of
229 creating a new private key. The program will prompt for the file
230 containing the private key, for the old passphrase, and twice for
231 the new passphrase.

--- 18 unchanged lines hidden (view full) ---

250 see the CERTIFICATES section for details.
251
252 -T output_file
253 Test DH group exchange candidate primes (generated using the -G
254 option) for safety.
255
256 -t type
257 Specifies the type of key to create. The possible values are
248 ``rsa1'' for protocol version 1 and ``rsa'' or ``dsa'' for proto-
249 col version 2.
258 ``rsa1'' for protocol version 1 and ``rsa'' or ``dsa'' for
259 protocol version 2.
250
251 -V validity_interval
260
261 -V validity_interval
252 Specify a validity interval when signing a certificate. A valid-
253 ity interval may consist of a single time, indicating that the
254 certificate is valid beginning now and expiring at that time, or
255 may consist of two times separated by a colon to indicate an ex-
256 plicit time interval. The start time may be specified as a date
257 in YYYYMMDD format, a time in YYYYMMDDHHMMSS format or a relative
258 time (to the current time) consisting of a minus sign followed by
259 a relative time in the format described in the TIME FORMATS sec-
260 tion of sshd_config(5). The end time may be specified as a
261 YYYYMMDD date, a YYYYMMDDHHMMSS time or a relative time starting
262 with a plus character.
262 Specify a validity interval when signing a certificate. A
263 validity interval may consist of a single time, indicating that
264 the certificate is valid beginning now and expiring at that time,
265 or may consist of two times separated by a colon to indicate an
266 explicit time interval. The start time may be specified as a
267 date in YYYYMMDD format, a time in YYYYMMDDHHMMSS format or a
268 relative time (to the current time) consisting of a minus sign
269 followed by a relative time in the format described in the TIME
270 FORMATS section of sshd_config(5). The end time may be specified
271 as a YYYYMMDD date, a YYYYMMDDHHMMSS time or a relative time
272 starting with a plus character.
263
264 For example: ``+52w1d'' (valid from now to 52 weeks and one day
265 from now), ``-4w:+4w'' (valid from four weeks ago to four weeks
266 from now), ``20100101123000:20110101123000'' (valid from 12:30
267 PM, January 1st, 2010 to 12:30 PM, January 1st, 2011),
268 ``-1d:20110101'' (valid from yesterday to midnight, January 1st,
269 2011).
270
271 -v Verbose mode. Causes ssh-keygen to print debugging messages
273
274 For example: ``+52w1d'' (valid from now to 52 weeks and one day
275 from now), ``-4w:+4w'' (valid from four weeks ago to four weeks
276 from now), ``20100101123000:20110101123000'' (valid from 12:30
277 PM, January 1st, 2010 to 12:30 PM, January 1st, 2011),
278 ``-1d:20110101'' (valid from yesterday to midnight, January 1st,
279 2011).
280
281 -v Verbose mode. Causes ssh-keygen to print debugging messages
272 about its progress. This is helpful for debugging moduli genera-
273 tion. Multiple -v options increase the verbosity. The maximum
274 is 3.
282 about its progress. This is helpful for debugging moduli
283 generation. Multiple -v options increase the verbosity. The
284 maximum is 3.
275
276 -W generator
277 Specify desired generator when testing candidate moduli for DH-
278 GEX.
279
280 -y This option will read a private OpenSSH format file and print an
281 OpenSSH public key to stdout.
282
285
286 -W generator
287 Specify desired generator when testing candidate moduli for DH-
288 GEX.
289
290 -y This option will read a private OpenSSH format file and print an
291 OpenSSH public key to stdout.
292
293 -z serial_number
294 Specifies a serial number to be embedded in the certificate to
295 distinguish this certificate from others from the same CA. The
296 default serial number is zero.
297
283MODULI GENERATION
284 ssh-keygen may be used to generate groups for the Diffie-Hellman Group
298MODULI GENERATION
299 ssh-keygen may be used to generate groups for the Diffie-Hellman Group
285 Exchange (DH-GEX) protocol. Generating these groups is a two-step pro-
286 cess: first, candidate primes are generated using a fast, but memory in-
287 tensive process. These candidate primes are then tested for suitability
288 (a CPU-intensive process).
300 Exchange (DH-GEX) protocol. Generating these groups is a two-step
301 process: first, candidate primes are generated using a fast, but memory
302 intensive process. These candidate primes are then tested for
303 suitability (a CPU-intensive process).
289
290 Generation of primes is performed using the -G option. The desired
291 length of the primes may be specified by the -b option. For example:
292
293 # ssh-keygen -G moduli-2048.candidates -b 2048
294
295 By default, the search for primes begins at a random point in the desired
304
305 Generation of primes is performed using the -G option. The desired
306 length of the primes may be specified by the -b option. For example:
307
308 # ssh-keygen -G moduli-2048.candidates -b 2048
309
310 By default, the search for primes begins at a random point in the desired
296 length range. This may be overridden using the -S option, which speci-
297 fies a different start point (in hex).
311 length range. This may be overridden using the -S option, which
312 specifies a different start point (in hex).
298
299 Once a set of candidates have been generated, they must be tested for
300 suitability. This may be performed using the -T option. In this mode
301 ssh-keygen will read candidates from standard input (or a file specified
302 using the -f option). For example:
303
304 # ssh-keygen -T moduli-2048 -f moduli-2048.candidates
305

--- 6 unchanged lines hidden (view full) ---

312 Screened DH groups may be installed in /etc/moduli. It is important that
313 this file contains moduli of a range of bit lengths and that both ends of
314 a connection share common moduli.
315
316CERTIFICATES
317 ssh-keygen supports signing of keys to produce certificates that may be
318 used for user or host authentication. Certificates consist of a public
319 key, some identity information, zero or more principal (user or host)
313
314 Once a set of candidates have been generated, they must be tested for
315 suitability. This may be performed using the -T option. In this mode
316 ssh-keygen will read candidates from standard input (or a file specified
317 using the -f option). For example:
318
319 # ssh-keygen -T moduli-2048 -f moduli-2048.candidates
320

--- 6 unchanged lines hidden (view full) ---

327 Screened DH groups may be installed in /etc/moduli. It is important that
328 this file contains moduli of a range of bit lengths and that both ends of
329 a connection share common moduli.
330
331CERTIFICATES
332 ssh-keygen supports signing of keys to produce certificates that may be
333 used for user or host authentication. Certificates consist of a public
334 key, some identity information, zero or more principal (user or host)
320 names and an optional set of constraints that are signed by a Certifica-
321 tion Authority (CA) key. Clients or servers may then trust only the CA
322 key and verify its signature on a certificate rather than trusting many
323 user/host keys. Note that OpenSSH certificates are a different, and much
324 simpler, format to the X.509 certificates used in ssl(8).
335 names and a set of options that are signed by a Certification Authority
336 (CA) key. Clients or servers may then trust only the CA key and verify
337 its signature on a certificate rather than trusting many user/host keys.
338 Note that OpenSSH certificates are a different, and much simpler, format
339 to the X.509 certificates used in ssl(8).
325
340
326 ssh-keygen supports two types of certificates: user and host. User cer-
327 tificates authenticate users to servers, whereas host certificates au-
328 thenticate server hosts to users. To generate a user certificate:
341 ssh-keygen supports two types of certificates: user and host. User
342 certificates authenticate users to servers, whereas host certificates
343 authenticate server hosts to users. To generate a user certificate:
329
330 $ ssh-keygen -s /path/to/ca_key -I key_id /path/to/user_key.pub
331
332 The resultant certificate will be placed in /path/to/user_key-cert.pub.
333 A host certificate requires the -h option:
334
335 $ ssh-keygen -s /path/to/ca_key -I key_id -h /path/to/host_key.pub
336
344
345 $ ssh-keygen -s /path/to/ca_key -I key_id /path/to/user_key.pub
346
347 The resultant certificate will be placed in /path/to/user_key-cert.pub.
348 A host certificate requires the -h option:
349
350 $ ssh-keygen -s /path/to/ca_key -I key_id -h /path/to/host_key.pub
351
337 The host certificate will be output to /path/to/host_key-cert.pub. In
338 both cases, key_id is a "key identifier" that is logged by the server
352 The host certificate will be output to /path/to/host_key-cert.pub.
353
354 It is possible to sign using a CA key stored in a PKCS#11 token by
355 providing the token library using -D and identifying the CA key by
356 providing its public half as an argument to -s:
357
358 $ ssh-keygen -s ca_key.pub -D libpkcs11.so -I key_id host_key.pub
359
360 In all cases, key_id is a "key identifier" that is logged by the server
339 when the certificate is used for authentication.
340
361 when the certificate is used for authentication.
362
341 Certificates may be limited to be valid for a set of principal (us-
342 er/host) names. By default, generated certificates are valid for all
343 users or hosts. To generate a certificate for a specified set of princi-
344 pals:
363 Certificates may be limited to be valid for a set of principal
364 (user/host) names. By default, generated certificates are valid for all
365 users or hosts. To generate a certificate for a specified set of
366 principals:
345
346 $ ssh-keygen -s ca_key -I key_id -n user1,user2 user_key.pub
347 $ ssh-keygen -s ca_key -I key_id -h -n host.domain user_key.pub
348
349 Additional limitations on the validity and use of user certificates may
367
368 $ ssh-keygen -s ca_key -I key_id -n user1,user2 user_key.pub
369 $ ssh-keygen -s ca_key -I key_id -h -n host.domain user_key.pub
370
371 Additional limitations on the validity and use of user certificates may
350 be specified through certificate constraints. A constrained certificate
351 may disable features of the SSH session, may be valid only when presented
352 from particular source addresses or may force the use of a specific com-
353 mand. For a list of valid certificate constraints, see the documentation
372 be specified through certificate options. A certificate option may
373 disable features of the SSH session, may be valid only when presented
374 from particular source addresses or may force the use of a specific
375 command. For a list of valid certificate options, see the documentation
354 for the -O option above.
355
356 Finally, certificates may be defined with a validity lifetime. The -V
376 for the -O option above.
377
378 Finally, certificates may be defined with a validity lifetime. The -V
357 option allows specification of certificate start and end times. A cer-
358 tificate that is presented at a time outside this range will not be con-
359 sidered valid. By default, certificates have a maximum validity inter-
360 val.
379 option allows specification of certificate start and end times. A
380 certificate that is presented at a time outside this range will not be
381 considered valid. By default, certificates have a maximum validity
382 interval.
361
383
362 For certificates to be used for user or host authentication, the CA pub-
363 lic key must be trusted by sshd(8) or ssh(1). Please refer to those man-
364 ual pages for details.
384 For certificates to be used for user or host authentication, the CA
385 public key must be trusted by sshd(8) or ssh(1). Please refer to those
386 manual pages for details.
365
366FILES
367 ~/.ssh/identity
368 Contains the protocol version 1 RSA authentication identity of
387
388FILES
389 ~/.ssh/identity
390 Contains the protocol version 1 RSA authentication identity of
369 the user. This file should not be readable by anyone but the us-
370 er. It is possible to specify a passphrase when generating the
391 the user. This file should not be readable by anyone but the
392 user. It is possible to specify a passphrase when generating the
371 key; that passphrase will be used to encrypt the private part of
393 key; that passphrase will be used to encrypt the private part of
372 this file using 128-bit AES. This file is not automatically ac-
373 cessed by ssh-keygen but it is offered as the default file for
394 this file using 128-bit AES. This file is not automatically
395 accessed by ssh-keygen but it is offered as the default file for
374 the private key. ssh(1) will read this file when a login attempt
375 is made.
376
377 ~/.ssh/identity.pub
396 the private key. ssh(1) will read this file when a login attempt
397 is made.
398
399 ~/.ssh/identity.pub
378 Contains the protocol version 1 RSA public key for authentica-
379 tion. The contents of this file should be added to
400 Contains the protocol version 1 RSA public key for
401 authentication. The contents of this file should be added to
380 ~/.ssh/authorized_keys on all machines where the user wishes to
381 log in using RSA authentication. There is no need to keep the
382 contents of this file secret.
383
384 ~/.ssh/id_dsa
385 Contains the protocol version 2 DSA authentication identity of
402 ~/.ssh/authorized_keys on all machines where the user wishes to
403 log in using RSA authentication. There is no need to keep the
404 contents of this file secret.
405
406 ~/.ssh/id_dsa
407 Contains the protocol version 2 DSA authentication identity of
386 the user. This file should not be readable by anyone but the us-
387 er. It is possible to specify a passphrase when generating the
408 the user. This file should not be readable by anyone but the
409 user. It is possible to specify a passphrase when generating the
388 key; that passphrase will be used to encrypt the private part of
410 key; that passphrase will be used to encrypt the private part of
389 this file using 128-bit AES. This file is not automatically ac-
390 cessed by ssh-keygen but it is offered as the default file for
411 this file using 128-bit AES. This file is not automatically
412 accessed by ssh-keygen but it is offered as the default file for
391 the private key. ssh(1) will read this file when a login attempt
392 is made.
393
394 ~/.ssh/id_dsa.pub
413 the private key. ssh(1) will read this file when a login attempt
414 is made.
415
416 ~/.ssh/id_dsa.pub
395 Contains the protocol version 2 DSA public key for authentica-
396 tion. The contents of this file should be added to
417 Contains the protocol version 2 DSA public key for
418 authentication. The contents of this file should be added to
397 ~/.ssh/authorized_keys on all machines where the user wishes to
398 log in using public key authentication. There is no need to keep
399 the contents of this file secret.
400
401 ~/.ssh/id_rsa
402 Contains the protocol version 2 RSA authentication identity of
419 ~/.ssh/authorized_keys on all machines where the user wishes to
420 log in using public key authentication. There is no need to keep
421 the contents of this file secret.
422
423 ~/.ssh/id_rsa
424 Contains the protocol version 2 RSA authentication identity of
403 the user. This file should not be readable by anyone but the us-
404 er. It is possible to specify a passphrase when generating the
425 the user. This file should not be readable by anyone but the
426 user. It is possible to specify a passphrase when generating the
405 key; that passphrase will be used to encrypt the private part of
427 key; that passphrase will be used to encrypt the private part of
406 this file using 128-bit AES. This file is not automatically ac-
407 cessed by ssh-keygen but it is offered as the default file for
428 this file using 128-bit AES. This file is not automatically
429 accessed by ssh-keygen but it is offered as the default file for
408 the private key. ssh(1) will read this file when a login attempt
409 is made.
410
411 ~/.ssh/id_rsa.pub
430 the private key. ssh(1) will read this file when a login attempt
431 is made.
432
433 ~/.ssh/id_rsa.pub
412 Contains the protocol version 2 RSA public key for authentica-
413 tion. The contents of this file should be added to
434 Contains the protocol version 2 RSA public key for
435 authentication. The contents of this file should be added to
414 ~/.ssh/authorized_keys on all machines where the user wishes to
415 log in using public key authentication. There is no need to keep
416 the contents of this file secret.
417
418 /etc/moduli
419 Contains Diffie-Hellman groups used for DH-GEX. The file format
420 is described in moduli(5).
421

--- 4 unchanged lines hidden (view full) ---

426
427AUTHORS
428 OpenSSH is a derivative of the original and free ssh 1.2.12 release by
429 Tatu Ylonen. Aaron Campbell, Bob Beck, Markus Friedl, Niels Provos, Theo
430 de Raadt and Dug Song removed many bugs, re-added newer features and
431 created OpenSSH. Markus Friedl contributed the support for SSH protocol
432 versions 1.5 and 2.0.
433
436 ~/.ssh/authorized_keys on all machines where the user wishes to
437 log in using public key authentication. There is no need to keep
438 the contents of this file secret.
439
440 /etc/moduli
441 Contains Diffie-Hellman groups used for DH-GEX. The file format
442 is described in moduli(5).
443

--- 4 unchanged lines hidden (view full) ---

448
449AUTHORS
450 OpenSSH is a derivative of the original and free ssh 1.2.12 release by
451 Tatu Ylonen. Aaron Campbell, Bob Beck, Markus Friedl, Niels Provos, Theo
452 de Raadt and Dug Song removed many bugs, re-added newer features and
453 created OpenSSH. Markus Friedl contributed the support for SSH protocol
454 versions 1.5 and 2.0.
455
434OpenBSD 4.7 March 13, 2010 7
456OpenBSD 4.8 August 4, 2010 OpenBSD 4.8