Roger Dingledine
cc3c4245cb
let the circuit-launcher choose the exit node (if he wants)
...
svn:r1428
2004-04-01 03:44:49 +00:00
Roger Dingledine
d01497cf3c
outline what bob does to initialize his hidden services
...
let circuit_launch_new return the circ it just made
svn:r1424
2004-04-01 03:23:28 +00:00
Roger Dingledine
36ff23209b
let alice recognize a y.onion address and, uhm, do something
...
svn:r1422
2004-04-01 02:41:41 +00:00
Roger Dingledine
d13857a3f0
put in hooks for alice and bob logic when circuits finish/fail
...
let you specify the purpose of circuits you launch
bugfix: we used to be declaring the first successful circuit too early -- when the first hop finished. now we're more accurate.
svn:r1421
2004-04-01 01:57:22 +00:00
Nick Mathewson
6d8be5e6f6
Add relay command types for rendezvous
...
svn:r1419
2004-04-01 01:11:28 +00:00
Roger Dingledine
ee45ae575d
allow conns to demand to be attached to a clean circuit
...
(nobody uses this yet)
svn:r1417
2004-03-31 23:06:16 +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
bf83b1e345
Add code to configure hidden services, parse configuration, generate keys and service IDs, and store/load them from disk
...
svn:r1410
2004-03-31 21:35:23 +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
Nick Mathewson
6ea61d5e0d
Parse and generate service descriptors
...
svn:r1403
2004-03-31 02:07:38 +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
Nick Mathewson
0ba9ab5fb0
Add rendezvous-related metadata and code to circuits. Initially, we
...
thought that a complicated adjunct structure would be necessary, but
it doesn't look that way anymore.
Of course, I might have forgotten something.
svn:r1396
2004-03-30 19:52:42 +00:00
Roger Dingledine
9723061dd9
first guess at a set of circuit purposes
...
svn:r1370
2004-03-29 22:14:19 +00:00
Nick Mathewson
0e6084d751
Remove descriptors that are older than 24 hours from the directory. Use strlcat instead of strncat to generate directories.
...
svn:r1361
2004-03-29 19:28:16 +00:00
Roger Dingledine
f241fdfc73
there is yet another dns-pending-conn-clobbering bug
...
somewhere
svn:r1354
2004-03-28 04:54:36 +00:00
Roger Dingledine
56dfc3151f
work around a tsocks bug
...
when an AP connection dies early, be sure to do a socks reject
for it. if you just hang up, tsocks goes into an infinite loop.
svn:r1352
2004-03-27 05:45:52 +00:00
Nick Mathewson
b7c2b18bd6
Add a RunTesting option to try to learn link state by creating test circuits, even when SocksPort is off.
...
svn:r1327
2004-03-21 03:03:10 +00:00
Nick Mathewson
2ba2f02181
Integrate the new "rephist" [rep(utation) hist(ory)] module to trace
...
successful/failed connections, successful/failed extends, and
connection uptimes.
It's still not done: more tests are needed, and not everything calls
connection/circuit_mark_for_close properly. This skews the results.
Also, there needs to be a 'testing' mode for non-OP ORs, where they
periodically build circuits just to test whether extends work.
svn:r1313
2004-03-20 04:59:29 +00:00
Nick Mathewson
da9d5ccfda
Add initial history-tracking backend code for reputation module. Not called or tested yet.
...
svn:r1310
2004-03-20 01:48:05 +00:00
Roger Dingledine
74ef3a63ae
bugfix: decrement OR connections from global_bucket too
...
bugfix: don't return immediately for has_pending_tls_data unless
the conn is allowed to read
svn:r1270
2004-03-14 17:06:29 +00:00
Roger Dingledine
703b2d3cf8
refactor bandwidth-control token buckets
...
this is a checkpoint commit; there still remain some
bugs, er, somewhere.
svn:r1269
2004-03-14 16:00:52 +00:00
Nick Mathewson
9b4203266e
Make OP work on windows! (Also misc logging tweaks)
...
svn:r1258
2004-03-11 06:19:08 +00:00
Nick Mathewson
59e2c77824
Get entropy in windows.
...
svn:r1257
2004-03-11 05:14:06 +00:00
Nick Mathewson
2da54de968
Make tor build on windows again. More work still needed
...
svn:r1247
2004-03-09 22:01:17 +00:00
Roger Dingledine
0ab367ed91
re-try streams at most 4 times
...
svn:r1242
2004-03-07 23:50:15 +00:00
Nick Mathewson
1e5b7bc6f1
New, more flexible directory parsing backend. Uses a bit more RAM, but implements the new spec. Uses more RAM, but not so you would notice.
...
svn:r1235
2004-03-05 05:48:28 +00:00
Nick Mathewson
b7633e2e67
Try to find out early if buffers get trashed or double-freed.
...
svn:r1225
2004-03-03 22:49:15 +00:00
Nick Mathewson
f4e4dac801
Implement hold_open_until_flushed. I may have missed something important.
...
svn:r1209
2004-03-03 05:08:01 +00:00
Roger Dingledine
8275e2302c
make socks5 not give a spurious warning
...
also rename AP_CONN_STATE_CONNECTING to _CONNECT_WAIT
svn:r1208
2004-03-03 04:54:16 +00:00
Roger Dingledine
de146de0c5
make circuit-building less noisy when a node in your exclude/exit/entrynodes is down
...
svn:r1206
2004-03-03 03:02:06 +00:00
Nick Mathewson
6f3c6d1289
Split out mark_for_close with circuits. Seems to work for me.
...
svn:r1197
2004-03-02 17:48:17 +00:00
Nick Mathewson
a1e4c6dc85
Fix assertion failure spotted by arma.
...
Apparently, when a DNS failure was already cached, then when we tried
to mark the exit connection as closed, we'd try to remove it from the
pending queue anyway, and hit an assert. Now, we put failed-resolve
connections in a separate state so that mark_for_close does the right
thing.
svn:r1196
2004-03-02 07:24:11 +00:00
Roger Dingledine
195ee8c845
create a separate connection_edge_destroy() function
...
svn:r1176
2004-02-29 00:11:37 +00:00
Roger Dingledine
62d3df8633
bugfix: when we time out on a stream and detach, send an end first
...
svn:r1175
2004-02-28 23:56:50 +00:00
Nick Mathewson
0a673f4491
Split dns_cancel_pending_resolve into dns_cancel_pending_resolve (kill a
...
resolve in response to a DNS worker dying) and connection_dns_remove (remove
a pending connection from the resolve structure.)
svn:r1168
2004-02-28 22:23:44 +00:00
Nick Mathewson
f039eca658
Stop trying to flush on broken sockets marked for close.
...
svn:r1163
2004-02-28 19:14:11 +00:00
Roger Dingledine
b354ecfecd
rename ExcludedNodes config option to ExcludeNodes
...
svn:r1155
2004-02-28 05:09:37 +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
Nick Mathewson
c5bbb571d2
Refactor mark_for_close, connection_edge_end and friends. Now, everybody
...
who wants to shut down a connection calls connection_mark_for_close instead
of setting marked_for_close to 1. This automatically removes the connection
from the DNS cache if needed, sends a RELAY END cell if appropriate, and can
be changed to do whatever else is needed.
Still to do:
- The same for circuits, maybe.
- Add some kind of hold_connection_open_until_flushed flag, maybe.
- Change stuff that closes connections with return -1 to use mark_for_close,
maybe.
svn:r1145
2004-02-27 22:00:26 +00:00
Roger Dingledine
195dfd35a8
Fix a bug where you might flush some data on a tls connection, and then
...
add some more data to be flushed but never turn POLLOUT on. not sure
how commonly this bug was hit, but it would be a doozy.
Also add some asserts to see if it happens elsewhere.
svn:r1142
2004-02-27 04:42:14 +00:00
Roger Dingledine
d3e9afda27
When it can't resolve any dirservers, it was useless from then on.
...
Now it reloads the RouterFile (or default dirservers) if it has no
dirservers.
svn:r1130
2004-02-26 22:56:36 +00:00
Roger Dingledine
8f2b429a3b
when they use tor as an http proxy, give them an http 501 failure
...
svn:r1126
2004-02-26 22:02:22 +00:00
Roger Dingledine
0b27ae0c2d
if the default torrc isn't there, just use some default defaults
...
plus provide an internal dirservers file if they don't have one
having no config files will make it easier to run on windows
svn:r1124
2004-02-26 21:25:51 +00:00
Nick Mathewson
496e414e52
Basic RAM poisoning and magic-checking to notice connection and circuit
...
corruption faster; also, check for corruption in dns.c so we can fail fast
for the bug that's nailing Lucky and moria3.
svn:r1123
2004-02-25 07:31:46 +00:00
Nick Mathewson
67a273962a
On OSX, decline to use the built-in select-baed poll wrapper, since it seems to sometimes not work.
...
svn:r1114
2004-02-20 23:41:45 +00:00
Roger Dingledine
67c0c64aa4
go back to a single exitpolicy parameter
...
if your exitpolicy includes " *:*" then it is final,
else we append the default exit policy.
(thanks weasel)
svn:r1105
2004-02-18 07:23:38 +00:00
Roger Dingledine
7562a62ef0
Get rid of the notion of a separate default default exit policy.
...
Create ExitPolicyPrepend config parameter, to customize the default
exit policy.
svn:r1103
2004-02-18 03:56:12 +00:00
Roger Dingledine
3456adec31
adding the reattach-after-timeout feature wasn't so easy after all.
...
maybe it works now.
svn:r1101
2004-02-18 01:21:20 +00:00