Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Leopard, X11, and ssh -Y causes warning message



I searched and found threads on this topic but I can not get the warning message to go away using what the threads say to do.

If I am in Terminal or an xterm, my DISPLAY is set to something like / tmp/launch-sf4x/:0

This is not in .Xauthority. So, if I do something like "ssh -f -Y remotehost xterm" I get back:

Warning: No xauth data; using fake authentication data for X11 forwarding.

Everything else seems to work fine. And I've read about the cute trick that accessing this socket causes launchd to start up, etc. But ssh is still unhappy.

I have discovered that if I change my display (after X11 is running) to :0, then I do not get the message from ssh.

I kinda want to open a bug report with Apple but wanted to bounce my idea off of this list first.

Could ssh be hacked so that it basically does this for me? i.e. check DISPLAY. If it is set to /tmp/launch.*/:0, then do a cat of the file (or open it or whatever is required), set the DISPLAY to :0, and continue normally.

The alternative I suppose would be to allow me to do:

xauth generate $DISPLAY .

but, currently, xauth complains that $DISPLAY is not a valid display.

I created this script and I have it in my ~/bin directory (which is part of my PATH). It seems to avoid the warning message.

#!/bin/sh

if [[ "$DISPLAY" =~ /tmp/launch-.*/:0 ]] ; then
    cat "$DISPLAY"
    DISPLAY=:0
fi
exec /usr/bin/ssh "$@"

_______________________________________________
Do not post admin requests to the list. They will be ignored.
X11-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/x11-users/email@hidden

This email sent to email@hidden


Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.