Arcade builds source-build-reference-packages with PublicSign = false
See original GitHub issue- This issue is blocking
- This issue is causing unreasonable pain
Building .NET 6 on RHEL 9 through source-build fails out of the box. There is a detailed investigation of the underlying issue at https://github.com/dotnet/runtime/issues/65874. The TLDR is that source-build uses RSA+SHA1 to sign assemblies, and that operation fails when SHA1 is not available - as is the case in RHEL 9 and being planned for a future version of Fedora.
The errors building source-build look like this:
/home/dotnet/dotnet-sdk-source-6.0.106/.dotnet/sdk/6.0.105/Roslyn/Microsoft.CSharp.Core.targets(75,5): error : Unhandled exception. Interop+Crypto+OpenSslCryptographicException: error:03000098:digital envelope routines::invalid digest [/home/dotnet/dotnet-sdk-source-6.0.106/src/source-build-reference-packages/artifacts/source-build/self/src/src/referencePackages/src/microsoft.bcl.asyncinterfaces/5.0.0/Microsoft.Bcl.AsyncInterfaces.5.0.0.csproj]
src/referencePackages/src/microsoft.bcl.asyncinterfaces/5.0.0/Microsoft.Bcl.AsyncInterfaces.5.0.0.csproj
has this bit of code:
<PropertyGroup>
<TargetFrameworks>netstandard2.0;netstandard2.1;net461</TargetFrameworks>
<NuspecFile>$(ArtifactsBinDir)microsoft.bcl.asyncinterfaces/5.0.0/microsoft.bcl.asyncinterfaces.nuspec</NuspecFile>
<StrongNameKeyId>Open</StrongNameKeyId>
<DisableImplicitFrameworkReferences>false</DisableImplicitFrameworkReferences>
</PropertyGroup>
Setting the StrongNameKeyId
to Open
makes arcade set PublicSign
to false:
And that uses full signing. Based on https://github.com/dotnet/runtime/issues/65874#issuecomment-1058345768, it sounds like we want to switch to <PublicSign>true</PublicSign>
?
Issue Analytics
- State:
- Created a year ago
- Comments:7 (7 by maintainers)
Top GitHub Comments
I interpreted the answer as this (close to what you said):
PublicSign
and offer no other option.I’d suggest that only the Microsoft official build of .NET enable full signing, and possibly only for Windows. Anyone else (like Red Hat) should go with
PublicSign
. I’m unaware of any downside for that.I just filed https://github.com/dotnet/arcade/issues/12515 to track how to make this flexible on arcade’s side (and then we can look at scenario-specific fixes as part of the VMR)