Implement client_mac_key test

This commit is contained in:
dAxpeDDa
2021-07-30 14:45:27 -07:00
committed by Kevin Lewi
parent ec528eb4d9
commit 3f6b6d4afe
4 changed files with 21 additions and 1 deletions
+6 -1
View File
@@ -28,7 +28,12 @@ pub type GenerateKe2Result<K, D, G> = (
#[cfg(not(test))]
pub type GenerateKe3Result<K, D, G> = (Vec<u8>, <K as KeyExchange<D, G>>::KE3Message);
#[cfg(test)]
pub type GenerateKe3Result<K, D, G> = (Vec<u8>, <K as KeyExchange<D, G>>::KE3Message, Vec<u8>);
pub type GenerateKe3Result<K, D, G> = (
Vec<u8>,
<K as KeyExchange<D, G>>::KE3Message,
Vec<u8>,
generic_array::GenericArray<u8, <D as digest::Digest>::OutputSize>,
);
pub trait KeyExchange<D: Hash, G: Group> {
type KE1State: FromBytes + ToBytesWithPointers + Zeroize + Clone;
+2
View File
@@ -189,6 +189,8 @@ impl<D: Hash, G: Group> KeyExchange<D, G> for TripleDH {
},
#[cfg(test)]
result.3,
#[cfg(test)]
result.2,
))
}