The Thoughts of Matt Palmer
So, you have two people who want to share a common terminal, but they don't want to (or can't) bang on the same keyboard and peer at the same screen.
Multiuser screen to the rescue!
You have two users, userH and userG, and one relevant machine, hostH. Both users have a terminal window on hostH (because both users have SSHed in, or one is on the local console, or whatever).
Requirements: ensure that the terminal window is the same size in both cases, and that the screen binary on hostH is SUID root.
UserH (the 'host' user) runs the following:
screen -S <some name>
UserH will then have a running screen session named "<some name>", and must then enable multiuser and allow the other user to connect by typing the following in their screen session:
CTRL-A :multiuser on CTRL-A :addacl userG
Now userG can run the following in their terminal:
screen -r userH/
And now both users are in a common screen session. Both of the users' keyboards will enter characters, so have some sort of out-of-band mechanism for collision avoidance. Either user typing 'exit' will quit the screen session. Remember that the session is running with the permissions of userH (who started the screen session), so don't do this with people you don't trust to peek at your pr0n stash.
posted at: 11:35 | category: /knowledge/software/screen | permalink