🏡 index : quine-global/charter.git

Charter: user-chosen trust for Windows software

Working title. Status: outline, November 2026.

Goal

Make it possible to install software on Windows because people you chose to trust reproduced it from source, rather than because a publisher rented a code-signing certificate or built up SmartScreen reputation. In short: Nix's trust model, available to Windows users.

A file should be trusted when:

  1. It's reproducible. Its hash follows from its source and build recipe, and anyone can rebuild it and get the same bytes.
  2. Independent rebuilders agree. At least k of the n rebuilders the user picked (the developer, a distro, a company, people they know) signed that hash.
  3. The user holds the trust roots. The user chooses whose signatures count, like Nix's trusted-public-keys. Microsoft's root program is one option among many, not the gatekeeper.
  4. It's current. A genuinely signed but old, vulnerable release can't be passed off as the latest (rollback and freeze attacks).
  5. It's public. Every attestation is in an append-only log, so nobody can quietly sign two different hashes for two audiences.

Why

Windows trust today is one root program (Microsoft's), reputation you pay for (Authenticode certificates and SmartScreen), opaque builds, and antivirus heuristics in place of proof. A concrete case: quine-global/hyper#176, where Bkav's machine-learning heuristic (W32.AIDetectMalware) flags Hyper's unsigned Windows installers on VirusTotal. Nothing a user can do on their own machine changes that verdict: no local trust store and no package manager's hash pinning reaches the antivirus engines or SmartScreen.

Non-goals

Prior art

What Status What we take from it
Bitcoin Core's Guix builds and guix.sigs In production Reproducible Windows releases cross-built from Linux; many independent builders sign their hashes (guix-attest, guix-verify); Authenticode signatures attached reproducibly
nixpkgs pkgsCross.mingwW64 In production Cross-compiling Windows binaries reproducibly from Linux
libnix (NLnet, NGI Zero Core) and upstream Nix's Windows port In progress Native Nix on Windows; Nix 2.34.0 notes continued work
nova-nix Experimental A separate Windows-native Nix; C:\nix\store, needs Developer Mode for symlinks
TUF Mature (python-tuf, go-tuf, AWS tough) Freshness, rollback and freeze protection, k-of-n role keys, key rotation
in-toto Mature Layouts (who may perform which build step, with thresholds) and attestations; Debian's apt-transport-in-toto experiment with rebuilders
Sigstore (cosign, Rekor) and Sigsum Mature / young Transparency logs; Sigsum has independent witnesses that cosign its log
Debian's reproducible builds and rebuilderd In production Independent rebuilders as infrastructure

The gap: nobody has a Windows client that checks k-of-n rebuilder attestations against roots the user chose, with freshness and a transparency log, for any project.

Architecture

Three pieces, which can progress independently:

  1. Reproducible Windows builds: Nix or Guix cross-compiling from Linux. The build machine needn't run Windows.
  2. Attestations and distribution: rebuilders publish in-toto attestations ("from commit C I built H"). TUF metadata distributes the project's layout, the rebuilder keys and the latest release, and makes them fresh. Every attestation also goes into a transparency log.
  3. The Windows client: given a file, it checks the attestations against the user's trust store and threshold, the TUF freshness metadata and log inclusion, then reports or installs. It's a single .exe with no GnuPG or Python.

Milestones

M0: Prototype client against Bitcoin Core (done)

bitcoin-verify, in quine-global/bitcoin, branch windows-trust-verifier. Rust, one 3 MB .exe. It pins builder fingerprints in its own trust store and checks a release file against each builder's signed all.SHA256SUMS in guix.sigs with a threshold. It was tested on a real Windows machine against the 32.1 installer (genuine: pass; one byte changed: fail) and has 9 offline tests on real attestations.

What we learned: on its own, this does nothing GnuPG plus Bitcoin Core's verify.py can't. Its value is packaging (no Python, GnuPG or wget on Windows). It counts toward the goal only once it gains what GnuPG lacks: M2 and M3.

M1: Make the client project-agnostic (done)

quine-global/quorum. It has a trust store per project (feed, source, threshold, pinned rebuilders) and two feeds: guix-sigs (OpenPGP, with a bitcoin-core preset) and in-toto (DSSE envelopes holding in-toto Statements, with Ed25519 or ECDSA P-256 keys). quorum keygen and quorum attest cover the rebuilder's side.

On Windows (runner-windows), the same quorum.exe checked the real Bitcoin Core 32.1 installer against live guix.sigs, and a release of a second project through an in-toto feed. The second project was a stand-in made for the test; a real one is M4. There are 17 tests, and ECDSA P-256 signatures made independently with LibreSSL verify. Interop with attestations made by cosign itself is still untested.

M2: Freshness and rollback protection (done)

In quorum. A project's TUF repository signs one target, release.json, which says which release is the latest. Users pin its first root by SHA-256. quorum check follows the specification's client workflow (section 5): it walks the root chain (rotation), checks role thresholds, lengths and hashes, and fails with OUTDATED (unless --allow-old), FROZEN (expired metadata) or ROLLBACK. quorum tuf init | release | refresh | rotate-root publish it.

It's a minimal client of our own. awslabs' tough is async and needs aws-lc-sys, a C library that breaks the Windows cross-build. Tested in 7 end-to-end cases, among them a correctly signed old release (OUTDATED) and the whole repository replayed as it was (ROLLBACK). Not yet tested against repositories made by python-tuf or tuf-on-ci, nor run on Windows.

M3: Transparency (done)

Off the shelf, with quorum as the client. The log is a self-hostable, static C2SP tlog-tiles log of attestations, not a public service: Tessera's posix-oneshot writes it, and litewitness witnesses cosign it over C2SP tlog-witness before a checkpoint is published. This is Sigsum's witness model with its ecosystem's own tools, without publishing anything to a public log. quorum reads it with Cloudflare's signed_note and tlog_tiles crates: it counts an attestation only if it's logged, requires k of the pinned witnesses, and refuses a log whose history changed since it last looked (FORK, by a consistency proof). quorum log monitor reports a rebuilder signing two hashes for one file (EQUIVOCATION) and rebuilders disagreeing (DISAGREEMENT).

Tested in 7 end-to-end cases against the real Tessera and two real litewitnesses (pinned in quorum's flake), among them equivocation found by the monitor and a rewritten history: refused by the witnesses, and caught by the client even when colluding witnesses cosigned it. Waiting (not asking) for Cloudflare's next release of its crates: their main branch has tlog_cosignature, which would replace quorum's last log code, and no longer pulls in url, which costs quorum 30 crates (Unicode data) in 0.2.0. quorum moves to it once it's on crates.io. Open: inclusion proofs instead of reading every leaf hash; submitting to public Sigsum or Rekor logs, which would publish data and so needs a decision.

M4: A second reproducible project for Windows (done for x64)

M5: Independent rebuilders

M6: Windows experience

M7: Native Nix on Windows (contribute upstream)

Open questions and risks

Related work in flight