tradle / bitjoe-js

Tradle bitjoe implementation in node
MIT License
2 stars 0 forks source link

json+multipart support #1

Open mvayngrib opened 9 years ago

mvayngrib commented 9 years ago

currently on-chain files are all JSON-only. Need support for attachments

mvayngrib commented 9 years ago

this may compromise the uniqueness of the infohash, as multipart boundaries are typically generated randomly.

possible solutions:

  1. a constant boundary, say --------------------00000000000000000 the downside is that this boundary may appear in one of the parts, which can result in dismemberment by the multipart consortium
  2. a deterministic boundary, like the merkle root of the parts, or the hash of the concatenation of the parts. Such a boundary would never (with infinitesimal probability) occur in a part, even if the parts were constructed by an attacker with unlimited resources.

downside - extra computation on creation and validation