The Libtorrent has just released version 2.0, which is going to completely change the game. Library Libtorrent, used by popular torreent clients (applications) such as uTorrent, Deluge and qBittorrent. Version 2 opens the door to many new possibilities and brings a new torrent format, which creates a separate swarm.
Millions of people use it BitTorrent every day, but few know how it works.
The BitTorrent was first released by inventor Bram Cohen almost two decades ago. It was quickly adopted by the public, but the new protocol just wasn't perfect. Over the years many new features have been added, such as DHT, UDP trackers, peer-exchange and streaming support.
As a developer of one of its top libraries BitTorrent, Arvid Norberg who developed the Libtorrent library, was closely involved in the development of the protocol BitTorrent v2. Its code makes too many torrent clients work properly.
This week, Norberg announced his latest release Libtorrent. Version 2.0 is here. The new version comes with many changes that will eventually reach the torrent clients and the world that uses them. The most important of these is the implementation of the protocol specifications BitTorrent v2.
The BitTorrent v2 is an improved version of its early standards BitTorrent and includes many technical changes. It was first proposed by Bram Cohen in 2008 and has been constantly updated and improved since.
The BitTorrent v2 changes the way torrents are "compiled" and the newer version is not backwards compatible with older torrents. Older torrents have SHA-1 encryption while newer versions use SHA-256. This means that in the future, there will be different torrent versions.
These different torrents (v1 and v2) should have separate torrent swarm. People who download version 1 torrents will not be able to share anything with people who download version 2 torrents and vice versa. Although it sounds like a step backwards, in reality there will be no problem (theoretically at least).
There is also an option to create so-called "hybrid" torrents that can be connected to both swarms. This will be two torrents in one. So all torrents will have the same number of seeders.
A v2-enabled client would still be able to "talk" to all peers, and peer-to-peer exchange would still work on version 1 peers. What will change is that a v2-enabled peer should announces a hybrid torrent twice, once for each info-hash. "Both the trackers and the DHT," Norberg told Torrentfreak.
"I think it would make sense for publishers to create hybrid torrents. At least experiment with them to make sure they work well. Torrents only for version 2 will only make sense for closed ecosystems at this time. ”
Note that the transition from SHA-1 to SHA-256 hashing will be able to prevent attacks and exploits in the protocol.
Norberg says the risk of these attacks is largely theoretical, but that may change over time. So switching to SHA-256 is definitely a great idea. An even more exciting change, according to the developer, is the use of 'per-file merkle hash trees' for piece hashes.
This simply means that all files in a torrent will have their own unique hash. Thus, a collection of 100 photos will have a unique hash for each photo. This brings many advantages.
For example, it will allow torrent clients to quickly check if they are receiving the correct file. This will prevent attacks with infected or strange files that can be used by some external for obvious reasons. One of them is when someone wants to damage the torrent.