0

I developed a app in my company to fetch the location of the device of my employees. They are field technicians so I need to know their location to assign different tasks. They are aware of the app installed in their cellphones, and I managed to forbid the uninstallation, but I cant prevent them to turn off the location services. There is a way to do that?

I was thinking in developing a Custom ROM and removing this option, so it always be on but i'am not a Android developer so I don't know if it is possible to do that.

Do you know any project about this? I searched in GitHub but i couldn't find any related really.

If you can help me I would be very grateful.

Thanks.

PS: I also have a Google G suite work profile in the cellphones, but I didn't find any option to control device settings remotely.

Sagar Zala
  • 4,854
  • 9
  • 34
  • 62
  • What's your role in the company? Are you the field technicians' boss? If not, either have their boss tell them (in writing) not to disable the company's app by turning off location services, tell their/your boss that it's (for security reasons) not possible for an app to 'hack' into the phone so deeply as to technically enforce it. Or/and just do your job developing and have others deal with the problem of 'lost' field technicians. – JimmyB Jul 16 '18 at 13:03
  • Iam shsreholder of the company and CTO, so I have the power to make a decision. The problem is the app it's needed for the correct assign of the tasks but the employees think it's only for supervision so they disable GPS. They have been working 7 years without this so this is a huge change for them and they are trying to avoid adapting it. I know that the company has to work on the adoption and enforce the using of the GPS, but If we can technically enforce it will be much easier to apply this new thing. My company is during a huge scaling and technical change so that's why they are reticent – Nicolas Rodriguez Sande Jul 16 '18 at 15:02
  • I'm starting to get the picture, thank you :) Sorry I can't help with the technical solution. – JimmyB Jul 17 '18 at 08:56

1 Answers1

1

Why can't you just ask them to not turn off their location? Then in your code simply check to see if the user has disabled the GPS and if so report that user to the server, after that you can deal with whoever did this in person.

Also, make sure your users don't cheat by using a FakeGPS app.

Alireza Ahmadi
  • 5,122
  • 7
  • 40
  • 67
  • I have implemented this checks, and i can know if they disabled the GPS. But i have 500 employees, so if i have to call one by one that disable GPS it will require a lot of time and attention, even if i push automated emails or SMS, they can just ignore it and say they didn't have signal, dont know, etc... I need a solution that i can implement without adding "time cost" to the company itself. – Nicolas Rodriguez Sande Jul 16 '18 at 12:28
  • Also, they know that they cant disable GPS in business hours, but they do it anyways. And we cant find a way to enforce them to do it. The only solution that comes to my mind is installing a custom rom with settings blocked. But we dont have experience with this type of things – Nicolas Rodriguez Sande Jul 16 '18 at 12:32
  • The Fake GPS app is not a problem because they have the app installation forbidden. – Nicolas Rodriguez Sande Jul 16 '18 at 12:33
  • @NicolasRodriguezSande Beside developing a custom ROM that takes a lot of effort including updates of 500 devices there isn't anything else you can do as an app developer! – Alireza Ahmadi Jul 16 '18 at 12:34
  • I really cant figure it out, because the location services is a system wide setting, so even if my app try to force a call, if the setting is disabled i wont work. – Nicolas Rodriguez Sande Jul 16 '18 at 12:39
  • I read something about including my app in the System Administration apps so it can work at system level, but i really dont know anything about android system to start with. I developed the app in a very simple way, the app just fetches the location and send it to the server, and then the server does all the processing and logic. So it is a very simple app. – Nicolas Rodriguez Sande Jul 16 '18 at 12:41
  • Can I have your email address? I will think about it more and disscuss it with friends and come back to you. It seems really intersting and I should be an easier way. – Alireza Ahmadi Jul 16 '18 at 12:45
  • @NicolasRodriguezSande I'm thinking the same about system apps. I will do a some research tonight and come back to you – Alireza Ahmadi Jul 16 '18 at 12:47
  • Yeah of course. nicolasrsande@gmail.com its my email. Also i found this SO dicussion about the subject: https://stackoverflow.com/questions/4721449/how-can-i-enable-or-disable-the-gps-programmatically-on-android/ But this method don't work anymore because it was exploiting a bug that has been fixed. Thanks for your help! – Nicolas Rodriguez Sande Jul 16 '18 at 12:55
  • If your app is critical for their work, just block it's func, while location is disabled. Otherwise, if custom rom is not an option, talk to some top manager(or other who can take this decision) and took the time of disabled GPS from their wages :) – lewkka Jul 16 '18 at 12:58
  • @lewkka the app only fetches the location and send it to the server so its no critical for them... Haha also its not a possibility to take the time of their wages, it must be illegal to do that. The custom rom is a possibility but a hard one. I'am also interested in the way of doing that because a custom ROM can give us device bugs so we add another problem to the case haha. I really dont have experience with custom ROMs, maybe it is easier that i thought . – Nicolas Rodriguez Sande Jul 16 '18 at 13:03
  • "i can know if they disabled the GPS" ... "we cant find a way to enforce them to do it" - Huh?! For sure those people have someone superior in the company who *can* make them comply to his/her orders. "its not a possibility to take the time of their wages" - I don't think there is *any* jurisdiction in the world where not following your employer's orders must go without consequences by law. – JimmyB Jul 16 '18 at 13:09
  • @JimmyB Welcome to Argentina... hahah . They have the order to comply, but they don't accept the fact they disable the GPS, they say "i didn't have signal' and "i dont know, i just doesn't work, i dont do anything" . So you can't just take time of his wages because they will just deny disabling it... Also even if we can take time of his wages, it doesn't solve the problem. Note that the employees always tend to avoid work, it happens because they are in the field all day so they have a lot of "freedom". so its difficult to enforce them not being there, in fact, this app is part of the solution – Nicolas Rodriguez Sande Jul 16 '18 at 13:22
  • I'am looking for a more "technical" way of doing that because if i can solve it that way, i wont add "business time" to checking their condition and enforcing a "punishment". If they cant just disable the location, they will have to comply and we would not require a person to check for "infractions". – Nicolas Rodriguez Sande Jul 16 '18 at 13:22
  • Oh, ok, thanks for clearing it up for me. I was thinking the app's location feature would be needed for their work much more than needed to supervise them. – JimmyB Jul 16 '18 at 14:00