aboutsummaryrefslogtreecommitdiff
path: root/src
Commit message (Collapse)AuthorAge
...
| | * | | | | | | | | Merge remote-tracking branch 'public/bug10169_023' into bug10169_024Nick Mathewson2014-02-12
| | |\| | | | | | | |
| | | * | | | | | | | Actually release buffer freelists when handling OOM conditions.Nick Mathewson2014-02-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise freeing buffers won't help for a little while.
| | | * | | | | | | | Fix bugs in bug10169 bugfix memory trackingNick Mathewson2014-02-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The chunk_grow() and chunk_copy() functions weren't adjusting the memory totals properly. Bugfix not on any released Tor version.
| | * | | | | | | | | Merge remote-tracking branch 'public/bug10169_023' into bug10169_024Nick Mathewson2014-01-03
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: doc/tor.1.txt src/or/config.c src/or/or.h The conflicts were all pretty trivial.
| | | * | | | | | | | Drop the MaxMemInQueues lower limit down to 256 MB.Nick Mathewson2013-11-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | on #9686, gmorehose reports that the 500 MB lower limit is too high for raspberry pi users.
| | | * | | | | | | | Rename MaxMemInCellQueues to MaxMemInQueuesNick Mathewson2013-11-20
| | | | | | | | | | |
| | | * | | | | | | | doxygen comments for 10169 codeNick Mathewson2013-11-20
| | | | | | | | | | |
| | | * | | | | | | | Count freed buffer bytes from buffers when oom-killing circuits.Nick Mathewson2013-11-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Also, aggressively clear the buffers to try to make their bytes go away fast rather than waiting for the close-marked-connection code to get 'em.
| | | * | | | | | | | Have the OOM handler also count the age the data in a stream bufferNick Mathewson2013-11-15
| | | | | | | | | | |
* | | | | | | | | | | ATTR_NORETURN is needed on lost_owning_controller nowNick Mathewson2014-03-03
| |_|_|_|_|_|/ / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This should fixes some "hey, that function could have __attribute__((noreturn))" warnings introduced by f96400d9. Bug not in any released version of Tor.
* | | | | | | | | | Fix compilation warnings in tor_addr_make_null patchNick Mathewson2014-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There was one "missing prototype" warning because the test function wasn't static, and one "unused parameter" warning about the "data" parameter. Also, I added a couple of tests to make sure that the "make_null" addresses really were the addresses we expected, by formatting them as strings.
* | | | | | | | | | add test for tor_addr_make_nullKevin Murray2014-03-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Signed-off-by: Kevin Murray <spam@kdmurray.id.au>
* | | | | | | | | | trivial whitespace fixesRoger Dingledine2014-03-03
| |_|_|_|_|_|_|_|/ |/| | | | | | | |
* | | | | | | | | whitespace fixNick Mathewson2014-02-28
| | | | | | | | |
* | | | | | | | | Merge branch 'bug10884_squashed'Nick Mathewson2014-02-28
|\ \ \ \ \ \ \ \ \
| * | | | | | | | | Unit tests for test_routerkeys_write_fingerprintNick Mathewson2014-02-28
| | | | | | | | | |
| * | | | | | | | | Unit tests for pk fingerprint functionsNick Mathewson2014-02-28
| | | | | | | | | |
| * | | | | | | | | Tighten router_write_fingerprint implNick Mathewson2014-02-28
| | | | | | | | | |
| * | | | | | | | | Write hashed bridge fingerprint to logs and to disk.Karsten Loesing2014-02-28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implements #10884.
* | | | | | | | | | Merge remote-tracking branch 'karsten/task-5824'Nick Mathewson2014-02-28
|\ \ \ \ \ \ \ \ \ \ | |/ / / / / / / / / |/| | | | | | | | |
| * | | | | | | | | Report complete directory request statistics on bridges.Karsten Loesing2013-12-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we wrote the directory request statistics code in August 2009, we thought that these statistics were only relevant for bridges, and that bridges should not report them. That's why we added a switch to discard relevant observations made by bridges. This code was first released in 0.2.2.1-alpha. In May 2012 we learned that we didn't fully disable directory request statistics on bridges. Bridges did report directory request statistics, but these statistics contained empty dirreq-v3-ips and dirreq-v3-reqs lines. But the remaining dirreq-* lines have always been non-empty. (We didn't notice for almost three years, because directory-request statistics were disabled by default until 0.2.3.1-alpha, and all statistics have been removed from bridge descriptors before publishing them on the metrics website.) Proposal 201, created in May 2012, suggests to add a new line called bridge-v3-reqs that is similar to dirreq-v3-reqs, but that is published only by bridges. This proposal is still open as of December 2013. Since October 2012 we're using dirreq-v3-resp (not -reqs) lines in combination with bridge-ips lines to estimate bridge user numbers; see task 8462. This estimation method has superseded the older approach that was only based on bridge-ips lines in November 2013. Using dirreq-v3-resp and bridge-ips lines is a workaround. The cleaner approach would be to use dirreq-v3-reqs instead. This commit makes bridges report the same directory request statistics as relays, including dirreq-v3-ips and dirreq-v3-reqs lines. It makes proposal 201 obsolete.
| * | | | | | | | | Disable (Cell,Entry,ExitPort)Statistics on bridgesKarsten Loesing2013-12-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In 0.2.3.8-alpha we attempted to "completely disable stats if we aren't running as a relay", but instead disabled them only if we aren't running as a server. This commit leaves DirReqStatistics enabled on both relays and bridges, and disables (Cell,Entry,ExitPort)Statistics on bridges.
* | | | | | | | | | Merge remote-tracking branch 'public/bug10449'Nick Mathewson2014-02-25
|\ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | bug10449: a dying owning controller makes Tor exit immediatelyNick Mathewson2014-02-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If you want a slow shutdown, send SIGNAL SHUTDOWN. (Why not just have the default be SIGNAL QUIT? Because this case should only happen when an owning controller has crashed, and a crashed controller won't be able to give the user any "tor is shutting down" feedback, and so the user gets confused for a while. See bug 10449 for more info)
* | | | | | | | | | | Trivial comment fix.Nick Mathewson2014-02-25
| | | | | | | | | | |
* | | | | | | | | | | Merge remote-tracking branch 'public/bug11048'Nick Mathewson2014-02-25
|\ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | Threadproof our log_backtrace implementationNick Mathewson2014-02-24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's possible for two threads to hit assertion failures at the same time. If that happens, let's keep them from stomping on the same cb_buf field. Fixes bug 11048; bugfix on 0.2.5.2-alpha. Reported by "cypherpunks".
* | | | | | | | | | | | Merge remote-tracking branch 'karsten/geoip2regcountry'Nick Mathewson2014-02-25
|\ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | Fall back to registered country if necessary.Karsten Loesing2014-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When extracting geoip and geoip6 files from MaxMind's GeoLite2 Country database, we only look at country->iso_code which is the two-character ISO 3166-1 country code of the country where MaxMind believes the end user is located. But if MaxMind thinks a range belongs to anonymous proxies, they don't put anything there. Hence, we omit those ranges and resolve them all to '??'. That's not what we want. What we should do is first try country->iso_code, and if there's no such key, try registered_country->iso_code which is the country in which the ISP has registered the IP address. In short: let's fill all A1 entries with what ARIN et. al think.
* | | | | | | | | | | | | Merge remote-tracking branch 'origin/maint-0.2.4'Nick Mathewson2014-02-25
|\ \ \ \ \ \ \ \ \ \ \ \ \ | | |_|_|_|_|_|_|_|_|_|/ / | |/| | | | | | | | | | |
| * | | | | | | | | | | | Merge remote-tracking branch 'origin/maint-0.2.3' into maint-0.2.4Nick Mathewson2014-02-25
| |\ \ \ \ \ \ \ \ \ \ \ \
| | * | | | | | | | | | | | Fix geoip by falling back to registered countries.Karsten Loesing2014-02-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | See 1d2179bc900f1646a5491b65294e78b175e70056 in master for details. """ Fall back to registered country if necessary. When extracting geoip and geoip6 files from MaxMind's GeoLite2 Country database, we only look at country->iso_code which is the two-character ISO 3166-1 country code of the country where MaxMind believes the end user is located. But if MaxMind thinks a range belongs to anonymous proxies, they don't put anything there. Hence, we omit those ranges and resolve them all to '??'. That's not what we want. What we should do is first try country->iso_code, and if there's no such key, try registered_country->iso_code which is the country in which the ISP has registered the IP address. In short: let's fill all A1 entries with what ARIN et. al think. """
| * | | | | | | | | | | | | Merge remote-tracking branch 'public/feature9777_024_squashed' into maint-0.2.4Nick Mathewson2014-02-24
| |\ \ \ \ \ \ \ \ \ \ \ \ \
* | | | | | | | | | | | | | | Download MaxMind's geoip file over https.Karsten Loesing2014-02-25
| |_|_|/ / / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the cert turns out to be invalid or if wget is otherwise unable to verify it, it's going to return an error and not download the file for us. Spotted by nickm.
* | | | | | | | | | | | | | Include instructions on generating geoip files.Karsten Loesing2014-02-21
| |_|_|/ / / / / / / / / / |/| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implements #10924.
* | | | | | | | | | | | | When not an exit node, don't test for DNS hijacking.Nick Mathewson2014-02-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Back in 5e762e6a5c0e6729bb7dbb586af2690c087d9ba8, non-exit servers stopped launching DNS requests for users. So there's no need for them to see if their DNS answers are hijacked. Patch from Matt Pagan. I think this is a 965 fix.
* | | | | | | | | | | | | Merge remote-tracking branch 'public/bug10987_024'Nick Mathewson2014-02-21
|\ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | Style tweaks on code, changes file for 10987Nick Mathewson2014-02-21
| | | | | | | | | | | | | |
| * | | | | | | | | | | | | Fix: send back correct IPv6 SOCKS5 connect replyDavid Goulet2014-02-21
| |/ / / / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For a client using a SocksPort connection and IPv6, the connect reply from tor daemon did not handle AF_INET6 thus sending back the wrong payload to the client. A changes file is provided and this fixes #10987 Signed-off-by: David Goulet <dgoulet@ev0ke.net>
* | | | | | | | | | | | | fixed long -> int implicit cast warning line 3453Nick Hopper2014-02-20
| | | | | | | | | | | | |
* | | | | | | | | | | | | Restitute a successful stat call to this test case.dana koch2014-02-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since the first stat call is made for it to deliberately fail, and we reference st.st_mode without st having valid data, st.st_mode can contain garbage and cause chmod to fail with EINVAL. We rerun stat and ensure it succeeded. Also make use of tt_abort_perror, to properly convey failure reasons to the user.
* | | | | | | | | | | | | Appropriately condition the _le64toh macro definition for OpenBSD.dana koch2014-02-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This corrects a linker error on OpenBSD, where the function is called letoh64. See also http://git.kernel.org/cgit/docs/man-pages/man-pages.git/tree/man3/endian.3#n84.
* | | | | | | | | | | | | mingw fix: Rename a variable in the unit testsNick Mathewson2014-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Apparently, MS C is #defining "IN" on us, so we can't name a variable IN. Delightful!
* | | | | | | | | | | | | Merge remote-tracking branch 'public/bug10722'Nick Mathewson2014-02-16
|\ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | Warning message when bug 10722 would triggerNick Mathewson2014-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If somebody's excludenodes settings are keeping their hidden service connections from working, they should probably get notified about it.
* | | | | | | | | | | | | | Merge branch 'bug4900_siphash_v2'Nick Mathewson2014-02-15
|\ \ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | | Remove string hash in ht.h so we can't accidentally use itNick Mathewson2014-02-15
| | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | Randomize the global siphash key at startupNick Mathewson2014-02-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This completes our conversion to using siphash for our hash functions.
| * | | | | | | | | | | | | | Split crypto_global_init() into pre/post configNick Mathewson2014-02-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's increasingly apparent that we want to make sure we initialize our PRNG nice and early, or else OpenSSL will do it for us. (OpenSSL doesn't do _too_ bad a job, but it's nice to do it ourselves.) We'll also need this for making sure we initialize the siphash key before we do any hashes.
| * | | | | | | | | | | | | | Siphash-2-4 is now our hash in nearly all cases.Nick Mathewson2014-02-12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I've made an exception for cases where I'm sure that users can't influence the inputs. This is likely to cause a slowdown somewhere, but it's safer to siphash everything and *then* look for cases to optimize. This patch doesn't actually get us any _benefit_ from siphash yet, since we don't really randomize the key at any point.