From: Loup Vaillant Date: Thu, 2 Feb 2023 10:15:26 +0000 (+0100) Subject: Fix UB (pointer pointing outside of object) X-Git-Url: https://git.codecow.com/?a=commitdiff_plain;h=ca06d3a2e53e3ba66a9d7e65bdba68c6dc4215e6;p=Monocypher.git Fix UB (pointer pointing outside of object) --- diff --git a/src/optional/monocypher-ed25519.c b/src/optional/monocypher-ed25519.c index 2dfa9ac..e6692b7 100644 --- a/src/optional/monocypher-ed25519.c +++ b/src/optional/monocypher-ed25519.c @@ -363,7 +363,7 @@ void crypto_sha512_hkdf_expand(u8 *okm, size_t okm_size, COPY(okm, blk, out_size); not_first = 1; - okm += 64; + okm += out_size; okm_size -= out_size; ctr++; }