Commit Graph

192 Commits

Author SHA1 Message Date
Roger Dingledine
53431a4950 fix compile complaints (and a bug)
svn:r4862
2005-08-26 21:30:52 +00:00
Nick Mathewson
e24d540d81 We no longer need dirserv_load_from_directory_string, so dirserv_add_descriptor no longer has to keep track of where each descriptor ends.
svn:r4861
2005-08-26 21:28:16 +00:00
Nick Mathewson
f559c49c39 Make network-status strings wellformed
svn:r4857
2005-08-26 21:11:53 +00:00
Nick Mathewson
9a3be928e9 Note that a descriptor has changed when we receive a new directory.
svn:r4855
2005-08-26 21:02:18 +00:00
Nick Mathewson
0e649ac60a Remove descriptor_list and use routerlist instead. Make directories manage routerlist a little better.
svn:r4854
2005-08-26 20:59:04 +00:00
Roger Dingledine
f3bccdce73 if dirservers set assumereachable, it overrides their individual
reachability testing


svn:r4851
2005-08-26 20:08:12 +00:00
Nick Mathewson
0239249160 Only free strmap if it is allocated.
svn:r4846
2005-08-26 18:48:13 +00:00
Nick Mathewson
ff25a7707a fix syntax err
svn:r4843
2005-08-26 18:35:52 +00:00
Nick Mathewson
88989be99b More documenting
svn:r4842
2005-08-26 18:02:49 +00:00
Nick Mathewson
d54d7b7ec1 Add some documentation; move the signature generation logic into routerparse.c along with the hash generation logic; make router signing use it as well.
svn:r4840
2005-08-26 15:34:53 +00:00
Nick Mathewson
e68bed8782 Fall back to routerlist instead of descriptor_list when we are a cache.
svn:r4837
2005-08-25 20:54:12 +00:00
Nick Mathewson
4dc3cb9fd9 Fix a segfault when starting a dir cache
svn:r4836
2005-08-25 20:45:53 +00:00
Nick Mathewson
54a6a8f0ef Start implementing the server side of the new directory protocol.
Probably very buggy, since I can't actually run an authdir.

Features
- Generate and publish new network-status format
- Code to cache and re-serve network-status objects generated by others.
- Publish individual descriptors (by fingerprint, by "all", and by
  "tell me yours.")  [Still needs compression logic]
- Publish client and server recommended versions seprately.
- Add digest of descriptor to routerinfo_t, so we can track them better, and
  length, so we can server them more easily.

Cleanups
- Unify code to sign directory-like things
- Make resolve_my_address() able to tell you which name it wound up resolving.
- Unify code to store and serve directory-like things so it all uses
  cached_dir_t.
- Unify code to set the value of cached_dir_t objects.


svn:r4835
2005-08-25 20:33:17 +00:00
Roger Dingledine
86f85f240c be much more conservative about logging reachability complaints.
the ones it logs now are probably genuine problem servers.


svn:r4832
2005-08-24 14:31:32 +00:00
Roger Dingledine
a120cc20c1 Dirservers now do their own external reachability testing of each
Tor server, and only list them as running if they've been found to
be reachable.

Dirservers also log trouble servers, but only start complaining loudly
after they've been up for an hour, to reduce false positives. We still
need to do something about the fact that it is quite loud when there
are many trouble servers.


svn:r4829
2005-08-24 02:31:02 +00:00
Nick Mathewson
50452c32ec fix bug 180: handle duplicate lines in approved-routers files.
svn:r4825
2005-08-23 22:00:35 +00:00
Roger Dingledine
cc1b82ade8 when listing min-bandwidth servers in the controller, don't get
fooled by a low bandwidthrate


svn:r4777
2005-08-14 08:38:34 +00:00
Roger Dingledine
ff54050fda let unregistered-servers take a parameter (the min bandwidth)
nick, is this an ugly hack of your protocol?


svn:r4775
2005-08-13 02:20:00 +00:00
Roger Dingledine
66b21a19db Add a 'quit' command for the controller.
Add a 'getinfo unregistered-servers' for arma's internal use.


svn:r4774
2005-08-13 01:55:23 +00:00
Nick Mathewson
18c11eb3bc Be consistent about preferring foo* to struct foo*
svn:r4637
2005-07-22 21:12:10 +00:00
Roger Dingledine
7c7c95c3f6 anonymous bugfix on our pointer arithmetic
svn:r4535
2005-07-12 22:56:06 +00:00
Nick Mathewson
30571317dd Fix unit tests that used old signature for add_fingerprint_to_dir
svn:r4495
2005-06-27 22:25:09 +00:00
Roger Dingledine
419d647353 more cleanups before i go wild
svn:r4469
2005-06-21 01:00:42 +00:00
Roger Dingledine
9c67ae34f1 overall cleanup and streamlining and doccing
also fix a DoS avenue on dirservers


