Tepe project: asynchronous trustless data sharing

Can NFTs actually do anything? You notch your name into a public registry, and people associate that notch with some sort of scarcity. Sure, people can promise to honor agreements based on what’s in the registry — a house promised to the owner of an NFT, or promised front row seats to Kings of Leon for life, or promised coffee discounts — but nothing compels the people involved to honor the arrangements.

 
a dall-e image of someone carving a notch into a wooden post

NFTs: carving your name into a digital post and hoping others value the notch.

 

What if you were guaranteed access to something scarce simply by holding an NFT? To be specific, what if the logic of a smart contract could grant access to a file only to holders of a corresponding NFT? The owner of the NFT wouldn’t need to trust that a bouncer will honor some digital notch, or that a company remains in business, or that a server remains up. The creator of the file can go completely off grid after setting up the system, without needing to know who the eventual owners are, or how the file gets to them. The NFT actually does something! Even better, the problem it addresses is a massive and pressing one: do you have control over your data?

The public nature of blockchains makes this exceedingly tricky, because consensus around the state of the blockchain depends upon everything being publicly visible. Zero knowledge proofs are buzzy and sound intimidating enough to be a solution to our problem, right? They manage consensus without publicly visible state, but the problem is, no one knows the state changes but the parties involved. If a creator wanted to grant access to a file to whoever owns an NFT, they’d have to make direct contact with the owners — all a zero knowledge proof could do is log that it happened. What’s the point? You might as well send the file over FTP.



 

Tepe — an artificial mound, covering up old data in the ancient ruins of Göbekli Tepe

 

Harang Ju and I spent the first part of 2023 brainstorming how to tackle this problem, and the second half putting it into practice. Our prototype app is called Tepe, and it allows for end-to-end token gating of content — no trust in humans is necessary. One person creates a channel — under the hood, a smart contract on the Secret network — that serves as the executor of access to content. The creator uploads an encrypted version of their content and stores it literally anywhere, out in the open — we use IPFS, decentralized file storage — and stashes the key in the hidden state of the smart contract. The Secret network is the only blockchain we’re aware of that allows for hidden state on-chain — thanks to reliance on Intel’s SGX as a secure enclave.

 

Our tepe app! This is the view from within a channel, where you can access the file if you own the NFT.

 

Anyway, the creator mints some NFTs and gives them/sells them/etc., and can then throw their laptop in a lake — the rest is handled by the smart contract. The owners of the NFTs can access the key to decrypt the data, and it’s theirs! Secure 1:1 file transfer, controlled broadcasting to subscribers, knowledge of where your data goes. Imagine Slack, where the whole conversation is passed around this way between members of a channel, instead of sitting on a server in a Slack datacenter — each update changes the file and the key stays the same. Imagine writing a book, posting the encrypted version, and auctioning off access.

Much of the year was spent learning the tech stack, most notably Rust for the smart contract (which we have posted to github) and Vue+Electron for the app (please try it out! Compile it yourself or try our .exe/.dmg!). We are excited to see what can be built on top of this, and would love to discuss more if you have any thoughts.

Next
Next

A minimal NFT, with more tokens than atoms on Earth | Oct 2021