Skip to content

Commit

Permalink
Tor 0.1.2.5 is dead. Long live Tor 0.1.2.5.
Browse files Browse the repository at this point in the history
The spec cited several caveats that would no longer be relevant when 0.1.2.5
was obsolete. Clearing out this cruft.
  • Loading branch information
atagar committed Mar 18, 2012
1 parent 739d70b commit 4eb029b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 61 deletions.
38 changes: 9 additions & 29 deletions dir-spec-v2.txt
Original file line number Diff line number Diff line change
Expand Up @@ -113,17 +113,6 @@
require current clients to understand any KeywordLine not currently
described.

The "opt" keyword was used until Tor 0.1.2.5-alpha for non-critical future
extensions. All implementations MUST ignore any item of the form "opt
keyword ....." when they would not recognize "keyword ....."; and MUST
treat "opt keyword ....." as synonymous with "keyword ......" when keyword
is recognized.

Implementations before 0.1.2.5-alpha rejected any document with a
KeywordLine that started with a keyword that they didn't recognize.
Implementations MUST prefix items not recognized by older versions of Tor
with an "opt" until those versions of Tor are obsolete.

Other implementations that want to extend Tor's directory format MAY
introduce their own items. The keywords for extension items SHOULD start
with the characters "x-" or "X-", to guarantee that they will not conflict
Expand Down Expand Up @@ -162,6 +151,10 @@
"hibernating", "read-history", "write-history", "eventdns", "platform",
"family".

For historical reasons some options are prefixed with "opt ", for instance
"opt fingerprint". This "opt " prefix should be ignored with the second word
used as the keyword instead.

Additionally, a router descriptor MAY contain any number of "accept",
"reject", and "opt" Items. Other than "router" and "router-signature",
the items may appear in any order.
Expand Down Expand Up @@ -206,17 +199,11 @@
identity key. A descriptor is considered invalid (and MUST be
rejected) if the fingerprint line does not match the public key.

[We didn't start parsing this line until Tor 0.1.0.6-rc; it should
be marked with "opt" until earlier versions of Tor are obsolete.]

"hibernating" 0|1

If the value is 1, then the Tor server was hibernating when the
descriptor was published, and shouldn't be used to build circuits.

[We didn't start parsing this line until Tor 0.1.0.6-rc; it should be
marked with "opt" until earlier versions of Tor are obsolete.]

"uptime"

The number of seconds that this OR process has been running.
Expand Down Expand Up @@ -273,9 +260,6 @@
number of bytes used in the most recent intervals, ordered from
oldest to newest.

[We didn't start parsing these lines until Tor 0.1.0.6-rc; they should
be marked with "opt" until earlier versions of Tor are obsolete.]

"eventdns" bool NL

Declare whether this version of Tor is using the newer enhanced
Expand All @@ -286,10 +270,9 @@
this option set to 0 if it is not present. All Tor versions at
0.1.2.2-alpha or later should be assumed to have this option set to
1 if it is not present. Until 0.1.2.1-alpha-dev, this option was
not generated, even when eventdns was in use. Versions of Tor
before 0.1.2.1-alpha-dev did not parse this option, so it should be
marked "opt". With 0.2.0.1-alpha, the old 'dnsworker' logic has
been removed, rendering this option of historical interest only.]
not generated, even when eventdns was in use. With 0.2.0.1-alpha, the
old 'dnsworker' logic has been removed, rendering this option of
historical interest only.]

2.2. Nonterminals in router descriptors

Expand Down Expand Up @@ -414,9 +397,7 @@
The "r" entry for each router must appear first and is required. The
"s" entry is optional (see Section 3.1 below for how the flags are
decided). Unrecognized flags on the "s" line and extra elements
on the "r" line must be ignored. The "v" line is optional; it was not
supported until 0.1.2.5-alpha, and it must be preceded with an "opt"
until all earlier versions of Tor are obsolete.
on the "r" line must be ignored. The "v" line is optional.

The signature section contains:

