* JCA <[EMAIL PROTECTED]> [2005-08-04 11:49 -0700]:
>   When I establish a connection by means of ssh, from a host A to a
> host B, I can use the output from the 'who am i' command in B so that
> in the shell created in B by the connection, the DISPLAY variable is
> set so that the output from X commands in B is sent to A.

Might I suggest using X11 forwarding through ssh instead?  Either run
'ssh -X B.domain.org' or set ForwardX11 to "yes" in your ~/.ssh/config.
(All assuming you run OpenSSH or SSH.com's SSH1.)  This will cause ssh to
set up $DISPLAY for you.  You also get the benefit of having your X
traffic encrypted, too.

> I thought that one could encode such data by means of the -S option to
> screen, but the problem is that, once the shell created under screen is
> up and running, I do not know how to retrieve that information.

You can get the IP address of of the ssh client in the environment
variable $SSH_CLIENT.  From that, you should be able to set your
$DISPLAY.  But I really recommend using ssh for it if you can.

-- 
...computer contrarian of the first order... / http://aperiodic.net/phil/
PGP: 026A27F2  print: D200 5BDB FC4B B24A 9248  9F7A 4322 2D22 026A 27F2
--- --
  /"\
  \ /
   x  ascii ribbon campaign against html e-mail 
  / \
---- --- --


_______________________________________________
screen-users mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/screen-users

Reply via email to