Cheating and piracy in mobile games: memory editing, speed hacks and modded APKs
How mobile game cheats and cracked builds work, and why the strongest defenses combine server-authoritative design with client hardening and runtime signals.
Mobile games get attacked from two directions. Cheaters change the game while it runs to win matches, farm currency or skip progression. Pirates distribute modified builds that unlock paid content or strip out ads and purchases. Both hurt revenue, and cheating also damages the experience of every honest player in the same match. This post explains how the common techniques work at a conceptual level, and why no single layer of defense is enough.
Memory editing
Game state has to live somewhere while the game runs: health, ammunition, currency, cooldown timers and inventory are all values in process memory. Memory editors scan that memory for a known value, let the player change it in the game, scan again to narrow down the address, and then overwrite it. Tools such as GameGuardian are popular on Android and are built around exactly this loop.
Memory editors usually need elevated access to another app's memory. That means a rooted device, an emulator, or a virtualization app that runs the game inside a container the cheater controls. Those environments are themselves a useful signal.
What helps
- Keep authoritative state on the server. If the server decides how much currency a player has, editing the local value only changes what the screen shows. This is the most effective control and the only one a cheater cannot patch.
- Make important values hard to find. Storing sensitive values encoded, splitting them, or keeping a checksum next to them defeats the simple scan-and-narrow approach and lets the game notice when a value changed outside normal code paths.
- Treat the environment as a signal. Root, emulators and virtualization containers do not prove cheating, but they are where most cheats run. They are good inputs to matchmaking, reporting and review.
Speed hacks
Games measure time to drive movement, animation, cooldowns and timers. A speed hack makes the game believe more or less time has passed than really has, usually by intercepting the system time functions the game or engine calls. The result is faster movement, instant reloads, shorter build timers or slowed-down opponents.
What helps
- Validate time on the server. In multiplayer games, the server should check that the actions a client reports are physically possible within the elapsed server time. In single-player games with online rewards, server timestamps should decide when a timer completes.
- Compare clocks. Comparing several time sources on the device, and comparing device time with server time over a session, exposes drift that normal devices do not show.
- Detect hooking. Speed hacks depend on intercepting function calls, so the presence of hooking frameworks is a strong signal, whether or not you can see the specific hook.
Modded APKs and repackaging
Instead of cheating at runtime, a modder can change the game itself. They unpack the APK, modify code or assets and re-sign it with their own key. For Unity games built with IL2CPP, public tools can recover much of the class and method structure from the metadata that ships with the game, which makes it easier to find functions such as damage calculation or purchase checks. The modified build is then shared through forums, messaging channels and third-party stores, often with features like unlimited currency or god mode built in.
Modded APKs are also a malware vector. Players who install them are trusting a stranger's build, and some mods carry unwanted code. That is a reputational problem for the original studio even though it did nothing wrong.
What helps
- Verify the build at runtime. The game can check that it is signed with your certificate and that its code and assets have not changed, and report the result to your servers.
- Use platform attestation. The Play Integrity API gives your server a signed verdict about whether the binary is the one you published and whether it was installed from Google Play.
- Harden the binary. Encrypting code, strings and native libraries, and obfuscating the logic that matters, raises the cost of finding and patching the functions modders target.
- Gate online features. Ranked play, leaderboards and purchases can require a passing integrity verdict, while offline play keeps working. This removes most of the value of a modded build without punishing players who are just offline.
Piracy and purchase bypass
Piracy in mobile games is mostly about in-app purchases and premium unlocks. Cracked builds either remove the purchase check entirely or fake the response from the billing library so the game believes a purchase succeeded.
The fix is well documented: never trust a purchase confirmed only on the device. Google's guidance on fighting fraud and abuse in Play Billing recommends verifying purchase tokens on your backend with the Google Play Developer API before granting entitlements. If the game has a server, purchase state and entitlements belong there.
Responding without hurting real players
Anti-cheat decisions affect real people, and false positives are expensive in reviews and support tickets. A few principles help:
- Prefer delayed, server-side action. Collect signals during play and act later through bans, shadow pools or reviews. Immediate client-side blocking tells the cheater exactly which change was detected.
- Separate signal from verdict. A rooted device is not a cheater. Combine environment signals with gameplay evidence (impossible scores, stats far outside normal ranges, physically impossible movement) before acting.
- Protect the competitive surfaces first. Ranked modes, leaderboards and the economy matter most. Casual offline play matters least.
- Plan to keep iterating. Cheat developers update their tools with your game. Rotating protections and server-side rules with each release keeps the cost on their side.
The OWASP MASVS RESILIENCE category is a useful reference for the client-side part of this, even though it was not written with games in mind: it covers tamper detection, environment detection and making reverse engineering harder.
Next step: three things the server must own
- Currency and inventory: the client requests, the server decides.
- Results: validate scores and match outcomes against what is physically possible in your game before they reach a leaderboard.
- Purchases: verify every receipt with the store on your server before granting anything.
Client hardening raises the cost of cheating. These three keep a cheat from turning into an economy problem.
Where Tamandua App Guard fits
The client-layer concepts above are educational, not an availability claim. Current App Guard evidence is a detect-only Android lab observation on one tested device: root and re-signing were detected and logged on-device. No hosted completion, console telemetry, public enrollment, purchase, blocking, or verified effect is offered. An assisted Android pilot is under consideration, not available. iOS is source/preview only; no enrollment or availability offer is made. A request records interest; it does not grant access or guarantee delivery. Until device signals reach your servers, the server-side decisions in this post have to rely on the gameplay evidence and purchase verification described above. Register interest.
Updated 2026-10-10: current App Guard availability boundaries replace the prior status paragraph.