Expand Down Expand Up @@ -882,8 +863,7 @@
apparent IP address of the client connecting to them (as a dotted quad).
For directory connections tunneled over a BEGIN_DIR stream, servers SHOULD
report the IP from which the circuit carrying the BEGIN_DIR stream reached
them. [Servers before version 0.1.2.5-alpha reported 127.0.0.1 for all
BEGIN_DIR-tunneled connections.]
them.

Servers SHOULD disable caching of multiple network statuses or multiple
router descriptors. Servers MAY enable caching of single descriptors,
Expand Down
35 changes: 3 additions & 32 deletions dir-spec.txt
Original file line number Diff line number Diff line change
Expand Up @@ -234,20 +234,6 @@
require current clients to understand any KeywordLine not currently
described.

The "opt" keyword was used until Tor 0.1.2.5-alpha for non-critical future
extensions. All implementations MUST ignore any item of the form "opt
keyword ....." when they would not recognize "keyword ....."; and MUST
treat "opt keyword ....." as synonymous with "keyword ......" when keyword
is recognized.

Implementations before 0.1.2.5-alpha rejected any document with a
KeywordLine that started with a keyword that they didn't recognize.
When generating documents that need to be read by older versions of Tor,
implementations MUST prefix items not recognized by older versions of
Tor with an "opt" until those versions of Tor are obsolete. [Note that
key certificates, status vote documents, extra info documents, and
status consensus documents will never be read by older versions of Tor.]

Other implementations that want to extend Tor's directory format MAY
introduce their own items. The keywords for extension items SHOULD start
with the characters "x-" or "X-", to guarantee that they will not conflict
Expand Down Expand Up @@ -540,10 +526,7 @@
Present only if this router is a directory cache that provides
extra-info documents.

[Versions before 0.2.0.1-alpha don't recognize this, and versions
before 0.1.2.5-alpha will reject descriptors containing it unless
it is prefixed with "opt"; it should be so prefixed until these
versions are obsolete.]
[Versions before 0.2.0.1-alpha don't recognize this]

"extra-info-digest" digest NL

Expand All @@ -554,10 +537,7 @@
(that is, not including the signature). (If this field is absent, the
router is not uploading a corresponding extra-info document.)

[Versions before 0.2.0.1-alpha don't recognize this, and versions
before 0.1.2.5-alpha will reject descriptors containing it unless
it is prefixed with "opt"; it should be so prefixed until these
versions are obsolete.]
[Versions before 0.2.0.1-alpha don't recognize this]

"hidden-service-dir" *(SP VersionNum) NL

Expand All @@ -568,10 +548,6 @@
supports those descriptor versions. If none are specified, it
defaults to version 2 descriptors.

[Versions of Tor before 0.1.2.5-alpha rejected router descriptors
with unrecognized items; the protocols line should be preceded with
an "opt" until these Tors are obsolete.]

"protocols" SP "Link" SP LINK-VERSION-LIST SP "Circuit" SP
CIRCUIT-VERSION-LIST NL

Expand All @@ -582,10 +558,6 @@
protocols are "Link 1 2 Circuit 1". See section 4.1 of tor-spec.txt
for more information about link protocol versions.

[Versions of Tor before 0.1.2.5-alpha rejected router descriptors
with unrecognized items; the protocols line should be preceded with
an "opt" until these Tors are obsolete.]

"allow-single-hop-exits" NL

[At most once.]
Expand Down Expand Up @@ -2396,8 +2368,7 @@
apparent IP address of the client connecting to them (as a dotted quad).
For directory connections tunneled over a BEGIN_DIR stream, servers SHOULD
report the IP from which the circuit carrying the BEGIN_DIR stream reached
them. [Servers before version 0.1.2.5-alpha reported 127.0.0.1 for all
BEGIN_DIR-tunneled connections.]
them.

Servers SHOULD disable caching of multiple network statuses or multiple
router descriptors. Servers MAY enable caching of single descriptors,
Expand Down

0 comments on commit 4eb029b

Please sign in to comment.