Opened 9 years ago

Closed 9 years ago

Last modified 7 years ago

#1899 closed defect (fixed)

We should launch a reachability test immediately if a router changes IP or port

Reported by: nickm Owned by: arma
Priority: Medium Milestone: Tor: 0.2.2.x-final
Component: Core Tor/Tor Version:
Severity: Keywords: easy tor-relay
Cc: Sebastian Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

When reviewing my patch for bug #911, Sebastian noted:

in dirserv_should_launch_reachability_test() shouldn't we test for difference in port or ip, and do the test immediately?

This is indeed so. We should do this once #911 is merged.

Marking for 0.2.2.x-final, since it's trivial.

Child Tickets

Change History (7)

comment:1 Changed 9 years ago by arma

Owner: set to arma
Status: newaccepted

triage: fine by me to include in 0.2.2.x if it's easy like we think.

comment:2 Changed 9 years ago by nickm

Status: acceptedneeds_review

The obvious implementation of this is in branch bug1899 in my public. That branch in turn depends on bug911, though, so we can't merge it till that one is reviewed.

comment:3 Changed 9 years ago by Sebastian

Looks good.

comment:4 Changed 9 years ago by arma

Looks good. My only suggestion is to note that the same logic happens in router_add_to_routerlist():

      if (router->addr == old_router->addr &&
          router->or_port == old_router->or_port) {
        /* these carry over when the address and orport are unchanged. */
        router->last_reachable = old_router->last_reachable;
        router->testing_since = old_router->testing_since;
      }

and it might be smart to make the logic a function called from each place.

comment:5 Changed 9 years ago by nickm

Resolution: fixed
Status: needs_reviewclosed

Plausible. Doing & merging.

comment:6 Changed 7 years ago by nickm

Keywords: tor-relay added

comment:7 Changed 7 years ago by nickm

Component: Tor RelayTor
Note: See TracTickets for help on using tickets.