6 ms·
Get the physical location of wireless router from its MAC address
- coderrr 18y agoThis is related to, but NOT A DUP of, the post incorrectly titled "Google map a cellphone knowing its MAC address" at http://news.ycombinator.com/item?id=298073 http://news.ycombinator.com/item?id=298073. The article intruiged me but I knew there had to be an easier way to send any MAC address to their API since there is no way for them to remotely determine your MAC address. In the blog post I show how.
- seiji 18y agoSkyhook knows where your access point is because at one time they drove by and mapped it. Google is probably collecting the same information from their street view vans. All you need is a laptop with a GPS receiver to log coordinates and MAC addresses. So why not do it yourself? http://wigle.net/ http://wigle.net/ is a public access point MAC address mapping site run by community contributions of location information.
- coderrr 18y agoI looked through the wiggle database. A TON of their information is super old. Of course there's no way to know how old SkyHook's is since it's totally private.
- seiji 18y agoSkyhook loves to tell you how recent their data is. They re-drive high turnover areas (colleges) a few times a year. Everything else is quite recent. With Skyhook's high profile use in the iPhone they can't afford to be out of date. Last I checked they had over 45 million access points recorded. With enough users, the system can become self sustaining. You upload all the detected access points in your area for a request so it's trivial for them to auto-update their system if you submitted a newly discovered or changed MAC address.
- forgeman 18y agoThanks for the wiggle.net link... I've got a place to put my wardriving data now! :)
- aasarava 18y agoDoes this mean that if you upgrade your router and put the old one on eBay and sell it to someone across the country, Skyhook's data is inaccurate (until they next drive by)?
- coderrr 18y agoyup
- forgeman 18y agocurl --header "Content-Type: text/xml" --data "<?xml version='1.0'?><LocationRQ xmlns='http://skyhookwireless.com/wps/2005' http://skyhookwireless.com/wps/2005' version='2.6' street-address-lookup='full'><authentication version='2.0'><simple><username>beta</username><realm>js.loki.com</realm></simple></authentication><access-point><mac>YOURMACADDRESS</mac><signal-strength>-50</signal-strength></access-point></LocationRQ>" https://api.skyhookwireless.com/wps2/location https://api.skyhookwireless.com/wps2/location <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
- coderrr 18y agohaha cmd line ftw, nice except you have an extra xml tag at the end
- deleted 18y ago[deleted]
- sil3ntmac 18y agoone single cmd wee MYMAC=$(arp -a | awk '/[0-9a-f]:/ { gsub(/^0:|[1-9a-z]0:/, "00:", $4); gsub(/:/, "", $4); print $4; exit; }') && curl --header "Content-Type: text/xml" --data "<?xml version='1.0'?><LocationRQ xmlns='http://skyhookwireless.com/wps/2005' http://skyhookwireless.com/wps/2005' version='2.6' street-address-lookup='full'><authentication version='2.0'><simple><username>beta</username><realm>js.loki.com</realm></simple></authentication><access-point><mac>$MYMAC</mac><signal-strength>-50</signal-strength></access-point></LocationRQ>" https://api.skyhookwireless.com/wps2/location https://api.skyhookwireless.com/wps2/location had to change 0: to 00: and strip out those :'s
- sil3ntmac 18y ago:P or rather, curl --header "Content-Type: text/xml" --data "<?xml version='1.0'?><LocationRQ xmlns='http://skyhookwireless.com/wps/2005' http://skyhookwireless.com/wps/2005' version='2.6' street-address-lookup='full'><authentication version='2.0'><simple><username>beta</username><realm>js.loki.com</realm></simple></authentication><access-point><mac>$(arp -a | awk '/[0-9a-f]:/ { gsub(/^0:|:0:/, "00:", $4); gsub(/:/, "", $4); print $4; exit; }')</mac><signal-strength>-50</signal-strength></access-point></LocationRQ>" https://api.skyhookwireless.com/wps2/location https://api.skyhookwireless.com/wps2/location
- forgeman 18y agoOur wonderful scripting adventures don't seem to work anymore... ;( Anyone able to confirm?