X11 Forwarding Alternatives⚓︎
Alternative Methods to X11⚓︎
Below are the steps to get a JavaScript enabled, terminal based, web browser for use when you absolutely need a web browser on a headless server. You should try using this method first before you break out a GUI browser. elinks is a terminal based web browser which supports JavaScript.
elinks Disabling Certificate Validation
X11 Forwarding⚓︎
If you absolutely need a GUI browser, be prepared for it to work at 56k speeds. Not just page loads, but the GUI itself will be taking a part of that 56k, so it is sloooww!
X11 Forwarding use to be ok with text-based apps, but with GUIs that update as you hover over icons, high color, and the added compression and cypher overhead GUI apps like browsers on X11 are unusable.
- Start Xming on your local device
- Launch Putty and confirm Enable X11 Forwarding is enabled under Connection -> SSH -> X11
- Use the same number here as xming shows as the current display, example “localhost:20.0”
- SSH to your ssh jump box
ssh -Y server.local
- Start your X11 application
If you need to sudo to another user to launch the x application, you will need to copy the cookie with the below steps.
xauth -f ~/.Xauthority list|tail -1
- Copy the line from your session listed above
echo $DISPLAY
- Copy this text as well
sudo su - <otheruser>
xauth add <output from xauth command above>
export DISPLAY=<output from echo command above>
xterm
References⚓︎
https://www.xmodulo.com/how-to-speed-up-x11-forwarding-in-ssh.html