Skip to content

Commit

Permalink
Add comment back in
Browse files Browse the repository at this point in the history
  • Loading branch information
julek-wolfssl committed Jul 26, 2023
1 parent 8ec2e23 commit 5cf4224
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/dtls13.c
Original file line number Diff line number Diff line change
Expand Up @@ -274,6 +274,9 @@ static int Dtls13GetRnMask(WOLFSSL* ssl, const byte* ciphertext, byte* mask,
if (c->chacha == NULL)
return BAD_STATE_E;

/* assuming CIPHER[0..3] should be interpreted as little endian 32-bits
integer. The draft rfc isn't really clear on that. See sec 4.2.3 of
the draft. See also Section 2.3 of the Chacha RFC. */
ato32le(ciphertext, &counter);

ret = wc_Chacha_SetIV(c->chacha, &ciphertext[4], counter);
Expand Down

0 comments on commit 5cf4224

Please sign in to comment.