| 1 | <?xml version="1.0" encoding="utf-8" ?> |
|---|
| 2 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
|---|
| 3 | <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> |
|---|
| 4 | <head> |
|---|
| 5 | <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> |
|---|
| 6 | <meta name="generator" content="Docutils 0.5: http://docutils.sourceforge.net/" /> |
|---|
| 7 | <title></title> |
|---|
| 8 | <link rel="stylesheet" href="../css/bep.css" type="text/css" /> |
|---|
| 9 | </head> |
|---|
| 10 | <body> |
|---|
| 11 | <div class="document"> |
|---|
| 12 | |
|---|
| 13 | <div id="upper" class="clear"> |
|---|
| 14 | <div id="wrap"> |
|---|
| 15 | <div id="header"> |
|---|
| 16 | <h1><a href="../index.html">BitTorrent<span>.org</span></a></h1> |
|---|
| 17 | </div> |
|---|
| 18 | <div id="nav"> |
|---|
| 19 | <ul> |
|---|
| 20 | <li><a href="../index.html">Home</a></li> |
|---|
| 21 | <li><a href="../introduction.html">For Users</a></li> |
|---|
| 22 | <li><a href="bep_0000.html"><span>For Developers</span></a></li> |
|---|
| 23 | <!-- <li><a href="./blog">Blog</a></li> --> |
|---|
| 24 | <li><a href="http://forum.bittorrent.org"> Forums </li> |
|---|
| 25 | <li><a href="../donate.html">Donate!</a></li> |
|---|
| 26 | </ul> |
|---|
| 27 | </div> <!-- nav --> |
|---|
| 28 | <!-- ### Begin Content ### --> |
|---|
| 29 | <div id="second"> |
|---|
| 30 | |
|---|
| 31 | |
|---|
| 32 | |
|---|
| 33 | <table class="rfc2822 docutils field-list" frame="void" rules="none"> |
|---|
| 34 | <col class="field-name" /> |
|---|
| 35 | <col class="field-body" /> |
|---|
| 36 | <tbody valign="top"> |
|---|
| 37 | <tr class="field"><th class="field-name">BEP:</th><td class="field-body">4</td> |
|---|
| 38 | </tr> |
|---|
| 39 | <tr class="field"><th class="field-name">Title:</th><td class="field-body">Assigned Numbers</td> |
|---|
| 40 | </tr> |
|---|
| 41 | <tr class="field"><th class="field-name">Version:</th><td class="field-body">11093</td> |
|---|
| 42 | </tr> |
|---|
| 43 | <tr class="field"><th class="field-name">Last-Modified:</th><td class="field-body"><a class="reference external" href="http://bittorrent.org/trac/browser/dotorg/trunk/html/beps/bep_0004.rst">2008-05-20 19:01:53 -0700 (Tue, 20 May 2008)</a></td> |
|---|
| 44 | </tr> |
|---|
| 45 | <tr class="field"><th class="field-name">Author:</th><td class="field-body">David Harrison <dave at bittorrent.com></td> |
|---|
| 46 | </tr> |
|---|
| 47 | <tr class="field"><th class="field-name">Status:</th><td class="field-body">Active</td> |
|---|
| 48 | </tr> |
|---|
| 49 | <tr class="field"><th class="field-name">Type:</th><td class="field-body">Process</td> |
|---|
| 50 | </tr> |
|---|
| 51 | <tr class="field"><th class="field-name">Created:</th><td class="field-body">10-Jan-2008</td> |
|---|
| 52 | </tr> |
|---|
| 53 | <tr class="field"><th class="field-name">Post-History:</th><td class="field-body"></td> |
|---|
| 54 | </tr> |
|---|
| 55 | </tbody> |
|---|
| 56 | </table> |
|---|
| 57 | <hr /> |
|---|
| 58 | <div class="contents topic" id="contents"> |
|---|
| 59 | <p class="topic-title first">Contents</p> |
|---|
| 60 | <ul class="simple"> |
|---|
| 61 | <li><a class="reference internal" href="#reserved-bit-allocations" id="id2">Reserved Bit Allocations</a></li> |
|---|
| 62 | <li><a class="reference internal" href="#reserved-message-ids" id="id3">Reserved Message IDs</a></li> |
|---|
| 63 | <li><a class="reference internal" href="#copyright" id="id4">Copyright</a></li> |
|---|
| 64 | </ul> |
|---|
| 65 | </div> |
|---|
| 66 | <p>This document describes the known bit allocations and message IDs for |
|---|
| 67 | the BitTorrent protocol. To request a bit allocation contact |
|---|
| 68 | <a class="reference external" href="mailto:editor%40bittorrent.org">editor<span>@</span>bittorrent<span>.</span>org</a>. Contact the same address if you are aware of |
|---|
| 69 | any omissions.</p> |
|---|
| 70 | <div class="section" id="reserved-bit-allocations"> |
|---|
| 71 | <h1>Reserved Bit Allocations</h1> |
|---|
| 72 | <pre class="literal-block"> |
|---|
| 73 | reserved[0] |
|---|
| 74 | 0x80 Azureus Messaging Protocol |
|---|
| 75 | |
|---|
| 76 | reserved[2] |
|---|
| 77 | 0x08 BitTorrent Location-aware Protocol (no known implementations) |
|---|
| 78 | |
|---|
| 79 | reserved[5] |
|---|
| 80 | 0x10 LTEP (Libtorrent Extension Protocol) |
|---|
| 81 | 0x02 Extension Negotiation Protocol |
|---|
| 82 | 0x01 Extension Negotiation Protocol |
|---|
| 83 | |
|---|
| 84 | reserved[7] |
|---|
| 85 | 0x01 BitTorrent DHT |
|---|
| 86 | 0x02 XBT Peer Exchange |
|---|
| 87 | 0x04 suggest, haveall, havenone, reject request, and allow fast extensions |
|---|
| 88 | 0x08 NAT Traversal |
|---|
| 89 | </pre> |
|---|
| 90 | <p>There are known collisions:</p> |
|---|
| 91 | <pre class="literal-block"> |
|---|
| 92 | reserved[0] |
|---|
| 93 | 0xFF BitComet Extension Protocol |
|---|
| 94 | |
|---|
| 95 | reserved[1] |
|---|
| 96 | 0xFF BitComet Extension Protocol |
|---|
| 97 | |
|---|
| 98 | reserved[7] |
|---|
| 99 | 0x01 XBT Metadata Exchange (implemented only in XBT) |
|---|
| 100 | </pre> |
|---|
| 101 | <p>It is recommended that further extensions use LTEP [#BEP-]_. With |
|---|
| 102 | LTEP, extension bit collisions become impossible since no new |
|---|
| 103 | extension bits are allocated. With LTEP, message ID collisions also |
|---|
| 104 | become impossible because message IDs are allocated on demand at the |
|---|
| 105 | beginning of the connection. Extension <em>name</em> collisions become |
|---|
| 106 | possible, but the probability is much less likely.</p> |
|---|
| 107 | </div> |
|---|
| 108 | <div class="section" id="reserved-message-ids"> |
|---|
| 109 | <h1>Reserved Message IDs</h1> |
|---|
| 110 | <pre class="literal-block"> |
|---|
| 111 | Core Protocol: |
|---|
| 112 | 0x00 choke |
|---|
| 113 | 0x01 unchoke |
|---|
| 114 | 0x02 interested |
|---|
| 115 | 0x03 not interested |
|---|
| 116 | 0x04 have |
|---|
| 117 | 0x05 bitfield |
|---|
| 118 | 0x06 request |
|---|
| 119 | 0x07 piece |
|---|
| 120 | 0x08 cancel |
|---|
| 121 | |
|---|
| 122 | DHT Extension: |
|---|
| 123 | 0x09 port |
|---|
| 124 | |
|---|
| 125 | Fast Extensions: |
|---|
| 126 | 0x0D suggest |
|---|
| 127 | 0x0E have all |
|---|
| 128 | 0x0F have none |
|---|
| 129 | 0x10 reject request |
|---|
| 130 | 0x11 allowed fast |
|---|
| 131 | |
|---|
| 132 | Additional IDs used in deployed clients: |
|---|
| 133 | 0x14 LTEP Handshake (implemented in libtorrent, uTorrent,...) |
|---|
| 134 | </pre> |
|---|
| 135 | </div> |
|---|
| 136 | <div class="section" id="copyright"> |
|---|
| 137 | <h1>Copyright</h1> |
|---|
| 138 | <p>This document has been placed in the public domain.</p> |
|---|
| 139 | <!-- Local Variables: |
|---|
| 140 | mode: indented-text |
|---|
| 141 | indent-tabs-mode: nil |
|---|
| 142 | sentence-end-double-space: t |
|---|
| 143 | fill-column: 70 |
|---|
| 144 | coding: utf-8 |
|---|
| 145 | End: --> |
|---|
| 146 | </div> |
|---|
| 147 | |
|---|
| 148 | |
|---|
| 149 | </div> |
|---|
| 150 | <div id="footer"> |
|---|
| 151 | <hr/> |
|---|
| 152 | </div> |
|---|
| 153 | |
|---|
| 154 | </div> |
|---|
| 155 | </body> |
|---|
| 156 | </html> |
|---|