Thanks — that’s exactly the use case, and it isn’t hypothetical.
Why it matters on ICP. A canister is upgradeable: whoever controls it can replace the Wasm at any time. The IC tells you the current module hash, but there is no built-in, trustless, time-anchored record of past module hashes that a third party can check without trusting the project or any single piece of infrastructure. Anchoring the module hash (plus source and build metadata) in Bitcoin gives you exactly that: proof that “this exact code was the deployed code at or before block N”, verifiable by anyone with a Bitcoin node. That covers upgrade accountability, disputes (“the code live when I interacted was X, not Y”), SNS/DAO transparency, and reproducible builds.
Workflow — any project can do this today, cost ≈ 0:
1. Read what is actually deployed (controllers + module hash)
dfx canister info --network ic
2. Build reproducibly and hash the artefacts
rustup toolchain install 1.95.0 --profile minimal --target wasm32-unknown-unknown
cargo +1.95.0 build --locked --release --target wasm32-unknown-unknown
sha256sum target/wasm32-unknown-unknown/release/.wasm Cargo.lock Cargo.toml src/.rs > SHA256SUMS.txt
3. Write a plain-text provenance manifest: canister id, module hash, source commit,
toolchain (rustc / dfx / ic-wasm versions), Wasm sha256, date.
Seal it in Bitcoin via OpenTimestamps (free; public calendars aggregate it into a tx)
ots stamp PROVENANCE.txt
ots stamp SHA256SUMS.txt
4. Hours later, pull the Bitcoin attestation into the proof
ots upgrade PROVENANCE.txt.ots
5. Anyone verifies - against their OWN node, no trusted party
ots verify PROVENANCE.txt.ots # "Success! Bitcoin block N attests existence as of "
ots info PROVENANCE.txt.ots # or read the block height and cross-check it on any explorer
dfx canister info --network ic # and compare the module hash with the manifest
6. Optional: sign the manifest so key-control is verifiable too
(post-quantum ML-DSA-87 with OpenSSL >= 3.5; pair it with classical ECDSA if you like)
openssl genpkey -algorithm ML-DSA-87 -out mldsa87.key
openssl pkey -in mldsa87.key -pubout -out mldsa87.pub
openssl pkeyutl -sign -inkey mldsa87.key -in PROVENANCE.txt -out PROVENANCE.sig
openssl pkeyutl -verify -pubin -inkey mldsa87.pub -in PROVENANCE.txt -sigfile PROVENANCE.sig
Three rules that keep it honest: a sealed manifest is never edited (corrections go in a separately sealed addendum); SHA256SUMS lists only immutable files — never the .ots, which change as they mature; and nothing is called “anchored” until ots upgrade + ots verify have actually succeeded.
A public, reproducible instance of your item 3 (genesis manifest): GitHub repo x39matrix/x39-Evidencia, release tag pq-genesis-ea65e899. It contains the genesis manifest, ECDSA (secp256k1) and ML-DSA-87 (FIPS-204) signatures over it — both verifiable with the OpenSSL command above —, the .ots proof attesting Bitcoin blocks 952718 and 952732, a verification record, and the exact commands to reproduce every check. No link needed: the verification rebuilds from the files alone.
And it’s how I treat my own canisters. Provenance manifests and state snapshots of e.g. arn4r-lqaaa-aaaao-baxwq-cai (read its live module hash with step 1) are sealed in Bitcoin and verified against a full node, together with a reproducible-build record of the source. Happy to share the provenance capsule if anyone wants to pick at it.
What this does and doesn’t prove — worth being precise: the timestamp proves the manifest, and therefore that module hash, existed before block N. It does not by itself prove the deployed Wasm came from the published source; for that you also reproduce the build and document the whole pipeline (in my case cargo reproduces the raw Wasm byte-for-byte, while the extra ic-wasm/dfx optimisation step still has to be recorded explicitly). It does not stop a controller from upgrading — it makes the history auditable. And a canister’s internal certification proves internal consistency, not that the controller didn’t rewrite it; the external anchor is the one thing no controller can change retroactively.
Adversarial feedback welcome — if any step doesn’t hold up, I’d rather hear it.