Skip to content

About

Zero-Knowledge Ephemeral Secret Sharing Vault with Browser Native WebCrypto AES-GCM-256, RFC 3986 Anchor Isolation, and Atomic Burn-on-Read Engine.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Latest commit

Β 

History

9 Commits

Folders and files

Repository files navigation

πŸ›‘οΈ ZeroTrace-Vault β€” Zero-Knowledge Ephemeral Secret Sharing Vault

Security: Zero-Knowledge Live Demo GitHub Stars Encryption: AES-GCM-256 RFC 3986 Anchor Node.js License: MIT



ZeroTrace-Vault Cryptographic Lifecycle Architecture

An enterprise-grade, end-to-end zero-knowledge secret orchestration engine designed to eliminate credential sprawl in corporate communications. Built with client-side WebCrypto AES-GCM-256, RFC 3986 URL-hash key isolation, and an atomic single-view burn-on-read ephemeral engine.


🌟 Support Open Source Privacy: If you find this project valuable, please consider giving it a Star ⭐ on GitHub! It takes 1 second and motivates future cryptographic and privacy tooling.


πŸ“Œ 1. The Real-World Incident & Why This Exists

In the Uber 2022 Breach, an attacker compromised the entire corporate AWS infrastructure and VPN network simply because a DevOps engineer shared admin credentials in an internal Slack channel. The attacker ran a simple search query: search "AWS_SECRET_ACCESS_KEY" and gained root access.

Corporate chats (Slack, WhatsApp, Teams, Emails) are permanent, indexed, searchable databases. Credentials shared there remain vulnerable indefinitely.

Why Existing Tools (Pastebin/Privnote) Fail:

Most pastebins encrypt on the server side or hold plaintext credentials in memory. If the server is compromised or an admin goes rogue, all secrets are leaked.


🎯 2. The Zero-Knowledge Guarantee (RFC 3986 Anchor Isolation)

ZeroTrace-Vault guarantees that even the system owner or cloud hosting provider CANNOT read the shared secrets.

