Skip to content

Commit 07e47f1

Browse files
authored
Change audit source to data.nuget.org and fix vulnerable package warning (#7300)
1 parent 9240a91 commit 07e47f1

6 files changed

Lines changed: 11 additions & 1 deletion

File tree

Directory.Packages.props

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,6 +96,8 @@
9696
<PackageVersion Include="System.Memory" Version="$(SystemMemoryPackageVersion)" />
9797
<PackageVersion Include="System.Security.Cryptography.Pkcs" Version="$(SystemSecurityCryptographyPkcsVersion)" />
9898
<PackageVersion Include="System.Security.Cryptography.ProtectedData" Version="$(SystemSecurityCryptographyProtectedDataVersion)" />
99+
<!-- S.S.C.Xml is a dependency of MSBuild. Once MSBuild no longer has a transitive dependency on a vulnerable version, this can be removed -->
100+
<PackageVersion Include="System.Security.Cryptography.Xml" Version="8.0.3" />
99101
<PackageVersion Include="System.Text.Json" Version="$(SystemTextJsonVersion)" />
100102
<!--
101103
The Microsoft.VisualStudio.SDK metapackage brings in System.Threading.Tasks.Dataflow 4.11.1 (assembly version 4.9.5.0).

NuGet.Config

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
</packageSources>
1212
<auditSources>
1313
<clear />
14-
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
14+
<add key="nuget.org" value="https://data.nuget.org/v3/index.json" />
1515
</auditSources>
1616
<packageSourceMapping>
1717
<clear />

build/common.project.props

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,8 @@
5252
<SuppressTfmSupportBuildWarnings>true</SuppressTfmSupportBuildWarnings>
5353
<DisableImplicitNuGetFallbackFolder>true</DisableImplicitNuGetFallbackFolder>
5454
<Nullable>enable</Nullable>
55+
<!-- NuGetAuditMode only defaults to all when targeting net10.0 or higher, which many projects do not -->
56+
<NuGetAuditMode>all</NuGetAuditMode>
5557
</PropertyGroup>
5658

5759
<!-- Defaults -->

eng/pipelines/official.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,8 @@ variables:
3030
extends:
3131
template: azure-pipelines/MicroBuild.1ES.Official.yml@MicroBuildTemplate
3232
parameters:
33+
settings:
34+
networkIsolationPolicy: Permissive,CFSClean
3335
sdl:
3436
sourceAnalysisPool: VSEng-MicroBuildVSStable
3537
binskim:

eng/pipelines/pull_request.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,8 @@ variables:
2727
extends:
2828
template: azure-pipelines/MicroBuild.1ES.Unofficial.yml@MicroBuildTemplate
2929
parameters:
30+
settings:
31+
networkIsolationPolicy: Permissive,CFSClean
3032
sdl:
3133
sourceAnalysisPool: VSEng-MicroBuildVSStable
3234
binskim:

src/NuGet.Core/NuGet.Build.Tasks.Pack/NuGet.Build.Tasks.Pack.csproj

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@
3737
<PackageReference Include="Microsoft.Build.Framework" ExcludeAssets="runtime" GeneratePathProperty="true" />
3838
<PackageReference Include="Microsoft.Build.Tasks.Core" ExcludeAssets="runtime" GeneratePathProperty="true" />
3939
<PackageReference Include="Microsoft.Build.Utilities.Core" ExcludeAssets="runtime" GeneratePathProperty="true" />
40+
<!-- MSBuild has a dependency on a vulnerable version of System.Security.Cryptography.Xml. Once MSBuild no longer has a transitive dependency on a vulnerable version, this can be removed -->
41+
<PackageReference Include="System.Security.Cryptography.Xml" />
4042
</ItemGroup>
4143

4244
<ItemGroup>

0 commit comments

Comments
 (0)