Commit Graph

86 Commits

Author SHA1 Message Date
Roger Dingledine
c5bef32d95 call directory_has_arrived has arrived every time we get
a new directory, not just the first time


svn:r1581
2004-04-09 19:30:38 +00:00
Nick Mathewson
2a01e3ad10 Launch intro services after launching connections; allow ORs to build circuits through as-yet-unconnectd ORs
svn:r1562
2004-04-08 03:53:39 +00:00
Roger Dingledine
9d38311ae3 allow for directories >8192 bytes
svn:r1545
2004-04-08 01:47:33 +00:00
Roger Dingledine
e79a578fec if the rend desc cache entry was fetched more than 15 mins ago,
then try to fetch a new one. but if the new fetch fails, use the
old one.


svn:r1540
2004-04-07 22:41:00 +00:00
Nick Mathewson
b07b2cef29 Remember when we received which service desc.
svn:r1536
2004-04-07 22:00:54 +00:00
Nick Mathewson
3d60cd1d61 Delete trailing whitespace and expand tabs; remove unused aes decrypt code
svn:r1522
2004-04-07 19:57:40 +00:00
Roger Dingledine
7eaa655b6d publish and fetch the right rendezvous urls
svn:r1463
2004-04-03 03:33:57 +00:00
Roger Dingledine
8c19d6e3d7 alice can intercept y.onion requests, do a lookup on them via tor,
and receive a 404


svn:r1455
2004-04-03 01:59:53 +00:00
Roger Dingledine
a8d805e292 break out circ->rend_service
(this breaks the compile; must fix things)

let alice react when she learns a new rendezvous descriptor

let alice launch intro and rend circuits and mark them with her query


svn:r1446
2004-04-02 23:38:26 +00:00
Roger Dingledine
f34e6da3e7 now circuit_get_newest returns an appropriate circ for your purpose
connection_ap_handshake_attach_circuit attaches to a circ of the
right purpose

add a skeletal rendclient.c


svn:r1441
2004-04-02 22:23:15 +00:00
Roger Dingledine
64cb3a027f teach directory servers to handle renddesc responses
svn:r1434
2004-04-01 21:32:01 +00:00
Roger Dingledine
a0b0d16981 Add an ap_bridge function to do a socketpair and skip socks.
This allows us to do a directory connection *through* tor just
as if we're doing it as an application.

Make ap_conns tolerate it when the application sends stuff before
The socks handshake is done (it just buffers it).

Tell directory_initiate_command the length of the payload (because
it might include nuls).

Add a directory_has_arrived function to, for example, start building
the rendezvous service descriptor.


svn:r1412
2004-03-31 22:02:13 +00:00
Nick Mathewson
157cd7fe15 Fix warning
svn:r1409
2004-03-31 20:58:35 +00:00
Roger Dingledine
b4a61d1ab1 better way: always nul-terminate. then sometimes use it, sometimes not.
svn:r1408
2004-03-31 05:10:34 +00:00
Roger Dingledine
87dbd36a3c let fetch_from_buf_http tolerate nuls in the http body
teach directory.c about which places it needs to nul-terminate
body before it uses it, and which places it must not


svn:r1407
2004-03-31 05:01:30 +00:00
Nick Mathewson
8fedefe6cb rename hidserv_xx
svn:r1406
2004-03-31 04:10:10 +00:00
Nick Mathewson
b32440a028 Implement hidserv_XX functions; there is still an XXX in directory_handle_command
svn:r1404
2004-03-31 03:42:56 +00:00
Roger Dingledine
670aeb6c8d add and use stubs for hidserv lookup and store
svn:r1402
2004-03-30 23:41:24 +00:00
Roger Dingledine
2d3ac08633 Refactor directory servers
* read all the time (before we would ignore eof sometimes, oops)
* we can handle different urls now
* send back 404 for an un-handled url
* commands initiated by the client can handle payloads now
* introduce conn->purpose to avoid exponential state-space explosion


svn:r1400
2004-03-30 22:57:49 +00:00
Roger Dingledine
83c88c55fd old or skewed descriptor doesn't mean we failed to parse it
svn:r1373
2004-03-29 23:23:01 +00:00
Roger Dingledine
ce08baba1b refactor directories a smidgen
svn:r1371
2004-03-29 22:18:05 +00:00
Roger Dingledine
32e268c61b oops, 0.0.4 is more broken than 0.0.3
maybe this will fix it


svn:r1347
2004-03-26 23:37:13 +00:00
Roger Dingledine
9c69f14a49 fix two assert triggers (darn it, I hate releasing software)
when connecting to a dirserver or OR and the network is down,
we would crash.


