Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

There are 2 uses of the hashes in bittorrent. a) integrity checking b) as unique identifier for the swarm.

The hash only gets truncated when used in places as unique identifier. When you start with a v2 magnet link or torrent file you get the full 32bytes hash, which means your integrity-checking is unaffected.



You download 32 bytes hash and check it using 20 byte hash from the magnet link.



Is there any plan to allow base64, longer hashes and selecting the hash algorithm in the magnet uri format?


No such plans. What would be the motivation anyway? A different hash function for the infohash calculation wouldn't change anything since other parts of the protocol would still use sha256 (v2) or sha1 (v1). So if this is about security, you wouldn't be changing the weakest link.

Not to mention that this would not be compatible with other peers, there is no algorithm-negotiation in the network protocols, so how would they know which hash you're using? The magnet link is pretty much the far end of the process, you'd have to change a lot of other things first.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: