更新时间:2023-08-27 16:45:22
您无法在ASP.NET应用程序中获取客户端MAC地址。
您发布的代码是获取SERVER上的接口,而不是客户端。 ASP.NET代码总是完全在服务器上运行,而不是客户端。
此外,MAC地址在客户端所在的网络之外没有意义。它不是全局唯一值,不能用于唯一标识客户端。
You can NOT get the client MAC address in an ASP.NET application.
The code you posted is getting the interfaces on the SERVER, not the client. ASP.NET code always runs entirely on the server, never the client.
Also, the MAC address is meaningless outside of the network the client is sitting on. It is NOT a globally unique value and cannot be used to identify a client uniquely.