#14186: Try to use fchmod() first when changing permissions on an AF_UNIX socket -------------------------------------------------+------------------------- Reporter: andrea | Owner: Type: defect | Status: new Priority: Medium | Milestone: Tor: | unspecified Component: Core Tor/Tor | Version: Tor: | 0.2.6.2-alpha Severity: Normal | Resolution: Keywords: tor-client tor-relay posix | Actual Points: permissions | Parent ID: | Points: Reviewer: | Sponsor: -------------------------------------------------+-------------------------
Comment (by f55jwk4f): nickm, it seems like you are the one who added the comment saying fchmod doesn't work on all platforms. So exactly on which platforms do fchmod doesn't work but chmod does? On these platforms, does chmod actually prevent processes without proper permissions to access the socket? I found that some operating systems don't honor permissions on unix sockets. (https://groups.google.com/d/topic/nodejs/6wXjU1n9U3w) And Posix says "may" for this case. Linux has commit 5822b7faca709c03a59c2929005bfe9caffe6592 which says we can fchmod before bind. -- Ticket URL: <https://trac.torproject.org/projects/tor/ticket/14186#comment:14> Tor Bug Tracker & Wiki <https://trac.torproject.org/> The Tor Project: anonymity online _______________________________________________ tor-bugs mailing list tor-bugs@lists.torproject.org https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs