Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also .

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also .
base repository: DonnchaC/torspec
base: bc348154c63f46fc6cc56c49d339fcd0aab78f3d
head repository: DonnchaC/torspec
compare: 3523
  • 3 commits
  • 1 file changed
  • 0 comments
  • 1 contributor
Showing with 39 additions and 6 deletions.
  1. +39 −6 control-spec.txt
@@ -1229,6 +1229,36 @@

[DROPGUARDS was added in Tor 0.2.5.2-alpha.]

3.26. HSPOST

The syntax is:
"+HSPOST" *[SP "SERVER=" Server] CRLF Descriptor CRLF "." CRLF

Server = LongName
Descriptor = The text of the descriptor formatted as specified
in rend-spec.txt section 1.3.

This command launches a hidden service descriptor upload to the specified
HSDirs. If one or more Server arguments are provided, an upload is triggered
on each of them in parallel. If no Server options are provided, it behaves
like a normal HS descriptor upload and will upload to the set of responsible
HS directories.

If any value is unrecognized, a 552 error is returned and the command is
stopped. If there is an error in parsing the descriptor, the server
must send a "554 Invalid descriptor" reply.

On success, Tor replies "250 OK" then Tor MUST eventually follow
this with a HS_DESC event with the result for each upload location.

Examples are:
C: +HSPOST SERVER=9695DFC35FFEB861329B9F1AB04C46397020CE31
[DESCRIPTOR]
.
S: 250 OK

[HSPOST was added in Tor 0.2.7.1-alpha]

4. Replies

Reply codes follow the same 3-character format as used by SMTP, with the
@@ -2519,29 +2549,32 @@

The syntax is:

"650" SP "HS_DESC" SP Action SP HSAddress SP AuthType SP HsDir [SP DescriptorID]
[SP "REASON=" Reason]
"650" SP "HS_DESC" SP Action SP HSAddress SP AuthType SP HsDir
[SP DescriptorID] [SP "REASON=" Reason]

Action = "REQUESTED" / "RECEIVED" / "IGNORE" / "FAILED"
Action = "REQUESTED" / "UPLOAD" / "RECEIVED" / "UPLOADED" / "IGNORE" /
"FAILED"
HSAddress = 16*Base32Character
AuthType = "NO_AUTH" / "BASIC_AUTH" / "STEALTH_AUTH" / "UNKNOWN"
HsDir = LongName / Fingerprint
DescriptorID = 32*Base32Character
Reason = "BAD_DESC" / "QUERY_REJECTED" / "NOT_FOUND" / "UNEXPECTED"
Reason = "BAD_DESC" / "QUERY_REJECTED" / "UPLOAD_REJECTED" / "NOT_FOUND" /
"UNEXPECTED"

These events will be triggerred when required HiddenService descriptor is
not found in the cache and a fetch from network is performed.
not found in the cache and a fetch or upload with the network is performed.

If we already had the v0 descriptor, the newly fected v2 descriptor will be
ignored and a "HS_DESC" event with "IGNORE" action will be generated.

For HsDir, LongName is always prefered. If HsDir cannot be found in node
list at the time event is sent, Fingerprint will be used instead.

If Action is "FAILED", Tor SHOULD send Reason field as well. Possible
If Action is "FAILED", Tor SHOULD send Reason field as well. Possible
values of Reason are:
- "BAD_DESC" - descriptor was retrieved, but found to be unparsable.
- "QUERY_REJECTED" - query was rejected by HS directory.
- "UPLOAD_REJECTED" - descriptor was rejected by HS directory.
- "NOT_FOUND" - HS descriptor with given identifier was not found.
- "UNEXPECTED" - nature of failure is unknown.

No commit comments for this range