I've been trying to sign assemblies with a PFX file. All worked fine, I accessed Properties/Signing at Visual Studio yet whenever I run the dotnet publish command, I get this error:
C:\Program Files\dotnet\sdk\2.1.201\Microsoft.Common.CurrentVersion.targets(3210,5): error PFX signing not supported on .NET Core
I've been looking for a way to work around this, yet with no luck so far.
So I figured I should go with SNK signing instead of PFX, considering it's no longer supported by PFX.
sn -p key.pfx key.pub
<DelaySign>true</DelaySign>
to the project file or by AssemblyDelaySignAttribute
. Use a public key from step 1 instead of the PFX for signing.sn -R assembly.dll key.pfx
https://learn.microsoft.com/en-us/dotnet/framework/tools/sn-exe-strong-name-tool
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With