ShareVault is a decentralized platform that allows users to securely store, share, and retrieve encrypted data, leveraging blockchain technology, Zero-Knowledge Proofs (ZKPs), and decentralized storage systems like IPFS/Filecoin. The platform ensures data privacy, integrity, and decentralization, enabling fair compensation for storage providers.
Key Features:
- Encrypted Fragmentation: Files are split and encrypted for secure storage.
- Zero-Knowledge Proofs: Proves storage integrity without exposing file content.
- Blockchain Integration: Metadata storage and payment systems are powered by Ethereum/Polygon.
- Decentralized Storage: Utilizes IPFS/Filecoin for data storage across multiple nodes.
- Fair Compensation: Storage providers earn cryptocurrency for hosting data.
ShareVault facilitates the sharing of encrypted data in a secure, decentralized manner. Users can upload files, which are split into encrypted fragments and stored across distributed nodes. Zero-Knowledge Proofs (ZKPs) are used to verify that data is stored correctly without revealing the contents. The platform is built with a frontend powered by React.js, Next.js, and a backend using Node.js and Ethereum/Polygon for blockchain integration.
- Frontend: React.js, Next.js
- Backend: Node.js
- Blockchain: Ethereum, Hardhat, Solidity Smart Contracts
- Storage Layer: IPFS/Filecoin
- Zero-Knowledge Proofs: zk-SNARKs/zk-STARKs
- Data Encoding: Reed-Solomon Codes
- Data Upload and Fragmentation: Files are split into encrypted fragments using erasure coding techniques.
- Proof of Storage: Nodes use ZKPs to prove they store data fragments securely.
- Decentralized Data Retrieval: Encrypted fragments are retrieved from the network and reassembled.
- Smart Contracts for Payments: Storage providers are compensated via Ethereum/Polygon-based smart contracts.
- Node.js (for the backend)
- npm and bun (for package management)
- Hardhat (for smart contract deployment)
-
Clone the Repository:
git clone https://github.com/your-username/sharevault.git cd sharevault
-
Install Dependencies:
npm install bun install
-
Configure Hardhat Project:
- Update
hardhat.config.js
with your blockchain network details.
- Update
-
Deploy Smart Contracts:
npx hardhat run scripts/deploy.js --network <network-name>
-
Start the Client:
bun run dev
-
Start the Server:
bun run dev
-
Run the Blockchain:
npx hardhat node
- File Upload: Users upload their files, which are split into encrypted fragments.
- Fragment Distribution: The encrypted fragments are distributed across decentralized storage nodes (IPFS/Filecoin).
- Proof of Storage: Storage nodes prove they store the fragments securely via Zero-Knowledge Proofs (ZKPs).
- Data Retrieval: Users retrieve the encrypted fragments, which are reassembled and decrypted.
- Payment Mechanism: Storage providers are compensated with cryptocurrency for their contributions.
ShareVault uses advanced security measures to protect data:
- AES Encryption: Encrypts data fragments to ensure only authorized users can access them.
- Zero-Knowledge Proofs: Validates storage integrity without revealing the actual data.
- Smart Contracts: Ensure tamper-proof metadata management and seamless payment processing.
- Scalability: Incorporate advanced zk-STARKs for better performance with larger datasets.
- Mobile Support: Develop cross-platform mobile applications to access ShareVault on the go.
- Real-Time Monitoring: Add advanced monitoring features for enhanced data availability and redundancy.
app/
: Contains the main application code, API routes, frontend pages, and libraries likecircom
(ZKP related files).ui/
: Reusable UI components like buttons, alerts, and inputs.public/
: Static files including SVGs and cryptographic files for ZKPs.
pages/api/
: Contains API routes for Ethereum interaction (ethProxy.ts
), data fetching (fetchData.ts
), and storing data (storeData.ts
).app/
: Server-side logic and ZKP-related libraries.
contracts/
: Solidity smart contracts for data commitment storage and locking.scripts/
: Deployment scripts for the blockchain.
This project is licensed under the MIT License. See the LICENSE
file for details.