aboutsummaryrefslogtreecommitdiff
path: root/proposals
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2022-02-24 10:54:05 -0500
committerNick Mathewson <nickm@torproject.org>2022-02-24 10:54:05 -0500
commit80e9d9e7dbbc3642a7e93946f48b5fa2fc568b3f (patch)
tree2453822026481fc22123373f6a96a26be82f1a9b /proposals
parent71c326ae934eee9f76b957f9097f5dba7fed8974 (diff)
parentfa940c0d9e30d52b168d0ee64bec08c0a88f4edb (diff)
downloadtorspec-80e9d9e7dbbc3642a7e93946f48b5fa2fc568b3f.tar.gz
torspec-80e9d9e7dbbc3642a7e93946f48b5fa2fc568b3f.zip
Merge remote-tracking branch 'tor-gitlab/mr/60'
Diffstat (limited to 'proposals')
-rw-r--r--proposals/332-ntor-v3-with-extra-data.md28
1 files changed, 19 insertions, 9 deletions
diff --git a/proposals/332-ntor-v3-with-extra-data.md b/proposals/332-ntor-v3-with-extra-data.md
index 4e55713..25ae0ba 100644
--- a/proposals/332-ntor-v3-with-extra-data.md
+++ b/proposals/332-ntor-v3-with-extra-data.md
@@ -338,20 +338,30 @@ We use the following meta-encoding for the contents of client and
server messages.
[Any number of times]:
- TYPE [one byte]
- LEN [one byte]
- BODY [LEN bytes]
+ EXTENSION
+ EXT_FIELD_TYPE [one byte]
+ EXT_FIELD_LEN [one byte]
+ EXT_FIELD [EXT_FIELD_LEN bytes]
-We do not specify specific TYPE semantics here; we leave those for
-other proposals.
+(`EXT_FIELD_LEN` may be zero, in which case EXT_FIELD is absent.)
All parties MUST reject messages that are not well-formed per the
rules above.
-To avoid partitioning, clients MUST reject messages with TYPEs that
-they do not recognize. (Therefore, whenever we specify a new server
-message TYPE, we must say that it can only be included if the client
-signals that it understands it.)
+We do not specify specific TYPE semantics here; we leave those for
+other proposals and specifications.
+
+Parties MUST ignore extensions with `EXT_FIELD_TYPE` bodies they do not
+recognize.
+
+Unless otherwise specified in the documentation for an extension type:
+* Each extension type SHOULD be sent only once in a message.
+* Parties MUST ignore any occurrences all occurrences of an extension
+ with a given type after the first such occurrence.
+* Extensions SHOULD be sent in numerically ascending order by type.
+
+(The above extension sorting and multiplicity rules are only defaults;
+they may be overridden in the description of individual extensions.)
# A.3 How much space is available?