SSH Tunnelling

#Secure Shell (SSH) could be used to tunnel insecure #Transmission Control Protocol (TCP) connections such as File Transfer Protocol (FTP) or IMAP if the configuration AllowTcpForwarding is enabled. This provides a secure layer onto the TCP connection without resort to displacing such protocol within a network.

One could run the command below in order to experience this feature:

sudo ssh -N -f -L 142:mail.luna.edu:143 benf@mail.luna.edu

-N option indicates that SSH should not execute remote command. -f option requests SSH to go to background just after asking for passphrase. These two options are used in order to establish a tunnel.

-L specifies the connections to a given TCP port on the local host that is to be forwarded by the remote host.

-X or -Y could be used to tunnel the #X Display Manager Control Protocol (XDMCP). The first is usually the more secure option than the latter except in case of Debian. You can change the default behaviour of SSH by modifying SSH Configuration where you can omit the option.

Links to this page
  • X Display Manager Control Protocol (XDMCP)

    Since XDMCP doesn’t primarily concern with encryption of its protocol, this could be a security risk. Therefore, instead of using xhost, one can utilise the 202203221227# for XDMCP by using the option -X or -Y (-X is arguably more secure except for Debian) or setting options in 202205191924#. When using this method, it is not necessary to change the setting on the 202205182153#.

  • Secure Shell (SSH)

    SSH is a protocol that aim to establish a secure #202206151232 connection between two computers. It uses the #202203221212 in order to secure the network communication between two hosts. Additionally, one could utilise the 202203221227# feature in order to Encapsulation# one Protocol (usually insecure) under SSH thus enhance the security of the protocol.

  • SSH Configuration

    To allow #202205182136 #202203221227 by default, set ForwardX11 or ForwardX11Trusted (less secure) to yes in the config file on the client side and X11Forwarding to yes on the server side. This is corresponded to the -X and -Y option.

#cryptography #networking