You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Facade proof: a producer is refused through a parameter that may be NULL (curl_mime_init(easy) → Curl_rand_alnum → random), leaving curl_mime "destroyed but never produced" #3126
curl_mime_free is proven the destroyer, but curl_mime_init is refused ("retains param 0 ... passed to random, which no unit defines"), so the report says "curl_mime: destroyed but never produced here; no resource". The refused path runs through the easy parameter, which since 7.87.0 may be NULL; the mime it returns is the produced object.
Two fixes: an unresolved callee (random, a libc function) on a path should not decide retention of an unrelated parameter; and a function whose return the proven destroyer frees is that resource's producer even when one of its other parameters stays unmodeled (present it with that parameter fixed or optional, cf. the optional-parent grammar issue).
Done when: curl_mime presents with a producer and destroyer from the proof.
Blocked on #3122 (the optional-parent producer: curl_mime_init(easy) with a NULL-able parent has no clause yet) for the producer half. The other half, an unresolved libc callee (random) deciding retention of an unrelated parameter, is a proof question that goes with #3174's ruling on what an undecided callee may be assumed to do.
Both halves are now resolved on main (verified against libcurl 8.23.0 on 673ca2631):
Proof half:curl_mime_init is no longer refused through random. The auto-draft now proves: curl_mime_init: raw: owned *mut curl_mime (proof: returns mime, a fresh allocation never retained), dropped by curl_mime_free, but param 0 is *mut c_void, which the facade does not describe curl_mime_free: destroyer, param 0 (proof: frees it)
Activity
ehartford commentedon Nov 18, 2026
Blocked on #3122 (the optional-parent producer:
curl_mime_init(easy)with a NULL-able parent has no clause yet) for the producer half. The other half, an unresolved libc callee (random) deciding retention of an unrelated parameter, is a proof question that goes with #3174's ruling on what an undecided callee may be assumed to do.ehartford commentedon Nov 27, 2026
Both halves are now resolved on
main(verified againstlibcurl 8.23.0on673ca2631):curl_mime_initis no longer refused throughrandom. The auto-draft now proves:curl_mime_init: raw: owned *mut curl_mime (proof: returns mime, a fresh allocation never retained), dropped by curl_mime_free, but param 0 is *mut c_void, which the facade does not describecurl_mime_free: destroyer, param 0 (proof: frees it)curl_mime_init(easy), NULL allowed since 7.87.0) is presented on the parent and collides with itsnew#3122 landedfrom curl_mime_init(null)so the contract can state the optional/null parent explicitly rather than guessing nullability (Law 4). Statingcurl_mimeinregistry/c/libcurl/facts.withis tracked under Registry facade for c.libcurl (HTTP): complete, reviewed, with a zero-unsafe UAT #3143.