Roger Dingledine
5a6e117caf
React to eof immediately on non-open edge connections.
...
Stop keeping track of num_retries for apconns, since they expire
after 60 seconds anyway.
When warning about retrying or giving up, print the address, so
the user knows which one it's talking about.
svn:r3073
2004-12-04 03:26:35 +00:00
Roger Dingledine
c644886c38
bugfix: When we were checking to see if an ap_conn should time out
...
waiting for its connected cell, we were calculating time from when the
ap_conn was created. So if it waited say 20 seconds before being attached,
then we would immediately decide that the circuit had timed out.
Also, make circuit_dump_by_conn() display actual circuit progress,
including circuits that haven't been attached to the conn yet but
hope to when it finishes connecting.
svn:r3072
2004-12-04 02:51:11 +00:00
Nick Mathewson
fc87758ff3
Add function to check that addr_policy_t is okay; change struct addr_policy_t to addr_policy_t.
...
svn:r3070
2004-12-04 01:14:36 +00:00
Roger Dingledine
eb558d0a84
clean up the other "Tell Roger" log that dfc keeps getting
...
svn:r3042
2004-11-30 09:02:25 +00:00
Roger Dingledine
1d4af1930c
Let resolve conns retry/expire also, rather than sticking around forever.
...
Put the check-if-requested-exitrouter-will-reject-us code in the
circuit_attach loop, so it gets checked periodically and not just
once at the beginning. This is useful in case the routerlist changes,
but also in case the address gets resolved into something that we learn
we'll reject.
svn:r3039
2004-11-30 08:39:14 +00:00
Roger Dingledine
d383c23e73
refuse .exit addresses immediately if the requested node would
...
refuse the request (e.g. due to exit policy or wrong version)
svn:r3038
2004-11-30 08:15:09 +00:00
Nick Mathewson
a5d3325c5c
Fix last patch
...
svn:r3031
2004-11-30 06:12:21 +00:00
Nick Mathewson
c8abe1907d
Rename parse_address to parse_extended_hostname (since we have other kinds of addresses); make its output an enum; support HEXDIGEST.exit hostnames.
...
svn:r3029
2004-11-30 03:44:10 +00:00
Nick Mathewson
7fbd297532
Suggestion from weasel: Make tor --version --version dump the cvs Id of every file.
...
svn:r3019
2004-11-29 22:25:31 +00:00
Roger Dingledine
c1dc17e6e2
put in initial support for ".nickname.exit" addresses, to let alice
...
decide what exit node to use; based on a patch by geoff goodell.
needs more work: e.g. it goes bananas building new circuits when the
chosen exit node's exit policy rejects the connection.
svn:r3015
2004-11-29 08:34:54 +00:00
Roger Dingledine
22727b4edc
wrong is ok, and right is fine, but in between is apparently
...
totally unacceptable to me.
svn:r3005
2004-11-28 11:39:53 +00:00
Nick Mathewson
6f5dbefa7e
Normalize space: add one between every control keyword and control clause.
...
svn:r3003
2004-11-28 09:05:49 +00:00
Roger Dingledine
7c9a707900
remove emacs droppings, since nick says he doesn't need them anymore
...
svn:r2989
2004-11-26 04:00:55 +00:00
Roger Dingledine
7d55f3685e
make tor-resolve work, uh, more. this time for sure!
...
svn:r2974
2004-11-24 06:16:36 +00:00
Roger Dingledine
cca469ec58
make tor-resolve work again
...
svn:r2973
2004-11-24 06:01:52 +00:00
Roger Dingledine
0eebfe3558
bugfix: let socks do multiple rounds of negotiation again
...
(which is needed for socks5)
svn:r2970
2004-11-24 04:35:28 +00:00
Nick Mathewson
22dba27d8d
Normalize a few more kinds of whitespace. We now dislike:
...
- func (args)
- if (x){
This doesn't normalize if(x), for(x); while(x), and friends.
svn:r2943
2004-11-22 23:28:26 +00:00
Roger Dingledine
4f2c2c9948
The crowning bugfix.
...
The problem was that with high load, circuit package window was
reaching 0. Whenever we got a circuit-level sendme, we were
reading a lot on each socket, but only writing out a bit. So we
would eventually reach eof. This would be noticed and acted on
even when there are still bytes sitting in the inbuf.
svn:r2932
2004-11-21 11:30:33 +00:00
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
Roger Dingledine
a4b1eb5630
allow StrictEntryNode and StrictExitNode to be singular
...
svn:r2922
2004-11-20 23:16:03 +00:00
Roger Dingledine
67aa3b66c5
clean up socks handling, refuse connections to port 0
...
svn:r2888
2004-11-15 07:50:15 +00:00
Nick Mathewson
4f835673be
Remove redundant declaration
...
svn:r2855
2004-11-14 17:22:10 +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
Roger Dingledine
ab951fc828
remove extraneous variable
...
svn:r2765
2004-11-10 00:19:18 +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
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
Roger Dingledine
a4753283dd
better interface for connection_ap_handshake_socks_reply()
...
make --list-fingerprint print the fingerprint again
svn:r2668
2004-11-03 23:13:28 +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
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
2fbf31533b
Tricksy compiler warnings! We hates them, hates them forever, my precious!
...
svn:r2615
2004-10-27 21:14:11 +00:00
Nick Mathewson
6980929e64
Use strlcpy, not strcpy.
...
svn:r2610
2004-10-27 06:48:16 +00:00
Nick Mathewson
44d4516155
Use tor_snprintf, not snprintf
...
svn:r2609
2004-10-27 06:37:34 +00:00
Nick Mathewson
c7151d8bed
Add "pass" target for RedirectExit, to make it easier to break out of a sequence of rules
...
svn:r2566
2004-10-19 17:46:06 +00:00
Roger Dingledine
97a0a43511
start the process of making 0.0.7* obsolete
...
svn:r2565
2004-10-17 21:51:20 +00:00
Roger Dingledine
640544ae3e
use connection_edge_is_rendezvous_stream() more
...
svn:r2564
2004-10-17 21:10:41 +00:00
Roger Dingledine
695cdb10fe
whoops, resolve cells were probably broken
...
svn:r2562
2004-10-17 20:31:19 +00:00
Nick Mathewson
8d27385c23
Implement RedirectExit.
...
svn:r2550
2004-10-17 01:57:34 +00:00
Roger Dingledine
aebc3a03ba
more int to size_t conversions, fixing one or more amd64 bugs
...
plus a whitespace patch on config.c from vicman
svn:r2482
2004-10-14 02:47:09 +00:00
Nick Mathewson
0383afac9a
Use parse_addr_port() function instead of ad-hoc variants
...
svn:r2441
2004-10-12 15:52:09 +00:00
Roger Dingledine
6468e049be
when a begin cell has an invalid port, give us a better hint of
...
what went wrong
svn:r2435
2004-10-10 01:47:24 +00:00
Roger Dingledine
a2517b4f07
checking only 0.0.7 and 0.0.8 didn't work, because some dirservers
...
files have really old descriptors for the authdirservers, so we're
asking them in the new format because they're too old.
now we actually compare the version to a cutoff version, and act
appropriately.
also take this chance to use only >=0.0.8 servers for dns resolves,
because of the recent bugs. we'll bump to >=0.0.9pre1 once there are
some servers running that.
svn:r2380
2004-09-27 06:00:43 +00:00
Roger Dingledine
fa0a1ec49f
cleanup: use strcmpstart() in more places
...
svn:r2372
2004-09-23 22:18:50 +00:00
Nick Mathewson
9defe8a307
Attach dummy resolve connections to a circuit *before* calling dns_resolve(). This fixes a bug where cached answers would never be sent in RESOLVED cells.
...
svn:r2360
2004-09-21 18:12:12 +00:00
Roger Dingledine
488aa52f25
fix assert triggers in 0.0.7.x: if the other side returns
...
an address 0.0.0.0, don't put it into the client dns cache.
svn:r2233
2004-08-15 20:05:35 +00:00
Roger Dingledine
292e9c5567
reject the default edonkey, kazaa, gnutella ports
...
to slow the coming flood
svn:r2195
2004-08-08 05:26:13 +00:00
Roger Dingledine
f47fe829dd
avoid racing the mark-for-close when the client hangs up on us
...
at the same time we get an end relay cell.
(thanks to wmf for reminding me)
svn:r2181
2004-08-07 02:19:49 +00:00