Commit Graph

76 Commits

Author SHA1 Message Date
Nick Mathewson
d0ff485e1b More work on directories. Signed directories not yet tested. No support for checking sigs yet
svn:r268
2003-05-07 02:13:23 +00:00
Nick Mathewson
fcf7bfe290 Refactor directories; add unit tests; add router keyword
svn:r266
2003-05-06 17:38:16 +00:00
Roger Dingledine
03ed54e920 put some symbolic constants to the onion skin lengths
svn:r265
2003-05-06 05:54:42 +00:00
Roger Dingledine
d7f50337c1 incremental path building in; uses ephemeral DH; onions are gone
still need to change circuit-level sendmes


svn:r264
2003-05-05 23:24:46 +00:00
Nick Mathewson
44b4efe34d Tests, headers, and debugging for onion skin backend
svn:r263
2003-05-05 04:27:00 +00:00
Roger Dingledine
96759a609e streams are now 8 bytes, and are recognized by intermediate hops
the OP only crypts the appropriate number of times depending on which
layer (hop on the path) it's for/from.


svn:r262
2003-05-02 21:29:25 +00:00
Roger Dingledine
8a94dd60af cpath is now a doubly linked list, not an array
svn:r260
2003-05-01 22:55:51 +00:00
Roger Dingledine
0560008497 terminology shift: data->relay, topic->relay, topic->stream
svn:r258
2003-05-01 06:42:29 +00:00
Nick Mathewson
32a3e704b4 Choose correct abstraction for topic_foo. Abstract random-integer code
svn:r249
2003-04-17 17:10:41 +00:00
Nick Mathewson
97d847b9e3 Factor out cell packing and unpacking
svn:r240
2003-04-16 17:44:33 +00:00
Nick Mathewson
33176c70a5 Factor out timeval-related functions.
svn:r237
2003-04-16 17:04:58 +00:00
Nick Mathewson
0c61bc3756 Remove the notion of "onion ciphers"; make packing and unpacking separate fns
svn:r236
2003-04-16 16:19:27 +00:00
Roger Dingledine
54af75b1b4 add missing prototype
svn:r235
2003-04-16 16:17:27 +00:00
Roger Dingledine
e1d37ed6ab divorce circuit building from user connections
now we rebuild the circuit periodically (but only if it's been used),
and we can further abstract it to do incremental circuit building, etc.


svn:r233
2003-04-16 06:18:31 +00:00
Nick Mathewson
1fa0fc1487 Introduce a few unit tests (from older code), refactor compression setup/teardown
svn:r232
2003-04-15 19:10:18 +00:00
Roger Dingledine
7df5caad0d make it work (heh)
svn:r231
2003-04-11 22:28:51 +00:00
Roger Dingledine
1d53d8ad0e refactored some duplicate code into connection_edge.c
svn:r230
2003-04-11 22:11:11 +00:00
Roger Dingledine
cdf6ea201f put most of the remaining exit policy stuff in
route selection still doesn't pay attention to exit policies though


svn:r227
2003-04-08 06:44:38 +00:00
Roger Dingledine
18bbac44ca parse exit policy lines
svn:r225
2003-04-07 04:38:19 +00:00
Nick Mathewson
c217b1ca71 Add magic to end of C files to make emacs happy; split test invocation into separate file.
svn:r224
2003-04-07 02:12:02 +00:00
Roger Dingledine
96e5f776d6 move cell size to 256. seems to work (?)
svn:r218
2003-03-24 04:02:24 +00:00
Roger Dingledine
9ac9db782a fix rare race condition
if the directory is remade while an OR is handshaking, the directory
needs to become dirty again when the handshake succeeds


svn:r215
2003-03-24 02:50:07 +00:00
Roger Dingledine
5d0904bc41 kludge because openssl and zlib both typedef free_func :(
svn:r208
2003-03-19 22:27:37 +00:00
Nick Mathewson
0fed84785e Finish zlib and half-open; switch to 3des (ede/ofb)
svn:r198
2003-03-19 20:48:56 +00:00
Roger Dingledine
64e46988f6 greatly simplify this notion of 'roles':
if your ORPort is non-zero then you must connect to all nodes
if your DirPort is non-zero then you must act like a directory server


svn:r192
2003-03-18 01:49:55 +00:00
Nick Mathewson
6deed60bb5 Add code for end-to-end zlib compression. Still needs flow-control
svn:r187
2003-03-17 02:42:45 +00:00
Roger Dingledine
70b35ce8c2 lazy (just in time) directory rebuilding
svn:r174
2003-03-11 01:51:41 +00:00
Roger Dingledine
b50c406c08 clean out obsolete cell types
svn:r170
2003-03-07 08:24:55 +00:00
Roger Dingledine
f97ddd44cd minor code cleanup
svn:r166
2003-03-05 20:03:05 +00:00
Roger Dingledine
7461959371 let up on the bandwidth constraints
svn:r162
2003-02-18 01:55:51 +00:00
Roger Dingledine
1714ea2ab8 Bugfixes and enhancements in sendmes and dns farm
svn:r161
2003-02-18 01:35:55 +00:00
Roger Dingledine
3cf02a88f4 rudimentary dns caching (of both resolves and resolve failures)
serious performance increase over non-caching


svn:r158
2003-02-14 07:53:55 +00:00
Roger Dingledine
0bc8dc1314 fix endian issues for topics -- they might work on bsd now
(they wouldn't have before)

alternate code which bypasses the dns farm, so we can compare speed


svn:r154
2003-02-06 23:48:35 +00:00
Roger Dingledine
ceafe12ed6 make reusing circuits work (and be the default)
performance is better, but not by much. not sure why yet.


svn:r153
2003-02-06 08:00:49 +00:00
Roger Dingledine
c35373a2cf major overhaul: dns slave subsystem, topics
on startup, it forks off a master dns handler, which forks off dns
slaves (like the apache model). slaves as spawned as load increases,
and then reused. excess slaves are not ever killed, currently.

implemented topics. each topic has a receive window in each direction
at each edge of the circuit, and sends sendme's at the data level, as
per before. each circuit also has receive windows in each direction at
each hop; an edge sends a circuit-level sendme as soon as enough data
cells have arrived (regardless of whether the data cells were flushed
to the exit conns). removed the 'connected' cell type, since it's now
a topic command within data cells.

at the edge of the circuit, there can be multiple connections associated
with a single circuit. you find them via the linked list conn->next_topic.

currently each new ap connection starts its own circuit, so we ought
to see comparable performance to what we had before. but that's only
because i haven't written the code to reattach to old circuits. please
try to break it as-is, and then i'll make it reuse the same circuit and
we'll try to break that.


svn:r152
2003-01-26 09:02:24 +00:00
Roger Dingledine
9d3e80a589 use a rbtree for replay detection, rather than linear search
when we had lots of new onions coming in, we were using 40% of
our time searching through the tracked_onions linked list.


svn:r150
2002-12-31 15:04:14 +00:00
Roger Dingledine
cbd2cdf04f onions go on and off the network correctly now
we're closer to an OS X port
 CVS: ----------------------------------------------------------------------


svn:r146
2002-12-03 22:18:23 +00:00
Roger Dingledine
8f18647a33 create cells are now queued and processed only when idle
we also queue data cells destined for a circuit that is
pending, and process them once the circuit opens

destroys reach into the queue and remove the pending onion,
along with its collected data cells


svn:r142
2002-11-27 04:08:20 +00:00
Roger Dingledine
b097aa3288 per-second cell statistics to help with profiling
svn:r140
2002-11-24 08:45:54 +00:00
Roger Dingledine
ab0aee04d9 added OnionsPerSecond to prevent create flooding
first cut, probably needs more playing with


svn:r137
2002-11-23 08:49:03 +00:00
Roger Dingledine
00a9e3732e remove popt dependency, consolidate config stuff
reformat parts of onion.c


svn:r136
2002-11-23 06:49:01 +00:00
Roger Dingledine
bf53852a00 cleanup and a variety of bugfixes
svn:r132
2002-10-02 22:54:20 +00:00
Nick Mathewson
bef3424bec Add convenience functions to wrap create and init for symmetric ciphers; clean up error handling in onion.c
svn:r131
2002-10-02 20:39:51 +00:00
Roger Dingledine
7032d16e78 cell now has a network appearance and an internal (struct) appearance
svn:r130
2002-10-02 20:12:44 +00:00
Roger Dingledine
7ed6c8bd39 introduced a periodic keepalive padding cell
now tor can be run safely inside nat'ed areas that kill idle
connections; and the proxy can handle when you suspend your laptop
and then emerge hours later from a new domain.


svn:r125
2002-10-01 23:37:31 +00:00
Roger Dingledine
827c7444f8 more robust http(ish) handling
svn:r123
2002-09-28 05:53:00 +00:00
Roger Dingledine
081e8969db catch hup to reload directory/router list
svn:r121
2002-09-28 01:40:11 +00:00
Roger Dingledine
22285e6ff1 cleanup
prkey is only fetched when it's needed
tor nodes who aren't dirservers now fetch directories and autoconnect
  to new nodes listed in the directory
default role is a non-dirserver node


svn:r120
2002-09-28 00:52:59 +00:00
Roger Dingledine
f033442be2 dirserver should include itself in the directory
if connecting to a dirserver fails, remove it from the router array


svn:r113
2002-09-26 13:17:14 +00:00
Roger Dingledine
01f6727306 directory servers in and functional
proxies now periodically pull down an hourly-updated directory,
and replace their router list with it if it parses correctly.


svn:r112
2002-09-26 12:09:10 +00:00