adragan Posted July 4, 2012 Share Posted July 4, 2012 Is it possible to get the MAC of a remore client ? I know Indy in 9 version could do that. Link to comment Share on other sites More sharing options...
dieger Posted July 4, 2012 Share Posted July 4, 2012 Is it possible to get the MAC of a remore client ? I know Indy in 9 version could do that. I think that isn´t possible because of security. The problem is that browsers don't allow you to get the mac address, because it would allow users to be identified uniquely. In IE you can get around this by writing an ActiveX control, and script that with javascript (which you did), but ActiveX is something only available in IE on Windows. Other solution can be a Java applet. Code to IE: var macAddress = ""; var ipAddress = ""; var computerName = ""; var wmi = GetObject("winmgmts:{impersonationLevel=impersonate}"); e = new Enumerator(wmi.ExecQuery("SELECT * FROM Win32_NetworkAdapterConfiguration WHERE IPEnabled = True")); for(; !e.atEnd(); e.moveNext()) { var s = e.item(); macAddress = s.MACAddress; ipAddress = s.IPAddress(0); computerName = s.DNSHostName; } Link to comment Share on other sites More sharing options...
adragan Posted July 5, 2012 Author Share Posted July 5, 2012 Thanks I'll try that. I have some mobile users and I need to identify them. I hoped that could have been a solution. Link to comment Share on other sites More sharing options...
zilav Posted July 5, 2012 Share Posted July 5, 2012 You should identify mobile clients by browser's agent string. Link to comment Share on other sites More sharing options...
adragan Posted July 6, 2012 Author Share Posted July 6, 2012 Can you be more specific ? Link to comment Share on other sites More sharing options...
zilav Posted July 6, 2012 Share Posted July 6, 2012 http://stackoverflow.com/questions/1005153/auto-detect-mobile-browser-via-user-agent Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now