Commit Graph

30 Commits

Author SHA1 Message Date
Andreas Fackler 51b87b8bae Add node transaction messages to Dynamic HB. 2018-07-30 23:52:34 +01:00
Andreas Fackler c0cef3b50b Avoid redundant key computations. 2018-07-30 23:52:34 +01:00
Andreas Fackler e3a401bcb9 Make SyncKeyGen NodeUid-aware.
This allows the caller to address nodes by ID instead of by index.

Also contains a few other minor changes that will be needed for
`DynamicHoneyBadger`.
2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 17fdffa90f threshold encryption of proposals in HoneyBadger 2018-07-30 23:52:34 +01:00
Andreas Fackler 0c66e16010 Remove generic E: Engine from crypto. 2018-07-30 23:52:34 +01:00
Andreas Fackler 81cbe5a63b Implement SyncKeyGen.
This is a _synchronous_ key generation algorithm. We will use it in
`DynamicHoneyBadger`, on top of `HoneyBadger` to satisfy the synchrony
requirements.

It can also be used independently e.g. on top of a blockchain.
2018-07-30 23:52:34 +01:00
Peter van Nostrand 1c3afe85eb Fix formatting. 2018-07-30 23:52:34 +01:00
Peter van Nostrand 5bf57d5d1d Added clear-on-drop secret-keys to 'NetworkInfo'. 2018-07-30 23:52:34 +01:00
Andreas Fackler 34d642f709 Improve Hash impl for Ciphertext.
This formulation makes it harder to forget updating the `Hash`
implementation if the `Ciphertext` type changes.
2018-07-30 23:52:34 +01:00
Andreas Fackler db1de60237 Implement Hash for "public" cryptographic types.
This adds a `Hash` implementation for public keys, commitments,
ciphertexts and signatures — types that might make sense to be included
in special transactions. The `DynamicHoneyBadger` implementation will
require some of them.
2018-07-30 23:52:34 +01:00
Andreas Fackler cf1782b2cf Simplify serde implementations, add Ciphertext. 2018-07-30 23:52:34 +01:00
Andreas Fackler db2d84cabd Support serde by default.
This removes the `serialization-serde` feature, since serde is already
used internally and therefore a dependency anyway.
2018-07-30 23:52:34 +01:00
Andreas Fackler 78b2a008c1 Rename crypto::keygen to crypto::poly. 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 36c32822ed review comment coverage 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 28ec3c5824 note in the broadcast example about the use of keys 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 16b3c045ca extended the common coin nonce with a global UID and the top-level epoch 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 3592c13133 fixed propagation of common coin messages to the top level 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 2faf2afa46 protobuf serialization 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy a1038d9fb3 updated the tests with key initialisation 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy a87bd6460b common coin implementation 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy 68b9da5a3d Common Coin module template; added keys in NetworkInfo 2018-07-30 23:52:34 +01:00
Andreas Fackler f6e01daa13 Implement polynomials for distributed key generation. 2018-07-30 23:52:34 +01:00
Andreas Fackler f8685b5367 Expand crypto tests. 2018-07-30 23:52:34 +01:00
Andreas Fackler 40196fae1d Implement threshold encryption. 2018-07-30 23:52:34 +01:00
Andreas Fackler 419aae5adc Implement simple encryption. 2018-07-30 23:52:34 +01:00
Andreas Fackler abff26a153 Make public keys and signatures serializable. 2018-07-30 23:52:34 +01:00
Andreas Fackler 12516d2716 Simplify hash_g2. 2018-07-30 23:52:34 +01:00
Andreas Fackler c830e8f605 Use SHA256 and byteorder in hash_g2. 2018-07-30 23:52:34 +01:00
Andreas Fackler 036548e6b8 Implement threshold signatures. 2018-07-30 23:52:34 +01:00
Vladimir Komendantskiy d3149b92f6
Initial commit 2018-07-30 13:29:55 +01:00