0

No xauth program; cannot forward X11

I got the following error when tried the command.

$ ssh -v -X name@host
...
debug1: No xauth program.
Warning: No xauth data; using fake authentication data for X11 forwarding.
...

According to the above, I have the following line in /etc/ssh/sshd_config on the host already. Does anybody know how to fix this problem?

$ grep  XAuthLocation /etc/ssh/sshd_config
XAuthLocation /usr/bin/xauth
$ which xauth
/usr/bin/xauth
$ xauth version
1.1
user1424739
  • 215
  • 1
  • 3
  • 10

2 Answers2

0

https://stackoverflow.com/questions/39622173/cant-run-ssh-x-on-macos-sierra

The above answer is relevant. I am using Catalina. The following lines need to added in /etc/ssh/ssh_config under the Host * entry.

XAuthLocation /opt/X11/bin/xauth
ServerAliveInterval 60
ForwardX11Timeout 596h
user1424739
  • 215
  • 1
  • 3
  • 10
-1

Install xauth on target host. Both sites have to have xauth installed to exchange/verify f.ex. MIT-MAGIC-COOKIE-1.

nutilius
  • 107
  • 4
  • xauth is already installed on the target host. – user1424739 Mar 05 '21 at 19:10
  • Did you check more verbose diagnostic info like: ssh -vvv host-addr – nutilius Mar 05 '21 at 19:15
  • -vvv doesn't show anything useful in addition. – user1424739 Mar 05 '21 at 19:23
  • So you have on both sides xauth installed. What do you have in ~/.ssh/config - maybe you have dedicated xauth there? BTW debug3 should show you where xauth is looked for – nutilius Mar 05 '21 at 19:37
  • I don't see any debug3 mentioning xauth other than the info that I showed in my original post. What debug3 info I should look for? ~/.ssh/config in my local machine has a set of hosts, but the one that I try to access is not there. – user1424739 Mar 05 '21 at 21:00