Jump to content

LF a confident guy with some revesrse knowledge for some help.


Go to solution Solved by n1ce0n3,

2 posts in this topic

Recommended Posts

Posted (edited)

Hi there, I'm currently trying to hack a pretty popular game (not going to tell the name of the game, though, it's pretty new and it has around a milion downloads on the play store :))

1. The game uses LUA, which is packed with some kind of a packer that renamed all the source files into its' hashed names. There's a ton of files like that.  

(pic1, pic2)

The progress I have so far. The game uses LuaJIT-2.1.0-beta3 on top of lua5.1. If I got it right the game uses a 64-bit compiler, since LUA's header is  1B 4C 4A 02 0A, when I compile lua script with a 32bit version of luajit - the header is  1B 4C 4A 02 02, the 64 bit version gives me  1B 4C 4A 02 0A.

Okay, so.

Each of these files you can see in a screenshot is not just a LUA script.

It is a lua script, which is compiled into LuaJIT with it's own name, after that that script gets zipped into a hashed name, but it keeps the lua extension. (e.g. config/Team.lua, becomes a ZIPPed archive "aa/aa70e1b8e38c140d2242f45bb58e2edf.lua".

On top of that the zip archive gets XXTEA encrypted.

Oh, forgot to mention that the game is built on cocos2d engine.

I've managed to recover all the source files (using luajit decompiler doesn't give you the exact sources, but at least it gives you a readable file, which you can look through and actually figure what's going on there.)

