[BitTorrent] Re: KEY tracker extension (and peer ids)

lazy_lightning_99 terrapin at sympatico.ca
Thu Dec 30 10:15:29 EST 2004



--- In BitTorrent at yahoogroups.com, "smilindog2000" <bill at v...> wrote:
> 
> --- In BitTorrent at yahoogroups.com, John Hoffman <theshadow at s...>
wrote:
> > The concept behind the "key" extension in the tracker announce is
very 
> > simple.  The peer chooses it randomly and will send the same value
with 
> > each announce.  This allows the tracker to verify the contactee is
the 
> > same peer even if its IP has changed, and lets the tracker update
that 
> > information.
> 
> I'm trying to figure this stuff out now.  If we get some good
> descriptions here, I'll try to add them to the wiki.

Good idea.  As a client developer, the wiki is the first (and most
useful) place that I check.  It's more than a little frustrating to
find some extensions (KEY, and UDP tracker, etc...) that appear to be
semi-widely supported but are not part of the spec there.  As I said,
searching the Yahoo group is more or less useless.

> The peer_id is enough for the tracker to identify a contactee, even
if
> the IP has changed, so that's not what the key is for.  I think the
> key flag is probably meant to keep other contactees from pretending
to
> be you during a download session.  You never tell anyone else the
key,
> but you do tell them your peer id.  So, the only secret information
> you tell the tracker is your key for the download session.  That
makes
> it the only reliable way to identify you.
> 
> I think from the client point of view, you just generate the random
> key at the same time you generate the peer id, but the only time you
> ever use the key is when talking to the tracker.

That makes sense.  Can we get confirmation of this?  Also, is this
something that is only supported in the UDP tracker spec, or in the
regular tracker protocol as well?

> I think there's a bit more to know about peer id's, too.
> 
> From the protocol spec, you'd think that you could use the same peer
> id over and over if you wanted, and never change it.  However, the
> trackers don't seem to expect clients to reuse peer ids.  Some wont
> let me re-download, since they figure I've already tried it once. 
> But, if I use a new peer id, I get through.  This may seem like
> reasonable behavior, but users simply have to have the ability to
> re-download.  Thus, it seems that peer-ids can't actually be
preserved.

This was another question I had... when to generate a new peerid. 
I've been generating it for each torrent session, not for each client
installation.  Haven't had any problems in testing, but not sure if
this is the right way in a live scenario, or for same torrents that
are resumed at a later date.

e





------------------------ Yahoo! Groups Sponsor --------------------~--> 
Make a clean sweep of pop-up ads. Yahoo! Companion Toolbar.
Now with Pop-Up Blocker. Get it for free!
http://us.click.yahoo.com/L5YrjA/eSIIAA/yQLSAA/dkFolB/TM
--------------------------------------------------------------------~-> 

 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/BitTorrent/

<*> To unsubscribe from this group, send an email to:
    BitTorrent-unsubscribe at yahoogroups.com

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 





More information about the BitTorrent mailing list