Annotation of src/usr.bin/ssh/sshd_config.5, Revision 1.159
1.1 stevesk 1: .\"
2: .\" Author: Tatu Ylonen <ylo@cs.hut.fi>
3: .\" Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
4: .\" All rights reserved
5: .\"
6: .\" As far as I am concerned, the code I have written for this software
7: .\" can be used freely for any purpose. Any derived versions of this
8: .\" software must be clearly marked as such, and if the derived work is
9: .\" incompatible with the protocol description in the RFC file, it must be
10: .\" called by a name other than "ssh" or "Secure Shell".
11: .\"
12: .\" Copyright (c) 1999,2000 Markus Friedl. All rights reserved.
13: .\" Copyright (c) 1999 Aaron Campbell. All rights reserved.
14: .\" Copyright (c) 1999 Theo de Raadt. All rights reserved.
15: .\"
16: .\" Redistribution and use in source and binary forms, with or without
17: .\" modification, are permitted provided that the following conditions
18: .\" are met:
19: .\" 1. Redistributions of source code must retain the above copyright
20: .\" notice, this list of conditions and the following disclaimer.
21: .\" 2. Redistributions in binary form must reproduce the above copyright
22: .\" notice, this list of conditions and the following disclaimer in the
23: .\" documentation and/or other materials provided with the distribution.
24: .\"
25: .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
26: .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
27: .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
28: .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
29: .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
30: .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
31: .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
32: .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
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.
35: .\"
1.159 ! dtucker 36: .\" $OpenBSD: sshd_config.5,v 1.158 2013/04/19 01:00:10 djm Exp $
! 37: .Dd $Mdocdate: April 19 2013 $
1.1 stevesk 38: .Dt SSHD_CONFIG 5
39: .Os
40: .Sh NAME
41: .Nm sshd_config
42: .Nd OpenSSH SSH daemon configuration file
43: .Sh SYNOPSIS
1.71 jmc 44: .Nm /etc/ssh/sshd_config
1.1 stevesk 45: .Sh DESCRIPTION
1.53 jmc 46: .Xr sshd 8
1.1 stevesk 47: reads configuration data from
48: .Pa /etc/ssh/sshd_config
49: (or the file specified with
50: .Fl f
51: on the command line).
52: The file contains keyword-argument pairs, one per line.
53: Lines starting with
54: .Ql #
55: and empty lines are interpreted as comments.
1.56 dtucker 56: Arguments may optionally be enclosed in double quotes
57: .Pq \&"
58: in order to represent arguments containing spaces.
1.1 stevesk 59: .Pp
60: The possible
61: keywords and their meanings are as follows (note that
62: keywords are case-insensitive and arguments are case-sensitive):
63: .Bl -tag -width Ds
1.30 djm 64: .It Cm AcceptEnv
65: Specifies what environment variables sent by the client will be copied into
66: the session's
67: .Xr environ 7 .
68: See
69: .Cm SendEnv
70: in
71: .Xr ssh_config 5
72: for how to configure the client.
1.31 djm 73: Note that environment passing is only supported for protocol 2.
1.30 djm 74: Variables are specified by name, which may contain the wildcard characters
1.51 jmc 75: .Ql *
1.30 djm 76: and
77: .Ql \&? .
1.31 djm 78: Multiple environment variables may be separated by whitespace or spread
1.30 djm 79: across multiple
80: .Cm AcceptEnv
81: directives.
1.31 djm 82: Be warned that some environment variables could be used to bypass restricted
1.30 djm 83: user environments.
84: For this reason, care should be taken in the use of this directive.
85: The default is not to accept any environment variables.
1.37 djm 86: .It Cm AddressFamily
87: Specifies which address family should be used by
1.53 jmc 88: .Xr sshd 8 .
1.37 djm 89: Valid arguments are
90: .Dq any ,
91: .Dq inet
1.52 jmc 92: (use IPv4 only), or
1.37 djm 93: .Dq inet6
94: (use IPv6 only).
95: The default is
96: .Dq any .
1.89 jmc 97: .It Cm AllowAgentForwarding
98: Specifies whether
99: .Xr ssh-agent 1
100: forwarding is permitted.
101: The default is
102: .Dq yes .
103: Note that disabling agent forwarding does not improve security
104: unless users are also denied shell access, as they can always install
105: their own forwarders.
1.1 stevesk 106: .It Cm AllowGroups
107: This keyword can be followed by a list of group name patterns, separated
108: by spaces.
109: If specified, login is allowed only for users whose primary
110: group or supplementary group list matches one of the patterns.
111: Only group names are valid; a numerical group ID is not recognized.
112: By default, login is allowed for all groups.
1.54 jmc 113: The allow/deny directives are processed in the following order:
114: .Cm DenyUsers ,
115: .Cm AllowUsers ,
116: .Cm DenyGroups ,
117: and finally
118: .Cm AllowGroups .
1.49 jmc 119: .Pp
120: See
121: .Sx PATTERNS
122: in
123: .Xr ssh_config 5
124: for more information on patterns.
1.1 stevesk 125: .It Cm AllowTcpForwarding
126: Specifies whether TCP forwarding is permitted.
1.150 djm 127: The available options are
128: .Dq yes
129: or
130: .Dq all
131: to allow TCP forwarding,
132: .Dq no
133: to prevent all TCP forwarding,
134: .Dq local
135: to allow local (from the perspective of
1.151 jmc 136: .Xr ssh 1 )
137: forwarding only or
1.150 djm 138: .Dq remote
139: to allow remote forwarding only.
1.1 stevesk 140: The default is
141: .Dq yes .
142: Note that disabling TCP forwarding does not improve security unless
143: users are also denied shell access, as they can always install their
144: own forwarders.
145: .It Cm AllowUsers
146: This keyword can be followed by a list of user name patterns, separated
147: by spaces.
1.14 jmc 148: If specified, login is allowed only for user names that
1.1 stevesk 149: match one of the patterns.
150: Only user names are valid; a numerical user ID is not recognized.
151: By default, login is allowed for all users.
152: If the pattern takes the form USER@HOST then USER and HOST
153: are separately checked, restricting logins to particular
154: users from particular hosts.
1.54 jmc 155: The allow/deny directives are processed in the following order:
156: .Cm DenyUsers ,
157: .Cm AllowUsers ,
158: .Cm DenyGroups ,
159: and finally
160: .Cm AllowGroups .
1.49 jmc 161: .Pp
162: See
163: .Sx PATTERNS
164: in
165: .Xr ssh_config 5
166: for more information on patterns.
1.149 djm 167: .It Cm AuthenticationMethods
168: Specifies the authentication methods that must be successfully completed
169: for a user to be granted access.
170: This option must be followed by one or more comma-separated lists of
171: authentication method names.
172: Successful authentication requires completion of every method in at least
173: one of these lists.
174: .Pp
175: For example, an argument of
176: .Dq publickey,password publickey,keyboard-interactive
177: would require the user to complete public key authentication, followed by
178: either password or keyboard interactive authentication.
179: Only methods that are next in one or more lists are offered at each stage,
180: so for this example, it would not be possible to attempt password or
181: keyboard-interactive authentication before public key.
1.157 markus 182: .Pp
183: For keyboard interactive authentication it is also possible to
184: restrict authentication to a specific device by appending a
185: colon followed by the device identifier
186: .Dq bsdauth ,
187: .Dq pam ,
188: or
189: .Dq skey ,
190: depending on the server configuration.
191: For example,
192: .Dq keyboard-interactive:bsdauth
193: would restrict keyboard interactive authentication to the
194: .Dq bsdauth
195: device.
1.149 djm 196: .Pp
197: This option is only available for SSH protocol 2 and will yield a fatal
198: error if enabled if protocol 1 is also enabled.
199: Note that each authentication method listed should also be explicitly enabled
200: in the configuration.
201: The default is not to require multiple authentication; successful completion
202: of a single authentication method is sufficient.
1.146 djm 203: .It Cm AuthorizedKeysCommand
1.147 jmc 204: Specifies a program to be used to look up the user's public keys.
1.158 djm 205: The program must be owned by root and not writable by group or others.
206: It will be invoked with a single argument of the username
1.146 djm 207: being authenticated, and should produce on standard output zero or
1.147 jmc 208: more lines of authorized_keys output (see
209: .Sx AUTHORIZED_KEYS
210: in
211: .Xr sshd 8 ) .
1.146 djm 212: If a key supplied by AuthorizedKeysCommand does not successfully authenticate
213: and authorize the user then public key authentication continues using the usual
214: .Cm AuthorizedKeysFile
215: files.
216: By default, no AuthorizedKeysCommand is run.
217: .It Cm AuthorizedKeysCommandUser
218: Specifies the user under whose account the AuthorizedKeysCommand is run.
219: It is recommended to use a dedicated user that has no other role on the host
220: than running authorized keys commands.
1.1 stevesk 221: .It Cm AuthorizedKeysFile
222: Specifies the file that contains the public keys that can be used
223: for user authentication.
1.124 djm 224: The format is described in the
225: .Sx AUTHORIZED_KEYS FILE FORMAT
226: section of
227: .Xr sshd 8 .
1.1 stevesk 228: .Cm AuthorizedKeysFile
229: may contain tokens of the form %T which are substituted during connection
1.52 jmc 230: setup.
1.17 jmc 231: The following tokens are defined: %% is replaced by a literal '%',
1.52 jmc 232: %h is replaced by the home directory of the user being authenticated, and
1.1 stevesk 233: %u is replaced by the username of that user.
234: After expansion,
235: .Cm AuthorizedKeysFile
236: is taken to be an absolute path or one relative to the user's home
237: directory.
1.133 jmc 238: Multiple files may be listed, separated by whitespace.
239: The default is
240: .Dq .ssh/authorized_keys .ssh/authorized_keys2 .
1.121 djm 241: .It Cm AuthorizedPrincipalsFile
242: Specifies a file that lists principal names that are accepted for
243: certificate authentication.
244: When using certificates signed by a key listed in
245: .Cm TrustedUserCAKeys ,
246: this file lists names, one of which must appear in the certificate for it
247: to be accepted for authentication.
1.125 jmc 248: Names are listed one per line preceded by key options (as described
1.124 djm 249: in
250: .Sx AUTHORIZED_KEYS FILE FORMAT
251: in
1.125 jmc 252: .Xr sshd 8 ) .
1.124 djm 253: Empty lines and comments starting with
1.121 djm 254: .Ql #
255: are ignored.
256: .Pp
257: .Cm AuthorizedPrincipalsFile
258: may contain tokens of the form %T which are substituted during connection
259: setup.
260: The following tokens are defined: %% is replaced by a literal '%',
261: %h is replaced by the home directory of the user being authenticated, and
262: %u is replaced by the username of that user.
263: After expansion,
264: .Cm AuthorizedPrincipalsFile
265: is taken to be an absolute path or one relative to the user's home
266: directory.
267: .Pp
1.138 djm 268: The default is
269: .Dq none ,
270: i.e. not to use a principals file \(en in this case, the username
1.121 djm 271: of the user must appear in a certificate's principals list for it to be
272: accepted.
273: Note that
274: .Cm AuthorizedPrincipalsFile
275: is only used when authentication proceeds using a CA listed in
276: .Cm TrustedUserCAKeys
277: and is not consulted for certification authorities trusted via
278: .Pa ~/.ssh/authorized_keys ,
279: though the
280: .Cm principals=
281: key option offers a similar facility (see
282: .Xr sshd 8
283: for details).
1.1 stevesk 284: .It Cm Banner
285: The contents of the specified file are sent to the remote user before
286: authentication is allowed.
1.78 djm 287: If the argument is
288: .Dq none
289: then no banner is displayed.
1.1 stevesk 290: This option is only available for protocol version 2.
291: By default, no banner is displayed.
292: .It Cm ChallengeResponseAuthentication
1.50 jmc 293: Specifies whether challenge-response authentication is allowed.
1.1 stevesk 294: All authentication styles from
295: .Xr login.conf 5
296: are supported.
297: The default is
298: .Dq yes .
1.80 djm 299: .It Cm ChrootDirectory
1.113 stevesk 300: Specifies the pathname of a directory to
1.80 djm 301: .Xr chroot 2
302: to after authentication.
1.113 stevesk 303: All components of the pathname must be root-owned directories that are
1.80 djm 304: not writable by any other user or group.
1.106 stevesk 305: After the chroot,
306: .Xr sshd 8
307: changes the working directory to the user's home directory.
1.80 djm 308: .Pp
1.113 stevesk 309: The pathname may contain the following tokens that are expanded at runtime once
1.80 djm 310: the connecting user has been authenticated: %% is replaced by a literal '%',
311: %h is replaced by the home directory of the user being authenticated, and
312: %u is replaced by the username of that user.
313: .Pp
314: The
315: .Cm ChrootDirectory
316: must contain the necessary files and directories to support the
1.103 stevesk 317: user's session.
1.80 djm 318: For an interactive session this requires at least a shell, typically
319: .Xr sh 1 ,
320: and basic
321: .Pa /dev
322: nodes such as
323: .Xr null 4 ,
324: .Xr zero 4 ,
325: .Xr stdin 4 ,
326: .Xr stdout 4 ,
327: .Xr stderr 4 ,
328: .Xr arandom 4
329: and
330: .Xr tty 4
331: devices.
332: For file transfer sessions using
1.105 jmc 333: .Dq sftp ,
1.80 djm 334: no additional configuration of the environment is necessary if the
1.105 jmc 335: in-process sftp server is used,
336: though sessions which use logging do require
1.104 stevesk 337: .Pa /dev/log
338: inside the chroot directory (see
339: .Xr sftp-server 8
1.81 jmc 340: for details).
1.80 djm 341: .Pp
342: The default is not to
343: .Xr chroot 2 .
1.1 stevesk 344: .It Cm Ciphers
345: Specifies the ciphers allowed for protocol version 2.
346: Multiple ciphers must be comma-separated.
1.34 dtucker 347: The supported ciphers are
348: .Dq 3des-cbc ,
349: .Dq aes128-cbc ,
350: .Dq aes192-cbc ,
351: .Dq aes256-cbc ,
352: .Dq aes128-ctr ,
353: .Dq aes192-ctr ,
354: .Dq aes256-ctr ,
1.153 markus 355: .Dq aes128-gcm@openssh.com ,
356: .Dq aes256-gcm@openssh.com ,
1.43 djm 357: .Dq arcfour128 ,
358: .Dq arcfour256 ,
1.34 dtucker 359: .Dq arcfour ,
360: .Dq blowfish-cbc ,
361: and
362: .Dq cast128-cbc .
1.52 jmc 363: The default is:
364: .Bd -literal -offset 3n
1.100 naddy 365: aes128-ctr,aes192-ctr,aes256-ctr,arcfour256,arcfour128,
1.153 markus 366: aes128-gcm@openssh.com,aes256-gcm@openssh.com,
1.100 naddy 367: aes128-cbc,3des-cbc,blowfish-cbc,cast128-cbc,aes192-cbc,
368: aes256-cbc,arcfour
1.1 stevesk 369: .Ed
370: .It Cm ClientAliveCountMax
1.48 jmc 371: Sets the number of client alive messages (see below) which may be
1.1 stevesk 372: sent without
1.52 jmc 373: .Xr sshd 8
1.17 jmc 374: receiving any messages back from the client.
375: If this threshold is reached while client alive messages are being sent,
1.52 jmc 376: sshd will disconnect the client, terminating the session.
1.17 jmc 377: It is important to note that the use of client alive messages is very
378: different from
1.27 markus 379: .Cm TCPKeepAlive
1.17 jmc 380: (below).
381: The client alive messages are sent through the encrypted channel
382: and therefore will not be spoofable.
383: The TCP keepalive option enabled by
1.27 markus 384: .Cm TCPKeepAlive
1.17 jmc 385: is spoofable.
386: The client alive mechanism is valuable when the client or
1.1 stevesk 387: server depend on knowing when a connection has become inactive.
388: .Pp
1.17 jmc 389: The default value is 3.
390: If
1.1 stevesk 391: .Cm ClientAliveInterval
1.48 jmc 392: (see below) is set to 15, and
1.1 stevesk 393: .Cm ClientAliveCountMax
1.52 jmc 394: is left at the default, unresponsive SSH clients
1.1 stevesk 395: will be disconnected after approximately 45 seconds.
1.57 markus 396: This option applies to protocol version 2 only.
1.42 djm 397: .It Cm ClientAliveInterval
398: Sets a timeout interval in seconds after which if no data has been received
399: from the client,
1.52 jmc 400: .Xr sshd 8
1.42 djm 401: will send a message through the encrypted
402: channel to request a response from the client.
403: The default
404: is 0, indicating that these messages will not be sent to the client.
405: This option applies to protocol version 2 only.
1.3 markus 406: .It Cm Compression
1.44 markus 407: Specifies whether compression is allowed, or delayed until
408: the user has authenticated successfully.
1.3 markus 409: The argument must be
1.44 markus 410: .Dq yes ,
411: .Dq delayed ,
1.3 markus 412: or
413: .Dq no .
414: The default is
1.44 markus 415: .Dq delayed .
1.1 stevesk 416: .It Cm DenyGroups
417: This keyword can be followed by a list of group name patterns, separated
418: by spaces.
419: Login is disallowed for users whose primary group or supplementary
420: group list matches one of the patterns.
421: Only group names are valid; a numerical group ID is not recognized.
422: By default, login is allowed for all groups.
1.54 jmc 423: The allow/deny directives are processed in the following order:
424: .Cm DenyUsers ,
425: .Cm AllowUsers ,
426: .Cm DenyGroups ,
427: and finally
428: .Cm AllowGroups .
1.49 jmc 429: .Pp
430: See
431: .Sx PATTERNS
432: in
433: .Xr ssh_config 5
434: for more information on patterns.
1.1 stevesk 435: .It Cm DenyUsers
436: This keyword can be followed by a list of user name patterns, separated
437: by spaces.
438: Login is disallowed for user names that match one of the patterns.
439: Only user names are valid; a numerical user ID is not recognized.
440: By default, login is allowed for all users.
441: If the pattern takes the form USER@HOST then USER and HOST
442: are separately checked, restricting logins to particular
443: users from particular hosts.
1.54 jmc 444: The allow/deny directives are processed in the following order:
445: .Cm DenyUsers ,
446: .Cm AllowUsers ,
447: .Cm DenyGroups ,
448: and finally
449: .Cm AllowGroups .
1.49 jmc 450: .Pp
451: See
452: .Sx PATTERNS
453: in
454: .Xr ssh_config 5
455: for more information on patterns.
1.67 dtucker 456: .It Cm ForceCommand
457: Forces the execution of the command specified by
458: .Cm ForceCommand ,
1.84 djm 459: ignoring any command supplied by the client and
460: .Pa ~/.ssh/rc
461: if present.
1.67 dtucker 462: The command is invoked by using the user's login shell with the -c option.
463: This applies to shell, command, or subsystem execution.
464: It is most useful inside a
465: .Cm Match
466: block.
467: The command originally supplied by the client is available in the
468: .Ev SSH_ORIGINAL_COMMAND
469: environment variable.
1.82 djm 470: Specifying a command of
471: .Dq internal-sftp
472: will force the use of an in-process sftp server that requires no support
473: files when used with
474: .Cm ChrootDirectory .
1.1 stevesk 475: .It Cm GatewayPorts
476: Specifies whether remote hosts are allowed to connect to ports
477: forwarded for the client.
478: By default,
1.52 jmc 479: .Xr sshd 8
1.15 jmc 480: binds remote port forwardings to the loopback address.
481: This prevents other remote hosts from connecting to forwarded ports.
1.1 stevesk 482: .Cm GatewayPorts
1.52 jmc 483: can be used to specify that sshd
1.39 djm 484: should allow remote port forwardings to bind to non-loopback addresses, thus
485: allowing other hosts to connect.
486: The argument may be
487: .Dq no
488: to force remote port forwardings to be available to the local host only,
1.1 stevesk 489: .Dq yes
1.39 djm 490: to force remote port forwardings to bind to the wildcard address, or
491: .Dq clientspecified
492: to allow the client to select the address to which the forwarding is bound.
1.1 stevesk 493: The default is
494: .Dq no .
1.23 markus 495: .It Cm GSSAPIAuthentication
1.25 markus 496: Specifies whether user authentication based on GSSAPI is allowed.
1.26 djm 497: The default is
1.23 markus 498: .Dq no .
499: Note that this option applies to protocol version 2 only.
500: .It Cm GSSAPICleanupCredentials
501: Specifies whether to automatically destroy the user's credentials cache
502: on logout.
503: The default is
504: .Dq yes .
505: Note that this option applies to protocol version 2 only.
1.1 stevesk 506: .It Cm HostbasedAuthentication
507: Specifies whether rhosts or /etc/hosts.equiv authentication together
508: with successful public key client host authentication is allowed
1.50 jmc 509: (host-based authentication).
1.1 stevesk 510: This option is similar to
511: .Cm RhostsRSAAuthentication
512: and applies to protocol version 2 only.
1.70 dtucker 513: The default is
514: .Dq no .
515: .It Cm HostbasedUsesNameFromPacketOnly
516: Specifies whether or not the server will attempt to perform a reverse
517: name lookup when matching the name in the
518: .Pa ~/.shosts ,
519: .Pa ~/.rhosts ,
520: and
521: .Pa /etc/hosts.equiv
522: files during
523: .Cm HostbasedAuthentication .
524: A setting of
525: .Dq yes
526: means that
527: .Xr sshd 8
528: uses the name supplied by the client rather than
529: attempting to resolve the name from the TCP connection itself.
1.1 stevesk 530: The default is
531: .Dq no .
1.117 djm 532: .It Cm HostCertificate
533: Specifies a file containing a public host certificate.
534: The certificate's public key must match a private host key already specified
535: by
536: .Cm HostKey .
537: The default behaviour of
538: .Xr sshd 8
539: is not to load any certificates.
1.1 stevesk 540: .It Cm HostKey
541: Specifies a file containing a private host key
542: used by SSH.
543: The default is
544: .Pa /etc/ssh/ssh_host_key
545: for protocol version 1, and
1.126 djm 546: .Pa /etc/ssh/ssh_host_dsa_key ,
547: .Pa /etc/ssh/ssh_host_ecdsa_key
548: and
1.1 stevesk 549: .Pa /etc/ssh/ssh_host_rsa_key
550: for protocol version 2.
551: Note that
1.52 jmc 552: .Xr sshd 8
1.1 stevesk 553: will refuse to use a file if it is group/world-accessible.
554: It is possible to have multiple host key files.
555: .Dq rsa1
556: keys are used for version 1 and
1.126 djm 557: .Dq dsa ,
558: .Dq ecdsa
1.1 stevesk 559: or
560: .Dq rsa
561: are used for version 2 of the SSH protocol.
562: .It Cm IgnoreRhosts
563: Specifies that
564: .Pa .rhosts
565: and
566: .Pa .shosts
567: files will not be used in
568: .Cm RhostsRSAAuthentication
569: or
570: .Cm HostbasedAuthentication .
571: .Pp
572: .Pa /etc/hosts.equiv
573: and
574: .Pa /etc/shosts.equiv
575: are still used.
576: The default is
577: .Dq yes .
578: .It Cm IgnoreUserKnownHosts
579: Specifies whether
1.52 jmc 580: .Xr sshd 8
1.1 stevesk 581: should ignore the user's
1.41 djm 582: .Pa ~/.ssh/known_hosts
1.1 stevesk 583: during
584: .Cm RhostsRSAAuthentication
585: or
586: .Cm HostbasedAuthentication .
587: The default is
588: .Dq no .
1.129 djm 589: .It Cm IPQoS
590: Specifies the IPv4 type-of-service or DSCP class for the connection.
591: Accepted values are
592: .Dq af11 ,
593: .Dq af12 ,
594: .Dq af13 ,
1.136 djm 595: .Dq af21 ,
1.129 djm 596: .Dq af22 ,
597: .Dq af23 ,
598: .Dq af31 ,
599: .Dq af32 ,
600: .Dq af33 ,
601: .Dq af41 ,
602: .Dq af42 ,
603: .Dq af43 ,
604: .Dq cs0 ,
605: .Dq cs1 ,
606: .Dq cs2 ,
607: .Dq cs3 ,
608: .Dq cs4 ,
609: .Dq cs5 ,
610: .Dq cs6 ,
611: .Dq cs7 ,
612: .Dq ef ,
613: .Dq lowdelay ,
614: .Dq throughput ,
615: .Dq reliability ,
616: or a numeric value.
1.131 djm 617: This option may take one or two arguments, separated by whitespace.
1.129 djm 618: If one argument is specified, it is used as the packet class unconditionally.
619: If two values are specified, the first is automatically selected for
620: interactive sessions and the second for non-interactive sessions.
621: The default is
622: .Dq lowdelay
623: for interactive sessions and
624: .Dq throughput
625: for non-interactive sessions.
1.1 stevesk 626: .It Cm KerberosAuthentication
1.24 markus 627: Specifies whether the password provided by the user for
1.1 stevesk 628: .Cm PasswordAuthentication
1.24 markus 629: will be validated through the Kerberos KDC.
1.1 stevesk 630: To use this option, the server needs a
631: Kerberos servtab which allows the verification of the KDC's identity.
1.52 jmc 632: The default is
1.29 dtucker 633: .Dq no .
634: .It Cm KerberosGetAFSToken
1.45 djm 635: If AFS is active and the user has a Kerberos 5 TGT, attempt to acquire
1.29 dtucker 636: an AFS token before accessing the user's home directory.
1.52 jmc 637: The default is
1.1 stevesk 638: .Dq no .
639: .It Cm KerberosOrLocalPasswd
1.52 jmc 640: If password authentication through Kerberos fails then
1.1 stevesk 641: the password will be validated via any additional local mechanism
642: such as
643: .Pa /etc/passwd .
1.52 jmc 644: The default is
1.1 stevesk 645: .Dq yes .
646: .It Cm KerberosTicketCleanup
647: Specifies whether to automatically destroy the user's ticket cache
648: file on logout.
1.52 jmc 649: The default is
1.1 stevesk 650: .Dq yes .
1.127 djm 651: .It Cm KexAlgorithms
652: Specifies the available KEX (Key Exchange) algorithms.
653: Multiple algorithms must be comma-separated.
654: The default is
655: .Dq ecdh-sha2-nistp256 ,
656: .Dq ecdh-sha2-nistp384 ,
657: .Dq ecdh-sha2-nistp521 ,
1.130 jmc 658: .Dq diffie-hellman-group-exchange-sha256 ,
1.127 djm 659: .Dq diffie-hellman-group-exchange-sha1 ,
660: .Dq diffie-hellman-group14-sha1 ,
661: .Dq diffie-hellman-group1-sha1 .
1.1 stevesk 662: .It Cm KeyRegenerationInterval
663: In protocol version 1, the ephemeral server key is automatically regenerated
664: after this many seconds (if it has been used).
665: The purpose of regeneration is to prevent
666: decrypting captured sessions by later breaking into the machine and
667: stealing the keys.
668: The key is never stored anywhere.
669: If the value is 0, the key is never regenerated.
670: The default is 3600 (seconds).
671: .It Cm ListenAddress
672: Specifies the local addresses
1.52 jmc 673: .Xr sshd 8
1.1 stevesk 674: should listen on.
675: The following forms may be used:
676: .Pp
677: .Bl -item -offset indent -compact
678: .It
679: .Cm ListenAddress
680: .Sm off
681: .Ar host No | Ar IPv4_addr No | Ar IPv6_addr
682: .Sm on
683: .It
684: .Cm ListenAddress
685: .Sm off
686: .Ar host No | Ar IPv4_addr No : Ar port
687: .Sm on
688: .It
689: .Cm ListenAddress
690: .Sm off
691: .Oo
692: .Ar host No | Ar IPv6_addr Oc : Ar port
693: .Sm on
694: .El
695: .Pp
696: If
697: .Ar port
698: is not specified,
1.52 jmc 699: sshd will listen on the address and all prior
1.1 stevesk 700: .Cm Port
1.17 jmc 701: options specified.
702: The default is to listen on all local addresses.
1.15 jmc 703: Multiple
1.1 stevesk 704: .Cm ListenAddress
1.17 jmc 705: options are permitted.
706: Additionally, any
1.1 stevesk 707: .Cm Port
1.52 jmc 708: options must precede this option for non-port qualified addresses.
1.1 stevesk 709: .It Cm LoginGraceTime
710: The server disconnects after this time if the user has not
711: successfully logged in.
712: If the value is 0, there is no time limit.
1.12 stevesk 713: The default is 120 seconds.
1.1 stevesk 714: .It Cm LogLevel
715: Gives the verbosity level that is used when logging messages from
1.53 jmc 716: .Xr sshd 8 .
1.1 stevesk 717: The possible values are:
1.52 jmc 718: QUIET, FATAL, ERROR, INFO, VERBOSE, DEBUG, DEBUG1, DEBUG2, and DEBUG3.
1.15 jmc 719: The default is INFO.
720: DEBUG and DEBUG1 are equivalent.
721: DEBUG2 and DEBUG3 each specify higher levels of debugging output.
722: Logging with a DEBUG level violates the privacy of users and is not recommended.
1.1 stevesk 723: .It Cm MACs
724: Specifies the available MAC (message authentication code) algorithms.
725: The MAC algorithm is used in protocol version 2
726: for data integrity protection.
727: Multiple algorithms must be comma-separated.
1.152 markus 728: The algorithms that contain
729: .Dq -etm
730: calculate the MAC after encryption (encrypt-then-mac).
731: These are considered safer and their use recommended.
1.52 jmc 732: The default is:
1.77 jmc 733: .Bd -literal -offset indent
1.152 markus 734: hmac-md5-etm@openssh.com,hmac-sha1-etm@openssh.com,
735: umac-64-etm@openssh.com,umac-128-etm@openssh.com,
736: hmac-sha2-256-etm@openssh.com,hmac-sha2-512-etm@openssh.com,
737: hmac-ripemd160-etm@openssh.com,hmac-sha1-96-etm@openssh.com,
738: hmac-md5-96-etm@openssh.com,
1.145 markus 739: hmac-md5,hmac-sha1,umac-64@openssh.com,umac-128@openssh.com,
1.144 naddy 740: hmac-sha2-256,hmac-sha2-512,hmac-ripemd160,
741: hmac-sha1-96,hmac-md5-96
1.77 jmc 742: .Ed
1.60 dtucker 743: .It Cm Match
1.61 jmc 744: Introduces a conditional block.
1.65 dtucker 745: If all of the criteria on the
1.60 dtucker 746: .Cm Match
1.65 dtucker 747: line are satisfied, the keywords on the following lines override those
748: set in the global section of the config file, until either another
1.60 dtucker 749: .Cm Match
1.65 dtucker 750: line or the end of the file.
1.91 djm 751: .Pp
1.61 jmc 752: The arguments to
1.60 dtucker 753: .Cm Match
1.65 dtucker 754: are one or more criteria-pattern pairs.
1.60 dtucker 755: The available criteria are
756: .Cm User ,
1.69 dtucker 757: .Cm Group ,
1.60 dtucker 758: .Cm Host ,
1.139 dtucker 759: .Cm LocalAddress ,
760: .Cm LocalPort ,
1.60 dtucker 761: and
762: .Cm Address .
1.91 djm 763: The match patterns may consist of single entries or comma-separated
764: lists and may use the wildcard and negation operators described in the
1.92 djm 765: .Sx PATTERNS
1.91 djm 766: section of
1.92 djm 767: .Xr ssh_config 5 .
1.91 djm 768: .Pp
769: The patterns in an
770: .Cm Address
771: criteria may additionally contain addresses to match in CIDR
1.93 jmc 772: address/masklen format, e.g.\&
1.91 djm 773: .Dq 192.0.2.0/24
774: or
775: .Dq 3ffe:ffff::/32 .
776: Note that the mask length provided must be consistent with the address -
777: it is an error to specify a mask length that is too long for the address
1.93 jmc 778: or one with bits set in this host portion of the address.
779: For example,
1.91 djm 780: .Dq 192.0.2.0/33
781: and
1.93 jmc 782: .Dq 192.0.2.0/8
1.91 djm 783: respectively.
784: .Pp
1.60 dtucker 785: Only a subset of keywords may be used on the lines following a
786: .Cm Match
787: keyword.
788: Available keywords are
1.142 jmc 789: .Cm AcceptEnv ,
1.99 okan 790: .Cm AllowAgentForwarding ,
1.142 jmc 791: .Cm AllowGroups ,
1.62 dtucker 792: .Cm AllowTcpForwarding ,
1.141 markus 793: .Cm AllowUsers ,
1.149 djm 794: .Cm AuthenticationMethods ,
1.146 djm 795: .Cm AuthorizedKeysCommand ,
796: .Cm AuthorizedKeysCommandUser ,
1.147 jmc 797: .Cm AuthorizedKeysFile ,
1.123 djm 798: .Cm AuthorizedPrincipalsFile ,
1.72 dtucker 799: .Cm Banner ,
1.85 djm 800: .Cm ChrootDirectory ,
1.141 markus 801: .Cm DenyGroups ,
802: .Cm DenyUsers ,
1.67 dtucker 803: .Cm ForceCommand ,
1.142 jmc 804: .Cm GatewayPorts ,
1.141 markus 805: .Cm GSSAPIAuthentication ,
1.87 djm 806: .Cm HostbasedAuthentication ,
1.123 djm 807: .Cm HostbasedUsesNameFromPacketOnly ,
1.74 jmc 808: .Cm KbdInteractiveAuthentication ,
1.72 dtucker 809: .Cm KerberosAuthentication ,
1.95 dtucker 810: .Cm MaxAuthTries ,
1.94 dtucker 811: .Cm MaxSessions ,
1.72 dtucker 812: .Cm PasswordAuthentication ,
1.97 djm 813: .Cm PermitEmptyPasswords ,
1.66 dtucker 814: .Cm PermitOpen ,
1.79 dtucker 815: .Cm PermitRootLogin ,
1.123 djm 816: .Cm PermitTunnel ,
1.107 dtucker 817: .Cm PubkeyAuthentication ,
1.159 ! dtucker 818: .Cm RekeyLimit ,
1.142 jmc 819: .Cm RhostsRSAAuthentication ,
1.141 markus 820: .Cm RSAAuthentication ,
1.66 dtucker 821: .Cm X11DisplayOffset ,
1.101 djm 822: .Cm X11Forwarding
1.60 dtucker 823: and
1.102 djm 824: .Cm X11UseLocalHost .
1.33 dtucker 825: .It Cm MaxAuthTries
826: Specifies the maximum number of authentication attempts permitted per
1.35 jmc 827: connection.
828: Once the number of failures reaches half this value,
829: additional failures are logged.
830: The default is 6.
1.90 djm 831: .It Cm MaxSessions
832: Specifies the maximum number of open sessions permitted per network connection.
833: The default is 10.
1.1 stevesk 834: .It Cm MaxStartups
835: Specifies the maximum number of concurrent unauthenticated connections to the
1.52 jmc 836: SSH daemon.
1.1 stevesk 837: Additional connections will be dropped until authentication succeeds or the
838: .Cm LoginGraceTime
839: expires for a connection.
1.156 dtucker 840: The default is 10:30:100.
1.1 stevesk 841: .Pp
842: Alternatively, random early drop can be enabled by specifying
843: the three colon separated values
844: .Dq start:rate:full
1.51 jmc 845: (e.g. "10:30:60").
1.53 jmc 846: .Xr sshd 8
1.1 stevesk 847: will refuse connection attempts with a probability of
848: .Dq rate/100
849: (30%)
850: if there are currently
851: .Dq start
852: (10)
853: unauthenticated connections.
854: The probability increases linearly and all connection attempts
855: are refused if the number of unauthenticated connections reaches
856: .Dq full
857: (60).
858: .It Cm PasswordAuthentication
859: Specifies whether password authentication is allowed.
860: The default is
861: .Dq yes .
862: .It Cm PermitEmptyPasswords
863: When password authentication is allowed, it specifies whether the
864: server allows login to accounts with empty password strings.
865: The default is
866: .Dq no .
1.62 dtucker 867: .It Cm PermitOpen
868: Specifies the destinations to which TCP port forwarding is permitted.
869: The forwarding specification must be one of the following forms:
870: .Pp
871: .Bl -item -offset indent -compact
872: .It
873: .Cm PermitOpen
874: .Sm off
875: .Ar host : port
876: .Sm on
877: .It
878: .Cm PermitOpen
879: .Sm off
880: .Ar IPv4_addr : port
881: .Sm on
882: .It
883: .Cm PermitOpen
884: .Sm off
885: .Ar \&[ IPv6_addr \&] : port
886: .Sm on
887: .El
888: .Pp
1.68 dtucker 889: Multiple forwards may be specified by separating them with whitespace.
1.62 dtucker 890: An argument of
891: .Dq any
892: can be used to remove all restrictions and permit any forwarding requests.
1.140 dtucker 893: An argument of
894: .Dq none
895: can be used to prohibit all forwarding requests.
1.63 jmc 896: By default all port forwarding requests are permitted.
1.1 stevesk 897: .It Cm PermitRootLogin
1.38 jmc 898: Specifies whether root can log in using
1.1 stevesk 899: .Xr ssh 1 .
900: The argument must be
901: .Dq yes ,
902: .Dq without-password ,
1.52 jmc 903: .Dq forced-commands-only ,
1.1 stevesk 904: or
905: .Dq no .
906: The default is
907: .Dq yes .
908: .Pp
909: If this option is set to
1.52 jmc 910: .Dq without-password ,
1.1 stevesk 911: password authentication is disabled for root.
912: .Pp
913: If this option is set to
1.52 jmc 914: .Dq forced-commands-only ,
1.1 stevesk 915: root login with public key authentication will be allowed,
916: but only if the
917: .Ar command
918: option has been specified
919: (which may be useful for taking remote backups even if root login is
1.17 jmc 920: normally not allowed).
921: All other authentication methods are disabled for root.
1.1 stevesk 922: .Pp
923: If this option is set to
1.52 jmc 924: .Dq no ,
1.38 jmc 925: root is not allowed to log in.
1.46 reyk 926: .It Cm PermitTunnel
927: Specifies whether
928: .Xr tun 4
929: device forwarding is allowed.
1.47 reyk 930: The argument must be
931: .Dq yes ,
1.58 stevesk 932: .Dq point-to-point
933: (layer 3),
934: .Dq ethernet
935: (layer 2), or
1.47 reyk 936: .Dq no .
1.58 stevesk 937: Specifying
938: .Dq yes
939: permits both
940: .Dq point-to-point
941: and
942: .Dq ethernet .
1.46 reyk 943: The default is
944: .Dq no .
1.6 markus 945: .It Cm PermitUserEnvironment
946: Specifies whether
947: .Pa ~/.ssh/environment
1.9 stevesk 948: and
1.6 markus 949: .Cm environment=
950: options in
951: .Pa ~/.ssh/authorized_keys
1.9 stevesk 952: are processed by
1.52 jmc 953: .Xr sshd 8 .
1.6 markus 954: The default is
955: .Dq no .
1.9 stevesk 956: Enabling environment processing may enable users to bypass access
957: restrictions in some configurations using mechanisms such as
958: .Ev LD_PRELOAD .
1.1 stevesk 959: .It Cm PidFile
1.4 stevesk 960: Specifies the file that contains the process ID of the
1.53 jmc 961: SSH daemon.
1.1 stevesk 962: The default is
963: .Pa /var/run/sshd.pid .
964: .It Cm Port
965: Specifies the port number that
1.52 jmc 966: .Xr sshd 8
1.1 stevesk 967: listens on.
968: The default is 22.
969: Multiple options of this type are permitted.
970: See also
971: .Cm ListenAddress .
972: .It Cm PrintLastLog
973: Specifies whether
1.52 jmc 974: .Xr sshd 8
1.36 jaredy 975: should print the date and time of the last user login when a user logs
976: in interactively.
1.1 stevesk 977: The default is
978: .Dq yes .
979: .It Cm PrintMotd
980: Specifies whether
1.52 jmc 981: .Xr sshd 8
1.1 stevesk 982: should print
983: .Pa /etc/motd
984: when a user logs in interactively.
985: (On some systems it is also printed by the shell,
986: .Pa /etc/profile ,
987: or equivalent.)
988: The default is
989: .Dq yes .
990: .It Cm Protocol
991: Specifies the protocol versions
1.52 jmc 992: .Xr sshd 8
1.5 stevesk 993: supports.
1.1 stevesk 994: The possible values are
1.52 jmc 995: .Sq 1
1.1 stevesk 996: and
1.52 jmc 997: .Sq 2 .
1.1 stevesk 998: Multiple versions must be comma-separated.
999: The default is
1.109 jmc 1000: .Sq 2 .
1.5 stevesk 1001: Note that the order of the protocol list does not indicate preference,
1002: because the client selects among multiple protocol versions offered
1003: by the server.
1004: Specifying
1005: .Dq 2,1
1006: is identical to
1007: .Dq 1,2 .
1.1 stevesk 1008: .It Cm PubkeyAuthentication
1009: Specifies whether public key authentication is allowed.
1010: The default is
1011: .Dq yes .
1012: Note that this option applies to protocol version 2 only.
1.159 ! dtucker 1013: .It Cm RekeyLimit
! 1014: Specifies the maximum amount of data that may be transmitted before the
! 1015: session key is renegotiated, optionally followed a maximum amount of
! 1016: time that may pass before the session key is renegotiated.
! 1017: The first argument is specified in bytes and may have a suffix of
! 1018: .Sq K ,
! 1019: .Sq M ,
! 1020: or
! 1021: .Sq G
! 1022: to indicate Kilobytes, Megabytes, or Gigabytes, respectively.
! 1023: The default is between
! 1024: .Sq 1G
! 1025: and
! 1026: .Sq 4G ,
! 1027: depending on the cipher.
! 1028: The optional second value is specified in seconds and may use any of the
! 1029: units documented in the
! 1030: .Sx TIME FORMATS
! 1031: section of
! 1032: .Xr sshd_config 5 .
! 1033: The default value for
! 1034: .Cm RekeyLimit
! 1035: is
! 1036: .Dq default none ,
! 1037: which means that rekeying is performed after the cipher's default amount
! 1038: of data has been sent or received and no time based rekeying is done.
! 1039: This option applies to protocol version 2 only.
1.118 djm 1040: .It Cm RevokedKeys
1.154 djm 1041: Specifies revoked public keys.
1.118 djm 1042: Keys listed in this file will be refused for public key authentication.
1043: Note that if this file is not readable, then public key authentication will
1044: be refused for all users.
1.154 djm 1045: Keys may be specified as a text file, listing one public key per line, or as
1046: an OpenSSH Key Revocation List (KRL) as generated by
1.155 jmc 1047: .Xr ssh-keygen 1 .
1.154 djm 1048: For more information on KRLs, see the
1049: .Sx KEY REVOCATION LISTS
1050: section in
1051: .Xr ssh-keygen 1 .
1.1 stevesk 1052: .It Cm RhostsRSAAuthentication
1053: Specifies whether rhosts or /etc/hosts.equiv authentication together
1054: with successful RSA host authentication is allowed.
1055: The default is
1056: .Dq no .
1057: This option applies to protocol version 1 only.
1058: .It Cm RSAAuthentication
1059: Specifies whether pure RSA authentication is allowed.
1060: The default is
1061: .Dq yes .
1062: This option applies to protocol version 1 only.
1063: .It Cm ServerKeyBits
1064: Defines the number of bits in the ephemeral protocol version 1 server key.
1.96 djm 1065: The minimum value is 512, and the default is 1024.
1.1 stevesk 1066: .It Cm StrictModes
1067: Specifies whether
1.52 jmc 1068: .Xr sshd 8
1.1 stevesk 1069: should check file modes and ownership of the
1070: user's files and home directory before accepting login.
1071: This is normally desirable because novices sometimes accidentally leave their
1072: directory or files world-writable.
1073: The default is
1074: .Dq yes .
1.112 djm 1075: Note that this does not apply to
1076: .Cm ChrootDirectory ,
1077: whose permissions and ownership are checked unconditionally.
1.1 stevesk 1078: .It Cm Subsystem
1.51 jmc 1079: Configures an external subsystem (e.g. file transfer daemon).
1.59 djm 1080: Arguments should be a subsystem name and a command (with optional arguments)
1081: to execute upon subsystem request.
1.80 djm 1082: .Pp
1.1 stevesk 1083: The command
1084: .Xr sftp-server 8
1085: implements the
1086: .Dq sftp
1087: file transfer subsystem.
1.80 djm 1088: .Pp
1089: Alternately the name
1090: .Dq internal-sftp
1091: implements an in-process
1092: .Dq sftp
1093: server.
1094: This may simplify configurations using
1095: .Cm ChrootDirectory
1096: to force a different filesystem root on clients.
1097: .Pp
1.1 stevesk 1098: By default no subsystems are defined.
1099: Note that this option applies to protocol version 2 only.
1100: .It Cm SyslogFacility
1101: Gives the facility code that is used when logging messages from
1.53 jmc 1102: .Xr sshd 8 .
1.1 stevesk 1103: The possible values are: DAEMON, USER, AUTH, LOCAL0, LOCAL1, LOCAL2,
1104: LOCAL3, LOCAL4, LOCAL5, LOCAL6, LOCAL7.
1105: The default is AUTH.
1.27 markus 1106: .It Cm TCPKeepAlive
1107: Specifies whether the system should send TCP keepalive messages to the
1108: other side.
1109: If they are sent, death of the connection or crash of one
1110: of the machines will be properly noticed.
1111: However, this means that
1112: connections will die if the route is down temporarily, and some people
1113: find it annoying.
1114: On the other hand, if TCP keepalives are not sent,
1115: sessions may hang indefinitely on the server, leaving
1116: .Dq ghost
1117: users and consuming server resources.
1118: .Pp
1119: The default is
1120: .Dq yes
1121: (to send TCP keepalive messages), and the server will notice
1122: if the network goes down or the client host crashes.
1123: This avoids infinitely hanging sessions.
1124: .Pp
1125: To disable TCP keepalive messages, the value should be set to
1126: .Dq no .
1.118 djm 1127: .It Cm TrustedUserCAKeys
1128: Specifies a file containing public keys of certificate authorities that are
1.120 djm 1129: trusted to sign user certificates for authentication.
1.119 jmc 1130: Keys are listed one per line; empty lines and comments starting with
1.118 djm 1131: .Ql #
1132: are allowed.
1133: If a certificate is presented for authentication and has its signing CA key
1134: listed in this file, then it may be used for authentication for any user
1135: listed in the certificate's principals list.
1136: Note that certificates that lack a list of principals will not be permitted
1137: for authentication using
1138: .Cm TrustedUserCAKeys .
1.119 jmc 1139: For more details on certificates, see the
1.118 djm 1140: .Sx CERTIFICATES
1141: section in
1142: .Xr ssh-keygen 1 .
1.18 markus 1143: .It Cm UseDNS
1144: Specifies whether
1.52 jmc 1145: .Xr sshd 8
1.40 jmc 1146: should look up the remote host name and check that
1.18 markus 1147: the resolved host name for the remote IP address maps back to the
1148: very same IP address.
1149: The default is
1150: .Dq yes .
1.1 stevesk 1151: .It Cm UseLogin
1152: Specifies whether
1153: .Xr login 1
1154: is used for interactive login sessions.
1155: The default is
1156: .Dq no .
1157: Note that
1158: .Xr login 1
1159: is never used for remote command execution.
1160: Note also, that if this is enabled,
1161: .Cm X11Forwarding
1162: will be disabled because
1163: .Xr login 1
1164: does not know how to handle
1165: .Xr xauth 1
1.15 jmc 1166: cookies.
1167: If
1.1 stevesk 1168: .Cm UsePrivilegeSeparation
1169: is specified, it will be disabled after authentication.
1170: .It Cm UsePrivilegeSeparation
1171: Specifies whether
1.52 jmc 1172: .Xr sshd 8
1.2 stevesk 1173: separates privileges by creating an unprivileged child process
1.15 jmc 1174: to deal with incoming network traffic.
1175: After successful authentication, another process will be created that has
1176: the privilege of the authenticated user.
1177: The goal of privilege separation is to prevent privilege
1.1 stevesk 1178: escalation by containing any corruption within the unprivileged processes.
1179: The default is
1180: .Dq yes .
1.134 djm 1181: If
1182: .Cm UsePrivilegeSeparation
1183: is set to
1184: .Dq sandbox
1185: then the pre-authentication unprivileged process is subject to additional
1186: restrictions.
1.137 djm 1187: .It Cm VersionAddendum
1188: Optionally specifies additional text to append to the SSH protocol banner
1189: sent by the server upon connection.
1190: The default is
1191: .Dq none .
1.1 stevesk 1192: .It Cm X11DisplayOffset
1193: Specifies the first display number available for
1.52 jmc 1194: .Xr sshd 8 Ns 's
1.1 stevesk 1195: X11 forwarding.
1.52 jmc 1196: This prevents sshd from interfering with real X11 servers.
1.1 stevesk 1197: The default is 10.
1198: .It Cm X11Forwarding
1199: Specifies whether X11 forwarding is permitted.
1.13 stevesk 1200: The argument must be
1201: .Dq yes
1202: or
1203: .Dq no .
1.1 stevesk 1204: The default is
1205: .Dq no .
1.13 stevesk 1206: .Pp
1207: When X11 forwarding is enabled, there may be additional exposure to
1208: the server and to client displays if the
1.52 jmc 1209: .Xr sshd 8
1.13 stevesk 1210: proxy display is configured to listen on the wildcard address (see
1211: .Cm X11UseLocalhost
1.52 jmc 1212: below), though this is not the default.
1.13 stevesk 1213: Additionally, the authentication spoofing and authentication data
1214: verification and substitution occur on the client side.
1215: The security risk of using X11 forwarding is that the client's X11
1.52 jmc 1216: display server may be exposed to attack when the SSH client requests
1.13 stevesk 1217: forwarding (see the warnings for
1218: .Cm ForwardX11
1219: in
1.19 jmc 1220: .Xr ssh_config 5 ) .
1.13 stevesk 1221: A system administrator may have a stance in which they want to
1222: protect clients that may expose themselves to attack by unwittingly
1223: requesting X11 forwarding, which can warrant a
1224: .Dq no
1225: setting.
1226: .Pp
1227: Note that disabling X11 forwarding does not prevent users from
1228: forwarding X11 traffic, as users can always install their own forwarders.
1.1 stevesk 1229: X11 forwarding is automatically disabled if
1230: .Cm UseLogin
1231: is enabled.
1232: .It Cm X11UseLocalhost
1233: Specifies whether
1.52 jmc 1234: .Xr sshd 8
1.1 stevesk 1235: should bind the X11 forwarding server to the loopback address or to
1.15 jmc 1236: the wildcard address.
1237: By default,
1.52 jmc 1238: sshd binds the forwarding server to the loopback address and sets the
1.1 stevesk 1239: hostname part of the
1240: .Ev DISPLAY
1241: environment variable to
1242: .Dq localhost .
1.8 stevesk 1243: This prevents remote hosts from connecting to the proxy display.
1.1 stevesk 1244: However, some older X11 clients may not function with this
1245: configuration.
1246: .Cm X11UseLocalhost
1247: may be set to
1248: .Dq no
1249: to specify that the forwarding server should be bound to the wildcard
1250: address.
1251: The argument must be
1252: .Dq yes
1253: or
1254: .Dq no .
1255: The default is
1256: .Dq yes .
1257: .It Cm XAuthLocation
1.11 stevesk 1258: Specifies the full pathname of the
1.1 stevesk 1259: .Xr xauth 1
1260: program.
1261: The default is
1262: .Pa /usr/X11R6/bin/xauth .
1263: .El
1.55 jmc 1264: .Sh TIME FORMATS
1.53 jmc 1265: .Xr sshd 8
1.1 stevesk 1266: command-line arguments and configuration file options that specify time
1267: may be expressed using a sequence of the form:
1268: .Sm off
1.7 stevesk 1269: .Ar time Op Ar qualifier ,
1.1 stevesk 1270: .Sm on
1271: where
1272: .Ar time
1273: is a positive integer value and
1274: .Ar qualifier
1275: is one of the following:
1276: .Pp
1277: .Bl -tag -width Ds -compact -offset indent
1.64 jmc 1278: .It Aq Cm none
1.1 stevesk 1279: seconds
1280: .It Cm s | Cm S
1281: seconds
1282: .It Cm m | Cm M
1283: minutes
1284: .It Cm h | Cm H
1285: hours
1286: .It Cm d | Cm D
1287: days
1288: .It Cm w | Cm W
1289: weeks
1290: .El
1291: .Pp
1292: Each member of the sequence is added together to calculate
1293: the total time value.
1294: .Pp
1295: Time format examples:
1296: .Pp
1297: .Bl -tag -width Ds -compact -offset indent
1298: .It 600
1299: 600 seconds (10 minutes)
1300: .It 10m
1301: 10 minutes
1302: .It 1h30m
1303: 1 hour 30 minutes (90 minutes)
1304: .El
1305: .Sh FILES
1306: .Bl -tag -width Ds
1307: .It Pa /etc/ssh/sshd_config
1308: Contains configuration data for
1.53 jmc 1309: .Xr sshd 8 .
1.1 stevesk 1310: This file should be writable by root only, but it is recommended
1311: (though not necessary) that it be world-readable.
1312: .El
1.19 jmc 1313: .Sh SEE ALSO
1314: .Xr sshd 8
1.1 stevesk 1315: .Sh AUTHORS
1316: OpenSSH is a derivative of the original and free
1317: ssh 1.2.12 release by Tatu Ylonen.
1318: Aaron Campbell, Bob Beck, Markus Friedl, Niels Provos,
1319: Theo de Raadt and Dug Song
1320: removed many bugs, re-added newer features and
1321: created OpenSSH.
1322: Markus Friedl contributed the support for SSH
1323: protocol versions 1.5 and 2.0.
1324: Niels Provos and Markus Friedl contributed support
1325: for privilege separation.