How can I obtain the client MAC address with C# code of someone who visits my website?
You don't have access to the MAC, you don't need it. The MAC is only known to the router who the computer is connected to.
You can't get the MAC address of the sender, because you can't get mac address behind the first router on the path to the client.
To achieve that, you have to run some code on the client machine. MAC address isn't provoided in the internet. Store some cookie with a guid on the machine, that is not as disliked as running code on the client machine. ;-)
The best thing in my oppinion is to establish a user management on your website and give the peaople a chance to register / login. Then you can track everything around the user.
来源:https://stackoverflow.com/questions/8125045/obtain-client-mac-address-in-asp-net-application