Skip to content

Dikshant-Neupane/LegacyX

Repository files navigation

LegacyX

Not even we can touch it.

A Solana-powered digital life vault where every human stores their assets, secrets, final words, conditional inheritance, whistleblower evidence, and real identity proof β€” governed by unstoppable smart contracts on-chain.


Table of Contents


Problem Statement

  • 70% of digital assets are lost forever when someone dies β€” no inheritance plan, no recovery.
  • Your deepfake exists right now. You cannot prove it isn't you. There is no cryptographic proof of your real identity anchored in time.
  • Your final words exist only inside your head. If you die today, the people you love will never hear what you needed to say.
  • Lawyers charge $50,000+ for estate planning. Conditional inheritance is gated behind wealth.
  • Whistleblowers die with their evidence if they cannot guarantee its release.

Solution

LegacyX is a zero-trust digital vault built on Solana where:

  1. You encrypt everything on your device β€” our servers never see your data, not even once.
  2. Your vault lives permanently on Arweave β€” even if we shut down tomorrow, your vault exists forever.
  3. Smart contracts enforce your rules β€” check-in deadlines, conditional inheritance, dead-man switches.
  4. Phantom Wallet is your only identity β€” no email, no password, no OAuth. Just your wallet.
  5. Anyone can verify your vault on Solscan in one click.

Core Features

Regret Vault

Encrypted final words β€” voice, video, or text β€” released to specific people after death. Burn-after-read option permanently destroys after first view.

Conditional Inheritance

Digital assets locked behind on-chain verifiable conditions set by the owner. No lawyers. $10 instead of $50,000.

Whistleblower Switch

Evidence auto-broadcasts to 1,000 wallets if owner stops checking in. Permanently unstoppable once configured.

Soul Wallet

Your memory and voice preserved. Your bloodline holds the key.

Proof of You

Biometric hash anchored on Solana while alive. Cryptographic proof you are real and not a deepfake. Verifiable by anyone on Solscan.

Social Recovery

3-of-N Phantom Wallet guardian multisig for vault recovery if owner loses wallet access.


Tech Stack

Layer Technology
Blockchain Solana (Devnet for MVP, Mainnet for production)
Smart Contracts Rust + Anchor Framework
Storage Arweave (permanent encrypted file storage)
Frontend Next.js 14 + TypeScript + TailwindCSS + Framer Motion
Wallet Phantom Wallet β€” ONLY authentication method
Wallet Adapter @solana/wallet-adapter-react
3D Visuals Three.js (vault orb sphere)
Animations Framer Motion + GSAP + CSS custom keyframes
Smooth Scroll Lenis
Mobile Solana Mobile Stack (SMS) + React Native
Deployment Vercel (frontend + serverless backend)
Explorers Solscan, Solana Explorer, Orb by Helius

Live Demo

πŸ”— Vercel: https://legacyx.vercel.app


Solana Devnet Program

Item Link
Program ID LGCYxV1111111111111111111111111111111111111
Solscan View on Solscan
Solana Explorer View on Explorer
Sample Vault TX

Anchor Test Results


Architecture

See docs/architecture.md for the full system architecture with Mermaid diagrams.

Three-Layer Vault:

  1. Arweave β€” Encrypted file storage (permanent)
  2. Solana β€” Rules, keys, and hashes (immutable)
  3. Device Biometric β€” Access control (local only)

Zero-Trust Principle: The server is intentionally blind. All encryption happens in the browser via SubtleCrypto before any network call. The server NEVER receives or stores unencrypted user data.


Getting Started

Prerequisites

  • Node.js 18+
  • Rust 1.70+
  • Solana CLI 1.17+
  • Anchor CLI 0.29+
  • Phantom Wallet browser extension

Installation

# Clone the repository
git clone https://github.com/YOUR_USERNAME/legacyx.git
cd legacyx

# Install frontend dependencies
cd frontend
npm install

# Install backend dependencies
cd ../backend
npm install

# Build Solana programs
cd ..
anchor build

# Run Anchor tests
anchor test

# Start frontend dev server
cd frontend
npm run dev

# Start backend dev server (separate terminal)
cd backend
npm run dev

Environment Variables

Copy .env.example files and fill in your values:

cp frontend/.env.example frontend/.env.local
cp backend/.env.example backend/.env

See backend/.env.example for all required variables.


Project Structure

