aboutsummaryrefslogtreecommitdiff
path: root/src/or/connection.c
Commit message (Collapse)AuthorAge
...
* infrastructure for integrity-checks in relay cellsRoger Dingledine2003-12-16
| | | | | | | | make circuit_consider_sending_sendme use connection_edge_send_command fix endian bug in relay length handling (maybe) svn:r946
* start tracking the 'It appears I've already sent the end' warningRoger Dingledine2003-12-14
| | | | svn:r932
* on hup, close and rebind listener ports too (in case their config has changed)Roger Dingledine2003-12-14
| | | | svn:r926
* back out the broken change from yesterdayRoger Dingledine2003-12-09
| | | | svn:r891
* general cleanupsRoger Dingledine2003-12-07
| | | | svn:r889
* fix vicious bug in connection_ap_attach_pending that caused it toRoger Dingledine2003-12-03
| | | | | | | | | | | 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
* bugfix: we were writing to stderr even when it's closedRoger Dingledine2003-11-30
| | | | svn:r868
* remove a conn_close_if_marked warningRoger Dingledine2003-11-30
| | | | | | | | Nov 27 15:45:19.003 [warn] connection_write_to_buf(): write_to_buf failed. Closing connection (fd 42). Nov 27 15:45:19.010 [warn] conn_close_if_marked(): Conn (socket 42) still wants to flush. Losing 0 bytes! svn:r866
* bugfix: an offline OP would leak all its sockets and stop workingRoger Dingledine2003-11-29
| | | | svn:r865
* Bring assert_connection_ok up to dateNick Mathewson2003-11-23
| | | | svn:r863
* make more sure we can't end up with two connections to the same ORRoger Dingledine2003-11-18
| | | | | | | fix leaked pk in connection_tls_finish_handshake svn:r839
* use the tor_malloc_zero wrapperRoger Dingledine2003-11-18
| | | | svn:r837
* Rename aci to circ_id throughout.Nick Mathewson2003-11-11
| | | | svn:r784
* Make AP connections wait for a circuit if none exists.Nick Mathewson2003-11-11
| | | | | | | | | | | | | Also: - Refactor socks request into a separate struct - Add a separate 'waiting for circuit' state to AP connections between 'waiting for socks' and 'open'. Arma: can you check out the XXX's I've added to connection_edge? I may be mishandling some async and close logic. svn:r783
* client now survives going offline betterRoger Dingledine2003-11-10
| | | | | | | | | fix badness in usage() if neither socksport nor orrport is defined, quit obsolete connection_flush_buf() svn:r780
* add DirBindAddress, parse the BindAddress's when you bindRoger Dingledine2003-10-25
| | | | | | | | | exit if bind fails add usage printfs rearrange config options for readability svn:r674
* make end relay cells have payloadsRoger Dingledine2003-10-22
| | | | | | | move default exit policy into config files svn:r653
* move closer to being able to reload config on HUPRoger Dingledine2003-10-21
| | | | | | | | rename APPort to SocksPort introduce new tor_free() macro svn:r642
* send the end cell when we realize we're going to end,Roger Dingledine2003-10-21
| | | | | | | | | | | | | | | not when we're closing the stream. this lets us put a payload in the end cell if we want to, to describe why we're closing the stream. there are still some places where we don't send the end cell immediately. i need to track them down. but it's a low priority, since i've made it send the end cell when we close the stream if we haven't already sent it. svn:r640
* clean up logging, allow user to specify log filesRoger Dingledine2003-10-15
| | | | | | | | | | | | If DebugLogFile is specified, log to it at -l debug If LogFile is specified, log to it at the -l from the commandline (default info) If no LogFile *and* not a Daemon, then log to stdout. Make conn->s = -1 by default (this might break things) When kill -USR1, prefer to log at INFO, but make sure they always see it. svn:r596
* Stop using stdout for non-debugging casesNick Mathewson2003-10-15
| | | | svn:r592
* make the buffer resize stuff workRoger Dingledine2003-10-14
| | | | | | | and make listener connections not have bufs svn:r584
* change WARNING to WARNRoger Dingledine2003-10-10
| | | | | | | and fix a few typos svn:r571
* Refactor, rename, and clarifyNick Mathewson2003-10-09
| | | | svn:r569
* Update LICENSE and copyright dates.Nick Mathewson2003-10-08
| | | | svn:r560
* some early bugfixesRoger Dingledine2003-10-07
| | | | | | | | | | our log() conflicts with log(3) distribute only the correct files from doc/ and src/config/ sometimes laptops go back in time. i guess that's ok for now. and bump the version number because we're live. svn:r544
* wrap strdup; prefer time() to gettimeofday()Roger Dingledine2003-10-04
| | | | svn:r538
* refactor so connection_write_to_buf() never failsRoger Dingledine2003-10-04
| | | | svn:r537
* mark all dirservers up at boot; mark a dirserver down if dir fetch failsRoger Dingledine2003-09-30
| | | | svn:r519
* We need to call get_connection_array before using its outputsNick Mathewson2003-09-30
| | | | svn:r513
* move connection_array accessors from main.c to connection.cRoger Dingledine2003-09-30
| | | | | | | (leave poll_array accessors in main.c) svn:r512
* move the tls handshake stuff to connection_orRoger Dingledine2003-09-30
| | | | svn:r510
* getting closer to having dirserv workingRoger Dingledine2003-09-30
| | | | | | | | 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
* expand the scheduler to address SSL_read()'s pending bytesRoger Dingledine2003-09-28
| | | | svn:r505
* Write necessary backends for online directory generation. I think.Nick Mathewson2003-09-27
| | | | svn:r503
* clean up receiver buckets; prepare for payloads in relay_end; note a few bugsRoger Dingledine2003-09-27
| | | | svn:r502
* connection_new() can't ever failRoger Dingledine2003-09-27
| | | | svn:r497
* first pass: obey log conventionRoger Dingledine2003-09-26
| | | | | | | | | | | | | | | | | | | | | ERR is if something fatal just happened WARNING is something bad happened, but we're still running. The bad thing is either a bug in the code, an attack or buggy protocol/implementation of the remote peer, etc. The operator should examine the bad thing and try to correct it. (No error or warning messages should be expected. I expect most people to run on -l warning eventually.) NOTICE is never ever used. INFO means something happened (maybe bad, maybe ok), but there's nothing you need to (or can) do about it. DEBUG is for everything louder than INFO. svn:r486
* various bugfixes and updatesRoger Dingledine2003-09-25
| | | | | | | | | | | | | | | | | | | | redo all the config files for the new format (we'll redo them again soon) fix (another! yuck) segfault in log_fn when input is too large tor_tls_context_new() returns -1 for error, not NULL fix segfault in check_conn_marked() on conn's that die during tls handshake make ORs also initialize conn from router when we're the receiving node make non-dirserver ORs upload descriptor to every dirserver on startup add our local address to the descriptor add Content-Length field to POST command revert the Content-Length search in fetch_from_buf_http() to previous code fix segfault in memmove in fetch_from_buf_http() raise maximum allowed headers/body size in directory.c svn:r484
* Refactor buffers; implement descriptors.Nick Mathewson2003-09-25
| | | | | | | | | | | | | | | | | 'buf_t' is now an opaque type defined in buffers.c . Router descriptors now include all keys; routers generate keys as needed on startup (in a newly defined "data directory"), and generate their own descriptors. Descriptors are now self-signed. Implementation is not complete: descriptors are never published; and upon receiving a descriptor, the directory doesn't do anything with it. At least "routers.or" and orkeygen are now obsolete, BTW. svn:r483
* cleanups, bugfixes, more verbose logsRoger Dingledine2003-09-24
| | | | | | | | | | | | | | | | | | | Fixed up the assert_*_ok funcs some (more work remains) Changed config so it reads either /etc/torrc or the -f arg, never both Finally tracked down a nasty bug with our use of tls: It turns out that if you ask SSL_read() for no more than n bytes, it will read the entire record from the network (and maybe part of the next record, I'm not sure), give you n bytes of it, and keep the remaining bytes internally. This is fine, except our poll-for-read looks at the network, and there are no bytes pending on the network, so we never know to ask SSL_read() for more bytes. Currently I've hacked it so if we ask for n bytes and it returns n bytes, then it reads again right then. This will interact poorly with our rate limiting; we need a cleaner solution. svn:r481
* bugfixes and note missing featuresRoger Dingledine2003-09-21
| | | | | | | | | | | | | deal with content-length headers better when reading http don't assume struct socks4_info is a packed struct fail the socks handshake if destip is zero flesh out conn_state_to_string() for dir conn fix typo (bug) in connection_handle_read() directory get is now called fetch, post is now upload reopen logs on sighup svn:r475
* leave the socks handshake on the inbuf until it's completeRoger Dingledine2003-09-18
| | | | | | | | | | | this paves the way for supporting socks5 and other handshakes it also removes those pesky AP-only variables from connection_t also hacked a fix for a bug where some streams weren't ending properly -- maybe because marked connections weren't flushing properly? svn:r472
* add in directory 'post' supportRoger Dingledine2003-09-17
| | | | svn:r471
* phase out non-tls handshake, now that tls is stable.Roger Dingledine2003-09-16
| | | | svn:r470
* bugfixes and refactoringsRoger Dingledine2003-09-16
| | | | svn:r468
* Use EXIT properly in assert_connection_okNick Mathewson2003-09-16
| | | | svn:r465
* Add first cut of assert_*_ok functionsNick Mathewson2003-09-16
| | | | svn:r464
* clean up exported api'sRoger Dingledine2003-09-16
| | | | svn:r461
* refactor connects into connection_connect()Roger Dingledine2003-09-16
| | | | svn:r460