Add decrypt helper function

This commit is contained in:
Michael Vines 2021-10-29 10:46:29 -07:00
parent 69fab16e83
commit c61775664e
1 changed files with 4 additions and 0 deletions

View File

@ -81,6 +81,10 @@ impl AesKey {
pub fn encrypt(&self, amount: u64) -> AesCiphertext {
Aes::encrypt(self, amount)
}
pub fn decrypt(&self, ct: &AesCiphertext) -> Option<u64> {
Aes::decrypt(self, ct)
}
}
#[derive(Debug)]