[tor-bugs] #17562 [Tor]: DataDirectory permissions are too restrictive when using CapabilityBoundingSet or SELinux

Tor Bug Tracker & Wiki blackhole at torproject.org
Mon Nov 9 13:51:28 UTC 2015


#17562: DataDirectory permissions are too restrictive when using
CapabilityBoundingSet or SELinux
------------------------+------------------------------------
 Reporter:  jamielinux  |          Owner:
     Type:  defect      |         Status:  needs_review
 Priority:  Medium      |      Milestone:  Tor: 0.2.8.x-final
Component:  Tor         |        Version:  Tor: unspecified
 Severity:  Normal      |     Resolution:
 Keywords:  tor-core    |  Actual Points:
Parent ID:              |         Points:
  Sponsor:              |
------------------------+------------------------------------
Changes (by nickm):

 * status:  new => needs_review


Comment:

 Replying to [comment:3 jamielinux]:
 > Replying to [comment:2 nickm]:
 > > Yeah, those capabilities should not be given to Tor.  Tor shouldn't
 really need anything besides CAP_NET_BIND_SERVICE.
 >
 > Also `CAP_SETUID`/`CAP_SETGID` for dropping permissions.

 Ah true. BTW, if you know your way around the Privileges system, could I
 ask you to take a look at the most recent patch on the #8195 ticket if you
 have a chance?  It adds an option for Tor servers to keep
 `CAP_NET_BIND_SERVICE` after setuid, and I'd like to make sure we did it
 right.

 > > I think that it's probably okay to allow gid == 0 as an exception for
 when group readable is okay?  Not 100% sure there, for all I know there's
 some horrible unix where gid 0 is unprivileged.  (Is that possible?)
 >
 > That would be horrific.
 >
 >
 > > I'm not too thrilled with changing the default permissions, though:
 those are locked down for a  pretty solid reason.  If we'd like to
 override that, I'd prefer to have it be based on an option than having it
 be always-750.
 >
 > I agree. I propose an alternative patch for it to be optional instead.
 Distribution packagers or administrators who want to use
 CapabilityBoundingSet or SELinux (or some other MAC) can create a
 DataDirectory with the 0750 TorUser:root permissions.

 Thanks, I'll have a look!

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/17562#comment:4>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list