[ovs-dev] [PATCH] Fix socket permissions on Linux

Terry Wilson twilson at redhat.com
Thu Aug 16 22:46:04 UTC 2018


>> Surely there's a better way to do this.
>
> I *hope* so. I mean it certainly seems like something one would want
> to be able to do, but I remember looking for a couple of days 2 years
> ago and giving up. umask seemed like the only reliable option.
> Whatever the solution is, fchmod is *not* it since it is specifically
> undefined behavior to use it on a socket. I'll try with ubuntu and see
> what happens there, but wouldn't imagine it to be different.

BTW, I should mention "reliable" above is assuming you want to set
permissions before the file shows up on the filesystem. using chmod on
the bind_path works, it's just that theoretically the file could be
moved, etc.

Terry


More information about the dev mailing list