nodejs / nodejs/corepack

Corepack does not work with COREPACK_NPM_REGISTRY that does not return signatures (Artifactory)

Open
#725 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
TypeScript
Stars
3.8k
Forks
279
Avg merge
1h 47m
Merged PRs (30d)
2

Description

Related to https://github.com/nodejs/corepack/issues/537 and https://github.com/nodejs/corepack/issues/570

Corepack does not work with our registry as it does not return the field dist.signatures.
Here's a comparison of https://registry.npmjs.org/pnpm/10.12.4 and <our-artifactory-host>/artifactory/api/npm/default-npm-3rdparty/pnpm/10.12.4

npmjs:

"dist": {
    "shasum": "88a0ccfe72d6345dede50dc9d6158400be2420eb",
    "tarball": "https://registry.npmjs.org/pnpm/-/pnpm-10.12.4.tgz",
    "fileCount": 1111,
    "integrity": "sha512-Xqiw3u2U7WhpHJutTJVUknBcXuuKh++GvGLHSiawN7CP+VcPEIsuTb0d0akYb+qSXlJ/FBxkjoWvRWMQdGgBhA==",
    "signatures": [
      {
        "sig": "MEUCIHgFNYCynawsQj2TFih8MSo5NU8irHoWSjYIWoFdjXsUAiEArLjxP+kP0pDgYCk1HfGfrLjxph157UO/0WcQTCDmxTM=",
        "keyid": "SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"
      }
    ],
    "unpackedSize": 17665923
  },

artifactory:

"dist" : {
    "tarball" : "<our-artifactory-host>/artifactory/api/npm/default-npm-3rdparty/pnpm/-/pnpm-10.12.4.tgz",
    "shasum" : "88a0ccfe72d6345dede50dc9d6158400be2420eb",
    "integrity" : "sha512-Xqiw3u2U7WhpHJutTJVUknBcXuuKh++GvGLHSiawN7CP+VcPEIsuTb0d0akYb+qSXlJ/FBxkjoWvRWMQdGgBhA=="
  },

Interestingly, <our-artifactory-host>/artifactory/api/npm/default-npm-3rdparty/pnpm/ returns the dist field just like npmjs, including signatures.

So maybe it is feasible to fetch the whole JSON for all versions as a fallback?

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No file or test is named. Start by tracing how COREPACK_NPM_REGISTRY responses and the dist.signatures field are handled, then compare metadata from npmjs and Artifactory endpoints. Done means Corepack can handle the reported registry response without breaking signature verification or package-manager resolution.

Written by the indexing model from the issue text.

Assessment

Tech stack
node.js, typescript
Domain
devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.