如何获取真实的硬件MAC地址

发布于 2024-08-18 03:27:34 字数 1436 浏览 7 评论 0原文

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

浮华 2024-08-25 03:27:34

Windows 必须访问 MAC 地址的唯一方法是询问驱动程序。

这就是驱动程序的用途 - 与硬件对话,这样 Windows 就不必为任何人可能想到的每个设备都包含代码。

如果驱动程序告诉 Windows MAC 地址是什么,那么这就是 MAC 地址。

The only means that Windows has to access the MAC address is asking the driver.

That's what the driver is for - to talk to the hardware so that Windows doesn't have to include code for every single device anyone might come up with ever.

If the driver is telling Windows that the MAC address is something, then that's what the MAC address is.

落花随流水 2024-08-25 03:27:34

MAC 地址是一个很好的候选地址,
因为它对于每个以太网都是唯一的
卡。

恐怕不是。首先,我读过有关客户收到整批具有相同 MAC 地址的机器的报告(显然这在构建集群时会带来痛苦)。

我还亲眼见过一台机器在重新启动时更改其 MAC 地址。每次。这是一台运行 Windows XP 的旧 IBM Thinkpad。

我的建议:如果您要生成唯一的 ID,请远离 MAC 地址。

MAC address is a good candidate,
because it is unique for each ethernet
card.

I'm afraid not. Firstly, I've read reports of customers receiving entire batches of machines with identical MAC addresses (apparently this causes pain when building clusters).

I have also seen with my own eyes a machine that changes its MAC address on reboot. Every time. It was an old IBM Thinkpad running Windows XP.

My advice: stay well away from MAC addresses if you're generating unique IDs.

简美 2024-08-25 03:27:34

我不认为你提到的“网络地址”指的是MAC地址。有些设备允许您出于 ISP 目的“欺骗”MAC 地址,但您应该能够使用您发现的方法获得真实的 MAC。

I don't think "Network Address" you mention refers to the MAC address. Some devices allow you to "spoof" the MAC address for ISP purposes, but you should be able to get the real MAC using the methods you found.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文