svn:r1340
2004-03-26 22:07:45 +00:00
Nick Mathewson
f608b85ddf Replace all connection_removes outsice of main.c with connection_mark_for_close
svn:r1328
2004-03-21 03:18:45 +00:00
Roger Dingledine
c195f69058 isspace and friends take an int. solaris cares.
svn:r1303
2004-03-19 20:50:12 +00:00
Roger Dingledine
6af8d0606f inform unapproved servers when we reject their descriptors
svn:r1263
2004-03-12 12:43:13 +00:00
Roger Dingledine
c362ed877d if the directory client hangs up before getting the directory,
then give up on him


svn:r1238
2004-03-06 05:09:33 +00:00
Roger Dingledine
4716d4d871 bugfix: only warn about an unrouter router after we've fetched a directory
svn:r1178
2004-02-29 01:31:33 +00:00
Nick Mathewson
b4a7883c90 make code more readable; arrbitrarily change a -1 to a 0.
svn:r1151
2004-02-28 04:34:27 +00:00
Nick Mathewson
4e89c6661a Push responsibility for connection marking down as far as possible; have only a close path; add some missing end cells; change return conventions a little.
svn:r1149
2004-02-28 04:11:53 +00:00
Roger Dingledine
f00dc6fe1e last minute fix: don't early-flush non-tls streams
e.g., this breaks directory service


svn:r1033
2004-01-31 00:36:00 +00:00
Roger Dingledine
6a19e64066 remove trailing whitespace
svn:r951
2003-12-17 21:09:31 +00:00
Roger Dingledine
5ecd6b6bad make fetch_from_buf_http malloc its strings rather
than use fixed-size strings

reorganize directory_handle_command so it'll be easier to do more with
our directory servers


svn:r950
2003-12-17 09:42:28 +00:00
Nick Mathewson
7c439c30d0 Resolve format warnings on MacOS X 10.3
svn:r938
2003-12-16 05:33:11 +00:00
Roger Dingledine
50e17d633b clean up some file-scope-global directory variables
svn:r925
2003-12-14 05:25:23 +00:00
Roger Dingledine
8222fe8e4f clean up some copyrights
svn:r907
2003-12-13 22:53:17 +00:00
Roger Dingledine
e0952d0773 terminology shift:
directory is the string that dirserv.c and directory.c deal with
routerlist is routerinfo's that are bundled together in routers.c

rename some of the get_routerlist functions to set_routerlist

preparing to break into router.c for stuff the router does,
and routerlist.c for handling routerlist.


svn:r886
2003-12-05 09:51:49 +00:00
Roger Dingledine
2de4fc2b7f bump up header length when the dirserv reads http commands
Nov 23 12:10:26.556 [warn] fetch_from_buf_http(): headerlen 1487 larger than 1023. Failing.
Nov 23 12:10:26.556 [warn] directory_handle_command(): input too large. Failing.


svn:r867
2003-11-30 09:47:57 +00:00
Roger Dingledine
975bb68010 simplify: options.OnionRouter==1 iff options.ORPort>0
svn:r857
2003-11-20 17:49:45 +00:00
Roger Dingledine
9c8a54a39f more cleanups and bugfix
svn:r790
2003-11-11 17:21:35 +00:00
Roger Dingledine
1969c8a92f client now survives going offline better
fix badness in usage()
if neither socksport nor orrport is defined, quit
obsolete connection_flush_buf()


svn:r780
2003-11-10 08:06:55 +00:00
Roger Dingledine
737760f071 fix segfault (connecting to dirserver when network is down)
svn:r580
2003-10-13 19:58:21 +00:00
Roger Dingledine
b9628f266f change WARNING to WARN
and fix a few typos


svn:r571
2003-10-10 01:48:32 +00:00
Nick Mathewson
36939303c9 Update LICENSE and copyright dates.
svn:r560
2003-10-08 02:04:08 +00:00
Roger Dingledine
be874358a4 wrap strdup; prefer time() to gettimeofday()
svn:r538
2003-10-04 03:29:09 +00:00
Roger Dingledine
f563bbd2f9 refactor so connection_write_to_buf() never fails
svn:r537
2003-10-04 02:38:18 +00:00
Roger Dingledine
5c8fc2f705 mark all dirservers up at boot; mark a dirserver down if dir fetch fails
svn:r519
2003-09-30 21:27:16 +00:00
Roger Dingledine
4533da06c9 getting closer to having dirserv working
we now add our own descriptor to the descriptor list
and we rebuild the directory (and dump to disk) after receiving a POST


svn:r509
2003-09-30 08:18:10 +00:00
Roger Dingledine
3ed7aedc11 bugfixes and features: closer to making dirserv work
fix a variety of seg faults
don't try to list OPs in running-routers
write cached-directory to disk when rebuilding the dir
on boot, dirservers load approved-routers file
on boot, dirservers load cached directory file


svn:r508
2003-09-29 23:14:49 +00:00
Roger Dingledine
467d278b8b more cleanup and rearranging
still not finished integrating new dirserv stuff


svn:r507
2003-09-29 07:50:08 +00:00