diff options
author | lloyd <[email protected]> | 2010-06-16 00:52:24 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2010-06-16 00:52:24 +0000 |
commit | ecb574d32f4382326e94ad19e9d5baecc84a3c29 (patch) | |
tree | 55e98453b046e8553bc21fc2153939032718bbec /src/hash | |
parent | b1405ff3191a4343d098c513af157d831723b92d (diff) |
More Doxygen comments
Diffstat (limited to 'src/hash')
-rw-r--r-- | src/hash/comb4p/comb4p.h | 6 | ||||
-rw-r--r-- | src/hash/hash.h | 5 | ||||
-rw-r--r-- | src/hash/par_hash/par_hash.h | 5 | ||||
-rw-r--r-- | src/hash/sha1/sha160.h | 6 | ||||
-rw-r--r-- | src/hash/sha2/sha2_32.h | 4 | ||||
-rw-r--r-- | src/hash/sha2/sha2_64.h | 3 | ||||
-rw-r--r-- | src/hash/skein/skein_512.h | 5 |
7 files changed, 32 insertions, 2 deletions
diff --git a/src/hash/comb4p/comb4p.h b/src/hash/comb4p/comb4p.h index 424512092..550b70b14 100644 --- a/src/hash/comb4p/comb4p.h +++ b/src/hash/comb4p/comb4p.h @@ -16,9 +16,13 @@ namespace Botan { * Combines two hash functions using a Feistel scheme. Described in * "On the Security of Hash Function Combiners", Anja Lehmann */ -class Comb4P : public HashFunction +class BOTAN_DLL Comb4P : public HashFunction { public: + /** + * @param h1 the first hash + * @param h2 the second hash + */ Comb4P(HashFunction* h1, HashFunction* h2); ~Comb4P() { delete hash1; delete hash2; } diff --git a/src/hash/hash.h b/src/hash/hash.h index 7cdfc6712..4f753f765 100644 --- a/src/hash/hash.h +++ b/src/hash/hash.h @@ -40,8 +40,13 @@ class BOTAN_DLL HashFunction : public BufferedComputation */ virtual void clear() = 0; + /** + * @param hash_len the output length + * @param block_len the internal block size (if applicable) + */ HashFunction(u32bit hash_len, u32bit block_len = 0) : BufferedComputation(hash_len), HASH_BLOCK_SIZE(block_len) {} + virtual ~HashFunction() {} private: HashFunction& operator=(const HashFunction&); diff --git a/src/hash/par_hash/par_hash.h b/src/hash/par_hash/par_hash.h index 34d69e39a..d82a74a19 100644 --- a/src/hash/par_hash/par_hash.h +++ b/src/hash/par_hash/par_hash.h @@ -23,7 +23,10 @@ class BOTAN_DLL Parallel : public HashFunction std::string name() const; HashFunction* clone() const; - Parallel(const std::vector<HashFunction*>&); + /** + * @param hashes a set of hashes to compute in parallel + */ + Parallel(const std::vector<HashFunction*>& hashes); ~Parallel(); private: void add_data(const byte[], u32bit); diff --git a/src/hash/sha1/sha160.h b/src/hash/sha1/sha160.h index 3d46e0c79..c66831a1e 100644 --- a/src/hash/sha1/sha160.h +++ b/src/hash/sha1/sha160.h @@ -24,6 +24,12 @@ class BOTAN_DLL SHA_160 : public MDx_HashFunction SHA_160(); protected: + /** + * Set a custom size for the W array. Normally 80, but some + * subclasses need slightly more for best performance/internal + * constraints + * @param W_size how big to make W + */ SHA_160(u32bit W_size); void compress_n(const byte[], u32bit blocks); diff --git a/src/hash/sha2/sha2_32.h b/src/hash/sha2/sha2_32.h index 319432122..e8e60d07c 100644 --- a/src/hash/sha2/sha2_32.h +++ b/src/hash/sha2/sha2_32.h @@ -20,6 +20,10 @@ class BOTAN_DLL SHA_224_256_BASE : public MDx_HashFunction { protected: void clear(); + + /** + * @param out output size in bytes + */ SHA_224_256_BASE(u32bit out) : MDx_HashFunction(out, 64, true, true) { clear(); } diff --git a/src/hash/sha2/sha2_64.h b/src/hash/sha2/sha2_64.h index 5094fc0d2..bf87eb62d 100644 --- a/src/hash/sha2/sha2_64.h +++ b/src/hash/sha2/sha2_64.h @@ -20,6 +20,9 @@ class BOTAN_DLL SHA_384_512_BASE : public MDx_HashFunction protected: void clear(); + /** + * @param out output size in bytes + */ SHA_384_512_BASE(u32bit out) : MDx_HashFunction(out, 128, true, true, 16) {} diff --git a/src/hash/skein/skein_512.h b/src/hash/skein/skein_512.h index b2ec57962..5d17fa564 100644 --- a/src/hash/skein/skein_512.h +++ b/src/hash/skein/skein_512.h @@ -20,6 +20,11 @@ namespace Botan { class BOTAN_DLL Skein_512 : public HashFunction { public: + /** + * @param output_bits the output size of Skein in bits + * @param personalization is a string that will paramaterize the + * hash output + */ Skein_512(u32bit output_bits = 512, const std::string& personalization = ""); |