mirror of
https://github.com/luxfi/mpc.git
synced 2026-09-24 00:26:24 +00:00
Adds threshold-signing transport so KMS can use mpcd as MPC backend. Reuses ML-KEM-768 hybrid handshake from luxfi/kms/pkg/zap (#55) by vendoring the same construction into mpc/pkg/zap — wire constants (opcodes 0x00F0/0x00F1, HKDF info "kms/zap/v1/session", direction tags) stay in lockstep with KMS. New surface: - pkg/zap: vendored handshake + session (forward-only convergent) - pkg/api/zap_kms_server.go: KMS-facing ZAP node (opcodes 0x0001/0x0010/0x0011/0x0012/0x0020) wired onto MPCBackend - cmd/mpcd: --kms-zap-listen flag (default :9970), enabled out of the box; default-disable by passing empty string Existing pkg/api/zap_server.go (dashboard event bus, opcodes 0x0060+) is unchanged — different consumer, different port. Closes the secrets-only mode gap on mainnet (#70).