Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tomas Krizek
Knot Resolver
Commits
57965cf9
Commit
57965cf9
authored
Jul 25, 2016
by
Karel Slaný
Committed by
Ondřej Surý
Aug 11, 2016
Browse files
Removed some asserts.
parent
1fcc1132
Changes
1
Show whitespace changes
Inline
Side-by-side
lib/cookies/alg_sha.c
View file @
57965cf9
...
...
@@ -71,7 +71,7 @@ static uint16_t cc_gen_hmac_sha256_64(const struct knot_cc_input *input,
update_hash
(
&
ctx
,
input
->
srvr_sockaddr
);
}
assert
(
KNOT_OPT_COOKIE_CLNT
<=
SHA256_DIGEST_SIZE
);
/*
KNOT_OPT_COOKIE_CLNT <= SHA256_DIGEST_SIZE
*/
cc_len
=
KNOT_OPT_COOKIE_CLNT
;
hmac_sha256_digest
(
&
ctx
,
cc_len
,
cc_out
);
...
...
@@ -111,7 +111,7 @@ static uint16_t sc_gen_hmac_sha256_64(const struct knot_sc_input *input,
update_hash
(
&
ctx
,
input
->
srvr_data
->
clnt_sockaddr
);
}
assert
(
SRVR_HMAC_SHA256_64_HASH_SIZE
<
SHA256_DIGEST_SIZE
);
/*
SRVR_HMAC_SHA256_64_HASH_SIZE < SHA256_DIGEST_SIZE
*/
hash_len
=
SRVR_HMAC_SHA256_64_HASH_SIZE
;
hmac_sha256_digest
(
&
ctx
,
hash_len
,
hash_out
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment