Use .clone() instead of processing ipad twice in key setup for HMAC
@@ -135,9 +135,9 @@ impl Hmac {
// Due to opad_hasher and ipad_hasher being initialized in init()
// using .unwrap() here should not be able to panic
- self.working_hasher.update(ipad.as_ref()).unwrap();
self.ipad_hasher.update(ipad.as_ref()).unwrap();
self.opad_hasher.update(opad.as_ref()).unwrap();
+ self.working_hasher = self.ipad_hasher.clone();
ipad.clear();
opad.clear();
}
