aboutsummaryrefslogtreecommitdiff
path: root/src/or/connection_or.c
Commit message (Collapse)AuthorAge
* Rename router_get_by_digest()Sebastian Hahn2010-10-14
| | | | | We now call the function router_get_by_id_digest() to make clear that we're talking about the identity digest here, not descriptor digest.
* Merge branch 'nodes'Nick Mathewson2010-10-13
|\
| * Initial conversion to use node_t throughout our codebase.Nick Mathewson2010-10-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A node_t is an abstraction over routerstatus_t, routerinfo_t, and microdesc_t. It should try to present a consistent interface to all of them. There should be a node_t for a server whenever there is * A routerinfo_t for it in the routerlist * A routerstatus_t in the current_consensus. (note that a microdesc_t alone isn't enough to make a node_t exist, since microdescriptors aren't usable on their own.) There are three ways to get a node_t right now: looking it up by ID, looking it up by nickname, and iterating over the whole list of microdescriptors. All (or nearly all) functions that are supposed to return "a router" -- especially those used in building connections and circuits -- should return a node_t, not a routerinfo_t or a routerstatus_t. A node_t should hold all the *mutable* flags about a node. This patch moves the is_foo flags from routerinfo_t into node_t. The flags in routerstatus_t remain, but they get set from the consensus and should not change. Some other highlights of this patch are: * Looking up routerinfo and routerstatus by nickname is now unified and based on the "look up a node by nickname" function. This tries to look only at the values from current consensus, and not get confused by the routerinfo_t->is_named flag, which could get set for other weird reasons. This changes the behavior of how authorities (when acting as clients) deal with nodes that have been listed by nickname. * I tried not to artificially increase the size of the diff here by moving functions around. As a result, some functions that now operate on nodes are now in the wrong file -- they should get moved to nodelist.c once this refactoring settles down. This moving should happen as part of a patch that moves functions AND NOTHING ELSE. * Some old code is now left around inside #if 0/1 blocks, and should get removed once I've verified that I don't want it sitting around to see how we used to do things. There are still some unimplemented functions: these are flagged with "UNIMPLEMENTED_NODELIST()." I'll work on filling in the implementation here, piece by piece. I wish this patch could have been smaller, but there did not seem to be any piece of it that was independent from the rest. Moving flags forces many functions that once returned routerinfo_t * to return node_t *, which forces their friends to change, and so on.
| * Try to make most routerinfo_t interfaces constNick Mathewson2010-10-01
| |
* | Remember to re-install inbuf/outbuf callbacks on ssl buffereventsNick Mathewson2010-10-12
| | | | | | | | | | If we don't, we will (among other bad things) never update lastread/lastwritten, and so flood the network with keepalives.
* | Actually call connection_tls_finish_handshake() with buffereventsNick Mathewson2010-10-12
| | | | | | | | | | | | First start of a fix for bug2001, but my test network still isn't working: the client and the server send each other VERSIONS cells, but never notice that they got them.
* | Log OpenSSL errors coming from bufferevent_opensslNick Mathewson2010-10-11
|/
* Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2010-09-29
|\
| * improve code comments, based on comments from nickRoger Dingledine2010-09-28
| |
| * handle ugly edge case in retrying entrynodesRoger Dingledine2010-09-28
| | | | | | | | | | | | | | | | Specifically, a circ attempt that we'd launched while the network was down could timeout after we've marked our entrynodes up, marking them back down again. The fix is to annotate as bad the OR conns that were around before we did the retry, so if a circuit that's attached to them times out we don't do anything about it.
* | Make the bufferevent code use the renegotiation-reenabling hackNick Mathewson2010-09-27
| |
* | note that libevent does not have an an easy way to reset buckets atmNick Mathewson2010-09-27
| |
* | Convert bufferevents to use rate-limiting.Nick Mathewson2010-09-27
| | | | | | | | | | | | | | | | | | | | | | This requires the latest Git version of Libevent as of 24 March 2010. In the future, we'll just say it requires Libevent 2.0.5-alpha or later. Since Libevent doesn't yet support hierarchical rate limit groups, there isn't yet support for tracking relayed-bytes separately when using the bufferevent system. If a future version does add support for hierarchical buckets, we can add that back in.
* | Get SSL connections and linked connections working with bufferevents.Nick Mathewson2010-09-27
| | | | | | | | | | Clients are now verified to work and build circuits correctly. There are still a few warnings given here and there that I need to look into.
* | Fix more remaining users of inbuf/outbuf to handle bufferevents instead.Nick Mathewson2010-09-27
| |
* | Move the "stop writing when the buffer is empty" logic to ↵Nick Mathewson2010-09-27
| | | | | | | | cnnection_finished_flushing
* | Refactor users of buf_datalen to bufferevent-friendly version.Nick Mathewson2010-09-27
|/
* A start at a patch for bug 1943 (alignment issues)Roger Dingledine2010-09-20
|
* perconnbwrate and perconnbwburst consensus paramsRoger Dingledine2010-09-16
|
* Merge branch 'bug1184'Nick Mathewson2010-09-15
|\
| * Clear cell queues when marking or truncating a circuit.Nick Mathewson2010-07-30
| | | | | | | | | | | | | | | | | | At best, this patch helps us avoid sending queued relayed cells that would get ignored during the time between when a destroy cell is sent and when the circuit is finally freed. At worst, it lets us release some memory a little earlier than it would otherwise. Fix for bug #1184. Bugfix on 0.2.0.1-alpha.
* | Add a simple integer-ceiling-division macro before we get it wrongNick Mathewson2010-09-14
| |
* | reinit per-conn token buckets on config or consensus changeRoger Dingledine2010-08-15
| |
* | factor out rate/burst setting. no actual changes.Roger Dingledine2010-08-15
|/
* Create rephist.hSebastian Hahn2010-07-27
|
* Create relay.hSebastian Hahn2010-07-27
|
* Create reasons.hSebastian Hahn2010-07-27
|
* Create networkstatus.hSebastian Hahn2010-07-27
|
* Create main.hSebastian Hahn2010-07-27
|
* Create dirserv.hSebastian Hahn2010-07-27
|
* Create control.hSebastian Hahn2010-07-27
|
* Create connection_or.hSebastian Hahn2010-07-27
|
* Create connection.hSebastian Hahn2010-07-27
|
* Create config.hSebastian Hahn2010-07-27
|
* Create command.hSebastian Hahn2010-07-27
|
* Create circuitbuild.hSebastian Hahn2010-07-27
|
* Create buffers.hSebastian Hahn2010-07-27
|
* Create routerlist.hSebastian Hahn2010-07-27
|
* Create router.hSebastian Hahn2010-07-27
|
* Create geoip.hSebastian Hahn2010-07-27
|
* Let bridge users use the non-primary address of a multi-homed bridgeRoger Dingledine2010-06-03
|
* Clarify 'marking connection as too old' messagesNick Mathewson2010-05-12
| | | | | | | | | | Back when we changed the idea of a connection being "too old" for new circuits into the connection being "bad" for new circuits, we didn't actually change the info messages. This led to telling the user that we were labelling connections as "too old" for being worse than connections that were actually older than them. Found by Scott on or-talk.
* let people test the RefuseUnknownExits ideaRoger Dingledine2010-03-10
|
* Merge remote branch 'origin/maint-0.2.1'Nick Mathewson2010-02-27
|\ | | | | | | | | | | Conflicts: src/common/test.h src/or/test.c
| * Update Tor Project copyright yearsNick Mathewson2010-02-27
| |
* | add config options to override.Roger Dingledine2009-12-29
| | | | | | | | somebody should add man page entries.
* | add separate per-conn write limitingRoger Dingledine2009-12-29
| |
* | New consensus params "bwconnrate" and "bwconnburst"Roger Dingledine2009-12-23
| | | | | | | | | | | | | | ...to let us rate-limit client connections as they enter the network. It's controlled in the consensus so we can turn it on and off for experiments. It's starting out off. Based on proposal 163.
* | Remove duplicate words and a duplicate newline.Karsten Loesing2009-12-18
| |
* | Make changes to latest bridge-stats fixes as suggested by Nick.Karsten Loesing2009-12-17
| |