
How does Google know where I am? - kumarharsh
http://security.stackexchange.com/questions/137418/how-does-google-know-where-i-am
======
pawadu
This is not tower triangulation.

Android searches for access points even when wifi is turned off. If anyone
(with GPS enabled) uses that wifi with any google services the bssid will end
up in their database. Also if the google car has been nearby it has recorded
the presence of the wifi access point at that location [1].

Before you freak out: Apple and Microsoft also use access point information
for positioning, although not as successfully.

[1] [https://googleblog.blogspot.se/2010/05/wifi-data-
collection-...](https://googleblog.blogspot.se/2010/05/wifi-data-collection-
update.html)

~~~
comboy
Are you sure they do that when wifi is off? I was under the impression that it
only happens when wifi is on (and it seems to me that my location on the map
is more stable with wifi on).

That would be very not ok if it would happen with wifi off. I turn my wifi off
to save the battery, and it wouldn't do much if it was still looking for
broadcasts.

~~~
kllrnohj
> I turn my wifi off to save the battery

Sending/receiving data over wifi takes roughly ~8x less power than
sending/receiving data over cell.

If you want to save battery you need to turn off data entirely not turn off
wifi. Turning off wifi ultimately costs you battery.

~~~
bogomipz
>"Sending/receiving data over wifi takes roughly ~8x less power than
sending/receiving data over cell"

How did you arrive at this 8x figure? I don't think this is correct at all.
See:

[http://people.cs.umass.edu/~arun/papers/TailEnder.pdf](http://people.cs.umass.edu/~arun/papers/TailEnder.pdf)

Additionally power efficiency is related to distance from the cell tower which
is generally much further away than a wifi access point.

~~~
kllrnohj
Were you misled by the changing axis scale? From that paper:

> Our measurements (Section 3) confirm that the transmission energy consumed
> by WiFi is significantly smaller than both 3G and GSM, especially for large
> transfer sizes.

Also that's 3G, not LTE which is what most everyone is using nowadays.

------
cpeterso
Mozilla built a crowd-sourced database of Wi-Fi, cell, and Bluetooth network
locations, collected by volunteers running an Android "stumbler/war-driving"
app. I helped start this project for Firefox OS, which is mostly defunct but
the Mozilla Location Service (MLS) is still used for Firefox Nightly and
DevEdition on the desktop. :-) Here is a zoomable map of the location data
coverage:

