# Field — Software Supply-Chain Security

**Packet:** software-supply-chain-and-release-engineering · **Date:** 2026-07-24
**Grounds:** the `minimumReleaseAgeExclude` scope-glob decision (jgwill/Miadi#521) and
the fresh-clone reproducibility concern (jgwill/Miadi#520).

## Canonical concepts

- **Supply-chain attack classes.** Dependency confusion / substitution, typosquatting,
  and — the class most relevant here — **compromise of a legitimate package at publish
  time** via maintainer account takeover or CI compromise. A malicious version is live on
  the registry for a window (hours) before detection and removal.
- **Software provenance.** The verifiable record of *where an artifact came from and how it
  was produced*: W3C **PROV-DM**, **in-toto** attestations (Torres-Arias et al., USENIX
  Security 2019), and **SLSA** levels (slsa.dev) as a graded provenance/integrity ladder.
  (Miadi's `@miadi/episodic-memory-schema` already grounds its provenance layer in PROV-DM
  and OAIS — this packet reuses that vocabulary.)
- **Release-age / maturity cooldown (quarantine).** A defense that *refuses to resolve a
  version until it is at least N old*, buying time for the ecosystem to detect and yank a
  malicious publish before it installs. pnpm 11 ships this on by default as
  `minimumReleaseAge = 1440` minutes (verified against pnpm docs, this session); Socket and
  StepSecurity ship comparable "cooldown" controls. **SBOM** (CycloneDX, SPDX) records what
  is present so exposure can be reasoned about after the fact.

## Key finding

The cooldown is a **trust-boundary control**. It defends against publishers you *do not
control* — the ~1600 third-party dependencies whose maintainers and CI you cannot audit.
Applied *uniformly*, it also delays the first-party packages you publish yourself
(`mia-co`, `@medicine-wheel/*`, `@miadi/*`), where it buys **no protection** — you already
trust and can verify your own release pipeline — while imposing real latency on daily
delivery. The workaround the friction forced (hand-pinning every `name@version` into an
exclude list on each publish) is itself a supply-chain smell: a growing, manually-edited
allowlist that rots and invites mistakes.

## Cautions

- A cooldown is *mitigation, not prevention*: it narrows the exposure window; it does not
  verify the artifact. Pair it with provenance (SLSA/in-toto) and integrity (lockfile,
  SBOM) — never treat "24 h old" as "safe."
- Excluding a scope means **trusting that scope's publish path**. It is defensible only for
  scopes whose maintainers, registry credentials, and CI you actually own. A scope glob
  over a *third-party* namespace would be a real regression.

## Engineering implication (what this grounds)

Scope the policy to the trust boundary it defends. Exclude **first-party scopes by
pattern**, not by version:

```yaml
minimumReleaseAgeExclude:
  - mia-co
  - '@medicine-wheel/*'
  - '@miadi/*'
```

The 24 h cooldown keeps protecting every third-party dependency; the friction disappears
from the packages we author. This is the specific instance of the general principle
**"a provenance/quarantine policy should key on the trust boundary it defends, not apply
uniformly."** See `saltzer-schroeder-1975` (fail-safe defaults, least privilege, and the
economy-of-mechanism argument for policies that match their threat model).

## Lines worth carrying into voice chronicle

> A cooldown that cannot tell your own hands from a stranger's is not caution — it is
> friction wearing caution's coat. Trust is a boundary; defend the boundary, not the mirror.

## Sources

See `source-ledger.yaml` — `slsa`, `in-toto-2019`, `ohm-2020`, `eo-14028`,
`saltzer-schroeder-1975`, `pnpm-minimum-release-age`, `w3c-prov-dm`.
