Unique Machine Identifier

J

JJ

Now I know this question has been asked many times, but I cannot seem to
find a good site which summarises the methods possible in vb .net.

I am after a way of producing a unique serial number for my app. The program
would produce a unique identifier for the computer, then I would psovide the
user with a serial number unique to their machine.

In other words I would like to check for things like:
i) Hard disk (not volume) serial number
ii) CPU serial number
iii) Video card serial number (?)
(iv) Any other unique number I could use.

The program will be using vb. net 2003 (.net 1.1) and will only be run on
Windows 2000 and XP.

I realise there may be commercial solutions out there, but I am only a poor
programmer and would like to save money and do it myself.

If there is anywhere you can point me to in order to get started on this,
please, please reply to this post.

JJ
 
J

JJ

OK so on further reading, it seems there is no reliable way to get hardware
serial numbers (correct me if I am wrong).

Some programmers have suggested one of the two methods:

(a) generate a randon number (with a checksum etc) that is something to do
with the date. This is presented to the user. The user
MUST then call the help desk, and give them this number. The help desk then
use a decoder to provide a one time only use key
(b) generate a unique number that is something to do with the date and MAC
address of the NIC (or the virtual NIC used by dial up networking). Use this
as a seed for a Luhn-Mod checksum to produce a unique serial number.

Can anyone comment as to whether I am heading down the right lines? I think
I prefer option (a) as it seems slightly simpler and probably more
reliable...?

Thanks
JJ
 
H

Herfried K. Wagner [MVP]

JJ said:
Now I know this question has been asked many times, but I cannot seem to
find a good site which summarises the methods possible in vb .net.

I am after a way of producing a unique serial number for my app. The
program would produce a unique identifier for the computer, then I would
psovide the user with a serial number unique to their machine.

In other words I would like to check for things like:
i) Hard disk (not volume) serial number
ii) CPU serial number
iii) Video card serial number (?)
(iv) Any other unique number I could use.

(v) The machine's SID:

<URL:http://groups.google.de/group/micro..._frm/thread/6c2803622a6bc9d2/7a4c404486381793>
 
J

JJ

I've managed to get the serial numbers I want to use (namely the windows
serial and the computer SID. Now I am looking to be able to encrypt the
numbers into a fixed size serial number that my program can authenticate.

I guess this means using something like MD5 and getting my prog to check the
checksum?

Can anyone help here? Perhaps point me int he right direction?

Thanks JJ
 
G

Guest

Have you looked as generating a GUID from your serial nos?
--
Dennis in Houston


JJ said:
I've managed to get the serial numbers I want to use (namely the windows
serial and the computer SID. Now I am looking to be able to encrypt the
numbers into a fixed size serial number that my program can authenticate.

I guess this means using something like MD5 and getting my prog to check the
checksum?

Can anyone help here? Perhaps point me int he right direction?

Thanks JJ
 
J

JJ

Hi Dennis.

I have collected the:
Windows serial number;
Computer SID;
Disk (volume) serial number;
Motherboard serial number.

I was hoping that someone would have a nice bit of code that allows you to
plug in a load of numbers and come out with a nice neat 32 digit (for
example) serial number using some complicated algorithm.
that my prog could verify. (I realise that not all of these serial number
may be available on all machines, so my methods must allow for perhaps any
two of these being preset.)

I am not so good at the maths so would appreciate if anyone can point me in
a direction that may help.

TIA,

JJ


Dennis said:
Have you looked as generating a GUID from your serial nos?
 
C

Cor Ligthert [MVP]

JJ,

If you take so much don't forget the Mac address which is on a network
adapter.
If it is there than it almost for sure unique.

Be aware that this kind of methods have finished software companies.

Cor
 
J

JJ

Hi Cor.

What do you mean by : "> Be aware that this kind of methods have finished
software companies.
"

Do you mean that these methods are a pain for end users?

Thanks,

JJ
 
C

Cor Ligthert [MVP]

Do you mean that these methods are a pain for end users?
Yes especially as they can not reach you, they have to change a computer
part and they need to have a result the next day.

Cor
 
J

JJ

I understand as I've been there.

However this software is a time limited software for a specific project, and
I want to tie it to the client and stop any possible use in the future, and
on other machines.

Thanks,

JJ
 
A

Andrew Morton

JJ said:
However this software is a time limited software for a specific
project, and I want to tie it to the client and stop any possible use
in the future, and on other machines.

To help tie it to the client, you could have their name boldly displayed
throughout it - "For the exclusive use of XYZ Corp" - which would hopefully
disuade other companies from using it. As to the time limitation, just check
the date when your program starts and every now and again whilst it's
running; yes, they could change the date on their computer, but that tends
to mess up other things too.

Andrew
 
J

JJ

Hi Andrew.

Yes I've got their logo all over it. Though maybe you're right about making
it a little more 'legal' looking with a "For the exclusive use of...' note.

I've managed to combat the time limitation by use of the licensemanager and
a few discreet registry keys inserted on install.
I am hoping the additional serial number strategy will help me with other
projects too though, so I still want to include it.

Thanks,

JJ
 
J

JJ

Hi Andrew.

Yes I've got their logo all over it. Though maybe you're right about making
it a little more 'legal' looking with a "For the exclusive use of...' note.

I've managed to combat the time limitation by use of the licensemanager and
a few registry keys inserted on install.
I am hoping the additional serial number strategy will help me with other
projects too though, so I still want to include it.

Thanks,

JJ
 
J

JJ

Hi Martin - no that won't happen as I'll take a number of serial numbers and
allow the user to change a percentage of them.

JJ
 
A

Andrew Morton

JJ wrote:
<snip serial number linked to one machine woes>

Thinking about it, if you distrust a customer so much that you'll go to such
extensive and unreliable lengths in an attempt to protect your software, do
you really want to being doing business with them?

Andrew
 
J

JJ

Good point. I do actually have some trust for them, but who knows how
desperate I may get in the future, and who therefore I may have to provide
my software to.....


I thought though that it was a pretty reliable method to get the windows
serial number, and the Windows SID? Am I wrong?

I understand that the hardware serial numbers may be a little more
unreliable, but please do tell me if I am wrong in my above statement.

Thanks,

JJ
 
A

Andrew Morton

JJ said:
I thought though that it was a pretty reliable method to get the
windows serial number, and the Windows SID? Am I wrong?

If you're the one providing the serial number generated from data from a
machine, you have to make sure that the serial number can be obtained at any
time... 02:30 on a Sunday, the middle of your holiday, whenever. And if it's
automatically generated (e.g. through a web site) you have to make sure that
generator is always available, and has 24 hour phone support. Remember that
Murphy's law works every second of every day...

Andrew
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top