T-Chain - Core Threshold Signature Specification
Core specification for the T-Chain (Threshold VM), providing distributed key generation and threshold signatures
Abstract
LP-7000 specifies the T-Chain (Threshold Signature Chain), Lux Network's specialized blockchain providing Multi-Party Computation (MPC) services including distributed key generation (DKG), threshold signatures, and secure key management. The T-Chain implements CGGMP21 for ECDSA, FROST for Schnorr/BLS, and Ringtail for post-quantum signatures.
Motivation
A dedicated threshold signature chain provides:
- Trustless Custody: Distribute key control across multiple parties
- Bridge Security: Enable MPC-secured cross-chain bridges
- Key Recovery: Support threshold-based key recovery
- Regulatory Compliance: Meet institutional custody requirements
Specification
Chain Parameters
| Parameter | Value |
|---|---|
| Chain ID | T |
| VM ID | thresholdvm |
| VM Name | thresholdvm |
| Block Time | 2 seconds |
| Consensus | Quasar |
Implementation
Go Package: github.com/luxfi/node/vms/thresholdvm
import (
tvm "github.com/luxfi/node/vms/thresholdvm"
"github.com/luxfi/node/utils/constants"
)
// VM ID constant
var ThresholdVMID = constants.ThresholdVMID // ids.ID{'t', 'h', 'r', 'e', 's', 'h', 'o', 'l', 'd', 'v', 'm'}
// Create T-Chain VM
factory := &tvm.Factory{}
vm, err := factory.New(logger)
Directory Structure
node/vms/thresholdvm/
├── cggmp/ # CGGMP21 implementation
├── frost/ # FROST signatures
├── ringtail/ # Post-quantum threshold
├── dkg/ # Distributed key generation
├── keygen/ # Key generation ceremonies
├── warp/ # Warp message integration
├── factory.go # VM factory
├── vm.go # Main VM implementation
└── *_test.go # Tests
Supported Protocols
CGGMP21 - Threshold ECDSA
UC-secure non-interactive threshold ECDSA based on IACR 2021/060:
import "github.com/luxfi/node/vms/thresholdvm/cggmp"
// Initialize CGGMP session
session := cggmp.NewSession(threshold, totalParties)
// Distributed Key Generation
keyShare, err := session.DKG(partyID, otherParties)
// Sign message
partialSig, err := session.Sign(keyShare, message)
// Combine signatures
fullSig, err := session.CombineSignatures(partialSigs)
FROST - Threshold Schnorr/BLS
Flexible Round-Optimized Schnorr Threshold signatures:
import "github.com/luxfi/node/vms/thresholdvm/frost"
// Initialize FROST session
session := frost.NewSession(threshold, totalParties)
// Key generation
keyShare, err := session.KeyGen(partyID)
// Sign with BLS
partialSig, err := session.SignBLS(keyShare, message)
// Sign with Schnorr
partialSig, err := session.SignSchnorr(keyShare, message)
Ringtail - Post-Quantum Threshold
Ring-based threshold signatures for quantum resistance:
import "github.com/luxfi/node/vms/thresholdvm/ringtail"
// Initialize Ringtail session
session := ringtail.NewSession(threshold, totalParties)
// Quantum-safe threshold key generation
keyShare, err := session.KeyGen(partyID)
// Sign with post-quantum security
partialSig, err := session.Sign(keyShare, message)
Key Management
Key Share Types
type KeyShare struct {
ID ids.ID `json:"id"`
PartyID uint32 `json:"partyId"`
Threshold uint32 `json:"threshold"`
TotalParties uint32 `json:"totalParties"`
PublicKey []byte `json:"publicKey"`
SecretShare []byte `json:"secretShare"` // Encrypted
Protocol Protocol `json:"protocol"`
}
type Protocol uint8
const (
ProtocolCGGMP21 Protocol = iota
ProtocolFROST
ProtocolRingtail
)
Key Ceremonies
| Ceremony | Description |
|---|---|
| DKG | Generate new threshold key |
| Resharing | Change threshold or add/remove parties |
| Refresh | Rotate shares without changing public key |
Transaction Types
| Type | Description |
|---|---|
InitDKG | Initialize distributed key generation |
SubmitShare | Submit key share commitment |
RevealShare | Reveal key share |
RequestSignature | Request threshold signature |
SubmitPartialSig | Submit partial signature |
RotateKey | Initiate key rotation |
ReshareKey | Change threshold parameters |
Threshold Parameters
| Config | Threshold (t) | Parties (n) | Security |
|---|---|---|---|
| 2-of-3 | 2 | 3 | Basic |
| 3-of-5 | 3 | 5 | Standard |
| 5-of-9 | 5 | 9 | High |
| 7-of-11 | 7 | 11 | Enterprise |
Warp Message Integration
import "github.com/luxfi/node/vms/thresholdvm/warp"
// Create Warp message with threshold signature
warpMsg, err := warp.CreateMessage(
sourceChainID,
destChainID,
payload,
)
// Sign with threshold key
signedMsg, err := tvm.ThresholdSignWarp(warpMsg, keyID)
// Verify threshold-signed Warp message
valid, err := tvm.VerifyThresholdWarp(signedMsg)
Bridge Integration
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ B-Chain │────▶│ T-Chain │────▶│ External │
│ (Bridge) │ │ (Threshold) │ │ Chain │
└─────────────┘ └─────────────┘ └─────────────┘
│ │ │
│ Lock Request │ │
│──────────────────▶│ │
│ │ │
│ │ Threshold Sign │
│ │──────────────────▶│
│ │ │
│ Signature OK │ │
│◀──────────────────│ │
API Endpoints
RPC Methods
| Method | Description |
|---|---|
threshold.initDKG | Start key generation ceremony |
threshold.getKeyInfo | Get threshold key information |
threshold.requestSign | Request threshold signature |
threshold.getSignature | Get completed signature |
threshold.reshare | Initiate key resharing |
REST Endpoints
POST /ext/bc/T/threshold/dkg/init
GET /ext/bc/T/threshold/keys/{keyId}
POST /ext/bc/T/threshold/sign
GET /ext/bc/T/threshold/signature/{sigId}
POST /ext/bc/T/threshold/reshare
Configuration
{
"thresholdvm": {
"defaultThreshold": 2,
"defaultParties": 3,
"defaultProtocol": "CGGMP21",
"keyRotationInterval": "24h",
"signatureTimeout": "30s",
"maxPendingSignatures": 1000,
"enableRingtail": true
}
}
Security Properties
- Unforgeability: t parties required to sign
- Key Secrecy: < t parties learn nothing about key
- Robustness: Signing succeeds with any t honest parties
- Proactive Security: Regular share refresh
Performance
| Operation | Time | Notes |
|---|---|---|
| DKG (3-of-5) | 500ms | One-time setup |
| CGGMP21 Sign | 100ms | Per signature |
| FROST Sign | 50ms | Per signature |
| Ringtail Sign | 200ms | Post-quantum |
| Warp Sign | 150ms | Including serialization |
Rationale
Design decisions for T-Chain:
- Multiple Protocols: Different use cases need different security/performance tradeoffs
- Warp Integration: Native cross-chain messaging support
- Proactive Security: Regular refresh prevents compromise accumulation
- Quantum Bridge: Ringtail provides migration path to PQ security
Backwards Compatibility
LP-7000 supersedes LP-0083. Both old and new numbers resolve to this document.
Test Cases
See github.com/luxfi/node/vms/thresholdvm/*_test.go:
func TestThresholdVMStats(t *testing.T)
func TestEncryptedWarpThroughThreshold(t *testing.T)
func TestRingtailProtocolForWarp(t *testing.T)
func TestWarpMessageHashForSigning(t *testing.T)
func TestThresholdConfigDefaults(t *testing.T)
func TestKeyShareInterface(t *testing.T)
func TestDKGCeremony(t *testing.T)
func TestCGGMP21Signing(t *testing.T)
func TestFROSTSigning(t *testing.T)
Reference Implementation
Repository: github.com/luxfi/node
Package: vms/thresholdvm
Dependencies:
vms/thresholdvm/cggmpvms/thresholdvm/frostvms/thresholdvm/ringtailvms/thresholdvm/dkg
Security Considerations
- Share Storage: Key shares must be encrypted at rest
- Communication Security: All MPC communication over TLS 1.3
- Party Authentication: Strong identity verification for ceremonies
- Timeout Handling: Proper cleanup of incomplete ceremonies
- Audit Logging: Full audit trail of all signing operations
Related LPs
| LP | Title | Relationship |
|---|---|---|
| LP-0083 | T-Chain Specification | Superseded by this LP |
| LP-7100 | CGGMP21 ECDSA | Sub-specification |
| LP-7200 | FROST Schnorr/BLS | Sub-specification |
| LP-7300 | Ringtail PQ | Sub-specification |
| LP-7400 | DKG Ceremonies | Sub-specification |
| LP-6000 | B-Chain | Uses T-Chain for bridge custody |
Copyright
Copyright and related rights waived via CC0.