legacyx/
β”œβ”€β”€ programs/legacyx/          # Solana smart contracts (Anchor/Rust)
β”‚   └── src/
β”‚       β”œβ”€β”€ lib.rs             # Program entry point
β”‚       β”œβ”€β”€ instructions/      # One file per instruction
β”‚       β”œβ”€β”€ state/             # Account data structures
β”‚       β”œβ”€β”€ errors.rs          # Custom error codes
β”‚       └── events.rs          # On-chain event definitions
β”œβ”€β”€ tests/                     # Anchor TypeScript test suite
β”œβ”€β”€ frontend/                  # Next.js 14 frontend
β”‚   β”œβ”€β”€ app/                   # App Router pages
β”‚   β”œβ”€β”€ components/            # Custom component library
β”‚   β”œβ”€β”€ lib/                   # Encryption, wallet, explorer utilities
β”‚   β”œβ”€β”€ hooks/                 # Custom React hooks
β”‚   └── styles/                # Global styles, design tokens
β”œβ”€β”€ backend/                   # Fastify API (Vercel serverless)
β”‚   └── src/
β”‚       β”œβ”€β”€ routes/            # API route handlers
β”‚       β”œβ”€β”€ services/          # Arweave, Solana, notification services
β”‚       β”œβ”€β”€ jobs/              # Check-in monitoring cron
β”‚       └── middleware/        # Auth, validation, rate limiting
β”œβ”€β”€ mobile/                    # Solana Mobile Stack (React Native)
β”œβ”€β”€ docs/                      # Architecture, security, threat model
β”œβ”€β”€ Anchor.toml                # Anchor configuration
└── README.md                  # This file

Smart Contract Instructions

Instruction Description Access
create_vault Initialize vault PDA, set interval, assign heirs Owner only
check_in Sign proof-of-life, reset timer Owner only
trigger_release Start 30-day grace period after missed check-in Anyone
release_to_heir Distribute key shards to heirs after grace period Registered heir
conditional_release Prove condition to unlock specific assets Registered heir
burn_message Permanently delete message CID from chain Registered heir
social_recovery M-of-N guardian multisig to reassign owner Registered guardian
identity_proof Anchor biometric SHA-256 hash on-chain Owner only
configure_whistleblower Set 1000 broadcast wallet addresses Owner only
whistleblower_broadcast Execute irreversible broadcast Anyone (if triggered)
mint_certificate Mint Token Extension NFT proof of vault Owner only
add_heir Add new heir to vault Owner only
add_file Store encrypted Arweave CID on vault PDA Owner only

API Endpoints

Method Endpoint Description
POST /api/vault/create Initialize vault PDA, mint certificate NFT
POST /api/vault/checkin Submit Phantom signed check-in transaction
POST /api/vault/upload Receive encrypted blob, upload to Arweave
GET /api/vault/:pubkey Return vault status, file list, heir info
GET /api/vault/:pubkey/certificate Return NFT certificate with verification links
POST /api/identity/proof Submit biometric hash to Solana
POST /api/recovery/initiate Start social recovery flow
POST /api/recovery/sign Guardian submits Phantom signature
POST /api/whistleblower/configure Set broadcast wallet addresses
GET /api/explorer/:txid Return formatted Solscan/Explorer/Orb links

Full API documentation: backend/API.md


Security Model

Zero-Trust Architecture

Principle Implementation
Client-side encryption AES-256-GCM via SubtleCrypto β€” runs in browser before any network call
Key derivation HKDF from Phantom Wallet keypair β€” key never leaves device
Secret sharing Shamir's Secret Sharing β€” M-of-N shards for heir reconstruction
Biometric privacy SHA-256 hash only β€” raw data destroyed from memory after hashing
Server blindness Server receives ONLY encrypted blobs and hashes β€” zero plaintext
On-chain verification All vault state verifiable on Solscan by anyone

See docs/threat-model.md for the complete threat model.


Explorer Integration

Every on-chain action in LegacyX immediately provides three verification links:

  • Solscan β€” Primary transaction explorer (shown after every action)
  • Solana Explorer β€” Official verification (vault certificates)
  • Orb by Helius β€” Visual explorer (demo video presentation)

Business Model

Tier Price Includes
Free $0 Basic vault, 1 heir, 100MB storage, annual check-in
Premium $9.99/mo Unlimited heirs, 10GB, Soul Wallet, conditional inheritance
Enterprise $99/mo Whistleblower vault, corporate identity, custom intervals
One-Time $4.99 Single Regret Vault message with burn-after-read

Demo Video

πŸŽ₯ Watch:

Video Structure (3 minutes max):

  • 0:00–0:30 β€” Problem statement
  • 0:30–2:30 β€” Live demo on Solana Devnet
  • 2:30–3:00 β€” Broader implications for Nepal and global market

Team

Name Role Location
Dikshant Neupane Full Stack Developer & Founder Nepal πŸ‡³πŸ‡΅

Built in Nepal. Powered by Solana.


License

MIT License β€” see LICENSE for details.


LegacyX β€” Your life, encrypted. Your legacy, permanent.
Not even we can touch it.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors