mirror of
https://github.com/luxfi/chains.git
synced 2026-09-24 00:26:00 +00:00
d682216d8c36e532e84518e56b405f4e6dbcdb2a
Kills node/vms/pcodecs from the M-Chain (MPC custody VM) — the LAST of the three app-chain VMs blocking pcodecs deletion. bridgevm + zkvm already native. Codec kill (wire.go): the legacy pcodecs LinearCodec keyed on serialize:"true" tags; every mpcvm type carries only json: tags, so the old codec marshaled ZERO fields — a Block round-tripped to all-zero and every block ID collided at sha256(0x0000). This is a latent corruption bug the native wire FIXES. wire.go owns Marshal/parse for Block (nested []*Operation as u32-length-list + concat sub-object blob), ManagedKey (PartyIDs []party.ID as packed string list; CreatedAt/LastUsedAt as UnixNano; Config/CMPConfig json:"-" excluded), CrossChainMPCRequest, Operation. Block.ID_ is derived (computeID=sha256(Marshal)) so it is excluded from wire; recomputed on ParseBlock, set from DB key on getBlock. ThresholdConfig (init.Config) + Genesis stay JSON at the boundary. Deleted mpcvm/codec.go; swapped 9 call sites. Parse rejects trailing bytes. Round-trips green (Operation/Block/ManagedKey/CrossChainMPCRequest incl empty-ops nil-slice). Threshold signing (sign_distributed.go + transport/attest_bridge): CGGMP21/CMP threshold-ECDSA ceremony across the M committee over native app-gossip; each validator runs its own executor + per-session gossipRouter; honest signers derive the SAME standard secp256k1 signature. B→M attestation seam is domain-bound and replay-safe. Tests: transport-free seam (bridge_seam_test) + full 3-validator in-process fabric driving the real Broadcast→Gossip→router.Deliver path (bridge_transport_test). 3 of 3 chains VMs native. chains repo now has ZERO pcodecs imports. Co-authored-by: Hanzo Dev <[email protected]>
Lux Chains
Independent VM plugin binaries for the Lux Network.
Each directory builds to a standalone binary that the Lux node loads as a plugin via --plugin-dir.
Build
make # build all VMs
make evm # build one VM
make test # test all
Install
lpm install evm
lpm install dexvm
Or copy binaries to ~/.lux/plugins/<vmid>.
VMs
| VM | Chain | Purpose |
|---|---|---|
| evm | C-Chain | EVM smart contracts |
| dexvm | D-Chain | Decentralized exchange |
| aivm | A-Chain | AI/ML inference |
| bridgevm | B-Chain | Cross-chain bridge |
| graphvm | G-Chain | GraphQL data layer |
| identityvm | I-Chain | Decentralized identity |
| keyvm | K-Chain | Key management |
| oraclevm | O-Chain | Oracle/off-chain data |
| quantumvm | Q-Chain | Post-quantum consensus signing (Pulsar) |
| relayvm | R-Chain | Cross-chain relay |
| servicenodevm | S-Chain | Service node registry |
| teleportvm | T-Chain | Unified teleport (bridge + relay + oracle) |
| mpcvm (MPC) | M-Chain | MPC ceremonies (CGGMP21, FROST, Pulsar-general) — bridge custody for external wallets |
| mpcvm (FHE) | F-Chain | FHE compute + TFHE bootstrap-key generation (encrypted EVM) |
| zkvm | Z-Chain | Groth16 over BLS12-381 (rolls N × ML-DSA-65 sigs into 192-byte proof) |
Languages
Go
98.2%
C
1.7%
Shell
0.1%