Exploiting BitTorrent
What is BitTorrent?
BitTorrent is a Peer2Peer filesharing protocol. It was designed in 2001 by Bram Cohen, to replace centralized server structures like FTP servers. Filesharing can be organized more efficient, no central server that has to provide all the upload. Also redundancy will be gained, due to distribution of the files to all the clients.
How does it work?
The files are divided into pieces, all the pieces that belong to one file are named in a so called torrent-fil, which is a meata data file also containing the hash cheksums for each piece and additional information.
Each piece can be downloaded seperately from one or more clients (peers) participating in the sharing process. But how does a peer know which other clients it should contact?
To obtain the information one needs to start a sharing process, he needs to get the torrent file first. The torrent files are published on public web servers. To obtain the list of peers praticipating, one then he needs to contact the so called tracker which keeps track of all the peers sharing the same file. The trackers IP address is included in the torrent file. The tracker responds with a list of randomly chosen peers and a client can now contact the other participants.
The peers are divided into two groups, seeders and leechers. A seeder is a peer that already obtained the whole file, he doesn't need to download anymore, but he still keeps his client running to share the file with others. A leecher is a peer that is still in the process of downloading the file, but he can also share already obtained pieces with others.
BitTorrent implements a fairness model: everybody needs to share with everybody! That means that every client participating in the sharing needs to provide his already obtained pieces to others, so he can download from the other peers.
The implementation of the fairness model is based on preferences. Somebody who doesn't contribute to the system will get low or no download rates, and somebody uploading a lot will get higher download rates.