A robust, decentralized backup system for wallet profile data using Shamir Secret Sharing and multiple storage backends.
๐ Live Demo: https://scbuergel.github.io/gresistor/
Last updated: July 2025
- ๐ Shamir Secret Sharing - Split sensitive data into configurable N-of-M threshold schemes
- ๐ Local Browser Storage - Full support for IndexedDB-based storage with multiple service management
- ๐ AES-256-GCM Encryption - Client-side encryption ensures complete data privacy
- ๐ Browser-First Design - Works entirely in the browser with no server dependencies
- โก Zero-Trust Architecture - Your keys never leave your device unencrypted
- ๐จ React UI - Complete user interface for backup, restore, and configuration
- ๐ TypeScript Library - Full core library with backup/restore logic
- ๐ Remote Storage Backends - IPFS and Swarm integration (API stubs ready)
- ๐ก๏ธ Safe Wallet Integration - EIP-712 signature validation and EIP-1271 support (structure in place)
- ๐ Remote Key-Backup Service - Secure shard storage with Safe authentication (server framework ready)
- ๐ Privacy Routing - Enhanced anonymity features
- ๐ง Additional Encryption Options - ChaCha20-Poly1305 and AES-GCM-SIV algorithms
- ๐ Advanced Nonce Strategies - Counter-based and XChaCha20 192-bit nonces
This project is organized as a monorepo with the following packages:
๐ฆ gresistor/
โโโ ๐ packages/library/ # โ
Core TypeScript library (IMPLEMENTED)
โโโ ๐จ packages/ui/ # โ
React-based user interface (IMPLEMENTED)
โโโ ๐ services/key-backup/ # ๐ง Express.js backend for remote storage (PLANNED)
| Component | Status | Description |
|---|---|---|
| Core Library | โ Complete | Encryption, Shamir sharing, local storage |
| React UI | โ Complete | Backup, restore, and configuration interfaces |
| Local Storage | โ Complete | IndexedDB with multi-service management |
| Remote Storage | ๐ง API Only | Swarm/IPFS interfaces defined but not implemented |
| Safe Integration | ๐ง Stubs | EIP-712/EIP-1271 structure in place |
| Key-Backup Service | ๐ง Framework | Express server with route stubs |
- Node.js 18+
- pnpm 8+
# Clone the repository
git clone https://github.com/SCBuergel/gresistor.git
cd gresistor
# Install dependencies
pnpm install# Start all services
pnpm devThis launches:
- ๐จ UI Server โ
http://localhost:3000(fully functional) - ๐ Backend Service โ
http://localhost:3001(framework only)
# Build for production
pnpm run deployPlaywright browsers are automatically installed when you run:
# Install all dependencies (includes Playwright browsers)
pnpm install# Run end-to-end tests with MetaMask integration
pnpm test
# Run with pause mode (pauses at strategic points for inspection)
pnpm test:pause
# Run local app tests only (excludes wallet interactions)
pnpm test:offchain
# Run local app tests in headed mode (browser visible)
pnpm test:offchain:headed
# Run local app tests with pause mode (headed + pauses for debugging)
pnpm test:offchain:pauseTest Types:
- Full E2E (
pnpm test): Complete workflow with MetaMask/Safe integration - Offchain (
pnpm test:offchain): Local app functionality only, faster for development - Headed modes: Add
:headedfor visible browser,:pausefor debugging
If tests fail with browser launch errors:
- Try manually reinstalling Chromium:
pnpm exec playwright install chromium - Check that you're running on a system that supports headed browsers (tests require GUI)
- Ensure you have sufficient disk space for browser installation
# Start all services in parallel development mode
pnpm dev
# Clean development start (removes cache first)
pnpm dev:clean
# Stop all development processes
pnpm kill-dev# Build all packages
pnpm build
# Build only UI packages (library + UI)
pnpm build:ui
# Deploy build (alias for build:ui)
pnpm deploy# Clean build artifacts and cache
pnpm clean:cache
# Kill processes on development ports
pnpm kill-ports
# Run linting across all packages
pnpm lint- ๐ง Configure Storage - Set up local browser storage services in the Config tab
- ๐พ Create Backup - Enter your sensitive data and configure N-of-M parameters
- โ๏ธ Generate Shares - System splits data using AES-256-GCM + Shamir Secret Sharing
- ๐ Store Locally - Shards distributed across multiple IndexedDB services
- ๐ Restore Data - Collect required threshold of shards to reconstruct original data
- ๐ Configure Backends - Choose from IPFS, Swarm, or remote key services
- ๐ก๏ธ Safe Authentication - Sign EIP-712 messages for secure shard requests
- ๐ค Distributed Storage - Upload encrypted blob and shards to different services
- ๐ Secure Retrieval - Authenticate with Safe to retrieve and reconstruct data
- Frontend: React + TypeScript + Vite
- Crypto: Web Crypto API + shamirs-secret-sharing
- Storage: IndexedDB (browser-native)
- Build: pnpm workspaces
- Testing: Playwright + Dappwright (E2E wallet simulation)
- Backend: Express.js + Node.js
- Remote Storage: IPFS, Swarm APIs
- Blockchain: Safe SDK, EIP-712/EIP-1271
- Privacy: Enhanced anonymity protocols
- CI/CD: GitHub Actions
- AES-256-GCM encryption with 96-bit random nonces
- Shamir Secret Sharing with user-configurable N-of-M thresholds
- Browser-only execution - no server-side key handling
- Multiple storage services for redundancy within browser
- EIP-712 signature validation for shard requests
- Safe multisig authentication via EIP-1271
- Transport-layer privacy via enhanced routing protocols
- Hardware security module support for enterprise deployments
- TypeScript library with Shamir sharing
- AES-256-GCM encryption
- Local browser storage
- React UI components
- IPFS backend implementation
- Swarm backend implementation
- Remote service API completion
- Integration testing
- EIP-712 message signing
- EIP-1271 signature verification
- Safe SDK integration
- Multi-owner authentication
- Enhanced privacy transport layers
- Alternative encryption algorithms
- Hardware security modules
- Enterprise key management
This project is licensed under the MIT License - see the LICENSE file for details.
This project is actively being developed. The core library and UI are functional for local storage use cases.
Current priorities:
- Complete IPFS/Swarm storage backend implementations
- Implement Safe wallet authentication features
- Build out the remote key-backup service functionality
See the roadmap above for detailed development phases.