aboutsummaryrefslogtreecommitdiffstats
path: root/src/pk_pad/eme1/eme1.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/pk_pad/eme1/eme1.h')
-rw-r--r--src/pk_pad/eme1/eme1.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/src/pk_pad/eme1/eme1.h b/src/pk_pad/eme1/eme1.h
new file mode 100644
index 000000000..2a0ac92c4
--- /dev/null
+++ b/src/pk_pad/eme1/eme1.h
@@ -0,0 +1,35 @@
+/*************************************************
+* EME1 Header File *
+* (C) 1999-2007 Jack Lloyd *
+*************************************************/
+
+#ifndef BOTAN_EME1_H__
+#define BOTAN_EME1_H__
+
+#include <botan/pk_util.h>
+
+namespace Botan {
+
+/*************************************************
+* EME1 *
+*************************************************/
+class BOTAN_DLL EME1 : public EME
+ {
+ public:
+ u32bit maximum_input_size(u32bit) const;
+
+ EME1(const std::string&, const std::string&, const std::string& = "");
+ ~EME1() { delete mgf; }
+ private:
+ SecureVector<byte> pad(const byte[], u32bit, u32bit,
+ RandomNumberGenerator&) const;
+ SecureVector<byte> unpad(const byte[], u32bit, u32bit) const;
+
+ const u32bit HASH_LENGTH;
+ SecureVector<byte> Phash;
+ MGF* mgf;
+ };
+
+}
+
+#endif