Mobile games don't tend to look favorably on rooted devices — i.e. smartphones where the user has root access to the system code — due to the potential for cheating. However, not many go to the extreme that Niantic has just imposed with a recent update for its massively popular Pokémon GO game.
After an August 18th update to v0.115.2 of the AR-based Pokémon title, user .NetRoller 3D on the XDA Developers forums reported receiving the unauthorized device error despite running stock Android, and was locked out of the game.
While the user had previously rooted their device, it wasn't root residue in the data and cache partitions or a cheating app that got them locked out (they had neither) — it was the presence of any file relating to rooting in their internal storage. That's right — Pokémon GO is using its storage read permissions to scan storage for evidence of rooting.
Even just having an empty file named after a root status concealing tool is enough to lock out a device. In a test on my unrooted Pixel 2, I found that adding an empty file named 'MagiskManager' triggered the error — whether storage permissions for the app were granted in my device's setting or not. Redditors found the same issues.
A subsequent update on August 19th did not revert the change, suggesting it was not a simple mistake or short-term test — an extremely disappointing result for players. While there are those who, for instance, use cheats only possible with rooted devices to fake out the GPS and gain access to new locations, many more root their devices to customize their operating system. Niantic has yet to respond to questions on the issue.
As for workarounds, if you're opposed to deleting any files from your storage, the other option is sandboxing to isolate Pokémon GO from the device's real internal storage. Sandboxing app Island can help with this — but it's unreleased and thus may be unstable, so use with caution.
- XDA Developers forums