The problem is that if I modify a decompiled script - pack it the way it was originally packed, most of the times - it fails to work (I think it's because the decompiler doesn't give you the exact source code as it is originally written, since I've tried compilig for all of the architectures available, and most of the time - the game eitehr hangs when it gets to read that file - or doesn't load the section that I've modified like the file is corrupt or something)

The game loads cocos2dlua.so library during the startup - and then it unloads the library, so that it doesn't remain in the proccesses' memory.

As much as I've tried - I couldn't figure the addresses of the functions I wan.

Also, the library has no exports, exports tab in IDA have a single entry, which is ".init_proc".

I've located the LUA functions' names in IDA, but since I'm not super confident with IDA, I cannot figure how do I either hook any of these, or how to get their address.

They are in the symbols table, but yet again, I have no idea how I can reach them. (pic)

I've hooked fopen, fred, fwrite, fgets, fread and most of the other relevant native functions, but the most I could've gotten was the file name that gets loaded.

TL:DR

I've decompiled all of the games' sources (over 10k LUA files), and the only thing that is left to do is to somehow execute luaL_loadstring or luaL_loadfile on my own.

I've spent quite some time on that and honestly I am out of ideas can I get what I'm trying to.

I even tried pattern scanning the binary and all its' libraries to get either of the functions, basically, any lua function - had no success so far.

 

I'll really appreciate any help I can get at this point.

Feel free to reach me out messages so then we can get in touch via discord or any way you'll prefer. Thanks in advance.

The game's binary is actually a "split installer" as they call it, it has both ARM and x86 libraries within it's content (even every lua script has another version of itself for another architecture). That prevents me from loading the binary manually into the process , since it gives me an error:

Error: dlopen failed: "/data/local/tmp/libcocos2dlua.so" has unexpected e_machine: 183 (EM_AARCH64)

Updated by n1ce0n3
  • Informative 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Our picks

    • Tiki Solitaire TriPeaks +1 Mod [ Unlimited Coins ]
      Mod APK Game Name: Tiki Solitaire TriPeaks By Scopely
      Rooted Device: Not Required.
      Google Play Store Link: 

       

      🤩 Hack Features

      - Unlimited Coins -> Earn some.
      • 0 replies
    • Tiki Solitaire TriPeaks +1 Jailed Cheat [ Unlimited Coins ]
      Modded/Hacked App: Tiki Solitaire TriPeaks By Scopely, Inc.
      Bundle ID: com.gsn.ios.tripeaks2
      iTunes Store Link: https://apps.apple.com/us/app/tiki-solitaire-tripeaks/id892521917
       

      Hack Features:
      - Unlimited Coins -> Earn some.


      Jailbreak required hack(s): https://iosgods.com/topic/171287-tiki-solitaire-tripeaks-all-versions-1-cheat-unlimited-coins/
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
        • Informative
        • Agree
        • Thanks
        • Like
      • 25 replies
    • Last Hero: Top-down Shooter +4 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Last Hero: Top-down Shooter By ITPINI OU
      Bundle ID: com.pridegames.risenhero
      iTunes Store Link: https://apps.apple.com/us/app/last-hero-top-down-shooter/id6670430912?uo=4

       

      Mod Requirements

      - Non-Jailbroken/Jailed or Jailbroken iPhone or iPad.
      - Sideloadly or alternatives.
      - Computer running Windows/macOS/Linux with iTunes installed.

       

      Hack Features

      - Unlimited Currencies & Resources -> Will increase instead of decrease.
      - God Mode
      - One-Hit Kill
      -- No Ads


      Jailbreak required iOS hacks: [Mod Menu Hack] Last Hero: Top-down Shooter v2.0 +4 Cheats [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APKs: https://iosgods.com/forum/68-android-section/
        • Agree
        • Haha
        • Thanks
        • Winner
        • Like
      • 9 replies
    • Goodwill Tiles: Match & Rescue +1 Jailed Cheat [ Debug Menu ]
      Modded/Hacked App: Goodwill Tiles: Match & Rescue By libra teknoloji anonim sirketi
      Bundle ID: com.librasoftworks.tilematch
      iTunes Store Link: https://apps.apple.com/us/app/goodwill-tiles-match-rescue/id6717585856?uo=4

       


      🤩 Hack Features

      - Debug Menu -> Head to Settings and toggle the Contact Us button. Restart the game to close the menu.
        • Like
      • 1 reply
    • Air Life: Aviation Tycoon +1++ Jailed Cheat [ Unlimited Currencies ]
      Modded/Hacked App: Air Life: Aviation Tycoon By Alphaquest Games LTDA
      Bundle ID: com.alphaquest.airlife
      iTunes Store Link: https://apps.apple.com/us/app/air-life-aviation-tycoon/id6502298994?uo=4


      Hack Features:
      - Unlimited Currencies -> Will increase instead of decrease.
      - Free In-App Purchases -> Toggle via iGMenu.


      Jailbreak required hack(s): [Mod Menu Hack] Air Life: Aviation Tycoon v1.2.2 +2++ Cheats [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
        • Informative
        • Agree
        • Winner
        • Like
      • 15 replies
    • Catacomb Crawlers +3 Jailed Cheats [ Damage & Defence ]
      Modded/Hacked App: Catacomb Crawlers By Emeroth Fintech Studio SRL
      Bundle ID: com.Emeroth-Studios.Catacomb-Crawlers
      iTunes Store Link: https://apps.apple.com/us/app/catacomb-crawlers/id6502052776?uo=4


      Hack Features:
      - Damage Multiplier
      - Defence Multiplier


      Jailbreak required hack(s): [Mod Menu Hack] Catacomb Crawlers v1.023 +2 Cheats [ Damage & Defence ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
        • Informative
        • Agree
        • Thanks
        • Like
      • 15 replies
    • Pet Pal Paw +2++ Jailed Cheats [ Debug Menu ]
      Modded/Hacked App: Pet Pal Paw By Yidian Brighten Network Technology Co., Ltd.
      Bundle ID: com.widgetpet.triplematch3d
      iTunes Store Link: https://apps.apple.com/us/app/pet-pal-paw/id6474220984?uo=4

       


      🚀 Hack Features

      - Debug Menu -> Tap on Settings.


      🍏 Jailbreak iOS hacks: [Mod Menu Hack] Pet Pal Paw v4.2 +2++ Cheats [ Debug Menu ] - Free Jailbroken Cydia Cheats - iOSGods
      🤖 Modded Android APKs: https://iosgods.com/forum/68-android-section/
        • Agree
        • Like
      • 4 replies
    • Magical Girl Dungeon +3 Jailed Cheats [ Damage ]
      Modded/Hacked App: Magical Girl Dungeon By Kenjirou Uesaka
      Bundle ID: com.KCG.MahoDungeon
      iTunes Store Link: https://apps.apple.com/us/app/magical-girl-dungeon/id6741759536?uo=4

       


      🤩 Hack Features

      - God Mode
      - Damage Multiplier
      -- No Ads
        • Informative
        • Winner
        • Like
      • 2 replies
    • Hungry Hearts Restaurant +2 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Hungry Hearts Restaurant By GAGEX Co.,Ltd.
      Bundle ID: jp.co.gagex.rigel
      iTunes Store Link: https://apps.apple.com/us/app/hungry-hearts-restaurant/id6504782640?uo=4

       
       

      🤩 Hack Features

      - Unlimited Coins -> Spend some.
      - Unlimited Hearts -> Will not decrease.


      🍏 Jailbreak iOS hacks: [Mod Menu Hack] Hungry Hearts Restaurant v1.0.7 +2 Cheats [ Unlimited Currencies ] - Free Jailbreak Cheats - iOSGods
      🤖 Modded Android APKs: https://iosgods.com/forum/68-android-section/
        • Informative
        • Like
      • 9 replies
    • Gordian Quest +6 Jailed Cheats [ Full Game Unlocked ]
      Modded/Hacked App: Gordian Quest By AETHER SKY OU
      Bundle ID: com.aethersky.com.gordianquest
      iTunes Store Link: https://apps.apple.com/us/app/gordian-quest/id6736658756?uo=4

       


      🤩 Hack Features

      - Add Currencies -> Pause the game and tap on Options.*
      - Add XP -> Pause the game and tap on Options.*
      - Add Skill Points -> Pause the game and tap on Options.*
      - Add Respec Points -> Pause the game and tap on Options.*
      - Auto Win -> Pause the game and tap on Options.*
      -- Full Game Unlocked

      * - Only 1 feature can be enabled at once.
        • Informative
        • Agree
        • Haha
        • Winner
        • Like
      • 14 replies
    • Secret Puzzle Society +4 Jailed Cheats [ Unlimited Currencies ]
      Modded/Hacked App: Secret Puzzle Society By Wildlife Studios, Inc
      Bundle ID: com.arizonags.puzzlesocietyalpha
      iTunes Store Link: https://apps.apple.com/us/app/secret-puzzle-society/id6449197556?uo=4


      Hack Features:
      - Unlimited Coins -> Earn or spend some.
      - Unlimited Clues -> Earn or spend some.
      - Unlimited Lives -> Earn or spend some.
      - Auto Win -> Use a move.


      Jailbreak required hack(s): [Mod Menu Hack] Secret Puzzle Society v1.6.3 +4 Cheats [ Unlimited Currencies ] - Free Jailbroken Cydia Cheats - iOSGods
      Modded Android APK(s): https://iosgods.com/forum/68-android-section/
      For more fun, check out the Club(s): https://iosgods.com/clubs/
        • Like
      • 18 replies
    • SushiMon Defense +3 Jailed Cheats [ Damage & Defence ]
      Modded/Hacked App: SushiMon Defense By Dreamplaygames Inc.
      Bundle ID: com.dreamplay.sushimonster.apple
      App Store Link: https://apps.apple.com/us/app/sushimon-defense/id6741675759?uo=4

       
       

      🤩 Hack Features

      - Damage Multiplier
      - Defence Multiplier
      - God Mode
        • Haha
        • Like
      • 6 replies
×
  • Create New...

Important Information

We would like to place cookies on your device to help make this website better. The website cannot give you the best user experience without cookies. You can accept or decline our cookies. You may also adjust your cookie settings. Privacy Policy - Guidelines