Device Detectionn

Hi Expperts,

Using PHP, JS, and/or jQuery, is it possible to detect if the user is using their registered device.

I think that every device world-wide has a unique MAC Address, so I guess maybe my question is how to read the MAC address? However, not of any modem or router, but of the endpoint device (ie-computer, phone or tablet)?

Thank you.
APD TorontoSoftware DeveloperAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

David FavorLinux/LXD/WordPress/Hosting SavantCommented:
This tends to be difficult for several reasons.

1) Every device will be running a different OS. Consider TracFones (millions upon millions of these devices in service). They all run a Java based OS, with no API services... or what you'd think of as API services, to determine a MAC address.

2) Android + iOS devices will likely throw up some sort of warning, depending version running, asking the user to allow access.

Imagine being presented some cryptic message about allowing some random code (your App) access to lowest level of machine hardware, which will likely include a suggestion to the user not to do this.

3) Here's the real kicker... Many mobile devices NAT through complex systems, where 1000s of devices connected to a given cell tower will return the exact same IP + MAC address.

So whatever you're trying to do, likely you'll find no solution which will work... even for a small percentage of devices.

4) There will never be a PHP/JS way to do this, as you're thinking about the wrong end of the connection.

This data must be acquired at the actual device + will never be correctly represented at the server side.

Simple Solution: All this said, all you require is a simple session management system (WordPress comes to mind) to ensure people have their own logins + if required, use WordPress bounce code which kills off any active sessions when a new person uses a user/pass combination.

Using simple bounce tech instantly gets rid of account sharing, because the original purchaser will start getting logged off (bounced) each time someone uses their login.

A clean way to stop account sharing.
APD TorontoSoftware DeveloperAuthor Commented:
I should  have also mentionned that this app would be used by 25 users... a max of 50 users
APD TorontoSoftware DeveloperAuthor Commented:
All users,  will accept and expect the mentionned "warnings" from this web applications.
Dave BaldwinFixer of ProblemsCommented:
MAC Addresses can only be read on the network the device is immediately connected to.  They do not pass thru routers.  You would have to read it with an app on the device itself.
leakim971PluritechnicianCommented:
you can store a unique cookie when the user register with its phone
BUT
if the device is rooted, people can edit the cookie or copy/paste it but with a rooted phone you can also "change" MAC Address too

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
PHP

From novice to tech pro — start learning today.