Skip to content

Commit

Permalink
Add commitments to decaf377-frost protos
Browse files Browse the repository at this point in the history
  • Loading branch information
cronokirby committed Nov 14, 2023
1 parent 8cf98cd commit 3392167
Show file tree
Hide file tree
Showing 4 changed files with 51 additions and 3 deletions.
16 changes: 16 additions & 0 deletions crates/proto/src/gen/penumbra.crypto.decaf377_frost.v1alpha1.rs
Original file line number Diff line number Diff line change
@@ -1,46 +1,62 @@
/// A commitment to a polynomial, as a list of group elements.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct VerifiableSecretSharingCommitment {
/// Each of these bytes should be the serialization of a group element.
#[prost(bytes = "vec", repeated, tag = "1")]
pub elements: ::prost::alloc::vec::Vec<::prost::alloc::vec::Vec<u8>>,
}
/// The public package sent in round 1 of the DKG protocol.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DkgRound1Package {
/// A commitment to the polynomial for secret sharing.
#[prost(message, optional, tag = "1")]
pub commitment: ::core::option::Option<VerifiableSecretSharingCommitment>,
/// A proof of knowledge of the underlying secret being shared.
#[prost(bytes = "vec", tag = "2")]
pub proof_of_knowledge: ::prost::alloc::vec::Vec<u8>,
}
/// A share of the final signing key.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SigningShare {
/// These bytes should be a valid scalar.
#[prost(bytes = "vec", tag = "1")]
pub scalar: ::prost::alloc::vec::Vec<u8>,
}
/// The per-participant package sent in round 2 of the DKG protocol.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct DkgRound2Package {
/// This is the share we're sending to that participant.
#[prost(message, optional, tag = "1")]
pub signing_share: ::core::option::Option<SigningShare>,
}
/// Represents a commitment to a nonce value.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct NonceCommitment {
/// These bytes should be a valid group element.
#[prost(bytes = "vec", tag = "1")]
pub element: ::prost::alloc::vec::Vec<u8>,
}
/// Represents the commitments to nonces needed for signing.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SigningCommitments {
/// One nonce to hide them.
#[prost(message, optional, tag = "1")]
pub hiding: ::core::option::Option<NonceCommitment>,
/// Another to bind them.
#[prost(message, optional, tag = "2")]
pub binding: ::core::option::Option<NonceCommitment>,
}
/// A share of the final signature. These get aggregated to make the actual thing.
#[allow(clippy::derive_partial_eq_without_eq)]
#[derive(Clone, PartialEq, ::prost::Message)]
pub struct SignatureShare {
/// These bytes should be a valid scalar.
#[prost(bytes = "vec", tag = "1")]
pub scalar: ::prost::alloc::vec::Vec<u8>,
}
Binary file modified crates/proto/src/gen/proto_descriptor.bin.no_lfs
Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -2,33 +2,49 @@ syntax = "proto3";

package penumbra.crypto.decaf377_frost.v1alpha1;

// A commitment to a polynomial, as a list of group elements.
message VerifiableSecretSharingCommitment {
// Each of these bytes should be the serialization of a group element.
repeated bytes elements = 1;
}

// The public package sent in round 1 of the DKG protocol.
message DKGRound1Package {
// A commitment to the polynomial for secret sharing.
VerifiableSecretSharingCommitment commitment = 1;
// A proof of knowledge of the underlying secret being shared.
bytes proof_of_knowledge = 2;
}

// A share of the final signing key.
message SigningShare {
// These bytes should be a valid scalar.
bytes scalar = 1;
}

// The per-participant package sent in round 2 of the DKG protocol.
message DKGRound2Package {
// This is the share we're sending to that participant.
SigningShare signing_share = 1;
}

// Represents a commitment to a nonce value.
message NonceCommitment {
// These bytes should be a valid group element.
bytes element = 1;
}

// Represents the commitments to nonces needed for signing.
message SigningCommitments {
// One nonce to hide them.
NonceCommitment hiding = 1;
// Another to bind them.
NonceCommitment binding = 2;
}

// A share of the final signature. These get aggregated to make the actual thing.
message SignatureShare {
// These bytes should be a valid scalar.
bytes scalar = 1;
}

0 comments on commit 3392167

Please sign in to comment.