vestigia.h (873B)
1 /* 2 * vestigia.h: the two marks a vestigia harness makes. 3 * 4 * Copyright (c) 2026 Jared Tobin 5 * License: MIT 6 * 7 * vestigia_secret marks n bytes at p as secret: under memcheck they 8 * become undefined, so every branch and address computed from them 9 * is reported, with this mark as the origin. vestigia_public marks 10 * n bytes at p as public again: outputs the function is meant to 11 * reveal (a signature, a public key), so that writing them out is 12 * not reported. Outside valgrind both are no-ops. 13 * 14 * Mark a secret after writing it and before the call; mark the 15 * outputs after the call. A harness compiles vestigia.c beside it, 16 * which defines both (and serves a foreign function interface as 17 * well as C). 18 */ 19 #ifndef VESTIGIA_H 20 #define VESTIGIA_H 21 22 #include <stddef.h> 23 24 void vestigia_secret(void *p, size_t n); 25 void vestigia_public(void *p, size_t n); 26 27 #endif