I am trying to use Xdm with foreign X server. The content of /etc/X11/xdm/Xservers is:
192.168.251.20:11 foreign
The process of Xdm to get the X resources is spawning Xrdb that supposedly should connect to the X server and ask for the Xresources. The authentication for Xdm and Xrdb is using xauth keys previously registered in both sides.
For a reason that I do not understand, Xrdb called from the command line read the .Xauthorization but exactly the same command spawned by Xdm doesn't.