Skip to content

fix: don't use all permissions for socket#810

Open
justinrubek wants to merge 2 commits intocloudflare:mainfrom
justinrubek:fix-socket-perms
Open

fix: don't use all permissions for socket#810
justinrubek wants to merge 2 commits intocloudflare:mainfrom
justinrubek:fix-socket-perms

Conversation

@justinrubek
Copy link

The call to fchmodat for the upgrade socket was panicking in my systemd service. I had set RestrictSUIDSGID which doesn't allow for setting stat::Mode::all (which is 0o7777 and sets the special bits).

I believe we should only need the permission bits for the socket and not the execute bits set. This only requires 0o666 (rw-rw-rw-) to function since the execute bits and special bits don't have an effect on connecting or communicating through the socket. In my testing this was sufficient to function and I was able to use RestrictSUIDSGID with the service.

@drcaramelsyrup drcaramelsyrup added the enhancement New feature or request label Feb 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants