T08 · Insecure Dependencies
- Location
readme.md:41- Finding
Unpinned External Package Receives Payment Provider Credentials
- Content
View full analysis
Vulnerability Details
File Location:
readme.md:41-60,readme.md:102; duplicated inskill.md:99-124
Vulnerability Type: Unverified and unpinned third-party dependency
Risk Level: MediumThe documentation instructs users to install an external npm package without pinning an exact version, providing a lockfile, or supplying integrity verification. The application then passes a Stripe API key to code whose implementation is absent from this project.
Relevant code from
readme.md:41-60:bash npm install openclaw-agent-payment-railbash export STRIPE_API_KEY="sk_test_..."typescript import { PaymentRail } from 'openclaw-agent-payment-rail'; const rail = new PaymentRail(); // Initialize await rail.initialize({ provider: 'stripe', apiKey: process.env.STRIPE_API_KEY, });The README also recommends a global installation at
readme.md:102:bash npm install -g openclaw-agent-payment-railEquivalent instructions appear in
skill.md:99-124:bash npm install openclaw-agent-payment-railbash # Stripe export STRIPE_API_KEY="sk_test_..." # PayPal (coming soon) export PAYPAL_CLIENT_ID="..." export PAYPAL_CLIENT_SECRET="..."typescript import { PaymentRail } from 'openclaw-agent-payment-rail'; const rail = new PaymentRail(); await rail.initialize({ provider: 'stripe', apiKey: process.env.STRIPE_API_KEY, });Technical Analysis
The artifact contains only documentation and does not include the implementation of the advertised payment operations. All substantive functionality is delegated to
openclaw-agent-payment-rail.The installation command does not pin an exact version. npm may therefore resolve a later release than the one originally reviewed. The artifact also provides no lockfile, package integrity hash, vendored source, signed provenance, or checksum through which users can verify the installed implementation. npm packages may execute lifecycle scripts during installation ...[truncated 2228 chars]
- Remediation
View remediation
Remediation Suggestions
- Pin the dependency to an exact reviewed version rather than allowing npm to select the latest compatible release.
- Commit a lockfile containing npm integrity metadata and require reproducible, lockfile-enforced installation such as
npm ci. - Include or vendor the implementation source in the audited artifact so payment and credential-handling behavior can be reviewed.
- Publish and verify release provenance, signatures, or cryptographic checksums for the approved package.
- Avoid recommending global installation unless the CLI is essential. Prefer a project-local dependency invoked through a pinned script.
- Where compatible, install with lifecycle scripts disabled and explicitly review any scripts before enabling them.
- Use restricted payment-provider credentials with only the permissions required for the documented operations.
- Use test-mode keys during development, isolate production credentials, rotate keys regularly, and revoke them immediately after suspected dependency compromise.
- Run payment integrations in a constrained service account or container with minimal filesystem access, restricted outbound networking, and no unrelated secrets in its environment.
- Add dependency monitoring and require security review before updating the approved package version.
