This project allows its users to create spaces (i.e. channels/blogs) where they can post statuses, articles, images, and videos. Other users (readers) can comment on the posts. Users can follow spaces and have their own personalized feed of posts from the spaces they follow. Users own their content.
It's possible to encrypt a post text and/or image and set up a price for readers they need to pay in order to decrypt the content. Once payment is made via Ethereum smart contract, a reader can decrypt the text or image. This is a pay-per-view feature.
Users sign in with .crypto domains.
The dapp stores user-generated content (spaces, posts, comments) on IPFS via OrbitDB. Images and videos get uploaded by users to their Textile Buckets. Web UI is implemented on React + Next.js and uses Ant Design v4 UI components.
We use a star signaling server to let users synchronize their local IFPS data with each other.
Post authors can optionally set up a price for decryption of their posts on Ethereum smart contract. Readers should buy a right to decrypt the content they want to read via the same smart contract. Once a reader paid per view, the third-party service that keeps encrypted secrets of the posts, re-encrypt a requested secret to a public key of a reader. Then a reader is able to decrypt an encrypted content (text or image). We use box() and secretbox() functions from TweetNaCl lib to encrypt and decrypt contents and secret keys.
The dapp verifies allows to sign in with .crypto domain. It verifies that the current account provided by web3 is the owner of .crypto domain via the lib @unstoppabledomains/resolution.