aboutsummaryrefslogtreecommitdiff
path: root/src/or/command.c
Commit message (Expand)AuthorAge
* Rename router_get_by_digest()•••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. Sebastian Hahn2010-10-14
* Implement a few more node-based functions•••Some of these functions only work for routerinfo-based nodes, and as such are only usable for advisory purposes. Fortunately, our uses of them are compatible with this limitation. Nick Mathewson2010-10-01
* Initial conversion to use node_t throughout our codebase.•••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. Nick Mathewson2010-10-01
* Try to make most routerinfo_t interfaces constNick Mathewson2010-10-01
* Fix some issues in rate-limiting noticed by SebastianNick Mathewson2010-08-31
* Add a generic rate-limited log mechanism, and use it in a few places•••Incidentally fixes bug 1042. Nick Mathewson2010-08-18
* Create relay.hSebastian Hahn2010-07-27
* Create onion.hSebastian Hahn2010-07-27
* Create hibernate.hSebastian Hahn2010-07-27
* Create cpuworker.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 circuitlist.hSebastian Hahn2010-07-27
* Create circuitbuild.hSebastian Hahn2010-07-27
* Create routerlist.hSebastian Hahn2010-07-27
* Create router.hSebastian Hahn2010-07-27
* Merge remote branch 'origin/maint-0.2.1'•••Conflicts: src/common/test.h src/or/test.c Nick Mathewson2010-02-27
|\
| * Update Tor Project copyright yearsNick Mathewson2010-02-27
* | Refactor the safe_str_*() API to make more sense.•••The new rule is: safe_str_X() means "this string is a piece of X information; make it safe to log." safe_str() on its own means "this string is a piece of who-knows-what; make it safe to log". Nick Mathewson2009-12-15
* | Allow SafeLogging to exclude client related informationSebastian Hahn2009-12-12
* | clean up the XXX comments around bug 1038Roger Dingledine2009-10-26
|/
* Fix compile warnings on Snow Leopard•••Big thanks to nickm and arma for helping me with this! Sebastian Hahn2009-09-01
* Only send netinfo clock_skew to controller if an authority told us so•••We were triggering a CLOCK_SKEW controller status event whenever we connect via the v2 connection protocol to any relay that has a wrong clock. Instead, we should only inform the controller when it's a trusted authority that claims our clock is wrong. Bugfix on 0.2.0.20-rc; starts to fix bug 1074. Reported by SwissTorExit. Roger Dingledine2009-08-28
* three hacks to workaround bug 1038•••The problem is that clients and hidden services are receiving relay_early cells, and they tear down the circuit. Hack #1 is for rendezvous points to rewrite relay_early cells to relay cells. That way there are never any incoming relay_early cells. Hack #2 is for clients and hidden services to never send a relay_early cell on an established rendezvous circuit. That works around rendezvous points that haven't upgraded yet. Hack #3 is for clients and hidden services to not tear down the circuit when they receive an inbound relay_early cell. We already refuse extend cells at clients. Roger Dingledine2009-07-27
* Update copyright to 2009.Karsten Loesing2009-05-04
* actually find the right identity_digest to blame when we get•••a destroy cell from our first hop. svn:r17991 Roger Dingledine2009-01-07
* clarify which relay gave us the good netinfo cell•••svn:r17973 Roger Dingledine2009-01-06
* Remove svn $Id$s from our source, and remove tor --version --version.•••The subversion $Id$ fields made every commit force a rebuild of whatever file got committed. They were not actually useful for telling the version of Tor files in the wild. svn:r17867 Nick Mathewson2009-01-04
* Document most undocumented variables.•••svn:r17754 Nick Mathewson2008-12-23
* Add DOCDOC entries for undocumented static and global variables.•••svn:r17739 Nick Mathewson2008-12-22
* fix typo noticed by wood•••svn:r17726 Roger Dingledine2008-12-22
* Downlgrade tweak, and answer lots of XXX021s. No actual code fixes in this p...•••svn:r17686 Nick Mathewson2008-12-18
* Use ctags and a python script to find identifiers that are never used anywher...•••svn:r17651 Nick Mathewson2008-12-17
* r17641@31-33-44: nickm | 2008-08-05 16:07:53 -0400••• Initial conversion of uint32_t addr to tor_addr_t addr in connection_t and related types. Most of the Tor wire formats using these new types are in, but the code to generate and use it is not. This is a big patch. Let me know what it breaks for you. svn:r16435 Nick Mathewson2008-08-05
* r17323@aud-055: nickm | 2008-07-23 17:58:25 +0200••• Implement most of proposal 110. svn:r16156 Nick Mathewson2008-07-23
* r17302@aud-055: nickm | 2008-07-23 14:55:28 +0200••• Never allow a circuit to be created with the same circid as a circuit that has been marked for close. May be a fix for bug 779. Needs testing. Backport candidate. svn:r16136 Nick Mathewson2008-07-23
* r15269@tombo: nickm | 2008-04-22 12:23:30 -0400••• Fix bug 663: warn less verbosely about clock skew from netinfo cells svn:r14408 Nick Mathewson2008-04-22
* r14388@tombo: nickm | 2008-02-21 22:44:28 -0500••• More 64-to-32 fixes. svn:r13672 Nick Mathewson2008-02-22
* r18296@catbus: nickm | 2008-02-20 23:30:11 -0500••• Answer one xxx020 item; move 7 other ones to a new "XXX020rc" category: they should get fixed before we cut a release candidate. arma: please review these to see whether you have fixes/answers for any. Please check out the other 14 XXX020s to see if any look critical for the release candidate. svn:r13640 Nick Mathewson2008-02-21
* r14182@tombo: nickm | 2008-02-15 17:20:51 -0500••• Defer, downgrade, or address more XXX020s. The remaining ones are all ones we should deal with before release. svn:r13530 Nick Mathewson2008-02-15
* r18068@catbus: nickm | 2008-02-13 11:33:19 -0500••• Patch from karsten: make hidden service code respect SafeLogging. svn:r13493 Nick Mathewson2008-02-13
* r18051@catbus: nickm | 2008-02-12 15:20:43 -0500••• Re-tune mempool parametes based on testing on peacetime: use smaller chuncks, free them a little more aggressively, and try very hard to concentrate allocations on fuller chunks. Also, lots of new documentation. svn:r13484 Nick Mathewson2008-02-12
* r18041@catbus: nickm | 2008-02-11 23:43:18 -0500••• Make version negotiation and handshaking messages more useful and accurate. svn:r13477 Nick Mathewson2008-02-12
* r18029@catbus: nickm | 2008-02-11 12:36:39 -0500••• Fix command.c compilation with gcc 4.2 warnings enabled. svn:r13475 Nick Mathewson2008-02-12
* r14108@tombo: nickm | 2008-02-10 20:09:10 -0500••• add some documentation svn:r13462 Nick Mathewson2008-02-11
* r14103@tombo: nickm | 2008-02-10 13:40:09 -0500••• Fix some XXX020s in command.c, and make it not-allowed to negotiate v1 using the v2 connection protocol: it is too hard to test, and pointless to support. svn:r13460 Nick Mathewson2008-02-10
* r14101@tombo: nickm | 2008-02-10 13:24:27 -0500••• Merge connection_or_act_on_netinfo into command.c; remove some fields from or_handshake_state(). svn:r13458 Nick Mathewson2008-02-10