Skip to content

About

Post-quantum cryptography SDK

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

QuantSec SDK

Quantum Security Software Development Kit - Post-quantum cryptography SDK for hybrid security in production systems.

License Rust

What is QuantSec?

QuantSec SDK is a post-quantum cryptography SDK designed for gradual migration in real-world systems.

The Problem It Solves

Quantum computers threaten current cryptography. When quantum computers become practical, algorithms like RSA, ECDSA, and ECDH will be broken. QuantSec provides:

  • ✅ Hybrid signatures (Ed25519 + Dilithium3) - works today, secure tomorrow
  • ✅ Post-quantum key exchange (X25519 + Kyber768) - quantum-resistant channels
  • ✅ Identity management - versioned, rotatable, revocable identities
  • ✅ Optional Blockchain anchoring - public trust anchor for identity verification
  • ✅ Multi-language support - Node.js, Python, Go, Rust

How It Works

QuantSec adds a security layer to your application:

Your Application
    ↓
QuantSec SDK (Security Layer)
    ↓
Your Existing Infrastructure

No architectural rewrites required. QuantSec integrates as a security layer.

Quick Start

1. Install (Rust)

git clone https://github.com/quantsec/quantsec-sdk
cd quantsec-sdk
cargo build --release

2. Use in Your Code

use quantsec_sdk::core::*;

fn main() -> Result<(), CryptoError> {
    let identity = Identity::generate(CryptoPolicy::default());

    let message = b"Hello, Quantum World!";
    let signature = identity.sign(message)?;

    assert!(identity.verify(message, &signature));

    Ok(())
}

3. Integrate with Your System

See QUICKSTART.md for 5-minute integration guide.

Architecture

QuantSec SDK is built in layers:

┌─────────────────────────────────────────┐
│  Language Bindings (Node.js/Python/Go)  │
└──────────────┬──────────────────────────┘
               │
┌──────────────▼──────────────────────────┐
│  C-ABI Interface (FFI)                  │
└──────────────┬──────────────────────────┘
               │
┌──────────────▼──────────────────────────┐
│  Core SDK (Rust)                        │
│  - Identity Management                  │
│  - Hybrid Signatures                     │
│  - Secure Channels                      │
└──────────────┬──────────────────────────┘
               │
┌──────────────▼──────────────────────────┐
│  Cryptographic Implementations          │
│  - Ed25519 (Classical)                  │
│  - Dilithium3 (Post-Quantum)           │
│  - Kyber768 (Post-Quantum KEM)         │
└─────────────────────────────────────────┘

Key Principle: All cryptography happens in the Rust core. Bindings are thin wrappers. Bindings contain no cryptographic logic and cannot weaken security guarantees.

Features

🔐 Hybrid Cryptography

  • Classical: Ed25519 signatures, X25519 key exchange
  • Post-Quantum: Dilithium3 signatures, Kyber768 KEM
  • Combined: Both must verify for security

🆔 Identity Management

  • Generate, load, export identities
  • Key rotation with version tracking
  • Public identity descriptors
  • Blockchain anchoring (optional)

🔒 Secure Channels

  • Hybrid key exchange (ECDH + Kyber)
  • AES-256-GCM authenticated encryption
  • Automatic key derivation (HKDF)

🌐 Multi-Language Support

  • Rust: Native API
  • Node.js: N-API binding
  • Python: pybind11 binding
  • Go: cgo binding

⛓️ Optional Blockchain Integration

  • Smart contract registry (EVM)
  • Identity anchoring
  • Rotation tracking
  • Revocation management

Documentation

Installation

Rust

cargo add quantsec-sdk

Node.js

cd bindings/nodejs
npm install
npm run build

Python

cd bindings/python
pip install -e .

Go

import "github.com/quantsec/quantsec-sdk/bindings/go"

Usage Examples

Sign and Verify

let identity = Identity::generate(CryptoPolicy::default());
let message = b"Important message";
let signature = identity.sign(message)?;
assert!(identity.verify(message, &signature));

Secure Channel

let channel = SecureChannel::establish(local_identity, remote_public)?;
let ciphertext = channel.encrypt(b"Secret data");

let plaintext = channel
    .decrypt(&ciphertext)
    .expect("decryption failed");
assert_eq!(plaintext, b"Secret data");

Blockchain Registration

const helper = new QuantSecRegistryHelper(contract);
await helper.registerIdentity(identity, signer);
const status = await helper.isIdentityActive(identity);

See examples/ for complete examples.

Security

  • ✅ Hybrid security: Classical + post-quantum algorithms
  • ✅ No private keys on-chain: Only public descriptors
  • ✅ Auditable: Event-based monitoring
  • ✅ Versioned: Track key rotations
  • ✅ Revocable: One-way revocation

Non-Goals

  • ❌ On-chain cryptography
  • ❌ Privacy-preserving anonymity
  • ❌ Replacement for TLS (yet)

See THREAT_MODEL.md for detailed security analysis.

Approximate Performance (development benchmarks)

  • Signature size: ~3.3 KB (64 + 3293 bytes)
  • Key generation: < 100ms
  • Signing: < 10ms
  • Verification: < 20ms
  • Key exchange: < 50ms

Performance varies by platform and is subject to change.

License

Licensed under either of:

at your option.

Contributing

Contributions are welcome! Please see CONTRIBUTING.md for guidelines.

Release Status: v0.1.0-alpha

⚠️ IMPORTANT: This is an alpha release. Use with caution.

What "Alpha" Means

  • API Stability: The public API is not stable and may change in future releases
  • Security Audit: This version has not undergone formal security audit
  • Production Use: Not recommended for production-critical applications without security audit
  • Key Storage: Private keys are exported in plaintext (see SECURITY.md for details)

What Works

  • ✅ Core cryptography implemented (Ed25519, Dilithium3, Kyber768)
  • ✅ Multi-language bindings (Node.js, Python, Go)
  • ✅ Blockchain integration (EVM smart contracts)
  • ✅ Identity management with key rotation
  • ✅ Secure channels with hybrid key exchange

What to Expect

  • Breaking Changes: API may change before v1.0.0
  • Bug Fixes: Critical bugs will be fixed in patch releases
  • Documentation: Documentation is being improved continuously
  • Security: Formal security audit planned before v1.0.0

Reporting Issues

For more details, see RELEASE.md.

Support

Acknowledgments

  • NIST Post-Quantum Cryptography Standardization
  • Open Quantum Safe project
  • Rust cryptography community

QuantSec SDK - Hybrid quantum-resistant security for today's applications.

About

Post-quantum cryptography SDK

Resources

Contributing

Security policy

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages