[gpm]GNU screen and libgpm

Alessandro Rubini rubini@gnu.org
Mon, 1 Oct 2001 12:14:50 +0200


> Hi. Please include the following in TODO:
> - Add GNU screen support to libgpm.

It's not a matter of modifying libgpm (well, it's not *only* libgpm at
least).

The problem is in screen mapping a pseudo-tty to a "real" tty (real
like virtual consoles are real, at least).  So, while you can enable
libgpm to accept ptys in addition to ttys, you still need to know
which pty is currently "foreground" at each mouse event.

The only solution I see is in having screen notify gpm at startup and
at each change of foreground pty, and gpm telling apart the various
clients that request the same tty, so it can send events to the right
client.

While not trivial, this may also easily open security risks, as gpm
clients that work inside screen have no authority over the tty (since
they live in a pty instead) and it's not easily solved -- at least I
have no solution in mind right ahead.

Please note, however, that I don't even know what the current
mechanism for authorization is. The current machinery has been put in
place when Ian Zimmermann was maintainer, and I didn't ever invest
time to actually understand it, since it has always worked.

/alessandro, who's much more ignorant than he likes to appear