CloudSafe is a decentralized application (DApp) that enables secure image storage and sharing using blockchain technology. It combines the power of Ethereum smart contracts for access control with IPFS for decentralized storage.
- Store images on IPFS (InterPlanetary File System)
- Permanent and immutable storage
- Content-addressed storage ensuring data integrity
- Powered by Pinata IPFS pinning service
- Ethereum-based access management
- Grant and revoke access to specific addresses
- View access history and current permissions
- Smart contract-powered security
- Modern, responsive design
- Seamless MetaMask integration
- Real-time updates and status
- Intuitive image upload and sharing
- Upload multiple image formats
- View all your uploaded images
- Share images with other users
- Access shared images from other users
- Node.js - Download & Install Node.js
- MetaMask - Install MetaMask Browser Extension
- Pinata Account - Sign up for Pinata
- Clone the repository:
git clone <repository-url>
cd cloudsafe- Install dependencies:
# Install root dependencies
npm install
# Install client dependencies
cd client
npm install- Configure environment variables:
Create a .env file in the client directory:
REACT_APP_PINATA_API_KEY=your_pinata_api_key
REACT_APP_PINATA_API_SECRET=your_pinata_secret_key- Start the local blockchain:
# In the root directory
npx hardhat node- Deploy the smart contract:
# In a new terminal
npx hardhat run scripts/deploy.js --network localhost- Start the application:
# In the client directory
npm start- Install MetaMask if you haven't already
- Connect MetaMask to the local network:
- Network Name: Hardhat Local
- RPC URL: http://127.0.0.1:8545/
- Chain ID: 31337
- Currency Symbol: ETH
- Click the "Choose Image" button
- Select an image file from your device
- Confirm the upload in MetaMask
- Wait for the transaction to be confirmed
- Your image will be stored on IPFS and linked to your address
- Your uploaded images appear automatically
- Click "Get Data" to refresh the image list
- Images are displayed in a responsive grid
- Click any image to view it in full size
- Click the "Share Access" button
- Enter the Ethereum address of the recipient
- Click "Share" and confirm the transaction
- The recipient can now view your images
- View current access permissions in the dropdown
- View all addresses with access in the sharing modal
- Revoke access by using the smart contract directly
- Track all access changes on the blockchain
- Access control through Ethereum smart contracts
- Permissioned access to image URLs
- Immutable access records
- Transparent permission management
- Images stored on IPFS
- Access controlled through blockchain
- Encrypted metadata
- Decentralized storage
- Secure MetaMask integration
- Transaction signing for all operations
- Network and account state management
- Automatic network detection
- Frontend: React.js
- Smart Contracts: Solidity
- Blockchain: Ethereum (Hardhat)
- Storage: IPFS (Pinata)
- Web3: ethers.js
- Styling: Modern CSS3
The application is fully responsive and works on:
- Desktop browsers
- Tablets
- Mobile devices
- Different screen sizes and orientations
-
MetaMask Required
- Must be installed and connected
- Local network must be configured
- Sufficient ETH needed for transactions
-
IPFS Storage
- Images are stored permanently
- Pinata credentials required
- Storage costs may apply
-
Network Requirements
- Local Hardhat network for development
- Can be deployed to testnets/mainnet
- Gas fees apply on public networks
This project is licensed under the MIT License - see the LICENSE file for details.