151-path-selection-improvements.txt 2.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. Filename: 151-path-selection-improvements.txt
  2. Title: Improving Tor Path Selection
  3. Version:
  4. Last-Modified:
  5. Author: Fallon Chen, Mike Perry
  6. Created: 5-Jul-2008
  7. Status: Draft
  8. Overview
  9. The performance of paths selected can be improved by adjusting the
  10. CircuitBuildTimeout and the number of guards. This proposal describes
  11. a method of tracking buildtime statistics, and using those statistics
  12. to adjust the CircuitBuildTimeout and the number of guards.
  13. Motivation
  14. Tor's performance can be improved by excluding those circuits that
  15. have long buildtimes (and by extension, high latency). For those Tor
  16. users who require better performance and have lower requirements for
  17. anonymity, this would be a very useful option to have.
  18. Implementation
  19. Learning the CircuitBuildTimeout
  20. Based on studies of build times, we found that the distribution of
  21. circuit buildtimes appears to be a Pareto distribution. The number
  22. of circuits to observe (ncircuits_to_observe) before changing the
  23. CircuitBuildTimeout will be tunable. From our preliminary
  24. measurements, it is likely that ncircuits_to_observe will be
  25. somewhere on the order of 1000. The values can be represented
  26. compactly in Tor in milliseconds as a circular array of 16 bit
  27. integers. More compact long-term storage representations can be
  28. implemented by simply storing a histogram with 50 millisecond
  29. buckets when writing out the statistics to disk.
  30. Calculating the preferred CircuitBuildTimeout
  31. Circuits that have longer buildtimes than some x% of the estimated
  32. CDF of the Pareto distribution will be excluded. x will be tunable
  33. as well.
  34. Circuit timeouts
  35. In the event of a timeout, backoff values should include the 100-x%
  36. of expected CDF of timeouts. Also, in the event of network failure,
  37. the observation mechanism should stop collecting timeout data.
  38. Other notes
  39. Since this follows a Pareto distribution, large reductions on the
  40. timeout can be achieved without cutting off a great number of the
  41. total paths. However, hard statistics on which cutoff percentage
  42. gives optimal performance have not yet been gathered.
  43. Issues
  44. Impact on anonymity