Nick Mathewson
3637ee0e59
r13383@catbus: nickm | 2007-06-13 13:53:04 -0400
...
Expose a function to parse a private key from a string as CRYPTO_PRIVATE. For testing.
svn:r10583
2007-06-13 18:15:53 +00:00
Roger Dingledine
af658b7828
More work towards making bridge users able to connect via bridges:
...
- demand options->Bridges and options->TunnelDirConns if
options->UseBridges is set.
- after directory fetches, accept descriptors that aren't referenced by
our networkstatuses, *if* they're for a configured bridge.
- delay directory fetching until we have at least one bridge descriptor.
- learn how to build a one-hop circuit when we have neither routerinfo
nor routerstatus for our destination.
- teach directory connections how to pick a bridge as the destination
directory when doing non-anonymous fetches.
- tolerate directory commands for which the dir_port is 0.
- remember descriptors when the requested_resource was "authority",
rather than just ignoring them.
- put bridges on our entry_guards list once we have a descriptor for them.
When UseBridges is set, only pick entry guards that are bridges. Else
vice versa.
svn:r10571
2007-06-12 09:17:23 +00:00
Roger Dingledine
622dd4927e
change the BandwidthRate/BandwidthBurst in the torrc
...
to RelayBandwidthRate/RelayBandwidthBurst, since that's
what most users will actually want. also flesh out the
torrc.complete entries and fix a few typos. based on
patch from "Armedblowfish".
svn:r10570
2007-06-12 08:19:02 +00:00
Peter Palfrader
c0b28adc65
Resetting the correct stats
...
svn:r10569
2007-06-12 01:09:53 +00:00
Nick Mathewson
a21381affa
r13364@catbus: nickm | 2007-06-11 20:15:53 -0400
...
Stop assuming that desc_by_eid_map works: in fact, it kinda doesn't. Add a big comment explaining why.
svn:r10567
2007-06-12 00:15:55 +00:00
Nick Mathewson
399890307d
r13362@catbus: nickm | 2007-06-11 19:00:23 -0400
...
Fix a warning on platforms where sizeof(size_t)==8, but sizeof(unsigned long)<8.
svn:r10566
2007-06-11 23:00:26 +00:00
Nick Mathewson
dddf065e62
r13358@catbus: nickm | 2007-06-11 18:46:24 -0400
...
Fix some dumb copypasta in r10562.
svn:r10565
2007-06-11 22:46:35 +00:00
Peter Palfrader
f621513cad
Remove an #undef, so you can -Ddefine stuff on the command line
...
svn:r10564
2007-06-11 22:32:30 +00:00
Nick Mathewson
367a77459a
r13355@catbus: nickm | 2007-06-11 18:19:34 -0400
...
Make all the digestmaps inside routerlist_t use the new typechecking wrappers, so we can catch any more bugs like the one fixed by 10561. This turned up a bug in routerlist_remove: we were extracting a routerinfo_t from desc_digest_map. Fix that too, though it was probably harmless, since we were only doing a pointer comparison with it.
svn:r10563
2007-06-11 22:19:40 +00:00
Nick Mathewson
f45732513e
r13354@catbus: nickm | 2007-06-11 18:17:40 -0400
...
Add typechecking wrappers to digestmap, so we can work with "map from digest to [FOO]" for arbitrary FOOs and still have some typesafety.
svn:r10562
2007-06-11 22:19:37 +00:00
Nick Mathewson
bde82e737b
r13352@catbus: nickm | 2007-06-11 17:42:45 -0400
...
Since desc_by_eid_map hold server descriptors, do not add routerinfo_ts. Bug found by weasel
svn:r10561
2007-06-11 21:42:48 +00:00
Peter Palfrader
e91cab20dd
Reorder routerlist_assert_ok() and routerlist_check_bug_417(), so if the assert_ok triggers we know that our bug_417 is wrong
...
svn:r10560
2007-06-11 19:46:23 +00:00
Nick Mathewson
932f2c79eb
r13338@catbus: nickm | 2007-06-10 15:13:32 -0400
...
Fix bug in 10533: put "opt v" line at the end of a routerstatus section; overwriting is bad.
svn:r10549
2007-06-10 19:13:40 +00:00
Roger Dingledine
04995f197d
more building blocks towards being able to fetch bridge descriptors
...
svn:r10548
2007-06-10 07:34:21 +00:00
Roger Dingledine
1ae7708ff8
discard the "bridge list" stubs that i hope i never need.
...
svn:r10547
2007-06-10 00:30:14 +00:00
Roger Dingledine
a97c3b8c2d
Be clearer on the various roles for auth dir types.
...
Bridge authorities no longer write bridge descriptors to their
cached-routers file -- this gets complex because of extrainfo documents.
svn:r10545
2007-06-09 07:05:19 +00:00
Roger Dingledine
8dfde75ef6
don't complain when approved-routers isn't there and we
...
don't need it.
svn:r10544
2007-06-09 05:28:11 +00:00
Roger Dingledine
eebeda2c71
scrub out some more references to the misnamed 'bridge' concept
...
svn:r10543
2007-06-09 05:17:33 +00:00
Roger Dingledine
15270358eb
bump to 0.2.0.2-alpha-dev
...
svn:r10542
2007-06-09 04:35:51 +00:00
Nick Mathewson
19389a3674
r13328@catbus: nickm | 2007-06-08 17:14:55 -0400
...
Arg. Irix apparently #defines sa_family to something. Thus, naming fields or variables "sa_family" will not work.
svn:r10541
2007-06-08 21:14:58 +00:00
Nick Mathewson
1d6db7ec3d
r13325@catbus: nickm | 2007-06-08 15:02:37 -0400
...
Parse networkstatuses (v2, vote, and consensus) after generating them, and fail fast if there is a parse error.
svn:r10540
2007-06-08 19:02:39 +00:00
Nick Mathewson
2bb7005481
r13317@catbus: nickm | 2007-06-08 14:39:59 -0400
...
bugfix: we were undercounting the number of authorities that recommended any given version by 1. Backport candidate.
svn:r10537
2007-06-08 18:41:19 +00:00
Nick Mathewson
678110570a
r13315@catbus: nickm | 2007-06-08 14:33:24 -0400
...
Make versions get added to networkstatuses correctly again.
svn:r10535
2007-06-08 18:41:14 +00:00
Nick Mathewson
171969656c
r13314@catbus: nickm | 2007-06-08 14:30:31 -0400
...
Enfore that known_flags in networkstatus votes must be unique.
svn:r10534
2007-06-08 18:41:12 +00:00
Nick Mathewson
7a6f3cd223
r13313@catbus: nickm | 2007-06-08 14:23:11 -0400
...
Refactor v3 vote generation code into "build a networkstatus_vote_t" and "format a networkstatus_vote_t". This should make testing possible.
svn:r10533
2007-06-08 18:41:09 +00:00
Nick Mathewson
1b200de0ef
r13304@catbus: nickm | 2007-06-07 13:25:37 -0400
...
Deprecate RedirectExits.
svn:r10526
2007-06-07 17:26:19 +00:00
Nick Mathewson
529cbe34b0
r13292@catbus: nickm | 2007-06-06 17:34:15 -0400
...
Check for non-standard SVK directories properly. Inspired by debian bug #420899 and related discussion on SVK list.
svn:r10522
2007-06-07 16:14:55 +00:00
Roger Dingledine
8db1b61a26
avoid leaking memory in a path never followed. pointed out
...
by robert watson.
svn:r10521
2007-06-07 15:07:33 +00:00
Nick Mathewson
6673d445f5
r13283@catbus: nickm | 2007-06-06 01:43:44 -0400
...
Fix up a couple of loops flagged by -Wunsafe-loop-optimizations so that they are more readable (and more amenable to compilation)
svn:r10513
2007-06-06 13:02:22 +00:00
Nick Mathewson
1a29d68081
r13276@catbus: nickm | 2007-06-05 19:45:33 -0400
...
Remove another long-dead #if 0 I missed before
svn:r10511
2007-06-06 04:51:33 +00:00
Nick Mathewson
d3b140b0de
r13275@catbus: nickm | 2007-06-05 19:11:05 -0400
...
Apply my sekrit "unused macro detector" script to hunt down some macros we didnt use.
svn:r10510
2007-06-06 04:51:30 +00:00
Nick Mathewson
1866ad3506
r13274@catbus: nickm | 2007-06-05 19:06:30 -0400
...
Remove some deadcode that seems unlikely to return
svn:r10509
2007-06-06 04:51:25 +00:00
Nick Mathewson
0a27f02b9c
r13267@catbus: nickm | 2007-06-05 16:54:20 -0400
...
Man page and small tweaks for last patch.
svn:r10505
2007-06-05 20:54:53 +00:00
Nick Mathewson
210beff55a
r13266@catbus: nickm | 2007-06-05 16:38:08 -0400
...
Patch from peter palfrader: control interface via unix domain socket
svn:r10504
2007-06-05 20:54:49 +00:00
Nick Mathewson
f0345d46f6
r13256@catbus: nickm | 2007-06-05 10:57:41 -0400
...
Mark fields that need to be ipv6-ified.
svn:r10503
2007-06-05 20:54:23 +00:00
Peter Palfrader
b6c6dd7e55
Change an assert into a tor_assert
...
svn:r10495
2007-06-05 01:09:09 +00:00
Nick Mathewson
23ae5976f3
r13254@catbus: nickm | 2007-06-04 20:13:47 -0400
...
When choosing a guard, weight by bandwidth. Resolves bug 440.
svn:r10493
2007-06-05 00:15:00 +00:00
Nick Mathewson
2e0713222b
r13252@catbus: nickm | 2007-06-04 18:57:21 -0400
...
Code to check signatures on consensus directories.
svn:r10492
2007-06-04 22:57:23 +00:00
Nick Mathewson
8b0e6a4466
r13250@catbus: nickm | 2007-06-04 18:28:55 -0400
...
Adapt code to parse v3 networkstatus votes so it can also parse a consensus. Make networkstatus_vote_t the catch-all type for votes and conensuses. Correct/clarify the second argument to directory-signature.
svn:r10491
2007-06-04 22:29:00 +00:00
Nick Mathewson
8d1224eb51
r13248@catbus: nickm | 2007-06-04 15:53:23 -0400
...
More code to generate a consensus from a list of votes. Now, we handle Named, and we actually generate and sign the signed consensus. Yippee. Still needs testing. Still not actually called.
svn:r10490
2007-06-04 19:54:02 +00:00
Nick Mathewson
bb6f53d60c
r13243@catbus: nickm | 2007-06-04 15:17:15 -0400
...
Start of code to compute consensus network-status stuff from a bunch of votes. Strangely, it does not yet feel like an enormous ugly hack.
svn:r10489
2007-06-04 19:19:01 +00:00
Peter Palfrader
32d12dcfbc
Fix retry_all_listeners() and retry_listeners() description to match code. We are smarter than comparing lengths of want- and have-listeners.
...
svn:r10487
2007-06-04 16:58:57 +00:00
Peter Palfrader
502879e0b4
Remove force flag from retry_all_listeners() and retry_listeners(). It always was 0.
...
svn:r10486
2007-06-04 16:54:42 +00:00
Nick Mathewson
6faa9e2641
r13239@catbus: nickm | 2007-06-04 11:30:37 -0400
...
Fix the fix for bug 445: set umask properly. Also use open+fdopen rather than just umask+fopen, and create authority identity key with mode 400.
svn:r10485
2007-06-04 15:30:40 +00:00
Roger Dingledine
80e675deb1
Stop tearing down the whole circuit when the user asks for a
...
connection to a port that the hidden service didn't configure.
Resolves bug 444.
svn:r10478
2007-06-04 03:13:13 +00:00
Nick Mathewson
cb0324c400
r13191@catbus: nickm | 2007-06-03 19:38:18 -0400
...
Set umask(0700) when starting tor-gencert; resolves bug 445.
svn:r10475
2007-06-03 23:38:20 +00:00
Nick Mathewson
6d447e04a2
r13189@catbus: nickm | 2007-06-03 19:08:01 -0400
...
Oops. Only bind ports and start libevent if we are actually running Tor.
svn:r10474
2007-06-03 23:08:07 +00:00
Nick Mathewson
d3ee41619c
r13186@catbus: nickm | 2007-06-03 19:00:20 -0400
...
Bind ports before setuid/setgid.
svn:r10473
2007-06-03 23:00:26 +00:00
Nick Mathewson
147e439c94
r13174@catbus: nickm | 2007-06-03 17:39:20 -0400
...
Patch from robert hogan: avoid crash when DNS port is set more than once.
svn:r10471
2007-06-03 21:39:24 +00:00
Nick Mathewson
f4ce7f9c9b
r13166@catbus: nickm | 2007-06-02 23:02:40 -0400
...
First cut at code to parse and validate v3 networkstatus votes.
svn:r10461
2007-06-03 03:05:10 +00:00
Nick Mathewson
e0d828299a
r13165@catbus: nickm | 2007-06-02 22:55:22 -0400
...
Remove an obsoleted function
svn:r10460
2007-06-03 03:05:07 +00:00
Roger Dingledine
0b73569dc6
bump to 0.2.0.2-alpha and declare that today is the day
...
svn:r10456
2007-06-02 23:56:04 +00:00
Nick Mathewson
d216133c8e
r13163@catbus: nickm | 2007-06-02 16:41:07 -0400
...
We do "-alpha-dev" now, not "-alpha-cvs".
svn:r10455
2007-06-02 20:41:10 +00:00
Roger Dingledine
f6880cbc6b
bump to 0.2.0.1-alpha-cvs while we're in transition
...
svn:r10454
2007-06-02 20:22:42 +00:00
Roger Dingledine
1407cf9de3
fix up a comment
...
svn:r10453
2007-06-02 20:22:31 +00:00
Nick Mathewson
c2dc8f4623
r13158@catbus: nickm | 2007-06-02 11:40:05 -0400
...
On systems with svk, do not clobber micro-revision.i when building from a tarball.
svn:r10452
2007-06-02 15:40:10 +00:00
Nick Mathewson
aee7f01624
r13154@catbus: nickm | 2007-06-02 11:26:44 -0400
...
Server-side support for If-Modified-Since in HTTP requsts for v1 stuff, and for network-status documents.
svn:r10451
2007-06-02 15:26:57 +00:00
Nick Mathewson
8400cecb1d
r13148@catbus: nickm | 2007-06-02 10:24:20 -0400
...
Fix bug 441, 442, and possibly 417 (again).
svn:r10449
2007-06-02 14:24:23 +00:00
Nick Mathewson
2ef3e7853b
r13144@catbus: nickm | 2007-06-02 08:44:42 -0400
...
Add some asserts to catch double-insert on routerlist.
svn:r10445
2007-06-02 12:44:57 +00:00
Nick Mathewson
5b6d7f10f3
r13143@catbus: nickm | 2007-06-01 16:43:40 -0400
...
Try to fix some mipspro compiler warnings. There will still be some left.
svn:r10444
2007-06-02 12:44:54 +00:00
Nick Mathewson
7c3f418e39
r13139@catbus: nickm | 2007-06-01 14:02:40 -0400
...
Add some ;trues, and tabify.
svn:r10441
2007-06-01 18:02:41 +00:00
Nick Mathewson
6df38f52db
r13137@catbus: nickm | 2007-06-01 13:49:34 -0400
...
Ah. Of course. You spell "is there an svn" as 'test -x "`which svn 2>&1`"'. Perfectly reasonable. Don't know why I didn't think of it in the first place.
svn:r10440
2007-06-01 17:49:37 +00:00
Nick Mathewson
0af91800f9
r13131@catbus: nickm | 2007-06-01 06:20:29 -0400
...
Test for ~/.svk/local, not ~/.svk. Eschew use of test -a and test -o. Bulletproof more against odd shells.
svn:r10439
2007-06-01 10:20:37 +00:00
Roger Dingledine
e64750e9a3
bump to 0.2.0.1-alpha
...
svn:r10437
2007-06-01 07:33:39 +00:00
Nick Mathewson
6bb65fa371
r13121@catbus: nickm | 2007-05-31 20:06:40 -0400
...
Oops. Different inet_ntop implementations seem to differ on whether, in an IPv6 address with a single "0" word, that word should be written as 0, or omitted. Fix the unit tests to account for that.
svn:r10432
2007-06-01 00:06:45 +00:00
Roger Dingledine
b1ee20f0e8
trivial changes from my sandbox
...
svn:r10429
2007-05-31 23:57:46 +00:00
Nick Mathewson
3b4fa59b60
r13117@catbus: nickm | 2007-05-31 19:40:32 -0400
...
Patch from Tup: treat RESOLVED_TYPE_ERROR_TRANSIENT as a SERVERFAILED, and RESOLVED_TYPE_ERROR as NOTEXIST. Generate transient/nontransient errors more sensibly. Set flags better on DNS replies.
svn:r10427
2007-05-31 23:40:35 +00:00
Nick Mathewson
534c55f531
r13111@catbus: nickm | 2007-05-31 15:03:41 -0400
...
Cleanup whitespace.
svn:r10425
2007-05-31 19:03:49 +00:00
Nick Mathewson
71c0a13703
r13110@catbus: nickm | 2007-05-31 15:03:24 -0400
...
Fix windows build.
svn:r10424
2007-05-31 19:03:46 +00:00
Nick Mathewson
884cb0c7a1
r13109@catbus: nickm | 2007-05-31 14:59:30 -0400
...
More code for voting and vote parsing (checkpointing)
svn:r10423
2007-05-31 19:03:44 +00:00
Nick Mathewson
5d4b426a33
r13103@catbus: nickm | 2007-05-31 14:40:18 -0400
...
Fix patch r10411; fix from robert hogan.
svn:r10422
2007-05-31 18:48:31 +00:00
Nick Mathewson
77502ac82d
r13102@catbus: nickm | 2007-05-31 13:56:25 -0400
...
Make "authdir_newdesc rejected" work again.
svn:r10421
2007-05-31 18:48:28 +00:00
Nick Mathewson
4061b2cbd1
r13101@catbus: nickm | 2007-05-31 12:57:42 -0400
...
Unit tests [and debugging] for tor_inet_ntop() and tor_inet_pton()
svn:r10420
2007-05-31 18:48:25 +00:00
Nick Mathewson
1cb1ebbfe0
r13090@catbus: nickm | 2007-05-30 03:17:57 -0400
...
If the user makes a torrc that exceeds the bandwidth cap by one byte, let them have it.
svn:r10411
2007-05-30 07:18:00 +00:00
Nick Mathewson
8b1e9398a8
r13079@catbus: nickm | 2007-05-29 17:05:38 -0400
...
Oops. Authorities should recommend nodes as exits.
svn:r10403
2007-05-29 21:05:49 +00:00
Nick Mathewson
4cd93bd9ec
r13071@catbus: nickm | 2007-05-29 15:54:46 -0400
...
Aaargh. Revert accidentally-committed debugging code in last patch.
svn:r10400
2007-05-29 19:54:54 +00:00
Nick Mathewson
1359871c14
r13070@catbus: nickm | 2007-05-29 15:53:21 -0400
...
Fix handling of resolves with very long or otherwise malformed addresses, and comment dns_resolve better, and stop making what should be a BUG warning into an assert(0). This fixes bug 427, which was introduced around 9900/9931/9932. Not a backport candidate: 0.1.2.x never had this bug.
svn:r10399
2007-05-29 19:54:51 +00:00
Nick Mathewson
3f9afa0625
r13068@catbus: nickm | 2007-05-29 14:58:13 -0400
...
Add some code to mitigate bug 393: Choose at random from multiple hidden service ports with the same virtport. This allows limited ad-hoc round-robining.
svn:r10398
2007-05-29 18:58:16 +00:00
Nick Mathewson
e11a92bd54
r13058@catbus: nickm | 2007-05-29 14:39:53 -0400
...
Note that the fix for bug 222 should technically be turned into a real fix, not a kludge, one of these days.
svn:r10397
2007-05-29 18:39:59 +00:00
Nick Mathewson
c5b3a8db84
r13057@catbus: nickm | 2007-05-29 14:39:27 -0400
...
fix for bug 439: make _sure_ *msg is set when we leave dirserv_add_multiple_descriptors().
svn:r10396
2007-05-29 18:39:56 +00:00
Nick Mathewson
e5ed434c42
r13054@catbus: nickm | 2007-05-29 14:20:50 -0400
...
An even better workaround for the probably-already-fixed bug 222.
svn:r10395
2007-05-29 18:21:00 +00:00
Nick Mathewson
9d1af71b70
r13053@catbus: nickm | 2007-05-29 13:35:33 -0400
...
Move connection_should_read_from_linked_conn into main.c, which is the only file that uses it.
svn:r10394
2007-05-29 18:20:56 +00:00
Nick Mathewson
f89a3b1448
r13050@catbus: nickm | 2007-05-29 13:31:11 -0400
...
Resolve all but 3 DOCDOCs.
svn:r10393
2007-05-29 17:31:13 +00:00
Nick Mathewson
69c712f189
r13048@catbus: nickm | 2007-05-29 11:08:53 -0400
...
Oops; better version of previous patch that does not get caught in an infinite loop.
svn:r10391
2007-05-29 15:08:55 +00:00
Nick Mathewson
fd3aa5c85d
r13046@catbus: nickm | 2007-05-29 11:07:12 -0400
...
Stop adding bogus entries to lists in router_parse_list_from_string(). I wonder which bugs _that_ caused.
svn:r10390
2007-05-29 15:07:16 +00:00
Nick Mathewson
916e98d3fa
r13042@catbus: nickm | 2007-05-29 10:41:10 -0400
...
oops; use tor_inet_aton rather than inet_aton in tor_inet_ntop. Spotted by Li-Hui Zhou.
svn:r10389
2007-05-29 14:41:24 +00:00
Nick Mathewson
63035cdb33
r13041@catbus: nickm | 2007-05-29 10:40:05 -0400
...
More messing around to try to address possible root causes of bug 436.
svn:r10388
2007-05-29 14:41:20 +00:00
Nick Mathewson
d509efb9b7
r13019@catbus: nickm | 2007-05-27 12:32:55 -0400
...
Merge an evdns fix from libevent r357: "evdns_shutdown fix from adam langley.
svn:r10387
2007-05-29 14:41:16 +00:00
Peter Palfrader
3425f2c11f
Segfault less. Somebody needs to look over why exactly this helps. re #436
...
svn:r10376
2007-05-28 21:34:42 +00:00
Roger Dingledine
64b0d7202e
also remove these obsolete torrcs
...
svn:r10362
2007-05-27 06:07:51 +00:00
Roger Dingledine
1ab216eb2f
what the heck is this obsolete dirservers file still doing here?
...
svn:r10361
2007-05-27 06:06:01 +00:00
Roger Dingledine
c1101fceeb
we were leaking a few megabytes a minute checking signatures
...
svn:r10359
2007-05-27 04:38:50 +00:00
Roger Dingledine
e13bf01a9f
fix a seg fault when my auth dirserver accepted a posted descriptor
...
(dirserv_add_multiple_descriptors doesn't set msg if there's no
failure.)
svn:r10358
2007-05-27 03:41:09 +00:00
Roger Dingledine
c8fd65a936
If Tor is invoked from something that isn't a shell (e.g. Vidalia),
...
now we expand "-f ~/.tor/torrc" correctly. Suggested by Matt Edman.
svn:r10351
2007-05-26 08:04:15 +00:00
Nick Mathewson
b0be93c8b0
r12988@catbus: nickm | 2007-05-25 20:15:56 -0400
...
socklen_t is a silly type anyway. Just use int as the argument for evdns_server_request_get_requesting_addr.
svn:r10347
2007-05-26 00:15:58 +00:00
Roger Dingledine
0f71ade42f
fix compile on bsd
...
svn:r10339
2007-05-25 21:56:47 +00:00
Roger Dingledine
0c047b87f5
polish r9933-r9994
...
svn:r10335
2007-05-25 19:41:31 +00:00
Roger Dingledine
a19d131ed7
i suspect we would trigger asserts if we answer a cached
...
resolve request. this should help that.
svn:r10334
2007-05-25 19:30:07 +00:00
Roger Dingledine
32f5e19168
remove an obsolete notion that we judge runningness based on
...
whether we have a connection open to the server right now.
svn:r10333
2007-05-25 19:22:26 +00:00
Nick Mathewson
368eb6a97a
r12964@catbus: nickm | 2007-05-25 14:49:23 -0400
...
hack to make reverse lookups work with dnsport. note that it is a hack. note some trouble spots.
svn:r10332
2007-05-25 18:49:26 +00:00