[tor-bugs] #5849 [Tor Relay]: Negative cell-processed-cells values

Tor Bug Tracker & Wiki torproject-admin at torproject.org
Mon May 14 12:38:04 UTC 2012


#5849: Negative cell-processed-cells values
-----------------------+----------------------------------------------------
 Reporter:  atagar     |          Owner:              
     Type:  defect     |         Status:  needs_review
 Priority:  minor      |      Milestone:              
Component:  Tor Relay  |        Version:              
 Keywords:             |         Parent:              
   Points:             |   Actualpoints:              
-----------------------+----------------------------------------------------
Changes (by karsten):

  * status:  new => needs_review


Comment:

 The problem is an integer overflow.  Here are the entries from two cell-
 processed-cells lines published by 24B1F63F:

 2012-05-09 08:34:31, 6839 84 32 14 7 5 3 1 1 1
 2012-05-10 08:34:31, -5923 73 26 11 6 4 2 1 1 1

 In order to calculate the 6839 in the first line, the relay summed up
 cells processed for the loudest 308806 circuits, that is, 2111924234
 (close to INT32_MAX), and then divided by those 308806 to come up with the
 mean number of 6839 cells per circuit.  When calculating the -5923 in the
 second line, the sum didn't fit into an integer, because there were 356842
 circuits per decile.

 See branch task-5849 in my public repo which is based on maint-0.2.2.
 Note that the patch is untested.

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


More information about the tor-bugs mailing list