svlug_secure_X_displays

This is part of The Pile, a partial archive of some open source mailing lists and newsgroups.



From: Robert Hajime Lanning <lanning@lanning.cc>
Subject: Re: [svlug] esoteric X question
To: steffl@bigfoot.com (Erik Steffl)
Date: Sun, 25 Feb 2001 15:12:27 -0800 (PST)
Cc: svlug@svlug.org

Erik Steffl wrote::
> 
> Jonathan Cobb wrote:
> > 
> > Wondering if there is any way to change the display for an application
> > AFTER you've started it.
> > 
> > Here's an example:
> > 
> > I'm at my desktop computer.  I ssh into some remote box and set the
> > DISPLAY env variable to be my desktop's display.  I can then run X
> > applications on the remote machine and the display goes to my desktop
> > (and securely with X11 forwarding over ssh).  Very common/handy
> > technique.
> > 
> > Problem:  Let's say I leave my office with the X applications still up,
> > and later in the day I'm logged in to another machine somewhere else in
> > the building, far from my office.  I can ssh into the same remote box
> > and start other X apps there, but is it possible to see my applications
> > that are running on the remote box but displayed elsewhere (my
> > desktop)?  In other words, can you change the effective DISPLAY for an X
> > application AFTER it has started?
> > 
> > I haven't been able to find any info on this.  Any help appreciated.
> 
>  obvious answer is vnc, it's not exactly what you want but it's similar
> and you might be able to use it to solve your problem.
> 
>   I think I've read something about some X proxy or something like that
> that bascially sits between app and server and if the server breaks
> connection you can reconnect to the proxy (the application does only
> have connection to proxy so it does not know server connection died).
> don't remember the name but at least you know there is sometyhing like
> that. happy freshmeating!

two problems with this is bit depth and geometry.  VNC will
work best.  Otherwise if the two displays are not identical
in this matter the graphics context will not work properly.

also, setting the DISPLAY variable to the desktop bypasses
ssh.  To do the secure/encrypted ssh X forwarding you must
allow ssh to automaticaly set your DISPLAY variable.  If you
have X setup on your desktop and ssh from it, ssh will use
your local .Xauthority file to get the key to connect to the
local X server then it will connect to the remote server and
run xauth to place a new key in the remote .Xauthority file
and set the remote DISPLAY variable to be :10 or something
the likes. (depends on how many ssh connections are
forwarding X) In essence the ssh daemon (sshd or ssh2d) by
default will act as an Xserver and setup the forwarding
automaticly when it can.


===

Date: Sun, 25 Feb 2001 18:23:51 -0800 (PST)
From: "Dagmar d'Surreal" <dagmar@dsurreal.org>
To: Erik Steffl <steffl@bigfoot.com>
Subject: Re: [svlug] esoteric X question

On Fri, 23 Feb 2001, Erik Steffl wrote:

> Jonathan Cobb wrote:
...(some snippage)...
> > that are running on the remote box but displayed elsewhere (my
> > desktop)?  In other words, can you change the effective DISPLAY for an X
> > application AFTER it has started?
> > 
> > I haven't been able to find any info on this.  Any help appreciated.
> 
>  obvious answer is vnc, it's not exactly what you want but it's similar
> and you might be able to use it to solve your problem.
> 
>   I think I've read something about some X proxy or something like that
> that bascially sits between app and server and if the server breaks
> connection you can reconnect to the proxy (the application does only
> have connection to proxy so it does not know server connection died).
> don't remember the name but at least you know there is sometyhing like
> that. happy freshmeating!


I suspect part of the reason is that a great number of X apps make
assumptions about what kind of colors they can get away with using *after*
they have connected to the display.  If one tries to move them to a
different display, they will encounter "issues".


===


the rest of The Pile (a partial mailing list archive)

doom@kzsu.stanford.edu