General Improvements (#268)
* Move `elliptic-curve` implementation to points to allow `Zeroize` * Simplify `Ristretto255::random_scalar` implementation * Fix `Ristretto255` deserialization * Remove unnecessary check in `Ristretto255::random_scalar` * Base `X25519` implementation on `curve25519-dalek` * Constrain public and secret key to `Copy` * Replace manual `ZeroizeOnDrop` implementation with `derive` * Update dependencies * Add `warn(unused_crate_dependencies)` * Sync crate feature naming with `voprf` * Remove unnecessary dependency crate features * Never produce a zero scalar * Rename `OprfGroup` to `OprfCs` * Rename `TripleDH` to `TripleDh` * Remove `slow-hash` crate feature * Rename `NoOpHash` to `Identity` * Rename `SlowHash` to `Ksf` * Move `KeyExchange` type definitions down * Deserialize secret and public keys from slices * Remove `PrivateKey::from_bytes` * Rename `From/ToBytes` to `De/Serialize` * Re-export `serde_` as `serde` * Custom `De/Serialize` implementation for keys * Remove custom `De/Serialize` implementation * Run Taplo v0.6
This commit is contained in:
@@ -49,18 +49,18 @@ struct Default;
|
||||
|
||||
#[cfg(feature = "ristretto255")]
|
||||
impl CipherSuite for Default {
|
||||
type OprfGroup = opaque_ke::Ristretto255;
|
||||
type OprfCs = opaque_ke::Ristretto255;
|
||||
type KeGroup = opaque_ke::Ristretto255;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDH;
|
||||
type SlowHash = opaque_ke::slow_hash::NoOpHash;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDh;
|
||||
type Ksf = opaque_ke::ksf::Identity;
|
||||
}
|
||||
|
||||
#[cfg(not(feature = "ristretto255"))]
|
||||
impl CipherSuite for Default {
|
||||
type OprfGroup = p256::NistP256;
|
||||
type OprfCs = p256::NistP256;
|
||||
type KeGroup = p256::NistP256;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDH;
|
||||
type SlowHash = opaque_ke::slow_hash::NoOpHash;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDh;
|
||||
type Ksf = opaque_ke::ksf::Identity;
|
||||
}
|
||||
|
||||
struct Locker {
|
||||
|
||||
@@ -43,18 +43,18 @@ struct Default;
|
||||
|
||||
#[cfg(feature = "ristretto255")]
|
||||
impl CipherSuite for Default {
|
||||
type OprfGroup = opaque_ke::Ristretto255;
|
||||
type OprfCs = opaque_ke::Ristretto255;
|
||||
type KeGroup = opaque_ke::Ristretto255;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDH;
|
||||
type SlowHash = opaque_ke::slow_hash::NoOpHash;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDh;
|
||||
type Ksf = opaque_ke::ksf::Identity;
|
||||
}
|
||||
|
||||
#[cfg(not(feature = "ristretto255"))]
|
||||
impl CipherSuite for Default {
|
||||
type OprfGroup = p256::NistP256;
|
||||
type OprfCs = p256::NistP256;
|
||||
type KeGroup = p256::NistP256;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDH;
|
||||
type SlowHash = opaque_ke::slow_hash::NoOpHash;
|
||||
type KeyExchange = opaque_ke::key_exchange::tripledh::TripleDh;
|
||||
type Ksf = opaque_ke::ksf::Identity;
|
||||
}
|
||||
|
||||
// Password-based registration between a client and server
|
||||
|
||||
Reference in New Issue
Block a user