Re: Using the DHT to find download sources

"pwang708" <[email protected]>
Newsgroups gmane.network.gnutella.devel
Message-ID <[email protected]>
> Note that there is always the remote possibility of a collision, whereby
> the SHA1 of your GUID would match the SHA1 of a file, and therefore
> push-proxy locations and IP:port of hosts offering the SHA1 would mix.
> One way to overcome this is to attach a small set of meta-data to
the value.
> For instance, to publish yourself as the location of a file, you would
> issue PUT(key, 'H', IP:port) to signal the value is a host and therefore
> the key the SHA1 of a file, whereas to publish a push-proxy you
would say
> PUT(key, 'P', IP:port) to signal the value is actually that of a
push-proxy.
> 
> Then naturally, the retrieval would have to specify what you really
want:
> a GET(key, 'H') would return ONLY a vector of IP:port that were
stored via
> a PUT(key, 'H') and not those stored under the same key but which
were the
> result of a PUT(key, 'P').
> 

FYI, in the current implementation, a DHT value has a DHTValueType
field. You can also specify the DHTValueType in the FindValue request
messages.

Peng
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.