-
Notifications
You must be signed in to change notification settings - Fork 91
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
Unable to Authenticode sign using version 0.9.1-beta.24406.1 #764
Comments
@martincostello, can you try the latest version of Sign CLI just uploaded to NuGet.org? https://www.nuget.org/packages/sign/0.9.1-beta.24469.1 BTW, this is unrelated to the above issue, but your CI output includes the warning:
These options are deprecated:
Going forward, these values should be passed using environment variables:
|
@dtivel Still failing with
Looking at our validation step, it seems like the
|
The readme still links to a sample AzDO yaml file which uses the obsolete options (https://github.com/dotnet/sign#sample-workflows): sign/docs/azdo-build-and-sign.yml Lines 87 to 89 in 8b9d88d
|
Just hit this with Silk.NET as well. Will continue using the old version. |
Hi, Looks like the issue in both cases here are the access policies for the identity accessing key vault. The required permissions are: Key: With HSM keys, it won't return the private key material, but will still return metadata about the key, such as size. @ChrisSfanos Are you able to update the access policies for the key vaults used by DNF projects to ensure the permissions are set accordingly? This may be a change from the way they were originally set up. |
Thanks Claire - The App access policy did only have Sign for Key permissions, so I've added Get to it (this should support the 'old' way - when we migrate to using managed identities, we will need to do work again to provide an access policy) If this works, I'll make the same change to Silk.NET for @Perksey |
Thanks @ChrisSfanos - I'll re-test our signing pipeline with the new version tomorrow and get back to you. |
Testing for dotnet/sign#764.
Looks like the permissions change in Azure was the fix - I've tested with the latest sign version here, and everything now seems to be working as expected: App-vNext/Polly#2383. Thanks everyone. |
Thanks Martin - I've made the same change for Silk.NET too |
Describe the bug
In Polly we Authenticode sign our assemblies and NuGet packages using a code signing certificate provided by the .NET Foundation.
Trying to release a new version today, signing failed with errors trying to download the key.
Since our last release, v8.4.1, we had ingested three dependabot updates for sign (App-vNext/Polly#2178, App-vNext/Polly#2205, App-vNext/Polly#2260). We only sign our builds that are intended to be published to NuGet.org, so the issue didn't come to light until now - we also can't validate signing in dependabot PRs anyway, as secrets are not available to them.
Reverting those changes (App-vNext/Polly#2305) and going back to the version we used for our 8.4.1 release resolved the issue, with the signing succeeding to publish 8.4.2 (logs).
Something in the last three public releases appears to have broken something.
This may be related to #753, but I assume the change their has been released, so if so either than change broke this use case, or it's a different problem.
I have no direct access to the certificate or the Azure resources it's stored in, so I can't check any settings related to it myself.
/cc @joelhulen
Repro steps
We were broken as of App-vNext/Polly@f7dc35f, but without you having access to our secrets I'm not sure how useful that is...
Expected behavior
Assemblies and NuGet packages are successfully signed.
Actual behavior
Signing fails with the following errors:
Additional context
The referenced commit where signing fails uses sign
0.9.1-beta.24406.1
and .NET SDK8.0.402
.The text was updated successfully, but these errors were encountered: