Skip to content

Update the sign check to remove the exclusions but only check on sign… #48275

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

Merged
merged 2 commits into from
Apr 11, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,10 @@
</ItemGroup>

<Target Name="ValidateBundledManifestSigning"
Condition=" '$(OS)' == 'Windows_NT' and '$(Architecture)' != 'arm' ">
Condition=" '$(OS)' == 'Windows_NT' and
'$(Architecture)' != 'arm' and
$(BUILD_SOURCEBRANCH) != '' and
Copy link
Member

Choose a reason for hiding this comment

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

You can also check this based on OfficialBuild=true and DotNetSignType=real

$(BUILD_SOURCEBRANCH.Contains('release')) ">
<PropertyGroup>
<SignCheckExe>$(PkgMicrosoft_DotNet_SignCheck)\tools\Microsoft.DotNet.SignCheck.exe</SignCheckExe>
<SignCheckLog Condition="'$(SignCheckLog)' == ''">$(ArtifactsLogDir)\workloadmanifestsigncheck.log</SignCheckLog>
Expand All @@ -60,7 +63,7 @@
<ItemGroup>
<!-- Don't try to validate signing for workload manifests that will be signed as part of post-build signing -->
<BundledManifestsToValidateSigning Include="@(BundledManifests)"
Exclude="Microsoft.NET.Workload.Mono.ToolChain.Current;Microsoft.NET.Workload.Mono.ToolChain.net6;Microsoft.NET.Workload.Mono.ToolChain.net7;Microsoft.NET.Workload.Mono.ToolChain.net8;Microsoft.NET.Workload.Emscripten.Current;Microsoft.NET.Workload.Emscripten.net6;Microsoft.NET.Workload.Emscripten.net7;Microsoft.NET.Workload.Emscripten.net8;Microsoft.NET.Sdk.Aspire">
Exclude="Microsoft.NET.Sdk.Aspire">
<RestoredMsiPathInNupkg>$([MSBuild]::NormalizePath($([System.IO.Directory]::GetFiles('%(RestoredMsiNupkgContentPath)/data/', '*$(MsiArchitectureForWorkloadManifests).msi'))))</RestoredMsiPathInNupkg>
</BundledManifestsToValidateSigning>

Expand Down