且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

客户端计算机在Asp.Net中的Mac地址.

更新时间:2022-06-23 22:21:41

哇,这很有趣,您似乎已经从下面的链接复制了问题.

如何获取客户端计算机的Mac地址在asp.net [ ^ ]

来自戴夫:
You didn''t actually read these links, did you? If you did and if you understood how networking works, you''d know that the solutions provided do not work in an ASP.NET app and getting the MAC address of a client is not possible.
Wow, this is interesting that you seem to have copied the question from the link below.

How to get Mac Address of Client Machine in asp.net[^]

From Dave:
You didn''t actually read these links, did you? If you did and if you understood how networking works, you''d know that the solutions provided do not work in an ASP.NET app and getting the MAC address of a client is not possible.


您不能.
MAC不会发布,而只是IP和子网(无论如何,它们都是由路由器提供的),因此,除非您可以访问路由器和防火墙后面的计算机,并且该计算机是Windows机器,否则任何解决方案都不会起作用.尤其是因为您希望它适用于所有浏览器",这意味着您无权访问路由器或防火墙后面的计算机!

如果它允许您安装ActiveX控件,则可以执行此操作(使用Windows框),但是对于一般用户而言,这种工作的可能性非常小-ActiveX太滥用了,无法由用户设置常规的是安装"权限默认值.
You can''t.
The MAC is not published, just the IP and subnet (and these are supplied by the router anyway), so unless you have access to the machine behind the router and firewall, and that machine is a Windows box, no solution is going to work. Especially since you want it to work for "all browsers" - which means you don''t have access to the machine behind the router or firewall!

You could do it (with a windows box) if it allowed you to install an ActiveX control, but the chances of that working are pretty remote for general users - ActiveX has been far too abused for general "yes install" permissions to be set by default.