Commit Graph

259 Commits

Author SHA1 Message Date
Nick Mathewson
4ff4577beb r6908@Kushana: nickm | 2006-07-26 12:38:52 -0400
Refactor connection_t into edge, or, dir, control, and base subtypes.  This might save some RAM on busy exit servers, but really matters most in terms of correctness.


svn:r6906
2006-07-26 19:07:26 +00:00
Nick Mathewson
7239262f71 Don't tell anybody, but we're going OO here. This patch splits
circuit_t into origin_circuit_t and or_circuit_t.  I fixed some
segaults; there may be more.  We still need to move more rendezvous
stuff into subtypes.

This is a trial run for splitting up connection_t; if the approach is
insane, please say so soon so we can do something smarter.

Also, this discards the old HALF_OPEN code, which nobody seems to
want.


svn:r6817
2006-07-23 07:37:35 +00:00
Roger Dingledine
9283ddb760 an entry guard that is "unlisted", as well as not known to be "down", is
not therefore "up".


svn:r6798
2006-07-21 07:06:18 +00:00
Roger Dingledine
237c7ecbfd tweak
svn:r6796
2006-07-20 23:45:26 +00:00
Roger Dingledine
42e2057d67 fix some more places where we shouldn't crash if we can't build
our own descriptor yet.


svn:r6775
2006-07-17 06:54:28 +00:00
Roger Dingledine
0ec293b189 actually, that excludenodes fix was redundant. take it out.
svn:r6727
2006-07-05 18:19:42 +00:00
Roger Dingledine
98c6bf6192 oops, we were ignoring options->ExcludeNodes when picking entry guards.
it is still the case that we ignore it with respect to entry guards
that we've already picked.


svn:r6726
2006-07-04 20:25:17 +00:00
Roger Dingledine
dc79dd6a46 minor fixes
svn:r6709
2006-07-04 03:19:59 +00:00
Roger Dingledine
d45757ebcb also remove word 'middleman' from a log notice
svn:r6704
2006-06-29 13:11:23 +00:00
Roger Dingledine
37c441d96f correct a function comment in compute_preferred_testing_list()
svn:r6660
2006-06-18 21:07:45 +00:00
Roger Dingledine
4e4cc9aa27 lower the number of seconds before we yell about clock jump.
and make the yelling only happen if you're a server.


svn:r6625
2006-06-15 09:03:15 +00:00
Roger Dingledine
de7a9c83d8 upgrade the severity of the 'clock jump' warn, and ask people
to report if it occurs.


svn:r6623
2006-06-14 22:28:16 +00:00
Roger Dingledine
09dfe1b265 bugfix: discourage picking directory authorities as our TestVia
hops, even if they're running the right versions, since we probably
already have a connection established to them.


svn:r6622
2006-06-14 11:06:43 +00:00
Roger Dingledine
977574e48d back off and add the $ at the beginning of the preferrednodes list
we generate.


svn:r6620
2006-06-13 12:57:19 +00:00
Roger Dingledine
23e2c6a7dd first cut at a workaround for the reachability bug: explicitly find a
server running the right version, if we can, and ask for that one.


svn:r6616
2006-06-13 10:25:22 +00:00
Roger Dingledine
279e86f3c8 Defense in depth: fix the reachability bug a second way too.
Now if we establish a connection with the right digest, regardless
of what the addr/port is, and we have pending create cells, use it.


svn:r6614
2006-06-13 05:51:28 +00:00
Roger Dingledine
889b8d5bac Add a new config option TestVia, that lets you specify preferred middle
hops to use for testing circuits. Perhaps this will let me debug the
reachability problem better.


svn:r6581
2006-06-10 00:26:39 +00:00
Roger Dingledine
6531a31aad actually, don't fix it that far. we should still do some
error checking.


svn:r6576
2006-06-09 09:07:59 +00:00
Roger Dingledine
0071d67efd when only one router is labelled as a guard, and we've
already picked him, we would cycle endlessly picking him
again, being unhappy about it, and so forth.

now we specifically exclude guards when picking a new guard.


svn:r6575
2006-06-09 09:02:32 +00:00
Roger Dingledine
1e9b35aee3 make connection_or_nonopen_was_started_here() based on something less
voodooey. it turns out we already do keep a flag like that around.


svn:r6560
2006-06-07 07:11:42 +00:00
Roger Dingledine
96914760bc fix the bug where we sometimes would fail to send some create cells
once we'd connected to a(nother) tor server.


svn:r6552
2006-06-06 03:33:24 +00:00
Roger Dingledine
a2fec314b6 scream louder if you've got a pending circuit for a given
addr/port but the intended n_conn digest is wrong.


svn:r6544
2006-06-05 09:47:19 +00:00
Roger Dingledine
4e773352c2 bugfix: if we are making our first ever connection to any entry
guard, then don't mark it down at first. we had this implemented
but it was disabled due to a bug.


