Skip to content

thenervelab/hippius-sync-engine

Repository files navigation

Hippius Sync Engine

End-to-end encrypted file synchronization. The server never sees plaintext.

Architecture

┌─────────────────────────────────────────────────────────────────┐
│                     Sync Engine Client                            │
│  ┌─────────────┐   ┌─────────────┐   ┌─────────────────────┐   │
│  │   BIP-39    │   │   Ed25519   │   │  XChaCha20-Poly1305 │   │
│  │  Mnemonic   │   │  Signatures │   │     Encryption      │   │
│  └─────────────┘   └─────────────┘   └─────────────────────┘   │
│                              │                                   │
│                    ┌─────────▼─────────┐                        │
│                    │   Three-Tree      │                        │
│                    │   Sync Engine     │                        │
│                    └─────────┬─────────┘                        │
└──────────────────────────────┼──────────────────────────────────┘
                               │ HTTP (ciphertext only)
                               ▼
┌──────────────────────────────────────────────────────────────────┐
│                     Sync Engine Server                            │
│  ┌─────────────┐   ┌─────────────┐   ┌─────────────────────┐   │
│  │   Sled DB   │   │  REST API   │   │   Arion Storage     │   │
│  │  (metadata) │   │  (axum)     │   │   (distributed)     │   │
│  └─────────────┘   └─────────────┘   └─────────────────────┘   │
└──────────────────────────────────────────────────────────────────┘

Workspace Crates

Crate Description README
hippius-sync-server HTTP REST API server README
hippius-sync-client Core sync engine library README
hippius-sync-client-cli Command-line interface README
hippius-sync-shared Shared types and utilities README

Quick Start

Build

cargo build --release

Run Server

# Set required environment variables
export HIPPIUS_DATABASE_PATH=./hippius_sync_data
export HIPPIUS_SERVER_API_KEY=your-api-key
export ARION_URL=http://storage.example.com:3000
export ARION_API_KEY=your-arion-key

cargo run -p hippius-sync-server --release

Run CLI

# Initialize a new encrypted drive
cargo run -p hippius-sync-client-cli -- init

# Configure server connection
cargo run -p hippius-sync-client-cli -- config \
  --server-url https://server.example.com:9999 \
  --api-key your-api-key \
  --bearer-token your-user-token

# Preview pending changes
cargo run -p hippius-sync-client-cli -- stage

# Sync with server
cargo run -p hippius-sync-client-cli -- sync

Security Model

  • BIP-39: 24-word mnemonic for key recovery
  • Ed25519: Digital signatures for manifest authenticity
  • XChaCha20-Poly1305: File and path encryption
  • AES-256-GCM: Encrypted mnemonic storage (PBKDF2-derived key)
  • SHA-256: Content hashing with user-salted deduplication

Testing

cargo test --all           # Run all tests
cargo clippy --all         # Linting

License

See LICENSE for details.

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors