Click here to Skip to main content
15,898,010 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,
My Name is Raja A,
In my asp.net web application i need to find every client using my application uniquely
by using any unique identification of client machine.

I tried to find the 'MAC' address of client by the use of "Web Server Control"
but while i do so i'm getting the same server "MAC" for all the client machines.

Can anyone help me out, with this problem.
(Think i'm a beginner please) .
Posted

You can only get the MAC address of clients on your own network. Google "get mac address asp.net" for examples of this, but if your server and clients are not on a LAN then what you want isn't possible.
 
Share this answer
 
Comments
Raj 0203 10-Jun-15 5:19am    
Thank You for the suggestion,
As i informed my problem is to find the clients machine uniquely and i thought by the use of "MAC" i can achieve that.
So kindly give me any idea to solve this problem.
You can't.
MAC addresses are not transferred beyond the local LAN segment, never to the internet - to access a client MAC address you would have to run software directly on the client machine, which is impossible except in very, very special circumstances, which do not apply to most browsers and browser setups.

And...MAC addresses aren't unique: they are only unique within the LAN segment, and can be "spoofed" very easily.

There is nothing you can do to uniquely identify any machine, except to set a cookie on it - and even then, I could open three different browsers and get three different cookies!
 
Share this answer
 
Comments
Raj 0203 10-Jun-15 5:01am    
Thank You for your support,
As you said, think this is a very special scenario, and let me know, what kind of program/software i have to run on the client machine to get the "MAC" address.
Please Help me.
F-ES Sitecore 10-Jun-15 5:11am    
You'll need to write a client-side component like an ActiveX control, a java applet etc

http://stackoverflow.com/questions/4467905/getting-mac-address-on-a-web-page-using-a-java-applet

Needless to say you're going to have a fair job getting this working. You're better off re-evaluating why you need the MAC address, you probably don't, you should find a better solution to your problem. As already suggested write a GUID in a cookie and identify people that way.
OriginalGriff 10-Jun-15 5:19am    
In order to do it, your client will have to be running IE. No other browser will let you do it. Then, IE has to be configured to allow you to send it an ActiveX control (and this is disabled by default). Then IE has to run the ActiveX control (and this is set to "get permissions from the user first, and warn him that this is potentially a dangerous thing to do" by default).
And then...you can write the ActiveX control.

And I come along, and spoof the MAC (which takes seconds) to give you a different value...

Seriously, this won't work!
Raj 0203 10-Jun-15 5:27am    
I'll work on this more, but i'd love to know is there any other way to identify a client uniquely.?
Thank You for the suggestions.
OriginalGriff 10-Jun-15 5:40am    
It's a major problem - but no, there isn't.
If there was, it would make the internet a heck of a lot safer!

You can't use the MAC, the IP, even cookies don't really fix it because each browser maintains separate cookie systems, and each browser provides methods to delete cookies! You can't even rely on geolocation! :laugh:

On of the things the internet really, really needs is a form of unique user identification - and it doesn't have anything even close, or any reliable method of working towards that either... :sigh:

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900