如何获取MAC地址以及网卡详细信息 [英] How to get the MAC address along with network card detail
本文介绍了如何获取MAC地址以及网卡详细信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Pl帮助获取MAC地址以及所有禁用的网卡详细信息启用wifi以及以太网但它只显示以太网mac
我尝试过:
公共函数getMacAddress()
Dim nics()As NetworkInterface = NetworkInterface.GetAllNetworkInterfaces()
返回nics(1).GetPhysicalAddress.ToString
结束函数
Pl help to get the MAC address along with Network card detail of all disable & enable wifi as well as ethernet but it shows only ethernet mac
What I have tried:
Public Function getMacAddress()
Dim nics() As NetworkInterface = NetworkInterface.GetAllNetworkInterfaces()
Return nics(1).GetPhysicalAddress.ToString
End Function
推荐答案
请参阅此处:检索LAN的IP和MAC地址 [ ^ ] - 代码在C#中,但它很简单,如果你不能解决它,在线转换器的存在将有所帮助:代码转换器 [ ^ ]
如果你打算使用这个在安全或复制保护系统中,您应该知道MAC地址是1)不唯一,2)容易欺骗。
See here: Retrieving IP and MAC addresses for a LAN[^] - the code is in C#, but it's pretty simple and if you can't work it out, online converter exist which will help: Code Converter[^]
If you are planning on using this for a security or copy protection system, you should be aware that MAC addresses are 1) not unique, and 2) easy to spoof.
这篇关于如何获取MAC地址以及网卡详细信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文