svn:r4468
2005-06-20 23:04:13 +00:00
Nick Mathewson
d4972bd2e1 Remove code that has been #if-0ed for a long time.
svn:r4435
2005-06-15 18:34:46 +00:00
Nick Mathewson
232861ba42 Docment or add DOCDOC comments to undocumented functions in src/or. Make function definition format uniform.
svn:r4411
2005-06-11 18:52:12 +00:00
Roger Dingledine
fcd0fc3364 flesh out the source file descriptions for doxygen
svn:r4404
2005-06-11 05:31:17 +00:00
Nick Mathewson
0831823763 Change end-of-file NLNL convention. It turns out arma I and I agree.
svn:r4382
2005-06-09 19:03:31 +00:00
Roger Dingledine
15f937c95e when a dirserver gets a mismatched fingerprint, log the expected
fp and the received fp


svn:r4372
2005-06-09 10:21:55 +00:00
Roger Dingledine
978648bff8 also print the platform string for rejected descriptors
svn:r4160
2005-05-02 22:06:04 +00:00
Roger Dingledine
15c1853bd6 don't print nulls
svn:r4159
2005-05-02 21:54:16 +00:00
Roger Dingledine
c9e83eb1b4 when we refuse a router descriptor, log contactinfo and source address.
svn:r4156
2005-05-02 21:48:54 +00:00
Nick Mathewson
69dc4e1675 Remove support for looking at old directory/routerdesc elements; mark non-new elements optional; switch to new format for dir-signing-key; start accepting newer elements so we can mark them as non-opt later; make tor-spec say the right stuff.
svn:r4154
2005-05-02 21:22:31 +00:00
Roger Dingledine
914ee87e07 stop re-reading and re-parsing the directory as soon as we make it.
it was nice for checking if we've got bugs, but it's really quite
expensive too. it was also nice for updating our routerinfo's
immediately, but we'll update them like everybody else when we fetch
a new dir from somebody else.


svn:r4128
2005-04-27 00:48:05 +00:00
Roger Dingledine
bf79b5266f those should be notices, not warns
svn:r4079
2005-04-12 22:09:04 +00:00
Nick Mathewson
8cc3307e0d Improve conn_*_to_string; add circuit_state_to_string; make skewed-descriptor messages better.
svn:r4047
2005-04-07 21:07:19 +00:00
Roger Dingledine
dd98412ce1 allow servers to publish descriptors from 12 hours in the future.
hopefully this will allow more slack and let crummier servers help
out too.


svn:r4046
2005-04-07 21:01:00 +00:00
Nick Mathewson
7709547c08 When we connect and finish TLS negotiation with address:port, it is obvious that any other key or nickname we might know about (as an authdirserver) does not actually exist at address:port.
svn:r4036
2005-04-06 21:09:47 +00:00
Nick Mathewson
3014b03b67 Add missing comma. Oops
svn:r4017
2005-04-06 03:20:06 +00:00
Nick Mathewson
88fe4d6292 Handle changed router status correctly when reloading fingerprint file
svn:r4016
2005-04-06 01:09:26 +00:00
Nick Mathewson
1b5e2182fa Log msg spelling fix
svn:r4015
2005-04-06 00:53:13 +00:00
Nick Mathewson
374edd356e Change replacement semantics for directory entries: fix bug 121.
svn:r4012
2005-04-06 00:01:35 +00:00
Roger Dingledine
823b7d4d8b automatically approve nodes running 0.1.0.2-rc or later
svn:r4001
2005-04-03 19:01:47 +00:00
Nick Mathewson
0e81265359 update copyright notices.
svn:r3982
2005-04-01 20:15:56 +00:00
Nick Mathewson
6e4bccc4ac Make GETINFO for "network-status" work on non-authdirs
svn:r3837
2005-03-23 19:15:10 +00:00
Nick Mathewson
b9016bd18f Fix several bugs (including some crashes) related to control interface; implement missing desc/name functionality.
svn:r3836
2005-03-23 08:40:11 +00:00
Nick Mathewson
0b7a9e2e7b Be willing to cache directories from up to ROUTER_MAX_AGE seconds into the future, now that we are more tolerant of skew.
svn:r3832
2005-03-23 06:39:53 +00:00
Nick Mathewson
905c16846a Fix a few more instances of memory not freed on exit (found by weasel).
svn:r3830
2005-03-23 06:20:50 +00:00
Roger Dingledine
ed9524a626 Remove controller getinfo support for "desc/all-ids".
Replace it with getinfo "network-status" just like in directories.
This way the controller can learn which servers are running, which
are verified, etc.


svn:r3801
2005-03-22 03:27:51 +00:00
Nick Mathewson
bbaa3c7792 Implement more control spec functionality
- Mapaddress
- Postdescriptor
- GetInfo on descriptors

Required changes elsewhere:
- Keep the most recent running_routers_t in the routerlist_t. That way we
  can learn about new routers and remember whether we were last told that
  they were up or down.  Also enables more simplifications.
- Keep the signed descriptor inside routerinfo_t.  This makes
  descriptor_entry_t in dirservers.c unneeded.
- Rename AddressMap (the verb) to MapAddress. Keep AddressMap as a noun.
- Check addresses for plausibility before mapping them.


svn:r3696
2005-02-25 20:46:13 +00:00