Converting to_bytes and try_from to serialize() and deserialize() (#138)

This commit is contained in:
Kevin Lewi
2021-02-17 02:47:00 -08:00
committed by GitHub
parent bb7d17a102
commit 782eeb7090
9 changed files with 132 additions and 251 deletions
-5
View File
@@ -113,11 +113,6 @@ pub(crate) struct OpenedInnerEnvelope<D: Hash> {
}
impl<D: Hash> Envelope<D> {
/// The additional number of bytes added to the plaintext
pub(crate) fn additional_size() -> usize {
NONCE_LEN + <D as Digest>::OutputSize::to_usize()
}
fn hmac_key_size() -> usize {
<D as Digest>::OutputSize::to_usize()
}