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

[Bug]: DLL files in **Signed** NuGet packages are not signed. #817

Closed
IADTIL opened this issue Sep 21, 2022 · 15 comments
Closed

[Bug]: DLL files in **Signed** NuGet packages are not signed. #817

IADTIL opened this issue Sep 21, 2022 · 15 comments
Labels
bug Something isn't working fixed This issue has been fixed.
Milestone

Comments

@IADTIL
Copy link

IADTIL commented Sep 21, 2022

The libraries in the *.Signed NuGet packages (65.22.6.152) are not signed.

@IADTIL IADTIL added the bug Something isn't working label Sep 21, 2022
@Wagnerp Wagnerp changed the title [Bug]: dll files in *Signed NuGet packages are not signed. [Question]: dll files in *Signed NuGet packages are not signed. Oct 22, 2022
@Wagnerp Wagnerp added question Further information is requested answered This question has been adequately answered. and removed bug Something isn't working labels Oct 22, 2022
@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 22, 2022

Hi @IADTIL

The 'signed' packages mean that the namespaces within these libraries are true and not have been altered somewhere along the line i.e. a strong name. These packages are intended for developers who were coming over from the original toolkit, as this was a by-product of the DLLs. Please see this article for details.

@Wagnerp Wagnerp closed this as completed Oct 22, 2022
@IADTIL
Copy link
Author

IADTIL commented Oct 23, 2022

Thanks for the link to the article, but I know what signed (strongly named) means. The point is that the dlls in the packages that claim they are signed, are NOT signed (or were not, if you have fixed them now?). When I tried to use them with a project that requires strongly named assemblies (because all my assemblies are signed) link them to a project that used, it wouldn't let me.

Instead I had to download the source, add the projects into my solution, and compile them that way, which defeats the object of nuget packages, and is not ideal because it means differently compiled assemblies with the same version number will be out there.

Have you fixed this now, or did you simply assume I don't know what "signed" means? If there have been no changes to the packages, don't simply mark this as a question. It's a definite bug.

Unfortunately I am now off that project, and am unlikely to be able to test it in future, unless I try it in a personal capacity.

Cheers.

@IADTIL IADTIL changed the title [Question]: dll files in *Signed NuGet packages are not signed. [Bug]: dll files in *Signed NuGet packages are not signed. Oct 23, 2022
@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 23, 2022

Hi @IADTIL

Thanks for the reply. It might be a bug with NuGet, if so then one option is to package the DLLs into an installer and then put it into the releases section. Sorry for the confusion :).

@Wagnerp Wagnerp reopened this Oct 23, 2022
@Wagnerp Wagnerp added bug Something isn't working in progress A fix for this issue is in the works. and removed question Further information is requested answered This question has been adequately answered. labels Oct 23, 2022
@Wagnerp Wagnerp self-assigned this Oct 23, 2022
@Wagnerp Wagnerp added this to the Version 7 milestone Oct 23, 2022
@mbagattini
Copy link

mbagattini commented Oct 23, 2022 via email

@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 24, 2022

Hi @mbagattini

It is supported, but I think NuGet somehow strips it out.

@Wagnerp Wagnerp changed the title [Bug]: dll files in *Signed NuGet packages are not signed. [Bug]: DLL files in *Signed* NuGet packages are not signed. Oct 24, 2022
@Wagnerp Wagnerp changed the title [Bug]: DLL files in *Signed* NuGet packages are not signed. [Bug]: DLL files in **Signed** NuGet packages are not signed. Oct 24, 2022
@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 24, 2022

Hi @IADTIL & @mbagattini

Would you mind testing these DLL files, to verify that they've been signed? Thanks!

@IADTIL
Copy link
Author

IADTIL commented Oct 24, 2022

Hi @IADTIL & @mbagattini

Would you mind testing these DLL files, to verify that they've been signed? Thanks!

None of them are.
You can test them for yourself using the strong name tool, sn.exe.

E.g.
"C:\Program Files (x86)\Microsoft SDKs\Windows\v10.0A\bin\NETFX 4.8 Tools\sn.exe" -v "C:\Signed\net462\Krypton.Docking.dll"

I used Powershell to run it on all the dlls from that zip file, with the same result for all of them:

Microsoft (R) .NET Framework Strong Name Utility  Version 4.0.30319.0
Copyright (c) Microsoft Corporation.  All rights reserved.

C:\Signed\net462\Krypton.Docking.dll does not represent a strongly named assembly

PS.

Running sn.exe on the dlls compiled by the projects included in my solution gives me this result, for example:

Microsoft (R) .NET Framework Strong Name Utility  Version 4.0.30319.0
Copyright (c) Microsoft Corporation.  All rights reserved.

Assembly 'C:\Delivery\Files\ComponentFactory.Krypton.Docking.dll' is valid

Cheers.

@mbagattini
Copy link

Just for clarity, I'm not actually testing the dlls. Pinging Ian: @IADTIL

@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 24, 2022

@mbagattini Sorry my mistake.

@IADTIL Thanks for your reply. If it works when you compile it, would you mind sharing the steps that you take to get there? Thanks.

@IADTIL
Copy link
Author

IADTIL commented Oct 24, 2022

@mbagattini Sorry my mistake.

@IADTIL Thanks for your reply. If it works when you compile it, would you mind sharing the steps that you take to get there? Thanks.

As I recall, I downloaded the source code, then simply copied the projects that I required (component projects under Krypton-master\Source\Krypton Components) into my solution and linked to the projects, instead of adding the NuGet packages to my projects. The Krypton projects are then compiled at the same time as my own code, and the dlls copied from that output. (I recall I did change the output location of the projects, as they put them into a bin folder further up the tree). The projects are already set up to sign the assemblies, so I don't understand where the unsigned versions are coming from, or why you would even want to use unsigned assemblies anyway. Why not make the signed assemblies the standard? (Unsigned assemblies can reference signed assemblies, but signed assemblies cannot reference unsigned ones).

Cheers.

@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 24, 2022

I think I'll make them signed as standard to keep it simple.

@IADTIL
Copy link
Author

IADTIL commented Oct 24, 2022

I think I'll make them signed as standard to keep it simple.

Great!

@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 24, 2022

On second thought... found the bug...

image

@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 24, 2022

Success!!

image

Wagnerp added a commit that referenced this issue Oct 24, 2022
Wagnerp added a commit that referenced this issue Oct 24, 2022
@Wagnerp Wagnerp removed their assignment Oct 26, 2022
@Wagnerp Wagnerp added fixed This issue has been fixed. and removed in progress A fix for this issue is in the works. labels Oct 26, 2022
@Wagnerp
Copy link
Contributor

Wagnerp commented Oct 26, 2022

Resolved - 24/10/2022

@Wagnerp Wagnerp closed this as completed Oct 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fixed This issue has been fixed.
Projects
None yet
Development

No branches or pull requests

3 participants