[tor-bugs] #17901 [Tor]: Tor would bind ControlPort to public ip address if it has no localhost interface
Tor Bug Tracker & Wiki
blackhole at torproject.org
Tue Dec 29 10:17:19 UTC 2015
#17901: Tor would bind ControlPort to public ip address if it has no localhost
interface
---------------------------------------+-----------------------------------
Reporter: s7r | Owner: teor
Type: defect | Status: assigned
Priority: High | Milestone: Tor:
Component: Tor | 0.2.8.x-final
Severity: Major | Version: Tor: 0.2.7.6
Keywords: 027-backport 026-backport | Resolution:
Parent ID: | Actual Points:
Sponsor: | Points:
---------------------------------------+-----------------------------------
Comment (by yawning):
Replying to [comment:16 teor]:
> Instead of resolving localhost, we could look through all the interfaces
and find the first address present on the system that:
> * is 127.0.0.1, or
> * is in 127/8.
>
> For stability, it would make sense to choose the numerically lowest
valid 127/8 address.
> (That is, exclude 127.0.0.0, and choose the address that is closest to
127.0.0.1.)
On Linux, when you query the interfaces, you can check the per-interface
flags for `IFF_LOOPBACK`. On systems where this information is readily
available (I think we even already have code that uses the relevant
ioctl), we should use that to restrict the set of candidate addresses.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/17901#comment:18>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list