Atomic buying of digital recordsdata with digital foreign money is an concept that has a protracted historical past on this space. Digital items, digital foreign money, the 2 appear to be an ideal mixture. Digital items, i.e. info, additionally represent huge markets. Take into consideration all of the movies, audios, texts, video games and different types of digital content material that individuals purchase and eat frequently. These are markets price billions and billions of {dollars} that individuals work together with each day.
Most critical makes an attempt to implement paid file sharing have failed. Filecoin was an try to do that on prime of IPFS, however in the end the challenge is absurdly over-engineered. BitTorrent (the corporate, not the protocol) was purchased by Justin Solar and integrated its personal cryptocurrency and blockchain. These two tasks successfully failed to supply any productive outcomes, with extraordinarily over-designed techniques on the technical facet and really questionable incentives on the financial facet.
BitStream is a proposal by Robin Linus (have you ever ever thought of slowing down and taking a break, Robin?) to aim to satisfy the necessities of atomic knowledge buying with out the pointless addition of altcoins and overly elaborate technical protocols for the change.
All recordsdata might be uniquely recognized by a single hash, this can be a crucial element on this scheme. Promoting a file atomically requires encrypting the file utilizing a operate that permits the person to confirm what’s encrypted, and after that the person atomically buys the file’s encryption key. The issue is that the verification course of, and extra importantly, proving whether or not you will have been tricked and the file is decrypted into incorrect knowledge, is pricey. Naively, you have to to supply all the encrypted file and the decryption key in order that others can decrypt it and confirm that the decrypted knowledge doesn’t match the anticipated hash worth when hashed.

File sharing techniques like BitTorrent ceaselessly divide recordsdata into standard-sized chunks and assemble a Merkle tree from them, which permits the foundation hash to operate like a file identifier in a magnet hyperlink and confirm that every particular person chunk of a file you obtain is okay. a legitimate a part of this file. It is a property you may reap the benefits of to enormously enhance the effectiveness of fraud proof exhibiting {that a} file distributor has deceived you.
The vendor of the file can generate a random worth and use it to encrypt every bit of file utilizing an XOR operation towards that random worth. They’ll then signal an attestation of the foundation hash of the encrypted file and the hash of the encryption worth. The encrypted file tree is configured in a particular strategy to facilitate easy fraud proofs.

As a substitute of constructing the Merkle tree from simply the conventional, however encrypted, file chunks, the tree creates pairs of leaves consisting of an encrypted file chunk and the hash of the unencrypted file chunk subsequent to it. Now at this level the customer can obtain the encrypted file and after verifying by taking all of the hashes of the unencrypted chunks and making a Merkle tree from them to verify they match the foundation hash of the unencrypted file, it could atomically buy the decryption worth. . That is achieved by the vendor utilizing it as a pre-image to an HTLC on the Lightning Community or to a mint like Cashu that helps HTLCs.

If the file isn’t decrypted appropriately, both as a result of the encrypted knowledge is a distinct file or as a result of the preimage isn’t the precise encryption key, the Merkle path within the encrypted file tree to 2 Any leaves could point out that the vendor has deceived the customer. Merely offering the trail to any encrypted piece of file and its corresponding unencrypted piece hash with the preimage bought by the customer will definitively show that the vendor didn’t present the customer with the file that he pretended to be.
Any file vendor utilizing the BitStream protocol can publish a bond which might be reduce with proof of fraud as designed above in the event that they mislead a buyer. This may be enforced by merely posting a deposit with a Chaumien mint within the easiest case. Platforms like Liquid provide various strategies for constructing a hyperlink that may really be utilized with out belief because of options like OP_CAT. Scripts could possibly be constructed to really take the BitStream fraud proof and validate it on the stack, permitting the creation of a UTXO that will be usable by anybody with a legitimate fraud proof. If OP_CAT ever turned obtainable on mainchain, this might even be performed with confidence with out the necessity for a federated execution atmosphere.
BitStream is an extremely promising protocol for the atomic sale of digital info with a really efficient system for proving fraud, with out shitcoins.