hasher: Add helper to determine hash algorithm from signature scheme

This commit is contained in:
Tobias Brunner
2015-03-04 13:54:09 +01:00
parent 353294ea5c
commit d874101055
2 changed files with 44 additions and 0 deletions
@@ -187,4 +187,12 @@ int hasher_algorithm_to_oid(hash_algorithm_t alg);
*/
int hasher_signature_algorithm_to_oid(hash_algorithm_t alg, key_type_t key);
/**
* Determine the hash algorithm associated with a given signature scheme.
*
* @param scheme signature scheme
* @return hash algorithm (could be HASH_UNKNOWN)
*/
hash_algorithm_t hasher_from_signature_scheme(signature_scheme_t scheme);
#endif /** HASHER_H_ @}*/