-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] npm 7.x does not send Authorization
header to download package tarball from private registry
#1960
Comments
Authorization
header to download package tarball from private registry
thank you for the detailed bug report! we released 7.0.1 of npm last night that includes a patch that i believe should resolve this for you. when you get a chance can you try updating with |
Everything works great now, thank you for the quick fix! |
@nlf I believe I'm running into this issue still.
The logs on
Environment:OS: macOS 11.1 .npmrc:
|
|
Current Behavior:
npm 7 does not send
Authorization
header when downloading package tarball from private registry even if it DOES send it to get package packument from the same registry.As a result, it fails to install private packages (at least for Verdaccio-based registries).
Expected Behavior:
Authorization
header should be sent to download package tarball from private registry (as in npm 6).Steps To Reproduce:
npm i
in a package that depends on a package from private scopeExample
I've inspected requests that npm6 and npm7 makes to install my package.
Here is request dump from Wireshark (I replaced my private scope name with word
PRIVATESCOPE
, my access token withACCESSTOKEN
and my private registry domain withPRIVATEDOMAIN
)npm 6 requests package packument (with token):
npm 6 downloads package tarball (with token):
npm 7 requests package information (with token):
npm 7 downloads package tarball (without token):
Response to the latest request:
Environment:
The text was updated successfully, but these errors were encountered: