dev(ciphers): change HashDomain and related structures to use EitherShakeOrBlake. Docu pending

This commit is contained in:
David Niehues
2025-02-11 21:14:24 +01:00
parent cf74584f51
commit 30e158f594
4 changed files with 51 additions and 29 deletions

View File

@@ -29,4 +29,13 @@ where
}
}
pub type EitherShakeOrBlake = HashChoice<32, 32, anyhow::Error, SHAKE256Core<32, 32>, Blake2bCore>;
pub type EitherShakeOrBlake = EitherHash<32, 32, anyhow::Error, SHAKE256Core<32, 32>, Blake2bCore>;
impl Clone for EitherShakeOrBlake {
fn clone(&self) -> Self {
match self {
Self::Left(l) => Self::Left(l.clone()),
Self::Right(r) => Self::Right(r.clone()),
}
}
}