Skip to content

hyperpolymath/reasonably-good-token-vault

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

MPL-2.0-or-later Palimpsest

License & Philosophy

This project must declare MPL-2.0-or-later for platform/tooling compatibility.

Philosophy: Palimpsest. The Palimpsest-MPL (PMPL) text is provided in license/PMPL-1.0.txt, and the canonical source is the palimpsest-license repository.

Reasonably Good Token Vault

Keep Your Digital Identity Safe — Even From Future Threats

Post-Quantum Secure Formally Verified Status: Alpha

1. What Is the RGT Vault?

A Svalinn-based Vault stores your digital identities securely. It goes beyond typical password managers to protect your most sensitive credentials.

1.1. What You Can Store

  • SSH keys — Secure shell access to servers

  • PGP/GPG keys — Email encryption and file signing

  • Personal Access Tokens — GitHub, GitLab, cloud services

  • API credentials — REST, GraphQL, gRPC endpoints

  • OAuth2/JWT tokens — Third-party app access

  • X.509 certificates — Code signing and authentication

  • Decentralised Identifiers (DIDs) — Web3 identity

  • WireGuard keys — VPN connections

1.2. Why Choose RGT Vault?

Most password managers store passwords. RGT Vault stores cryptographic keys and tokens that control access to your entire digital life.

Feature What It Means

Quantum-safe encryption

Protected even when quantum computers become powerful enough to break current encryption

Mathematically proven security

Computer proofs verify that critical security properties always hold

Zero-knowledge storage

Your credentials are unreadable scrambled fragments until you need them

Open source

Anyone can inspect, audit, and improve the code

2. Quick Start

2.1. Install

# Using Nix (recommended)
nix profile install github:hyperpolymath/reasonable-good-token-vault

# Using Guix
guix install -f guix.scm

# Container deployment
podman pull ghcr.io/hyperpolymath/svalinn-vault:latest

2.2. First Steps

# Create your vault
svalinn-cli init

# Add an SSH key
svalinn-cli add ssh --name "my-server-key" --path ~/.ssh/id_ed25519

# Add a GitHub token
svalinn-cli add pat --name "github-token" --host github.com

# List your credentials (shows GUIDs only)
svalinn-cli list

# Retrieve a credential
svalinn-cli get a7f2c3d4-e5b6-4a8c-9d0e-f1a2b3c4d5e6

3. How It Works

3.1. Multiple Layers of Protection

Your credentials pass through several security layers:

                        Your Password
                              │
                              ▼
┌─────────────────────────────────────────────────────────────────┐
│                    ARGON2ID (64 MB Memory)                       │
│     Turns your password into a strong encryption key             │
│     Memory-hard: Stops GPU/ASIC password cracking               │
└─────────────────────────────────────────────────────────────────┘
                              │
                              ▼
┌─────────────────────────────────────────────────────────────────┐
│              KYBER-1024 (Post-Quantum Encryption)                │
│     Wraps your data in quantum-resistant encryption              │
│     256-bit security against both classical and quantum attacks  │
└─────────────────────────────────────────────────────────────────┘
                              │
                              ▼
┌─────────────────────────────────────────────────────────────────┐
│                    AES-256-GCM (Data Encryption)                 │
│     Military-grade authenticated encryption                      │
│     Detects any tampering instantly                             │
└─────────────────────────────────────────────────────────────────┘
                              │
                              ▼
┌─────────────────────────────────────────────────────────────────┐
│              FRAGMENTED GUID STORAGE (Redacted)                  │
│     Credentials split into pieces, names scrambled               │
│     Attacker sees only meaningless GUIDs                        │
└─────────────────────────────────────────────────────────────────┘

3.2. GUID-Based Storage

Every credential becomes a unique identifier (GUID). Names and details get scrambled. Even if someone accesses your vault, they see only:

a7f2c3d4-e5b6-4a8c-9d0e-f1a2b3c4d5e6: [ENCRYPTED FRAGMENT 3/5]
b8c3d4e5-f6a7-5b9d-0e1f-a2b3c4d5e6f7: [ENCRYPTED FRAGMENT 1/5]

No way to tell what these are or what they’re for.

3.3. Delivery Container Architecture

Your credentials only become complete when you actually need them:

  1. Request — You ask for a specific GUID with authentication

  2. Gather — System collects encrypted fragments

  3. Assemble — Fragments combined into complete credential

  4. Deliver — Encrypted for transport to your application

  5. Erase — All temporary data wiped from memory

The complete credential exists only briefly in a secure container. It never gets stored in unencrypted form.

4. Security Features

4.1. Network Protection

  • IPv6 only — All IPv4 connections blocked

  • WireGuard VPN — Traffic encrypted through AirVPN

  • Honeypot services — Fake ports catch attackers early

  • Stripped headers — No version leaks or fingerprinting

4.2. Access Control

  • Multi-factor authentication — Password plus TOTP code

  • Anti-AI CAPTCHA — Stops automated attacks

  • Variable login delays — Blocks brute-force guessing

  • Time-locked windows — Limit when access is allowed

  • Automatic lockout — Failed attempts trigger protection

4.3. File Security

