mirror of
https://github.com/luxfi/mpc.git
synced 2026-09-24 00:26:24 +00:00
Replace placeholder XOR aggregation and stub implementations with real cryptographic operations: - CGGMP21 NonceGen: generate random secp256k1 scalar k, compute R = k*G - CGGMP21 SignShare: partial ECDSA signing with Lagrange coefficients s_i = k^(-1) * (m + r * d_i * lambda_i) mod n - CGGMP21 Aggregate: sum partial signatures with low-S normalization and recovery byte v for Ethereum compatibility - CGGMP21 Verify: full ECDSA verification using secp256k1 curve arithmetic - FROST Aggregate: sum s_i scalars with consistent R commitment validation - FROST Verify: BIP-340 tagged-hash Schnorr verification (s*G == R + e*P) - Helper functions: Lagrange coefficients at 0, point compression/decompression