summaryrefslogtreecommitdiff
path: root/sshd.8
diff options
context:
space:
mode:
authornaddy@openbsd.org <naddy@openbsd.org>2016-08-15 12:32:04 +0000
committerDamien Miller <djm@mindrot.org>2016-08-23 13:28:30 +1000
commitffe6549c2f7a999cc5264b873a60322e91862581 (patch)
tree4a20d7e5c88fb528ad914fbabe76e6890069cc61 /sshd.8
parentc38ea634893a1975dbbec798fb968c9488013f4a (diff)
upstream commit
Catch up with the SSH1 code removal and delete all mention of protocol 1 particularities, key files and formats, command line options, and configuration keywords from the server documentation and examples. ok jmc@ Upstream-ID: 850328854675b4b6a0d4a90f0b4a9dd9ca4e905f
Diffstat (limited to 'sshd.8')
-rw-r--r--sshd.8108
1 files changed, 23 insertions, 85 deletions
diff --git a/sshd.8 b/sshd.8
index 6c521f23e..148a8b923 100644
--- a/sshd.8
+++ b/sshd.8
@@ -33,8 +33,8 @@
33.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 33.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
34.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 34.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35.\" 35.\"
36.\" $OpenBSD: sshd.8,v 1.284 2016/02/17 07:38:19 jmc Exp $ 36.\" $OpenBSD: sshd.8,v 1.285 2016/08/15 12:32:04 naddy Exp $
37.Dd $Mdocdate: February 17 2016 $ 37.Dd $Mdocdate: August 15 2016 $
38.Dt SSHD 8 38.Dt SSHD 8
39.Os 39.Os
40.Sh NAME 40.Sh NAME
@@ -44,14 +44,12 @@
44.Nm sshd 44.Nm sshd
45.Bk -words 45.Bk -words
46.Op Fl 46DdeiqTt 46.Op Fl 46DdeiqTt
47.Op Fl b Ar bits
48.Op Fl C Ar connection_spec 47.Op Fl C Ar connection_spec
49.Op Fl c Ar host_certificate_file 48.Op Fl c Ar host_certificate_file
50.Op Fl E Ar log_file 49.Op Fl E Ar log_file
51.Op Fl f Ar config_file 50.Op Fl f Ar config_file
52.Op Fl g Ar login_grace_time 51.Op Fl g Ar login_grace_time
53.Op Fl h Ar host_key_file 52.Op Fl h Ar host_key_file
54.Op Fl k Ar key_gen_time
55.Op Fl o Ar option 53.Op Fl o Ar option
56.Op Fl p Ar port 54.Op Fl p Ar port
57.Op Fl u Ar len 55.Op Fl u Ar len
@@ -96,9 +94,6 @@ to use IPv4 addresses only.
96Forces 94Forces
97.Nm 95.Nm
98to use IPv6 addresses only. 96to use IPv6 addresses only.
99.It Fl b Ar bits
100Specifies the number of bits in the ephemeral protocol version 1
101server key (default 1024).
102.It Fl C Ar connection_spec 97.It Fl C Ar connection_spec
103Specify the connection parameters to use for the 98Specify the connection parameters to use for the
104.Fl T 99.Fl T
@@ -169,36 +164,18 @@ This option must be given if
169is not run as root (as the normal 164is not run as root (as the normal
170host key files are normally not readable by anyone but root). 165host key files are normally not readable by anyone but root).
171The default is 166The default is
172.Pa /etc/ssh/ssh_host_key
173for protocol version 1, and
174.Pa /etc/ssh/ssh_host_dsa_key , 167.Pa /etc/ssh/ssh_host_dsa_key ,
175.Pa /etc/ssh/ssh_host_ecdsa_key . 168.Pa /etc/ssh/ssh_host_ecdsa_key ,
176.Pa /etc/ssh/ssh_host_ed25519_key 169.Pa /etc/ssh/ssh_host_ed25519_key
177and 170and
178.Pa /etc/ssh/ssh_host_rsa_key 171.Pa /etc/ssh/ssh_host_rsa_key .
179for protocol version 2.
180It is possible to have multiple host key files for 172It is possible to have multiple host key files for
181the different protocol versions and host key algorithms. 173the different host key algorithms.
182.It Fl i 174.It Fl i
183Specifies that 175Specifies that
184.Nm 176.Nm
185is being run from 177is being run from
186.Xr inetd 8 . 178.Xr inetd 8 .
187If SSH protocol 1 is enabled,
188.Nm
189should not normally be run
190from inetd because it needs to generate the server key before it can
191respond to the client, and this may take some time.
192Clients may have to wait too long if the key was regenerated every time.
193.It Fl k Ar key_gen_time
194Specifies how often the ephemeral protocol version 1 server key is
195regenerated (default 3600 seconds, or one hour).
196The motivation for regenerating the key fairly
197often is that the key is not stored anywhere, and after about an hour
198it becomes impossible to recover the key for decrypting intercepted
199communications even if the machine is cracked into or physically
200seized.
201A value of zero indicates that the key will never be regenerated.
202.It Fl o Ar option 179.It Fl o Ar option
203Can be used to give options in the format used in the configuration file. 180Can be used to give options in the format used in the configuration file.
204This is useful for specifying options for which there is no separate 181This is useful for specifying options for which there is no separate
@@ -257,8 +234,7 @@ may also be used to prevent
257from making DNS requests unless the authentication 234from making DNS requests unless the authentication
258mechanism or configuration requires it. 235mechanism or configuration requires it.
259Authentication mechanisms that may require DNS include 236Authentication mechanisms that may require DNS include
260.Cm RhostsRSAAuthentication , 237.Cm HostbasedAuthentication
261.Cm HostbasedAuthentication ,
262and using a 238and using a
263.Cm from="pattern-list" 239.Cm from="pattern-list"
264option in a key file. 240option in a key file.
@@ -269,42 +245,14 @@ or
269.Cm DenyUsers . 245.Cm DenyUsers .
270.El 246.El
271.Sh AUTHENTICATION 247.Sh AUTHENTICATION
272The OpenSSH SSH daemon supports SSH protocols 1 and 2. 248The OpenSSH SSH daemon supports SSH protocol 2 only.
273The default is to use protocol 2 only,
274though this can be changed via the
275.Cm Protocol
276option in
277.Xr sshd_config 5 .
278Protocol 1 should not be used
279and is only offered to support legacy devices.
280.Pp
281Each host has a host-specific key, 249Each host has a host-specific key,
282used to identify the host. 250used to identify the host.
283Partial forward security for protocol 1 is provided through
284an additional server key,
285normally 1024 bits,
286generated when the server starts.
287This key is normally regenerated every hour if it has been used, and
288is never stored on disk.
289Whenever a client connects, the daemon responds with its public 251Whenever a client connects, the daemon responds with its public
290host and server keys. 252host key.
291The client compares the 253The client compares the
292RSA host key against its own database to verify that it has not changed. 254host key against its own database to verify that it has not changed.
293The client then generates a 256-bit random number. 255Forward security is provided through a Diffie-Hellman key agreement.
294It encrypts this
295random number using both the host key and the server key, and sends
296the encrypted number to the server.
297Both sides then use this
298random number as a session key which is used to encrypt all further
299communications in the session.
300The rest of the session is encrypted
301using a conventional cipher, currently Blowfish or 3DES, with 3DES
302being used by default.
303The client selects the encryption algorithm
304to use from those offered by the server.
305.Pp
306For protocol 2,
307forward security is provided through a Diffie-Hellman key agreement.
308This key agreement results in a shared session key. 256This key agreement results in a shared session key.
309The rest of the session is encrypted using a symmetric cipher, currently 257The rest of the session is encrypted using a symmetric cipher, currently
310128-bit AES, Blowfish, 3DES, CAST128, Arcfour, 192-bit AES, or 256-bit AES. 258128-bit AES, Blowfish, 3DES, CAST128, Arcfour, 192-bit AES, or 256-bit AES.
@@ -477,32 +425,25 @@ key (empty lines and lines starting with a
477.Ql # 425.Ql #
478are ignored as 426are ignored as
479comments). 427comments).
480Protocol 1 public keys consist of the following space-separated fields: 428Public keys consist of the following space-separated fields:
481options, bits, exponent, modulus, comment.
482Protocol 2 public key consist of:
483options, keytype, base64-encoded key, comment. 429options, keytype, base64-encoded key, comment.
484The options field is optional; 430The options field is optional.
485its presence is determined by whether the line starts 431The keytype is
486with a number or not (the options field never starts with a number).
487The bits, exponent, modulus, and comment fields give the RSA key for
488protocol version 1; the
489comment field is not used for anything (but may be convenient for the
490user to identify the key).
491For protocol version 2 the keytype is
492.Dq ecdsa-sha2-nistp256 , 432.Dq ecdsa-sha2-nistp256 ,
493.Dq ecdsa-sha2-nistp384 , 433.Dq ecdsa-sha2-nistp384 ,
494.Dq ecdsa-sha2-nistp521 , 434.Dq ecdsa-sha2-nistp521 ,
495.Dq ssh-ed25519 , 435.Dq ssh-ed25519 ,
496.Dq ssh-dss 436.Dq ssh-dss
497or 437or
498.Dq ssh-rsa . 438.Dq ssh-rsa ;
439the comment field is not used for anything (but may be convenient for the
440user to identify the key).
499.Pp 441.Pp
500Note that lines in this file are usually several hundred bytes long 442Note that lines in this file can be several hundred bytes long
501(because of the size of the public key encoding) up to a limit of 443(because of the size of the public key encoding) up to a limit of
5028 kilobytes, which permits DSA keys up to 8 kilobits and RSA 4448 kilobytes, which permits DSA keys up to 8 kilobits and RSA
503keys up to 16 kilobits. 445keys up to 16 kilobits.
504You don't want to type them in; instead, copy the 446You don't want to type them in; instead, copy the
505.Pa identity.pub ,
506.Pa id_dsa.pub , 447.Pa id_dsa.pub ,
507.Pa id_ecdsa.pub , 448.Pa id_ecdsa.pub ,
508.Pa id_ed25519.pub , 449.Pa id_ed25519.pub ,
@@ -511,8 +452,7 @@ or the
511file and edit it. 452file and edit it.
512.Pp 453.Pp
513.Nm 454.Nm
514enforces a minimum RSA key modulus size for protocol 1 455enforces a minimum RSA key modulus size of 768 bits.
515and protocol 2 keys of 768 bits.
516.Pp 456.Pp
517The options (if present) consist of comma-separated option 457The options (if present) consist of comma-separated option
518specifications. 458specifications.
@@ -690,7 +630,7 @@ maintained automatically: whenever the user connects from an unknown host,
690its key is added to the per-user file. 630its key is added to the per-user file.
691.Pp 631.Pp
692Each line in these files contains the following fields: markers (optional), 632Each line in these files contains the following fields: markers (optional),
693hostnames, bits, exponent, modulus, comment. 633hostnames, keytype, base64-encoded key, comment.
694The fields are separated by spaces. 634The fields are separated by spaces.
695.Pp 635.Pp
696The marker is optional, but if it is present then it must be one of 636The marker is optional, but if it is present then it must be one of
@@ -731,9 +671,9 @@ character.
731Only one hashed hostname may appear on a single line and none of the above 671Only one hashed hostname may appear on a single line and none of the above
732negation or wildcard operators may be applied. 672negation or wildcard operators may be applied.
733.Pp 673.Pp
734Bits, exponent, and modulus are taken directly from the RSA host key; they 674The keytype and base64-encoded key are taken directly from the host key; they
735can be obtained, for example, from 675can be obtained, for example, from
736.Pa /etc/ssh/ssh_host_key.pub . 676.Pa /etc/ssh/ssh_host_rsa_key.pub .
737The optional comment field continues to the end of the line, and is not used. 677The optional comment field continues to the end of the line, and is not used.
738.Pp 678.Pp
739Lines starting with 679Lines starting with
@@ -772,8 +712,8 @@ Note that the lines in these files are typically hundreds of characters
772long, and you definitely don't want to type in the host keys by hand. 712long, and you definitely don't want to type in the host keys by hand.
773Rather, generate them by a script, 713Rather, generate them by a script,
774.Xr ssh-keyscan 1 714.Xr ssh-keyscan 1
775or by taking 715or by taking, for example,
776.Pa /etc/ssh/ssh_host_key.pub 716.Pa /etc/ssh/ssh_host_rsa_key.pub
777and adding the host names at the front. 717and adding the host names at the front.
778.Xr ssh-keygen 1 718.Xr ssh-keygen 1
779also offers some basic automated editing for 719also offers some basic automated editing for
@@ -912,7 +852,6 @@ This file is used in exactly the same way as
912but allows host-based authentication without permitting login with 852but allows host-based authentication without permitting login with
913rlogin/rsh. 853rlogin/rsh.
914.Pp 854.Pp
915.It Pa /etc/ssh/ssh_host_key
916.It Pa /etc/ssh/ssh_host_dsa_key 855.It Pa /etc/ssh/ssh_host_dsa_key
917.It Pa /etc/ssh/ssh_host_ecdsa_key 856.It Pa /etc/ssh/ssh_host_ecdsa_key
918.It Pa /etc/ssh/ssh_host_ed25519_key 857.It Pa /etc/ssh/ssh_host_ed25519_key
@@ -924,7 +863,6 @@ Note that
924.Nm 863.Nm
925does not start if these files are group/world-accessible. 864does not start if these files are group/world-accessible.
926.Pp 865.Pp
927.It Pa /etc/ssh/ssh_host_key.pub
928.It Pa /etc/ssh/ssh_host_dsa_key.pub 866.It Pa /etc/ssh/ssh_host_dsa_key.pub
929.It Pa /etc/ssh/ssh_host_ecdsa_key.pub 867.It Pa /etc/ssh/ssh_host_ecdsa_key.pub
930.It Pa /etc/ssh/ssh_host_ed25519_key.pub 868.It Pa /etc/ssh/ssh_host_ed25519_key.pub