Lines Matching refs:hash_size
80 return ctx->hash_size; in SipHash_hash_size()
83 static size_t siphash_adjust_hash_size(size_t hash_size) in siphash_adjust_hash_size() argument
85 if (hash_size == 0) in siphash_adjust_hash_size()
86 hash_size = SIPHASH_MAX_DIGEST_SIZE; in siphash_adjust_hash_size()
87 return hash_size; in siphash_adjust_hash_size()
90 int SipHash_set_hash_size(SIPHASH *ctx, size_t hash_size) in SipHash_set_hash_size() argument
92 hash_size = siphash_adjust_hash_size(hash_size); in SipHash_set_hash_size()
93 if (hash_size != SIPHASH_MIN_DIGEST_SIZE in SipHash_set_hash_size()
94 && hash_size != SIPHASH_MAX_DIGEST_SIZE) in SipHash_set_hash_size()
103 ctx->hash_size = siphash_adjust_hash_size(ctx->hash_size); in SipHash_set_hash_size()
106 if ((size_t)ctx->hash_size != hash_size) { in SipHash_set_hash_size()
108 ctx->hash_size = hash_size; in SipHash_set_hash_size()
120 ctx->hash_size = siphash_adjust_hash_size(ctx->hash_size); in SipHash_Init()
138 if (ctx->hash_size == SIPHASH_MAX_DIGEST_SIZE) in SipHash_Init()
212 if (outlen != (size_t)ctx->hash_size) in SipHash_Final()
244 if (ctx->hash_size == SIPHASH_MAX_DIGEST_SIZE) in SipHash_Final()
252 if (ctx->hash_size == SIPHASH_MIN_DIGEST_SIZE) in SipHash_Final()