[tor-bugs] #3521 [Tor]: Allow controllers to retrieve HS descriptors from Tor

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri May 2 12:46:35 UTC 2014


#3521: Allow controllers to retrieve HS descriptors from Tor
-----------------------------+-----------------------------------
     Reporter:  rransom      |      Owner:  rransom
         Type:  enhancement  |     Status:  new
     Priority:  normal       |  Milestone:  Tor: 0.2.???
    Component:  Tor          |    Version:
   Resolution:               |   Keywords:  needs-proposal tor-hs
Actual Points:               |  Parent ID:  #8993
       Points:               |
-----------------------------+-----------------------------------

Comment (by wfn):

 Replying to [comment:6 asn]:

 > Me and hellais wrote a small patch for this issue. You can find it in
 branch `bug8891` in `https://git.torproject.org/user/asn/tor.git`.
 >
 > It's a bit of a PoC and it was done the easiest way possible: You send
 `GETINFO hs/desc/id/idnxcnkne4qt76tg` to the control port, and Tor will
 search its cache of hidden service descriptors and if it finds a
 descriptor for `idnxcnkne4qt76tg.onion` it spits it out.
 >
 > In the future we will also want a command that actually fetches the
 descriptor even if it's not cached.

 I've been tinkering with `or/control.c` to allow for [1]-type of
 descriptor fetching (cache, network). But, the "fetch descriptors from
 directories" logic is asynchronous in nature
 (`rend_client_refetch_v2_renddesc()` -> `directory_get_from_hs_dir()`
 which chooses the dirauth to query, etc., and which in turn calls
 `directory_initiate_command_routerstatus_rend()` -> `connection_connect()`
 -> send things, and then register via `connection_watch_events()`, and
 `connection_start_reading()`). Therefore, implementing a "try to remotely
 fetch an HS descriptor and return that exact descriptor" type of thing
 turned out not to be that easy. I suppose one could start from the bottom-
 up and not use things like `directory_get_from_hs_dir()`, but I'm not
 sure.

 This is just in case someone else is considering implementing the same
 thing. It would be useful for sure.

 [1]: https://lists.torproject.org/pipermail/tor-
 dev/2013-September/005366.html

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/3521#comment:14>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list