[https://location.services.mozilla.com/map](https://location.services.mozilla.com/map)

Mozilla exchanges the cell location data with the OpenCellID project.
Mozilla's cell database is available for download here:

[https://location.services.mozilla.com/downloads](https://location.services.mozilla.com/downloads)

For privacy reasons, the Wi-Fi and Bluetooth databases are not currently
downloadable, but they can be queried through a web service API:

[https://location.services.mozilla.com/api](https://location.services.mozilla.com/api)

------
dogma1138
GPS for a long time haven't been used as the only source of location, to some
extent it can now be considered a "2nd fiddle" to INS since solid state INS
sensors are very good these days. The phone receives location information from
wifi and more importantly it gets location messages from cell towers, and it
uses dead reckoning[0] using it's INS sensors.
[0][https://en.wikipedia.org/wiki/Dead_reckoning](https://en.wikipedia.org/wiki/Dead_reckoning)

If you want "privacy" turn off the location services, or your phone, if you
want privacy don't take your phone with you.

That said this isn't some "conspiracy" Google actually states when you enable
background location services that this will be on all the time even when GPS
and the wireless network are explicitly disabled, IIRC even in airplane mode
the location background service can be operational without violating FCC
regulations.

~~~
leot
Do you have a citation on phones using inertial navigation?

~~~
dogma1138
The technical term is usually sensor fusion and route prediction, this is how
your phone knows that if it gets a weird echo from the GPS signal that you
haven't jumped 150 meters forward under 1 second or help you navigate in doors
etc.

It is also used for indoor navigation, Google had quite a few talks about this
this one is from Google I/O 2013
[https://www.youtube.com/watch?v=oLOUXNEcAJk](https://www.youtube.com/watch?v=oLOUXNEcAJk)
(click to
[https://youtu.be/oLOUXNEcAJk?t=1985](https://youtu.be/oLOUXNEcAJk?t=1985) if
you want to see the break down).

There were a few better/more technical talks from 2010 and a few more recent
ones that I'm trying to find again.

On android this is exposed through the Fused Sensor Location provider
[https://developers.google.com/android/reference/com/google/a...](https://developers.google.com/android/reference/com/google/android/gms/location/FusedLocationProviderApi).

"Fused Location Provider: Get highly accurate location information (latitude
and longitude) based on combined signals from the device GPS and _sensors._ "

~~~
dogma1138
I found the 2010 technical talk
[https://www.youtube.com/watch?v=C7JQ7Rpwn2k](https://www.youtube.com/watch?v=C7JQ7Rpwn2k)

And the 2nd 2013 talk
[https://youtu.be/Bte_GHuxUGc?t=400](https://youtu.be/Bte_GHuxUGc?t=400)

------
wil421
If you want to stop your network from being scanned by Google street view or
stop Microsoft doing whatever they do, you can add strings to your ssid.

[https://www.reddit.com/r/privacy/comments/3g3xyu/for_wifi_ms...](https://www.reddit.com/r/privacy/comments/3g3xyu/for_wifi_ms..).

~~~
jomamaxx
We should not have to do that.

~~~
gohrt
Talk to your government, or organize a boycott threat.

Your house is also visible in Street View, for precisely the same reason: It
transmits electromagnetic waves that are visible from public roads.

~~~
andybak
Not mine. I've painted the whole thing with Vantablack®

------
Gracana
Wifi mapping is the method by which google has no idea where I am. My roommate
moved across the country and moved in with me, and android thinks I'm at his
old house whenever I connect to his wifi router, even with GPS enabled, and
even having installed OpenWRT and changed the ssid of the router. It's pretty
maddening.

~~~
rtkwe
It's because Google and other mapping companies use the BSSID (MAC) which
doesn't change if you just change the SSID.

~~~
Gracana
Of course. I just wanted to point out that I changed everything that could be
changed apart from buying a new router. I am at Google's mercy, they created
the problem and only they can fix it.

------
dev1n
I had someone from Google (young guy, summer job stuff) come into my office
park and map out wi-fi points asking us if this office is still where the
company I work for works at. Google has the resources to utilize HUMINT.
That's how Google knows where you are.

This guy said he does this in a bunch of cities, driving around the geographic
area of the USA where I work in. Very interesting to learn about.

Edit: I am not located anywhere near where Google has an office, so for him to
stop by was interesting by itself.

Edit 2: grammar.

~~~
rasz_pl
Did he also give away promotional google pendrives by any chance? and ask for
special access to the office buildings? This sounds dodgy as f. I think your
office park was being pentested.

------
blackoil
It was possible for long. Many years back my low IQ Nokia phone had no GPS or
wifi but maps were pretty accurate using just feel phone tower tringulation.

~~~
kalleboo
Yep I have memories of traveling abroad using the J2ME Google Maps on my Sony
Ericsson dumbphone and walking down the street and waiting for it to switch to
the next tower just to see if I went in the right direction...

------
slim
If I understood correctly, android downloads nearby BSSIDs with corresponding
Geoposition when internet connectivity is available, to use them when no
connectivity is available.

It should be possible to reconstruct google's BSSID database, right?

~~~
spyder
Yes and there are multiple databases available on the net:

[http://openbmap.org/](http://openbmap.org/)

[https://openwifi.su/?lang=en](https://openwifi.su/?lang=en)

[https://wigle.net/](https://wigle.net/)

~~~
slim
I meant by hacking an android device

------
partycoder
This was not publicly known before.

To my knowledge this Google trick was first discovered by the researcher Samy
Kamkar ([https://samy.pl/mapxss](https://samy.pl/mapxss)), though the tool no
longer works.

When the tool used to work, I tested it using my home router address and it
accurately located me. Then, I moved to another house, and the location
remained being my old home. Then, after a couple of weeks, it got updated.

I think in the final product the resulting location is not only based off one
WiFi address. It might try to crossvalidate using the multiple addresses you
can see.

------
awalGarg
From the comments section of the top-voted answer:

> Something you didn't mention: when a Google-car goes around taking pictures
> for StreetView it also maps the location and all wifi networks name. So
> taking a new router with a new network name from a different ISP might work,
> but only until they come near your house to update their pictures... > \-
> Bakuriu

I am not sure how this makes me feel :-|

~~~
RKearney
You could create a faraday cage around your home to prevent your Wi-Fi signals
from broadcasting outside your home. Otherwise I don't really see the issue
with Google picking up signals from the street that people blast outside the
extents of their homes.

~~~
kuschku
So I can go around with a telezoom lens attached to a drone and photograph
into every backyard, into every window, photograph people naked in the shower,
children changing clothes on 21st floor thinking no one will look, etc – and
publish that?

Or maybe we as society do already have reasonable limits where "publicly
available" is not equivalent to "publicly indexable".

~~~
rohit89
No, this is analogous to cameras on every street. Perfectly legal even if they
are recording children ...

~~~
kuschku
But they are not.

Video surveillance of public space is illegal, not even the government can do
that.

At least here in Germany.

------
Pica_soO
Can you trace your cellphone-to-cellphone contacts, and conclude where a User
is by comparing his environment? I always imagined for fun a "underground"
internet consisting of multicellular social-organism, that traffics data by
handing packets over to another organism that is most likely to meet the user.
In Reverse this approach could be used to trace a users propable location by
finding in which social-organism s/he/it resides, and if that organism is
showing its usual behaviour. (e.g. The morning Bus-To-Work always consists of
a base set of workers and a set of drivers, the driver remaining constantly in
it, the user has for last 2 years entered this organism at the same time and
left at the same station, thus the packet can be entrusted to this organism,
who will deliver it to the most likely organism the user contacted next).

------
DanielBMarkham
I hate suggesting regulation, but devices should be required to have physical
switches for cams, mics, and radios. The gap between what the consumer thinks
their gear is doing and what it's actually doing has become far too broad.

------
jotux
[https://developers.google.com/maps/documentation/geolocation...](https://developers.google.com/maps/documentation/geolocation/intro)

------
MzHN
Most geolocation methods make sense to me, but I've yet to figure out how
Google knows the location of my desktop PC, both home and work PCs, with
greater accuracy than just city.

Neither has Wi-Fi.

------
mattbgates
Facebook knows where you are too.. and your friends. Muhahahaha.

------
rasz_pl
just wait for project tango rollout, inb4 "How does Google know the layout of
my flat and brands I use?".

------
whatnotests
Spies!

------
deadowl
cell tower triangulation.

------
tlow
Prediction.

------
chalana
Does my phone have a portion of this BSSID db locally?