svn:r6541
2006-06-05 08:58:18 +00:00
Roger Dingledine
bf09898f79 Note a bug that causes servers to sometimes never send the pending
create cell. Nick, is this a bug? If so, is my fix right?


svn:r6538
2006-06-05 07:27:48 +00:00
Nick Mathewson
853e2d99b6 Add a new warning to our "warn a lot" list: unused parameters. This means we have to explicitly "use" unuseds, but it can catch bugs. (It caught two coding mistakes so far.)
svn:r6532
2006-06-04 22:42:13 +00:00
Roger Dingledine
1f0e20806b END_CIRC_REASON_OR_IDENTITY apparently means that we were told to
connect to a different OR than lives on the addr:port we connected
to. we don't actually remember whether that was the case, currently.
so call it END_CIRC_REASON_OR_CONN_CLOSED as a compromise.


svn:r6515
2006-05-30 06:17:28 +00:00
Roger Dingledine
1e4923652b simplify a log message
svn:r6512
2006-05-30 05:29:03 +00:00
Roger Dingledine
701341ef8a put one of the XXX's back in
svn:r6422
2006-04-25 07:06:48 +00:00
Nick Mathewson
6ebd886511 forward-port: "Resolve" all XXX011 items, mostly by marking them non-011.
svn:r6396
2006-04-18 03:07:24 +00:00
Nick Mathewson
785d25e06c If I could forget that I had enabled StrictExitNodes, others will too.
svn:r6295
2006-04-02 22:59:59 +00:00
Roger Dingledine
6f08d121d9 Refactor and consolidate addr/exit policies into a new policies.c.
Fix some minor bugs and memory leaks along the way.


svn:r6246
2006-03-27 02:25:34 +00:00
Roger Dingledine
b899b9592a When the controller's *setconf commands fail, collect an error message
in a string and hand it back. This starts to resolve bug 275.


svn:r6241
2006-03-26 06:51:26 +00:00
Roger Dingledine
c06e6ddadd Finish the transition from the word 'verified' to the words
'named' and 'valid'.


svn:r6188
2006-03-19 01:21:59 +00:00
Roger Dingledine
581795f41d auth dir servers were only modifying a server's is_running field
when they created a network status. so if nobody asked for a
network status, they would never discover that any servers are
is_running, so they could never build a circuit.


svn:r6183
2006-03-18 01:24:04 +00:00
Roger Dingledine
cf6ba3e76f let an authdir that's not a naming authdir start even
if it doesn't have an approved-routers file. if it does,
read it and parse it as usual.


svn:r6182
2006-03-18 00:22:23 +00:00
Roger Dingledine
7d141c6776 but i made the line too long
svn:r6176
2006-03-17 19:25:36 +00:00
Roger Dingledine
f1bcc2d6f8 stop tricking server operators into thinking they got their
torrc perfect, just because tor could build a circuit.


svn:r6175
2006-03-17 19:20:07 +00:00
Roger Dingledine
8d1f65a222 quiet another entry guard log message
svn:r6169
2006-03-15 22:48:48 +00:00
Peter Palfrader
a4ec555228 change INET_NTOA_BUF_LEN+1 to INET_NTOA_BUF_LEN
add a comment in a few places where we add weird numbers to buffer lengths


svn:r6161
2006-03-14 23:40:37 +00:00
Roger Dingledine
86a72f73b9 make entry guard logs even quieter
svn:r6116
2006-03-10 16:51:26 +00:00
Roger Dingledine
82d1fdbaea don't abandon entry guards until they've been dead a whole month.
make entry guard log messages quieter.


svn:r6106
2006-03-09 00:55:55 +00:00
Roger Dingledine
2bfd2a2400 clean up a log message
svn:r6074
2006-02-21 17:54:56 +00:00
Peter Palfrader
5eea6c76df Split ReachableAddresses into ReachableDirAddresses and ReachableORAddresses
svn:r6009
2006-02-13 21:17:20 +00:00
Roger Dingledine
36484f873a convert some more source files to the new log convention
svn:r6002
2006-02-13 08:28:42 +00:00
Roger Dingledine
3c4e68488b Clients now honor the "guard" flag in the router status when
picking entry guards, rather than looking at is_fast or is_stable.

Now dirservers can change how they define it and clients will
automatically use their new definition.


svn:r5979
2006-02-12 03:43:39 +00:00
Roger Dingledine
5f051574d5 Happy new year!
svn:r5949
2006-02-09 05:46:49 +00:00
Roger Dingledine
1c596156aa tweak comment
svn:r5930
2006-02-09 00:08:23 +00:00
Roger Dingledine
bdba6e42dc avoid a minor confusing log message
svn:r5887
2006-02-01 03:05:52 +00:00
Roger Dingledine
8fc44169e5 only start testing reachability once we've established a circuit.
this will make startup on dirservers less noisy.
it may also break things in subtle ways.


svn:r5878
2006-01-29 01:11:41 +00:00
Roger Dingledine
cca9a2f7b0 oh, and the other bits of the commit
svn:r5836
2006-01-17 04:03:23 +00:00