The LocalForward keyword specifies a local TCP/IP port to be forwarded over a secure channel to a specified port on a remote host. The GatewayPorts keyword enables remote hosts to connect to local forwarded ports.
The command ssh enables port forwarding through these options:
-L, which specifies the local port to be forwarded to the specified port on the remote host
-R, which specifies a remote port to be forwarded to the local host and specified port
The ForwardX11 keyword redirects X11 connections to the remote host with the DISPLAY environment variable set. The XAuthLocation keyword specifies the location of the xauth(1) program.