Roger Dingledine
3516ae1a26
add an ap_conn connecting state; report connecting delay
...
svn:r1011
2004-01-20 09:21:46 +00:00
Roger Dingledine
53061b3778
fix endian issue: rh.integrity was getting sent wrong
...
now it's a char[4] rather than an int
svn:r966
2004-01-02 09:03:38 +00:00
Roger Dingledine
8085235e5f
make loglevel info less noisy
...
svn:r961
2003-12-30 22:49:35 +00:00
Roger Dingledine
f3fdbadfdf
randomize the initial circ_id and stream_id, so an adversary who
...
breaks in part-way through can't learn how many circs/streams have
been made
svn:r960
2003-12-28 04:46:09 +00:00
Roger Dingledine
71739b486a
back out the insert-padding-if-conflict code
...
use recognized + digest instead, just assume it's enough bits
svn:r959
2003-12-26 06:29:57 +00:00
Roger Dingledine
43fcb70bad
checkpoint: revamp relay cell packaging and handling
...
include the infrastructure for inserting padding cells when there's
a relay-recognized conflict, but it does not work currently.
svn:r958
2003-12-23 07:45:31 +00:00
Roger Dingledine
a5e6ec244f
rename circ_id_t to uint16_t for code clarity
...
change message when using non-recommended tor version
svn:r954
2003-12-19 19:55:02 +00:00
Roger Dingledine
45a66c6955
make a relay_header_t struct and pack/unpack funcs
...
split 7-byte stream_id string into 2-byte recognized and 2-byte stream_id
fix two seg faults in fetch_from_buf_http
fix several lurking seg faults in handling unexpected relay cells
still need to
* clean up relay_crypt
* use relay dummies if there's going to be a conflict with rh.recognized
* check for a conflict when generating stream_ids
svn:r953
2003-12-19 05:09:51 +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
Roger Dingledine
aba237e3e2
end-to-end integrity checking now works
...
initialize digests from shared secrets at handshake
make circuit_send_next_onion_skin use connection_edge_send_command
svn:r948
2003-12-17 05:58:30 +00:00
Roger Dingledine
21cc01299b
infrastructure for integrity-checks in relay cells
...
make circuit_consider_sending_sendme use connection_edge_send_command
fix endian bug in relay length handling (maybe)
svn:r946
2003-12-16 22:56:50 +00:00
Roger Dingledine
4e50f79b11
resolve an edge case in get_unique_circ_id_by_conn
...
svn:r944
2003-12-16 20:45:10 +00:00
Roger Dingledine
8712a30e91
move cell size to 512 bytes
...
move length to 2 bytes, put it in the relay header
remove 4 reserved bytes in cell
add 4 bytes to relay header for the integrity check
svn:r942
2003-12-16 09:48:17 +00:00
Roger Dingledine
961ecf7abf
add H(K|1) to the onionskin reply
...
verify it at the client end
abstract the onionskin handshake lengths
breaks backward compatibility (again)
svn:r941
2003-12-16 08:21:58 +00:00
Nick Mathewson
4885e90490
Make compile warning-free on cygwin
...
svn:r936
2003-12-15 21:35:52 +00:00
Roger Dingledine
08534a6271
start tracking the 'It appears I've already sent the end' warning
...
svn:r932
2003-12-14 08:32:14 +00:00
Roger Dingledine
05c05d6444
more friendly warning when there are too many dns workers
...
svn:r919
2003-12-14 04:19:12 +00:00
Roger Dingledine
7a3a3ae1df
bugfix: a circuit that immediately failed still counts as a failed circuit
...
svn:r905
2003-12-13 07:42:18 +00:00
Roger Dingledine
9c66e2bf9a
if >=2 circs are being built that handle a given stream,
...
no need to have new circs handle it too.
svn:r896
2003-12-12 23:03:25 +00:00
Roger Dingledine
38ce03d0e7
close the circuit when we get a truncated cell
...
svn:r893
2003-12-09 02:06:58 +00:00
Roger Dingledine
d172fdd300
fix vicious bug in connection_ap_attach_pending that caused it to
...
never work.
fix vicious bug in choose_good_exit_server that caused it to *skip over*
pending circuits, and look only at *non-pending circuits*, when choosing
a good exit node for the new circuit.
bugfix: remove incorrect asserts in circuit_get_newest()
svn:r876
2003-12-03 09:50:02 +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
f5994416c4
bugfix and cleanups
...
svn:r848
2003-11-19 13:12:43 +00:00
Nick Mathewson
fd07872a72
Separate failure-count tracking from circuit-launching.
...
Increment failure counts only when circuits close without having been built.
Reset failure counts only on the second, and when circuits are done building.
svn:r847
2003-11-19 02:22:52 +00:00
Roger Dingledine
25ac8857f3
bugfix: sometimes we closed a circ while cpuworker was cranking,
...
and it didn't notice
svn:r841
2003-11-18 21:12:17 +00:00
Roger Dingledine
f0cccc567e
bugfix: don't ask for ->next of an expired circuit
...
bugfix: keep going when a circ fails in circuit_n_conn_open
(make circuit_enumerate_by_naddr_nport obsolete)
bugfix: make circuit_n_conn_open only look at circ's that start at us
bugfix: only try circuit_n_conn_open if we're an OP. Otherwise we
expect connections to always already be up.
bugfix: when choosing path length, pay attention to whether the directory
says a router is down.
bugfix: when picking good exit, skip routers which are known to be down
(more work needs to be done on this one)
svn:r838
2003-11-18 09:53:03 +00:00
Roger Dingledine
ac56486bf6
use the tor_malloc_zero wrapper
...
svn:r837
2003-11-18 08:20:19 +00:00
Roger Dingledine
a3e39b0ceb
don't build too many circs at once
...
expire circs that have been building for too long
svn:r835
2003-11-18 07:48:00 +00:00
Nick Mathewson
4eabb8450e
Fix possible bug in circID selection when building circuits on combination OP/OR servers
...
svn:r830
2003-11-17 18:40:56 +00:00
Roger Dingledine
7a702d64d4
more verbose info for circuits when kill -USR1
...
svn:r829
2003-11-17 09:30:29 +00:00
Roger Dingledine
a18ced652b
finally find and possibly fix the circuit_deliver_relay_cell warn bug
...
svn:r827
2003-11-17 07:43:03 +00:00
Roger Dingledine
42b5ed754f
catch the last missing log line i hope
...
svn:r825
2003-11-17 07:29:43 +00:00
Nick Mathewson
90e143e6d4
Remove a possible source of error in circID picking.
...
svn:r824
2003-11-17 07:24:01 +00:00
Roger Dingledine
e5d6e7db1a
continue the circuit_deliver_relay_cell forward-failure bughunt
...
svn:r823
2003-11-17 07:20:51 +00:00
Roger Dingledine
851b0933f5
trivial bugfixes
...
svn:r821
2003-11-17 01:23:15 +00:00
Roger Dingledine
4aede010b9
recognize in-progress circs and don't start redundant ones
...
quickly notice streams that don't have a circ on the way, and start one
svn:r819
2003-11-17 00:57:56 +00:00
Roger Dingledine
6d0e611fde
change when circuits are built and expired
...
not quite happy with it yet
svn:r817
2003-11-16 21:49:52 +00:00
Roger Dingledine
f5089681f7
bugfix: if you recognize a relay cell, don't also pass it on.
...
svn:r816
2003-11-16 17:31:19 +00:00
Roger Dingledine
fe856406be
initial patches on patches
...
svn:r814
2003-11-16 17:00:02 +00:00
Nick Mathewson
a8eaa79e03
Improved exit policy syntax; basic client-side DNS caching.
...
- Exit policies now support bitmasks (18.0.0.0/255.0.0.0) and bitcounts
18.0.0.0/8. Policies are parsed on startup, not when comparing to them.
- desired_path_len is now part of an opaque cpath_build_state_t structure.
- END_REASON_EXITPOLICY cells no longer include a port.
- RELAY_COMMAND_CONNECTED cells now include the IP address we've connected
to.
- connection_edge now has a client_dns cache to remember resolved addresses.
It gets populated by RELAY_COMMAND_CONNECTED cells and END_REASON_EXITPOLICY
cells. It gets used by connection_ap_handshake_send_begin. We don't
compare it to exit policies yet.
svn:r812
2003-11-14 20:45:47 +00:00
Roger Dingledine
273da1d3c4
commencing the bughunt
...
svn:r811
2003-11-14 07:15:52 +00:00
Roger Dingledine
f5829aa723
lay groundwork for EntryNodes and ExitNodes
...
svn:r805
2003-11-12 19:34:34 +00:00
Nick Mathewson
99a6d48f62
Restore erroneously removed assert
...
svn:r796
2003-11-12 03:48:33 +00:00
Nick Mathewson
e0ad4d08be
Fix thinko: Failure and success are different things.
...
svn:r795
2003-11-12 03:01:38 +00:00
Nick Mathewson
2e05b9ccf9
Remove dead code
...
svn:r794
2003-11-12 02:58:45 +00:00
Nick Mathewson
7d441ec6b4
Compute paths as we build them.
...
svn:r793
2003-11-12 02:55:38 +00:00
Nick Mathewson
e6296a4e2f
Refactor onion_generate_cpath to build cpaths one hop at a time. This
...
is a the first step in computing hops one step at a time. Next, we move
the responsibility for calling onion_extend_cpath into circuit.c
(Later, we may want to special-case onion_extend_cpath to treat entry
and exit routers differently.)
svn:r792
2003-11-12 02:32:20 +00:00
Roger Dingledine
9c8a54a39f
more cleanups and bugfix
...
svn:r790
2003-11-11 17:21:35 +00:00
Nick Mathewson
7bde42676b
Rename aci to circ_id throughout.
...
svn:r784
2003-11-11 03:01:48 +00:00