6

Tor support AES for symmetric cryptography which is fine but for asymmetric cryptography we might prefer something else (I guess now its RSA1024 which is almost broken and proposals are saying to replace it with ECC in the future).

Main question:

  • Let say Alice have Bob's public key (a better cipher than RSA) so Alice don't need onion address to find Bob's public key first. Is it possible that Bob just advertise his descriptor (introduction points) on HSdirs with this custom cipher and meet Alice or hidden services are limited to what Tor support today?

Detailed questions:

  • How actually a descriptor look like (encoding) ? is there any format or size limit for descriptor on HSdir?
  • Where descriptors are hosted? Who are HSdirs? Tor relays who donate their disk space for hosting these messages?
  • How Alice find descriptor for Bob from DHT?
  • wiki says truncated SHA1 is not secure (I say full SHA1 is not secure either) but attacker would not be able to impersonate already existing hidden services! How he can't?
1
  • How we can contact Tor team about onion address weakness? seems nobody in this website is going to answer this question
    – user1062
    Feb 1, 2014 at 15:39

2 Answers 2

2

Sorry, I don't really understand your main question, but I'll do my best to answer the others.

How actually a descriptor look like (encoding) ? is there any format or size limit for descriptor on HSdir?

Descriptors are encoded as plain text and are fetched via regular HTTP (performed over a Tor circuit, ofcourse).

Where descriptors are hosted? who are HSdirs? Tor relays who donate their disk space for hosting these messages?

Hidden service descriptors are hosted by HSDirs (hidden service directories), which are just onion-routers (Tor relays) who meet a few conditions such as having a certain amount of uptime.

How Alice find descriptor for Bob from DHT?

The DHT (distributed hash table) is made up of HSDirs. The HSDirs that are used by a hidden service are selected using a function of time and the service's onion-address. When a client wants to download a hidden service's descriptors they calculate the hidden service's HSDirs and download them from there.

wiki says truncated SHA1 is not secure (i say full SHA1 is not secure either) but attacker would not be able to impersonate already existing hidden services! how he can't?

Work is currently being done to switch Tor to newer encryption and hashing algorithms.

AFAIK it is possible to impersonate a hidden service, but it's considered computationally infeasible. Once the hidden service's protocol is updated it will be even more difficult to do so.

1

How actually a descriptor look like (encoding) ? is there any format or size limit for descriptor on HSdir?

The hidden service descriptor is plain text and the full format can be found in the rend-spec document.

Where descriptors are hosted? who are HSdirs? Tor relays who donate their disk space for hosting these messages?

Descriptors are hosted in a distributed hash table (DHT) consisting of all HSdirs, defined in the dir-spec as:

"HSDir" -- A router is a v2 hidden service directory if it stores and serves v2 hidden service descriptors, and the authority believes that it's been up for at least 25 hours (or the current value of MinUptimeHidServDirectoryV2).

(as of 2013-03-11 with commit 5bab2738)

How Alice find descriptor for Bob from DHT?

Alice knows Bob's address (z.onion address, derived from Bob's public key). She then picks a random HSDir and sends it an HTTP 'GET' request for "/tor/rendezvous2/z" where z is the descriptor ID. If the request is unsuccessful, Alice retries with another randomly selected HSDir. If the request returns a 404 HTTP response, the service is not recognized. Otherwise Bob's most recent HS descriptor is returned.

All of this can also be found in the spec.

wiki says truncated SHA1 is not secure (i say full SHA1 is not secure either) but attacker would not be able to impersonate already existing hidden services! how he can't?

SHA1 is not completely broken, but (serious) weaknesses have been observed. Currently it's beleived that impersonating a hidden service would be very difficult, however, that's not to say that it will remain that way. As someone else mentioned, work is being done to move the hidden service spec towards using better hashing and encryption standards.

For more information see:

And finally, your main question:

let say Alice have Bob's public key (a better cipher than RSA) so Alice don't need onion address to find Bob's public key first. is that possible Bob just advertise his descriptor (introduction points) on HSdirs with this custom cipher and meet Alice or hidden services are limited to what Tor support today?

No, this is not going to be easy to do. However, if Alice already has Bob's public key once the HS connection is established you could end-to-end encrypt the channel using whatever form of encryption you want. Remember, hidden services aren't limited to HTTP, you could pipe any (TCP) protocol over the wire (and use any encryption that protocol supports) without modifying Tor's crypto at all.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .