⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 bittorrent location-aware protocol 1_0 specification.mht

📁 关于BT的协议文档
💻 MHT
📖 第 1 页 / 共 5 页
字号:
formatted as in the HTTP/HTTPS GET request in a <A class=3D"external =
text"=20
title=3Dhttp://wiki.theory.org/BitTorrentSpecification#byte_strings=20
href=3D"http://wiki.theory.org/BitTorrentSpecification#byte_strings"=20
rel=3Dnofollow>string</A> form. The returned peers will be sorted in =
ascending=20
order by distance to the requester. A compromise could be made here. If =
there=20
are no peers having the whole torrent in the server response, the =
tracker may=20
substitute the last positions of the peers list with the closest =
seeders. With=20
such a server behavior a seeder can detect clustered peers with no =
available=20
seeders and make a compromise with the distance and distribute it to a =
peer of=20
the cluster. Even if the connecting peer does not support the BitTorrent =

Location-aware Protocol 1.0, the tracker may still check each =
peer=E2=80=99s location in=20
one of those IP address location databases and return the closest ones =
first.=20
</P>
<DIV class=3Deditsection style=3D"FLOAT: right; MARGIN-LEFT: 5px">[<A=20
title=3D"Edit section: New Peer Notification Message"=20
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit&amp;section=3D11">edit</A>=
]</DIV><A=20
name=3DNew_Peer_Notification_Message></A>
<H3>New Peer Notification Message </H3>
<P>When the tracker returns the list of peers to a peer <B>A</B>, these =
are the=20
closest peers and there is a maximum distance. If a new peer connects to =
the=20
tracker and its distance to peer <B>A</B> is less than the maximum =
distance, the=20
tracker will send to peer <B>A</B> a message notifying that a new closer =
peer=20
had connected. This is called <B>New Peer Notification Message</B> and =
it is a=20
<A class=3D"external text"=20
title=3Dhttp://wiki.theory.org/BitTorrentSpecification#dictionaries=20
href=3D"http://wiki.theory.org/BitTorrentSpecification#dictionaries"=20
rel=3Dnofollow>bencoded dictionary</A> with the following key / value =
pairs: </P>
<UL>
  <LI><B>info hash</B>: 20-byte SHA1 hash of the value of the info key =
from the=20
  <A class=3D"external text"=20
  =
title=3Dhttp://wiki.theory.org/BitTorrentSpecification#Metainfo_File_Stru=
cture=20
  =
href=3D"http://wiki.theory.org/BitTorrentSpecification#Metainfo_File_Stru=
cture"=20
  rel=3Dnofollow>Metainfo file</A>. Note that the value will be a =
bencoded=20
  dictionary, given the definition of the info key.=20
  <LI><B>peer id</B>: <A class=3D"external text"=20
  title=3Dhttp://wiki.theory.org/BitTorrentSpecification#peer_id=20
  href=3D"http://wiki.theory.org/BitTorrentSpecification#peer_id"=20
  rel=3Dnofollow>peer's self-selected ID</A>, as described as described =
in the=20
  BitTorrent protocol specification.=20
  <LI><B>ip</B>: peer's IP address (either IPv6 or IPv4) or DNS name (<A =

  class=3D"external text"=20
  title=3Dhttp://wiki.theory.org/BitTorrentSpecification#byte_strings=20
  href=3D"http://wiki.theory.org/BitTorrentSpecification#byte_strings"=20
  rel=3Dnofollow>string</A>).=20
  <LI><B>port</B>: peer's port number (<A class=3D"external text"=20
  title=3Dhttp://wiki.theory.org/BitTorrentSpecification#integers=20
  href=3D"http://wiki.theory.org/BitTorrentSpecification#integers"=20
  rel=3Dnofollow>integer</A>). </LI></UL>
