comparison libtomcrypt/src/misc/crypt/crypt_find_hash_any.c @ 1471:6dba84798cd5

Update to libtomcrypt 1.18.1, merged with Dropbear changes
author Matt Johnston <matt@ucc.asn.au>
date Fri, 09 Feb 2018 21:44:05 +0800
parents f849a5ca2efc
children
comparison
equal deleted inserted replaced
1470:8bba51a55704 1471:6dba84798cd5
3 * LibTomCrypt is a library that provides various cryptographic 3 * LibTomCrypt is a library that provides various cryptographic
4 * algorithms in a highly modular and flexible manner. 4 * algorithms in a highly modular and flexible manner.
5 * 5 *
6 * The library is free for all purposes without any express 6 * The library is free for all purposes without any express
7 * guarantee it works. 7 * guarantee it works.
8 *
9 * Tom St Denis, [email protected], http://libtom.org
10 */ 8 */
11 #include "tomcrypt.h" 9 #include "tomcrypt.h"
12 10
13 /** 11 /**
14 @file crypt_find_hash_any.c 12 @file crypt_find_hash_any.c
15 Find a hash, Tom St Denis 13 Find a hash, Tom St Denis
16 */ 14 */
17 15
18 /** 16 /**
19 Find a hash flexibly. First by name then if not present by digest size 17 Find a hash flexibly. First by name then if not present by digest size
20 @param name The name of the hash desired 18 @param name The name of the hash desired
21 @param digestlen The minimum length of the digest size (octets) 19 @param digestlen The minimum length of the digest size (octets)
22 @return >= 0 if found, -1 if not present 20 @return >= 0 if found, -1 if not present
23 */int find_hash_any(const char *name, int digestlen) 21 */int find_hash_any(const char *name, int digestlen)
24 { 22 {
42 } 40 }
43 LTC_MUTEX_UNLOCK(&ltc_hash_mutex); 41 LTC_MUTEX_UNLOCK(&ltc_hash_mutex);
44 return z; 42 return z;
45 } 43 }
46 44
47 /* $Source$ */ 45 /* ref: $Format:%D$ */
48 /* $Revision$ */ 46 /* git commit: $Format:%H$ */
49 /* $Date$ */ 47 /* commit time: $Format:%ai$ */