#88 closed enhancement (fixed)
option to allow different users to share an mmap file and connect via unix domain sockets
Reported by: | Antoine Martin | Owned by: | Antoine Martin |
---|---|---|---|
Priority: | minor | Milestone: | 0.1 |
Component: | core | Version: | 0.1.0 |
Keywords: | Cc: |
Description
This requires two things:
- that the user can override the default location for sockets, so they can use
/tmp
instead of~/.xpra
- an option to be able to change the file mask so other users can access the mmap file
Attachments (3)
Change History (8)
Changed 9 years ago by
Attachment: | share-mmap.patch added |
---|
comment:1 Changed 9 years ago by
Outstanding issues and notes:
os.chown(self.mmap_file, -1, s.st_uid)
- shouldn't that beos.chown(self.mmap_file, -1, s.st_gid)
? As we want the gid to match?- agreed to rename
logdir
toconfdir
- moved the "
sockfile
" setup code to the connection classes' "target
" attribute create_unix_domain_socket
is racy: we chmod by name after callingbind
, this should useumask
or a temporary directory. Also, this is a change from previous versions which may affect security, I can't see a problem since ".xpra
" is 0700 and the socket will go there by default, but maybe I am missing something?- the man page needs updating
- the code does not work with "
--no-deamon
"
Updated patch to follow.
Changed 9 years ago by
Attachment: | mmap-patch-3.patch added |
---|
comment:2 Changed 9 years ago by
In patch 3 I have:
Added umask so there is no race condition in create_unix_domain_socket
Updated the man page
comment:3 Changed 9 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
merged with only cosmetic changes in r594
You must have spotted that fchmod was unnecessary in the non-mmap_group codepath: tempfile.NamedTemporaryFile
does it for us (although this isn't documented explicitly in the Python docs..)
Closing, please test and re-open if needed. Thanks!
comment:5 Changed 6 weeks ago by
this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/88
Note: See
TracTickets for help on using
tickets.
original patch from violetse