diff options
author | Jimmy Hu <jimmy.hu@dexon.org> | 2019-01-04 16:24:26 +0800 |
---|---|---|
committer | Wei-Ning Huang <w@byzantine-lab.io> | 2019-06-12 17:27:21 +0800 |
commit | 9a8e616df90409e1a94b7843d1ceddcf010bc11b (patch) | |
tree | 9ee2a492ea8c5406bf7df078b1b2f028af1d65a7 /vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go | |
parent | b92aa8f1590c3ecb1e2fe8ba12a5092ca190786c (diff) | |
download | go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.tar go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.tar.gz go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.tar.bz2 go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.tar.lz go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.tar.xz go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.tar.zst go-tangerine-9a8e616df90409e1a94b7843d1ceddcf010bc11b.zip |
vendor: sync to latest core (#125)
Diffstat (limited to 'vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go')
-rw-r--r-- | vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go b/vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go index f021d1bfb..efe846755 100644 --- a/vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go +++ b/vendor/github.com/dexon-foundation/dexon-consensus/core/types/dkg/dkg.go @@ -31,6 +31,11 @@ import ( "github.com/dexon-foundation/dexon-consensus/core/types" ) +// NewID creates a DKGID from NodeID. +func NewID(ID types.NodeID) cryptoDKG.ID { + return cryptoDKG.NewID(ID.Hash[:]) +} + // PrivateShare describe a secret share in DKG protocol. type PrivateShare struct { ProposerID types.NodeID `json:"proposer_id"` |