Skip to content
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

[Cross-platform Dotnet Nuget Sign] No certificate info shows when running dotnet nuget sign on default verbosity #11173

Open
v-luzh opened this issue Aug 20, 2021 · 4 comments

Comments

@v-luzh
Copy link

v-luzh commented Aug 20, 2021

Details about Problem

NuGet version: NuGet Client Dev\6.0.0.204
VS Version: Main\31617.326
OS: Windows-10-Enterprise-21H1

Detailed repro steps

  1. Git clone https://github.com/NuGet/Entropy.git to Windows VM.
  2. Copy the “SDKPatchTool” folder from https://github.com/NuGet/Entropy.git to the desktop of Linux VM.
  3. Copy the “Nupkgs” folder of the NuGet build to the desktop of Linux VM.
  4. Go to the “SDKPatchTool” folder on Linux, and edit the paths in the “patchOnUnix.ps1”.
  5. Open a bash on Linux, cd to the “SDKPatchTool” folder path and run “patchOnUnix.ps1” script: ./patchOnUnix.ps1.
  6. On Windows VM, create a C# Class Library (.NET 6.0) project and pack it with command dotnet pack.
  7. On Windows VM, cd to <path_to_Entropy>\TestCertGenerator and create a new test certificate: .\CreateTestCertificate.ps1 -AddAsTrustedRootAuthority -Password password -GenerateCerFile in powershell.
  8. Copy the “*.nupkg” file (created in step6), “.cer” file and the “.pfx” file from the above Windows machine to Linux machine.
  9. Change the .cer to .crt format: openssl x509 -inform DER -in <.cer file path> -out <.crt file path> on Linux
  10. Add the certificate(.crt) to trusted store on Linux:
      cd /usr/local/share/ca-certificates/ 
      sudo cp <.crt file path>  ./ 
      sudo chmod 644 ./<.crt file name> 
      sudo update-ca-certificates 
  1. Run ./dotnet nuget sign <PackageFilePath> --certificate-path <PfxFilePath> --certificate-password password on Linux.

Expected Result

There is certificate info when signing with Dotnet Nuget Sign Command.

Actual Result

No certificate info show when signing with Dotnet Nuget Sign Command as below screenshot.
image

Notes:

1.It is not a regression since it’s a new feature.
2.It repro on Linux/Windows/Mac.
3.Workaround: add an option “-v n” at the end of the signing command.

@nkolev92 nkolev92 changed the title [Dotnet Nuget Sign] No certificate info shows when signing/verifying with Dotnet Nuget Sign Command until adding option “-v" [Dotnet Nuget Sign] No certificate info shows when running dotnet nuget verify on default verbosity Aug 21, 2021
@nkolev92
Copy link
Member

@v-luzh
I was not able to repro this on Windows.

Can you post the output from dotnet nuget verify please?

Please copy the console values instead of a screenshot. Thanks!

@v-luzh
Copy link
Author

v-luzh commented Aug 23, 2021

Hi @nkolev92, sorry, this bug just repro when signing, doesn't repro when verifying. Updated the bug.

@v-luzh v-luzh changed the title [Dotnet Nuget Sign] No certificate info shows when running dotnet nuget verify on default verbosity [Dotnet Nuget Sign] No certificate info shows when running dotnet nuget sign on default verbosity Aug 23, 2021
@heng-liu heng-liu self-assigned this Aug 23, 2021
@heng-liu heng-liu added this to the Sprint 2021-08 milestone Aug 23, 2021
@heng-liu heng-liu added the Category:Quality Week Issues that should be considered for quality week label Aug 23, 2021
@heng-liu
Copy link
Contributor

heng-liu commented Oct 4, 2021

As per comments, it would be better to confirm with both NuGet PM and the .NET CLI PMs about the verbosities.

@nkolev92 nkolev92 modified the milestones: Sprint 2022-04, Sprint 2022-05 Apr 25, 2022
@heng-liu heng-liu removed this from the Sprint 2022-05 milestone May 2, 2022
@v-luzh v-luzh changed the title [Dotnet Nuget Sign] No certificate info shows when running dotnet nuget sign on default verbosity [Cross-platform Dotnet Nuget Sign] No certificate info shows when running dotnet nuget sign on default verbosity Sep 29, 2022
@jebriede jebriede added Priority:2 Issues for the current backlog. and removed Triage:NeedsTriageDiscussion Triage:NeedsRepro labels Nov 13, 2023
@v-luzh
Copy link
Author

v-luzh commented Aug 23, 2024

It still reproes on .NET SDK Version: 8.0.400-rtm.24367.3 patched with Dev\6.12.0.33

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants