fix(keeper): pin @percolatorct/shared to its npm release, not a raw git SHA - #370
fix(keeper): pin @percolatorct/shared to its npm release, not a raw git SHA#370Morenikeoa wants to merge 1 commit into
Conversation
…it SHA package.json pinned @percolatorct/shared to a raw git commit SHA (github:dcccrypto/percolator-shared#052edb5...) resolved via a codeload.github.com tarball with NO integrity hash in pnpm-lock.yaml -- distinct from the already-fixed dcccrypto#326 (which covered the SDK's identical git-SHA pin). A force-push or history rewrite at that ref silently changes what production installs, with no npm provenance and no hash to detect tampering on `pnpm install`, on a hot-wallet-adjacent process. The pinned git SHA's own package.json reports version 1.0.0-beta.8, which is also published to npm (the `beta` dist-tag) with a real sha512 integrity hash. Switched the pin to that exact published version -- same code, now hash-verified on every install. Verified via `pnpm install` (lockfile now carries a sha512 integrity hash for this dependency) + `pnpm build` (clean) + full test suite: 974 passed, 33 skipped, 1 pre-existing unrelated failure (tests/v17-risk-params.poc.test.ts, stale assertion from dcccrypto#345, out of scope here) -- no regressions from the dependency swap. BUG-111 from a clean-room Phase 4 audit pass.
|
Warning Review limit reached
More reviews will be available in 43 minutes and 52 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits. 🚦 How do rate limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (1)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Problem
package.jsonpins@percolatorct/sharedto a raw git commit SHA:Resolved via a
codeload.github.comtarball URL with no integrity hash inpnpm-lock.yaml. This is a second, distinct non-registry dependency from the already-fixed #326 (which covered@percolatorct/sdk's identical git-SHA-pin problem) — same weakness, different package.Production Impact
A force-push or history rewrite at that commit ref (or a compromised GitHub tarball cache) silently changes what production installs, with no npm provenance and no hash to detect tampering on
pnpm install— on a process that holds a hot signing wallet.Fix
The pinned git SHA's own
package.jsonreports"version": "1.0.0-beta.8", which is also published to npm under thebetadist-tag with a realsha512integrity hash. Switched the dependency to that exact version — same code, now hash-verified on every install:pnpm-lock.yamlnow carries asha512integrity hash for this dependency instead of a bare git-tarball reference.Proof of Fix
pnpm install— clean; lockfile entry confirmed to carryintegrity: sha512-....pnpm build— clean, zero errors.tests/v17-risk-params.poc.test.ts— stale assertion from fix(keeper): accept maintenanceMarginBps==10000 (valid fast-path) — found in live devnet test #345, out of scope here). No regressions from the dependency swap, confirming the npm-published1.0.0-beta.8is behaviorally identical to the previously-pinned git SHA.Test Output