untitled design

Apple and Google underestimate the accelerometer – the perfect tracking tool. It is in every smartphone

Every modern smartphone is equipped with an accelerometer and accompanying sensors for tracking movement – at first they appeared in mobile phones (back in the days of the iPhone 4) to determine the exact location, then they became useful in games, and now, as a result, they are integral components of gadgets. But such “harmless” sensors can be used for surveillance, and lately cybersecurity experts have been talking about it loudly.

This material is written about how the accelerometer alone or in conjunction with related sensors can be used to spy on smartphone owners, as well as why the indifference of Apple and Google in this matter poses a serious danger to the privacy of their users. The topic is based on an article by German developer and researcher Tommy Mysk – it describes the state of affairs in iOS, but the points are also true for Android.

Briefly: what is an accelerometer and why other sensors are needed

An accelerometer is a device that measures the acceleration of a smartphone. He reacts to the slightest changes, being able to record “acceleration” even by a few millimeters. In modern devices, the accelerometer works in conjunction with other sensors – for example, the Core Motion framework on iOS includes it, a gyroscope (measures the angle of inclination), a pedometer (pedometer), a magnetometer (records the level of the magnetic field) and a barometer (measures atmospheric pressure).

Some of these sensors are similar to each other and, in principle, are suitable for the same thing, but they are still used in conjunction to eliminate each other’s shortcomings. Take, for example, the function of orientation in space: the magnetometer has low accuracy for fast movements, but at a long distance it has practically no deviations. The gyroscope, in turn, responds quickly and accurately to changes, but accumulates huge errors as measurements are made. But even he needs to know the initial orientation, since he only reacts to its changes.

Within the framework of this article, a bunch of only two sensors is interesting: an accelerometer and a gyroscope. For brevity, they will often be referred to below under one name – accelerometer.

How apps can interact with the accelerometer

Both Apple and Google consider the access of applications to almost all of the above-described sensors to be completely safe – games and programs do not need to ask the user for special permission to receive information from these devices, as opposed to using the same Bluetooth or GPS. The only limitation is that applications can read accelerometer data only when they are open (you cannot track indicators in the background – at least on iOS).

How the accelerometer can be used for tracking

Although the accelerometer is installed in smartphones for good purposes, it is quite possible to investigate it to spy on the owner of the gadget. These are not just guesses – the researchers confirmed this statement in experiments, then the most interesting and non-obvious scenarios are noted.

🔴 Transport definition

The accelerometer helps you track how you hold your smartphone and how you move. With the help of this sensor, you can understand what you are doing at a particular moment (if you hold the gadget in your hands): lie down, sit, walk, ride a bike, and the like. In the iPhone, you cannot secretly access only the pedometer, since it is protected by the system resolution, but there are many complex algorithms in the public domain that can process data from other sensors to calculate steps.

Moreover, in the same iPhone there is a barometer (also with free access for applications) – a device for measuring air pressure and altitude. Thanks to the combination of all these movement tracking sensors, games and programs on a smartphone can easily determine what a person is doing while using them: riding a bus, racing on a train, or flying an airplane.

🔴 Heart rate measurement

Several years earlier, researchers at Philips Health and the University of Bristol, England, had tackled the question of finding a replacement for standard heart rate sensors in fitness trackers that use a photoplethysmogram, a method based on recording blood flow using infrared or light radiation and a photoresistor or phototransistor. They set themselves this goal because the corresponding sensor in wearable gadgets consumes too much power.

As an alternative, they chose an accelerometer (using up to 5,000 times less power). In their study, experts created two machine learning models: one relied solely on accelerometer data, and the second, if necessary, also took data from a pulse oximeter. As shown by the results of scientific work published in 2018, the second option turned out to be quite successful – using a separate heart rate sensor only 20.25% of the time, the algorithm based on the accelerometer predicted the heart rate with an average absolute error (MAE) of only 2.89 beats per minute. …

Although the first model of researchers, which relied exclusively on an accelerometer, turned out to be a failure (MSE, that is, mean square error – 94.8), the results of the scientific work are quite indicative. They give the understanding that even with the help of an accelerometer, it is potentially possible to determine a person’s heart rate while using a smartphone.

🔴 Respiration rate measurement

In 2016, an Australian electrical engineer proved experimentally that with the help of sensors in a smartphone (accelerometer and gyroscope), it is possible to quite accurately determine the breathing rate – the error is only 2 breaths per minute.

Location Sensor Actual number of breaths per minute The number of breaths per minute measured by the sensor
Abdomen Accelerometer 13 13
Breast Accelerometer 10 10
Breast Gyroscope 9 11
Abdomen Gyroscope 15 16

In practice, the method she invented has a number of limitations, because of which it can hardly be used for full-fledged surveillance, but the very potential should definitely be taken into account. There are two snags: firstly, the smartphone must take measurements within a minute (at least, this was the case in the study); secondly, the sensors of mobile gadgets record all environmental signals – for accurate measurements, the smartphone must adhere to the surface of the body, and completely.

🔴 Wiretapping and more

This is one of the most dangerous threats to privacy – in 2020, researchers developed the Spearphone algorithm, which allows partially recognizing speech from smartphone speakers. The fact is that each sound creates certain vibrations – if the sound source is loud enough, the accelerometer is able to pick up these vibrations. In their scientific work, scientists have found that if a conversation is broadcast through a regular phone speaker (not a spoken one), its vibrations can be easily caught and recognized.

10-fold cross-validation Test and training
TIGigits model PGP word list TIGigits model PGP word list
Gender classification
Samsung Galaxy S6 0,91 0,80 0,87 0,82
Samsung Galaxy Note 4 0,99 0,91 1,00 0,95
LG G3 0,89 0,95 0,85 0,95
Personality classification
Samsung Galaxy S6 0,69 0,70 0,56 0,71
Samsung Galaxy Note 4 0,94 0,80 0,92 0,80
LG G3 0,91 0,92 0,89 0,95
The results of testing the accelerometer in smartphones lying on the surface

Recognition does not mean direct conversion of vibration into the original sound – Spearphone allows you to classify a person by gender (with an accuracy of more than 90%) and personality (more than 80%). It is impossible to recognize speech by vibration, but you can try to determine the fact of pronunciation of specific words (for example, look for the word “bomb”, knowing in advance what vibration should be as a result of the pronunciation of this word) – however, the accuracy of this possibility is not indicated.

10-fold cross-validation Test and training
TIGigits model PGP word list TIGigits model PGP word list
Gender classification
Samsung Galaxy S6 0,77 0,72 0,76 0,70
Samsung Galaxy Note 4 0,81 0,87 0,77 0,88
LG G3 0,99 0,95 1,00 0,95
Personality classification
Samsung Galaxy S6 0,33 0,34 0,26 0,29
Samsung Galaxy Note 4 0,73 0,75 0,61 0,70
LG G3 0,98 0,93 1,00 0,95
Accelerometer test results in hand-held smartphones

🔴 Even the determination of the exact location, albeit indirect

All of the above methods used the accelerometer “directly”, but with the help of it it is possible to indirectly determine even the user’s location, although this sensor itself is absolutely in no way suitable for this.

Imagine that you got on a bus and opened a conditional Facebook. You are worried about your privacy and have blocked the application from tracking your location, but the person in the next seat is less careful – he sits on the same social network, but gives her access to the location. Since you are both at the same height, moving at the same speed and shaking the same (when hitting holes or bumps), the application can potentially determine that you and your neighbor are riding in the same vehicle, and therefore, it can receive your geolocation thanks to another person’s smartphone.

Which popular applications constantly use the accelerometer

Tommy Mysk analyzed the access of known applications to the accelerometer, and found that some of them use it either constantly or regularly. They all belong to Facebook.

  • Facebook client – constantly reads the accelerometer. The app uses smartphone shaking to bring up a support window, and this is probably one of the reasons for reading the sensor readings. This feature can be turned off, but after that Facebook still continues to use the accelerometer.
  • Instagram – reads the accelerometer only when the user goes to Direct (private messages section).
  • WhatsApp – reads the accelerometer in order to add a motion effect to the chat wallpaper. This option can be disabled in the settings, and after that the activation of the sensor is terminated.

In other applications tested (including Facebook Messenger), the researcher did not record access to the accelerometer for no apparent reason: Signal, Slack, Telegram, TikTok, Threema, Twitter, and WeChat.

It is worth mentioning separately Chrome, which was recently reproached for providing sites with access to the accelerometer by default – the authoritative edition of Forbes even advised its readers to delete this browser in connection with this problem (while Safari in iOS blocks the transfer of accelerometer data by default, in Chrome this option is enabled and marked as recommended for use). Unhindered access of absolutely all sites to the sensor seems really strange, because, in fact, it is really only needed by map services.

It is very easy to fix the problem – you just need to notice it.

Summing up the article, we can safely conclude that the accelerometer, in fact, can be used as fully for surveillance as the same geolocation services. It can be a great tool for both regular espionage and for creating a digital fingerprint of a user, allowing you to show him targeted ads and even manipulate his emotions using all the same advertisements.

Yes, many of the above methods of tracking through an accelerometer work more hypothetically than in reality, but the fact remains. The strangest thing is that the solution to all this is quite simple – you just need to protect access to movement tracking sensors with system resolution, as is the case with Bluetooth or location determination. Most likely, this has not yet happened solely because the problem of unhindered access to the accelerometer has become loud only recently – previously the media wrote little about it, and the already overloaded operating system developers simply did not attach any importance to this problem. We can assume that everything will change in iOS 14 and Android 13 – at least, we would very much like that.

You may also like

Get the latest

Stay Informed: Get the Latest Updates and Insights

 

Most popular