Skip to content

Commit

Permalink
remove commented out code (#427)
Browse files Browse the repository at this point in the history
  • Loading branch information
conradoplg authored Jul 3, 2023
1 parent abc1122 commit 31913f4
Show file tree
Hide file tree
Showing 5 changed files with 0 additions and 57 deletions.
8 changes: 0 additions & 8 deletions frost-core/src/frost.rs
Original file line number Diff line number Diff line change
Expand Up @@ -289,14 +289,6 @@ where
}
}

// impl<C> Debug for GroupCommitment<C> where C: Ciphersuite {
// fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
// f.debug_tuple("GroupCommitment")
// .field(&hex::encode(self.0.compress().serialize()))
// .finish()
// }
// }

/// Generates the group commitment which is published as part of the joint
/// Schnorr signature.
///
Expand Down
9 changes: 0 additions & 9 deletions frost-core/src/frost/round1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -87,15 +87,6 @@ where
}
}

// impl<C> Drop for Nonce<C>
// where
// C: Ciphersuite,
// {
// fn drop(&mut self) {
// self.zeroize()
// }
// }

#[cfg(any(test, feature = "test-impl"))]
impl<C> FromHex for Nonce<C>
where
Expand Down
6 changes: 0 additions & 6 deletions frost-core/src/frost/round2.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,12 +177,6 @@ fn compute_signature_share<C: Ciphersuite>(
}
}

// // Zeroizes `SignatureShare` to be the `Default` value on drop (when it goes out
// // of scope). Luckily the derived `Default` includes the `Default` impl of
// // Scalar, which is four 0u64's under the hood, and u16, which is
// // 0u16.
// impl DefaultIsZeroes for SignatureShare {}

/// Performed once by each participant selected for the signing operation.
///
/// Implements [`sign`] from the spec.
Expand Down
14 changes: 0 additions & 14 deletions frost-core/src/signature.rs
Original file line number Diff line number Diff line change
Expand Up @@ -118,17 +118,3 @@ impl<C: Ciphersuite> std::fmt::Debug for Signature<C> {
.finish()
}
}

// impl<C> FromHex for Signature<C>
// where
// C: Ciphersuite,
// {
// type Error = &'static str;

// fn from_hex<T: AsRef<[u8]>>(hex: T) -> Result<Self, Self::Error> {
// match FromHex::from_hex(hex) {
// Ok(bytes) => Self::deserialize(bytes).map_err(|_| "malformed signature encoding"),
// Err(_) => Err("invalid hex"),
// }
// }
// }
20 changes: 0 additions & 20 deletions frost-core/src/verifying_key.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,6 @@ impl<C> VerifyingKey<C>
where
C: Ciphersuite,
{
// pub(crate) fn from(scalar: &<<C::Group as Group>::Field as Field>::Scalar) -> Self {
// let element = <C::Group as Group>::generator() * *scalar;

// VerifyingKey { element }
// }

/// Create a new VerifyingKey from the given element.
#[cfg(feature = "internals")]
pub fn new(element: <C::Group as Group>::Element) -> Self {
Expand Down Expand Up @@ -132,17 +126,3 @@ where
Self(value.serialize())
}
}

// impl<C: Ciphersuite> From<VerifyingKey<C>> for <C::Group as Group>::ElementSerialization {
// fn from(pk: VerifyingKey<C>) -> <C::Group as Group>::ElementSerialization {
// pk.bytes.bytes
// }
// }

// impl<C: Ciphersuite> TryFrom<<C::Group as Group>::ElementSerialization> for VerifyingKey<C> {
// type Error = Error;

// fn try_from(bytes: [u8; 32]) -> Result<Self, Self::Error> {
// VerifyingKeyBytes::from(bytes).try_into()
// }
// }

0 comments on commit 31913f4

Please sign in to comment.