[tor-bugs] #23414 [Core Tor/Tor]: rep_hist_format_hs_stats() should add noise, then round

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri Sep 15 07:40:56 UTC 2017

#23414: rep_hist_format_hs_stats() should add noise, then round
 Reporter:  teor                                 |          Owner:  teor
     Type:  defect                               |         Status:
                                                 |  needs_revision
 Priority:  Medium                               |      Milestone:  Tor:
                                                 |  0.3.2.x-final
Component:  Core Tor/Tor                         |        Version:  Tor:
 Severity:  Normal                               |     Resolution:
 Keywords:  tor-relay, security-low, privcount,  |  Actual Points:  1.0
  031-backport, 030-backport, 029-backport,      |
  028-backport                                   |
Parent ID:  #23061                               |         Points:  0.5
 Reviewer:                                       |        Sponsor:
Changes (by teor):

 * status:  needs_review => needs_revision


 Oops, the original tests were right: the only thing worse than a
 consistent bias is one that is inconsistent (it changes when the noised
 signal is negative).

 Good news is that round_int64_to_next_multiple_of() becomes a two-liner:
 const uint64_t bias = (uint64_t)INT64_MAX + 1;
 return round_uint64_to_next_multiple_of(number + bias, divisor) - bias;

 Bad news is that it's my weekend, so it will be Monday before I get to

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

More information about the tor-bugs mailing list