diff options
author | Jimmy Hu <jimmy.hu@dexon.org> | 2019-03-20 14:57:12 +0800 |
---|---|---|
committer | Jimmy Hu <jimmy.hu@dexon.org> | 2019-03-27 15:25:10 +0800 |
commit | 6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7 (patch) | |
tree | 2c18fe616f84df7274f19f88cf325fe558869918 /core/types/vote.go | |
parent | fa3b5a29499739e90b3cf17f9a0cf60a72a64fc0 (diff) | |
download | tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.tar tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.tar.gz tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.tar.bz2 tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.tar.lz tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.tar.xz tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.tar.zst tangerine-consensus-6efe199cb38eb4cb9a9a64d98ff5f8c4fb997da7.zip |
core: merge notarySet and DKGSet (#488)
* core: ăăăȘă DKGSet
* test logger
* temporary fix before finalized
* core: Sign psig on commit vote
* Add syncer log
* fixup
Diffstat (limited to 'core/types/vote.go')
-rw-r--r-- | core/types/vote.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/core/types/vote.go b/core/types/vote.go index c4a625e..8bc0c78 100644 --- a/core/types/vote.go +++ b/core/types/vote.go @@ -22,6 +22,7 @@ import ( "github.com/dexon-foundation/dexon-consensus/common" "github.com/dexon-foundation/dexon-consensus/core/crypto" + cryptoDKG "github.com/dexon-foundation/dexon-consensus/core/crypto/dkg" ) // VoteType is the type of vote. @@ -61,8 +62,9 @@ type VoteHeader struct { // Vote is the vote structure defined in Crypto Shuffle Algorithm. type Vote struct { - VoteHeader `json:"header"` - Signature crypto.Signature `json:"signature"` + VoteHeader `json:"header"` + PartialSignature cryptoDKG.PartialSignature `json:"partial_signature"` + Signature crypto.Signature `json:"signature"` } func (v *Vote) String() string { @@ -91,6 +93,8 @@ func (v *Vote) Clone() *Vote { Period: v.Period, Position: v.Position, }, + PartialSignature: cryptoDKG.PartialSignature( + crypto.Signature(v.PartialSignature).Clone()), Signature: v.Signature.Clone(), } } |