Unreviewed code from an unrelated package can execute in the install environment.
What to do: remove this version and, if it ran, rotate the credentials it could reach. Remediation↓
AI security review
scanned · by lpm-firewall-ai
The preinstall hook automatically runs an external package command unrelated to the payment-card component, without disclosure. The install-time execution is reachable and meets the remote-code rule for blocking.
Static reason
One or more suspicious static signals were detected.
Trigger
Package installation, through the preinstall lifecycle.
Mechanism
The script runs `npx force-resolutions`, which can fetch and execute that package from the configured npm registry when it is not already available. This behavior is not disclosed as part of the card library's install instructions.
Attack narrative
On installation, the package runs `npx force-resolutions`, invoking external package code without disclosing that execution in its card-library install instructions.
Evidence
package.jsonREADME.md
Decision evidence
public snapshot
Evidence for block
The package runs `npx force-resolutions` in its preinstall lifecycle, so installing it invokes an external package command automatically.
The manifest declares only two runtime dependencies, neither of which is force-resolutions.
The package describes itself as a JavaScript payment-card library; its documented install step does not disclose the force-resolutions command.
Evidence against
The exported runtime bundle provides a Card component, and searches found no network or process-execution primitives in the bundle.
Behavioral surface
SourceNo risky source behavior triggered.
Supply chainMinified
ManifestNo manifest risk signals triggered.
Scanned 2 files · 156 KB of source
Findings
4 high · 1 medium · 1 low
Where they are, most severe file first. Code opens a file's flagged lines, with their evidence, below.
Avoid installing @trustpayments/js-payments-card@2.2.1256. Remove it from direct dependencies and check your lockfile for transitive copies.
Choose an independently verified alternative or release. This report does not establish that other versions are safe.
If this version ran, investigate the affected machine and build environment. Rotate credentials it could access and rebuild from a trusted environment.