<P>If a peer receives a new peer notification message and does not serve =
the=20
current torrent he should respond in plain text =E2=80=9C<B>11:not =
serving</B>=E2=80=9D. If he=20
is serving the torrent the response should be =
=E2=80=9C<B>7:serving</B>=E2=80=9D. After this the=20
peer should close the connection. With this implementation the tracker =
can=20
filter out peers not serving the torrent anymore. </P>
<DIV class=3Deditsection style=3D"FLOAT: right; MARGIN-LEFT: 5px">[<A=20
title=3D"Edit section: Peer-peer Handshake"=20
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit&amp;section=3D12">edit</A>=
]</DIV><A=20
name=3DPeer-peer_Handshake></A>
<H3>Peer-peer Handshake </H3>
<P>In a handshake between peers the <A class=3D"external text"=20
title=3Dhttp://wiki.theory.org/BitTorrentSpecification#Handshake=20
href=3D"http://wiki.theory.org/BitTorrentSpecification#Handshake"=20
rel=3Dnofollow>pstr</A> will have a value =E2=80=9C<B>BitTorrent =
Location-aware Protocol=20
1.0</B>=E2=80=9D. The <A class=3D"external text"=20
title=3Dhttp://wiki.theory.org/BitTorrentSpecification#Reserved_Bytes=20
href=3D"http://wiki.theory.org/BitTorrentSpecification#Reserved_Bytes"=20
rel=3Dnofollow>reserved bit</A> is 21. </P>
<DIV class=3Deditsection style=3D"FLOAT: right; MARGIN-LEFT: 5px">[<A=20
title=3D"Edit section: Location Message"=20
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit&amp;section=3D13">edit</A>=
]</DIV><A=20
name=3DLocation_Message></A>
<H3>Location Message </H3>
<P>If the two peers had declared the BitTorrent Location-aware Protocol =
1.0,=20
both of them send immediately after the <A class=3D"external text"=20
title=3Dhttp://wiki.theory.org/BitTorrent_Location-aware_Protocol_1.0_Spe=
cification#Peer-peer_Handshake=20
href=3D"http://wiki.theory.org/BitTorrent_Location-aware_Protocol_1.0_Spe=
cification#Peer-peer_Handshake"=20
rel=3Dnofollow>handshake</A> and before the <A class=3D"external text"=20
title=3Dhttp://wiki.theory.org/BitTorrentSpecification#bitfield:_.3Clen.3=
D0001.2BX.3E.3Cid.3D5.3E.3Cbitfield.3E=20
href=3D"http://wiki.theory.org/BitTorrentSpecification#bitfield:_.3Clen.3=
D0001.2BX.3E.3Cid.3D5.3E.3Cbitfield.3E"=20
rel=3Dnofollow>bitfield</A> their latitude and longitude in a location =
message.=20
The format is: <I>&lt;latitude&gt;&lt;longitude&gt;</I>. Both, the =
latitude and=20
longitude, will be formatted as within the tracker response. When a peer =

receives other peer=E2=80=99s location and it differs from the one =
supplied by the=20
tracker, he must reply with =E2=80=9C<B>17:Location =
Mismatch</B>=E2=80=9D and drop the=20
connection. </P>
<DIV class=3Deditsection style=3D"FLOAT: right; MARGIN-LEFT: 5px">[<A=20
title=3D"Edit section: Implementation in the Client and the Tracker"=20
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit&amp;section=3D14">edit</A>=
]</DIV><A=20
name=3DImplementation_in_the_Client_and_the_Tracker></A>
<H2>Implementation in the Client and the Tracker </H2>
<P>When implementing the BitTorrent Location-aware Protocol 1.0 in a =
client=20
side, the decisions from what peer to download what are complex and =
should go=20
under testing to find out where the performance is best. This is =
definitely not=20
an easy task, but with the existence of so many clients, some of them =
open=20
source, the upgrade should be possible. </P>
<DIV class=3Deditsection style=3D"FLOAT: right; MARGIN-LEFT: 5px">[<A=20
title=3D"Edit section: Related Documents"=20
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit&amp;section=3D15">edit</A>=
]</DIV><A=20
name=3DRelated_Documents></A>
<H2>Related Documents </H2>
<UL>
  <LI><A class=3D"external text"=20
  title=3Dhttp://wiki.theory.org/BitTorrentSpecification=20
  href=3D"http://wiki.theory.org/BitTorrentSpecification" =
rel=3Dnofollow>Bittorrent=20
  Protocol Specification v1.0</A> </LI></UL>
