summaryrefslogtreecommitdiff
path: root/src/sha1.h
diff options
context:
space:
mode:
authorzyp <zyp@localhost>2006-05-09 22:33:27 +0200
committerzyp <zyp@localhost>2006-05-09 22:33:27 +0200
commit0c4fc1e72770fc78d87891e5c031272fca59e409 (patch)
tree10682cb815cff09ec1e2ce9beb619c916f08616c /src/sha1.h
parent373495b3a1c8ccdcfece70bac69625b6823ccec0 (diff)
[project @ zyp-20060509203327-c8c93b489da2ea46]
[project @ 27] Multihash library rewrite complete.
Diffstat (limited to 'src/sha1.h')
-rw-r--r--src/sha1.h20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/sha1.h b/src/sha1.h
new file mode 100644
index 0000000..011c2f8
--- /dev/null
+++ b/src/sha1.h
@@ -0,0 +1,20 @@
+#ifndef _SHA1_H_
+#define _SHA1_H_
+
+#include "hash.h"
+
+#include <openssl/sha.h>
+
+namespace Multihash {
+ class SHA1 : public Hash {
+ private:
+ SHA_CTX sha1_ctx;
+ protected:
+ virtual void hash_update(const char* data, int length);
+ virtual std::string hash_digest();
+ public:
+ SHA1(Hash* n = 0);
+ };
+}
+
+#endif // _SHA1_H_