Granting X11 access fails under SSH
- Found in: 1.18
CategoryFixed: fixed in 736 for release 1.19
Steps to reproduce:
Log in to a machine with ssh -X (enabling X forwarding)
pola-run -B --x11 --net -e xclock
Expected result: xclock works, just as if it wasn't wrapped with pola-run.
Actual result:
X11 connection rejected because of wrong authentication. X connection to localhost:11.0 broken (explicit kill or server shutdown).
Note that using pola-run -fw / -e xclock does work.
The reason for this is that SSH sets up environment variables differently to a local X session. A local X session (e.g. using gdm) sets XAUTHORITY to $HOME/.Xauthority. SSH leaves XAUTHORITY unset, and Xlib takes XAUTHORITY as defaulting to $HOME/.Xauthority.
When the --x11 option is used, pola-run grants read access to the file given in XAUTHORITY, but it fails to grant access to $HOME/.Xauthority when XAUTHORITY is set.
The same problem occurs with plash-pkg-launch which shares the code.