<DIV class=3Deditsection style=3D"FLOAT: right; MARGIN-LEFT: 5px">[<A=20
title=3D"Edit section: Change Log"=20
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit&amp;section=3D16">edit</A>=
]</DIV><A=20
name=3DChange_Log></A>
<H2>Change Log </H2>
<P>Put your changes below this line, so that the most recent changes =
appear=20
first. </P>
<UL>
  <LI>April 25, 2007 - Initial Publication - by Boian V Petkantchin.=20
  <UL>
    <LI>Contact: sogartary at yahoo.com </LI></UL></LI></UL><!-- Saved =
in parser cache with key mw-to:pcache:idhash:1668-0!1!0!!en!2 and =
timestamp 20070718154832 -->
<DIV class=3Dprintfooter>Retrieved from "<A=20
href=3D"http://wiki.theory.org/BitTorrent_Location-aware_Protocol_1.0_Spe=
cification">http://wiki.theory.org/BitTorrent_Location-aware_Protocol_1.0=
_Specification</A>"</DIV><!-- end content -->
<DIV class=3DvisualClear></DIV></DIV></DIV></DIV>
<DIV id=3Dcolumn-one>
<DIV class=3Dportlet id=3Dp-cactions>
<H5>Views</H5>
<UL>
  <LI class=3Dselected id=3Dca-nstab-main><A=20
  =
href=3D"http://wiki.theory.org/BitTorrent_Location-aware_Protocol_1.0_Spe=
cification">Article</A>=20

  <LI id=3Dca-talk><A=20
  =
href=3D"http://wiki.theory.org/Talk:BitTorrent_Location-aware_Protocol_1.=
0_Specification">Discussion</A>=20

  <LI id=3Dca-edit><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dedit">Edit</A>=20

  <LI id=3Dca-history><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;action=3Dhistory">History</A>=20
  </LI></UL></DIV>
<DIV class=3Dportlet id=3Dp-personal>
<H5>Personal tools</H5>
<DIV class=3DpBody>
<UL>
  <LI id=3Dpt-login><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DSpecial:Userlogin&amp;re=
turnto=3DBitTorrent_Location-aware_Protocol_1.0_Specification">Log=20
  in / create account</A> </LI></UL></DIV></DIV>
<DIV class=3Dportlet id=3Dp-logo><A title=3D"Main Page"=20
style=3D"BACKGROUND-IMAGE: =
url(/static/skins/common/images/theoryorg.png)"=20
href=3D"http://wiki.theory.org/Main_Page"></A></DIV>
<SCRIPT type=3Dtext/javascript> if (window.isMSIE55) fixalpha(); =
</SCRIPT>

<DIV class=3Dportlet id=3Dp-navigation>
<H5>Navigation</H5>
<DIV class=3DpBody>
<UL>
  <LI id=3Dn-mainpage><A href=3D"http://wiki.theory.org/Main_Page">Main =
Page</A>=20
  <LI id=3Dn-portal><A=20
  href=3D"http://wiki.theory.org/TheoryOrg:Community_Portal">Community =
portal</A>=20
  <LI id=3Dn-currentevents><A =
href=3D"http://wiki.theory.org/Current_events">Current=20
  events</A>=20
  <LI id=3Dn-recentchanges><A=20
  href=3D"http://wiki.theory.org/Special:Recentchanges">Recent =
changes</A>=20
  <LI id=3Dn-randompage><A =
href=3D"http://wiki.theory.org/Special:Random">Random=20
  page</A>=20
  <LI id=3Dn-help><A =
href=3D"http://wiki.theory.org/Help:Contents">Help</A>=20
  <LI id=3Dn-sitesupport><A=20
  href=3D"http://wiki.theory.org/TheoryOrg:Site_support">Donations</A>=20
</LI></UL></DIV></DIV>
<DIV class=3Dportlet id=3Dp-search>
<H5><LABEL for=3DsearchInput>Search</LABEL></H5>
<DIV class=3DpBody id=3DsearchBody>
<FORM id=3Dsearchform action=3D/Special:Search>
<DIV><INPUT id=3DsearchInput accessKey=3Df name=3Dsearch> <INPUT =
class=3DsearchButton id=3DsearchGoButton type=3Dsubmit value=3DGo =
name=3Dgo>&nbsp; <INPUT class=3DsearchButton type=3Dsubmit =
value=3DSearch name=3Dfulltext>=20
</DIV></FORM></DIV></DIV>
<DIV class=3Dportlet id=3Dp-tb>
<H5>Toolbox</H5>
<DIV class=3DpBody>
<UL>
  <LI id=3Dt-whatlinkshere><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DSpecial:Whatlinkshere&am=