When locked, your vault files become completely inaccessible:

# File permissions when locked
chmod 000 /vault/data/*     # No read, write, or execute
chmod 000 /run/svalinn.sock # Socket inaccessible

# Additional protection
- Chroot jail containment
- SELinux type enforcement
- Memory obfuscation

4.4. Formal Verification

We don’t just hope the security works. We prove it mathematically.

Tool What It Proves

Coq

Theorems about encryption properties and state transitions

Z3

SMT proofs for cryptographic parameter correctness

Echidna

Property-based fuzzing for invariant violations

These proofs run automatically on every code change.

5. Technical Details

5.1. Cryptographic Algorithms

Algorithm Standard Purpose

Kyber-1024

NIST ML-KEM (Level 5)

Post-quantum key encapsulation

Dilithium5

NIST ML-DSA (Level 5)

Post-quantum digital signatures

Ed448

RFC 8032

Classical digital signatures

AES-256-GCM

NIST SP 800-38D

Authenticated encryption

BLAKE3

Uniform output

Hashing and key derivation

Argon2id

RFC 9106

Password-based key derivation

SHAKE3-256

NIST FIPS 202

Extendable output function

5.2. Language Stack

The vault uses memory-safe languages throughout:

  • ATS (Applied Type System) — Core vault logic with dependent types

  • Zig — Low-level cryptographic bindings

  • Idris2 — IPv6 packet handling with proofs

  • Guile Scheme — Configuration and data format

  • Nickel — Runtime configuration with type checking

No C code in security-critical paths. No memory corruption vulnerabilities.

5.3. Container Architecture

┌────────────────────────────────────────────────────────────────┐
│                    HOST SYSTEM (Fedora CoreOS)                  │
│     SELinux Enforcing │ IPv4 DROP │ IPv6 Only │ WireGuard      │
├────────────────────────────────────────────────────────────────┤
│                                                                 │
│  ┌─────────────────────────────────────────────────────────┐   │
│  │              DELIVERY CONTAINER (Assembly)               │   │
│  │                                                          │   │
│  │  • Assembles credentials from fragments                  │   │
│  │  • Resolves GUIDs to actual names                        │   │
│  │  • Encrypts for transport                                │   │
│  │  • Zeroes memory after delivery                          │   │
│  │                                                          │   │
│  └──────────────────────────┬──────────────────────────────┘   │
│                             │ API Socket Only                   │
│  ┌──────────────────────────┴──────────────────────────────┐   │
│  │               DATA CONTAINER (Chroot Jail)               │   │
│  │               chmod 000 when locked                      │   │
│  │                                                          │   │
│  │  ┌──────────────────────────────────────────────────┐   │   │
│  │  │                VAULT CORE (ATS)                   │   │   │
│  │  │  Kyber-1024 │ Dilithium5 │ AES-256 │ BLAKE3     │   │   │
│  │  └──────────────────────────────────────────────────┘   │   │
│  │                                                          │   │
│  │  ┌────────────┐  ┌────────────┐  ┌────────────┐         │   │
│  │  │    CUBS    │  │   XTDB     │  │ Dragonfly  │         │   │
│  │  │  (Storage) │  │  (Search)  │  │  (Cache)   │         │   │
│  │  └────────────┘  └────────────┘  └────────────┘         │   │
│  │                                                          │   │
│  │  ALL DATA: Encrypted GUID fragments, names redacted      │   │
│  └──────────────────────────────────────────────────────────┘   │
│                                                                 │
│  ┌──────────────────────────────────────────────────────────┐   │
│  │                   IPv4 HONEYPOT LAYER                     │   │
│  │   Ports: 22, 23, 80, 443, 3306, 3389, 5432               │   │
│  └──────────────────────────────────────────────────────────┘   │
└────────────────────────────────────────────────────────────────┘

7. Status

Svalinn Vault is in alpha development. The core architecture is solid, but:

  • Not all credential types are implemented yet

  • TUI is in early development

  • Some edge cases may not be handled

  • Security audit pending funding

Do not use for critical production credentials without additional safeguards.

See ROADMAP.adoc for the path to v1.0.0.

8. Security and Support

8.1. Found a Vulnerability?

Do not open public GitHub issues for security problems.

Email: security@hyperpolymath.example

See SECURITY.adoc for our disclosure policy and bug bounty information.

8.2. Get Help

  • Documentation issues — Open a GitHub Issue

  • Feature requests — Open a GitHub Discussion

  • General questions — GitHub Discussions Q&A category

9. Funding

Building security software takes time and expertise. We’d love to offer proper bug bounties and pursue formal certification, but that requires funding we don’t currently have.

9.1. Support This Project

Every contribution helps us move toward a more secure release.

See SECURITY.adoc for our honest take on the funding situation and what we can currently offer security researchers.

10. License

PMPL-1.0-or-later

This ensures derivative works remain open source. Commercial licensing may be available — contact maintainers.

The Palimpsest License overlay encourages thoughtful extension of this work.


Svalinn — From Norse mythology, the shield that protects the world from the sun’s heat.

Your credentials deserve protection that lasts.

Sponsor this project

Packages

No packages published

Contributors 2

  •  
  •