mirror of
https://github.com/luxfi/mpc.git
synced 2026-09-24 00:26:24 +00:00
ZAP is the binary protocol — like HTTP=80 and HTTPS=443, ZAP=9999
across the Lux ecosystem. The DNS name (e.g. zap.kms.svc, zap.mpc.svc,
mpc-node-headless.lux-mpc.svc) disambiguates the service; the port is
always the same.
Changes:
- mpcd --listen default :9651 → :9999
- pkg/transport/{transport,factory}.go: comments and examples
- k8s/mpc-statefulset.yaml: ports + peer template
- k8s/network-policy.yaml: ingress/egress allow rules
- cloudbuild.yaml: EXPOSE
- deployments/customer-3of5/{compose.yml,k8s/*,topology.yaml}: full
template sweep — every peer hostname is distinct, port is uniform 9999
- README.md / LLM.md: example commands
luxd validator P2P (9631 mainnet, 9641 testnet, 9651 devnet) is a
DIFFERENT protocol on a DIFFERENT pod and is unchanged.
135 lines
4.7 KiB
YAML
135 lines
4.7 KiB
YAML
# 3-of-5 Threshold Topology: Customer + Lux
|
|
#
|
|
# Topology:
|
|
# Lux: 3 nodes (lux-0, lux-1, lux-2) -- operated by Lux
|
|
# Customer: 2 nodes (cust-0, cust-1) -- operated by Customer
|
|
# Threshold: 3 (any 3 nodes produce a valid signature)
|
|
#
|
|
# Security properties:
|
|
# - Customer alone (2 nodes) CANNOT sign. Prevents rogue customer transactions.
|
|
# - Lux alone (3 nodes) CAN sign. Required for operational/bridge/emergency use.
|
|
# - Customer + 1 Lux node (3 nodes) CAN sign. Normal DAO governance flow.
|
|
# - Single node compromise: attacker has 1 share, needs 2 more. No risk.
|
|
# - Two node compromise (worst case): attacker needs 1 more. Still safe if
|
|
# compromised nodes are on the same side (customer or lux).
|
|
#
|
|
# Trust model:
|
|
# Lux holds signing majority. This is intentional for bridge/operational keys.
|
|
# For DAO governance keys where customer must co-approve, use Safe multisig
|
|
# on-chain (see safe-integration.md) to enforce customer participation even
|
|
# when Lux holds threshold majority.
|
|
#
|
|
# Network topology:
|
|
# Lux nodes run in lux-k8s cluster (lux-mpc-customer namespace).
|
|
# Customer nodes run in customer's own infrastructure.
|
|
# ZAP transport connects all 5 nodes over TLS (mTLS via Ed25519 identity keys).
|
|
# Customer nodes connect to Lux nodes via public endpoint (mpc-customer.lux.network).
|
|
#
|
|
# Key types generated:
|
|
# - ECDSA (secp256k1): Bitcoin, Ethereum/EVM, Lux C/X/P chains
|
|
# - EdDSA (Ed25519): Solana, TON, Polkadot (via FROST)
|
|
# - FROST (secp256k1): Bitcoin Taproot, Safe on-chain verification
|
|
|
|
topology:
|
|
name: "customer-3of5"
|
|
threshold: 3
|
|
total_nodes: 5
|
|
|
|
nodes:
|
|
- id: "lux-0"
|
|
operator: "lux"
|
|
p2p_port: 9999
|
|
api_port: 9800
|
|
data_dir: "/data/mpc/lux-0"
|
|
|
|
- id: "lux-1"
|
|
operator: "lux"
|
|
p2p_port: 9999
|
|
api_port: 9801
|
|
data_dir: "/data/mpc/lux-1"
|
|
|
|
- id: "lux-2"
|
|
operator: "lux"
|
|
p2p_port: 9999
|
|
api_port: 9802
|
|
data_dir: "/data/mpc/lux-2"
|
|
|
|
- id: "cust-0"
|
|
operator: "customer"
|
|
p2p_port: 9999
|
|
api_port: 9800
|
|
data_dir: "/data/mpc/cust-0"
|
|
|
|
- id: "cust-1"
|
|
operator: "customer"
|
|
p2p_port: 9999
|
|
api_port: 9801
|
|
data_dir: "/data/mpc/cust-1"
|
|
|
|
protocols:
|
|
ecdsa:
|
|
curve: "secp256k1"
|
|
protocol: "CGGMP21"
|
|
chains:
|
|
- { network: "BTC", name: "Bitcoin (Legacy/SegWit)" }
|
|
- { network: "ETH", name: "Ethereum + all EVM chains" }
|
|
- { network: "LUX", name: "Lux C/X/P chains" }
|
|
- { network: "XRPL", name: "XRP Ledger" }
|
|
notes: "Also supports LSS protocol for dynamic resharing"
|
|
|
|
eddsa:
|
|
curve: "ed25519"
|
|
protocol: "FROST"
|
|
chains:
|
|
- { network: "SOL", name: "Solana" }
|
|
- { network: "TON", name: "TON" }
|
|
notes: "FROST Taproot mode produces BIP-340 compatible signatures"
|
|
|
|
sr25519:
|
|
curve: "ristretto255"
|
|
protocol: "FROST"
|
|
chains:
|
|
- { network: "DOT", name: "Polkadot" }
|
|
- { network: "KSM", name: "Kusama" }
|
|
notes: "Schnorrkel/Ristretto255 via generic FROST over ristretto255 group"
|
|
|
|
bls:
|
|
curve: "bls12-381"
|
|
protocol: "BLS-Threshold"
|
|
chains:
|
|
- { network: "LUX", name: "Lux consensus (validator signing)" }
|
|
- { network: "ETH", name: "Ethereum beacon chain" }
|
|
notes: "Aggregatable threshold signatures for consensus"
|
|
|
|
frost_taproot:
|
|
curve: "secp256k1"
|
|
protocol: "FROST"
|
|
chains:
|
|
- { network: "BTC", name: "Bitcoin Taproot (BIP-340/341)" }
|
|
safe_verifiable: true
|
|
notes: "On-chain FROST.sol verification via ecrecover trick"
|
|
|
|
lss:
|
|
curve: "secp256k1"
|
|
protocol: "LSS"
|
|
chains:
|
|
- { network: "BTC", name: "Bitcoin (dynamic resharing)" }
|
|
- { network: "ETH", name: "Ethereum (dynamic resharing)" }
|
|
notes: "Supports t/n changes without key regeneration"
|
|
|
|
# DKG generates keys for ALL protocols in a single ceremony.
|
|
# Each wallet gets: ECDSA + EdDSA + SR25519 + BLS key shares.
|
|
# Protocol selection is automatic based on target chain (see GetNetworkKeyType).
|
|
#
|
|
# Chain → Protocol mapping:
|
|
# BTC (legacy/segwit) → CGGMP21 (secp256k1)
|
|
# BTC (taproot) → FROST (secp256k1, BIP-340)
|
|
# ETH / all EVM → CGGMP21 (secp256k1)
|
|
# LUX C/X/P → CGGMP21 (secp256k1)
|
|
# LUX consensus → BLS-Threshold (bls12-381)
|
|
# SOL → FROST (ed25519)
|
|
# TON → FROST (ed25519)
|
|
# XRPL → CGGMP21 (secp256k1)
|
|
# DOT / KSM → FROST (ristretto255/sr25519)
|
|
# Any + resharing → LSS (secp256k1)
|