[tor-bugs] #2286 [Tor]: We still use self-published relay bandwidth sometimes

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Feb 19 14:13:49 UTC 2013


#2286: We still use self-published relay bandwidth sometimes
------------------------------------------------+---------------------------
 Reporter:  arma                                |          Owner:  andrea            
     Type:  enhancement                         |         Status:  needs_revision    
 Priority:  major                               |      Milestone:  Tor: 0.2.4.x-final
Component:  Tor                                 |        Version:                    
 Keywords:  arma-cares needs-proposal tor-auth  |         Parent:                    
   Points:                                      |   Actualpoints:                    
------------------------------------------------+---------------------------

Comment(by andrea):

 Possible bug found!  Hurrah for unit tests!

 When we do networkstatus_compute_consensus() with unmeasured bandwidth
 clipping, we emit a Bandwidth=<value> and optionally an "Unmeasured=1"
 flag to indicate we do not have a measured bandwidth.  See dirvote.c line
 2057.  However, when we parse the router status lines in the consensus in
 routerstatus_parse_entry_from_string(), we read the Bandwidth=<value> and
 the Measured=1 flags older consensus versions can emit, but not the
 Unmeasured=1 flag.  The has_measured_bw field of routerstatus_t does not
 survive a round trip through the parser.  I'm not sure this actually
 breaks anything (do the consumers of the consensus care?) but it was
 unexpected enough that I wrote my unit tests in a way that flunked it.
 Should we change this behavior or should I change my test?

-- 
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/2286#comment:61>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list