summaryrefslogtreecommitdiffstats
path: root/openpgp/src/crypto/backend/rust/aead.rs
diff options
context:
space:
mode:
Diffstat (limited to 'openpgp/src/crypto/backend/rust/aead.rs')
-rw-r--r--openpgp/src/crypto/backend/rust/aead.rs6
1 files changed, 5 insertions, 1 deletions
diff --git a/openpgp/src/crypto/backend/rust/aead.rs b/openpgp/src/crypto/backend/rust/aead.rs
index e5fcdb0b..4a51b427 100644
--- a/openpgp/src/crypto/backend/rust/aead.rs
+++ b/openpgp/src/crypto/backend/rust/aead.rs
@@ -150,7 +150,11 @@ impl AEADAlgorithm {
| SymmetricAlgorithm::Unencrypted =>
Err(Error::UnsupportedSymmetricAlgorithm(sym_algo).into()),
},
- AEADAlgorithm::OCB | AEADAlgorithm::Private(_) | AEADAlgorithm::Unknown(_) =>
+ AEADAlgorithm::OCB =>
+ Err(Error::UnsupportedAEADAlgorithm(*self).into()),
+ AEADAlgorithm::GCM =>
+ Err(Error::UnsupportedAEADAlgorithm(*self).into()),
+ AEADAlgorithm::Private(_) | AEADAlgorithm::Unknown(_) =>
Err(Error::UnsupportedAEADAlgorithm(*self).into()),
}
}