Commit Graph

893 Commits

Author SHA1 Message Date
Nick Mathewson
bf80e2df3f Replace calls to time(NULL) that occur on the order of once per read, one per write, or once per cell with calls to a function that looks at a cached value of time. This is tricksy to benchmark, since it will only help on systems where time() is a syscall and syscalls are relatively slow.
svn:r17690
2008-12-18 17:19:04 +00:00
Nick Mathewson
ecaee1d927 Remove fixed xxx020s; downgrade unfixed ones.
(The unfixed ones are being downgraded to regular XXXs mainly on the rationale that they don't seem to be exploding Tor, and they were apparently not showstoppers for 0.2.0.x-final.)

svn:r17682
2008-12-18 16:11:03 +00:00
Nick Mathewson
4911ec627b Call release_lockfile() before exiting.
svn:r17679
2008-12-18 15:00:13 +00:00
Nick Mathewson
7d92053286 Remove RedirectExit feature; it has been deprecated since 0.2.0.3-alpha
svn:r17663
2008-12-17 23:02:04 +00:00
Nick Mathewson
2ad36f68c8 Rename ServerDNSAllowBrokenResolvConf to ServerDNSAllowBrokenConfig.
(Many users have no idea what a resolv.conf is, and shouldn't be forced to learn.  The old option will keep working for now.)
Also, document it.

svn:r17661
2008-12-17 22:58:14 +00:00
Nick Mathewson
7678ac5193 Move edge-only flags from connection_t to edge_connection_t.
svn:r17643
2008-12-17 14:59:28 +00:00
Nick Mathewson
26632d59dd Rename or_is_obsolete and move it to or_connection_t where it belongs.
svn:r17642
2008-12-17 14:59:19 +00:00
Nick Mathewson
f3b52e331e Avoid multiple descriptor-fetch connections to authorities. Fixes bug 366.
svn:r17594
2008-12-11 19:12:55 +00:00
Nick Mathewson
4e69284e89 Fix wide line in main.c
svn:r17587
2008-12-11 17:23:00 +00:00
Nick Mathewson
53d3f812bd Add new internal-use-only option for controllers to use to prevent SIGHUP from reloading the configuration. Fixes bug 856.
svn:r17567
2008-12-10 22:17:02 +00:00
Nick Mathewson
9aa706e20c Bug 691 fix: do not shutdown Tor servers right away if the network is down.
svn:r17566
2008-12-10 20:45:31 +00:00
Roger Dingledine
f31c16d993 Directory mirrors no longer fetch the v1 directory or
running-routers files. They are obsolete, and nobody asks for them
anymore. This is the first step to making v1 authorities obsolete.


svn:r17513
2008-12-07 23:53:39 +00:00
Jacob Appelbaum
cf75162a0c Add comment clarifying OpenSSL usage.
svn:r17498
2008-12-07 01:14:49 +00:00
Roger Dingledine
984dc51f26 clean up some log messages
svn:r17406
2008-11-29 11:55:30 +00:00
Roger Dingledine
0b7a2a505e prepare_for_poll() -- plus its mysterious cousin, prepare_for_pool() --
are long gone.


svn:r17351
2008-11-21 14:07:57 +00:00
Nick Mathewson
6c50ab6e61 Document a couple of functions.
svn:r17239
2008-11-10 20:40:01 +00:00
Roger Dingledine
c62d5f6a5c beg nick for some documentation on the locking functions
svn:r17233
2008-11-10 00:48:13 +00:00
Nick Mathewson
e06f140f97 Whitespace fixes.
svn:r16967
2008-09-25 20:22:17 +00:00
Nick Mathewson
06f96363fd Remove now-needless _tor_dmalloc_free helper.
svn:r16964
2008-09-25 17:36:09 +00:00
Nick Mathewson
f95d7c189b Refactor unit test macros and tor_free_all() logic a bit so as to make it easier to free memory on failing tests, in order to suppress scanner warnings and to make dmalloc() usable with tests.
svn:r16816
2008-09-09 20:43:31 +00:00
Roger Dingledine
fa64d8041f minor cleanups on karsten's patch
svn:r16810
2008-09-09 09:21:21 +00:00
Roger Dingledine
ef7af1d61e karsten's patch for bug 767.
svn:r16808
2008-09-09 08:41:58 +00:00
Roger Dingledine
d37fae2f4e Catch and report a few more bootstrapping failure cases when Tor
fails to establish a TCP connection. Cleanup on 0.2.1.x.


svn:r16803
2008-09-09 06:25:39 +00:00
Nick Mathewson
c33dde4ac1 Fix mingw build with --enable-gcc-warnings set.
svn:r16759
2008-09-04 21:58:09 +00:00
Nick Mathewson
f80ac31d74 Add a lockfile to the Tor data directory to avoid situations where two Tors start with the same datadir, or where a --list-fingerprints races with a server to create keys, or such.
svn:r16722
2008-09-01 20:06:26 +00:00
Nick Mathewson
97245376d9 Next patch from Karsten: client-side configuration stuff for proposal 121.
svn:r16510
2008-08-12 16:12:26 +00:00
Nick Mathewson
960a0f0a99 r17641@31-33-44: nickm | 2008-08-05 16:07:53 -0400
Initial conversion of uint32_t addr to tor_addr_t addr in connection_t and related types.  Most of the Tor wire formats using these new types are in, but the code to generate and use it is not.  This is a big patch.  Let me know what it breaks for you.


svn:r16435
2008-08-05 20:08:19 +00:00
Roger Dingledine
1ad83d74b1 Send an initial "Starting" bootstrap status event, so we have a
state to start out in.


svn:r15326
2008-06-17 08:15:42 +00:00
Nick Mathewson
67a1658da5 Fix last geoip bugs.
svn:r15106
2008-06-10 20:11:59 +00:00
Roger Dingledine
eafb07ec96 extra points if you make it compile. boy, i'm on a roll.
svn:r15077
2008-06-09 05:17:52 +00:00
Roger Dingledine
1ca2ead8c4 when we haven't had any application requests lately, don't bother
logging when we have expired a bunch of descriptors.


svn:r15074
2008-06-09 05:13:33 +00:00
Nick Mathewson
3a469018e5 Fix warning when compiling with dmalloc.
svn:r14829
2008-05-29 14:37:56 +00:00
Nick Mathewson
ac330d9ba7 New code to implement proposal for local geoip stats. Only enabled with --enable-geoip-stats passed to configure.
svn:r14802
2008-05-29 02:29:35 +00:00
Nick Mathewson
05b184de01 r15304@tombo: nickm | 2008-04-23 16:31:40 -0400
Forward-port: I had apparently broken OSX and Freebsd by not initializing threading before we initialize the logging system.  This patch should do so, and fix bug 671.


svn:r14430
2008-04-23 20:32:31 +00:00
Nick Mathewson
b927ede48c r15161@31-33-107: nickm | 2008-04-10 11:11:58 -0400
Make dumpstats() log the size and fullness of openssl-internal buffers, so I can test my hypothesis that many of them are empty, and my alternative hypothesis that many of them are mostly empty, against the null hypothesis that we really need to be burning 32K per open OR connection on this.


svn:r14350
2008-04-10 15:12:24 +00:00
Nick Mathewson
31153d6374 r19243@catbus: nickm | 2008-04-08 13:28:59 -0400
Use a freelist to hold a few recent memarea chunks.  We do a kazillion memarea allocs and frees; that cant be good for us.


svn:r14319
2008-04-08 17:29:05 +00:00
Nick Mathewson
e89bf1c573 r19109@catbus: nickm | 2008-03-27 16:05:18 -0400
Replace a syntax error and a log message that was never emitted with a simple assert.  Asserts are fun and easy.


svn:r14224
2008-03-27 20:05:44 +00:00
Peter Palfrader
9d132fbde6 Add --hush switch.
New --hush command-line option similar to --quiet.  While --quiet disables all
logging to the console on startup, --hush limits the output to messages of
warning and error severity.


svn:r14222
2008-03-27 17:25:49 +00:00
Nick Mathewson
968ad93b0a r19093@catbus: nickm | 2008-03-27 12:43:58 -0400
Only log a notice that dmalloc has been set up if it fails.  Actually, since we have not added a temp log yet, I am not sure this ever does anything.


svn:r14216
2008-03-27 16:46:39 +00:00
Nick Mathewson
02acee891c r19089@catbus: nickm | 2008-03-27 11:05:23 -0400
Free some static hashtables and the log mutex on exit. Backport candidate.


svn:r14212
2008-03-27 15:05:28 +00:00
Nick Mathewson
745f3c859a r19066@catbus: nickm | 2008-03-26 13:24:15 -0400
Initialize logging before we log anything.  Bugfix on 0.2.0.x-alpha.


svn:r14199
2008-03-26 17:25:16 +00:00
Nick Mathewson
b5b77f8bf3 r19004@catbus: nickm | 2008-03-21 15:18:43 -0400
Use RAND_poll() again: the bug that made us stop using it has been fixed.


svn:r14150
2008-03-21 19:18:57 +00:00
Nick Mathewson
e0de72dd87 r14410@tombo: nickm | 2008-02-23 16:51:46 -0500
Fix the last of the -Wshorten-64-to-32 warnings.


svn:r13696
2008-02-24 22:10:08 +00:00
Nick Mathewson
e7db789e82 r14399@tombo: nickm | 2008-02-22 14:09:38 -0500
More 64-to-32 fixes. Partial backport candidate. still not done.


svn:r13680
2008-02-22 19:09:45 +00:00
Nick Mathewson
e18ee2a2ab r14357@31-33-219: nickm | 2008-02-21 10:39:11 -0500
Fix bug-handling code for unhandled write errors, so that it does not try to flush any data on the failed connection. Bugfix on 0.1.2.x.


svn:r13655
2008-02-21 15:39:26 +00:00
Roger Dingledine
1812a22a60 If we're trying to flush the last bytes on a connection (for
example, when answering a directory request), reset the  
time-to-give-up timeout every time we manage to write something
on the socket. Bugfix on 0.1.2.x.


svn:r13643
2008-02-21 05:51:09 +00:00
Roger Dingledine
8889229407 and another useful answer
svn:r13642
2008-02-21 05:42:12 +00:00
Nick Mathewson
063ced8903 r18296@catbus: nickm | 2008-02-20 23:30:11 -0500
Answer one xxx020 item; move 7 other ones to a new "XXX020rc" category: they should get fixed before we cut a release candidate. arma: please review these to see whether you have fixes/answers for any. Please check out the other 14 XXX020s to see if any look critical for the release candidate.


svn:r13640
2008-02-21 04:30:14 +00:00
Nick Mathewson
1df0647c66 r18291@catbus: nickm | 2008-02-20 22:35:32 -0500
Resolve all DOCDOC issues, and document some other undocumented code, and fix a changelog entry.


svn:r13638
2008-02-21 03:38:46 +00:00
Nick Mathewson
de827f89df r14062@tombo: nickm | 2008-02-08 15:17:07 -0500
Change DNs in x509 certificates to be harder to fingerprint.  Raise common code.  Refactor random hostname generation into crypto.c


svn:r13429
2008-02-08 21:13:12 +00:00