Skip to content

Disable Nuget Audit in VMR builds - #5600

Merged
akoeplinger merged 1 commit into
dotnet:release/10.0.1xxfrom
mmitche:disable-nuget-audit
Mar 20, 2026
Merged

akoeplinger merged 1 commit into
dotnet:release/10.0.1xxfrom
mmitche:disable-nuget-audit

Conversation

@mmitche

@mmitche mmitche commented Mar 20, 2026

Copy link
Copy Markdown
Member

No description provided.

@mmitche
mmitche requested review from a team as code owners March 20, 2026 00:10

@ViktorHofer ViktorHofer left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We shouldn't do this. NuGet Audit uses nuget.org or azdo as an audit source implicitly. So it works today in official builds. We were also in discussion with azdo on supporting audit from anonymous builds.

What is this trying to fix?

@akoeplinger

akoeplinger commented Mar 20, 2026 •

Copy link
Copy Markdown
Member

@ViktorHofer see the discussion on Teams. we need to get this in to fix the VMR build which got broken when we enabled CFSClean.

@ViktorHofer

Copy link
Copy Markdown
Member

Disabling this security feature doesn't feel right. If you can't remove the auditSource from nuget repo's NuGet.config for whatever reason, just remove the entry at build time. We already mutate each repo's NuGet.config.

@akoeplinger

Copy link
Copy Markdown
Member

I agree but we should unbreak the buuld first

@ViktorHofer

Copy link
Copy Markdown
Member

Ok. I'm just saying that this is the wrong course of action. There is no to do marker or any context on this PR suggesting that this is only for a short period of time.

@ViktorHofer

Copy link
Copy Markdown
Member

Cant you just set this property as a build argument only in nuget-client.proj?

@akoeplinger

Copy link
Copy Markdown
Member

ah I didn't see this was set for all projects, I agree we should only do it for nuget-client. I'd still prefer to get this PR in to fix the build and will file a follow-up PR

@ViktorHofer
ViktorHofer dismissed their stale review March 20, 2026 09:23

Dismissing my request for changes to unblock any efforts here. I already shared my concerns with this approach.

@akoeplinger
akoeplinger merged commit df857ae into dotnet:release/10.0.1xx Mar 20, 2026
11 checks passed
@akoeplinger

Copy link
Copy Markdown
Member

/backport to main

@github-actions

Copy link
Copy Markdown
Contributor

Started backporting to main (link to workflow run)

@mmitche

mmitche commented Mar 20, 2026

Copy link
Copy Markdown
Member Author

@ViktorHofer Is the concern about local builds? Because any official build will not be able to hit nuget.org.

@mmitche

mmitche commented Mar 20, 2026

Copy link
Copy Markdown
Member Author

Disabling this security feature doesn't feel right. If you can't remove the auditSource from nuget repo's NuGet.config for whatever reason, just remove the entry at build time. We already mutate each repo's NuGet.config.

True, that seems like a better approach. But, either way, NuGet AUdit is not going to work in official builds against nuget.org, because that endpoint is blocked

@mmitche

mmitche commented Mar 20, 2026

Copy link
Copy Markdown
Member Author

@ViktorHofer I don't think it uses nuget.org by default if not specified, or the docs are wrong.

If auditSources is not defined or is cleared without adding any sources, then packageSources will be used and warning NU1905 is suppressed.

https://learn.microsoft.com/en-us/nuget/concepts/auditing-packages#audit-sources

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants