DF-0598 / run.sh
#!/bin/sh # DF-0598 — run the code-level proof harness. # Demonstrates: (a) vulnerable smb_sm_lookupint leaks one VC ref per miss # (wrong-VC ref taken via the stale post-loop vcp at smb_conn.c:175-178), # and (b) the fixed version (fix.diff) leaks zero refs and returns *vcpp=NULL # on every miss. # Usage: ./run.sh [N] (N = number of failing lookups, default 10) set -e cd "$(dirname "$0")" N="${1:-10}" echo "+ ./leak $N" ./leak "$N" echo "RUN_EXIT=$?" |