diff options
Diffstat (limited to 'src/pk_pad/hash_id/hash_id.h')
-rw-r--r-- | src/pk_pad/hash_id/hash_id.h | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/src/pk_pad/hash_id/hash_id.h b/src/pk_pad/hash_id/hash_id.h index 847d9106c..909cc6b19 100644 --- a/src/pk_pad/hash_id/hash_id.h +++ b/src/pk_pad/hash_id/hash_id.h @@ -13,11 +13,21 @@ namespace Botan { -/* -* Return the values of various defined HashIDs +/** +* Return the PKCS #1 hash identifier +* @see RFC 3447 section 9.2 +* @param hash_name the name of the hash function +* @return byte sequence identifying the hash +* @throw Invalid_Argument if the hash has no known PKCS #1 hash id +*/ +BOTAN_DLL MemoryVector<byte> pkcs_hash_id(const std::string& hash_name); + +/** +* Return the IEEE 1363 hash identifier +* @param hash_name the name of the hash function +* @return byte code identifying the hash, or 0 if not known */ -BOTAN_DLL MemoryVector<byte> pkcs_hash_id(const std::string&); -BOTAN_DLL byte ieee1363_hash_id(const std::string&); +BOTAN_DLL byte ieee1363_hash_id(const std::string& hash_name); } |