Commit Graph

488 Commits

Author SHA1 Message Date
Roger Dingledine
310a8da0d2 break reached_eof() out of process_inbuf()
svn:r2930
2004-11-21 10:14:57 +00:00
Roger Dingledine
671d84dc2f some more debugging aids
svn:r2929
2004-11-21 09:39:01 +00:00
Roger Dingledine
6a516dfdd3 be more greedy about filling up all relay cells.
this may have some bugs in it still.
and it may end up not being what we want to do.


svn:r2928
2004-11-21 07:43:12 +00:00
Nick Mathewson
bb18d4238f Dont keep rephist info for routers that havent had activity for 24 hours.
svn:r2926
2004-11-21 05:14:46 +00:00
Nick Mathewson
36f4e15e81 Call init_keys() where needed; fix hibernate bug.
svn:r2924
2004-11-21 04:19:04 +00:00
Nick Mathewson
8acaf8e187 Add "MEMUNIT" and "INTERVAL" types to configuration. Also tweak Accounting setup. More docs needed
svn:r2911
2004-11-20 00:37:00 +00:00
Roger Dingledine
4b76fe8036 Break DirFetchPostPeriod into:
- DirFetchPeriod for fetching full directory,
  - StatusFetchPeriod for fetching running-routers,
  - DirPostPeriod for posting server descriptor,
  - RendPostPeriod for posting hidden service descriptors.

Also make sure the hidden service descriptors are at a random
offset from each other, to hinder linkability.


svn:r2889
2004-11-15 09:05:54 +00:00
Nick Mathewson
22a0d82749 Cache running-routers; compress running-routers; serve compressed running-routers.z
svn:r2883
2004-11-15 04:04:20 +00:00
Roger Dingledine
ee591be3f2 fix a bug in configuring accounting in options_act()
svn:r2881
2004-11-15 04:01:31 +00:00
Nick Mathewson
3e6edf20cc Resolve some hibernating-related XXXX009s.
svn:r2875
2004-11-14 22:21:23 +00:00
Nick Mathewson
a732727a2b Add simpler option_is_same, as suggested by arma. Finish implementing SAVECONF
svn:r2868
2004-11-14 20:51:28 +00:00
Nick Mathewson
08627d5d87 Track whether descriptor is dirty/uploaded. When any options are set, mark it dirty. Once a minute, regenerate and upload the server descriptor if it is dirty.
svn:r2832
2004-11-13 16:53:48 +00:00
Nick Mathewson
eabcf6618e Write most of the implementation for SAVECONF.
svn:r2820
2004-11-12 20:09:54 +00:00
Nick Mathewson
5109de5626 Rename exit_policy to addr_policy, since it gets used for SOCKS and directory connections too. Make all policies get validated in options_validate, and make SOCKS/directory policies get set in options_act.
svn:r2819
2004-11-12 19:39:13 +00:00
Nick Mathewson
60880cda84 Resolve a bunch of FIXME items; mark a lot more for attention; ask for clarification on some. Turn all XXXX008 ("showstopper for 0.0.8 release") items into XXXX009 or XXXX, since plainly they were not showstoppers for 0.0.8. Add/clean some docs.
svn:r2808
2004-11-12 16:39:03 +00:00
Nick Mathewson
954570486f Resolve a FIXME: use identity comparison, not nickname comparison, to
choose circuit ID types.  This is important because our view of "the
nickname of the router on the other side of this connection" is
skewed, and depends on whether we think the other rotuer is
verified--and there's no way to know whether another router thinks you
are verified.

