Search

Atalasoft Knowledge Base

HOWTO: Generate a Strong Name DLL for Use in Special Licensing

Tananda
DotImage

Customers with certain special license needs (Cloud deployment, embedding licensing in class libraries) need to sign their assemblies (strong name) with a signing key. DotImage Special Licensing (sometimes called a PKL for Public Key-tied License) requires such an arrangement

In order to generate a license we need a customer to provide a dll sigend (strong named) with their signing key. The license can then be generated which ties to the public key, allowing that developer to sign and license components to use DotImage

Generating a Signed Empty Assembly

When we ask you to generate a signed empty assembly you will need to do so by creating a new .NET Framework class library project in Visual studio.

For newer visual studio such as Visual Studio 2022 it is vital that you ensure that this is a .NET Framework Class library and NOT a .NET Core (.NET 6 / .NET 5) assembly

For older Visual studio (such as Visual Studio 2012) just a new Class Library project is fine

Visual Studio 2022

  1. Open Visual Studio 2022
  2. go to File->New->Project
  3. In that Create a new Project dialog you want to do a Class Library (.NET Framework)


    NOTE: DO NOT do New Class Library .. it MUST BE Class Library (.NET Framework) or it will fail
  4. Select that option and click next...
  5. In the "Configure your New Project" dialog, pick a location to save it to


    NOTE: remember where you saved this you will need to find the folder later
  6. Click Create...
  7. Once the project is created, you need to right click on ClassLibray1 project and select Properties


    This will bring up the properties tabs
  8. Click on the SIGNING option
  9. On the SIGNING page, CHECK the "Sign the Assembly" checkbox
    1. If you do not have a valid signing key use the option

    2. If you hae a key browse and find it
  10. Assuming you chose New above... give it a name


    NOTE: if you don't want to be prompted to provide a password every time you build, UNCHECK "Protect my key file with a password:" otherwise you will need to ensure your build process auto responds when needed... this is your responsibility we will not provide support in how to handle password prompts during automated builds.
  11. DO NOT CHECK Delay sign only


  12. Save and then do a Build->Rebuild Solution
  13. Now, Right click on your ClassLibrary1 project and select "Open Folder in File Explorer"


  14. Now, dig down to the bin\Debug directory in there and find ClassLibrary1.dll


  15. THIS FILE needs to be uploaded to Atalasoft

Visual Studio 2015 example

  • File -> new -> Project
  • In the New Project dialog:
    • select template: Visual C# or VB.net and class Library
    • Ensure that your target is .NET framework 4.5.2 or above (up to 4.8 but not .NET 5 or .NET 6)
    • Click OK
  • In Solution Explorer, right click on the project (ClassLibrary1 in our example) and select Properties
  • Click the signing tab
  • In the Signing tab
    • check "sign this application"
      (if there is a 'delayed signing' option, keep that option unchecked and jsut check sign this application)
    • Now, if you have an official commercial signing key you can browse to it and use it
      Alternately, you can create a new self signed key..
    • Once you have that done just do a rebuild on the solution
    • Then, right click on the project in solution explorer and select "open in Windows File Explorer"
      • Navigate into the output directory (default is going to be bin/debug
      • Find the output (in this case it would be ClassLibrary1.dll
      • This is the dll you need to attach to the case when requesting a cloud or Public key tied license
Details
Last Modified: Last Month
Last Modified By: Tananda
Type: HOWTO
Article not rated yet.
Article has been viewed 979 times.
Options
Also In This Category