Restricting fake location application while collecting gps points with Collect android app

App versions:

ODK Collect v1.27.3 also KoBoCollect v1.27.3

Problem description:

Enumerators are able to use fake location application while collecting gps points with Collect android app.

Steps to reproduce the problem:

  • Enable the fake location app.
  • Collect gps data in Collect android app.
  • You are able to collect fake gps location.

Expected behavior

While collecting data with Collect android app would it be possible to disable the fake location app that generates fake location?

Other information:

For details, please have a look at the community forum for the detailed discussion:

Hi @Lama
welcome to the forum! Please introduce yourself here!

While collecting data with Collect android app would it be possible to disable the fake location app that generates fake location?

It is doable. Location class we use provides isFromMockProvider() so we could easily check it and ignore such results.

Is that a real problem you faced?

1 Like

Hi @Grzesiek2010,

Thank you for getting back on the query! Great to hear that it's doable. Yes its a problem faced by our users where the enumerators seems to manipulate location by installing Fake GPS applications in their Android phones.

Thank you!

1 Like

Ok so wee need to figure out how to handle that issue.
We can:

  1. Ignore locations that come from fake providers at all
  2. Add an option in admin settings that would disable it (enabled by default).
  3. Do that on a form level, adding an appearance for example.

Personally I would consider first two options. @LN @seadowg any thoughts?


Yeah if isFromMockProvider() can indeed filter out results from the fake GPS apps I'd probably go for option 2. This would allow people to still use fake GPS apps for testing things out or development.

Hi Everyone

is there any update on this ,How we can disable this fake location activity

1 Like

Hi @caneeraj
we haven't implemented any changes so far to address this issue. @LN we were talking about it during v1.29 planning have you maybe thought about this issue?

This information ( isFromMockProvider() ) could be included in audit_log.

1 Like

It seems like there are more users interested in this feature so we recently discussed it. We would rather avoid adding another option in settings or on a form level to disable fake location providers. Instead we think that a good solution would be to record such fake locations normally but set the accuracy to 0.
That would indicate the location is faked because it's not possible to achieve 0 accuracy in normal life using GPS.
Thanks to that you could determine during analyzing our data whether the recorded location is real or not.

We could also add a log about using faked location provider in audit file.

What do you think about such solution?

1 Like

Hi @Grzesiek2010

Thank you for considering this ,

But my humble submission is that in case we are considering that 0 accuracy can not be achieved then in the location repoting 0 should replace Fake location as this will be much easily identifiable.

Thank you

CA Neeraj

1 Like

Note, this is how the geopoint widget already works when manually selecting a location on a map (with the placement-map option). Basically, an accuracy of 0 indicates a manually selected location ,and a non-zero accuracy indicates an actual 'real' GPS acquisition.

As a consequence, setting 'fake' GPS location to have accuracy zero would make it indistinguishable from a user-selected location, which may (or may not?) be the desired behavior...

1 Like

That's true I didn't mention it here but I think it's ok. Using both placement-map or normal gps question with a faked provider might result in receiving your real position or not. You as person responsible for analyzing data (and/or preparing a form) should know that using placement-map option doesn't guarantee collecting real locations and the same with a faked provider so if in both cases the accuracy would be 0 the behavior would be consistent.


ODK Collect v1.30.0 is now available and forces an accuracy of 0 for all locations captured from a mock location provider. As @Grzesiek2010 notes above, this behavior matches how we represent locations manually selected by data collectors on a map.

This topic was automatically closed after 6 days. New replies are no longer allowed.