ensure that ctx
is non-NULL
The code-path via the `ed25519ph_*()` APIs would have allowed to get here and de-reference `ctx` even if it is `NULL`. Signed-off-by: Steffen Jaeckel <s@jaeckel.eu>
This commit is contained in:
parent
fd41f04026
commit
bb7712bd64
@ -28,6 +28,7 @@ int ec25519_crypto_ctx(unsigned char *out, unsigned long *outlen, unsigned char
|
||||
buf++;
|
||||
|
||||
if (ctxlen > 0u) {
|
||||
LTC_ARGCHK(ctx != NULL);
|
||||
XMEMCPY(buf, ctx, ctxlen);
|
||||
buf += ctxlen;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user