Solved

Generating and Compressing Computer ID

Posted on 2011-09-16
5
741 Views
Last Modified: 2012-05-12
Hi Experts,

To protect my software, i'm trying to generate a unique computer id. I'm trying to combine Hardisk ID, Windows Key, MAC Address etc. My question is, after i retrieved all the above information, how should i compress all the information into 25 character computer id?

Thanks in advance
Reynaldi
0
Comment
Question by:reynaldio
  • 3
5 Comments
 
LVL 9

Accepted Solution

by:
Mahdi78 earned 500 total points
ID: 36549634
You will find all what want about your need in OnGuard library
http://sourceforge.net/projects/tponguard/
0
 
LVL 9

Assisted Solution

by:Mahdi78
Mahdi78 earned 500 total points
ID: 36549699
As short way to get Machine ID without installing package, do the following

1- Add the folder OnGuard\source to your project search path.
2- Add OnGuard unit to uses clause.
3- Create the following function to get machine id


uses OnGuard;

function GetMachineID: String;
begin
Result := IntToStr(ABS(CreateMachineID([midUser,
      midSystem, {midNetwork,} midDrives])));
end;

Open in new window

0
 
LVL 9

Expert Comment

by:Mahdi78
ID: 36550267
If you're going to use your method, you can collect information and compress them by this function


uses IdHashMessageDigest;

function CompressID(str:string):string;
var
  md5 : TIdHashMessageDigest5;
begin
  md5 := TIdHashMessageDigest5.Create;
  try
    Result:=copy(md5.HashStringAsHex(str), 1 , 25);
  finally
    md5.Free;
  end;
end;

Open in new window

0
 
LVL 100

Expert Comment

by:mlmcc
ID: 36967107
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
Azure Functions is a solution for easily running small pieces of code, or "functions," in the cloud. This article shows how to create one of these functions to write directly to Azure Table Storage.
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…
The Email Laundry PDF encryption service allows companies to send confidential encrypted  emails to anybody. The PDF document can also contain attachments that are embedded in the encrypted PDF. The password is randomly generated by The Email Laundr…

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question