project screenshot 1
project screenshot 2
project screenshot 3
project screenshot 4
project screenshot 5
project screenshot 6

De-File Drive

A GoogleDrive/Dropbox for files but decentralised powered with e2e file encryption, private group creation for your friends and file sharing with no link management hassle!

De-File Drive

Created At

Hack FEVM

Project Description

We already have web2 drives where we can store files and share them with users via links, but the problem with this approach is: → general lack of privacy → no guarantee of data uptime/loss → information overload and duplication … and many more aargh!

<<< Here comes De-File Drive to rescue >>>

What De-File Drive is?

A decentralised file storage system, with secure files, minimum duplication and capability to create groups where we can add our closed ones or the people we want to share the file with.

Features?

  • Group/Private space:

    • Users can create groups where they can add members via their wallet address
    • Only users who are currently in the group can on-board new members
    • There is no hierarchy in group and no admins. Everyone who is added is equal. (still we can create admin functionality in future, for making it more robust and private and also role based access).
    • You can only join a group if someone adds you in, no other way!!!
  • File Storage and Management:

    • Users can view/download files shared to the groups they are part of.
    • Uploaded file is first encrypted, with encryption keys mapped with respective groupId
    • The encrypted file is uploaded on IPFS and can be accessed via its CID
    • On receiver’s end, file is again decrypted via the encryption key mapped to its group
    • A file shared in a group will be visible to all users in the group.

Pre-requisites to use the app?

  1. Access the app here: https://de-file-drive.vercel.app/
  2. After onboarding, user would need to connect wallet (tested on MetaMask) to the FileCoin - Wallaby Testnet network
  3. Make sure to get some TFIL from faucet here: https://wallaby.network/#faucet, to make transactions and to be able to proceed.

How it works and how to use?

Group creation:

  1. After onboarding user first need to create group.
  2. Hit Create Group Button and provide some unique groupId/group name.
  3. After submitting, Sign the transaction and wait for you group to be created.

Add Files:

  1. Click on your group.
  2. After Selecting files, firstly the files are encrypted using encryption key associated with the groupId.
  3. The encrypted files are then uploaded on IPFS and then on FileCoin via web.storage’s JS APIS
  4. We receive the root CID of the uploaded file.
  5. Using this CID we can access the encrypted file and decrypt it, via the same encryption key, to show under the Synced Files section.

Add Friends in the group:

  1. Click on your group.
  2. Hit Add Friend CTA and enter friend’s valid wallet address
  3. After submitting, Sign the transaction and wait for your friend to get added to the group.
  4. Your friend can now see the groups as well as the files shared with them.

Limitation(s)?

  • Currently due to FVM limitation of events, polling has been used for checking data availability.
  • Error handling for failure scenarios to be tested and managed. (ps: was short of hands)

Hurdles? We need a better way user and group discovery to make it secure and available at the same time.

How it's Made

Tech behind, how are they pieced and sponsor tech?

  1. We used remix for smart contract prototyping and FEVM HardHat Starter Kit for deployment.

  2. The smart contract is written in Solidity and deployed on FileCoin Wallaby Testnetwork.

  3. Following is the address of deployed smart contract: 0x5b8DfeA556e6EE8401Ea4C0884a5B43AE5462931

  4. The client is built using Next.js - a framework powered by React.js with out of the box support for SSR and SSG

  5. web3modal is used to be able to interact and connect wallets.

  6. To communicate with our deployed contract and execute the methods exposed by the contract’s ABI we used ethers.js

  7. To communicate with IPFS and retrieve the contents CID post uploading it we used web3.storage, also it helps to store the file on FileCoin.

  8. Files metadata as well as its encryption key is stored on the FileCoin blockchain to perform on-chain computation on the state data.

  9. Deployment of App is managed by vercel and CI is configured with Github.

  10. We used various other open source libs and design patters to build the neat UI and performant app.


How I'm impressed?

I am impressed by fact that tools which are used are all open-source and even the contract is public, but still the data is hidden and seems to be private within my network of users!

Glossary:

SSR - Server Side Rendering, SSG - Static Site Generation, ABI - Application Binary Interface, FEVM - FileCoin Ethereum Virtual Machine, CID - Content Identifier

background image mobile

Join the mailing list

Get the latest news and updates