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
Roger Dingledine
ce59d5a632
also change purpose_is_private to purpose_needs_anonymity
...
svn:r10331
2007-05-25 18:40:09 +00:00
Roger Dingledine
6e216ed7ef
karsten got confused by private_connection, so try calling
...
it anonymized_connection instead.
svn:r10330
2007-05-25 18:25:33 +00:00
Nick Mathewson
ba4969a59e
r12959@catbus: nickm | 2007-05-25 14:22:33 -0400
...
The second time that we resolve a.com and get 1.2.3.4, return an A record mapping (a->1.2.3.4), not mapping (1.2.3.4->1.2.3.4).
svn:r10329
2007-05-25 18:22:43 +00:00
Nick Mathewson
527fbc304e
r12958@catbus: nickm | 2007-05-25 14:19:29 -0400
...
Fix more dnsport bugs: set state correctly, and actually cache the answers.
svn:r10328
2007-05-25 18:22:42 +00:00
Nick Mathewson
5f226f130c
r12957@catbus: nickm | 2007-05-25 14:11:02 -0400
...
Fix a dnsserv bug: mark the connectino as "finished handshaking" once dnsserv_resolved is called.
svn:r10327
2007-05-25 18:22:39 +00:00
Nick Mathewson
39fe91b9a2
r12946@catbus: nickm | 2007-05-25 10:46:50 -0400
...
Add an AutomapHostsOnResolve option. It seems to work.
svn:r10324
2007-05-25 14:48:16 +00:00
Roger Dingledine
7127c30f46
irix64's cc doesn't think hibernate_state_t is necessarily an int.
...
good point.
svn:r10320
2007-05-24 23:51:08 +00:00
Roger Dingledine
42d7b0877d
forward-port r10318
...
svn:r10319
2007-05-24 23:39:04 +00:00
Nick Mathewson
703bf19620
r12942@catbus: nickm | 2007-05-24 16:31:22 -0400
...
Well, that was easier than I thought it would be. Tor is now a DNS proxy as well as a socks proxy. Probably some bugs remain, but since it A) has managed to resolve one address for me successfully, and B) will not affect anybody who leaves DNSPort unset, it feel like a good time to commit.
svn:r10317
2007-05-24 20:31:30 +00:00
Nick Mathewson
17830bc03b
r12941@catbus: nickm | 2007-05-24 16:25:00 -0400
...
Fix some eventdns dns server bugs, and add a new eventdns function to get the address of whoever requested this lookup.
svn:r10316
2007-05-24 20:31:27 +00:00
Nick Mathewson
a312afd67e
r12936@catbus: nickm | 2007-05-24 14:12:34 -0400
...
Review XXXX comments without a version; upgrade some to XXXX020.
svn:r10315
2007-05-24 18:12:52 +00:00
Nick Mathewson
56aefe8d23
r12935@catbus: nickm | 2007-05-24 14:12:04 -0400
...
dir-signing-key should never take arguments.
svn:r10314
2007-05-24 18:12:44 +00:00
Nick Mathewson
9aaf3d182f
r12934@catbus: nickm | 2007-05-24 14:11:18 -0400
...
When freeing slack buffers, free the buffers at the end of the freelist first.
svn:r10313
2007-05-24 18:12:41 +00:00
Nick Mathewson
687461d36c
r12920@catbus: nickm | 2007-05-24 13:12:52 -0400
...
and remove an XXX012.
svn:r10308
2007-05-24 17:13:08 +00:00
Nick Mathewson
212a3c3478
r12919@catbus: nickm | 2007-05-24 13:04:56 -0400
...
backport candidate: Warn when using a version of libevent before 1.3b to run a server on osx or bsd: these versions of libevent interact badly with userspace threads.
svn:r10307
2007-05-24 17:13:05 +00:00
Nick Mathewson
4c6398a8f0
r12918@catbus: nickm | 2007-05-24 12:52:40 -0400
...
Make reset_download_failures() reset extrainfo download status too.
svn:r10306
2007-05-24 17:13:02 +00:00
Nick Mathewson
3980ebd6a1
r12917@catbus: nickm | 2007-05-24 12:48:47 -0400
...
Put the hash-as-signed, not the raw hash, in the signed_descriptor_digest field of our own descriptor. Backport candidate; probably harmless though.
svn:r10305
2007-05-24 17:13:00 +00:00
Nick Mathewson
d3d86b17a7
r12916@catbus: nickm | 2007-05-24 12:43:45 -0400
...
Add math functions to round values to the nearest power of 2. Make mempools more careful about making sure that the size of their chunks is a little less than a power of 2, not a little more.
svn:r10304
2007-05-24 17:12:57 +00:00
Nick Mathewson
d0a5c4f984
r12915@catbus: nickm | 2007-05-24 12:12:34 -0400
...
Do not send a warning when somebody uploads an extrainfo that we will reject, if it happens to be newer than our current routerdesc.
svn:r10303
2007-05-24 17:12:54 +00:00
Nick Mathewson
ca9e13f2a0
r12906@catbus: nickm | 2007-05-22 20:43:13 -0400
...
s/32/64/; s/breaks/works/;
svn:r10297
2007-05-23 00:43:20 +00:00
Roger Dingledine
e583827d60
new ip addresses for moria1 and moria2; new ports for moria2
...
svn:r10296
2007-05-22 23:51:39 +00:00
Nick Mathewson
38300735cd
r12902@catbus: nickm | 2007-05-22 14:52:29 -0400
...
First draft of code to generate votes. needs testing. does not yet upload or serve votes. Shares most of its code with the old generate_v2_networkstatus.
svn:r10295
2007-05-22 18:52:32 +00:00
Nick Mathewson
9e0acc0c11
r12899@catbus: nickm | 2007-05-22 13:51:26 -0400
...
Extract common code from networkstatus_getinfo_helper_single() and generate_v2_networkstatus().
svn:r10294
2007-05-22 17:58:30 +00:00
Nick Mathewson
c9fa4e6583
r12898@catbus: nickm | 2007-05-22 13:11:04 -0400
...
More v3 directory code: have authorities load certificates; have everybody store certificates to disk and load them; provide a way to configure v3 authorities.
svn:r10293
2007-05-22 17:58:25 +00:00
Nick Mathewson
6975a093e9
r12853@catbus: nickm | 2007-05-22 11:36:54 -0400
...
Make connection_array into a smartlist.
svn:r10292
2007-05-22 15:49:14 +00:00
Nick Mathewson
e935d73b34
r12852@catbus: nickm | 2007-05-22 11:00:27 -0400
...
Use svn revisions consistently throughout all log messages.
svn:r10291
2007-05-22 15:48:46 +00:00
Nick Mathewson
4ec5e139c8
r12850@catbus: nickm | 2007-05-21 22:20:42 -0400
...
Partial backport candidate: do not rely on finding a \0 after an mmaped() router/extrainfo file. Also, set journal length correctly when starting up.
svn:r10248
2007-05-22 02:20:52 +00:00
Nick Mathewson
d23cb33a1a
r12846@catbus: nickm | 2007-05-21 21:55:15 -0400
...
Oops; it is possible to have an empty store.
svn:r10247
2007-05-22 01:55:50 +00:00
Nick Mathewson
0cb342e859
r12844@catbus: nickm | 2007-05-21 21:52:19 -0400
...
Oops. It compiles better when you spell the fields right.
svn:r10245
2007-05-22 01:52:22 +00:00
Nick Mathewson
32c8d94c12
r12842@catbus: nickm | 2007-05-21 21:51:45 -0400
...
Partial backport candidate. Fix issue noted in r10241: stores were rebuilt too often. Also notes dropped bytes better.
svn:r10244
2007-05-22 01:51:53 +00:00
Roger Dingledine
590a98ff37
clean up r10240 so we avoid the exit node itself too
...
svn:r10242
2007-05-22 01:20:23 +00:00
Roger Dingledine
b89ad9eb1b
mark a bug for nick to tackle -- we're rebuilding our router store more
...
often than we need to. reported by lodger.
svn:r10241
2007-05-22 01:17:08 +00:00
Roger Dingledine
6ede110c4d
When choosing an entry guard for our circuit, avoid using guards
...
that are in the same family as the chosen exit -- not just guards
that are exactly the chosen exit. (Reported by lodger.)
svn:r10240
2007-05-22 01:01:24 +00:00
Roger Dingledine
82054e0dd2
Make the NodeFamilies config option work. (Reported by
...
lodger -- it has never actually worked, even though we added it
in Oct 2004.)
svn:r10238
2007-05-22 00:46:55 +00:00
Nick Mathewson
de5194eeaa
r13025@Kushana: nickm | 2007-05-21 17:40:56 -0400
...
Bugfix and possible backport candidate: use the same logic as in read_all when reading resolv.conf. Maybe this fixes bug 433.
svn:r10237
2007-05-21 21:48:02 +00:00
Peter Palfrader
d2f7a9d0cc
Hopefully fix #429 for good by actually using, not just figuring out, the correct mmap
...
svn:r10233
2007-05-21 12:14:45 +00:00
Nick Mathewson
a4f5b99e61
r13023@Kushana: nickm | 2007-05-20 16:16:36 -0400
...
More bulletproofing on bug 429
svn:r10231
2007-05-20 20:16:45 +00:00
Nick Mathewson
21a72520ce
r13021@Kushana: nickm | 2007-05-20 14:03:10 -0400
...
Provide actual reasons when dropping an uploaded extrainfo for incompatibility; also, clean whitespace.
svn:r10230
2007-05-20 18:03:26 +00:00
Nick Mathewson
5364833be0
r13017@Kushana: nickm | 2007-05-20 13:40:45 -0400
...
Address points in r10227.
svn:r10229
2007-05-20 17:43:55 +00:00
Nick Mathewson
bc26f28865
svn:r10228
2007-05-20 17:43:29 +00:00
Roger Dingledine
ddd0054a85
point out two remote crash bugs, a memory leak, and a few other
...
items we should probably look into.
svn:r10227
2007-05-20 14:15:23 +00:00
Nick Mathewson
0b661f6575
r12818@catbus: nickm | 2007-05-20 01:15:50 -0400
...
Look for extrainfo bodies in the extrainfo mmap, not in the descriptor mmap. Duh. Should fix bug 429.
svn:r10226
2007-05-20 05:15:53 +00:00
Peter Palfrader
6d46ece6ac
Fix a loop in routerlist_assert_ok()
...
svn:r10224
2007-05-19 21:14:17 +00:00
Nick Mathewson
5f58bee0b0
r12812@catbus: nickm | 2007-05-19 16:17:36 -0400
...
Fix compilation with -O0; add unit tests for swap and shuffle.
svn:r10223
2007-05-19 20:17:37 +00:00
Nick Mathewson
6f8866a817
r12810@catbus: nickm | 2007-05-19 16:08:42 -0400
...
Fix bugs in extrainfo_insert, and change it to use desc_by_eid_map.
svn:r10222
2007-05-19 20:08:44 +00:00
Nick Mathewson
4d3ec5919e
r12808@catbus: nickm | 2007-05-19 14:48:51 -0400
...
Fix another consistency error.
svn:r10221
2007-05-19 18:48:53 +00:00
Nick Mathewson
48e30ce2c7
r12805@catbus: nickm | 2007-05-19 14:31:00 -0400
...
Fix a groovy memory corruption bug in routerlist_replace.
svn:r10220
2007-05-19 18:31:04 +00:00
Nick Mathewson
07199e3d09
r12804@catbus: nickm | 2007-05-19 14:21:18 -0400
...
Disable a blatantly incorrect control event with potential for memory corruption.
svn:r10219
2007-05-19 18:31:02 +00:00
Nick Mathewson
0a27b53252
r12802@catbus: nickm | 2007-05-19 14:12:27 -0400
...
clear some ram when freeing it; add some more checks to assert_routerlist_ok.
svn:r10218
2007-05-19 18:12:31 +00:00
Nick Mathewson
58d27cfc29
r12800@catbus: nickm | 2007-05-18 20:45:15 -0400
...
Possible fix for bug 417 and bug 404: do not insert our routerinfo directly; instead, re-parse it first.
svn:r10217
2007-05-19 00:45:17 +00:00
Nick Mathewson
61a116b3da
r12798@catbus: nickm | 2007-05-18 20:31:54 -0400
...
Yet more debugging code to track down 417/404, inspired by a fun core from arma.
svn:r10216
2007-05-19 00:32:00 +00:00
Nick Mathewson
adf95e7f00
r12794@catbus: nickm | 2007-05-18 20:24:26 -0400
...
Make caches-extra-info lines parseable.
svn:r10215
2007-05-19 00:24:29 +00:00
Roger Dingledine
84c3a19170
found this in my sandbox
...
svn:r10214
2007-05-19 00:14:34 +00:00
Nick Mathewson
e476e61ce0
r12982@Kushana: nickm | 2007-05-18 15:15:14 -0400
...
Partial backport candidate: We had a bug where we were downloading descriptors by descriptor digest, but trying to look them up by identity fingerprint when updating their failure count and next retry time. (Also use correct backoff logic for extrainfo code.) Needs testing, doubtless.
svn:r10210
2007-05-18 21:19:53 +00:00
Nick Mathewson
ec55cf526d
r12981@Kushana: nickm | 2007-05-18 14:12:19 -0400
...
First cut at code to download extra-info docs. Also note a bad bug in directory.c (look for the string BUG BUG BUG).
svn:r10209
2007-05-18 21:19:19 +00:00
Nick Mathewson
b4bd9f772c
r12771@catbus: nickm | 2007-05-16 18:12:32 -0400
...
Make -Wstrict-overflow=5 happy with GCC 4.2. It is kind of a pain, but it does agood job of letting us know where we can make our code better by simplifying dependent conditionals.
svn:r10201
2007-05-16 22:16:13 +00:00
Nick Mathewson
2988d797eb
r12770@catbus: nickm | 2007-05-16 17:49:26 -0400
...
Move around field order a little, in order to compact some structures. (Thanks to -Wpadded)
svn:r10200
2007-05-16 22:15:57 +00:00
Nick Mathewson
807adfc879
r12769@catbus: nickm | 2007-05-16 17:32:01 -0400
...
Fix warnings from -Wunsafe-loop-optimizations, which incidentally turned up a logic bug in connection_or_flush_from_first_active_circuit that would overcount the number of cells flushed.
svn:r10199
2007-05-16 22:15:48 +00:00
Nick Mathewson
b837191fd0
r12768@catbus: nickm | 2007-05-16 17:25:33 -0400
...
Fix GCC warnings related to local parameters/variables getting shadowed.
svn:r10198
2007-05-16 22:15:14 +00:00
Nick Mathewson
e043b86f47
r12764@catbus: nickm | 2007-05-15 17:17:39 -0400
...
Enable (and cope with) more GCC 4.2 warnings.
svn:r10196
2007-05-15 21:17:48 +00:00
Nick Mathewson
bfdc366037
r12763@catbus: nickm | 2007-05-15 05:29:33 -0400
...
Make --enable-gcc-warnings happy on the upcoming gcc 4.2
svn:r10195
2007-05-15 21:17:42 +00:00
Nick Mathewson
ca32b4d5b5
r12761@catbus: nickm | 2007-05-15 03:13:52 -0400
...
Be a lot smarter when parsing lists of routers and extrainfos.
svn:r10193
2007-05-15 07:13:56 +00:00
Nick Mathewson
a7514649c3
r12758@catbus: nickm | 2007-05-14 15:19:29 -0400
...
Cleanup, lock-down, and refactor bits of routerparse.c: use a single unified function to check all signatures. Fix all DOCDOCs. Remove some old dead debugging code. Enforce some parsing rules better.
svn:r10192
2007-05-14 22:51:05 +00:00
Roger Dingledine
37519d993d
backport candidate: seems to me that r10153 won't work without
...
this patch too.
svn:r10187
2007-05-14 08:09:12 +00:00
Nick Mathewson
5f9d4d0587
r12750@catbus: nickm | 2007-05-13 10:08:13 -0400
...
Fix compilation in connection_edge.c
svn:r10186
2007-05-13 20:24:43 +00:00
Roger Dingledine
440b7f0c70
polish r9726-r9903
...
svn:r10182
2007-05-13 09:25:06 +00:00
Roger Dingledine
346826d97b
If a directory authority is down, skip it when deciding where to get
...
networkstatus objects or descriptors. Otherwise we keep asking
every 10 seconds forever.
(adapted from r9880)
svn:r10175
2007-05-12 23:22:27 +00:00
Nick Mathewson
11f3e894d3
r12708@catbus: nickm | 2007-05-10 15:18:08 -0400
...
Patch from shibz: implement a getinfo status/version/... so a controller can tell whether the current version is recommended, whether any versions are good, and how many authorities agree.
svn:r10162
2007-05-10 19:30:02 +00:00
Nick Mathewson
e3b2a7b53b
r12935@Kushana: nickm | 2007-05-10 11:25:09 -0400
...
Make buffer unit tests pass again
svn:r10158
2007-05-10 15:25:40 +00:00
Roger Dingledine
de11011b1b
backport candidate: when we have k non-v2 authorities in our
...
dirservers lines, we ignored as many as k v2 authorities while
updating our network-statuses.
(not a problem right now since we have zero non-v2 authorities.
but if we ever change that...)
svn:r10157
2007-05-10 10:01:53 +00:00
Roger Dingledine
4e9a008e66
Backport candidate: if all of our dirservers have given us
...
bad or no networkstatuses lately, then stop hammering them
once per minute even if we think they're failed.
svn:r10156
2007-05-10 09:34:34 +00:00
Roger Dingledine
5ffabd4de4
backport candidate:
...
If a directory server runs out of space in the connection table
as it's processing a begin_dir request, it will free the exit stream
but leave it attached to the circuit, leading to unpredictable
behavior. (Reported by seeess, fixes bug 425.)
svn:r10154
2007-05-10 08:53:05 +00:00
Roger Dingledine
cd23b65a07
Backport candidate: count it as a failure if we fetch a valid
...
network-status but we don't want to keep it. Otherwise we'll keep fetching
it and keep not wanting to keep it. Fixes part of bug 422.
svn:r10153
2007-05-10 05:12:20 +00:00
Roger Dingledine
8e8144cd58
fix a printf size_t/int mismatch from r10150
...
svn:r10152
2007-05-10 04:04:44 +00:00
Roger Dingledine
de6b3512e9
move a few more situations over to the authority_type_t bitfield
...
svn:r10151
2007-05-10 04:01:28 +00:00
Nick Mathewson
34a09c24b5
r12706@catbus: nickm | 2007-05-09 18:39:46 -0400
...
Keep two freelists for buffer ram chunks: one of 4k chunks, and one of 16k chunks. Also, document the whole business.
svn:r10150
2007-05-09 22:39:49 +00:00
Nick Mathewson
b248ed620f
r12704@catbus: nickm | 2007-05-09 17:43:34 -0400
...
Periodically clean the freelist of buffer memory chunks.
svn:r10149
2007-05-09 21:43:41 +00:00
Nick Mathewson
ceac39aa8a
r12697@catbus: nickm | 2007-05-09 00:15:40 -0400
...
Change authority_type_t to a set of flags; use it more consistently.
svn:r10144
2007-05-09 04:15:46 +00:00
Roger Dingledine
66f9240eb5
complain when we try to upload to, say, bridge authorities,
...
yet we didn't configure any first.
svn:r10143
2007-05-09 02:20:03 +00:00
Roger Dingledine
07bf274d98
Interim commit: new config options Bridge and UseBridges.
...
It is becoming increasingly clear to me that bridges should
be a special case of entry guards, not a whole separate pile
of nearly identical functions.
svn:r10141
2007-05-08 11:28:05 +00:00
Roger Dingledine
d136f2a7b2
When we are reporting the DirServer line we just parsed, we were
...
logging the second stanza of the key fingerprint, not the first.
svn:r10140
2007-05-08 10:33:46 +00:00
Roger Dingledine
54f5ab39b3
record the router purpose at each step of the circuit path.
...
i have the feeling this will come in handy.
svn:r10139
2007-05-08 10:11:53 +00:00
Roger Dingledine
1d3bb103a4
clean up some function argument names
...
svn:r10138
2007-05-08 10:01:33 +00:00
Roger Dingledine
a201861dc2
use the new _PublishServerDescriptor to publish descriptors either
...
to v2 authorities or to bridge authorities, depending on config.
svn:r10137
2007-05-08 09:13:30 +00:00
Roger Dingledine
e4f40dd794
Change the PublishServerDescriptor config option from a boolean
...
into a string: "v1", "v2", bridge", "". Continue to support
"0" and "1".
svn:r10136
2007-05-08 09:09:26 +00:00
Nick Mathewson
89753e2163
r12676@catbus: nickm | 2007-05-07 13:11:38 -0400
...
When we cannot find a micro-revision number, do not overwrite an already-present micro-revision.i.
svn:r10134
2007-05-07 17:11:53 +00:00
Roger Dingledine
95ead29574
prepare directory_post_to_dirservers() to hear what sort of
...
dir authority we'd like to upload to. at some point we should
pick a config option to say that in, for bridges.
svn:r10129
2007-05-07 09:28:48 +00:00
Roger Dingledine
f8a8b27dd2
add a 'bridge' flag for dirserver config entries
...
svn:r10128
2007-05-07 08:26:50 +00:00
Roger Dingledine
43411ceed3
Implement "getinfo status/circuit-established"
...
svn:r10120
2007-05-05 22:51:02 +00:00
Roger Dingledine
713626bd73
make it work on windows/etc again, i presume
...
svn:r10118
2007-05-04 10:43:01 +00:00
Roger Dingledine
10efbed2f5
ok, i'm not so good at counting
...
svn:r10117
2007-05-04 10:39:17 +00:00
Roger Dingledine
0ce53ca817
on the theory that my client_used hack is here to stay at least for the
...
next little while, make it only take effect _when there's an attached
origin circuit_, rather than from the first attached origin circuit
until death of the conn.
svn:r10116
2007-05-04 10:34:47 +00:00
Roger Dingledine
462dfe2012
make MaxAdvertisedBandwidth into a legal default
...
svn:r10115
2007-05-04 09:25:23 +00:00
Roger Dingledine
b1d93df038
if you're using relaybandwidthrate and relaybandwidthburst, make
...
sure that's reflected in your router descriptor.
svn:r10114
2007-05-04 09:20:13 +00:00
Roger Dingledine
dc795203aa
early skeletal support for running a bridge directory authority
...
svn:r10112
2007-05-04 08:04:27 +00:00
Roger Dingledine
d112e7b1ad
fix some code comments, a wrapper, and add a todo item
...
svn:r10111
2007-05-04 07:24:01 +00:00
Roger Dingledine
dfe93fb386
whoops, i missed main.c in my r10092
...
svn:r10098
2007-05-02 21:56:32 +00:00