Click here to Skip to main content
15,904,023 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am making a project (software) in which i am using a HASP key registration for every user who will be willing to use the software. For this I have bought a license for this from HASP Key company.

I want to keep a check on the login of user on three basis i.e., "USER ID", "PASSWORD" and "HASP KEY". I don't know that how the key is generated when we insert the HASP key into the computer means, it generates it randomly or generates a single key every time. I need this Key information from the HASP key. For this I contacted the HASP Key owners; they asked me that I can get all information from the HaspKey.GetInfo() method but I am not able to get this method in C#.Net 2.0. I have also included the Aladin namespace but still not able to get this method. :(

My software is for Single User and for Multi-User and I need this check for both.

If anyone out there have any knowledge on this (HASP) then kindly provide me a solution to it, I would be very grateful to that person.
Posted

1 solution

Aladdin provide you with 3 things:


  1. a Master Key: it is needed to write your specific informations into User Keys
  2. a Developer Key: it is needed to bind your executables to the User Keys using the Envelope method
  3. the Vendor Suite: it is a collection of tools to administer your Keys and customers


On the Vendor Suite you should add your Master Key to its database; when you run the Envelope or ToolBox applet from the Vendor Suite main window, the software ask you about generating some files specific for your Master Key (it should be plugged onto an USB port). Inside My Documents folder you'll find a folder structure like the one below:

Aladdin\HASP SRM 4.0\API\Runtime\DotNet


Inside that folder you'find a set of assemblies related to your key; in your project you should add the right one to its references. Your Master Key is provided with a batch code, a number (probably 5 decimal digits) that you should give to Aladdin each time you make an order for User Keys; assume that your batck number is xxxxx, then the assembiles you are interested on are something like hasp_windows_xxxxx.dll and hasp_windows_x64_xxxxx.dll (the right one to be referenced depends on the target platform of your project).

Finally, from the Vendor Suite main window, you can run the ToolBox application: it give you documentation and code snippets that you can paste in your software.

I hope this could help you...

Sauro
 
Share this answer
 
v3
Comments
Varun Sareen 19-Jul-10 2:05am    
Dear Sauro, Actually the DOTNET file which you have send us doesn't solved our purpose because the same folder path we have already received from SAFENET (HASP) incorporation. Actually we need a unique for every HASP key we made for our Software no matter it is single user software or multi user software. For e.g there is a unique ID associated with each mobile handset i.e., EMI number. If you could help me then it would be so nice of you.

Thanks

Varun Sareen
Sauro Viti 19-Jul-10 3:01am    
Dear Varun,
I'm very sorry that what I said is not of help for you. Unfortunately that is all I know about HASP HL devices; I used it to protect an application of my company, but our protection scheme is quite simple so I didn't need to investigate more.

Sauro
Varun Sareen 19-Jul-10 4:14am    
Dear Sauro
It's ok. It's still really nice of you.

Thanks

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900