Java

## SSH with X11 forwarding
$ ssh -X unixhost1

## Get the display
$ echo $DISPLAY
localhost:11.0

## Extract the xauth entry

## NOTE: you have to leave off localhost here
$ xauth list :11
unixhost1/unix:11 MIT-MAGIC-COOKIE-1 eb8d4ea8ad1f0070a8f7d2f9b3bf04f9

## sudo to required tech id

$ sudo su - sudoUser

## Merge in auth info echoed earlier

$ xauth add unixhost1/unix:11 MIT-MAGIC-COOKIE-1 eb8d4ea8ad1f0070a8f7d2f9b3bf04f9

## Set display

## NOTE: without localhost this won't work
$ export DISPLAY localhost:11.0

## Run an X command

$ xterm