You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[ ] Check if this is a typo or other quick fix and ignore the rest :)
## Type of change
Update to JavaScript verification content
### What should this PR do?
Explain how chainctl libraries verify works for JavaScript packages
### Why are we making this change?
New chainctl functionality:
https://github.com/chainguard-dev/mono/pull/37476/changes
### What are the acceptance criteria?
Content should be clear and accurate, and appear in the correct location
### How should this PR be tested?
Review the deploy preview
---------
Signed-off-by: s-stumbo <sally.stumbo@chainguard.dev>
To integrate this into your build pipeline, add the verification step after
212
212
dependency resolution and before the packaging phase.
213
213
214
-
### Analyze an npm tarball
214
+
### Analyze JavaScript packages
215
+
216
+
`chainctl libraries verify` can scan local package manager caches and stores
217
+
to confirm that your installed JavaScript packages were built by Chainguard. It supports the following JavaScript package managers:
218
+
219
+
- pnpm store: auto-detected by `v10/index/` or `v11/index/` structure (pnpm v10 and v11 supported)
220
+
- npm cache: auto-detected by `_cacache/index-v5/` structure
221
+
- Yarn Classic: v1.x, requires `yarn:` prefix
222
+
223
+
#### Analyze an npm tarball
215
224
216
225
Verify an npm package tarball to confirm it was built by Chainguard:
217
226
@@ -224,7 +233,66 @@ and `9.0.0`)
224
233
225
234
Verification uses SLSA provenance attestations. `chainctl` computes a SHA-512 digest of the tarball locally, fetches the signed attestation bundle, and uses `cosign` to confirm that the signature is valid, the certificate chains to the Sigstore root, the signer identity matches the Chainguard JavaScript builder, and the digest matches what was attested at build time.
226
235
227
-
Verification currently operates on individual npm tarballs.
236
+
#### Verify an npm cache
237
+
238
+
Verify your npm cache:
239
+
240
+
```sh
241
+
chainctl libraries verify "$(npm config get cache)"
242
+
```
243
+
244
+
#### Verify a pnpm store
245
+
246
+
Verify your pnpm store:
247
+
248
+
```sh
249
+
chainctl libraries verify "$(pnpm store path)"
250
+
```
251
+
252
+
pnpm v9 and earlier are not supported. Verification works by comparing
253
+
the tarball hash recorded in your local store against the hash in Chainguard's
254
+
signed SLSA attestation. pnpm v10 records this hash in the index file path;
0 commit comments