Skip to content

Commit

Permalink
PR feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
andyleiserson committed Dec 13, 2023
1 parent 4f23db3 commit bddc60a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 13 deletions.
12 changes: 0 additions & 12 deletions ipa-core/src/ff/ec_prime_field.rs
Original file line number Diff line number Diff line change
Expand Up @@ -139,18 +139,6 @@ impl From<BA256> for Fp25519 {
}
}

/*
/// BA256 mod field prime
impl BA256 {
#[must_use]
pub fn mod_fp25519(&self) -> Self {
let mut buf: GenericArray<u8, U32> = [0u8; 32].into();
Fp25519::from(*self).serialize(&mut buf);
BA256::deserialize(&buf)
}
}
*/

///conversion from and to unsigned integers, preserving entropy, for testing purposes only
#[cfg(test)]
macro_rules! sc_hash_impl {
Expand Down
7 changes: 6 additions & 1 deletion ipa-core/src/protocol/prss/crypto.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,12 @@ pub trait FromRandomU128 {

/// Trait for things that can be generated by PRSS.
///
/// The exact semantics of the generation depend on the value being generated.
/// The exact semantics of the generation depend on the value being generated, but like
/// `rand::distributions::Standard`, a uniform distribution is typical. When implementing
/// this trait, consider the consequences if the implementation were to be used in
/// an unexpected way. For example, an implementation that draws from a subset of the
/// possible values could be dangerous, if used in an unexpected context where
/// security relies on sampling from the full space.
///
/// At a high level, there are two kinds of PRSS generation:
/// 1. Raw values: In this case, two values are generated, one using the randomness that is shared
Expand Down

0 comments on commit bddc60a

Please sign in to comment.