Thank very much Nicholas for your prompt and enlightning reply. Though i'm sure any technical issues can be solved in due time (like, in the case of sockets then if one is not enough, how about two? so we can split function among them... Well i'm not developer over here and lack the required background for scrutiny so i drop my search here)
The fact is, though without the convenience of following the rights pattern of the OS, the -r option you gave me works fine for my use case. Why? Well, i just tested and : . with "tmux attach -r" i can get into the session . but i cannot interact with the apps in that session . and the only command i could issue towards the tmux server was to detach ... and i guess, not tested fully only with the creator's keybindings . and no access to command mode (default ":") or other binding (not even "?" !) Going back to Beth and Bob's story, I see a solution this way : 1. Beth (or the server'a admin) creates a dumb user BILL in GUSERS BILL login shell has to be something along the lines of : /bin/tmux attach -r 2. Bob will then connect as BILL and, upon loging in, be thrown right into the current session... read-only so that he can only watch or leave. I still saw a problem : as BILL detaches from the session, tmux restores the permission flags for the socket! so BILL cannot re-attach if session opened by BETH... It might be solved by adding another layer of scripting but am I not missing some other crucial option that would make it some much more... you know, palatable. However this can go, I'm already satisfied and happy with your answer. Have a nice and peaceful time. JClu 20140329 ----- Nicholas Marriott <nicholas.marri...@gmail.com> wrote : > Both read and write permission is needed on the socket to attach and > this cannot be changed. > > You can attach with -r (tmux attach -r) to attach readonly which is a > convenience to prevent accidental interference. > > Do not give people you do not trust access to your tmux socket, readonly > or not. > > > > On Fri, Mar 28, 2014 at 11:39:31PM +0100, c...@free.fr wrote: > > Good Day everyone! > > As a seli-starter with tmux, i'll expose my use case by a little scenario : > > + Beth is working on a project and wants to show it to Bob > > + but she doesn't want Bob to do anything on it (read only). > > > > I thought i'd be able to achieve such a situation by using Sockets : > > 1. BETH and BOB are two users on the server and > > > > 2. both belong to group GUSERS > > > > 3. here is what Beth could do : > > _BETH$ tmux -S $tm/sBETH > > _BETH$ ls -l $tm > > _total 0 > > _srw-rw---- 1 BETH GUSERS 0 Mar 28 22:32 sBETH > > and Bob side : > > -BOB$ tmux -S $tm/sBETH attach > > Here goes Bob on Beth's session. But this way GUSER has rw permissions > > and > > thus BOB can modify sBETH's related session > > > > 4. Then Beth tries this : > > _BETH$ chmod g-w $tm/sBETH > > _BETH$ ls -l $tm > > _total 0 > > _srw-r----- 1 BETH GUSERS 0 Mar 28 22:32 sBETH > > So the rest of GUSER can only read from sBETH > > 5. Well, unfortunately it goes further as, when Bob tries to attach to > > the session here is what he gets : > > _BOB$ ls -l $tm > > _total 0 > > _srw-r----- 1 BETH GUSERS 0 Mar 28 22:32 sBETH > > -BOB$ tmux -S $tm/sBETH attach > > server not found: Permission denied > > So, Bob cannot even access Beth's session in a read only way... > > > > Is there a way to do it without resorting to VPS which still leaves > > sessions rw? > > If not can i make a request for its implementation? > > > > And i understand that this way Bob has no way to tell tmux that he wants to > > detach... nevermind, > > this is read-only so he just kills his connection (^Z then kill -9 %1 or > > something). > > of course a proper way to still interact with tmux till the end would be > > much appreciated. > > > > FYI this case is the common one when doing presentations, showing things to > > students or friends. > > > > thank you > > > > JClu > > 20140328 > > > > PS: please, as I'm new here, if this was'nt the right place to present my > > case, could > > you be so kind as to show me the way to proceed the correctly. Thanks > > in advance. > > > > ------------------------------------------------------------------------------ > > _______________________________________________ > > tmux-users mailing list > > tmux-users@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/tmux-users ------------------------------------------------------------------------------ _______________________________________________ tmux-users mailing list tmux-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/tmux-users