I\'m coding a p2p implementation that I would like to make decentralized however I\'m having some trouble grasping how DHT in protocols like bittorrent work. How does the client
The general theory can be found in wikipedia's article on Kademlia. The specific protocol specification used in bittorrent is here: http://wiki.theory.org/BitTorrentDraftDHTProtocol