There is no easy way for the average user to store private data in a secure and decentralized cloud. MyPFS offers a simplified and user friendly web where any user just need a metamask wallet to upload, delete and access private data on a decentralized cloud.
There is no easy way to store private data in a decentralized way where you can be sure that it will be secure and won't be erased.
Cloud services like Google Drive enable you to store your data privately but you have to rely on this company for the security and longevity of your files.
IPFS enables you to store data in a node network so you don't need to rely on centralized entities anymore but nodes are public so everyone can access your data.
Thanks to our solution we are adding privacy to IPFS. We allow the average user to easily encrypt his data by signing a message with his wallet and storing it on many IPFS nodes so it lasts forever.
Encryption is done on the browser using Metamask Snaps, each user generates its own app-specific private key so they have a unique key, different from their wallet one. Files are then stored using web3.storage which replicates and pin the data on multiple IPFS nodes so we can ensure we'll never lose our data.
Encryption is done asymmetrically so data is encrypted with the public key and then decrypted with the private key.
Also, to make it easy for users to keep track of their file URLs we made a directory system stored on a smart contract which gets updated every time a new file is created.
MyPFS is a website done with Next Js. It allows users to connect with its metamask flask wallet and install our metamask snap extension which takes care of generating an app-specific private key for the user (different from the wallet private key) and a public key. Then we developt an SDK that receives those keys and the data, encrypts it, and pushes it to IPFS. The encryption was a real technical challenge because we had to figure out how to encrypt data asymmetrically, in a bidirectional way (encrypt and decrypt) and most important - on the browser. Encryption isn't something that's normally done on the browser because developers usually need to run many buffers and functions which requires more than a lightweight browser to work.
For pushing the data to IPFS, our SDK uses web3.storage, we are using one web3.storage API key for this demo but the idea is that the SDK allows the user to determine their own API keys, use their nodes or use another IPFS node provider service.
Finally, our SDK adds the recently created IPFS URL to a directory file also stored on IPFS and after that, it writes a record on a smart contract which contains a map of addresses - directory so the user doesn't need to manually store his IPFS links and we can retrieve them on the website.
This was done in that specific way because we didn't want to create a centralized backend which would go against our vision and would force users to rely on us to list their URLs.