p;target=3DBitTorrent_Location-aware_Protocol_1.0_Specification">What=20
  links here</A>=20
  <LI id=3Dt-recentchangeslinked><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DSpecial:Recentchangeslin=
ked&amp;target=3DBitTorrent_Location-aware_Protocol_1.0_Specification">Re=
lated=20
  changes</A>=20
  <LI id=3Dt-specialpages><A=20
  href=3D"http://wiki.theory.org/Special:Specialpages">Special pages</A> =

  <LI id=3Dt-print><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;printable=3Dyes">Printable=20
  version</A>=20
  <LI id=3Dt-permalink><A=20
  =
href=3D"http://wiki.theory.org/index.php?title=3DBitTorrent_Location-awar=
e_Protocol_1.0_Specification&amp;oldid=3D2062">Permanent=20
  link</A> </LI></UL></DIV></DIV></DIV><!-- end of the left (by default =
at least) column -->
<DIV class=3DvisualClear></DIV>
<DIV id=3Dfooter>
<DIV id=3Df-poweredbyico><A href=3D"http://www.mediawiki.org/"><IMG =
alt=3DMediaWiki=20
src=3D"http://wiki.theory.org/static/skins/common/images/poweredby_mediaw=
iki_88x31.png"></A></DIV>
<UL id=3Df-list>
  <LI id=3Dlastmod>This page was last modified 12:15, 1 May 2007.=20
  <LI id=3Dviewcount>This page has been accessed 2,475 times.=20
  <LI id=3Dprivacy><A title=3D"TheoryOrg:Privacy policy"=20
  href=3D"http://wiki.theory.org/TheoryOrg:Privacy_policy">Privacy =
policy</A>=20
  <LI id=3Dabout><A title=3DTheoryOrg:About=20
  href=3D"http://wiki.theory.org/TheoryOrg:About">About TheoryOrg</A>=20
  <LI id=3Ddisclaimer><A title=3D"TheoryOrg:General disclaimer"=20
  =
href=3D"http://wiki.theory.org/TheoryOrg:General_disclaimer">Disclaimers<=
/A>=20
  </LI></UL></DIV>
<SCRIPT type=3Dtext/javascript>if (window.runOnloadHook) =
runOnloadHook();</SCRIPT>
</DIV><!-- Served by bucky in 0.192 secs. --></BODY></HTML>

------=_NextPart_000_0000_01C7C9EE.B2129470
Content-Type: image/png
Content-Transfer-Encoding: base64
Content-Location: http://wiki.theory.org/static/skins/common/images/poweredby_mediawiki_88x31.png

iVBORw0KGgoAAAANSUhEUgAAAFgAAAAfCAMAAABUFvrSAAAAA3NCSVQICAjb4U/gAAAClFBMVEUC
KWuqqtbmxQbRvxS1xc+BdgdzlKmEq76qqqpBeZ3HxHrt7OZbZ1LWxE0lX3hxeUWzq2nY3N5WhKPQ
dQoAUIThyiSwrTY9RpT29vbGwqSjtsTHzdDAaQoAZplPepgATICdo6vp1Asyao7o59vO1NfQx2Ph
2XiOkTeKjY3yzQnW1smGla7s2yNemLXflg06hK0wO3h2pLvm2D/1sgfn4akHV4uYscEbLHZEd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GoQBAOa5pS
xLteeHN9zJFOa1I9j7fV6XRePv7bLnFKk+YhLJg1D+MSvMBcYM5r7dJqW1txrphD+AKMD2eFCrr+
8hTISSn+y+0N+DsRHbz66RMn6h09Pf392z7G8ZMId8jAXsZDeS+zzyEhsn4wsB0Lc4UdSri9Nk+L
ZxWEwRiGTGJ48WFn+nvXbl5rb2/Pnw7odNb9X9zFsEkEYyM1cF8+9zVgfClGGDCCwLiC8bmp1GDg
YwIJH1sWFqZpREPX/nj7cFLSJ9OnxsbGzn89HeANFu/spmkNQv/T+A2P/S7Bt04/39im23/xzsac

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -