DuendeSoftware / Support

Support for Duende Software products
20 stars 0 forks source link

Build error NU3042 when using Duende.IdentityServer.AspNetIdentity 7.0.6 on linux #1355

Closed pregress closed 1 month ago

pregress commented 1 month ago

Which version of Duende IdentityServer are you using? 7.0.6

Which version of .NET are you using? SDK: 8.0.303 (current latest)

Describe the bug When building on linux using a msft docker image: eg mcr.microsoft.com/dotnet/sdk:8.0 We receive the following build error (warning as error):

/data/jenkins/workspace/REDACTED/REDACTED.csproj : error NU3042: Warning As Error: Package 'Duende.IdentityServer.AspNetIdentity 7.0.6' from source 'https://api.nuget.org/v3/index.json': The following X.509 root certificate is untrusted because it is not present in the certificate bundle at /usr/share/dotnet/sdk/8.0.303/trustedroots/codesignctl.pem. For more information, see documentation for NU3042.

To Reproduce

  1. Reference Duende.IdentityServer.AspNetIdentity 7.0.6 in a csproj
  2. Enable warning as error for the csproj
  3. build/pubslish it using mcr.microsoft.com/dotnet/sdk:8.0 on linux in release

Expected behavior

Successful build, without warnings.

Log output/exception with stacktrace

/data/jenkins/workspace/REDACTED/REDACTED.csproj : error NU3042: Warning As Error: Package 'Duende.IdentityServer.AspNetIdentity 7.0.6' from source 'https://api.nuget.org/v3/index.json': The following X.509 root certificate is untrusted because it is not present in the certificate bundle at /usr/share/dotnet/sdk/8.0.303/trustedroots/codesignctl.pem.  For more information, see documentation for NU3042.

Additional context

https://learn.microsoft.com/en-us/nuget/reference/errors-and-warnings/nu3042

pregress commented 1 month ago

Closed, duplicate of #1352