{
    "content": [
        {
            "type": "text",
            "text": "# slogin(1) (man)\n\n**Summary:** ssh — OpenSSH remote login client\n\n**Synopsis:** ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bindinterface] [-b bindaddress] [-c cipherspec]\n[-D [bindaddress:]port] [-E logfile] [-e escapechar] [-F configfile] [-I pkcs11]\n[-i identityfile] [-J destination] [-L address] [-l loginname] [-m macspec] [-O ctlcmd]\n[-o option] [-p port] [-Q queryoption] [-R address] [-S ctlpath] [-W host:port]\n[-w localtun[:remotetun]] destination [command [argument ...]]\n\n## Flags\n\n| Flag | Long | Arg | Description |\n|------|------|-----|-------------|\n| -4 | — | — |  |\n| -6 | — | — |  |\n| -A | — | — | This can also be specified on a per-host basis in a configuration file. Agent forwarding should be enabled with caution. |\n| -a | — | — |  |\n| -B | — | — | Bind to the address of bindinterface before attempting to connect to the destination host. This is only useful on system |\n| -b | — | — | Use bindaddress on the local machine as the source address of the connection. Only useful on systems with more than one  |\n| -C | — | — | warded X11, TCP and UNIX-domain connections). The compression algorithm is the same used by gzip(1). Compression is desi |\n| -c | — | — | Selects the cipher specification for encrypting the session. cipherspec is a comma- separated list of ciphers listed in  |\n| -D | — | — | Specifies a local “dynamic” application-level port forwarding. This works by allocat‐ ing a socket to listen to port on  |\n| -E | — | — | Append debug logs to logfile instead of standard error. |\n| -e | — | — | Sets the escape character for sessions with a pty (default: ‘~’). The escape character is only recognized at the beginni |\n| -F | — | — | Specifies an alternative per-user configuration file. If a configuration file is given on the command line, the system-w |\n| -f | — | — | is going to ask for passwords or passphrases, but the user wants it in the background. This implies -n. The recommended  |\n| -G | — | — |  |\n| -g | — | — | nection, then this option must be specified on the master process. |\n| -I | — | — | Specify the PKCS#11 shared library ssh should use to communicate with a PKCS#11 token providing keys for user authentica |\n| -i | — | — | Selects a file from which the identity (private key) for public key authentication is read. You can also specify a publi |\n| -J | — | — | Connect to the target host by first making a ssh connection to the jump host described by destination and then establish |\n| -K | — | — | to the server. |\n| -k | — | — |  |\n| -L | — | — |  |\n| -L | — | — |  |\n| -L | — | — |  |\n| -L | — | — | Specifies that connections to the given TCP port or Unix socket on the local (client) host are to be forwarded to the gi |\n| -l | — | — | Specifies the user to log in as on the remote machine. This also may be specified on a per-host basis in the configurati |\n| -M | — | — | places ssh into “master” mode but with confirmation required using ssh-askpass(1) be‐ fore each operation that changes t |\n| -m | — | — | A comma-separated list of MAC (message authentication code) algorithms, specified in order of preference. See the MACs k |\n| -N | — | — | the description of SessionType in sshconfig(5) for details. |\n| -n | — | — | used when ssh is run in the background. A common trick is to use this to run X11 pro‐ grams on a remote machine. For exa |\n| -O | — | — | Control an active connection multiplexing master process. When the -O option is speci‐ fied, the ctlcmd argument is inte |\n| -o | — | — | Can be used to give options in the format used in the configuration file. This is use‐ ful for specifying options for wh |\n| -p | — | — | Port to connect to on the remote host. This can be specified on a per-host basis in the configuration file. |\n| -Q | — | — | Queries for the algorithms supported by one of the following features: cipher (sup‐ ported symmetric ciphers), cipher-au |\n| -q | — | — |  |\n| -R | — | — |  |\n| -R | — | — |  |\n| -R | — | — |  |\n| -R | — | — |  |\n| -R | — | — | Specifies that connections to the given TCP port or Unix socket on the remote (server) host are to be forwarded to the l |\n| -S | — | — | Specifies the location of a control socket for connection sharing, or the string “none” to disable connection sharing. R |\n| -s | — | — | cilitate the use of SSH as a secure transport for other applications (e.g. sftp(1)). The subsystem is specified as the r |\n| -T | — | — |  |\n| -t | — | — | programs on a remote machine, which can be very useful, e.g. when implementing menu services. Multiple -t options force  |\n| -V | — | — |  |\n| -v | — | — | helpful in debugging connection, authentication, and configuration problems. Multiple -v options increase the verbosity. |\n| -W | — | — | Requests that standard input and output on the client be forwarded to host on port over the secure channel. Implies -N,  |\n| -w | — | — | Requests tunnel device forwarding with the specified tun(4) devices between the client (localtun) and the server (remote |\n| -X | — | — | tion file. X11 forwarding should be enabled with caution. Users with the ability to bypass file permissions on the remot |\n| -x | — | — |  |\n| -Y | — | — | SECURITY extension controls. (Debian-specific: In the default configuration, this option is equivalent to -X, since Forw |\n| -y | — | — | sent to stderr. ssh may additionally obtain configuration data from a per-user configuration file and a system- wide con |\n\n## See Also\n\n- scp(1)\n- sftp(1)\n- ssh-add(1)\n- ssh-agent(1)\n- ssh-argv0(1)\n- ssh-keygen(1)\n- ssh-keyscan(1)\n- tun(4)\n- sshconfig(5)\n- ssh-keysign(8)\n- sshd(8)\n\n## Section Outline\n\n- **NAME** (2 lines)\n- **SYNOPSIS** (6 lines)\n- **DESCRIPTION** (16 lines) — 51 subsections\n  - -4 (1 lines)\n  - -6 (1 lines)\n  - -A (9 lines)\n  - -a (1 lines)\n  - -B (3 lines)\n  - -b (3 lines)\n  - -C (5 lines)\n  - -c (4 lines)\n  - -D (15 lines)\n  - -E (2 lines)\n  - -e (6 lines)\n  - -F (5 lines)\n  - -f (9 lines)\n  - -G (1 lines)\n  - -g (2 lines)\n  - -I (3 lines)\n  - -i (11 lines)\n  - -J (7 lines)\n  - -K (2 lines)\n  - -k (1 lines)\n  - -L (1 lines)\n  - -L (1 lines)\n  - -L (1 lines)\n  - -L (18 lines)\n  - -l (3 lines)\n  - -M -M (4 lines)\n  - -m (3 lines)\n  - -N (2 lines)\n  - -n (7 lines)\n  - -O (7 lines)\n  - -o (99 lines)\n  - -p (3 lines)\n  - -Q (10 lines)\n  - -q (1 lines)\n  - -R (1 lines)\n  - -R (1 lines)\n  - -R (1 lines)\n  - -R (1 lines)\n  - -R (24 lines)\n  - -S (4 lines)\n  - -s (4 lines)\n  - -T (1 lines)\n  - -t (3 lines)\n  - -V (1 lines)\n  - -v (3 lines)\n  - -W (5 lines)\n  - -w (11 lines)\n  - -X (16 lines)\n  - -x (1 lines)\n  - -Y (7 lines)\n  - -y (6 lines)\n- **AUTHENTICATION** (92 lines)\n- **ESCAPE CHARACTERS** (36 lines)\n- **TCP FORWARDING** (21 lines)\n- **X11 FORWARDING** (22 lines)\n- **VERIFYING HOST KEYS** (47 lines)\n- **SSH-BASED VIRTUAL PRIVATE NETWORKS** (32 lines)\n- **ENVIRONMENT** (65 lines)\n- **FILES** (91 lines)\n- **EXIT STATUS** (2 lines)\n- **SEE ALSO** (3 lines)\n- **STANDARDS** (40 lines)\n- **AUTHORS** (6 lines)\n\n## Full Content\n\n### NAME\n\nssh — OpenSSH remote login client\n\n### SYNOPSIS\n\nssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bindinterface] [-b bindaddress] [-c cipherspec]\n[-D [bindaddress:]port] [-E logfile] [-e escapechar] [-F configfile] [-I pkcs11]\n[-i identityfile] [-J destination] [-L address] [-l loginname] [-m macspec] [-O ctlcmd]\n[-o option] [-p port] [-Q queryoption] [-R address] [-S ctlpath] [-W host:port]\n[-w localtun[:remotetun]] destination [command [argument ...]]\n\n### DESCRIPTION\n\nssh (SSH client) is a program for logging into a remote machine and for executing commands on a\nremote machine.  It is intended to provide secure encrypted communications between two un‐\ntrusted hosts over an insecure network.  X11 connections, arbitrary TCP ports and UNIX-domain\nsockets can also be forwarded over the secure channel.\n\nssh connects and logs into the specified destination, which may be specified as either\n[user@]hostname or a URI of the form ssh://[user@]hostname[:port].  The user must prove their\nidentity to the remote machine using one of several methods (see below).\n\nIf a command is specified, it will be executed on the remote host instead of a login shell.  A\ncomplete command line may be specified as command, or it may have additional arguments.  If\nsupplied, the arguments will be appended to the command, separated by spaces, before it is sent\nto the server to be executed.\n\nThe options are as follows:\n\n#### -4\n\n#### -6\n\n#### -A\n\nThis can also be specified on a per-host basis in a configuration file.\n\nAgent forwarding should be enabled with caution.  Users with the ability to bypass file\npermissions on the remote host (for the agent's UNIX-domain socket) can access the lo‐\ncal agent through the forwarded connection.  An attacker cannot obtain key material\nfrom the agent, however they can perform operations on the keys that enable them to au‐\nthenticate using the identities loaded into the agent.  A safer alternative may be to\nuse a jump host (see -J).\n\n#### -a\n\n#### -B\n\nBind to the address of bindinterface before attempting to connect to the destination\nhost.  This is only useful on systems with more than one address.\n\n#### -b\n\nUse bindaddress on the local machine as the source address of the connection.  Only\nuseful on systems with more than one address.\n\n#### -C\n\nwarded X11, TCP and UNIX-domain connections).  The compression algorithm is the same\nused by gzip(1).  Compression is desirable on modem lines and other slow connections,\nbut will only slow down things on fast networks.  The default value can be set on a\nhost-by-host basis in the configuration files; see the Compression option.\n\n#### -c\n\nSelects the cipher specification for encrypting the session.  cipherspec is a comma-\nseparated list of ciphers listed in order of preference.  See the Ciphers keyword in\nsshconfig(5) for more information.\n\n#### -D\n\nSpecifies a local “dynamic” application-level port forwarding.  This works by allocat‐\ning a socket to listen to port on the local side, optionally bound to the specified\nbindaddress.  Whenever a connection is made to this port, the connection is forwarded\nover the secure channel, and the application protocol is then used to determine where\nto connect to from the remote machine.  Currently the SOCKS4 and SOCKS5 protocols are\nsupported, and ssh will act as a SOCKS server.  Only root can forward privileged ports.\nDynamic port forwardings can also be specified in the configuration file.\n\nIPv6 addresses can be specified by enclosing the address in square brackets.  Only the\nsuperuser can forward privileged ports.  By default, the local port is bound in accor‐\ndance with the GatewayPorts setting.  However, an explicit bindaddress may be used to\nbind the connection to a specific address.  The bindaddress of “localhost” indicates\nthat the listening port be bound for local use only, while an empty address or ‘*’ in‐\ndicates that the port should be available from all interfaces.\n\n#### -E\n\nAppend debug logs to logfile instead of standard error.\n\n#### -e\n\nSets the escape character for sessions with a pty (default: ‘~’).  The escape character\nis only recognized at the beginning of a line.  The escape character followed by a dot\n(‘.’) closes the connection; followed by control-Z suspends the connection; and fol‐\nlowed by itself sends the escape character once.  Setting the character to “none” dis‐\nables any escapes and makes the session fully transparent.\n\n#### -F\n\nSpecifies an alternative per-user configuration file.  If a configuration file is given\non the command line, the system-wide configuration file (/etc/ssh/sshconfig) will be\nignored.  The default for the per-user configuration file is ~/.ssh/config.  If set to\n“none”, no configuration files will be read.\n\n#### -f\n\nis going to ask for passwords or passphrases, but the user wants it in the background.\nThis implies -n.  The recommended way to start X11 programs at a remote site is with\nsomething like ssh -f host xterm.\n\nIf the ExitOnForwardFailure configuration option is set to “yes”, then a client started\nwith -f will wait for all remote port forwards to be successfully established before\nplacing itself in the background.  Refer to the description of ForkAfterAuthentication\nin sshconfig(5) for details.\n\n#### -G\n\n#### -g\n\nnection, then this option must be specified on the master process.\n\n#### -I\n\nSpecify the PKCS#11 shared library ssh should use to communicate with a PKCS#11 token\nproviding keys for user authentication.\n\n#### -i\n\nSelects a file from which the identity (private key) for public key authentication is\nread.  You can also specify a public key file to use the corresponding private key that\nis loaded in ssh-agent(1) when the private key file is not present locally.  The de‐\nfault is ~/.ssh/idrsa, ~/.ssh/idecdsa, ~/.ssh/idecdsask, ~/.ssh/ided25519,\n~/.ssh/ided25519sk and ~/.ssh/iddsa.  Identity files may also be specified on a per-\nhost basis in the configuration file.  It is possible to have multiple -i options (and\nmultiple identities specified in configuration files).  If no certificates have been\nexplicitly specified by the CertificateFile directive, ssh will also try to load cer‐\ntificate information from the filename obtained by appending -cert.pub to identity\nfilenames.\n\n#### -J\n\nConnect to the target host by first making a ssh connection to the jump host described\nby destination and then establishing a TCP forwarding to the ultimate destination from\nthere.  Multiple jump hops may be specified separated by comma characters.  This is a\nshortcut to specify a ProxyJump configuration directive.  Note that configuration di‐\nrectives supplied on the command-line generally apply to the destination host and not\nany specified jump hosts.  Use ~/.ssh/config to specify configuration for jump hosts.\n\n#### -K\n\nto the server.\n\n#### -k\n\n#### -L\n\n#### -L\n\n#### -L\n\n#### -L\n\nSpecifies that connections to the given TCP port or Unix socket on the local (client)\nhost are to be forwarded to the given host and port, or Unix socket, on the remote\nside.  This works by allocating a socket to listen to either a TCP port on the local\nside, optionally bound to the specified bindaddress, or to a Unix socket.  Whenever a\nconnection is made to the local port or socket, the connection is forwarded over the\nsecure channel, and a connection is made to either host port hostport, or the Unix\nsocket remotesocket, from the remote machine.\n\nPort forwardings can also be specified in the configuration file.  Only the superuser\ncan forward privileged ports.  IPv6 addresses can be specified by enclosing the address\nin square brackets.\n\nBy default, the local port is bound in accordance with the GatewayPorts setting.  How‐\never, an explicit bindaddress may be used to bind the connection to a specific ad‐\ndress.  The bindaddress of “localhost” indicates that the listening port be bound for\nlocal use only, while an empty address or ‘*’ indicates that the port should be avail‐\nable from all interfaces.\n\n#### -l\n\nSpecifies the user to log in as on the remote machine.  This also may be specified on a\nper-host basis in the configuration file.\n\n#### -M -M\n\nplaces ssh into “master” mode but with confirmation required using ssh-askpass(1) be‐\nfore each operation that changes the multiplexing state (e.g. opening a new session).\nRefer to the description of ControlMaster in sshconfig(5) for details.\n\n#### -m\n\nA comma-separated list of MAC (message authentication code) algorithms, specified in\norder of preference.  See the MACs keyword for more information.\n\n#### -N\n\nthe description of SessionType in sshconfig(5) for details.\n\n#### -n\n\nused when ssh is run in the background.  A common trick is to use this to run X11 pro‐\ngrams on a remote machine.  For example, ssh -n shadows.cs.hut.fi emacs & will start an\nemacs on shadows.cs.hut.fi, and the X11 connection will be automatically forwarded over\nan encrypted channel.  The ssh program will be put in the background.  (This does not\nwork if ssh needs to ask for a password or passphrase; see also the -f option.)  Refer\nto the description of StdinNull in sshconfig(5) for details.\n\n#### -O\n\nControl an active connection multiplexing master process.  When the -O option is speci‐\nfied, the ctlcmd argument is interpreted and passed to the master process.  Valid com‐\nmands are: “check” (check that the master process is running), “forward” (request for‐\nwardings without command execution), “cancel” (cancel forwardings), “exit” (request the\nmaster to exit), and “stop” (request the master to stop accepting further multiplexing\nrequests).\n\n#### -o\n\nCan be used to give options in the format used in the configuration file.  This is use‐\nful for specifying options for which there is no separate command-line flag.  For full\ndetails of the options listed below, and their possible values, see sshconfig(5).\n\nAddKeysToAgent\nAddressFamily\nBatchMode\nBindAddress\nCanonicalDomains\nCanonicalizeFallbackLocal\nCanonicalizeHostname\nCanonicalizeMaxDots\nCanonicalizePermittedCNAMEs\nCASignatureAlgorithms\nCertificateFile\nCheckHostIP\nCiphers\nClearAllForwardings\nCompression\nConnectionAttempts\nConnectTimeout\nControlMaster\nControlPath\nControlPersist\nDynamicForward\nEscapeChar\nExitOnForwardFailure\nFingerprintHash\nForkAfterAuthentication\nForwardAgent\nForwardX11\nForwardX11Timeout\nForwardX11Trusted\nGatewayPorts\nGlobalKnownHostsFile\nGSSAPIAuthentication\nGSSAPIKeyExchange\nGSSAPIClientIdentity\nGSSAPIDelegateCredentials\nGSSAPIKexAlgorithms\nGSSAPIRenewalForcesRekey\nGSSAPIServerIdentity\nGSSAPITrustDns\nHashKnownHosts\nHost\nHostbasedAcceptedAlgorithms\nHostbasedAuthentication\nHostKeyAlgorithms\nHostKeyAlias\nHostname\nIdentitiesOnly\nIdentityAgent\nIdentityFile\nIPQoS\nKbdInteractiveAuthentication\nKbdInteractiveDevices\nKexAlgorithms\nKnownHostsCommand\nLocalCommand\nLocalForward\nLogLevel\nMACs\nMatch\nNoHostAuthenticationForLocalhost\nNumberOfPasswordPrompts\nPasswordAuthentication\nPermitLocalCommand\nPermitRemoteOpen\nPKCS11Provider\nPort\nPreferredAuthentications\nProxyCommand\nProxyJump\nProxyUseFdpass\nPubkeyAcceptedAlgorithms\nPubkeyAuthentication\nRekeyLimit\nRemoteCommand\nRemoteForward\nRequestTTY\nSendEnv\nServerAliveInterval\nServerAliveCountMax\nSessionType\nSetEnv\nStdinNull\nStreamLocalBindMask\nStreamLocalBindUnlink\nStrictHostKeyChecking\nTCPKeepAlive\nTunnel\nTunnelDevice\nUpdateHostKeys\nUser\nUserKnownHostsFile\nVerifyHostKeyDNS\nVisualHostKey\nXAuthLocation\n\n#### -p\n\nPort to connect to on the remote host.  This can be specified on a per-host basis in\nthe configuration file.\n\n#### -Q\n\nQueries for the algorithms supported by one of the following features: cipher (sup‐\nported symmetric ciphers), cipher-auth (supported symmetric ciphers that support au‐\nthenticated encryption), help (supported query terms for use with the -Q flag), mac\n(supported message integrity codes), kex (key exchange algorithms), kex-gss (GSSAPI key\nexchange algorithms), key (key types), key-cert (certificate key types), key-plain\n(non-certificate key types), key-sig (all key types and signature algorithms),\nprotocol-version (supported SSH protocol versions), and sig (supported signature algo‐\nrithms).  Alternatively, any keyword from sshconfig(5) or sshdconfig(5) that takes an\nalgorithm list may be used as an alias for the corresponding queryoption.\n\n#### -q\n\n#### -R\n\n#### -R\n\n#### -R\n\n#### -R\n\n#### -R\n\nSpecifies that connections to the given TCP port or Unix socket on the remote (server)\nhost are to be forwarded to the local side.\n\nThis works by allocating a socket to listen to either a TCP port or to a Unix socket on\nthe remote side.  Whenever a connection is made to this port or Unix socket, the con‐\nnection is forwarded over the secure channel, and a connection is made from the local\nmachine to either an explicit destination specified by host port hostport, or\nlocalsocket, or, if no explicit destination was specified, ssh will act as a SOCKS 4/5\nproxy and forward connections to the destinations requested by the remote SOCKS client.\n\nPort forwardings can also be specified in the configuration file.  Privileged ports can\nbe forwarded only when logging in as root on the remote machine.  IPv6 addresses can be\nspecified by enclosing the address in square brackets.\n\nBy default, TCP listening sockets on the server will be bound to the loopback interface\nonly.  This may be overridden by specifying a bindaddress.  An empty bindaddress, or\nthe address ‘*’, indicates that the remote socket should listen on all interfaces.\nSpecifying a remote bindaddress will only succeed if the server's GatewayPorts option\nis enabled (see sshdconfig(5)).\n\nIf the port argument is ‘0’, the listen port will be dynamically allocated on the\nserver and reported to the client at run time.  When used together with -O forward the\nallocated port will be printed to the standard output.\n\n#### -S\n\nSpecifies the location of a control socket for connection sharing, or the string “none”\nto disable connection sharing.  Refer to the description of ControlPath and\nControlMaster in sshconfig(5) for details.\n\n#### -s\n\ncilitate the use of SSH as a secure transport for other applications (e.g. sftp(1)).\nThe subsystem is specified as the remote command.  Refer to the description of\nSessionType in sshconfig(5) for details.\n\n#### -T\n\n#### -t\n\nprograms on a remote machine, which can be very useful, e.g. when implementing menu\nservices.  Multiple -t options force tty allocation, even if ssh has no local tty.\n\n#### -V\n\n#### -v\n\nhelpful in debugging connection, authentication, and configuration problems.  Multiple\n-v options increase the verbosity.  The maximum is 3.\n\n#### -W\n\nRequests that standard input and output on the client be forwarded to host on port over\nthe secure channel.  Implies -N, -T, ExitOnForwardFailure and ClearAllForwardings,\nthough these can be overridden in the configuration file or using -o command line op‐\ntions.\n\n#### -w\n\nRequests tunnel device forwarding with the specified tun(4) devices between the client\n(localtun) and the server (remotetun).\n\nThe devices may be specified by numerical ID or the keyword “any”, which uses the next\navailable tunnel device.  If remotetun is not specified, it defaults to “any”.  See\nalso the Tunnel and TunnelDevice directives in sshconfig(5).\n\nIf the Tunnel directive is unset, it will be set to the default tunnel mode, which is\n“point-to-point”.  If a different Tunnel forwarding mode it desired, then it should be\nspecified before -w.\n\n#### -X\n\ntion file.\n\nX11 forwarding should be enabled with caution.  Users with the ability to bypass file\npermissions on the remote host (for the user's X authorization database) can access the\nlocal X11 display through the forwarded connection.  An attacker may then be able to\nperform activities such as keystroke monitoring.\n\nFor this reason, X11 forwarding is subjected to X11 SECURITY extension restrictions by\ndefault.  Refer to the ssh -Y option and the ForwardX11Trusted directive in\nsshconfig(5) for more information.\n\n(Debian-specific: X11 forwarding is not subjected to X11 SECURITY extension restric‐\ntions by default, because too many programs currently crash in this mode.  Set the\nForwardX11Trusted option to “no” to restore the upstream behaviour.  This may change in\nfuture depending on client-side improvements.)\n\n#### -x\n\n#### -Y\n\nSECURITY extension controls.\n\n(Debian-specific: In the default configuration, this option is equivalent to -X, since\nForwardX11Trusted defaults to “yes” as described above.  Set the ForwardX11Trusted op‐\ntion to “no” to restore the upstream behaviour.  This may change in future depending on\nclient-side improvements.)\n\n#### -y\n\nsent to stderr.\n\nssh may additionally obtain configuration data from a per-user configuration file and a system-\nwide configuration file.  The file format and configuration options are described in\nsshconfig(5).\n\n### AUTHENTICATION\n\nThe OpenSSH SSH client supports SSH protocol 2.\n\nThe methods available for authentication are: GSSAPI-based authentication, host-based authenti‐\ncation, public key authentication, keyboard-interactive authentication, and password authenti‐\ncation.  Authentication methods are tried in the order specified above, though\nPreferredAuthentications can be used to change the default order.\n\nHost-based authentication works as follows: If the machine the user logs in from is listed in\n/etc/hosts.equiv or /etc/ssh/shosts.equiv on the remote machine, the user is non-root and the\nuser names are the same on both sides, or if the files ~/.rhosts or ~/.shosts exist in the\nuser's home directory on the remote machine and contain a line containing the name of the\nclient machine and the name of the user on that machine, the user is considered for login.  Ad‐\nditionally, the server must be able to verify the client's host key (see the description of\n/etc/ssh/sshknownhosts and ~/.ssh/knownhosts, below) for login to be permitted.  This au‐\nthentication method closes security holes due to IP spoofing, DNS spoofing, and routing spoof‐\ning.  [Note to the administrator: /etc/hosts.equiv, ~/.rhosts, and the rlogin/rsh protocol in\ngeneral, are inherently insecure and should be disabled if security is desired.]\n\nPublic key authentication works as follows: The scheme is based on public-key cryptography, us‐\ning cryptosystems where encryption and decryption are done using separate keys, and it is un‐\nfeasible to derive the decryption key from the encryption key.  The idea is that each user cre‐\nates a public/private key pair for authentication purposes.  The server knows the public key,\nand only the user knows the private key.  ssh implements public key authentication protocol au‐\ntomatically, using one of the DSA, ECDSA, Ed25519 or RSA algorithms.  The HISTORY section of\nssl(8) (on non-OpenBSD systems, see\nhttp://www.openbsd.org/cgi-bin/man.cgi?query=ssl&sektion=8#HISTORY) contains a brief discussion\nof the DSA and RSA algorithms.\n\nThe file ~/.ssh/authorizedkeys lists the public keys that are permitted for logging in.  When\nthe user logs in, the ssh program tells the server which key pair it would like to use for au‐\nthentication.  The client proves that it has access to the private key and the server checks\nthat the corresponding public key is authorized to accept the account.\n\nThe server may inform the client of errors that prevented public key authentication from suc‐\nceeding after authentication completes using a different method.  These may be viewed by in‐\ncreasing the LogLevel to DEBUG or higher (e.g. by using the -v flag).\n\nThe user creates their key pair by running ssh-keygen(1).  This stores the private key in\n~/.ssh/iddsa (DSA), ~/.ssh/idecdsa (ECDSA), ~/.ssh/idecdsask (authenticator-hosted ECDSA),\n~/.ssh/ided25519 (Ed25519), ~/.ssh/ided25519sk (authenticator-hosted Ed25519), or\n~/.ssh/idrsa (RSA) and stores the public key in ~/.ssh/iddsa.pub (DSA), ~/.ssh/idecdsa.pub\n(ECDSA), ~/.ssh/idecdsask.pub (authenticator-hosted ECDSA), ~/.ssh/ided25519.pub (Ed25519),\n~/.ssh/ided25519sk.pub (authenticator-hosted Ed25519), or ~/.ssh/idrsa.pub (RSA) in the\nuser's home directory.  The user should then copy the public key to ~/.ssh/authorizedkeys in\ntheir home directory on the remote machine.  The authorizedkeys file corresponds to the con‐\nventional ~/.rhosts file, and has one key per line, though the lines can be very long.  After\nthis, the user can log in without giving the password.\n\nA variation on public key authentication is available in the form of certificate authentica‐\ntion: instead of a set of public/private keys, signed certificates are used.  This has the ad‐\nvantage that a single trusted certification authority can be used in place of many public/pri‐\nvate keys.  See the CERTIFICATES section of ssh-keygen(1) for more information.\n\nThe most convenient way to use public key or certificate authentication may be with an authen‐\ntication agent.  See ssh-agent(1) and (optionally) the AddKeysToAgent directive in\nsshconfig(5) for more information.\n\nKeyboard-interactive authentication works as follows: The server sends an arbitrary \"challenge\"\ntext and prompts for a response, possibly multiple times.  Examples of keyboard-interactive au‐\nthentication include BSD Authentication (see login.conf(5)) and PAM (some non-OpenBSD systems).\n\nFinally, if other authentication methods fail, ssh prompts the user for a password.  The pass‐\nword is sent to the remote host for checking; however, since all communications are encrypted,\nthe password cannot be seen by someone listening on the network.\n\nssh automatically maintains and checks a database containing identification for all hosts it\nhas ever been used with.  Host keys are stored in ~/.ssh/knownhosts in the user's home direc‐\ntory.  Additionally, the file /etc/ssh/sshknownhosts is automatically checked for known\nhosts.  Any new hosts are automatically added to the user's file.  If a host's identification\never changes, ssh warns about this and disables password authentication to prevent server\nspoofing or man-in-the-middle attacks, which could otherwise be used to circumvent the encryp‐\ntion.  The StrictHostKeyChecking option can be used to control logins to machines whose host\nkey is not known or has changed.\n\nWhen the user's identity has been accepted by the server, the server either executes the given\ncommand in a non-interactive session or, if no command has been specified, logs into the ma‐\nchine and gives the user a normal shell as an interactive session.  All communication with the\nremote command or shell will be automatically encrypted.\n\nIf an interactive session is requested ssh by default will only request a pseudo-terminal (pty)\nfor interactive sessions when the client has one.  The flags -T and -t can be used to override\nthis behaviour.\n\nIf a pseudo-terminal has been allocated the user may use the escape characters noted below.\n\nIf no pseudo-terminal has been allocated, the session is transparent and can be used to reli‐\nably transfer binary data.  On most systems, setting the escape character to “none” will also\nmake the session transparent even if a tty is used.\n\nThe session terminates when the command or shell on the remote machine exits and all X11 and\nTCP connections have been closed.\n\n### ESCAPE CHARACTERS\n\nWhen a pseudo-terminal has been requested, ssh supports a number of functions through the use\nof an escape character.\n\nA single tilde character can be sent as ~~ or by following the tilde by a character other than\nthose described below.  The escape character must always follow a newline to be interpreted as\nspecial.  The escape character can be changed in configuration files using the EscapeChar con‐\nfiguration directive or on the command line by the -e option.\n\nThe supported escapes (assuming the default ‘~’) are:\n\n~.      Disconnect.\n\n~^Z     Background ssh.\n\n~#      List forwarded connections.\n\n~&      Background ssh at logout when waiting for forwarded connection / X11 sessions to termi‐\nnate.\n\n~?      Display a list of escape characters.\n\n~B      Send a BREAK to the remote system (only useful if the peer supports it).\n\n~C      Open command line.  Currently this allows the addition of port forwardings using the\n-L, -R and -D options (see above).  It also allows the cancellation of existing port-\nforwardings with -KL[bindaddress:]port for local, -KR[bindaddress:]port for remote\nand -KD[bindaddress:]port for dynamic port-forwardings.  !command allows the user to\nexecute a local command if the PermitLocalCommand option is enabled in sshconfig(5).\nBasic help is available, using the -h option.\n\n~R      Request rekeying of the connection (only useful if the peer supports it).\n\n~V      Decrease the verbosity (LogLevel) when errors are being written to stderr.\n\n~v      Increase the verbosity (LogLevel) when errors are being written to stderr.\n\n### TCP FORWARDING\n\nForwarding of arbitrary TCP connections over a secure channel can be specified either on the\ncommand line or in a configuration file.  One possible application of TCP forwarding is a se‐\ncure connection to a mail server; another is going through firewalls.\n\nIn the example below, we look at encrypting communication for an IRC client, even though the\nIRC server it connects to does not directly support encrypted communication.  This works as\nfollows: the user connects to the remote host using ssh, specifying the ports to be used to\nforward the connection.  After that it is possible to start the program locally, and ssh will\nencrypt and forward the connection to the remote server.\n\nThe following example tunnels an IRC session from the client to an IRC server at\n“server.example.com”, joining channel “#users”, nickname “pinky”, using the standard IRC port,\n6667:\n\n$ ssh -f -L 6667:localhost:6667 server.example.com sleep 10\n$ irc -c '#users' pinky IRC/127.0.0.1\n\nThe -f option backgrounds ssh and the remote command “sleep 10” is specified to allow an amount\nof time (10 seconds, in the example) to start the program which is going to use the tunnel.  If\nno connections are made within the time specified, ssh will exit.\n\n### X11 FORWARDING\n\nIf the ForwardX11 variable is set to “yes” (or see the description of the -X, -x, and -Y op‐\ntions above) and the user is using X11 (the DISPLAY environment variable is set), the connec‐\ntion to the X11 display is automatically forwarded to the remote side in such a way that any\nX11 programs started from the shell (or command) will go through the encrypted channel, and the\nconnection to the real X server will be made from the local machine.  The user should not manu‐\nally set DISPLAY.  Forwarding of X11 connections can be configured on the command line or in\nconfiguration files.\n\nThe DISPLAY value set by ssh will point to the server machine, but with a display number\ngreater than zero.  This is normal, and happens because ssh creates a “proxy” X server on the\nserver machine for forwarding the connections over the encrypted channel.\n\nssh will also automatically set up Xauthority data on the server machine.  For this purpose, it\nwill generate a random authorization cookie, store it in Xauthority on the server, and verify\nthat any forwarded connections carry this cookie and replace it by the real cookie when the\nconnection is opened.  The real authentication cookie is never sent to the server machine (and\nno cookies are sent in the plain).\n\nIf the ForwardAgent variable is set to “yes” (or see the description of the -A and -a options\nabove) and the user is using an authentication agent, the connection to the agent is automati‐\ncally forwarded to the remote side.\n\n### VERIFYING HOST KEYS\n\nWhen connecting to a server for the first time, a fingerprint of the server's public key is\npresented to the user (unless the option StrictHostKeyChecking has been disabled).  Finger‐\nprints can be determined using ssh-keygen(1):\n\n$ ssh-keygen -l -f /etc/ssh/sshhostrsakey\n\nIf the fingerprint is already known, it can be matched and the key can be accepted or rejected.\nIf only legacy (MD5) fingerprints for the server are available, the ssh-keygen(1) -E option may\nbe used to downgrade the fingerprint algorithm to match.\n\nBecause of the difficulty of comparing host keys just by looking at fingerprint strings, there\nis also support to compare host keys visually, using random art.  By setting the VisualHostKey\noption to “yes”, a small ASCII graphic gets displayed on every login to a server, no matter if\nthe session itself is interactive or not.  By learning the pattern a known server produces, a\nuser can easily find out that the host key has changed when a completely different pattern is\ndisplayed.  Because these patterns are not unambiguous however, a pattern that looks similar to\nthe pattern remembered only gives a good probability that the host key is the same, not guaran‐\nteed proof.\n\nTo get a listing of the fingerprints along with their random art for all known hosts, the fol‐\nlowing command line can be used:\n\n$ ssh-keygen -lv -f ~/.ssh/knownhosts\n\nIf the fingerprint is unknown, an alternative method of verification is available: SSH finger‐\nprints verified by DNS.  An additional resource record (RR), SSHFP, is added to a zonefile and\nthe connecting client is able to match the fingerprint with that of the key presented.\n\nIn this example, we are connecting a client to a server, “host.example.com”.  The SSHFP re‐\nsource records should first be added to the zonefile for host.example.com:\n\n$ ssh-keygen -r host.example.com.\n\nThe output lines will have to be added to the zonefile.  To check that the zone is answering\nfingerprint queries:\n\n$ dig -t SSHFP host.example.com\n\nFinally the client connects:\n\n$ ssh -o \"VerifyHostKeyDNS ask\" host.example.com\n[...]\nMatching host key fingerprint found in DNS.\nAre you sure you want to continue connecting (yes/no)?\n\nSee the VerifyHostKeyDNS option in sshconfig(5) for more information.\n\n### SSH-BASED VIRTUAL PRIVATE NETWORKS\n\nssh contains support for Virtual Private Network (VPN) tunnelling using the tun(4) network\npseudo-device, allowing two networks to be joined securely.  The sshdconfig(5) configuration\noption PermitTunnel controls whether the server supports this, and at what level (layer 2 or 3\ntraffic).\n\nThe following example would connect client network 10.0.50.0/24 with remote network\n10.0.99.0/24 using a point-to-point connection from 10.1.1.1 to 10.1.1.2, provided that the SSH\nserver running on the gateway to the remote network, at 192.168.1.15, allows it.\n\nOn the client:\n\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\nOn the server:\n\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\nClient access may be more finely tuned via the /root/.ssh/authorizedkeys file (see below) and\nthe PermitRootLogin server option.  The following entry would permit connections on tun(4) de‐\nvice 1 from user “jane” and on tun device 2 from user “john”, if PermitRootLogin is set to\n“forced-commands-only”:\n\ntunnel=\"1\",command=\"sh /etc/netstart tun1\" ssh-rsa ... jane\ntunnel=\"2\",command=\"sh /etc/netstart tun2\" ssh-rsa ... john\n\nSince an SSH-based setup entails a fair amount of overhead, it may be more suited to temporary\nsetups, such as for wireless VPNs.  More permanent VPNs are better provided by tools such as\nipsecctl(8) and isakmpd(8).\n\n### ENVIRONMENT\n\nssh will normally set the following environment variables:\n\nDISPLAY               The DISPLAY variable indicates the location of the X11 server.  It is au‐\ntomatically set by ssh to point to a value of the form “hostname:n”,\nwhere “hostname” indicates the host where the shell runs, and ‘n’ is an\ninteger ≥ 1.  ssh uses this special value to forward X11 connections over\nthe secure channel.  The user should normally not set DISPLAY explicitly,\nas that will render the X11 connection insecure (and will require the\nuser to manually copy any required authorization cookies).\n\nHOME                  Set to the path of the user's home directory.\n\nLOGNAME               Synonym for USER; set for compatibility with systems that use this vari‐\nable.\n\nMAIL                  Set to the path of the user's mailbox.\n\nPATH                  Set to the default PATH, as specified when compiling ssh.\n\nSSHASKPASS           If ssh needs a passphrase, it will read the passphrase from the current\nterminal if it was run from a terminal.  If ssh does not have a terminal\nassociated with it but DISPLAY and SSHASKPASS are set, it will execute\nthe program specified by SSHASKPASS and open an X11 window to read the\npassphrase.  This is particularly useful when calling ssh from a\n.xsession or related script.  (Note that on some machines it may be nec‐\nessary to redirect the input from /dev/null to make this work.)\n\nSSHASKPASSREQUIRE   Allows further control over the use of an askpass program.  If this vari‐\nable is set to “never” then ssh will never attempt to use one.  If it is\nset to “prefer”, then ssh will prefer to use the askpass program instead\nof the TTY when requesting passwords.  Finally, if the variable is set to\n“force”, then the askpass program will be used for all passphrase input\nregardless of whether DISPLAY is set.\n\nSSHAUTHSOCK         Identifies the path of a UNIX-domain socket used to communicate with the\nagent.\n\nSSHCONNECTION        Identifies the client and server ends of the connection.  The variable\ncontains four space-separated values: client IP address, client port num‐\nber, server IP address, and server port number.\n\nSSHORIGINALCOMMAND  This variable contains the original command line if a forced command is\nexecuted.  It can be used to extract the original arguments.\n\nSSHTTY               This is set to the name of the tty (path to the device) associated with\nthe current shell or command.  If the current session has no tty, this\nvariable is not set.\n\nSSHTUNNEL            Optionally set by sshd(8) to contain the interface names assigned if tun‐\nnel forwarding was requested by the client.\n\nSSHUSERAUTH         Optionally set by sshd(8), this variable may contain a pathname to a file\nthat lists the authentication methods successfully used when the session\nwas established, including any public keys that were used.\n\nTZ                    This variable is set to indicate the present time zone if it was set when\nthe daemon was started (i.e. the daemon passes the value on to new con‐\nnections).\n\nUSER                  Set to the name of the user logging in.\n\nAdditionally, ssh reads ~/.ssh/environment, and adds lines of the format “VARNAME=value” to the\nenvironment if the file exists and users are allowed to change their environment.  For more in‐\nformation, see the PermitUserEnvironment option in sshdconfig(5).\n\n### FILES\n\n~/.rhosts\nThis file is used for host-based authentication (see above).  On some machines this\nfile may need to be world-readable if the user's home directory is on an NFS partition,\nbecause sshd(8) reads it as root.  Additionally, this file must be owned by the user,\nand must not have write permissions for anyone else.  The recommended permission for\nmost machines is read/write for the user, and not accessible by others.\n\n~/.shosts\nThis file is used in exactly the same way as .rhosts, but allows host-based authentica‐\ntion without permitting login with rlogin/rsh.\n\n~/.ssh/\nThis directory is the default location for all user-specific configuration and authen‐\ntication information.  There is no general requirement to keep the entire contents of\nthis directory secret, but the recommended permissions are read/write/execute for the\nuser, and not accessible by others.\n\n~/.ssh/authorizedkeys\nLists the public keys (DSA, ECDSA, Ed25519, RSA) that can be used for logging in as\nthis user.  The format of this file is described in the sshd(8) manual page.  This file\nis not highly sensitive, but the recommended permissions are read/write for the user,\nand not accessible by others.\n\n~/.ssh/config\nThis is the per-user configuration file.  The file format and configuration options are\ndescribed in sshconfig(5).  Because of the potential for abuse, this file must have\nstrict permissions: read/write for the user, and not writable by others.  It may be\ngroup-writable provided that the group in question contains only the user.\n\n~/.ssh/environment\nContains additional definitions for environment variables; see ENVIRONMENT, above.\n\n~/.ssh/iddsa\n~/.ssh/idecdsa\n~/.ssh/idecdsask\n~/.ssh/ided25519\n~/.ssh/ided25519sk\n~/.ssh/idrsa\nContains the private key for authentication.  These files contain sensitive data and\nshould be readable by the user but not accessible by others (read/write/execute).  ssh\nwill simply ignore a private key file if it is accessible by others.  It is possible to\nspecify a passphrase when generating the key which will be used to encrypt the sensi‐\ntive part of this file using AES-128.\n\n~/.ssh/iddsa.pub\n~/.ssh/idecdsa.pub\n~/.ssh/idecdsask.pub\n~/.ssh/ided25519.pub\n~/.ssh/ided25519sk.pub\n~/.ssh/idrsa.pub\nContains the public key for authentication.  These files are not sensitive and can (but\nneed not) be readable by anyone.\n\n~/.ssh/knownhosts\nContains a list of host keys for all hosts the user has logged into that are not al‐\nready in the systemwide list of known host keys.  See sshd(8) for further details of\nthe format of this file.\n\n~/.ssh/rc\nCommands in this file are executed by ssh when the user logs in, just before the user's\nshell (or command) is started.  See the sshd(8) manual page for more information.\n\n/etc/hosts.equiv\nThis file is for host-based authentication (see above).  It should only be writable by\nroot.\n\n/etc/ssh/shosts.equiv\nThis file is used in exactly the same way as hosts.equiv, but allows host-based authen‐\ntication without permitting login with rlogin/rsh.\n\n/etc/ssh/sshconfig\nSystemwide configuration file.  The file format and configuration options are described\nin sshconfig(5).\n\n/etc/ssh/sshhostkey\n/etc/ssh/sshhostdsakey\n/etc/ssh/sshhostecdsakey\n/etc/ssh/sshhosted25519key\n/etc/ssh/sshhostrsakey\nThese files contain the private parts of the host keys and are used for host-based au‐\nthentication.\n\n/etc/ssh/sshknownhosts\nSystemwide list of known host keys.  This file should be prepared by the system admin‐\nistrator to contain the public host keys of all machines in the organization.  It\nshould be world-readable.  See sshd(8) for further details of the format of this file.\n\n/etc/ssh/sshrc\nCommands in this file are executed by ssh when the user logs in, just before the user's\nshell (or command) is started.  See the sshd(8) manual page for more information.\n\n### EXIT STATUS\n\nssh exits with the exit status of the remote command or with 255 if an error occurred.\n\n### SEE ALSO\n\nscp(1), sftp(1), ssh-add(1), ssh-agent(1), ssh-argv0(1), ssh-keygen(1), ssh-keyscan(1), tun(4),\nsshconfig(5), ssh-keysign(8), sshd(8)\n\n### STANDARDS\n\nS. Lehtinen and C. Lonvick, The Secure Shell (SSH) Protocol Assigned Numbers, RFC 4250, January\n2006.\n\nT. Ylonen and C. Lonvick, The Secure Shell (SSH) Protocol Architecture, RFC 4251, January 2006.\n\nT. Ylonen and C. Lonvick, The Secure Shell (SSH) Authentication Protocol, RFC 4252, January\n2006.\n\nT. Ylonen and C. Lonvick, The Secure Shell (SSH) Transport Layer Protocol, RFC 4253, January\n2006.\n\nT. Ylonen and C. Lonvick, The Secure Shell (SSH) Connection Protocol, RFC 4254, January 2006.\n\nJ. Schlyter and W. Griffin, Using DNS to Securely Publish Secure Shell (SSH) Key Fingerprints,\nRFC 4255, January 2006.\n\nF. Cusack and M. Forssen, Generic Message Exchange Authentication for the Secure Shell Protocol\n(SSH), RFC 4256, January 2006.\n\nJ. Galbraith and P. Remaker, The Secure Shell (SSH) Session Channel Break Extension, RFC 4335,\nJanuary 2006.\n\nM. Bellare, T. Kohno, and C. Namprempre, The Secure Shell (SSH) Transport Layer Encryption\nModes, RFC 4344, January 2006.\n\nB. Harris, Improved Arcfour Modes for the Secure Shell (SSH) Transport Layer Protocol, RFC\n4345, January 2006.\n\nM. Friedl, N. Provos, and W. Simpson, Diffie-Hellman Group Exchange for the Secure Shell (SSH)\nTransport Layer Protocol, RFC 4419, March 2006.\n\nJ. Galbraith and R. Thayer, The Secure Shell (SSH) Public Key File Format, RFC 4716, November\n2006.\n\nD. Stebila and J. Green, Elliptic Curve Algorithm Integration in the Secure Shell Transport\nLayer, RFC 5656, December 2009.\n\nA. Perrig and D. Song, Hash Visualization: a New Technique to improve Real-World Security,\n1999, International Workshop on Cryptographic Techniques and E-Commerce (CrypTEC '99).\n\n### AUTHORS\n\nOpenSSH is a derivative of the original and free ssh 1.2.12 release by Tatu Ylonen.  Aaron\nCampbell, Bob Beck, Markus Friedl, Niels Provos, Theo de Raadt and Dug Song removed many bugs,\nre-added newer features and created OpenSSH.  Markus Friedl contributed the support for SSH\nprotocol versions 1.5 and 2.0.\n\nBSD                            February 6, 2022                            BSD\n\n"
        }
    ],
    "structuredContent": {
        "command": "slogin",
        "section": "1",
        "mode": "man",
        "summary": "ssh — OpenSSH remote login client",
        "synopsis": "ssh [-46AaCfGgKkMNnqsTtVvXxYy] [-B bindinterface] [-b bindaddress] [-c cipherspec]\n[-D [bindaddress:]port] [-E logfile] [-e escapechar] [-F configfile] [-I pkcs11]\n[-i identityfile] [-J destination] [-L address] [-l loginname] [-m macspec] [-O ctlcmd]\n[-o option] [-p port] [-Q queryoption] [-R address] [-S ctlpath] [-W host:port]\n[-w localtun[:remotetun]] destination [command [argument ...]]",
        "flags": [
            {
                "flag": "-4",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-6",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-A",
                "long": null,
                "arg": null,
                "description": "This can also be specified on a per-host basis in a configuration file. Agent forwarding should be enabled with caution. Users with the ability to bypass file permissions on the remote host (for the agent's UNIX-domain socket) can access the lo‐ cal agent through the forwarded connection. An attacker cannot obtain key material from the agent, however they can perform operations on the keys that enable them to au‐ thenticate using the identities loaded into the agent. A safer alternative may be to use a jump host (see -J)."
            },
            {
                "flag": "-a",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-B",
                "long": null,
                "arg": null,
                "description": "Bind to the address of bindinterface before attempting to connect to the destination host. This is only useful on systems with more than one address."
            },
            {
                "flag": "-b",
                "long": null,
                "arg": null,
                "description": "Use bindaddress on the local machine as the source address of the connection. Only useful on systems with more than one address."
            },
            {
                "flag": "-C",
                "long": null,
                "arg": null,
                "description": "warded X11, TCP and UNIX-domain connections). The compression algorithm is the same used by gzip(1). Compression is desirable on modem lines and other slow connections, but will only slow down things on fast networks. The default value can be set on a host-by-host basis in the configuration files; see the Compression option."
            },
            {
                "flag": "-c",
                "long": null,
                "arg": null,
                "description": "Selects the cipher specification for encrypting the session. cipherspec is a comma- separated list of ciphers listed in order of preference. See the Ciphers keyword in sshconfig(5) for more information."
            },
            {
                "flag": "-D",
                "long": null,
                "arg": null,
                "description": "Specifies a local “dynamic” application-level port forwarding. This works by allocat‐ ing a socket to listen to port on the local side, optionally bound to the specified bindaddress. Whenever a connection is made to this port, the connection is forwarded over the secure channel, and the application protocol is then used to determine where to connect to from the remote machine. Currently the SOCKS4 and SOCKS5 protocols are supported, and ssh will act as a SOCKS server. Only root can forward privileged ports. Dynamic port forwardings can also be specified in the configuration file. IPv6 addresses can be specified by enclosing the address in square brackets. Only the superuser can forward privileged ports. By default, the local port is bound in accor‐ dance with the GatewayPorts setting. However, an explicit bindaddress may be used to bind the connection to a specific address. The bindaddress of “localhost” indicates that the listening port be bound for local use only, while an empty address or ‘*’ in‐ dicates that the port should be available from all interfaces."
            },
            {
                "flag": "-E",
                "long": null,
                "arg": null,
                "description": "Append debug logs to logfile instead of standard error."
            },
            {
                "flag": "-e",
                "long": null,
                "arg": null,
                "description": "Sets the escape character for sessions with a pty (default: ‘~’). The escape character is only recognized at the beginning of a line. The escape character followed by a dot (‘.’) closes the connection; followed by control-Z suspends the connection; and fol‐ lowed by itself sends the escape character once. Setting the character to “none” dis‐ ables any escapes and makes the session fully transparent."
            },
            {
                "flag": "-F",
                "long": null,
                "arg": null,
                "description": "Specifies an alternative per-user configuration file. If a configuration file is given on the command line, the system-wide configuration file (/etc/ssh/sshconfig) will be ignored. The default for the per-user configuration file is ~/.ssh/config. If set to “none”, no configuration files will be read."
            },
            {
                "flag": "-f",
                "long": null,
                "arg": null,
                "description": "is going to ask for passwords or passphrases, but the user wants it in the background. This implies -n. The recommended way to start X11 programs at a remote site is with something like ssh -f host xterm. If the ExitOnForwardFailure configuration option is set to “yes”, then a client started with -f will wait for all remote port forwards to be successfully established before placing itself in the background. Refer to the description of ForkAfterAuthentication in sshconfig(5) for details."
            },
            {
                "flag": "-G",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-g",
                "long": null,
                "arg": null,
                "description": "nection, then this option must be specified on the master process."
            },
            {
                "flag": "-I",
                "long": null,
                "arg": null,
                "description": "Specify the PKCS#11 shared library ssh should use to communicate with a PKCS#11 token providing keys for user authentication."
            },
            {
                "flag": "-i",
                "long": null,
                "arg": null,
                "description": "Selects a file from which the identity (private key) for public key authentication is read. You can also specify a public key file to use the corresponding private key that is loaded in ssh-agent(1) when the private key file is not present locally. The de‐ fault is ~/.ssh/idrsa, ~/.ssh/idecdsa, ~/.ssh/idecdsask, ~/.ssh/ided25519, ~/.ssh/ided25519sk and ~/.ssh/iddsa. Identity files may also be specified on a per- host basis in the configuration file. It is possible to have multiple -i options (and multiple identities specified in configuration files). If no certificates have been explicitly specified by the CertificateFile directive, ssh will also try to load cer‐ tificate information from the filename obtained by appending -cert.pub to identity filenames."
            },
            {
                "flag": "-J",
                "long": null,
                "arg": null,
                "description": "Connect to the target host by first making a ssh connection to the jump host described by destination and then establishing a TCP forwarding to the ultimate destination from there. Multiple jump hops may be specified separated by comma characters. This is a shortcut to specify a ProxyJump configuration directive. Note that configuration di‐ rectives supplied on the command-line generally apply to the destination host and not any specified jump hosts. Use ~/.ssh/config to specify configuration for jump hosts."
            },
            {
                "flag": "-K",
                "long": null,
                "arg": null,
                "description": "to the server."
            },
            {
                "flag": "-k",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-L",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-L",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-L",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-L",
                "long": null,
                "arg": null,
                "description": "Specifies that connections to the given TCP port or Unix socket on the local (client) host are to be forwarded to the given host and port, or Unix socket, on the remote side. This works by allocating a socket to listen to either a TCP port on the local side, optionally bound to the specified bindaddress, or to a Unix socket. Whenever a connection is made to the local port or socket, the connection is forwarded over the secure channel, and a connection is made to either host port hostport, or the Unix socket remotesocket, from the remote machine. Port forwardings can also be specified in the configuration file. Only the superuser can forward privileged ports. IPv6 addresses can be specified by enclosing the address in square brackets. By default, the local port is bound in accordance with the GatewayPorts setting. How‐ ever, an explicit bindaddress may be used to bind the connection to a specific ad‐ dress. The bindaddress of “localhost” indicates that the listening port be bound for local use only, while an empty address or ‘*’ indicates that the port should be avail‐ able from all interfaces."
            },
            {
                "flag": "-l",
                "long": null,
                "arg": null,
                "description": "Specifies the user to log in as on the remote machine. This also may be specified on a per-host basis in the configuration file."
            },
            {
                "flag": "-M",
                "long": null,
                "arg": null,
                "description": "places ssh into “master” mode but with confirmation required using ssh-askpass(1) be‐ fore each operation that changes the multiplexing state (e.g. opening a new session). Refer to the description of ControlMaster in sshconfig(5) for details."
            },
            {
                "flag": "-m",
                "long": null,
                "arg": null,
                "description": "A comma-separated list of MAC (message authentication code) algorithms, specified in order of preference. See the MACs keyword for more information."
            },
            {
                "flag": "-N",
                "long": null,
                "arg": null,
                "description": "the description of SessionType in sshconfig(5) for details."
            },
            {
                "flag": "-n",
                "long": null,
                "arg": null,
                "description": "used when ssh is run in the background. A common trick is to use this to run X11 pro‐ grams on a remote machine. For example, ssh -n shadows.cs.hut.fi emacs & will start an emacs on shadows.cs.hut.fi, and the X11 connection will be automatically forwarded over an encrypted channel. The ssh program will be put in the background. (This does not work if ssh needs to ask for a password or passphrase; see also the -f option.) Refer to the description of StdinNull in sshconfig(5) for details."
            },
            {
                "flag": "-O",
                "long": null,
                "arg": null,
                "description": "Control an active connection multiplexing master process. When the -O option is speci‐ fied, the ctlcmd argument is interpreted and passed to the master process. Valid com‐ mands are: “check” (check that the master process is running), “forward” (request for‐ wardings without command execution), “cancel” (cancel forwardings), “exit” (request the master to exit), and “stop” (request the master to stop accepting further multiplexing requests)."
            },
            {
                "flag": "-o",
                "long": null,
                "arg": null,
                "description": "Can be used to give options in the format used in the configuration file. This is use‐ ful for specifying options for which there is no separate command-line flag. For full details of the options listed below, and their possible values, see sshconfig(5). AddKeysToAgent AddressFamily BatchMode BindAddress CanonicalDomains CanonicalizeFallbackLocal CanonicalizeHostname CanonicalizeMaxDots CanonicalizePermittedCNAMEs CASignatureAlgorithms CertificateFile CheckHostIP Ciphers ClearAllForwardings Compression ConnectionAttempts ConnectTimeout ControlMaster ControlPath ControlPersist DynamicForward EscapeChar ExitOnForwardFailure FingerprintHash ForkAfterAuthentication ForwardAgent ForwardX11 ForwardX11Timeout ForwardX11Trusted GatewayPorts GlobalKnownHostsFile GSSAPIAuthentication GSSAPIKeyExchange GSSAPIClientIdentity GSSAPIDelegateCredentials GSSAPIKexAlgorithms GSSAPIRenewalForcesRekey GSSAPIServerIdentity GSSAPITrustDns HashKnownHosts Host HostbasedAcceptedAlgorithms HostbasedAuthentication HostKeyAlgorithms HostKeyAlias Hostname IdentitiesOnly IdentityAgent IdentityFile IPQoS KbdInteractiveAuthentication KbdInteractiveDevices KexAlgorithms KnownHostsCommand LocalCommand LocalForward LogLevel MACs Match NoHostAuthenticationForLocalhost NumberOfPasswordPrompts PasswordAuthentication PermitLocalCommand PermitRemoteOpen PKCS11Provider Port PreferredAuthentications ProxyCommand ProxyJump ProxyUseFdpass PubkeyAcceptedAlgorithms PubkeyAuthentication RekeyLimit RemoteCommand RemoteForward RequestTTY SendEnv ServerAliveInterval ServerAliveCountMax SessionType SetEnv StdinNull StreamLocalBindMask StreamLocalBindUnlink StrictHostKeyChecking TCPKeepAlive Tunnel TunnelDevice UpdateHostKeys User UserKnownHostsFile VerifyHostKeyDNS VisualHostKey XAuthLocation"
            },
            {
                "flag": "-p",
                "long": null,
                "arg": null,
                "description": "Port to connect to on the remote host. This can be specified on a per-host basis in the configuration file."
            },
            {
                "flag": "-Q",
                "long": null,
                "arg": null,
                "description": "Queries for the algorithms supported by one of the following features: cipher (sup‐ ported symmetric ciphers), cipher-auth (supported symmetric ciphers that support au‐ thenticated encryption), help (supported query terms for use with the -Q flag), mac (supported message integrity codes), kex (key exchange algorithms), kex-gss (GSSAPI key exchange algorithms), key (key types), key-cert (certificate key types), key-plain (non-certificate key types), key-sig (all key types and signature algorithms), protocol-version (supported SSH protocol versions), and sig (supported signature algo‐ rithms). Alternatively, any keyword from sshconfig(5) or sshdconfig(5) that takes an algorithm list may be used as an alias for the corresponding queryoption."
            },
            {
                "flag": "-q",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-R",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-R",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-R",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-R",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-R",
                "long": null,
                "arg": null,
                "description": "Specifies that connections to the given TCP port or Unix socket on the remote (server) host are to be forwarded to the local side. This works by allocating a socket to listen to either a TCP port or to a Unix socket on the remote side. Whenever a connection is made to this port or Unix socket, the con‐ nection is forwarded over the secure channel, and a connection is made from the local machine to either an explicit destination specified by host port hostport, or localsocket, or, if no explicit destination was specified, ssh will act as a SOCKS 4/5 proxy and forward connections to the destinations requested by the remote SOCKS client. Port forwardings can also be specified in the configuration file. Privileged ports can be forwarded only when logging in as root on the remote machine. IPv6 addresses can be specified by enclosing the address in square brackets. By default, TCP listening sockets on the server will be bound to the loopback interface only. This may be overridden by specifying a bindaddress. An empty bindaddress, or the address ‘*’, indicates that the remote socket should listen on all interfaces. Specifying a remote bindaddress will only succeed if the server's GatewayPorts option is enabled (see sshdconfig(5)). If the port argument is ‘0’, the listen port will be dynamically allocated on the server and reported to the client at run time. When used together with -O forward the allocated port will be printed to the standard output."
            },
            {
                "flag": "-S",
                "long": null,
                "arg": null,
                "description": "Specifies the location of a control socket for connection sharing, or the string “none” to disable connection sharing. Refer to the description of ControlPath and ControlMaster in sshconfig(5) for details."
            },
            {
                "flag": "-s",
                "long": null,
                "arg": null,
                "description": "cilitate the use of SSH as a secure transport for other applications (e.g. sftp(1)). The subsystem is specified as the remote command. Refer to the description of SessionType in sshconfig(5) for details."
            },
            {
                "flag": "-T",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-t",
                "long": null,
                "arg": null,
                "description": "programs on a remote machine, which can be very useful, e.g. when implementing menu services. Multiple -t options force tty allocation, even if ssh has no local tty."
            },
            {
                "flag": "-V",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-v",
                "long": null,
                "arg": null,
                "description": "helpful in debugging connection, authentication, and configuration problems. Multiple -v options increase the verbosity. The maximum is 3."
            },
            {
                "flag": "-W",
                "long": null,
                "arg": null,
                "description": "Requests that standard input and output on the client be forwarded to host on port over the secure channel. Implies -N, -T, ExitOnForwardFailure and ClearAllForwardings, though these can be overridden in the configuration file or using -o command line op‐ tions."
            },
            {
                "flag": "-w",
                "long": null,
                "arg": null,
                "description": "Requests tunnel device forwarding with the specified tun(4) devices between the client (localtun) and the server (remotetun). The devices may be specified by numerical ID or the keyword “any”, which uses the next available tunnel device. If remotetun is not specified, it defaults to “any”. See also the Tunnel and TunnelDevice directives in sshconfig(5). If the Tunnel directive is unset, it will be set to the default tunnel mode, which is “point-to-point”. If a different Tunnel forwarding mode it desired, then it should be specified before -w."
            },
            {
                "flag": "-X",
                "long": null,
                "arg": null,
                "description": "tion file. X11 forwarding should be enabled with caution. Users with the ability to bypass file permissions on the remote host (for the user's X authorization database) can access the local X11 display through the forwarded connection. An attacker may then be able to perform activities such as keystroke monitoring. For this reason, X11 forwarding is subjected to X11 SECURITY extension restrictions by default. Refer to the ssh -Y option and the ForwardX11Trusted directive in sshconfig(5) for more information. (Debian-specific: X11 forwarding is not subjected to X11 SECURITY extension restric‐ tions by default, because too many programs currently crash in this mode. Set the ForwardX11Trusted option to “no” to restore the upstream behaviour. This may change in future depending on client-side improvements.)"
            },
            {
                "flag": "-x",
                "long": null,
                "arg": null,
                "description": ""
            },
            {
                "flag": "-Y",
                "long": null,
                "arg": null,
                "description": "SECURITY extension controls. (Debian-specific: In the default configuration, this option is equivalent to -X, since ForwardX11Trusted defaults to “yes” as described above. Set the ForwardX11Trusted op‐ tion to “no” to restore the upstream behaviour. This may change in future depending on client-side improvements.)"
            },
            {
                "flag": "-y",
                "long": null,
                "arg": null,
                "description": "sent to stderr. ssh may additionally obtain configuration data from a per-user configuration file and a system- wide configuration file. The file format and configuration options are described in sshconfig(5)."
            }
        ],
        "examples": [],
        "see_also": [
            {
                "name": "scp",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/scp/1/json"
            },
            {
                "name": "sftp",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/sftp/1/json"
            },
            {
                "name": "ssh-add",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ssh-add/1/json"
            },
            {
                "name": "ssh-agent",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ssh-agent/1/json"
            },
            {
                "name": "ssh-argv0",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ssh-argv0/1/json"
            },
            {
                "name": "ssh-keygen",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ssh-keygen/1/json"
            },
            {
                "name": "ssh-keyscan",
                "section": "1",
                "url": "https://www.chedong.com/phpMan.php/man/ssh-keyscan/1/json"
            },
            {
                "name": "tun",
                "section": "4",
                "url": "https://www.chedong.com/phpMan.php/man/tun/4/json"
            },
            {
                "name": "sshconfig",
                "section": "5",
                "url": "https://www.chedong.com/phpMan.php/man/sshconfig/5/json"
            },
            {
                "name": "ssh-keysign",
                "section": "8",
                "url": "https://www.chedong.com/phpMan.php/man/ssh-keysign/8/json"
            },
            {
                "name": "sshd",
                "section": "8",
                "url": "https://www.chedong.com/phpMan.php/man/sshd/8/json"
            }
        ],
        "section_outline": [
            {
                "name": "NAME",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SYNOPSIS",
                "lines": 6,
                "subsections": []
            },
            {
                "name": "DESCRIPTION",
                "lines": 16,
                "subsections": [
                    {
                        "name": "-4",
                        "lines": 1,
                        "flag": "-4"
                    },
                    {
                        "name": "-6",
                        "lines": 1,
                        "flag": "-6"
                    },
                    {
                        "name": "-A",
                        "lines": 9,
                        "flag": "-A"
                    },
                    {
                        "name": "-a",
                        "lines": 1,
                        "flag": "-a"
                    },
                    {
                        "name": "-B",
                        "lines": 3,
                        "flag": "-B"
                    },
                    {
                        "name": "-b",
                        "lines": 3,
                        "flag": "-b"
                    },
                    {
                        "name": "-C",
                        "lines": 5,
                        "flag": "-C"
                    },
                    {
                        "name": "-c",
                        "lines": 4,
                        "flag": "-c"
                    },
                    {
                        "name": "-D",
                        "lines": 15,
                        "flag": "-D"
                    },
                    {
                        "name": "-E",
                        "lines": 2,
                        "flag": "-E"
                    },
                    {
                        "name": "-e",
                        "lines": 6,
                        "flag": "-e"
                    },
                    {
                        "name": "-F",
                        "lines": 5,
                        "flag": "-F"
                    },
                    {
                        "name": "-f",
                        "lines": 9,
                        "flag": "-f"
                    },
                    {
                        "name": "-G",
                        "lines": 1,
                        "flag": "-G"
                    },
                    {
                        "name": "-g",
                        "lines": 2,
                        "flag": "-g"
                    },
                    {
                        "name": "-I",
                        "lines": 3,
                        "flag": "-I"
                    },
                    {
                        "name": "-i",
                        "lines": 11,
                        "flag": "-i"
                    },
                    {
                        "name": "-J",
                        "lines": 7,
                        "flag": "-J"
                    },
                    {
                        "name": "-K",
                        "lines": 2,
                        "flag": "-K"
                    },
                    {
                        "name": "-k",
                        "lines": 1,
                        "flag": "-k"
                    },
                    {
                        "name": "-L",
                        "lines": 1,
                        "flag": "-L"
                    },
                    {
                        "name": "-L",
                        "lines": 1,
                        "flag": "-L"
                    },
                    {
                        "name": "-L",
                        "lines": 1,
                        "flag": "-L"
                    },
                    {
                        "name": "-L",
                        "lines": 18,
                        "flag": "-L"
                    },
                    {
                        "name": "-l",
                        "lines": 3,
                        "flag": "-l"
                    },
                    {
                        "name": "-M -M",
                        "lines": 4,
                        "flag": "-M"
                    },
                    {
                        "name": "-m",
                        "lines": 3,
                        "flag": "-m"
                    },
                    {
                        "name": "-N",
                        "lines": 2,
                        "flag": "-N"
                    },
                    {
                        "name": "-n",
                        "lines": 7,
                        "flag": "-n"
                    },
                    {
                        "name": "-O",
                        "lines": 7,
                        "flag": "-O"
                    },
                    {
                        "name": "-o",
                        "lines": 99,
                        "flag": "-o"
                    },
                    {
                        "name": "-p",
                        "lines": 3,
                        "flag": "-p"
                    },
                    {
                        "name": "-Q",
                        "lines": 10,
                        "flag": "-Q"
                    },
                    {
                        "name": "-q",
                        "lines": 1,
                        "flag": "-q"
                    },
                    {
                        "name": "-R",
                        "lines": 1,
                        "flag": "-R"
                    },
                    {
                        "name": "-R",
                        "lines": 1,
                        "flag": "-R"
                    },
                    {
                        "name": "-R",
                        "lines": 1,
                        "flag": "-R"
                    },
                    {
                        "name": "-R",
                        "lines": 1,
                        "flag": "-R"
                    },
                    {
                        "name": "-R",
                        "lines": 24,
                        "flag": "-R"
                    },
                    {
                        "name": "-S",
                        "lines": 4,
                        "flag": "-S"
                    },
                    {
                        "name": "-s",
                        "lines": 4,
                        "flag": "-s"
                    },
                    {
                        "name": "-T",
                        "lines": 1,
                        "flag": "-T"
                    },
                    {
                        "name": "-t",
                        "lines": 3,
                        "flag": "-t"
                    },
                    {
                        "name": "-V",
                        "lines": 1,
                        "flag": "-V"
                    },
                    {
                        "name": "-v",
                        "lines": 3,
                        "flag": "-v"
                    },
                    {
                        "name": "-W",
                        "lines": 5,
                        "flag": "-W"
                    },
                    {
                        "name": "-w",
                        "lines": 11,
                        "flag": "-w"
                    },
                    {
                        "name": "-X",
                        "lines": 16,
                        "flag": "-X"
                    },
                    {
                        "name": "-x",
                        "lines": 1,
                        "flag": "-x"
                    },
                    {
                        "name": "-Y",
                        "lines": 7,
                        "flag": "-Y"
                    },
                    {
                        "name": "-y",
                        "lines": 6,
                        "flag": "-y"
                    }
                ]
            },
            {
                "name": "AUTHENTICATION",
                "lines": 92,
                "subsections": []
            },
            {
                "name": "ESCAPE CHARACTERS",
                "lines": 36,
                "subsections": []
            },
            {
                "name": "TCP FORWARDING",
                "lines": 21,
                "subsections": []
            },
            {
                "name": "X11 FORWARDING",
                "lines": 22,
                "subsections": []
            },
            {
                "name": "VERIFYING HOST KEYS",
                "lines": 47,
                "subsections": []
            },
            {
                "name": "SSH-BASED VIRTUAL PRIVATE NETWORKS",
                "lines": 32,
                "subsections": []
            },
            {
                "name": "ENVIRONMENT",
                "lines": 65,
                "subsections": []
            },
            {
                "name": "FILES",
                "lines": 91,
                "subsections": []
            },
            {
                "name": "EXIT STATUS",
                "lines": 2,
                "subsections": []
            },
            {
                "name": "SEE ALSO",
                "lines": 3,
                "subsections": []
            },
            {
                "name": "STANDARDS",
                "lines": 40,
                "subsections": []
            },
            {
                "name": "AUTHORS",
                "lines": 6,
                "subsections": []
            }
        ]
    }
}