sharpbrick / powered-up

.NET implementation of the LEGO PoweredUp Protocol
MIT License
94 stars 19 forks source link

Linux install failed: nuget reports signature expiration and self-signed certificate #187

Closed smr99 closed 2 years ago

smr99 commented 2 years ago

I got to Step 2 of the install instructions (using Debian linux, with .NET 5) and this is the result. Is it true that a signature needs to be re-done? Or is it an issue on my side? I'm using Debian-provided .NET packages.

$ dotnet tool install --framework net5.0 -g SharpBrick.PoweredUp.Cli [ .... welcome text elided .... ]

error NU3028: Package 'SharpBrick.PoweredUp.Cli 3.4.0' from source 'https://api.nuget.org/v3/index.json': The repository primary signature's timestamp found a chain building issue: UntrustedRoot: self signed certificate in certificate chain error NU3037: Package 'SharpBrick.PoweredUp.Cli 3.4.0' from source 'https://api.nuget.org/v3/index.json': The repository primary signature validity period has expired. The tool package could not be restored. Tool 'sharpbrick.poweredup.cli' failed to install. This failure may have been caused by:

  • You are attempting to install a preview release and did not use the --version option to specify the version.
  • A package by this name was found, but it was not a .NET tool.
  • The required NuGet feed cannot be accessed, perhaps because of an Internet connection problem.
  • You mistyped the name of the tool.

For more reasons, including package naming enforcement, visit https://aka.ms/failure-installing-tool

tthiery commented 2 years ago

I tested it on my slightly outdated pi ... it works there.

I do not sign my packages. So as a package author i am not involved in any signature work in the processing chain. Considering both messages, have you considered checking your system clock? my gut tells me, that there is something wrong there ;)

$ lsb_release -a
No LSB modules are available.
Distributor ID: Raspbian
Description:    Raspbian GNU/Linux 10 (buster)
Release:        10
Codename:       buster

$ dotnet --version
5.0.202

$ dotnet tool install --framework net5.0 -g SharpBrick.PoweredUp.Cli
[... welcome text redacted ...]
You can invoke the tool using the following command: poweredup
Tool 'sharpbrick.poweredup.cli' (version '3.4.0') was successfully installed.

$ dotnet tool list -g
Package Id                    Version      Commands
----------------------------------------------------
sharpbrick.poweredup.cli      3.4.0        poweredup
smr99 commented 2 years ago

Thanks for that. I agree it is likely my system, then. I tried a different tool (nrconfig.tool) and I got the same kind of errors.

tthiery commented 2 years ago

Always glad to help. When you found out, send me a note. I am curious.