relay: Implement a circuit cell queue maximum size

This commit introduces the consensus parameter "circ_max_cell_queue_size"
which controls the maximum number of cells a circuit queue should have.

The default value is currently 50000 cells which is above what should be
expected but keeps us a margin of error for padding cells.

Related to this is #9072. Back in 0.2.4.14-alpha, we've removed that limit due
to a Guard discovery attack. Ticket #25226 details why we are putting back the
limit due to the memory pressure issue on relays.

Fixes #25226

Signed-off-by: David Goulet <dgoulet@torproject.org>
This commit is contained in:
David Goulet
2018-03-20 15:27:58 -04:00
parent 3d5bf12ac2
commit d064122e70
4 changed files with 70 additions and 0 deletions
+4
View File
@@ -0,0 +1,4 @@
o Major bugfixes (relay, denial of service):
- Impose a limit on circuit cell queue size. The limit can be controlled by
a consensus parameter. Fixes bug 25226; bugfix on 0.2.4.14-alpha.