X-Git-Url: https://git.distorted.org.uk/~mdw/catacomb/blobdiff_plain/8276a9c565bc29afbc6cc120dfde0801c06c2bbd..25f3ce6a509ff9e3a354303023cb2028e9f83b95:/pub/x448.c diff --git a/pub/x448.c b/pub/x448.c index 73ca6bf7..6bef9dd3 100644 --- a/pub/x448.c +++ b/pub/x448.c @@ -101,6 +101,8 @@ void x448(octet zz[X448_OUTSZ], #include #include +#include "ct.h" + static int vrf_x448(dstr dv[]) { dstr dz = DSTR_INIT; @@ -110,10 +112,12 @@ static int vrf_x448(dstr dv[]) if (dv[1].len != X448_PUBSZ) die(1, "bad public length"); if (dv[2].len != X448_OUTSZ) die(1, "bad result length"); + ct_poison(dv[0].buf, dv[0].len); dstr_ensure(&dz, X448_OUTSZ); dz.len = X448_OUTSZ; x448((octet *)dz.buf, (const octet *)dv[0].buf, (const octet *)dv[1].buf); + ct_remedy(dz.buf, dz.len); if (memcmp(dz.buf, dv[2].buf, X448_OUTSZ) != 0) { ok = 0; fprintf(stderr, "failed!");