How the # Anchor Isolation Works:

  1. Alice's browser/CLI generates a 256-bit AES-GCM key locally.
  2. The secret is encrypted on the client machine.
  3. The server receives ONLY the ciphertext and 96-bit IV. The key is NEVER sent over the wire.
  4. A unique URL is generated: https://vault.domain.com/v/c0ed7d19...#knN2IeVIVu...
  5. According to RFC 3986, web browsers never transmit the hash fragment (#...) in HTTP requests. The key remains strictly in Bob's browser memory.
[ Alice Browser/CLI ] ──(AES-GCM-256 + IV)──> Ciphertext ──> [ ZeroTrace Server ] ──> [ Ephemeral RAM ]
          β”‚                                                                                 β–²
          └──────> URL: https://vault.dev/v/{UUID}#{Key}                                     β”‚
                             β”‚                                                             β”‚
  [ Bob Browser ] <──────────┴──────── (Fetch Ciphertext & Burn) β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
    (Decrypts locally using #Key)

πŸ”₯ 3. Strict Single-View Policy (Burn-on-Read)

  1. Pre-flight Crawl Protection (/api/v1/secret/:id/meta):
    Social link crawlers (Slackbot, WhatsApp, Discord) fetching link previews will NOT destroy the secret.
  2. Atomic Burn Execution (/api/v1/secret/:id/burn):
    When Bob clicks "Reveal Secret", the server retrieves the payload and instantly purges it from RAM.
  3. Second Attempt Defense:
    Any subsequent request with the same UUID immediately yields 404 Not Found.

πŸ› οΈ 4. Technology Stack

Layer Technologies Description
Cryptography Browser Native WebCrypto API (SubtleCrypto) AES-GCM-256 bit encryption, 96-bit unique IVs, 0 external crypto dependencies
Backend Core Node.js, Express.js High-throughput REST API, bounded ephemeral in-memory storage map
Security Hardening Helmet.js, Custom Sliding-Window Rate Limiter, Strict CORS Strict CSP (no unsafe-inline), Anti-Clickjacking, no-store caching, IP sliding-window rate limit (30 req/min)
Frontend UI Modern HTML5, Responsive CSS3, Vanilla JS Dark cyber glassmorphic operations console, real-time TTL burn countdown
CLI Client Node.js CLI Script (zerotrace-cli.js) Direct HTTP/HTTPS secret sharing and UNIX pipeline integration (cat file | node cli)
Containerization Docker, Docker Compose, Render Blueprint Production non-root container & 1-click render.yaml deployment

🌐 Live Demo

πŸ”— Live Website: https://zerotrace-vault.onrender.com

πŸ”— GitHub Repository: https://github.com/Atulkumar5772/ZeroTrace-Vault


πŸ“‚ 5. Project Structure

ZeroTrace-Vault/
β”œβ”€β”€ assets/
β”‚   └── zerotrace-preview.svg                    # End-to-end cryptographic architecture diagram
β”œβ”€β”€ backend/
β”‚   β”œβ”€β”€ package.json                             # Dependencies: express, helmet, cors
β”‚   └── src/
β”‚       β”œβ”€β”€ server.js                            # Daemon entry point & graceful store cleanup
β”‚       β”œβ”€β”€ routes.js                            # REST API endpoints (/create, /meta, /burn)
β”‚       β”œβ”€β”€ vaultStore.js                        # Bounded ephemeral RAM store, UUID & Base64URL validation, TTL sweeper
β”‚       └── rateLimiter.js                       # Sliding-window IP rate limiter
β”œβ”€β”€ cli/
β”‚   └── zerotrace-cli.js                         # Terminal pipe tool for developers (HTTP & HTTPS)
β”œβ”€β”€ frontend/
β”‚   └── public/
β”‚       β”œβ”€β”€ index.html                           # Web vault interface
β”‚       β”œβ”€β”€ style.css                            # Cyber glassmorphic styling
β”‚       β”œβ”€β”€ crypto.js                            # Client-side WebCrypto AES-GCM-256 implementation
β”‚       └── app.js                               # DOM handling, burn triggers, clipboard copy
β”œβ”€β”€ tests/
β”‚   └── comprehensive_test.js                   # 8/8 automated security & lifecycle verification tests
β”œβ”€β”€ docker-compose.yml                           # One-click Docker deployment
β”œβ”€β”€ Dockerfile                                   # Production Node.js container
β”œβ”€β”€ test_verification.js                         # Quick end-to-end test script
β”œβ”€β”€ LICENSE                                      # MIT License
└── README.md                                    # Comprehensive engineering documentation

πŸ’» 6. Running Locally

1. Start the Vault Server:

cd backend
npm install
npm start

Server opens at:

http://localhost:3000

2. CLI Tool Usage (Terminal / Pipes):

# Share a direct string against local server
node cli/zerotrace-cli.js "my-production-token"

# Or pipe output from any command:
cat ~/.ssh/id_rsa | node cli/zerotrace-cli.js

# Or target a remote HTTPS deployment (e.g. Render):
ZEROTRACE_URL=https://zerotrace-vault.onrender.com node cli/zerotrace-cli.js "my-production-token"

πŸ§ͺ 7. Automated Verification

Run the end-to-end cryptographic and burn test suite:

node test_verification.js

Or run the full production security & adversarial test suite (starts an isolated test server automatically or targets PORT):

node tests/comprehensive_test.js

Expected checks:

  • βœ… Backend Daemon Healthcheck & No Active-Count Leak
  • βœ… Reject Malformed / Non-Base64URL & Invalid IV/Tag Lengths
  • βœ… Reject Oversized Secret Payload (> 512 KB)
  • βœ… End-to-End Cryptographic Secret Lifecycle & Whitespace Preservation
  • βœ… Preflight Metadata Check (Preview Bot Anti-Burn Verification)
  • βœ… Atomic Burn-on-Read & 20-Way Concurrent Race Condition Test
  • βœ… Replay Attack Prevention (404 after Burn)
  • βœ… Strict CORS Rejection, X-Forwarded-For Spoof Immunity, Error Status Codes (400/413), Cache-Control: no-store, and CLI End-to-End Test

πŸ“„ License

This project is licensed under the MIT License.


πŸ‘¨β€πŸ’» Author

Atul Kumar

Computer Science Student @ PIET Jaipur (2024–2028) β€’ Red Hat Intern β€’ Salesforce Developer

Β 

About

Zero-Knowledge Ephemeral Secret Sharing Vault with Browser Native WebCrypto AES-GCM-256, RFC 3986 Anchor Isolation, and Atomic Burn-on-Read Engine.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages