Every digital device, no matter if it is running software by Microsoft or Google I consider basically compromised - they may as well ( and probably do ) have root access to it. However, me being me, I like having the same amount of access and information. Just in case my device gets stolen/lost/otherwise dissapears. For this I've created a small service that can be run on boot, based on the source code of "iwlist" - which is freely available and GPL'd.
This tool, which you can find below this post as source code, can connect to my GPS tracker server, and send it the current coordinates as found by the Android system, as well as all the nearby WiFi networks. This allows the server then to determine where the phone is. This file can be compiled with an arch arm64 installation, or any other arm64 linux machine.
gcc -o gpstrack -O3 -static phonetrack.c
#chcon "u:object_r:shell_exec:s0"/vendor/bin/gpstrack
#cat /vendor/etc/init/wlan_assistant.rc
service wlan_assistant /vendor/bin/wlan_assistant
class main
user wifi
group system gps inet
on post-fs-data
start gpstrack
service gpstrack /vendor/bin/track
seclabel u:r:magisk:s0
File | tracker-2.0.7z |
Size | 377.37MB |
crc32 | 1542993883 |
md5 | 8c5c7ad4423271298ba9baaaa36aee90 |
sha512 | 0f28f74dbc61c244140c916eec169b5334c7479d8807a58cdbf9f74d778bbb5854f386e4774986ce8433dba64580b711fe8ba021e833cd8b660dd16e81dbe1f6 |
File | phonetrack.c |
Size | 22.49kB |
crc32 | 1436839025 |
md5 | c459a1ef9b8745ce6593917f492a35f8 |
sha512 | 017699fe1e00c60d6cf26ee4cc1a063018d00228d90872700dfee4fc5b89309de67f94ec6d000e9180290b0f16c463e83dc1fa5374ad8549afa9cdbb5689942e |