[bittorrent] DHT - Clarifying the spec

Ludvig Strigeus strigeus at gmail.com
Sat Mar 3 05:33:53 EST 2007


Hi,

Oh ok, I didn't notice that. I wrote the DHT code before that spec existed.
Well my opinion still holds, but I guess the spec needs to be less ambiguous
to be able to apply it.

Reject anything but strings. Use 4-byte strings for requests.

/Ludvig


On 3/3/07, Adrian Ulrich <torrent at blinkenlights.ch> wrote:
>
>
> > I don't agree at all that it's 'nice' to accept things that are outside
> the
> > spec. For example accepting ints even though the spec says otherwise.
>
> The spec says you shall use a 'single character string value'.
> but uses INTs and Strings in the example packets:
>
> Int:
> generic error = {'t':0, 'y':'e', 'e':[201, "A Generic Error Ocurred"]}
> bencoded = d1:eli201e23:A Generic Error Ocurrede1:ti0e1:y1:ee
>
> String:
>   Response = {"t":"0", "y":"r", "r": {"id":"mnopqrstuvwxyz123456"}}
>   bencoded = d1:rd2:id20:mnopqrstuvwxyz123456e1:t1:01:y1:re
>
>
> So what does uTorrent do?
>
> _______________________________________________
> BitTorrent mailing list
> BitTorrent at lists.ibiblio.org
> http://lists.ibiblio.org/mailman/listinfo/bittorrent
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ibiblio.org/pipermail/bittorrent/attachments/20070303/77968cf8/attachment.html 


More information about the BitTorrent mailing list