Live data from Hacker News

The BitTorrent Protocol Specification v2

bittorrent.org

1–10 of 114 posts

Re: The BitTorrent Protocol Specification v2

#4
post #2

Can someone diff the spec from the previous version? What's the changelog? :)

The main differences I can see is a change from SHA1 -> SHA2 and also seems to have added official spec for webtorrent.

It also appears to be using a merkle hash tree for piece hashing now along with a few new peer wire messages to support that.

Re: The BitTorrent Protocol Specification v2

#6
This update to the spec is a modest change that's largely a preemptive reaction to SHA1 being broken; large portions of BitTorrent are designed around the 20-byte length of a SHA1 checksum. They've decided to move forward with SHA256 truncated to 20 bytes to avoid incompatibilities with existing infrastructure such as the Mainline DHT.

Beyond the hashing algorithm, some important additions that were previously proposals without widespread use (e.g. merkle tree for hashing pieces) are becoming required. The focus has mostly been on optimizing latency for the P2P protocol and making sane improvements to the file spec. I feel like trackers were largely overlooked in this update, but I'm biased because I work on a popular tracker.

Ideally, BitTorrent would be broken down into separate specifications that could be used together or in separate systems: one for the file format and piece representation for sharing files, one for the P2P protocol, and one for discovery (trackers, DHTs). I want to believe that there would be far more interesting P2P projects if you could just lift robust primitives from BitTorrent.

Re: The BitTorrent Protocol Specification v2

#7
post #2

Can someone diff the spec from the previous version? What's the changelog? :)

The main differences I can see is a change from SHA1 -> SHA2 and also seems to have added official spec for webtorrent.

> official spec for webtorrent

Huh, where do you see that? Not seeing any ctrl-f hits for webtorrent or webrtc.

Re: The BitTorrent Protocol Specification v2

#8
What's the stuff about "proof layers", is that new in this v2? The paper briefly talks about proof layer requests. Is this something merkle-tree related? What is the purpose? Is it to prevent clients from lying about having pieces they do not have by requesting a verifiable random hash chunk?

Re: The BitTorrent Protocol Specification v2

#9
post #7

Earlier quoted context omitted.

The main differences I can see is a change from SHA1 -> SHA2 and also seems to have added official spec for webtorrent.

> official spec for webtorrent Huh, where do you see that? Not seeing any ctrl-f hits for webtorrent or webrtc.

Whoops, i skimmed and they mentioned the end user web browser and I assumed they had.

I guess this is why they say when you assume you make an ass out of you and me.

Re: The BitTorrent Protocol Specification v2

#10

This update to the spec is a modest change that's largely a preemptive reaction to SHA1 being broken; large portions of BitTorrent are designed around the 20-byte length of a SHA1 checksum. They've decided to move forward with SHA256 truncated to 20 bytes to avoid incompatibilities with existing infrastructure such as the Mainline DHT. Beyond the hashing algorithm, some important additions that were previously propos…

The DHT BEPs specify a network that is only barely related to the bittorrent core protocol, they can already be used independently, and some people do.

> I feel like trackers were largely overlooked in this update, but I'm biased because I work on a popular tracker.

Yes, we did not pay much attention to trackers, but BEP52 basically seized the opportunity to do some incompatible changes we always wanted to do anyway (quite a few accumulated over the years), and there were no such open issues with the http tracker protocol.

Post reply on HN