{"id":8232,"date":"2026-03-14T11:00:28","date_gmt":"2026-03-14T11:00:28","guid":{"rendered":"https:\/\/commandlinux.com\/?p=8232"},"modified":"2026-05-18T14:48:25","modified_gmt":"2026-05-18T14:48:25","slug":"ssh-2","status":"publish","type":"post","link":"https:\/\/commandlinux.com\/man-page\/man1\/ssh\/","title":{"rendered":"SSH"},"content":{"rendered":"\n<link rel=\"stylesheet\" href=\"https:\/\/wordpress-541078-6199923.cloudwaysapps.com\/wp-content\/themes\/smart-mag\/man-style.css\"><script>document.title = \"SSH linux command man page\";<\/script><div class='man-page' style='max-width:900px;margin:40px auto;'>\n\n<A NAME=\"lbAB\">&nbsp;<\/A>\n<H2>NAME<\/H2>\n\n\n\n<B>ssh<\/B>\n\n &#8211; OpenSSH SSH client (remote login program)\n\n<A NAME=\"lbAC\">&nbsp;<\/A>\n<H2>SYNOPSIS<\/H2>\n\n<B>ssh<\/B>\n\n-words\n\n[-<B>1246AaCfgKkMNnqsTtVvXxYy <\/B>[-<B>b <\/B><I>bind_address<\/I>\n\n\n\n]\n\n\n\n\n\n]\n\n[-<B>c <\/B><I>cipher_spec<\/I>\n\n\n\n]\n\n[-<B>D <\/B>[<I>bind_address : <\/I><B><\/B><I>port<\/I>\n\n\n\n]\n\n\n\n\n\n]\n\n[-<B>E <\/B><I>log_file<\/I>\n\n\n\n]\n\n[-<B>e <\/B><I>escape_char<\/I>\n\n\n\n]\n\n[-<B>F <\/B><I>configfile<\/I>\n\n\n\n]\n\n[-<B>I <\/B><I>pkcs11<\/I>\n\n\n\n]\n\n[-<B>i <\/B><I>identity_file<\/I>\n\n\n\n]\n\n[-<B>L <\/B>[<I>bind_address : <\/I><B><\/B><I>port : <\/I><B><\/B><I>host : <\/I><B><\/B><I>hostport<\/I>\n\n\n\n\n\n\n\n\n\n\n\n]\n\n\n\n\n\n]\n\n[-<B>l <\/B><I>login_name<\/I>\n\n\n\n]\n\n[-<B>m <\/B><I>mac_spec<\/I>\n\n\n\n]\n\n[-<B>O <\/B><I>ctl_cmd<\/I>\n\n\n\n]\n\n[-<B>o <\/B><I>option<\/I>\n\n\n\n]\n\n[-<B>p <\/B><I>port<\/I>\n\n\n\n]\n\n[-<B>Q cipher | cipher-auth | mac | kex | key<\/B>\n\n\n\n]\n\n[-<B>R <\/B>[<I>bind_address : <\/I><B><\/B><I>port : <\/I><B><\/B><I>host : <\/I><B><\/B><I>hostport<\/I>\n\n\n\n\n\n\n\n\n\n\n\n]\n\n\n\n\n\n]\n\n[-<B>S <\/B><I>ctl_path<\/I>\n\n\n\n]\n\n[-<B>W <\/B><I>host : <\/I><B><\/B><I>port<\/I>\n\n\n\n\n\n\n\n]\n\n[-<B>w <\/B><I>local_tun <\/I><B><\/B>[: <B><\/B><I>remote_tun<\/I>\n\n\n\n]\n\n\n\n\n\n\n\n]\n\n[<I>user <\/I><B>@ <\/B><I>hostname<\/I>\n\n\n\n]\n\n\n\n\n\n[<I>command<\/I>\n\n]\n\n<A NAME=\"lbAD\">&nbsp;<\/A>\n<H2>DESCRIPTION<\/H2>\n\n\n\n<B>ssh<\/B>\n\n\n(SSH client) is a program for logging into a remote machine and for\nexecuting commands on a remote machine.\nIt is intended to replace rlogin and rsh,\nand provide secure encrypted communications between\ntwo untrusted hosts over an insecure network.\nX11 connections, arbitrary TCP ports and\nUNIX\nsockets can also be forwarded over the secure channel.\n<P>\n\n<B>ssh<\/B>\n\n\nconnects and logs into the specified\n<I>hostname<\/I>\n\n(with optional\n<I>user<\/I>\n\nname).\nThe user must prove\nhis\/her identity to the remote machine using one of several methods\ndepending on the protocol version used (see below).\n<P>\n\nIf\n<I>command<\/I>\n\nis specified,\nit is executed on the remote host instead of a login shell.\n<P>\n\nThe options are as follows:\n<DL COMPACT>\n<P>\n\n<DT><B>-1<\/B>\n\n\n<DD>\nForces\n<B>ssh<\/B>\n\n\nto try protocol version 1 only.\n<DT><B>-2<\/B>\n\n\n<DD>\nForces\n<B>ssh<\/B>\n\n\nto try protocol version 2 only.\n<DT><B>-4<\/B>\n\n\n<DD>\nForces\n<B>ssh<\/B>\n\n\nto use IPv4 addresses only.\n<DT><B>-6<\/B>\n\n\n<DD>\nForces\n<B>ssh<\/B>\n\n\nto use IPv6 addresses only.\n<DT><B>-A<\/B>\n\n\n<DD>\nEnables forwarding of the authentication agent connection.\nThis can also be specified on a per-host basis in a configuration file.\n<P>\n\nAgent forwarding should be enabled with caution.\nUsers with the ability to bypass file permissions on the remote host\n(for the agent&#8217;s\nUNIX\nsocket) can access the local agent through the forwarded connection.\nAn attacker cannot obtain key material from the agent,\nhowever they can perform operations on the keys that enable them to\nauthenticate using the identities loaded into the agent.\n<DT><B>-a<\/B>\n\n\n<DD>\nDisables forwarding of the authentication agent connection.\n<DT><B>-b <\/B><I>bind_address<\/I>\n\n\n\n\n<DD>\nUse\n<I>bind_address<\/I>\n\non the local machine as the source address\nof the connection.\nOnly useful on systems with more than one address.\n<DT><B>-C<\/B>\n\n\n<DD>\nRequests compression of all data (including stdin, stdout, stderr, and\ndata for forwarded X11, TCP and\nUNIX\nconnections).\nThe compression algorithm is the same used by\n<B>gzip<\/B>(1),\n\n\nand the\n&#8220;level&#8221;\n\ncan be controlled by the\n<B>CompressionLevel<\/B>\n\noption for protocol version 1.\nCompression is desirable on modem lines and other\nslow connections, but will only slow down things on fast networks.\nThe default value can be set on a host-by-host basis in the\nconfiguration files; see the\n<B>Compression<\/B>\n\noption.\n<DT><B>-c <\/B><I>cipher_spec<\/I>\n\n\n\n\n<DD>\nSelects the cipher specification for encrypting the session.\n<P>\n\nProtocol version 1 allows specification of a single cipher.\nThe supported values are\n&#8220;3des&#8221;\n\n \n&#8220;blowfish&#8221;\n\n \nand\n&#8220;des&#8221;\n\n \nFor protocol version 2,\n<I>cipher_spec<\/I>\n\nis a comma-separated list of ciphers\nlisted in order of preference.\nSee the\n<B>Ciphers<\/B>\n\nkeyword in\nssh_config5\n\n\nfor more information.\n<DT><B>-D \n<\/B>\n\n\n\n\n[<I>bind_address : <\/I>]\n\n\n\n<I>port<\/I>\n\n\n<DD>\n\n<DD>Specifies a local\n&#8220;dynamic&#8221;\n\napplication-level port forwarding.\nThis works by allocating a socket to listen to\n<I>port<\/I>\n\non the local side, optionally bound to the specified\n<I>bind_address<\/I>\n\n \nWhenever a connection is made to this port, the\nconnection is forwarded over the secure channel, and the application\nprotocol is then used to determine where to connect to from the\nremote machine.\nCurrently the SOCKS4 and SOCKS5 protocols are supported, and\n<B>ssh<\/B>\n\n\nwill act as a SOCKS server.\nOnly root can forward privileged ports.\nDynamic port forwardings can also be specified in the configuration file.\n<P>\n\nIPv6 addresses can be specified by enclosing the address in square brackets.\nOnly the superuser can forward privileged ports.\nBy default, the local port is bound in accordance with the\n<B>GatewayPorts<\/B>\n\nsetting.\nHowever, an explicit\n<I>bind_address<\/I>\n\nmay be used to bind the connection to a specific address.\nThe\n<I>bind_address<\/I>\n\nof\n&#8220;localhost&#8221;\n\nindicates that the listening port be bound for local use only, while an\nempty address or\n`*&#8217;\n\nindicates that the port should be available from all interfaces.\n<DT><B>-E <\/B><I>log_file<\/I>\n\n\n\n\n<DD>\nAppend debug logs to\n<I>log_file<\/I>\n\ninstead of standard error.\n<DT><B>-e <\/B><I>escape_char<\/I>\n\n\n\n\n<DD>\nSets the escape character for sessions with a pty (default:\n`~&#8217;\n\n) .\nThe escape character is only recognized at the beginning of a line.\nThe escape character followed by a dot\n(`.&#8217;\n\n)\n\ncloses the connection;\nfollowed by control-Z suspends the connection;\nand followed by itself sends the escape character once.\nSetting the character to\n&#8220;none&#8221;\n\ndisables any escapes and makes the session fully transparent.\n<DT><B>-F <\/B><I>configfile<\/I>\n\n\n\n\n<DD>\nSpecifies an alternative per-user configuration file.\nIf a configuration file is given on the command line,\nthe system-wide configuration file\n(\/etc\/ssh\/ssh_config\n\n)\n\nwill be ignored.\nThe default for the per-user configuration file is\n~\/.ssh\/config\n\n \n<DT><B>-f<\/B>\n\n\n<DD>\nRequests\n<B>ssh<\/B>\n\n\nto go to background just before command execution.\nThis is useful if\n<B>ssh<\/B>\n\n\nis going to ask for passwords or passphrases, but the user\nwants it in the background.\nThis implies\n&#8211;<B>n<\/B>\n\n \nThe recommended way to start X11 programs at a remote site is with\nsomething like\n<B>ssh -f host xterm<\/B>\n\n \n<P>\n\nIf the\n<B>ExitOnForwardFailure<\/B>\n\nconfiguration option is set to\n&#8220;yes&#8221;\n\n \nthen a client started with\n&#8211;<B>f<\/B>\n\nwill wait for all remote port forwards to be successfully established\nbefore placing itself in the background.\n<DT><B>-g<\/B>\n\n\n<DD>\nAllows remote hosts to connect to local forwarded ports.\nIf used on a multiplexed connection, then this option must be specified\non the master process.\n<DT><B>-I <\/B><I>pkcs11<\/I>\n\n\n\n\n<DD>\nSpecify the PKCS#11 shared library\n<B>ssh<\/B>\n\n\nshould use to communicate with a PKCS#11 token providing the user&#8217;s\nprivate RSA key.\n<DT><B>-i <\/B><I>identity_file<\/I>\n\n\n\n\n<DD>\nSelects a file from which the identity (private key) for\npublic key authentication is read.\nThe default is\n~\/.ssh\/identity\n\nfor protocol version 1, and\n~\/.ssh\/id_dsa\n\n \n~\/.ssh\/id_ecdsa\n\n \n~\/.ssh\/id_ed25519\n\nand\n~\/.ssh\/id_rsa\n\nfor protocol version 2.\nIdentity files may also be specified on\na per-host basis in the configuration file.\nIt is possible to have multiple\n&#8211;<B>i<\/B>\n\noptions (and multiple identities specified in\nconfiguration files).\n<B>ssh<\/B>\n\n\nwill also try to load certificate information from the filename obtained\nby appending\n-cert.pub\n\nto identity filenames.\n<DT><B>-K<\/B>\n\n\n<DD>\nEnables GSSAPI-based authentication and forwarding (delegation) of GSSAPI\ncredentials to the server.\n<DT><B>-k<\/B>\n\n\n<DD>\nDisables forwarding (delegation) of GSSAPI credentials to the server.\n<DT><B>-L \n<\/B>\n\n\n\n\n[<I>bind_address : <\/I>]\n\n\n\n<I>port : host : hostport<\/I>\n\n\n<DD>\n\n<DD>Specifies that the given port on the local (client) host is to be\nforwarded to the given host and port on the remote side.\nThis works by allocating a socket to listen to\n<I>port<\/I>\n\non the local side, optionally bound to the specified\n<I>bind_address<\/I>\n\n \nWhenever a connection is made to this port, the\nconnection is forwarded over the secure channel, and a connection is\nmade to\n<I>host<\/I>\n\nport\n<I>hostport<\/I>\n\nfrom the remote machine.\nPort forwardings can also be specified in the configuration file.\nIPv6 addresses can be specified by enclosing the address in square brackets.\nOnly the superuser can forward privileged ports.\nBy default, the local port is bound in accordance with the\n<B>GatewayPorts<\/B>\n\nsetting.\nHowever, an explicit\n<I>bind_address<\/I>\n\nmay be used to bind the connection to a specific address.\nThe\n<I>bind_address<\/I>\n\nof\n&#8220;localhost&#8221;\n\nindicates that the listening port be bound for local use only, while an\nempty address or\n`*&#8217;\n\nindicates that the port should be available from all interfaces.\n<DT><B>-l <\/B><I>login_name<\/I>\n\n\n\n\n<DD>\nSpecifies the user to log in as on the remote machine.\nThis also may be specified on a per-host basis in the configuration file.\n<DT><B>-M<\/B>\n\n\n<DD>\nPlaces the\n<B>ssh<\/B>\n\n\nclient into\n&#8220;master&#8221;\n\nmode for connection sharing.\nMultiple\n&#8211;<B>M<\/B>\n\noptions places\n<B>ssh<\/B>\n\n\ninto\n&#8220;master&#8221;\n\nmode with confirmation required before slave connections are accepted.\nRefer to the description of\n<B>ControlMaster<\/B>\n\nin\nssh_config5\n\n\nfor details.\n<DT><B>-m <\/B><I>mac_spec<\/I>\n\n\n\n\n<DD>\nAdditionally, for protocol version 2 a comma-separated list of MAC\n(message authentication code) algorithms can\nbe specified in order of preference.\nSee the\n<B>MACs <\/B>keyword for more information.\n\n\n\n<DT><B>-N<\/B>\n\n\n<DD>\nDo not execute a remote command.\nThis is useful for just forwarding ports\n(protocol version 2 only).\n<DT><B>-n<\/B>\n\n\n<DD>\nRedirects stdin from\n\/dev\/null\n\n(actually, prevents reading from stdin).\nThis must be used when\n<B>ssh<\/B>\n\n\nis run in the background.\nA common trick is to use this to run X11 programs on a remote machine.\nFor example,\n<B>ssh -n shadows.cs.hut.fi emacs<\/B>\n\n \nwill start an emacs on shadows.cs.hut.fi, and the X11\nconnection will be automatically forwarded over an encrypted channel.\nThe\n<B>ssh<\/B>\n\n\nprogram will be put in the background.\n(This does not work if\n<B>ssh<\/B>\n\n\nneeds to ask for a password or passphrase; see also the\n&#8211;<B>f<\/B>\n\noption.)\n<DT><B>-O <\/B><I>ctl_cmd<\/I>\n\n\n\n\n<DD>\nControl an active connection multiplexing master process.\nWhen the\n&#8211;<B>O<\/B>\n\noption is specified, the\n<I>ctl_cmd<\/I>\n\nargument is interpreted and passed to the master process.\nValid commands are:\n&#8220;check&#8221;\n\n(check that the master process is running),\n&#8220;forward&#8221;\n\n(request forwardings without command execution),\n&#8220;cancel&#8221;\n\n(cancel forwardings),\n&#8220;exit&#8221;\n\n(request the master to exit), and\n&#8220;stop&#8221;\n\n(request the master to stop accepting further multiplexing requests).\n<DT><B>-o <\/B><I>option<\/I>\n\n\n\n\n<DD>\nCan be used to give options in the format used in the configuration file.\nThis is useful for specifying options for which there is no separate\ncommand-line flag.\nFor full details of the options listed below, and their possible values, see\nssh_config5.\n\n\n<P>\n\n<DL COMPACT>\n<P>\n\n<DT><B>AddressFamily<\/B>\n<DD>\n<DT><B>BatchMode<\/B>\n<DD>\n<DT><B>BindAddress<\/B>\n<DD>\n<DT><B>CanonicalDomains<\/B>\n<DD>\n<DT><B>CanonicalizeFallbackLocal<\/B>\n<DD>\n<DT><B>CanonicalizeHostname<\/B>\n<DD>\n<DT><B>CanonicalizeMaxDots<\/B>\n<DD>\n<DT><B>CanonicalizePermittedCNAMEs <\/B><DT><B>ChallengeResponseAuthentication<\/B>\n<DD>\n\n\n\n<DD>\n<DT><B>CheckHostIP<\/B>\n<DD>\n<DT><B>Cipher<\/B>\n<DD>\n<DT><B>Ciphers<\/B>\n<DD>\n<DT><B>ClearAllForwardings<\/B>\n<DD>\n<DT><B>Compression<\/B>\n<DD>\n<DT><B>CompressionLevel<\/B>\n<DD>\n<DT><B>ConnectionAttempts<\/B>\n<DD>\n<DT><B>ConnectTimeout<\/B>\n<DD>\n<DT><B>ControlMaster<\/B>\n<DD>\n<DT><B>ControlPath<\/B>\n<DD>\n<DT><B>ControlPersist<\/B>\n<DD>\n<DT><B>DynamicForward<\/B>\n<DD>\n<DT><B>EscapeChar<\/B>\n<DD>\n<DT><B>ExitOnForwardFailure<\/B>\n<DD>\n<DT><B>ForwardAgent<\/B>\n<DD>\n<DT><B>ForwardX11<\/B>\n<DD>\n<DT><B>ForwardX11Timeout<\/B>\n<DD>\n<DT><B>ForwardX11Trusted<\/B>\n<DD>\n<DT><B>GatewayPorts<\/B>\n<DD>\n<DT><B>GlobalKnownHostsFile<\/B>\n<DD>\n<DT><B>GSSAPIAuthentication<\/B>\n<DD>\n<DT><B>GSSAPIDelegateCredentials<\/B>\n<DD>\n<DT><B>HashKnownHosts<\/B>\n<DD>\n<DT><B>Host<\/B>\n<DD>\n<DT><B>HostbasedAuthentication<\/B>\n<DD>\n<DT><B>HostKeyAlgorithms<\/B>\n<DD>\n<DT><B>HostKeyAlias<\/B>\n<DD>\n<DT><B>HostName<\/B>\n<DD>\n<DT><B>IdentityFile<\/B>\n<DD>\n<DT><B>IdentitiesOnly<\/B>\n<DD>\n<DT><B>IPQoS<\/B>\n<DD>\n<DT><B>KbdInteractiveAuthentication<\/B>\n<DD>\n<DT><B>KbdInteractiveDevices<\/B>\n<DD>\n<DT><B>KexAlgorithms<\/B>\n<DD>\n<DT><B>LocalCommand<\/B>\n<DD>\n<DT><B>LocalForward<\/B>\n<DD>\n<DT><B>LogLevel<\/B>\n<DD>\n<DT><B>MACs <\/B><DT><B>Match<\/B>\n<DD>\n\n\n\n<DD>\n<DT><B>NoHostAuthenticationForLocalhost<\/B>\n<DD>\n<DT><B>NumberOfPasswordPrompts<\/B>\n<DD>\n<DT><B>PasswordAuthentication<\/B>\n<DD>\n<DT><B>PermitLocalCommand<\/B>\n<DD>\n<DT><B>PKCS11Provider<\/B>\n<DD>\n<DT><B>Port<\/B>\n<DD>\n<DT><B>PreferredAuthentications<\/B>\n<DD>\n<DT><B>Protocol<\/B>\n<DD>\n<DT><B>ProxyCommand<\/B>\n<DD>\n<DT><B>ProxyUseFdpass<\/B>\n<DD>\n<DT><B>PubkeyAuthentication<\/B>\n<DD>\n<DT><B>RekeyLimit<\/B>\n<DD>\n<DT><B>RemoteForward<\/B>\n<DD>\n<DT><B>RequestTTY<\/B>\n<DD>\n<DT><B>RhostsRSAAuthentication<\/B>\n<DD>\n<DT><B>RSAAuthentication<\/B>\n<DD>\n<DT><B>SendEnv<\/B>\n<DD>\n<DT><B>ServerAliveInterval<\/B>\n<DD>\n<DT><B>ServerAliveCountMax<\/B>\n<DD>\n<DT><B>StreamLocalBindMask<\/B>\n<DD>\n<DT><B>StreamLocalBindUnlink<\/B>\n<DD>\n<DT><B>StrictHostKeyChecking<\/B>\n<DD>\n<DT><B>TCPKeepAlive<\/B>\n<DD>\n<DT><B>Tunnel<\/B>\n<DD>\n<DT><B>TunnelDevice<\/B>\n<DD>\n<DT><B>UsePrivilegedPort<\/B>\n<DD>\n<DT><B>User<\/B>\n<DD>\n<DT><B>UserKnownHostsFile<\/B>\n<DD>\n<DT><B>VerifyHostKeyDNS<\/B>\n<DD>\n<DT><B>VisualHostKey<\/B>\n<DD>\n<DT><B>XAuthLocation<\/B>\n<DD>\n<\/DL>\n<P>\n\n<DT><B>-p <\/B><I>port<\/I>\n\n\n\n\n<DD>\nPort to connect to on the remote host.\nThis can be specified on a\nper-host basis in the configuration file.\n<DT><B>-Q cipher | cipher-auth | mac | kex | key<\/B>\n\n\n\n\n<DD>\nQueries\n<B>ssh<\/B>\n\n\nfor the algorithms supported for the specified version 2.\nThe available features are:\n<I>cipher<\/I>\n\n(supported symmetric ciphers),\n<I>cipher-auth<\/I>\n\n(supported symmetric ciphers that support authenticated encryption),\n<I>mac<\/I>\n\n(supported message integrity codes),\n<I>kex<\/I>\n\n(key exchange algorithms),\n<I>key<\/I>\n\n(key types).\n<DT><B>-q<\/B>\n\n\n<DD>\nQuiet mode.\nCauses most warning and diagnostic messages to be suppressed.\n<DT><B>-R \n<\/B>\n\n\n\n\n[<I>bind_address : <\/I>]\n\n\n\n<I>port : host : hostport<\/I>\n\n\n<DD>\n\n<DD>Specifies that the given port on the remote (server) host is to be\nforwarded to the given host and port on the local side.\nThis works by allocating a socket to listen to\n<I>port<\/I>\n\non the remote side, and whenever a connection is made to this port, the\nconnection is forwarded over the secure channel, and a connection is\nmade to\n<I>host<\/I>\n\nport\n<I>hostport<\/I>\n\nfrom the local machine.\n<P>\n\nPort forwardings can also be specified in the configuration file.\nPrivileged ports can be forwarded only when\nlogging in as root on the remote machine.\nIPv6 addresses can be specified by enclosing the address in square brackets.\n<P>\n\nBy default, the listening socket on the server will be bound to the loopback\ninterface only.\nThis may be overridden by specifying a\n<I>bind_address<\/I>\n\n \nAn empty\n<I>bind_address<\/I>\n\n \nor the address\n`*&#8217;\n\n,\nindicates that the remote socket should listen on all interfaces.\nSpecifying a remote\n<I>bind_address<\/I>\n\nwill only succeed if the server&#8217;s\n<B>GatewayPorts<\/B>\n\noption is enabled (see\nsshd_config5).\n\n\n<P>\n\nIf the\n<I>port<\/I>\n\nargument is\n`0&#8242;\n\n,\nthe listen port will be dynamically allocated on the server and reported\nto the client at run time.\nWhen used together with\n<B>-O forward<\/B>\n\nthe allocated port will be printed to the standard output.\n<DT><B>-S <\/B><I>ctl_path<\/I>\n\n\n\n\n<DD>\nSpecifies the location of a control socket for connection sharing,\nor the string\n&#8220;none&#8221;\n\nto disable connection sharing.\nRefer to the description of\n<B>ControlPath<\/B>\n\nand\n<B>ControlMaster<\/B>\n\nin\nssh_config5\n\n\nfor details.\n<DT><B>-s<\/B>\n\n\n<DD>\nMay be used to request invocation of a subsystem on the remote system.\nSubsystems are a feature of the SSH2 protocol which facilitate the use\nof SSH as a secure transport for other applications (eg.\n<B>sftp<\/B>(1)).\n\n\nThe subsystem is specified as the remote command.\n<DT><B>-T<\/B>\n\n\n<DD>\nDisable pseudo-tty allocation.\n<DT><B>-t<\/B>\n\n\n<DD>\nForce pseudo-tty allocation.\nThis can be used to execute arbitrary\nscreen-based programs on a remote machine, which can be very useful,\ne.g. when implementing menu services.\nMultiple\n&#8211;<B>t<\/B>\n\noptions force tty allocation, even if\n<B>ssh<\/B>\n\n\nhas no local tty.\n<DT><B>-V<\/B>\n\n\n<DD>\nDisplay the version number and exit.\n<DT><B>-v<\/B>\n\n\n<DD>\nVerbose mode.\nCauses\n<B>ssh<\/B>\n\n\nto print debugging messages about its progress.\nThis is helpful in\ndebugging connection, authentication, and configuration problems.\nMultiple\n&#8211;<B>v<\/B>\n\noptions increase the verbosity.\nThe maximum is 3.\n<DT><B>-W <\/B><I>host : <\/I><B><\/B><I>port<\/I>\n\n\n\n\n\n\n\n\n<DD>\nRequests that standard input and output on the client be forwarded to\n<I>host<\/I>\n\non\n<I>port<\/I>\n\nover the secure channel.\nImplies\n&#8211;<B>N<\/B>\n\n \n&#8211;<B>T<\/B>\n\n \n<B>ExitOnForwardFailure<\/B>\n\nand\n<B>ClearAllForwardings<\/B>\n\n \nWorks with Protocol version 2 only.\n<DT><B>-w \n<\/B>\n\n\n\n<I>local_tun <\/I><B><\/B>[: <B><\/B><I>remote_tun<\/I>\n\n\n\n]\n\n\n\n\n\n<DD>\n\n<DD>Requests\ntunnel\ndevice forwarding with the specified\n<B>tun<\/B>(4)\n\n\ndevices between the client\n(<I>local_tun<\/I>\n\n)\n\nand the server\n(<I>remote_tun<\/I>\n\n)\n\n \n<P>\n\nThe devices may be specified by numerical ID or the keyword\n&#8220;any&#8221;\n\n \nwhich uses the next available tunnel device.\nIf\n<I>remote_tun<\/I>\n\nis not specified, it defaults to\n&#8220;any&#8221;\n\n \nSee also the\n<B>Tunnel<\/B>\n\nand\n<B>TunnelDevice<\/B>\n\ndirectives in\nssh_config5.\n\n\nIf the\n<B>Tunnel<\/B>\n\ndirective is unset, it is set to the default tunnel mode, which is\n&#8220;point-to-point&#8221;\n\n \n<DT><B>-X<\/B>\n\n\n<DD>\nEnables X11 forwarding.\nThis can also be specified on a per-host basis in a configuration file.\n<P>\n\nX11 forwarding should be enabled with caution.\nUsers with the ability to bypass file permissions on the remote host\n(for the user&#8217;s X authorization database)\ncan access the local X11 display through the forwarded connection.\nAn attacker may then be able to perform activities such as keystroke monitoring.\n<P>\n\nFor this reason, X11 forwarding is subjected to X11 SECURITY extension\nrestrictions by default.\nPlease refer to the\n<B>ssh<\/B>\n\n\n&#8211;<B>Y<\/B>\n\noption and the\n<B>ForwardX11Trusted<\/B>\n\ndirective in\nssh_config5\n\n\nfor more information.\n<DT><B>-x<\/B>\n\n\n<DD>\nDisables X11 forwarding.\n<DT><B>-Y<\/B>\n\n\n<DD>\nEnables trusted X11 forwarding.\nTrusted X11 forwardings are not subjected to the X11 SECURITY extension\ncontrols.\n<DT><B>-y<\/B>\n\n\n<DD>\nSend log information using the\n<B>syslog<\/B>(3)\n\n\nsystem module.\nBy default this information is sent to stderr.\n<\/DL>\n<P>\n\n<P>\n\n<B>ssh<\/B>\n\n\nmay additionally obtain configuration data from\na per-user configuration file and a system-wide configuration file.\nThe file format and configuration options are described in\nssh_config5.\n\n\n<A NAME=\"lbAE\">&nbsp;<\/A>\n<H2>AUTHENTICATION<\/H2>\n\nThe OpenSSH SSH client supports SSH protocols 1 and 2.\nThe default is to use protocol 2 only,\nthough this can be changed via the\n<B>Protocol<\/B>\n\noption in\nssh_config5\n\n\nor the\n&#8211;<B>1<\/B>\n\nand\n&#8211;<B>2<\/B>\n\noptions (see above).\nBoth protocols support similar authentication methods,\nbut protocol 2 is the default since\nit provides additional mechanisms for confidentiality\n(the traffic is encrypted using AES, 3DES, Blowfish, CAST128, or Arcfour)\nand integrity (hmac-md5, hmac-sha1,\nhmac-sha2-256, hmac-sha2-512,\numac-64, umac-128, hmac-ripemd160).\nProtocol 1 lacks a strong mechanism for ensuring the\nintegrity of the connection.\n<P>\n\nThe methods available for authentication are:\nGSSAPI-based authentication,\nhost-based authentication,\npublic key authentication,\nchallenge-response authentication,\nand password authentication.\nAuthentication methods are tried in the order specified above,\nthough protocol 2 has a configuration option to change the default order:\n<B>PreferredAuthentications<\/B>\n\n \n<P>\n\nHost-based authentication works as follows:\nIf the machine the user logs in from is listed in\n\/etc\/hosts.equiv\n\nor\n\/etc\/ssh\/shosts.equiv\n\non the remote machine, and the user names are\nthe same on both sides, or if the files\n~\/.rhosts\n\nor\n~\/.shosts\n\nexist in the user&#8217;s home directory on the\nremote machine and contain a line containing the name of the client\nmachine and the name of the user on that machine, the user is\nconsidered for login.\nAdditionally, the server\n<I>must<\/I>\n\nbe able to verify the client&#8217;s\nhost key (see the description of\n\/etc\/ssh\/ssh_known_hosts\n\nand\n~\/.ssh\/known_hosts\n\n \nbelow)\nfor login to be permitted.\nThis authentication method closes security holes due to IP\nspoofing, DNS spoofing, and routing spoofing.\n[Note to the administrator:\n\/etc\/hosts.equiv\n\n \n~\/.rhosts\n\n \nand the rlogin\/rsh protocol in general, are inherently insecure and should be\ndisabled if security is desired.]\n<P>\n\nPublic key authentication works as follows:\nThe scheme is based on public-key cryptography,\nusing cryptosystems\nwhere encryption and decryption are done using separate keys,\nand it is unfeasible to derive the decryption key from the encryption key.\nThe idea is that each user creates a public\/private\nkey pair for authentication purposes.\nThe server knows the public key, and only the user knows the private key.\n<B>ssh<\/B>\n\n\nimplements public key authentication protocol automatically,\nusing one of the DSA, ECDSA, ED25519 or RSA algorithms.\nProtocol 1 is restricted to using only RSA keys,\nbut protocol 2 may use any.\nThe HISTORY section of\n<B>ssl<\/B>(8)\n\n\n(on non-OpenBSD systems, see\n\nhttp:\/\/www.openbsd.org\/cgi-bin\/man.cgi?query=ssl&#038;sektion=8#HISTORY)\n\ncontains a brief discussion of the DSA and RSA algorithms.\n<P>\n\nThe file\n~\/.ssh\/authorized_keys\n\nlists the public keys that are permitted for logging in.\nWhen the user logs in, the\n<B>ssh<\/B>\n\n\nprogram tells the server which key pair it would like to use for\nauthentication.\nThe client proves that it has access to the private key\nand the server checks that the corresponding public key\nis authorized to accept the account.\n<P>\n\nThe user creates his\/her key pair by running\nssh-keygen1.\n\n\nThis stores the private key in\n~\/.ssh\/identity\n\n(protocol 1),\n~\/.ssh\/id_dsa\n\n(protocol 2 DSA),\n~\/.ssh\/id_ecdsa\n\n(protocol 2 ECDSA),\n~\/.ssh\/id_ed25519\n\n(protocol 2 ED25519),\nor\n~\/.ssh\/id_rsa\n\n(protocol 2 RSA)\nand stores the public key in\n~\/.ssh\/identity.pub\n\n(protocol 1),\n~\/.ssh\/id_dsa.pub\n\n(protocol 2 DSA),\n~\/.ssh\/id_ecdsa.pub\n\n(protocol 2 ECDSA),\n~\/.ssh\/id_ed25519.pub\n\n(protocol 2 ED25519),\nor\n~\/.ssh\/id_rsa.pub\n\n(protocol 2 RSA)\nin the user&#8217;s home directory.\nThe user should then copy the public key\nto\n~\/.ssh\/authorized_keys\n\nin his\/her home directory on the remote machine.\nThe\nauthorized_keys\n\nfile corresponds to the conventional\n~\/.rhosts\n\nfile, and has one key\nper line, though the lines can be very long.\nAfter this, the user can log in without giving the password.\n<P>\n\nA variation on public key authentication\nis available in the form of certificate authentication:\ninstead of a set of public\/private keys,\nsigned certificates are used.\nThis has the advantage that a single trusted certification authority\ncan be used in place of many public\/private keys.\nSee the CERTIFICATES section of\nssh-keygen1\n\n\nfor more information.\n<P>\n\nThe most convenient way to use public key or certificate authentication\nmay be with an authentication agent.\nSee\nssh-agent1\n\n\nfor more information.\n<P>\n\nChallenge-response authentication works as follows:\nThe server sends an arbitrary\nQq challenge\n\ntext, and prompts for a response.\nProtocol 2 allows multiple challenges and responses;\nprotocol 1 is restricted to just one challenge\/response.\nExamples of challenge-response authentication include\nBSD Authentication (see\nlogin.conf5)\n\n\nand PAM (some\nnon- Ox systems).\n\n\n\n<P>\n\nFinally, if other authentication methods fail,\n<B>ssh<\/B>\n\n\nprompts the user for a password.\nThe password is sent to the remote\nhost for checking; however, since all communications are encrypted,\nthe password cannot be seen by someone listening on the network.\n<P>\n\n<B>ssh<\/B>\n\n\nautomatically maintains and checks a database containing\nidentification for all hosts it has ever been used with.\nHost keys are stored in\n~\/.ssh\/known_hosts\n\nin the user&#8217;s home directory.\nAdditionally, the file\n\/etc\/ssh\/ssh_known_hosts\n\nis automatically checked for known hosts.\nAny new hosts are automatically added to the user&#8217;s file.\nIf a host&#8217;s identification ever changes,\n<B>ssh<\/B>\n\n\nwarns about this and disables password authentication to prevent\nserver spoofing or man-in-the-middle attacks,\nwhich could otherwise be used to circumvent the encryption.\nThe\n<B>StrictHostKeyChecking<\/B>\n\noption can be used to control logins to machines whose\nhost key is not known or has changed.\n<P>\n\nWhen the user&#8217;s identity has been accepted by the server, the server\neither executes the given command, or logs into the machine and gives\nthe user a normal shell on the remote machine.\nAll communication with\nthe remote command or shell will be automatically encrypted.\n<P>\n\nIf a pseudo-terminal has been allocated (normal login session), the\nuser may use the escape characters noted below.\n<P>\n\nIf no pseudo-tty has been allocated,\nthe session is transparent and can be used to reliably transfer binary data.\nOn most systems, setting the escape character to\n&#8220;none&#8221;\n\nwill also make the session transparent even if a tty is used.\n<P>\n\nThe session terminates when the command or shell on the remote\nmachine exits and all X11 and TCP connections have been closed.\n<A NAME=\"lbAF\">&nbsp;<\/A>\n<H2>ESCAPE CHARACTERS<\/H2>\n\nWhen a pseudo-terminal has been requested,\n<B>ssh<\/B>\n\n\nsupports a number of functions through the use of an escape character.\n<P>\n\nA single tilde character can be sent as\n<B>~~<\/B>\n\nor by following the tilde by a character other than those described below.\nThe escape character must always follow a newline to be interpreted as\nspecial.\nThe escape character can be changed in configuration files using the\n<B>EscapeChar<\/B>\n\nconfiguration directive or on the command line by the\n&#8211;<B>e<\/B>\n\noption.\n<P>\n\nThe supported escapes (assuming the default\n`~&#8217;\n\n)\nare:\n<DL COMPACT>\n<P>\n\n<DT><B>~.<\/B>\n\n\n<DD>\nDisconnect.\n<DT><B>~^Z<\/B>\n\n\n<DD>\nBackground\n<B>.<\/B>\n\n<DT><B>~#<\/B>\n\n\n<DD>\nList forwarded connections.\n<DT><B>~&amp;<\/B>\n\n\n<DD>\nBackground\n<B>ssh<\/B>\n\n\nat logout when waiting for forwarded connection \/ X11 sessions to terminate.\n<DT><B>~?<\/B>\n\n\n<DD>\nDisplay a list of escape characters.\n<DT><B>~B<\/B>\n\n\n<DD>\nSend a BREAK to the remote system\n(only useful for SSH protocol version 2 and if the peer supports it).\n<DT><B>~C<\/B>\n\n\n<DD>\nOpen command line.\nCurrently this allows the addition of port forwardings using the\n&#8211;<B>L<\/B>\n\n \n&#8211;<B>R<\/B>\n\nand\n&#8211;<B>D<\/B>\n\noptions (see above).\nIt also allows the cancellation of existing port-forwardings\nwith\n\n&#8211;<B>KL <\/B>[<I>bind_address : port<\/I>\n\n]\n\n\n\n\n\n\nfor local,\n\n&#8211;<B>KR <\/B>[<I>bind_address : port<\/I>\n\n]\n\n\n\n\n\n\nfor remote and\n\n&#8211;<B>KD <\/B>[<I>bind_address : port<\/I>\n\n]\n\n\n\n\n\n\nfor dynamic port-forwardings.\n<B>! <\/B><I>command<\/I>\n\n\n\n\n\nallows the user to execute a local command if the\n<B>PermitLocalCommand<\/B>\n\noption is enabled in\nssh_config5.\n\n\nBasic help is available, using the\n&#8211;<B>h<\/B>\n\noption.\n<DT><B>~R<\/B>\n\n\n<DD>\nRequest rekeying of the connection\n(only useful for SSH protocol version 2 and if the peer supports it).\n<DT><B>~V<\/B>\n\n\n<DD>\nDecrease the verbosity\n(<B>LogLevel<\/B>\n\n)\n\nwhen errors are being written to stderr.\n<DT><B>~v<\/B>\n\n\n<DD>\nIncrease the verbosity\n(<B>LogLevel<\/B>\n\n)\n\nwhen errors are being written to stderr.\n<\/DL>\n<P>\n\n<A NAME=\"lbAG\">&nbsp;<\/A>\n<H2>TCP FORWARDING<\/H2>\n\nForwarding of arbitrary TCP connections over the secure channel can\nbe specified either on the command line or in a configuration file.\nOne possible application of TCP forwarding is a secure connection to a\nmail server; another is going through firewalls.\n<P>\n\nIn the example below, we look at encrypting communication between\nan IRC client and server, even though the IRC server does not directly\nsupport encrypted communications.\nThis works as follows:\nthe user connects to the remote host using\n<B>,<\/B>\n\nspecifying a port to be used to forward connections\nto the remote server.\nAfter that it is possible to start the service which is to be encrypted\non the client machine,\nconnecting to the same local port,\nand\n<B>ssh<\/B>\n\n\nwill encrypt and forward the connection.\n<P>\n\nThe following example tunnels an IRC session from client machine\n&#8220;127.0.0.1&#8221;\n\n(localhost)\nto remote server\n&#8220;server.example.com&#8221;\n\n \n\n<PRE>\n$ ssh -f -L 1234:localhost:6667 server.example.com sleep 10\n$ irc -c &#8216;#users&#8217; -p 1234 pinky 127.0.0.1\n<\/PRE>\n\n<P>\n\nThis tunnels a connection to IRC server\n&#8220;server.example.com&#8221;\n\n \njoining channel\n&#8220;#users&#8221;\n\n \nnickname\n&#8220;pinky&#8221;\n\n \nusing port 1234.\nIt doesn&#8217;t matter which port is used,\nas long as it&#8217;s greater than 1023\n(remember, only root can open sockets on privileged ports)\nand doesn&#8217;t conflict with any ports already in use.\nThe connection is forwarded to port 6667 on the remote server,\nsince that&#8217;s the standard port for IRC services.\n<P>\n\nThe\n&#8211;<B>f<\/B>\n\noption backgrounds\n<B>ssh<\/B>\n\n\nand the remote command\n&#8220;sleep 10&#8221;\n\nis specified to allow an amount of time\n(10 seconds, in the example)\nto start the service which is to be tunnelled.\nIf no connections are made within the time specified,\n<B>ssh<\/B>\n\n\nwill exit.\n<A NAME=\"lbAH\">&nbsp;<\/A>\n<H2>X11 FORWARDING<\/H2>\n\nIf the\n<B>ForwardX11<\/B>\n\nvariable is set to\n&#8220;yes&#8221;\n\n(or see the description of the\n&#8211;<B>X<\/B>\n\n \n&#8211;<B>x<\/B>\n\n \nand\n&#8211;<B>Y<\/B>\n\noptions above)\nand the user is using X11 (the\n<B>DISPLAY<\/B>\n\nenvironment variable is set), the connection to the X11 display is\nautomatically forwarded to the remote side in such a way that any X11\nprograms started from the shell (or command) will go through the\nencrypted channel, and the connection to the real X server will be made\nfrom the local machine.\nThe user should not manually set\n<B>DISPLAY<\/B>\n\n \nForwarding of X11 connections can be\nconfigured on the command line or in configuration files.\n<P>\n\nThe\n<B>DISPLAY<\/B>\n\nvalue set by\n<B>ssh<\/B>\n\n\nwill point to the server machine, but with a display number greater than zero.\nThis is normal, and happens because\n<B>ssh<\/B>\n\n\ncreates a\n&#8220;proxy&#8221;\n\nX server on the server machine for forwarding the\nconnections over the encrypted channel.\n<P>\n\n<B>ssh<\/B>\n\n\nwill also automatically set up Xauthority data on the server machine.\nFor this purpose, it will generate a random authorization cookie,\nstore it in Xauthority on the server, and verify that any forwarded\nconnections carry this cookie and replace it by the real cookie when\nthe connection is opened.\nThe real authentication cookie is never\nsent to the server machine (and no cookies are sent in the plain).\n<P>\n\nIf the\n<B>ForwardAgent<\/B>\n\nvariable is set to\n&#8220;yes&#8221;\n\n(or see the description of the\n&#8211;<B>A<\/B>\n\nand\n&#8211;<B>a<\/B>\n\noptions above) and\nthe user is using an authentication agent, the connection to the agent\nis automatically forwarded to the remote side.\n<A NAME=\"lbAI\">&nbsp;<\/A>\n<H2>VERIFYING HOST KEYS<\/H2>\n\nWhen connecting to a server for the first time,\na fingerprint of the server&#8217;s public key is presented to the user\n(unless the option\n<B>StrictHostKeyChecking<\/B>\n\nhas been disabled).\nFingerprints can be determined using\nssh-keygen1:\n\n\n<P>\n\n\n<BLOCKQUOTE><TT>$ ssh-keygen -l -f \/etc\/ssh\/ssh_host_rsa_key<\/TT><\/BLOCKQUOTE>\n<P>\n\nIf the fingerprint is already known, it can be matched\nand the key can be accepted or rejected.\nBecause of the difficulty of comparing host keys\njust by looking at hex strings,\nthere is also support to compare host keys visually,\nusing\n<I>random art<\/I>\n\n \nBy setting the\n<B>VisualHostKey<\/B>\n\noption to\n&#8220;yes&#8221;\n\n \na small ASCII graphic gets displayed on every login to a server, no matter\nif the session itself is interactive or not.\nBy learning the pattern a known server produces, a user can easily\nfind out that the host key has changed when a completely different pattern\nis displayed.\nBecause these patterns are not unambiguous however, a pattern that looks\nsimilar to the pattern remembered only gives a good probability that the\nhost key is the same, not guaranteed proof.\n<P>\n\nTo get a listing of the fingerprints along with their random art for\nall known hosts, the following command line can be used:\n<P>\n\n\n<BLOCKQUOTE><TT>$ ssh-keygen -lv -f ~\/.ssh\/known_hosts<\/TT><\/BLOCKQUOTE>\n<P>\n\nIf the fingerprint is unknown,\nan alternative method of verification is available:\nSSH fingerprints verified by DNS.\nAn additional resource record (RR),\nSSHFP,\nis added to a zonefile\nand the connecting client is able to match the fingerprint\nwith that of the key presented.\n<P>\n\nIn this example, we are connecting a client to a server,\n&#8220;host.example.com&#8221;\n\n \nThe SSHFP resource records should first be added to the zonefile for\nhost.example.com:\n\n<BLOCKQUOTE>\n<PRE>\n$ ssh-keygen -r host.example.com.\n<\/PRE>\n<\/BLOCKQUOTE>\n\n<P>\n\nThe output lines will have to be added to the zonefile.\nTo check that the zone is answering fingerprint queries:\n<P>\n\n\n<BLOCKQUOTE><TT>$ dig -t SSHFP host.example.com<\/TT><\/BLOCKQUOTE>\n<P>\n\nFinally the client connects:\n\n<BLOCKQUOTE>\n<PRE>\n$ ssh -o &quot;VerifyHostKeyDNS ask&quot; host.example.com\n[&#8230;]\nMatching host key fingerprint found in DNS.\nAre you sure you want to continue connecting (yes\/no)?\n<\/PRE>\n<\/BLOCKQUOTE>\n\n<P>\n\nSee the\n<B>VerifyHostKeyDNS<\/B>\n\noption in\nssh_config5\n\n\nfor more information.\n<A NAME=\"lbAJ\">&nbsp;<\/A>\n<H2>SSH-BASED VIRTUAL PRIVATE NETWORKS<\/H2>\n\n<B>ssh<\/B>\n\n\ncontains support for Virtual Private Network (VPN) tunnelling\nusing the\n<B>tun<\/B>(4)\n\n\nnetwork pseudo-device,\nallowing two networks to be joined securely.\nThe\nsshd_config5\n\n\nconfiguration option\n<B>PermitTunnel<\/B>\n\ncontrols whether the server supports this,\nand at what level (layer 2 or 3 traffic).\n<P>\n\nThe following example would connect client network 10.0.50.0\/24\nwith remote network 10.0.99.0\/24 using a point-to-point connection\nfrom 10.1.1.1 to 10.1.1.2,\nprovided that the SSH server running on the gateway to the remote network,\nat 192.168.1.15, allows it.\n<P>\n\nOn the client:\n\n<BLOCKQUOTE>\n<PRE>\n# ssh -f -w 0:1 192.168.1.15 true\n# ifconfig tun0 10.1.1.1 10.1.1.2 netmask 255.255.255.252\n# route add 10.0.99.0\/24 10.1.1.2\n<\/PRE>\n<\/BLOCKQUOTE>\n\n<P>\n\nOn the server:\n\n<BLOCKQUOTE>\n<PRE>\n# ifconfig tun1 10.1.1.2 10.1.1.1 netmask 255.255.255.252\n# route add 10.0.50.0\/24 10.1.1.1\n<\/PRE>\n<\/BLOCKQUOTE>\n\n<P>\n\nClient access may be more finely tuned via the\n\/root\/.ssh\/authorized_keys\n\nfile (see below) and the\n<B>PermitRootLogin<\/B>\n\nserver option.\nThe following entry would permit connections on\n<B>tun<\/B>(4)\n\n\ndevice 1 from user\n&#8220;jane&#8221;\n\nand on tun device 2 from user\n&#8220;john&#8221;\n\n \nif\n<B>PermitRootLogin<\/B>\n\nis set to\n&#8220;forced-commands-only&#8221;\n\n \n\n<PRE>\ntunnel=&quot;1&quot;,command=&quot;sh \/etc\/netstart tun1&quot; ssh-rsa &#8230; jane\ntunnel=&quot;2&quot;,command=&quot;sh \/etc\/netstart tun2&quot; ssh-rsa &#8230; john\n<\/PRE>\n\n<P>\n\nSince an SSH-based setup entails a fair amount of overhead,\nit may be more suited to temporary setups,\nsuch as for wireless VPNs.\nMore permanent VPNs are better provided by tools such as\n<B>ipsecctl<\/B>(8)\n\n\nand\n<B>isakmpd<\/B>(8).\n\n\n<A NAME=\"lbAK\">&nbsp;<\/A>\n<H2>ENVIRONMENT<\/H2>\n\n<B>ssh<\/B>\n\n\nwill normally set the following environment variables:\n<DL COMPACT>\n<P>\n\n<DT><B>DISPLAY<\/B>\n\n\n<DD>\nThe\n<B>DISPLAY<\/B>\n\nvariable indicates the location of the X11 server.\nIt is automatically set by\n<B>ssh<\/B>\n\n\nto point to a value of the form\n&#8220;hostname:n&#8221;\n\n \nwhere\n&#8220;hostname&#8221;\n\nindicates the host where the shell runs, and\n`n&#8217;\n\nis an integer &#038;gt=; 1.\n<B>ssh<\/B>\n\n\nuses this special value to forward X11 connections over the secure\nchannel.\nThe user should normally not set\n<B>DISPLAY<\/B>\n\nexplicitly, as that\nwill render the X11 connection insecure (and will require the user to\nmanually copy any required authorization cookies).\n<DT><B>HOME<\/B>\n\n\n<DD>\nSet to the path of the user&#8217;s home directory.\n<DT><B>LOGNAME<\/B>\n\n\n<DD>\nSynonym for\n<B>USER<\/B>\n\n \nset for compatibility with systems that use this variable.\n<DT><B>MAIL<\/B>\n\n\n<DD>\nSet to the path of the user&#8217;s mailbox.\n<DT><B>PATH<\/B>\n\n\n<DD>\nSet to the default\n<B>PATH<\/B>\n\n \nas specified when compiling\n<B>.<\/B>\n\n<DT><B>SSH_ASKPASS<\/B>\n\n\n<DD>\nIf\n<B>ssh<\/B>\n\n\nneeds a passphrase, it will read the passphrase from the current\nterminal if it was run from a terminal.\nIf\n<B>ssh<\/B>\n\n\ndoes not have a terminal associated with it but\n<B>DISPLAY<\/B>\n\nand\n<B>SSH_ASKPASS<\/B>\n\nare set, it will execute the program specified by\n<B>SSH_ASKPASS<\/B>\n\nand open an X11 window to read the passphrase.\nThis is particularly useful when calling\n<B>ssh<\/B>\n\n\nfrom a\n.xsession\n\nor related script.\n(Note that on some machines it\nmay be necessary to redirect the input from\n\/dev\/null\n\nto make this work.)\n<DT><B>SSH_AUTH_SOCK<\/B>\n\n\n<DD>\nIdentifies the path of a\nUNIX\nsocket used to communicate with the agent.\n<DT><B>SSH_CONNECTION<\/B>\n\n\n<DD>\nIdentifies the client and server ends of the connection.\nThe variable contains\nfour space-separated values: client IP address, client port number,\nserver IP address, and server port number.\n<DT><B>SSH_ORIGINAL_COMMAND<\/B>\n\n\n<DD>\nThis variable contains the original command line if a forced command\nis executed.\nIt can be used to extract the original arguments.\n<DT><B>SSH_TTY<\/B>\n\n\n<DD>\nThis is set to the name of the tty (path to the device) associated\nwith the current shell or command.\nIf the current session has no tty,\nthis variable is not set.\n<DT><B>TZ<\/B>\n\n\n<DD>\nThis variable is set to indicate the present time zone if it\nwas set when the daemon was started (i.e. the daemon passes the value\non to new connections).\n<DT><B>USER<\/B>\n\n\n<DD>\nSet to the name of the user logging in.\n<\/DL>\n<P>\n\n<P>\n\nAdditionally,\n<B>ssh<\/B>\n\n\nreads\n~\/.ssh\/environment\n\n \nand adds lines of the format\n&#8220;VARNAME=value&#8221;\n\nto the environment if the file exists and users are allowed to\nchange their environment.\nFor more information, see the\n<B>PermitUserEnvironment<\/B>\n\noption in\nsshd_config5.\n\n\n<A NAME=\"lbAL\">&nbsp;<\/A>\n<H2>FILES<\/H2>\n\n<DL COMPACT>\n<P>\n\n<DT><B>~\/.rhosts\n\n<\/B>\n<DD>\nThis file is used for host-based authentication (see above).\nOn some machines this file may need to be\nworld-readable if the user&#8217;s home directory is on an NFS partition,\nbecause\n<B>sshd<\/B>(8)\n\n\nreads it as root.\nAdditionally, this file must be owned by the user,\nand must not have write permissions for anyone else.\nThe recommended\npermission for most machines is read\/write for the user, and not\naccessible by others.\n<P>\n\n<DT><B>~\/.shosts\n\n<\/B>\n<DD>\nThis file is used in exactly the same way as\n.rhosts\n\n \nbut allows host-based authentication without permitting login with\nrlogin\/rsh.\n<P>\n\n<DT><B>~\/.ssh\/\n\n<\/B>\n<DD>\nThis directory is the default location for all user-specific configuration\nand authentication information.\nThere is no general requirement to keep the entire contents of this directory\nsecret, but the recommended permissions are read\/write\/execute for the user,\nand not accessible by others.\n<P>\n\n<DT><B>~\/.ssh\/authorized_keys\n\n<\/B>\n<DD>\nLists the public keys (DSA, ECDSA, ED25519, RSA)\nthat can be used for logging in as this user.\nThe format of this file is described in the\n<B>sshd<\/B>(8)\n\n\nmanual page.\nThis file is not highly sensitive, but the recommended\npermissions are read\/write for the user, and not accessible by others.\n<P>\n\n<DT><B>~\/.ssh\/config\n\n<\/B>\n<DD>\nThis is the per-user configuration file.\nThe file format and configuration options are described in\nssh_config5.\n\n\nBecause of the potential for abuse, this file must have strict permissions:\nread\/write for the user, and not writable by others.\nIt may be group-writable provided that the group in question contains only\nthe user.\n<P>\n\n<DT><B>~\/.ssh\/environment\n\n<\/B>\n<DD>\nContains additional definitions for environment variables; see\nSx ENVIRONMENT ,\n\nabove.\n<P>\n\n<DT><B>~\/.ssh\/identity\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_dsa\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_ecdsa\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_ed25519\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_rsa\n\n<\/B>\n<DD>\nContains the private key for authentication.\nThese files\ncontain sensitive data and should be readable by the user but not\naccessible by others (read\/write\/execute).\n<B>ssh<\/B>\n\n\nwill simply ignore a private key file if it is accessible by others.\nIt is possible to specify a passphrase when\ngenerating the key which will be used to encrypt the\nsensitive part of this file using 3DES.\n<P>\n\n<DT><B>~\/.ssh\/identity.pub\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_dsa.pub\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_ecdsa.pub\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_ed25519.pub\n\n<\/B>\n<DD>\n<DT><B>~\/.ssh\/id_rsa.pub\n\n<\/B>\n<DD>\nContains the public key for authentication.\nThese files are not\nsensitive and can (but need not) be readable by anyone.\n<P>\n\n<DT><B>~\/.ssh\/known_hosts\n\n<\/B>\n<DD>\nContains a list of host keys for all hosts the user has logged into\nthat are not already in the systemwide list of known host keys.\nSee\n<B>sshd<\/B>(8)\n\n\nfor further details of the format of this file.\n<P>\n\n<DT><B>~\/.ssh\/rc\n\n<\/B>\n<DD>\nCommands in this file are executed by\n<B>ssh<\/B>\n\n\nwhen the user logs in, just before the user&#8217;s shell (or command) is\nstarted.\nSee the\n<B>sshd<\/B>(8)\n\n\nmanual page for more information.\n<P>\n\n<DT><B>\/etc\/hosts.equiv\n\n<\/B>\n<DD>\nThis file is for host-based authentication (see above).\nIt should only be writable by root.\n<P>\n\n<DT><B>\/etc\/ssh\/shosts.equiv\n\n<\/B>\n<DD>\nThis file is used in exactly the same way as\nhosts.equiv\n\n \nbut allows host-based authentication without permitting login with\nrlogin\/rsh.\n<P>\n\n<DT><B>\/etc\/ssh\/ssh_config\n\n<\/B>\n<DD>\nSystemwide configuration file.\nThe file format and configuration options are described in\nssh_config5.\n\n\n<P>\n\n<DT><B>\/etc\/ssh\/ssh_host_key\n\n<\/B>\n<DD>\n<DT><B>\/etc\/ssh\/ssh_host_dsa_key\n\n<\/B>\n<DD>\n<DT><B>\/etc\/ssh\/ssh_host_ecdsa_key\n\n<\/B>\n<DD>\n<DT><B>\/etc\/ssh\/ssh_host_ed25519_key\n\n<\/B>\n<DD>\n<DT><B>\/etc\/ssh\/ssh_host_rsa_key\n\n<\/B>\n<DD>\nThese files contain the private parts of the host keys\nand are used for host-based authentication.\nIf protocol version 1 is used,\n<B>ssh<\/B>\n\n\nmust be setuid root, since the host key is readable only by root.\nFor protocol version 2,\n<B>ssh<\/B>\n\n\nuses\nssh-keysign8\n\n\nto access the host keys,\neliminating the requirement that\n<B>ssh<\/B>\n\n\nbe setuid root when host-based authentication is used.\nBy default\n<B>ssh<\/B>\n\n\nis not setuid root.\n<P>\n\n<DT><B>\/etc\/ssh\/ssh_known_hosts\n\n<\/B>\n<DD>\nSystemwide list of known host keys.\nThis file should be prepared by the\nsystem administrator to contain the public host keys of all machines in the\norganization.\nIt should be world-readable.\nSee\n<B>sshd<\/B>(8)\n\n\nfor further details of the format of this file.\n<P>\n\n<DT><B>\/etc\/ssh\/sshrc\n\n<\/B>\n<DD>\nCommands in this file are executed by\n<B>ssh<\/B>\n\n\nwhen the user logs in, just before the user&#8217;s shell (or command) is started.\nSee the\n<B>sshd<\/B>(8)\n\n\nmanual page for more information.\n<\/DL>\n<P>\n\n<A NAME=\"lbAM\">&nbsp;<\/A>\n<H2>EXIT STATUS<\/H2>\n\n<B>ssh<\/B>\n\n\nexits with the exit status of the remote command or with 255\nif an error occurred.\n\n<A NAME=\"lbAO\">&nbsp;<\/A>\n<H2>STANDARDS<\/H2>\n\n<DL COMPACT><DT><DD>\nS. Lehtinen\nC. Lonvick\nJanuary 2006\n<I>RFC 4250<\/I>\n<I>The Secure Shell (SSH) Protocol Assigned Numbers<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nT. Ylonen\nC. Lonvick\nJanuary 2006\n<I>RFC 4251<\/I>\n<I>The Secure Shell (SSH) Protocol Architecture<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nT. Ylonen\nC. Lonvick\nJanuary 2006\n<I>RFC 4252<\/I>\n<I>The Secure Shell (SSH) Authentication Protocol<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nT. Ylonen\nC. Lonvick\nJanuary 2006\n<I>RFC 4253<\/I>\n<I>The Secure Shell (SSH) Transport Layer Protocol<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nT. Ylonen\nC. Lonvick\nJanuary 2006\n<I>RFC 4254<\/I>\n<I>The Secure Shell (SSH) Connection Protocol<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nJ. Schlyter\nW. Griffin\nJanuary 2006\n<I>RFC 4255<\/I>\n<I>Using DNS to Securely Publish Secure Shell (SSH) Key Fingerprints<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nF. Cusack\nM. Forssen\nJanuary 2006\n<I>RFC 4256<\/I>\n<I>Generic Message Exchange Authentication for the Secure Shell Protocol (SSH)<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nJ. Galbraith\nP. Remaker\nJanuary 2006\n<I>RFC 4335<\/I>\n<I>The Secure Shell (SSH) Session Channel Break Extension<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nM. Bellare\nT. Kohno\nC. Namprempre\nJanuary 2006\n<I>RFC 4344<\/I>\n<I>The Secure Shell (SSH) Transport Layer Encryption Modes<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nB. Harris\nJanuary 2006\n<I>RFC 4345<\/I>\n<I>Improved Arcfour Modes for the Secure Shell (SSH) Transport Layer Protocol<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nM. Friedl\nN. Provos\nW. Simpson\nMarch 2006\n<I>RFC 4419<\/I>\n<I>Diffie-Hellman Group Exchange for the Secure Shell (SSH) Transport Layer Protocol<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nJ. Galbraith\nR. Thayer\nNovember 2006\n<I>RFC 4716<\/I>\n<I>The Secure Shell (SSH) Public Key File Format<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nD. Stebila\nJ. Green\nDecember 2009\n<I>RFC 5656<\/I>\n<I>Elliptic Curve Algorithm Integration in the Secure Shell Transport Layer<\/I>\n<\/DL>\n\n<P>\n\n<DL COMPACT><DT><DD>\nA. Perrig\nD. Song\n1999\nInternational Workshop on Cryptographic Techniques and E-Commerce (CrypTEC &#8217;99)\n<I>Hash Visualization: a New Technique to improve Real-World Security<\/I>\n<\/DL>\n\n<A NAME=\"lbAP\">&nbsp;<\/A>\n<H2>AUTHORS<\/H2>\n\nOpenSSH is a derivative of the original and free\nssh 1.2.12 release by Tatu Ylonen.\nAaron Campbell, Bob Beck, Markus Friedl, Niels Provos,\nTheo de Raadt and Dug Song\nremoved many bugs, re-added newer features and\ncreated OpenSSH.\nMarkus Friedl contributed the support for SSH\nprotocol versions 1.5 and 2.0.\n<P>\n","protected":false},"excerpt":{"rendered":"<p>OpenSSH SSH client (remote login program)<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[53],"tags":[],"class_list":["post-8232","post","type-post","status-publish","format-standard","category-man-page"],"_links":{"self":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts\/8232","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/comments?post=8232"}],"version-history":[{"count":2,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts\/8232\/revisions"}],"predecessor-version":[{"id":11385,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/posts\/8232\/revisions\/11385"}],"wp:attachment":[{"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/media?parent=8232"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/categories?post=8232"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/commandlinux.com\/wp-json\/wp\/v2\/tags?post=8232"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}