diff options
author | lloyd <[email protected]> | 2014-12-08 06:51:10 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2014-12-08 06:51:10 +0000 |
commit | 1b7dbd5ca22f83ac8011dc209d92d2562562c816 (patch) | |
tree | 1258dd5cebd6d399b93df09085e2656422ee5c8d /src/lib/pubkey | |
parent | 42a34f672bfd4737e66d8813d024b6f73fdfcad4 (diff) |
Add a basic speed test for McEliece
Diffstat (limited to 'src/lib/pubkey')
-rw-r--r-- | src/lib/pubkey/mce/mce_kem.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/lib/pubkey/mce/mce_kem.h b/src/lib/pubkey/mce/mce_kem.h index 4e46a0fab..2bb1edba5 100644 --- a/src/lib/pubkey/mce/mce_kem.h +++ b/src/lib/pubkey/mce/mce_kem.h @@ -37,6 +37,16 @@ class BOTAN_DLL McEliece_KEM_Decryptor * returns the derived 512-bit symmetric key */ secure_vector<Botan::byte> decrypt(const byte msg[], size_t msg_len); + + /** + * returns the derived 512-bit symmetric key + */ + template<typename Alloc> + secure_vector<Botan::byte> decrypt_vec(const std::vector<byte, Alloc>& v) + { + return decrypt(&v[0], v.size()); + + } private: McEliece_Private_Operation m_raw_priv_op; }; |