Valid provenance says where the package was built and nothing more
In September and October, two npm packages shipped malicious code through their own release pipeline. One of them with valid provenance. What the signature attests, what stays unchecked and where to look on your side.
What happened
On 22 September 2026, Orca Security described an attack on the npm package @dforge-core/dforge-mcp. On 9 September 2026, the attackers take over the maintainer’s account and change the release workflow in GitHub Actions. After the change, every push to main triggers an automatic release through OIDC trusted publishing. That turns the right to push into the right to publish.
Version 0.2.21 carries the GHAPPIER loader: a single malicious line, hidden on line 3320 of a 99KB configuration file. The release has valid provenance through GitHub Actions OIDC, and the attestation is recorded in Sigstore’s public log. The payload only runs when the MCP server starts, not at install time. Its last stage opens a remote shell and deletes itself from disk. Version 0.2.21 is the latest for about 35 minutes, until the maintainer publishes a clean 0.2.22. Version 0.2.20 is also an attempted malicious release, but it breaks the install. At the time Orca published, there is no CVE and no advisory in OSV or in the GitHub Advisory Database.
Orca explains the attack in one sentence: “The attack exploited a fundamental limitation of npm trusted publishing: provenance attests where an artifact was built, not whether its source was honest.” Provenance attests which build the artefact comes from. Whether the code is honest, it does not say.
On 5 October 2026, StepSecurity described a second case. @subql/common 5.8.3 contains a hidden payload that collects credentials and gives a remote shell. It runs at install time, through postinstall, and again when the package is imported. It targets developer machines and CI environments, including runners in GitHub Actions.
A temporary branch, chore/ci-audit-55, appears in the repo. The first commit switches the publish workflow to a canary release and publishes 5.8.3-onf-rt1, whose code matches 5.8.2. The provenance record for that version points to an Actions run that is no longer accessible. The branch is deleted and created again. A second commit adds a step that downloads an archive from ci-artifacts.dev and uses it to replace packages/common right before publishing. StepSecurity writes: “There is no hash or signature verification of that external archive in the added step.” And further on: “The external replacement therefore lies between building repository source and publishing the package.”
It takes 33 minutes from the branch being created at 11:23 to 5.8.3 appearing in npm at 11:56 UTC. At the time of the check, main still points to the common parent of the two commits. The article does not establish how the account was taken over, and both commits are unsigned.
What they show
Provenance answers where the package comes from: which repo and which Actions run. For GHAPPIER that answer is correct. The package really does come from a build in the project’s workflow. Only the workflow now belongs to the attacker.
With SubQuery, the build runs from the code in the repo, but the files that reach npm come from someone else’s server. The swap happens between the build and the publish. main is untouched, and the branch lives for minutes. A review of main would have seen nothing.
Both cases go through the same place: the release workflow. Whoever can change it, or create a branch it runs from, publishes in the project’s name.
For 0.2.21 there was no CVE and no advisory. A check that looks for known vulnerabilities would not have caught it.
How I look at it in the course
The pipeline is a series of steps on every commit: build, tests, vulnerability scan, deploy, monitoring. If a step fails, the ones after it do not run. In the DevOps course at TU-Sofia, students write their pipeline in GitHub Actions on top of the lab template. The pipeline scans the image for vulnerabilities, because it may contain a library with a known vulnerability. Automatic deploy is dangerous without CI, because it will ship broken code too.
The release workflow is the same deploy, only to npm. Green there says the steps passed. Who wrote them, green does not say.
Infrastructure as code goes through a pull request and review like any other code. Workflow files deserve the same review and more attention, because they hold the right to publish.
The Zero Trust model says that no connection is trusted by default. Valid provenance proves one connection: between the package and the run that built it. The connection between the run and honest code needs a separate check.
What to check on your side
- The lockfiles. Look for @dforge-core/dforge-mcp 0.2.21 and 0.2.20 and @subql/common 5.8.3. Orca recommends 0.2.22 or later. StepSecurity recommends excluding 5.8.3 from transitive dependencies as well: @subql/cli, @subql/node-core and others have ranges that can resolve to it.
- Credentials. Both sources recommend rotating everything the process could reach, on every machine and every runner where these versions ran.
- The release workflow’s triggers: which branches and events it runs from. Orca recommends monitoring changes to them.
- Steps that download something from outside without checking a hash. In SubQuery, exactly such a step replaces the package.
- The events in GitHub: branches and workflows created and deleted. The SubQuery payload tries to add a “Run Copilot” workflow to up to five repos, which reads secrets through toJSON(secrets). StepSecurity recommends reviewing the create and delete events in GitHub Actions.
- Who has push rights on the branch the release runs from.
- The provenance of a dependency you update: which commit the build ran from and whether that commit is in main.
My next step
The next thing I am doing is an exercise for the security lab: a release workflow in which students swap a step themselves and see that the provenance stays valid.
Sources
- Orca Security, “GHAPPIER Loader”, 22.09.2026: https://orca.security/resources/research/ghappier-loader-npm-supply-chain-attack/
- StepSecurity, “SubQuery Ecosystem Compromise: Hidden Credential Theft and Backdoors”, 5.10.2026: https://www.stepsecurity.io/blog/subql-ecosystem-compromised