← Home

rewire

Easy dependency injection for node.js unit testing

48
Versions
MIT
License
No
Install Scripts
Missing
Provenance

Supply chain provenance

Status for the latest visible version.

No SLSA provenance npm registry signatures gitHead linked

Without SLSA provenance there is no cryptographic link between this tarball and the public source — the axios compromise (March 2026) relied on exactly this gap.

Maintainers

jhnnspeeri

Keywords

dependencyinjectionmockshimmoduleunittestleakinspectfakerequire

Accepted risks

Findings the reviewer chose to accept rather than block on.

SourceRuleReasonAccepted byWhen
semgrep semgrep:eval-usage AI (semgrep): rewire's __get__ intentionally uses eval() to read private module variables by name — this is the package's core documented mechanism for unit test dependency injection, not a supply-chain risk. ai
publish-pattern new-deps-added AI (publish-pattern): pirates is a well-known, reputable module-hooking library widely used in the JS ecosystem; its addition to rewire is consistent with legitimate module interception functionality. ai

Versions (showing 48 of 48)

Version Deps Published
9.0.1 2 / 7
9.0.0 1 / 7
8.0.0 1 / 7
7.0.0 1 / 7
6.0.0 1 / 5
5.0.0 1 / 4
4.0.1 1 / 3
4.0.0 1 / 3
3.0.2 2 / 3
3.0.1 2 / 3
3.0.0 2 / 3
2.5.2 0 / 3
2.5.1 0 / 3
2.5.0 0 / 3
2.4.0 0 / 3
2.3.4 0 / 3
2.3.3 0 / 3
2.3.2 0 / 3
2.3.1 0 / 3
2.3.0 0 / 3
2.2.0 0 / 3
2.1.5 0 / 3
2.1.4 0 / 3
2.1.3 0 / 3
2.1.2 0 / 3
2.1.1 0 / 3
2.1.0 0 / 3
2.0.1 0 / 3
2.0.0 0 / 3
1.1.3 0 / 3
1.1.2 0 / 3
1.1.1 0 / 5
1.1.0 0 / 5
1.0.4 0 / 4
1.0.3 0 / 4
1.0.2 0 / 4
1.0.1 0 / 4
1.0.0 0 / 4
0.3.2 0 / 3
0.3.1 0 / 3
0.3.0 0 / 3
0.2.2 0 / 2
0.2.1 0 / 2
0.2.0 0 / 2
0.1.3 1 / 2
0.1.2 1 / 2
0.1.1 1 / 2
0.1.0 1 / 2

v9.0.1

1 finding
LOW No provenance attestation provenance

Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v9.0.0

1 finding
LOW No provenance attestation provenance

Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.

v8.0.0

1 finding
LOW No provenance attestation provenance

Package was published without Sigstore provenance. Consider requesting the maintainer enable provenance via CI/CD.