For backward compatibility, we notice when the other router chooses
the same circuit ID type as us (because it's running an old version),
and switch our type to be polite.


svn:r2797
2004-11-10 20:14:37 +00:00
Nick Mathewson
c9af37d1ba Resolve FIXME items: make circuit_free_cpath_node static
svn:r2792
2004-11-10 14:28:04 +00:00
Roger Dingledine
646903542a make nick's config patch build
svn:r2783
2004-11-10 03:48:38 +00:00
Nick Mathewson
4cdddcc13d Remvove an XXX
svn:r2769
2004-11-10 02:02:06 +00:00
Nick Mathewson
5a5be93f80 Normalize whitespace; add a "tell me about all the unnormalized whitespace" target; fix a braino in dirserv.c
svn:r2758
2004-11-09 20:04:00 +00:00
Nick Mathewson
cd753df7bf Resolve many XXXs and all DOCDOCs
svn:r2755
2004-11-09 18:22:17 +00:00
Nick Mathewson
b960574556 Change interface to config_trial_assign even more; have it use get_options() instead
svn:r2754
2004-11-09 17:15:17 +00:00
Roger Dingledine
3901473bf3 change the interface to config_trial_assign()
svn:r2737
2004-11-09 07:55:48 +00:00
Roger Dingledine
6521c2ce51 Stop using the wrong DataDirectory when we're validating.
Also validate/normalize the DataDirectory better.


svn:r2732
2004-11-09 07:05:53 +00:00
Nick Mathewson
48a0b6c476 Separate is-recognized-option from get-option-value, since NULL is ambiguous and returning "" misrepresents.
svn:r2731
2004-11-09 06:40:32 +00:00
Roger Dingledine
90b47172bd Make an options_act() where we do all the things a new options set
needs.
Still needs more work.


svn:r2716
2004-11-09 04:28:18 +00:00
Nick Mathewson
cb5de85585 Separate validate from activate. Document undocumented stuff in config.c.
svn:r2711
2004-11-08 23:12:40 +00:00
Roger Dingledine
394554cfbf Clean up copyrights.
Break connection_consider_empty_buckets() out of
connection_read_bucket_decrement().


svn:r2698
2004-11-07 01:33:06 +00:00
Roger Dingledine
6c61ed4fb5 Make options no longer a global variable.
Now we can try setting an option but back out if it fails to parse, or
  if it's disallowed (e.g. changing RunAsDaemon from 1 to 0).
Use parse_line_from_str rather than parse_line_from_file.


svn:r2692
2004-11-06 05:18:11 +00:00
Nick Mathewson
2e8353e2f4 Use new log format; convert old format to new format.
svn:r2684
2004-11-05 05:50:35 +00:00
Roger Dingledine
2ba3a9de16 make the default default options.FirewallPorts be the default
svn:r2683
2004-11-04 23:39:57 +00:00
Nick Mathewson
19868fe968 Move accounting code into hibernate; start adding logic to track bandwidth-per-seconds-active
svn:r2680
2004-11-04 22:33:06 +00:00
Roger Dingledine
f7a30fa73e break out validate_options
leave options.FirewallPorts NULL if it's NULL


svn:r2673
2004-11-04 10:23:30 +00:00
Roger Dingledine
59453ac6ef add a ControlPort and control listener conn.
note that print_usage is obsolete.


svn:r2671
2004-11-04 06:41:49 +00:00
Roger Dingledine
d0c158c8d6 clarify the bandwidthburst and bandwidthrate are in bytes
(niels had thought they were in bits, or kb, or something)


svn:r2669
2004-11-04 03:25:43 +00:00
Nick Mathewson
cea9125d71 Implement two flavors of authentication for control connections: one for trusted FS, one for untrusted FS.
svn:r2664
2004-11-03 19:49:03 +00:00
Nick Mathewson
451f8b5045 - Implement all of control interface except authentication, setconfig,
and actually making the sockets.
- Make sure that identity-based nicknames start with $.
- Use new string_join interface.


svn:r2661
2004-11-03 18:33:07 +00:00
Nick Mathewson
347d3f9d62 Start implementing control interface.
svn:r2652
2004-11-03 01:32:26 +00:00
Nick Mathewson
8db0abb687 First attempt at hibernation code. It needs more work around the XXXXs, but first I want arma to review the basic approach while I meditate on how to fix them.
svn:r2649
2004-11-02 23:47:32 +00:00
Nick Mathewson
ad4dc74482 Use a stricter set of warnings; make them all pass.
svn:r2645
2004-11-02 03:02:17 +00:00
Roger Dingledine
b390786582 Hidden service operators had a bug in version 1 style INTRODUCE cells
that made them fail. Fix the bug, and revert clients to use version 0
until 0.0.9pre4 is obsolete.


svn:r2641
2004-11-01 21:46:27 +00:00
Nick Mathewson
ce79bab7f1 Split util into util (general utilities), container (smartlist and strmap), and compat (cross-platform compatability).
svn:r2640
2004-11-01 20:41:47 +00:00
Roger Dingledine
984ffec105 implement first piece of hibernation
still need to track bandwidth, and make decisions based on bandwidth


svn:r2630
2004-10-31 20:28:41 +00:00
Nick Mathewson
9510d9a792 tor --list-fingerprint to print fingerprint and exit
svn:r2627
2004-10-30 19:18:37 +00:00
Nick Mathewson
11d330be5e Tweaks to prevent obsolete restarting tors from hammering the dirservers. (1) Cache a received directory as soon as the signature checks out. (2) Treat a cached directory as "recent" based on its mtime. (3) If we have a recent directory, we dont need to fetch a newer one for DirFetchPostPeriod. This needs review!
svn:r2618
2004-10-28 18:37:52 +00:00
Nick Mathewson
2fbf31533b Tricksy compiler warnings! We hates them, hates them forever, my precious!
svn:r2615
2004-10-27 21:14:11 +00:00
Nick Mathewson
ce5709184b Pass with -Wstrict-prototypes
svn:r2614
2004-10-27 18:16:37 +00:00
Nick Mathewson
b90b2bb848 Add and document router-status line using new unified liveness/verifiedness format; continue to generate running-routers; continue to parse running-routers when no router-status line is found
svn:r2592
2004-10-27 00:48:51 +00:00
Roger Dingledine
0113a643a2 quick-and-dirty dir policy since the dirservers are getting hammered
nick, could you abstract this sometime so we don't repeat the
sockspolicy code twice?


svn:r2589
2004-10-25 06:16:26 +00:00
Nick Mathewson
57f09573f5 Every 60 seconds, check whether the listeners are still alive, and relaunch the dead ones.
svn:r2581
2004-10-24 01:22:40 +00:00