aboutsummaryrefslogtreecommitdiff
path: root/src/or/dirserv.c
Commit message (Collapse)AuthorAge
...
| | * | Routers count as down when they change ORPort, tooSebastian Hahn2011-02-08
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | rransom noticed that a change of ORPort is just as bad as a change of IP address from a client's perspective, because both mean that the relay is not available to them while the new information hasn't propagated. Change the bug1035 fix accordingly. Also make sure we don't log a bridge's IP address (which might happen when we are the bridge authority).
| | * | Treat routers whose IPs have changed as having been down for MTBF/routerinfoNick Mathewson2010-11-22
| | | | | | | | | | | | | | | | calculation purposes.
* | | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2011-03-06
|\| | | | | | | | | | | | | | | | | | | Conflicts: src/or/routerparse.c
| * | | Merge remote branch 'origin/maint-0.2.1' into maint-0.2.2Nick Mathewson2011-03-06
| |\ \ \ | | | |/ | | |/|
| | * | Do not serve encrypt-only descriptors with the "all" request. Reported by ↵Nick Mathewson2011-03-04
| | | | | | | | | | | | | | | | piebeer
* | | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2011-01-03
|\| | |
| * | | Merge remote branch 'origin/maint-0.2.1' into maint-0.2.2Nick Mathewson2011-01-03
| |\| | | | | | | | | | | | | | | | | | | | | | Conflicts: src/common/test.h src/or/test.c
| | * | Bump copyright statements to 2011Nick Mathewson2011-01-03
| | | |
* | | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2010-12-07
|\| | |
| * | | Merge branch 'bug2081_followup_022' into maint-0.2.2Nick Mathewson2010-12-07
| |\ \ \
| | * | | Reject relay versions older than 0.2.0.26-rcNick Mathewson2010-12-07
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was the first version to cache the correct directory information. Fixes bug 2156.
| | * | | Have authorities reject routers running verions susceptible to bug 1038.Nick Mathewson2010-11-22
| | | |/ | | |/|
* | | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2010-12-06
|\| | |
| * | | Add a missing ! to directory_fetches_from_authoritiesNick Mathewson2010-12-06
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | The old logic would have us fetch from authorities if we were refusing unknown exits and our exit policy was reject*. Instead, we want to fetch from authorities if we're refusing unknown exits and our exit policy is _NOT_ reject*. Fixed by boboper. Fixes more of 2097. Bugfix on 0.2.2.16-alpha.
* | | Merge remote branch 'sjmurdoch/cloexec'Nick Mathewson2010-12-01
|\ \ \
| * | | Do cloexec on socketpairs and stdio filesNick Mathewson2010-11-20
| | | |
* | | | fix memory leak introduced in 26e89742Roger Dingledine2010-11-30
|/ / / | | | | | | | | | found via valgrind
* | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2010-10-21
|\| | | | | | | | | | | | | | Conflicts: src/common/tortls.c
| * | Merge branch 'bug988-nm' into maint-0.2.2Nick Mathewson2010-10-21
| |\ \
| | * | Maintain separate server and client identity keys when appropriate.Robert Ransom2010-10-04
| | | | | | | | | | | | | | | | Fixes a bug described in ticket #988.
* | | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2010-10-20
|\| | | | | | | | | | | | | | | | | | | Conflicts: src/or/networkstatus.c
| * | | Add a ! to directory_caches_dir_info() to fix a logic errorNick Mathewson2010-10-20
| |/ / | | | | | | | | | | | | | | | We want to fetch directory info more aggressively if we need it to refuseunknownexits. Thus, we'll want it if our exit policy is _NOT_ reject *.
* | | Merge branch 'bug1992_part1'Nick Mathewson2010-10-15
|\ \ \
| * | | refactor all these tor_inet_ntoa idiomsRoger Dingledine2010-10-01
| | | | | | | | | | | | | | | | but don't refactor the ones that look messy
* | | | 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
|\ \ \ \
| * | | | Rename routerstatus_t.is_running to is_flagged_runningNick Mathewson2010-10-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This was the only flag in routerstatus_t that we would previously change in a routerstatus_t in a consensus. We no longer have reason to do so -- and probably never did -- as you can now confirm more easily than you could have done by grepping for is_running before this patch. The name change is to emphasize that the routerstatus_t is_running flag is only there to tell you whether the consensus says it's running, not whether it *you* think it's running.
| * | | | 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 routerstatus_t interfaces constNick Mathewson2010-10-01
| | | | |
| * | | | Try to make most routerinfo_t interfaces constNick Mathewson2010-10-01
| |/ / /
* / / / Fix a crash bug when serving microdescs on a bufferevent.Nick Mathewson2010-10-07
|/ / /
* | | Code to download, parse, and store microdesc consensusesNick Mathewson2010-09-27
| | |
* | | Merge remote branch 'origin/maint-0.2.2'Nick Mathewson2010-09-27
|\| | | | | | | | | | | | | | Conflicts: src/or/config.c
| * | Change bug1751 enabling code based on comments from armaNick Mathewson2010-09-27
| | |
| * | First cut of code to enable RefuseUnknownExitsNick Mathewson2010-09-21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The RefuseUnknownExits config option is now a tristate, with "1" meaning "enable it no matter what the consensus says", "0" meaning "disable it no matter what the consensus says", and "auto" meaning "do what the consensus says". If the consensus is silent, we enable RefuseUnknownExits. This patch also changes the dirserv logic so that refuseunknownexits won't make us cache unless we're an exit.
* | | Refactor users of buf_datalen to bufferevent-friendly version.Nick Mathewson2010-09-27
|/ /
* | Merge branch 'bug1899'Nick Mathewson2010-09-14
|\ \
| * | Extract the "do these routers have the same addr:orport" logic into a fnNick Mathewson2010-09-14
| | |
| * | Launch reachability tests for routers whose IP or ORPort changeNick Mathewson2010-09-03
| | | | | | | | | | | | Implements #1899, suggested by Sebastian. Depends on #911 fix.
* | | Tweak some issues found by arma in bug911 review.Nick Mathewson2010-09-14
|/ /
* | Move code for launching tests out of router_add_to_routerlist()Nick Mathewson2010-08-18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | router_add_to_routerlist() is supposed to be a nice minimal function that only touches the routerlist structures, but it included a call to dirserv_single_reachability_test(). We have a function that gets called _after_ adding descriptors successfully: routerlist_descriptors_added. This patch moves the responsibility for testing there. Because the decision of whether to test or not depends on whether there was an old routerinfo for this router or not, we have to first detect whether we _will_ want to run the tests if the router is added. We make this the job of routers_update_status_from_consensus_networkstatus(). Finally, this patch makes the code notice if a router is going from hibernating to non-hibernating, and if so causes a reachability test to get launched.
* | Allow some skew in checking when a router said it was hibernatingNick Mathewson2010-08-18
| | | | | | | | | | | | | | | | This solves the problem Roger noted as: What if the router has a clock that's 5 minutes off, so it publishes a descriptor for 5 minutes in the future, and we test it three minutes in. In this edge case, we will continue to advertise it as Running for the full 45 minute period.
* | Clarify AssumeReachable semantics wrt hibernationNick Mathewson2010-08-18
| |
* | Add some braces to make arma happyNick Mathewson2010-08-18
| |
* | If a router is hibernating, never vote that it is Running.Nick Mathewson2010-07-31
| | | | | | | | | | Also, clean up and comment some of the logic in dirserv_set_router_is_running.
* | Create routerparse.hSebastian Hahn2010-07-27
| |
* | Create rephist.hSebastian Hahn2010-07-27
| |
* | Create policies.hSebastian Hahn2010-07-27
| |
* | Create networkstatus.hSebastian Hahn2010-07-27
| |
* | Create microdesc.hSebastian Hahn2010-07-27
| |