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

Signing: improve signing related error messages #6906

Closed
mishra14 opened this issue May 5, 2018 · 2 comments
Closed

Signing: improve signing related error messages #6906

mishra14 opened this issue May 5, 2018 · 2 comments
Assignees
Labels
Area:ErrorHandling warnings and errors/log messages & related error codes. Functionality:Signing Priority:2 Issues for the current backlog. Type:Bug
Milestone

Comments

@mishra14
Copy link
Contributor

mishra14 commented May 5, 2018

We should improve signing related error messages in the following ways -

  1. Add the package identity as part of the message.
  2. Add reason for generic messages.

For example -
NU3008: Package is not signed. should be NU3008: {PackageRepository} declared that all its packages are repository signed. But package A v1.0.0 is not signed.

@mishra14 mishra14 added Priority:1 High priority issues that must be resolved in the current sprint. Area:ErrorHandling warnings and errors/log messages & related error codes. Functionality:Signing labels May 5, 2018
@mishra14 mishra14 added this to the Backlog milestone May 5, 2018
@dtivel dtivel changed the title Improve singing related error messages Signing: improve signing related error messages May 7, 2018
mishra14 pushed a commit to NuGet/NuGet.Client that referenced this issue May 8, 2018
## Bug
Fixes: NuGet/Home#6903
Regression: No

## Fix
Details: As part of e91dbf3 we added support for verifying package signature on unzip. Any errors results in throwing of a new `SignatureException` with actual results inside `SignatureException.Results`. In install command that exception was not throws as is and this resulted in empty logging on the console - 

```
C:\>NuGet.exe install <package>
...
NU3000:
```

This PR fixes this - 

```
F:\validation\test>NuGet.exe install <package>
...
WARNING: NU3027: The signature should be timestamped to enable long-term signature validity after the certificate has expired.
NU3008: The package integrity check failed.
```

## Testing/Validation
Tests Added: Yes  
Validation done:  manual validation

I have opened the following issues - 
https://github.com/NuGet/Home/issues/6905: Add infrastructure to support mock https server
NuGet/Home#6906: Improve singing related error messages
@rrelyea rrelyea modified the milestones: Backlog, 4.8 Jun 15, 2018
@rrelyea rrelyea modified the milestones: 4.8, 4.9 Jul 19, 2018
@mishra14
Copy link
Contributor Author

The scenario is improved in NuGet/NuGet.Client#2360 where we have added prefix to all signing logs. Adjusting labels.

@mishra14 mishra14 removed their assignment Jul 23, 2018
@mishra14 mishra14 added Priority:2 Issues for the current backlog. and removed Priority:1 High priority issues that must be resolved in the current sprint. Sprint 137 labels Jul 23, 2018
@mishra14
Copy link
Contributor Author

mishra14 commented Jul 23, 2018

@PatoBeltran you would want to fix the error messages for NU3034 and NU3004 once we enable client policy.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area:ErrorHandling warnings and errors/log messages & related error codes. Functionality:Signing Priority:2 Issues for the current backlog. Type:Bug
Projects
None yet
Development

No branches or pull requests

3 participants