1. 28 Jan, 2016 1 commit
  2. 15 Dec, 2015 1 commit
  3. 07 Dec, 2015 1 commit
  4. 18 Nov, 2015 2 commits
  5. 29 Sep, 2015 2 commits
    • teor (Tim Wilson-Brown)'s avatar
      Add checks and unit tests for get_interface_address* failure · 7fa102b4
      teor (Tim Wilson-Brown) authored and Nick Mathewson's avatar Nick Mathewson committed
      Ensure that either a valid address is returned in address pointers,
      or that the address data is zeroed on error.
      
      Ensure that free_interface_address6_list handles NULL lists.
      
      Add unit tests for get_interface_address* failure cases.
      
      Fixes bug #17173.
      Patch by fk/teor, not in any released version of tor.
      7fa102b4
    • Fabian Keil's avatar
      get_interface_address6_list(): Bring back a return code check · 3ea834ce
      Fabian Keil authored and Nick Mathewson's avatar Nick Mathewson committed
      ... that was removed by 31eb486c which first appeared in
      0.2.7.3-rc.
      
      If tor is running in a ElectroBSD (or FreeBSD) jail it can't
      get any IP addresses that aren't assigned to the jail by
      looking at the interfaces and (by design) the
      get_interface_address6_via_udp_socket_hack() fallback doesn't
      work either.
      
      The missing return code check resulted in tor_addr_is_internal()
      complaining about a "non-IP address of type 49", due to reading
      uninitialised memory.
      
      Fixes #17173.
      3ea834ce
  6. 15 Sep, 2015 4 commits
    • teor (Tim Wilson-Brown)'s avatar
      ExitPolicyRejectPrivate rejects local IPv6 address and interface addresses · 098b82c7
      teor (Tim Wilson-Brown) authored
      ExitPolicyRejectPrivate now rejects more local addresses by default:
       * the relay's published IPv6 address (if any), and
       * any publicly routable IPv4 or IPv6 addresses on any local interfaces.
      
      This resolves a security issue for IPv6 Exits and multihomed Exits that
      trust connections originating from localhost.
      
      Resolves ticket 17027. Patch by "teor".
      Patch on 42b8fb5a (11 Nov 2007), released in 0.2.0.11-alpha.
      098b82c7
    • teor (Tim Wilson-Brown)'s avatar
      ExitPolicy accept6/reject6 produces IPv6 wildcard addresses only · d3358a0a
      teor (Tim Wilson-Brown) authored
      In previous versions of Tor, ExitPolicy accept6/reject6 * produced
      policy entries for IPv4 and IPv6 wildcard addresses.
      
      To reduce operator confusion, change accept6/reject6 * to only produce
      an IPv6 wildcard address.
      
      Resolves bug #16069.
      
      Patch on 2eb7eafc and a96c0aff (25 Oct 2012),
      released in 0.2.4.7-alpha.
      d3358a0a
    • teor (Tim Wilson-Brown)'s avatar
      Ignore accept6/reject6 IPv4, warn about unexpected rule outcomes · e033d5e9
      teor (Tim Wilson-Brown) authored
      When parsing torrc ExitPolicies, we now warn if:
        * an IPv4 address is used on an accept6 or reject6 line. The line is
          ignored, but the rest of the policy items in the list are used.
          (accept/reject continue to allow both IPv4 and IPv6 addresses in torrcs.)
        * a "private" address alias is used on an accept6 or reject6 line.
          The line filters both IPv4 and IPv6 private addresses, disregarding
          the 6 in accept6/reject6.
      
      When parsing torrc ExitPolicies, we now issue an info-level message:
        * when expanding an accept/reject * line to include both IPv4 and IPv6
          wildcard addresses.
      
      In each instance, usage advice is provided to avoid the message.
      
      Partial fix for ticket 16069. Patch by "teor".
      Patch on 2eb7eafc and a96c0aff (25 Oct 2012),
      released in 0.2.4.7-alpha.
      e033d5e9
    • teor (Tim Wilson-Brown)'s avatar
      Add get_interface_address[6]_list for a list of interface IP addresses · 31eb486c
      teor (Tim Wilson-Brown) authored
      Add get_interface_address[6]_list by refactoring
      get_interface_address6. Add unit tests for new and existing functions.
      
      Preparation for ticket 17027. Patch by "teor".
      Patch on 42b8fb5a (11 Nov 2007), released in 0.2.0.11-alpha.
      31eb486c
  7. 31 Jul, 2015 1 commit
    • Nick Mathewson's avatar
      Move formatting functions around. · 347fe449
      Nick Mathewson authored
      The base64 and base32 functions used to be in crypto.c;
      crypto_format.h had no header; some general-purpose functions were in
      crypto_curve25519.c.
      
      This patch makes a {crypto,util}_format.[ch], and puts more functions
      there.  Small modules are beautiful!
      347fe449
  8. 29 Jun, 2015 2 commits
  9. 31 Mar, 2015 3 commits
  10. 16 Feb, 2015 2 commits
  11. 12 Feb, 2015 2 commits
  12. 23 Jan, 2015 1 commit
  13. 07 Jan, 2015 1 commit
  14. 02 Jan, 2015 1 commit
  15. 30 Dec, 2014 1 commit
  16. 29 Dec, 2014 2 commits
  17. 21 Dec, 2014 1 commit
  18. 20 Dec, 2014 1 commit
    • teor's avatar
      Fix clang warning, IPv6 address comment, buffer size typo · 6a9cae2e
      teor authored
      The address of an array in the middle of a structure will
      always be non-NULL. clang recognises this and complains.
      Disable the tautologous and redundant check to silence
      this warning.
      
      A comment about an IPv6 address string incorrectly refers
      to an IPv4 address format.
      
      A log buffer is sized 10024 rather than 10240.
      
      Fixes bug 14001.
      6a9cae2e
  19. 28 Oct, 2014 1 commit
  20. 22 Oct, 2014 1 commit
  21. 25 Sep, 2014 2 commits
  22. 15 Sep, 2014 1 commit
    • Nick Mathewson's avatar
      Clear up another clangalyzer issue · 53a94c4b
      Nick Mathewson authored
      "The NULL pointer warnings on the return value of
      tor_addr_to_in6_addr32() are incorrect. But clang can't work this
      out itself due to limited analysis depth. To teach the analyser that
      the return value is safe to dereference, I applied tor_assert to the
      return value."
      
      Patch from teor.  Part of 13157.
      53a94c4b
  23. 02 Sep, 2014 1 commit
  24. 22 May, 2014 1 commit
    • Nick Mathewson's avatar
      sandbox: revamp sandbox_getaddrinfo cacheing · e425fc78
      Nick Mathewson authored
      The old cache had problems:
           * It needed to be manually preloaded. (It didn't remember any
             address you didn't tell it to remember)
           * It was AF_INET only.
           * It looked at its cache even if the sandbox wasn't turned on.
           * It couldn't remember errors.
           * It had some memory management problems. (You can't use memcpy
             to copy an addrinfo safely; it has pointers in.)
      
      This patch fixes those issues, and moves to a hash table.
      
      Fixes bug 11970; bugfix on 0.2.5.1-alpha.
      e425fc78
  25. 19 Apr, 2014 1 commit
  26. 05 Apr, 2014 1 commit
  27. 27 Mar, 2014 1 commit
  28. 25 Mar, 2014 1 commit
    • Nick Mathewson's avatar
      Fix warnings from doxygen · d5e11f21
      Nick Mathewson authored
      Most of these are simple.  The only nontrivial part is that our
      pattern for using ENUM_BF was confusing doxygen by making declarations
      that didn't look like declarations.
      d5e11f21