什么是好的唯一PC标识?标识、PC

2023-09-02 11:50:07 作者:すれ違う(错过)

我一直期待在code在本教程和我发现,它使用 My.Computer.Name 保存设置不应计算机之间漫游。它是完全可能的,但是,对于一个用户具有两个同名电脑。如果他们想拥有每台PC上相同的用户名,例如,他们很可能最终与命名用户名,PC两台PC。

I've been looking at the code in this tutorial, and I found that it uses My.Computer.Name to save settings that shouldn't roam between computers. It's entirely possible, however, for a user to have two identically named PCs. If they wanted to have the same username on each PC, for example, they may very well end up with two PCs named Username-PC.

什么是确定不同的PC上一些好的方法?难道电脑具有与其关联的GUID,或者我应该看看拉序号掉一些硬件?如果识别仍然存在通过Windows的重新安装我不在乎。

What are some good methods of identifying different PCs? Do PCs have GUIDs associated with them, or should I look into pulling the serial number off of some hardware? I don't care if the identification persists through reinstallation of Windows.

(我联系的教程是在VB.Net,但我实现它在C#)

(The tutorial I linked is in VB.Net, but I'm implementing it in C#)

推荐答案

有一些很好的标识符:

MAC地址:这是很容易获得的,而且它通常是唯一的。但是,它可以被欺骗/相当容易地改变,所以它取决于如何独特它需要。 CPU序列号:它不提供大量的旧系统,但它的存在。请查看这个MSDN页面。它不会改变,但它结合到一台计算机。 硬盘序列号:这可能不会改变,但如果高清失败,可能是一个麻烦。请查看这个MSDN页面。 MAC Address: It's fairly easy to get at, and it's usually unique. However, it can be spoofed/changed rather easily, so it depends on how unique it needs to be. CPU Serial Number: It's not available on lots of older systems, but it's there. Check out this MSDN page. It won't change, but it's bound to a computer. HDD Serial Number: It's likely to not change, but can be a nuisance if the HD fails. Check out this MSDN page.