Skip to content
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

Add .npmrc file #1722

Merged
merged 1 commit into from
Jan 22, 2024
Merged

Add .npmrc file #1722

merged 1 commit into from
Jan 22, 2024

Conversation

eerhardt
Copy link
Member

@eerhardt eerhardt commented Jan 19, 2024

Resolves a Security Supply Chain Violation

I copied this file and approach from https://github.com/dotnet/aspnetcore/blob/main/.npmrc.

Fix #1670

Microsoft Reviewers: Open in CodeFlow

Resolves a Security Supply Chain Violation

Fix dotnet#1670
@dotnet-issue-labeler dotnet-issue-labeler bot added the needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners label Jan 19, 2024
@@ -0,0 +1,2 @@
registry=https://pkgs.dev.azure.com/dnceng/public/_packaging/dotnet-public-npm/npm/registry/
always-auth=true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this line is specific to aspnet core, and not even sure it's required anymore.
Had to deal with it during the holidays. If you look at all the other dotnet repos they don't have it. It's supposed to allow azdo to authenticate to the feeds (all the upstream ones) using the tokens configured in azdo. But these are public and shouldn't require auth. That's what I understood.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sebastienros not exactly. other repos don't do this b/c they don't use npm or yarn. and, auth is for updating the feed when an authorized person like you grabs packages from the upstream feed and updates lock files

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Javier told me 2 weeks ago and I already had forgotten.

So I believe we don't need that here. There is nothing that requires the feed to be updated (packages.lock file), right @eerhardt ?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm just following the docs from the error: https://aka.ms/cfs/npm. See Mitigation Steps section.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I merged what I had to unblock the supply chain validation. We can tweak this as we go.

@danmoseley danmoseley added area-engineering-systems and removed needs-area-label An area label is needed to ensure this gets routed to the appropriate area owners labels Jan 19, 2024
@mitchdenny mitchdenny added this to the preview 3 (Feb) milestone Jan 21, 2024
@eerhardt eerhardt merged commit 3c99c90 into dotnet:main Jan 22, 2024
8 checks passed
@eerhardt eerhardt deleted the Addnpmrc branch January 22, 2024 16:41
@github-actions github-actions bot locked and limited conversation to collaborators Apr 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

npmrc file missing for test project
6 participants