aboutsummaryrefslogtreecommitdiffstats
path: root/core/types
diff options
context:
space:
mode:
authorJimmy Hu <jimmy.hu@dexon.org>2018-09-19 15:00:11 +0800
committerGitHub <noreply@github.com>2018-09-19 15:00:11 +0800
commit54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4 (patch)
treeb0e503e08cc52dae2536ebef3dcd0110edd1b333 /core/types
parent8c33027b943e08de21b7bddb82fecc2b2a5664a2 (diff)
downloaddexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.tar
dexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.tar.gz
dexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.tar.bz2
dexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.tar.lz
dexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.tar.xz
dexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.tar.zst
dexon-consensus-54fa224dbbf1b1c0f8d54a3f10a81adb321ce1e4.zip
core:DKG and TSIG protocol (#115)
Diffstat (limited to 'core/types')
-rw-r--r--core/types/dkg.go19
1 files changed, 14 insertions, 5 deletions
diff --git a/core/types/dkg.go b/core/types/dkg.go
index 7fee404..7fb686c 100644
--- a/core/types/dkg.go
+++ b/core/types/dkg.go
@@ -24,17 +24,18 @@ import (
// DKGPrivateShare describe a secret share in DKG protocol.
type DKGPrivateShare struct {
- ProposerID ValidatorID `json:"proposer_id"`
- Round uint64 `json:"round"`
- PrivateKeyShare dkg.PrivateKey `json:"private_key_share"`
- Signature crypto.Signature `json:"signature"`
+ ProposerID ValidatorID `json:"proposer_id"`
+ Round uint64 `json:"round"`
+ PrivateShare dkg.PrivateKey `json:"private_share"`
+ Signature crypto.Signature `json:"signature"`
}
// DKGMasterPublicKey decrtibe a master public key in DKG protocol.
type DKGMasterPublicKey struct {
ProposerID ValidatorID `json:"proposer_id"`
Round uint64 `json:"round"`
- PublicKeyShares dkg.PublicKeyShares `json:"private_key_share"`
+ DKGID dkg.ID `json:"dkg_id"`
+ PublicKeyShares dkg.PublicKeyShares `json:"public_key_shares"`
Signature crypto.Signature `json:"signature"`
}
@@ -45,3 +46,11 @@ type DKGComplaint struct {
PrivateShare DKGPrivateShare `json:"private_share"`
Signature crypto.Signature `json:"signature"`
}
+
+// DKGPartialSignature describe a partial signature in DKG protocol.
+type DKGPartialSignature struct {
+ ProposerID ValidatorID `json:"proposerID"`
+ Round uint64 `json:"round"`
+ PartialSignature dkg.PartialSignature `json:"partial_signature"`
+ Signature crypto.Signature `json:"signature"`
+}