Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Windowless Custom Wishes

4 views
Skip to first unread message

Perry Wagle

unread,
Sep 17, 1996, 3:00:00 AM9/17/96
to

Hi --

I've built my own wish, called simple_wish at the moment, with my own
custom commands. I'm still prototyping, but what I think I want to do
is to build a server application that runs a simple_wish script that
runs on a system that doesn't necessarily have a display manager
running, or at least one whose user cares about my server.

Client applications are on other machines, and are either "automatic",
or "manual". The automatic client applications have no human
peripheral units (8-) and probably don't have X displays either. But
the manual clients do have both humans and X displays, and want to
both display windows on the client machine X display, and have the
SERVER application display windows there also.

So the client needs to hand the server the DISPLAY, and the XAuth
magic cookies, and have it pop up windows on that DISPLAY.

Thats the scenario.

My question is, how do I start up the SERVER simple_wish script with
NO display attached initially? (And potentially will have zero to N
displays, one per manual client, attached at a given time, but I don't
see difficulty varying the number once I figure out how to do zero).

At the moment, I'm thinking in terms of delaying executing Tk_Init,
Tk_Main, etc, but that seems to be a hack, and likely to bite me in
the future even if it works out now. I also have the feeling that
display-less X11 applications weren't Really Intended To Work by the X
Consortium, or whoever God is in these matters.

Can I do this for TCL/TK applications? Whats the Right Way To Do It?

-- Perry Wagle, Geophysics, Indiana University Geology Department
wa...@indiana.edu

Kris Bosland

unread,
Sep 18, 1996, 3:00:00 AM9/18/96
to

[incr tcl] 2.0+ has run-time Tk loading working (actually, I think
that you only need the plus-patch, by Jan Nijtmans).

-Kris Bosland <kr...@aimnet.com>

Donal K. Fellows

unread,
Sep 19, 1996, 3:00:00 AM9/19/96
to

[ Courtesy Cc:ed ]

In article <6899@843019376>, Perry Wagle <wa...@cs.indiana.edu> wrote:
> I've built my own wish, called simple_wish at the moment, with my own
> custom commands. I'm still prototyping, but what I think I want to do
> is to build a server application that runs a simple_wish script that
> runs on a system that doesn't necessarily have a display manager
> running, or at least one whose user cares about my server.
>
> Client applications are on other machines, and are either "automatic",
> or "manual". The automatic client applications have no human
> peripheral units (8-) and probably don't have X displays either. But
> the manual clients do have both humans and X displays, and want to
> both display windows on the client machine X display, and have the
> SERVER application display windows there also.

So you have this server somewhere, and you want to have two kinds of
client accessing it, one of which is suited for automation, and the
other of which is designed for people. You also want the server to be
able to cause some kind of extra display of windows when the GUI
client is the one connecting.

> So the client needs to hand the server the DISPLAY, and the XAuth
> magic cookies, and have it pop up windows on that DISPLAY.
>
> Thats the scenario.

This is where you are running into trouble, as X security is not
designed to work that way, and indeed, what you are describing is a
disgusting security hole (in principle, if nothing else). Your whole
proposed mechanism is broken.

The following are my suggestions for what to do instead:
1. Make the server a TCP/IP-based server (eg. using tclsh7.5)
2. Get the clients to tell the server what sort of client they are
3. Allow the graphical client to perform actions on the behalf of
the server (there are _lots_ of options for how to do this...) but
the server itself should not have direct access to the client's
display.

I assume that you were going to do #1 and #2 anyway, but you had #3
the wrong way round.

This scheme has the advantage of being far more platform-independant
than relying on the far end running X, and should solve all your
problems, mow the lawn, clean out the cat's litter, put out the trash,
wash the dishes, ... (well, maybe I'm selling it a little too hard :^)

Donal.
--
Donal K. Fellows http://r8h.cs.man.ac.uk:8000/ (SAY NO TO COMMERCIAL SPAMS!)
(work) fell...@cs.man.ac.uk Dept. Comp. Sci, Univ. Manchester, U.K.
| do...@ugglan.demon.co.uk 6,Randall Place, Heaton, Bradford, U.K. (home)
+-> ++44-161-275-6137 Send correspondence to my office ++44-1274-401017 <-+

0 new messages