Skip to content
 
 

Latest commit

 

History

1 Commit

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

boost-ipfs

Quantum-secure entity state system on IPFS.

What it does

  • Entities write encrypted state blobs stored on IPFS
  • Per-entity encryption — only authorized subscribers can decrypt
  • Full history — state forms a linked chain (prev_cid), walkable from any point
  • Quantum-secure — CRYSTALS-Kyber (ML-KEM) for key encapsulation, CRYSTALS-Dilithium (ML-DSA) for signatures, AES-256-GCM for symmetric encryption

How it works

Entity writes state
  → generate random AES-256 key
  → encrypt blob with AES-GCM
  → for each authorized reader: encapsulate AES key with their Kyber public key
  → sign entire record with Dilithium
  → publish to IPFS → get CID
  → notify subscribers

Entity reads state (given CID)
  → fetch record from IPFS
  → verify Dilithium signature
  → find own encapsulated key
  → decapsulate with Kyber secret key → recover AES key
  → decrypt blob

Setup

Prerequisites

Install liboqs (the C library):

# macOS
brew install liboqs

# Ubuntu/Debian
sudo apt install liboqs-dev

For real IPFS storage (optional — LocalStore works for testing):

brew install ipfs   # or https://docs.ipfs.tech/install/
ipfs init
ipfs daemon

Install

pip install -r requirements.txt

Quick start

from boostipfs import Entity, Network, LocalStore

store = LocalStore()  # or IPFSStore("http://127.0.0.1:5001")
net = Network(store)

alice = Entity("alice", net)
bob = Entity("bob", net)

bob.authorize(alice)
alice.subscribe(bob, callback=lambda cid: print(f"new: {cid}"))

cid = bob.write(b"hello world")
print(alice.read(cid))           # b"hello world"
print(alice.read_history(cid))   # [b"hello world"]

Run the demo

python demo.py

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages