Reputation: 1353
I'm creating a program that authenticates from a before it runs. I also want to deny access. Is there an id or a serial that all Windows computers have that can't be changed, that I could put on a black list? And how would I access that in C#?
Upvotes: 1
Views: 1201
Reputation: 945
Hmm, off the top of my head MAC address would be a good choice. It could be changed by getting a new NIC card, but it's not super easy to change.
Upvotes: -1
Reputation: 63
A combination of CUPID, hard disk volume ID and MAC address would be a good choice. They won't be changed unless with hardware changes. (However, HD vol. ID would be changed if you format the disk)
Upvotes: 2
Reputation: 655
MAC address can actually be changed quite easily.
This article: has info on exactly what you want: How To Get Hardware Information.
Basically, just mix a few of the hardware component IDs, and you should have a pretty solid key for your system.
Upvotes: 2
Reputation: 29240
This kind of restriction on access is generally accomplished by a hardware dongle or by a licensing server. Without these, specifically identifying a particular PC as the 'allowed machine' is a tricky proposition and anything you choose is likely to be spoofable.
Upvotes: 2