MPC Protocols
ECDSA Signatures
In order to use ECDSA, you need to enable one of the following protocols.
DKLS23
DKLS23 is a state-of-the-art MPC protocol for computing ECDSA keys and signatures based on the research paper https://eprint.iacr.org/2023/765. The values below are used as default. So you only need to have [DKLS23.Features] in your config where you set to true the operations that you need, such as GenerateKey and Sign.
TOML
[DKLS23]
MinChainPathLength = 0
Bip32CacheSize = 1024
PresigGenRequestLimit = 100
PresigGenGlobalLimit = 5000
DeactivatedPlayersCache = "inMemory"
[DKLS23.Features]
GenerateKey = false
GeneratePresignatures = false
Sign = false
SignWithPresignature = false
GenerateRecoveryData = false
PublicKey = false
ChainCode = false
Reshare = false
CopyKey = false
ExportKeyShare = false
ImportKeyShare = false
ExportKey = false
ImportKey = false
BIP32GenerateSeed = false
BIP32DeriveFromSeed = false
BIP32DeriveFromKey = false
BIP32ConvertKey = false
BIP32ExportSeed = false
BIP32ImportSeed = false
BIP32Info = false
Upgrading from DKLS19 to DKLS23
If you already use the DKLS19 protocol, you can upgrade to the faster DKLS23 protocol. Note, however, that DKLS23 only works with recent versions of the SDK, so if you use older versions of the SDK, you may have to upgrade these as well. In addition, it's not possible to use DKLS23 with our legacy SDK (SDKv1).
You can upgrade from DKLS19 to DKLS23 with these steps:
- Change
[DKLS19]to[DKLS23]in the MPC node configuration files. - Run a key reshare operation for each of your existing keys that were generated with DKLS19.
- Delete any existing presignatures that were generated with the DKLS19 protocol.
- You can restore key share backups from DKLS19 after switching to the DKLS23 protocol.
📘
Deprecation of DKLS19
DKLS19 is included in v70 LTS and will as such be supported until at least 2027-03-01. But it will not be part of future LTS versions.
Deactivated Players
Builder Vault applies a certain optimization to the DKLS23 protocol. As a consequence of this, a malicious MPC node may try to deviate from the correct protocol execution in a certain way. This will be detected by the current MPC node and does no harm, as long as the current node refuses to run too many signing operations with the other node.
The MPC node will rarely need to deactivate other MPC nodes. This only happens if the other MPC node deliberately tries to cheat. In the rare cases where this occur, you need to consider the fact that you are under attack, and take appropriate action.
The deactivated player cache normally lives in the memory of your MPC node. If you use a setup with horizontal scaling, where your MPC node is replicated among several instances, a malicious node may be able to cause one signing session to abort on each instance. To prevent this, you must set DeactivatedPlayersCache = "database" if you have more than five instances of your MPC node running in a replicated setup.
DKLS19
The DKLS19 protocol also computes ECDSA signatures. This protocol is based on the research paper https://eprint.iacr.org/2019/523.
TOML
[DKLS19]
MinChainPathLength = 0
Bip32CacheSize = 1024
PresigGenRequestLimit = 100
PresigGenGlobalLimit = 5000
[DKLS19.Features]
GenerateKey = false
GeneratePresignatures = false
Sign = false
SignWithPresignature = false
GenerateRecoveryData = false
PublicKey = false
ChainCode = false
Reshare = false
CopyKey = false
ExportKeyShare = false
ImportKeyShare = false
ExportKey = false
ImportKey = false
BIP32GenerateSeed = false
BIP32DeriveFromSeed = false
BIP32DeriveFromKey = false
BIP32ConvertKey = false
BIP32ExportSeed = false
BIP32ImportSeed = false
BIP32Info = false
SEPH18S
As an alternative to DKLS19 and DKLS23, you can use SEPH18S which is based on the research paper https://eprint.iacr.org/2020/501.
TOML
[SEPH18S]
MinChainPathLength = 0
Bip32CacheSize = 1024
PresigGenRequestLimit = 1000
PresigGenGlobalLimit = 50000
[SEPH18S.Features]
GenerateKey = false
GeneratePresignatures = false
Sign = false
SignWithPresignature = false
GenerateRecoveryData = false
PublicKey = false
ChainCode = false
Reshare = false
CopyKey = false
ExportKeyShare = false
ImportKeyShare = false
ExportKey = false
ImportKey = false
BIP32GenerateSeed = false
BIP32DeriveFromSeed = false
BIP32DeriveFromKey = false
BIP32ConvertKey = false
BIP32ExportSeed = false
BIP32ImportSeed = false
BIP32Info = false
Schnorr Signatures
To do Ed25519, Ed448, BIP340 or other Schnorr-based signatures, as used by Mina, Zilliqa, and Polkadot, you need to enable the SEPD19S MPC protocol:
TOML
[SEPD19S]
MinChainPathLength = 0
PresigGenRequestLimit = 1000
PresigGenGlobalLimit = 100000
[SEPD19S.Features]
GenerateKey = false
GeneratePresignatures = false
Sign = false
SignWithPresignature = false
GenerateRecoveryData = false
PublicKey = false
ChainCode = false
Reshare = false
CopyKey = false
ExportKeyShare = false
ImportKeyShare = false
ExportKey = false
ImportKey = false
RSA
To enable RSA encryption and signing:
TOML
[ADN06]
[ADN06.Features]
PublicKey = false
SignPKCS1v15 = false
SignPSS = false
Decrypt = false
ExportKey = false
ImportKey = false
ECDH
The SEPD20ECDSA protocol is an MPC protocol that computes the ECDH function. This protocol can operate with any t+1 of the MPC nodes.
TOML
[SEPD20ECDH.Features]
GenerateKey = false
ComputeSecret = false
PublicKey = false
AES and HMAC
To use Builder Vault for various AES operations (AES-GCM, AES-CBC, etc.) as well as HMAC, you will need to enable one of the following general-purpose MPC protocols.
MRZ15
The MRZ15 protocol is a general-purpose MPC protocol that works for three players and security threshold t = 1, based on the research paper https://eprint.iacr.org/2015/931.
TOML
[MRZ15.AESFeatures]
GenerateKey = false
ExportKey = false
ImportKey = false
CTRKeyStream = false
CBCEncrypt = false
CBCDecrypt = false
GCMEncrypt = false
GCMDecrypt = false
CMAC = false
[MRZ15.HMACFeatures]
GenerateKey = false
ExportKey = false
ImportKey = false
HMACSHA256 = false
HMACSHA512 = false
[MRZ15.AN10922Features]
ImportKey = false
DeriveAESKey = false
Checksum = false
[MRZ15.RFC5649Features]
ImportKey = false
AesWrapBlobWithPadding = false
WRK17
WRK17 is another general purpose MPC protocol. It works for two MPC nodes and is based on the research paper https://eprint.iacr.org/2017/189.
TOML
[WRK17]
KeySize = 16
Rho = 40
BucketSize = 4
[WRK17.AESFeatures]
GenerateKey = false
ExportKey = false
ImportKey = false
CTRKeyStream = false
CBCEncrypt = false
CBCDecrypt = false
GCMEncrypt = false
GCMDecrypt = false
CMAC = false
[WRK17.HMACFeatures]
GenerateKey = false
ExportKey = false
ImportKey = false
HMACSHA256 = false
HMACSHA512 = false
[WRK17.AN10922Features]
ImportKey = false
DeriveAESKey = false
Checksum = false
Broadcast
In some cases it is handy to use Builder Vault as a way to broadcast arbitrary messages to all the MPC nodes.
TOML
[BROADCAST]
MaxMessageLength = 65536
[BROADCAST.Features]
SimpleBroadcast = false
AdvancedBroadcast = false