Ten practical SSH tricks

Summary

At the Chemnitz Linux Days 2008, Julius Plenz, then still a school pupil, showed ten practical features of SSH. The program can do far more than open a secure shell on another computer: transfer files, start graphical programs, build tunnels and even set up entire VPNs. The talk explained and demonstrated the features live.

More than a secure shell

SSH encrypts the connection between two computers and checks whether you are really talking to the right server. Many services can be transported over this one connection. Typical examples are port forwarding, which lets you reach a service behind a firewall, a dynamic SOCKS proxy for the browser, forwarding of graphical programs and mounting remote directories with sshfs.

With the -w option, OpenSSH can even connect tunnel network interfaces on both sides and thus set up a simple VPN.

Why it is still useful today

SSH is the most important tool in any Linux administration, yet many people use only a fraction of it. Since 2008, further convenience features have been added, such as ProxyJump, which gives access to internal systems via a jump host, and connection multiplexing, which speeds up repeated connections considerably. A well-maintained ~/.ssh/config file saves time every day.

Ideas

  • One SSH connection can transport many services in encrypted form.
  • Port forwarding makes services behind firewalls reachable.
  • OpenSSH can build a simple VPN with tunnel interfaces.

Insights

  • Many administrators use only a small part of what SSH can do.
  • A well-thought-out SSH configuration is a big productivity gain.

Facts

  • The speaker was Julius Plenz, then a school pupil.
  • The website for the talk was openssh.com.
  • Basic Unix knowledge and some experience with SSH were expected.

References

Remarks

  • The slides and audio recordings of the talk are linked on the Chemnitz Linux Days programme page.

Recommendations

  • Set up frequently used servers with user, port and ProxyJump in ~/.ssh/config.
  • Use keys instead of passwords and protect the private key with a passphrase.

Open the programme item

Search the Web Archive

Found a mistake or have something to add? Get in touch.