Torrent file

From Just Solve the File Format Problem
Jump to: navigation, search
File Format
Name Torrent file
Ontology
Extension(s) .torrent
MIME Type(s) application/x-bittorrent
Released 2001

A torrent file is used by the BitTorrent protocol as a way of helping its users locate a file. BitTorrent is a peer-to-peer network with an ever-changing set of nodes that appear and disappear minute-to-minute as different users start and stop copies of a BitTorrent client. Special nodes called trackers are the point of contact to obtain files shared through the network, though the actual data of the file may be obtained in lots of little pieces spread over many nodes. A torrent file is the first thing you need to obtain before getting a file from BitTorrent; these can be found on many websites.

Contents

File format

Torrent files are serialized using the Bencode system, and contain these keys:

  • announce - URL of tracker that knows where to find the file
  • info - Dictionary containing more info about the file:
    • name - Filename/suggested save path
    • piece length - bytes per piece; commonly 262,144 (256K)
    • pieces - Concatenation of SHA-1 hashes of pieces
    • length - File size in bytes, if only one file is being shared
    • files - List of file dictionaries if multiple files are being shared:
      • path - Subdirectory name list; last name is filename
      • length - File size in bytes.

Legal and cultural issues

BitTorrent is reviled in some circles for being used to unlawfully pirate copyrighted material (music, movies, e-books, etc.). It is applauded in some other circles for those very same reasons. Undoubtedly some legislators would like to ban it altogether. However, it has many perfectly legitimate uses, such as in the distribution of free, open-source software and public-domain materials.

Tech specs

Sample files

Software

Links and references

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox