Share screen session with users in the same group (Linux)
Yes, it is possible, but your screen should have suid bit on and this has some security implications. Basically you should do the following in order to be able to share a screen session:
chmod u+s /usr/bin/screen
Then as a user (let's suppose that its username is user1), you should run screen and run the following two commands in it:
<ctrl+a>:multiuser on
<ctrl+a>:acladd user2
Finally, user2 should be able to connect to the session with the following command:
screen -x user1/
You can find more information here.
You can enable multiuser mode either via .screenrc, or within the session by using Ctrl+a : with multiuser on
. Access can then be controlled by adding individual users with acladd user2
, or by re-creating group lists within screen acls (aclgrp
).
I do not believe there is a way to directly use unix groups for screen multiuser ACLs.
See man screen
or http://aperiodic.net/screen/multiuser