Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I've been looking at the issues with running xrdp as a non-root user, and comparing #16, neutrinolabs/xrdp#464 and the debian packaging patches (https://anonscm.debian.org/cgit/pkg-remote/xrdp.git/tree/debian/patches/fix_perms.diff).
I'm contemplating running xrdp as a non-root user on other distros (e.g. redhat) who don't take the step of patching the package, and was hoping this might be fixable upstream?
I appreciate that the project is reluctant to change the permissions/bits on the whole socketdir directory, but was wondering if just this simple change to the socket itself would be acceptable?
Since the code that creates the socketdir does nothing if the socket already exists, it's easy to make the directory with appropriate permissions before starting the daemon. However there's no way to modify the socket perms without patching, or something a bit more hacky (inotify script, ld_preload library) etc.
I'm fairly sure this change is 'safe' as it should have no effect unless the directory changes have also been made.
Thanks for considering this request!