Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
Trac
Trac
  • Project overview
    • Project overview
    • Details
    • Activity
  • Issues 246
    • Issues 246
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Operations
    • Operations
    • Metrics
    • Incidents
  • Analytics
    • Analytics
    • Value Stream
  • Wiki
    • Wiki
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Create a new issue
  • Issue Boards

GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

  • Legacy
  • TracTrac
  • Issues
  • #17950

Closed (moved)
Open
Opened Dec 29, 2015 by teor@teor

Make address family search more accurate

Tor searches local interfaces for IPv4/IPv6 addresses, but it often retrieves all addresses, then filters for IPv4/IPv6.

We could make this more efficient for some of the interface address functions:

  • getifaddrs doesn't take an address family, but we can check the address families of the returned addresses
  • ioctl(.,SIOCGIFCONF,.) only supports AF_INET6 on AIX, or on HP-UX and Solaris with SIOCGLIFCONF, and otherwise only returns IPv4 addresses
  • GetAdaptersAddresses (Win32) takes an address family as its first argument
  • tor_getsockname/get_interface_address6_via_udp_socket_hack takes an address family as its first argument

A design for this could be:

  • pass the address family to get_interface_addresses_raw
  • pass the address family to the API-specific functions that take an address family, or when converting the address to a smartlist, include/exclude addresses matching the specified address families
To upload designs, you'll need to enable LFS and have admin enable hashed storage. More information
Assignee
Assign to
Tor: 0.2.8.x-final
Milestone
Tor: 0.2.8.x-final
Assign milestone
Time tracking
None
Due date
None
Reference: legacy/trac#17950