如何在c#中获取客户端机器的MAC地址 [英] How to get MAC address of client machine in c#

查看:575
本文介绍了如何在c#中获取客户端机器的MAC地址的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法使用c#

推荐答案

来获取客户端机器的mac地址: http://stackoverflow.com/questions/850650/reliable-method-to-get-machines-mac-address -in-c-sharp [ ^ ]
Start here : http://stackoverflow.com/questions/850650/reliable-method-to-get-machines-mac-address-in-c-sharp[^]


否。

嗯 - 有,只是它只能在一小部分客户端:他们必须运行IE,IE必须设置为接受并运行ActiveX控件,并且需要编写并向客户端发送ActiveX控件。

但是。 ..

1)大多数人不使用IE浏览器。

2)IE默认设置是不接受或运行ActiveX控件

3大多数用户都非常警惕ActiveX,因为它是滥用的。



所以它可能会在0.01%的访问者中工作?



MAC地址不会离开本地LAN网段 - 它们永远不会传递到下一个段或互联网,因为它们已经被本地IP地址取代。



如果您考虑使用它们来保证安全,请忘记它们:不是唯一的(只在局域网中是唯一的)并且它们难以置信地容易欺骗。
No.
Well - there is, it's just that it will only work in a tiny, tiny minority of the clients: they must be running IE, IE must be set to accept and run ActiveX controls, and you need to write and send an ActiveX control to your client.
But...
1) Most people don't use IE.
2) IE default setting is not to accept or run ActiveX controls
3) Most users are very wary of ActiveX because it is wide open for abuse.

So it'll work in maybe 0.01% of your visitors?

MAC addresses do not leave the local LAN segment - they are never passed to the next segment or the internet as they are already replaced by the local IP address.

And if you are thinking of using them for security, forget it: they aren't unique (only unique within a lan segment) and they are unbelievably easy to spoof.


这篇关于如何在c#中获取客户端机器的MAC地址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