diff options
author | Nick Mathewson <nickm@torproject.org> | 2023-10-14 18:52:20 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2023-10-14 18:53:18 -0400 |
commit | 3457b0720834c8347d8318c1080ebc9486d77300 (patch) | |
tree | b486a3d03fdfae7d98c4e6cf510179cf907c443f /spec/dos-spec.md | |
parent | a331e9f48790ad4beaba1ee443c5ad8b13d3afb4 (diff) | |
download | torspec-3457b0720834c8347d8318c1080ebc9486d77300.tar.gz torspec-3457b0720834c8347d8318c1080ebc9486d77300.zip |
Add short IDs for most long section names
I've left off sections that are headings for their whole document.
Diffstat (limited to 'spec/dos-spec.md')
-rw-r--r-- | spec/dos-spec.md | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/dos-spec.md b/spec/dos-spec.md index d0b8e89..d37649f 100644 --- a/spec/dos-spec.md +++ b/spec/dos-spec.md @@ -3,7 +3,7 @@ This document is incomplete; it describes some mechanisms that Tor uses to avoid different kinds of denial-of-service attacks. -## Handling low-memory conditions +## Handling low-memory conditions { #oom } (See also `tor-spec.txt`, section 8.1.) @@ -22,7 +22,7 @@ With this in mind, any Tor implementation—especially one that runs as a relay or onion service—must take steps to prevent memory-based denial-of-service attacks. -### Detecting low memory +### Detecting low memory { #oom-detection } The easiest way to notice you're out of memory would, in theory, be getting an error when you try to allocate more. Unfortunately, some @@ -52,7 +52,7 @@ kinds of allocation: Note that directory caches aren't counted, since those are stored on disk and accessed via mmap. -### Responding to low memory +### Responding to low memory { #oom-response } If our allocations exceed MaxMemInQueues, then we take the following steps to reduce our memory allocation. @@ -87,7 +87,7 @@ rule, according to the age of their oldest queued data. Upon freeing a circuit, a "DESTROY cell" must be sent in both directions. -### Reporting low memory +### Reporting low memory { #oom-reporting } We define a "low threshold" equal to 3/4 of MaxMemInQueues. Every time our memory usage is above the low threshold, we record |