Skip to content

Best practice question - linux user permissions for socket file #2368

Answered by dosvicap
dosvicap asked this question in Q&A
Discussion options

You must be logged in to vote

Answering my own question here. I learned how to use File Access Control Lists to add permissions to a specific group or user for a specific file.

So, after removig www-data from my admin group, I navigated to the rpc socket file path and simply did:

setfacl -m www-data:rwx rpc.socket
setfacl -m g:www-data:rwx rpc.socket

The commands granted read, write, and execute permissions for the www-data user and the www-data group to the socket file and nothing else.

Replies: 3 comments 1 reply

Comment options

You must be logged in to vote
0 replies
Answer selected by dosvicap
Comment options

You must be logged in to vote
1 reply
@dosvicap
Comment options

Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants