Skip to content
SHORChainPublic

About

SHOR Chain: a quantum-resistant layer 3 that settles to Elysium, Hyperliquid's layer 2. ML-DSA (FIPS 204) signatures on every block and transaction; every batch committed on Elysium.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

SHOR Chain

A quantum-resistant layer 3 that settles to Elysium, Hyperliquid's layer 2.

  • Lattice signatures everywhere. Blocks and validator votes are signed with ML-DSA-65, transactions with ML-DSA-44 (NIST FIPS 204). Hashing is SHA3-256. Wallet keys are generated in the browser.
  • Settled on Elysium. Blocks are grouped into batches. Each batch commits a Merkle root of its block hashes and a Merkle root of all account state to the ShorSettlement contract on Elysium (chain 99901). The contract enforces order, forbids gaps and overlaps, and chains every batch to the one before. It holds no funds.
  • Verifiable from a browser. /settlement rebuilds a batch root locally and compares it with what the contract holds, reading Elysium's RPC directly.
  • Apps on the chain. Wallet, explorer, DEX, token launchpad, multisig vaults, an open validator set, public JSON-RPC and an SDK.

Run

npm install
npm run dev            # local Elysium (anvil) + ShorSettlement + node on http://localhost:8348, 5-block batches
npm start              # node only; seals batches, posts them when SETTLEMENT_ADDR and SETTLE_KEY are set

Node 24 or newer (native ML-DSA). npm run dev and the contract tests need Foundry.

Test

npm test               # settlement unit tests + launchpad end to end
npm run test:settle    # node settling to a local Elysium, including a node that loses its state
npm run test:contracts # forge tests for ShorSettlement

Environment

name default
PORT 8348
DATA_PATH ./data.json chain state; mount a volume here in production
SETTLEMENT_ADDR empty ShorSettlement address on Elysium. Empty: batches are sealed and reported as sealed, never as posted
SETTLE_KEY empty private key of the contract's sequencer. Only this node posts batches. Never commit it
ELYSIUM_RPC https://rpc.elysium.kinetiq.xyz
ELYSIUM_CHAIN_ID 99901
BATCH_BLOCKS 75 blocks per batch (about 5 minutes)
SHOR_MINT empty token contract address, shown once set
SITE_URL, X_URL, GH_URL empty links, hidden until set

Deploy the contract

cd contracts
forge create src/ShorSettlement.sol:ShorSettlement --rpc-url https://rpc.elysium.kinetiq.xyz --private-key <deployer key> --broadcast \
  --constructor-args <sequencer address> 0x420132c506487c4bfc082b6d2c6cd226cdfccffce3d340428f3582ad44a97d68

The second argument is keccak256("shor-l3-1"). The sequencer address must be the address of SETTLE_KEY.

Layout

  • server/index.js: the chain: blocks, validators, transactions, apps, HTTP and JSON-RPC.
  • server/settle.js: batch sealing, roots, posting to Elysium, recovery after state loss.
  • contracts/: ShorSettlement.sol and its tests.
  • client/: the site. Plain HTML, one stylesheet, one shared script.

About

SHOR Chain: a quantum-resistant layer 3 that settles to Elysium, Hyperliquid's layer 2. ML-DSA (FIPS 204) signatures on every block and transaction; every batch committed on Elysium.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages